Running an inverse simulation

Running an inverse simulation#

Tutorials to run inversions are available in the CHIMERE section. Here, we provide a specific yaml as an example. In this example, 6 CH4 emission sectors are optimized within a 4D-VAR inversion. These 6 sectors are respectively AGRIWST (agriculture and waste), FF (fossil fuels, transport and industry), BBB (biomass and biofuel burning), WET (wetlands), ONAT (termites, geological, freshwaters, soil sinks) and OCE (oceans).

This yaml is mostly similar to the previous forward yaml. The main changes are the following ones:

  • mode: has to be set to 4dvar (or other inversion mode). The minimizer and simulator used in the previous studies are respectively M1QN3 and gausscost, but could be changed (congrad minimizer in particular). epsg sets the limit of the inversion in terms of the reduction of the norm of the gradient of the cost function, niter the limit in terms of maximum number of iterations.

  • datavect: for each component to be optimized in the control vector, hresol has to be defined. The resolution (hresol, tresol, vresol for the background, and if necessary the regions_infos), the error (err) and the correlations (hcorrelations, tcorrelations, vcorrelations for the background) have to be set in this section.

Note

The choice of the parameters of the B matrix (resolution, error, correlations of errors) is crucial for the results of the inversion. It is based on scientific assumptions, but also on technical limits (memory, computational cost…). In particular, hresol can be set to hpixels, regions or global. In our example, the fluxes are optimized as regions. Here, the R matrix is assumed to be diagonal, with the coefficients equal to the corresponding obserror. A representation error and a model error should also be accounted for.

The outputs of the simulation are located here:

  • Optimized fluxes: $WORKDIR/controlvect/fluxes/controlvect_flux_CH4[sector].nc

  • Optimized background: $WORKDIR/controlvect/background/controlvect_background_CH4.nc

  • Prior obs/sim (first forward): $WORKDIR/obsoperator/fwd_-001/obsvect/[satellites or concs]/CH4/monitor.nc

  • Posterior obs/sim (last forward): $WORKDIR/obsoperator/fwd_-002/obsvect/[satellites or concs]/CH4/monitor.nc

  • Evolution of the cost and gradcost: $WORKDIR/simulator/gradcost.txt

The gradcost.txt file can be used during the inversion to monitor the progress of the optimization. Documentation about the structure of controlvect and obsvect is provided respectively here and here.

Warning

The emission estimates of regional inversions result from the balance between the background optimization and the flux optimization. This balance is subtle, and background optimization remains a major challenge for regional inversions. It is something to keep in mind when analysing the outputs of the inversion!