gausscost/std gausscost/std#

Description#

The Bayesian cost function is the basic quadratic form derived from the Gaussian assumption in the application of the Bayesian theorem for data assimilation as described here. The defining equation is:

\[J(\mathbf{x}) = \frac{1}{2} (\mathbf{x} - \mathbf{x}^\textrm{b})^\textrm{T} (\mathbf{P}^\textrm{b})^{-1} (\mathbf{x} - \mathbf{x}^\textrm{b}) + \frac{1}{2} (\mathcal{H}(\mathbf{x}) - \mathbf{y}^\textrm{o})^\textrm{T}\mathbf{R}^{-1}(\mathcal{H}(\mathbf{x}) - \mathbf{y}^\textrm{o})\]

The Plugin returns both the cost function and its gradient. The gradient is computed using the formula:

\[\nabla J_\mathbf{x} = (\mathbf{P}^\textrm{b})^{-1} (\mathbf{x} - \mathbf{x}^\textrm{b}) + \mathcal{H}^*\left[\mathbf{R}^{-1}(\mathcal{H}(\mathbf{x}) - \mathbf{y}^\textrm{o})\right]\]

All computations of the cost function and its gradient are saved in the folder $workdir/simulator to make debugging easier, as well as monitoring conveniently variational inversions during their computation.

YAML arguments#

The following arguments are used to configure the plugin. pyCIF will return an exception at the initialization if mandatory arguments are not specified, or if any argument does not fit accepted values or type:

Optional arguments#

reload_from_previous : bool, optional, default False

Use results from previous computations, i.e., reload simulated concentrations, or adjoint sensitivities from previous observation operator computations

do_svd : bool, optional, default False

Computes the cost function based on the SVD decomposition

replace_NaNs : bool, optional, default False

Replace NaNs in departures by 0. This option must be used with caution and only when knowing where NaNs come from.

Requirements#

The current plugin requires the present plugins to run properly:

Requirement name

Requirement type

Explicit definition

Any valid

Default name

Default version

controlvect

ControlVect

True

True

standard

std

obsvect

ObsVect

False

True

standard

std

obsoperator

ObsOperator

True

True

standard

std

YAML template#

Please find below a template for a YAML configuration:

 1simulator:
 2  plugin:
 3    name: gausscost
 4    version: std
 5    type: simulator
 6
 7  # Optional arguments
 8  reload_from_previous: XXXXX  # bool
 9  do_svd: XXXXX  # bool
10  replace_NaNs: XXXXX  # bool