ukaea / ReMKiT1D-Python

Python modules and notebooks used to initialize and analyze ReMKiT1D runs
GNU General Public License v3.0
9 stars 1 forks source link

Initialisation of variables on dual grid permits non-zero last value #28

Closed SMijin closed 5 months ago

SMijin commented 5 months ago

At the moment, there is no warning when users input a non-zero initial condition on the last (rightmost) cell boundary for variables on dual grids. This can lead to confusion, as it can confound with existing boundary conditions. For example, setting both a non-zero particle flux on the last cell as well as an explicit outflow boundary condition leads to those two fluxes adding together.

Given that there is a use case for setting these values to be non-zero (fixed outflow conditions), a warning should be added in case the user did not intend to do that.

SMijin commented 5 months ago

Added a warning when adding non-zero variables on the dual grid. Fix on dev-v1.2.0 branch.