namespace mom_entrain_diffusive

Overview

Diapycnal mixing and advection in isopycnal mode. More…

namespace mom_entrain_diffusive {

// global functions

subroutine, public entrainment_diffusive(
    h h,
    tv tv,
    fluxes fluxes,
    dt dt,
    G G,
    GV GV,
    US US,
    CS CS,
    ea ea,
    eb eb,
    kb_out kb_out,
    Kd_Lay Kd_Lay,
    Kd_int Kd_int
    );

subroutine, public entrain_diffusive_init(
    Time Time,
    G G,
    GV GV,
    US US,
    param_file param_file,
    diag diag,
    CS CS
    );

subroutine, public entrain_diffusive_end(CS CS);

} // namespace mom_entrain_diffusive

Detailed Documentation

Diapycnal mixing and advection in isopycnal mode.

By Robert Hallberg, September 1997 - July 2000

This file contains the subroutines that implement diapycnal mixing and advection in isopycnal layers. The main subroutine, calculate_entrainment, returns the entrainment by each layer across the interfaces above and below it. These are calculated subject to the constraints that no layers can be driven to neg- ative thickness and that the each layer maintains its target density, using the scheme described in Hallberg (MWR 2000). There may or may not be a bulk mixed layer above the isopycnal layers. The solution is iterated until the change in the entrainment between successive iterations is less than some small tolerance.

The dual-stream entrainment scheme of MacDougall and Dewar (JPO 1997) is used for combined diapycnal advection and diffusion, modified as described in Hallberg (MWR 2000) to be solved implicitly in time. Any profile of diffusivities may be used. Diapycnal advection is fundamentally the residual of diapycnal diffusion, so the fully implicit upwind differencing scheme that is used is entirely appropriate. The downward buoyancy flux in each layer is determined from an implicit calculation based on the previously calculated flux of the layer above and an estim- ated flux in the layer below. This flux is subject to the foll- owing conditions: (1) the flux in the top and bottom layers are set by the boundary conditions, and (2) no layer may be driven below an Angstrom thickness. If there is a bulk mixed layer, the mixed and buffer layers are treated as Eulerian layers, whose thicknesses only change due to entrainment by the interior layers.

Global Functions

subroutine, public entrainment_diffusive(
    h h,
    tv tv,
    fluxes fluxes,
    dt dt,
    G G,
    GV GV,
    US US,
    CS CS,
    ea ea,
    eb eb,
    kb_out kb_out,
    Kd_Lay Kd_Lay,
    Kd_int Kd_int
    )

This subroutine calculates ea and eb, the rates at which a layer entrains from the layers above and below. The entrainment rates are proportional to the buoyancy flux in a layer and inversely proportional to the density differences between layers. The scheme that is used here is described in detail in Hallberg, Mon. Wea. Rev. 2000.

Parameters:

g

The ocean’s grid structure.

gv

The ocean’s vertical grid structure.

us

A dimensional unit scaling type

h

Layer thicknesses [H ~> m or kg m-2].

tv

A structure containing pointers to any available thermodynamic fields. Absent fields have NULL ptrs.

fluxes

A structure of surface fluxes that may be used.

dt

The time increment [T ~> s].

cs

The control structure returned by a previous call to entrain_diffusive_init.

ea

The amount of fluid entrained from the layer

eb

The amount of fluid entrained from the layer

kb_out

The index of the lightest layer denser than

kd_lay

The diapycnal diffusivity of layers

kd_int

The diapycnal diffusivity of interfaces

subroutine, public entrain_diffusive_init(
    Time Time,
    G G,
    GV GV,
    US US,
    param_file param_file,
    diag diag,
    CS CS
    )

This subroutine initializes the parameters and memory associated with the entrain_diffusive module.

Parameters:

time

The current model time.

g

The ocean’s grid structure.

gv

The ocean’s vertical grid structure.

us

A dimensional unit scaling type

param_file

A structure to parse for run-time parameters.

diag

A structure that is used to regulate diagnostic output.

cs

A pointer that is set to point to the control structure.

subroutine, public entrain_diffusive_end(CS CS)

This subroutine cleans up and deallocates any memory associated with the entrain_diffusive module.

Parameters:

cs

A pointer to the control structure for this module that will be deallocated.