ERF
Energy Research and Forecasting: An Atmospheric Modeling Code
ERF_FloodCoupler.H File Reference

The atmosphere side of the flood coupling, shared by every flood engine. More...

#include <memory>
#include <string>
#include <vector>
#include <AMReX_MultiFab.H>
#include <AMReX_Geometry.H>
#include <AMReX_BoxArray.H>
#include <ERF_FloodCouplingParams.H>
#include <ERF_FloodEngine.H>
#include <ERF_FloodGrid.H>
#include <ERF_SurfacePrecipitation.H>
Include dependency graph for ERF_FloodCoupler.H:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  FloodCoupler
 

Detailed Description

The atmosphere side of the flood coupling, shared by every flood engine.

ERF holds one FloodCoupler (std::unique_ptr<FloodCoupler> m_flood_coupler), which owns the flood engine selected by erf.flood.engine. The coupler:

  • checks the ERF configuration a flood grid needs and builds that grid on the level it refines (erf.flood.anchor_level);
  • keeps the microphysics surface precipitation accumulation it saw last, and each step of that level hands the engine the change since then (liquid and frozen), with the wind after the dycore (FloodForcing);
  • writes the engine's fields into the ERF plotfile on request;
  • records the flood grid in the checkpoint and refuses a restart onto another one.

The coupling is one-way: nothing returns to the atmosphere.