Skip to content

LA⚓︎

Linear advection (i.e. translation) in 1D.

Optimal solution provided by Kalman filter (ExtKF). System is typically used with a relatively large size (Nx=1000), but initialized with a moderate wavenumber (k), which a DA method should hopefully be able to exploit.

The system (and the impact on the DA) can also be adjusted by selecting non-optimal time steps, and/or various noise configs.

A summary for the purpose of DA is provided in section 3.3 of thesis found at ora.ox.ac.uk/objects/uuid:9f9961f0-6906-4147-a8a9-ca9f2d0e4a12

Modules:

Name Description
demo

Demonstrate the Linear Advection (LA) model.

evensen2009

A mix of evensen2009a and sakov2008a.

raanes2015

Reproduce results from Fig. 2 of raanes2014.

small

Smaller version.

Fmat(Nx, c, dx, dt) ⚓︎

Generate transition matrix.

  • Nx - System size
  • c - Velocity of wave. Wave travels to the rigth for c>0.
  • dx - Grid spacing
  • dt - Time step

Note that the 1st-order upwind scheme used here is exact (vis-a-vis the analytic solution) only for dt = abs(dx/c), in which case it corresponds to np.roll(x,1,axis=x.ndim-1), i.e. circshift in Matlab.

basis_vector(Nx, k) ⚓︎

Generate basis vectors.

  • Nx - state vector length
  • k - max wavenumber (wavelengths to fit into interval 1:Nx)

homogeneous_1D_cov(M, d, kind='Expo') ⚓︎

Generate a covariance matrix for a 1D homogenous random field.

Generate initial correlations for Linear Advection experiment.

d - decorr length, where the unit distance = M(i)-M(i-1) for all i.

sinusoidal_sample(Nx, k, N) ⚓︎

Generate N basis vectors, and center them.

The centring is not naturally a part of the basis generation, but serves to avoid the initial transitory regime if the model is dissipative(, and more ?).

Examples:

>>> E = sinusoidal_sample(100, 4, 5)
>>> plt.plot(E.T)