Shadowing sensitivity algorithms for chaotic systems
Source:R/sensitivity-algorithms.R
shadowing_algorithms.RdLeast squares shadowing computes derivatives of long time averages
<g> = (1/T) int g(u, p, t) dt of ergodic chaotic systems, whose
ordinary sensitivities grow without bound. ForwardLSS() and
AdjointLSS() solve the discretized least squares problem on the saved
points of a solution; NILSS() (forward) and NILSAS() (adjoint)
restrict the computation to the unstable subspace, integrating tangent or
adjoint solutions over nseg segments of nstep saved points each.
TimeDilation(), CosWindowing() and Cos2Windowing() choose how
LSS treats the time average.
Usage
ForwardLSS(LSSregularizer = TimeDilation(10), g = NULL, autojacvec = NULL)
AdjointLSS(LSSregularizer = TimeDilation(10), g = NULL, autojacvec = NULL)
TimeDilation(alpha, t0skip = 0, t1skip = 0)
CosWindowing()
Cos2Windowing()
NILSS(nseg, nstep, nus = NULL, g = NULL, seed = NULL, autojacvec = NULL)
NILSAS(
nseg,
nstep,
M = NULL,
g = NULL,
seed = NULL,
autojacvec = NULL,
adjoint_sensealg = NULL
)Arguments
- LSSregularizer
TimeDilation(alpha, t0skip, t1skip)(the default, weightalphaof the time dilation, times skipped at both ends),CosWindowing()orCos2Windowing().- g
The instantaneous objective
g(u, p, t).- autojacvec
As in sensitivity_algorithms.
- alpha, t0skip, t1skip
Time dilation weight and skipped times.
- nseg, nstep
Number of segments and of saved points per segment.
- nus
Dimension of the unstable subspace for
NILSS()(defaultlength(u0) - 1).- seed
Seed of the random initial tangent or adjoint directions.
- M
Number of homogeneous adjoint solutions for
NILSAS()(at least the number of positive Lyapunov exponents plus one).- adjoint_sensealg
For
NILSAS(): the continuous adjoint method of the segment solves.BacksolveAdjoint()integrates the state backward with the adjoint from the state saved at each segment end (Julia's default); the other methods (the defaultNULLisInterpolatingAdjoint()) read the state from the dense forward solution.