Theory
The equations implemented in WAM2layers v3 are described in detail in this manuscript. Below, we provide a brief summary of the main principle.
Considering the schematic illustration below, forward- and backward tracking can be formulated respectively as:
where \(F\) are (total) moisture fluxes and \(s\) represents the amount of tracked relative to total moisture in the grid cells. The vertical fluxes, denoted by underscript \(u\) and \(l\), are not illustrated, but they follow the same systematic as the horizontal fluxes. Note that all fluxes are by definition positive; this is needed because moisture flux is scaled with the relative amount of tracked moisture in the grid cells where it originates from.

In WAM2Layers code, these equations are solved for one upper and one lower layer (such that only two of the 4 vertical transport terms are relevant for each layer). The evaporation term is used for the lower layer only, while the precipitation contribution is distributed across the two layers.
Sensitivity analysis time and vertical resolution
In WAM2layers (and in most other moisture tracking mdodels) several settings are optional regarding resolutions in time and space. We recommend to at least critically think about these settings in the light of your research question rather than just applying the default values from the config file. A recommended sensitivity study is this thesis, for which the underlying data can be found here.