mom_controlled_forcing module reference

Use control-theory to adjust the surface heat flux and precipitation.

More…

Data Types

ctrl_forcing_cs

Control structure for MOM_controlled_forcing.

Functions/Subroutines

apply_ctrl_forcing()

This subroutine determines corrective surface forcing fields using simple control theory.

periodic_int()

This function maps rval into an integer in the range from 1 to num_period.

periodic_real()

This function shifts rval by an integer multiple of num_period so that 0 <= val_out < num_period.

register_ctrl_forcing_restarts()

This subroutine is used to allocate and register any fields in this module that should be written to or read from the restart file.

controlled_forcing_init()

Set up this modules control structure.

controlled_forcing_end()

Clean up this modules control structure.

Detailed Description

  • By Robert Hallberg, July 2011 *

  • This program contains the subroutines that use control-theory * to adjust the surface heat flux and precipitation, based on the * time-mean or periodically (seasonally) varying anomalies from the * observed state. The techniques behind this are described in * Hallberg and Adcroft (2011, in prep.). *

  • Macros written all in capital letters are defined in MOM_memory.h. *

  • A small fragment of the grid is shown below: *

  • j+1 x ^ x ^ x At x: q * j+1 > o > o > At ^: v, tauy * j x ^ x ^ x At >: u, taux * j > o > o > At o: h, fluxes. * j-1 x ^ x ^ x * i-1 i i+1 At x & ^: * i i+1 At > & o: *

  • The boundaries always run through q grid points (x). *

Adjustments are based on the time-mean or periodically (seasonally) varying anomalies from the observed state.

The techniques behind this are described in Hallberg and Adcroft (2018, in prep.).

Type Documentation

type mom_controlled_forcing/ctrl_forcing_cs

Control structure for MOM_controlled_forcing.

Type fields:
  • % use_temperature [logical] :: If true, temperature and salinity are used as state variables.

  • % do_integrated [logical] :: If true, use time-integrated anomalies to control the surface state.

  • % num_cycle [integer] :: The number of elements in the forcing cycle.

  • % heat_int_rate [real] :: The rate at which heating anomalies accumulate [T-1 ~> s-1].

  • % prec_int_rate [real] :: The rate at which precipitation anomalies accumulate [T-1 ~> s-1].

  • % heat_cyc_rate [real] :: The rate at which cyclical heating anomalies accumulate [T-1 ~> s-1].

  • % prec_cyc_rate [real] :: The rate at which cyclical precipitation anomalies accumulate [T-1 ~> s-1].

  • % len2 [real] :: The square of the length scale over which the anomalies are smoothed via a Laplacian filter [L2 ~> m2].

  • % lam_heat [real] :: A constant of proportionality between SST anomalies and heat fluxes [Q R Z T-1 C-1 ~> W m-2 degC-1].

  • % lam_prec [real] :: A constant of proportionality between SSS anomalies (normalised by mean SSS) and precipitation [R Z T-1 ~> kg m-2 s-1].

  • % lam_cyc_heat [real] :: A constant of proportionality between cyclical SST anomalies and corrective heat fluxes [Q R Z T-1 C-1 ~> W m-2 degC-1].

  • % lam_cyc_prec [real] :: A constant of proportionality between cyclical SSS anomalies (normalised by mean SSS) and corrective precipitation [R Z T-1 ~> kg m-2 s-1].

  • % heat_0 [real(:,:),pointer] :: The non-periodic integrative corrective heat flux that has been.

  • % precip_0 [real(:,:),pointer] :: The non-periodic integrative corrective precipitation that has been.

  • % heat_cyc [real(:,:,:),pointer] :: The periodic integrative corrective heat flux that has been evolved.

  • % precip_cyc [real(:,:,:),pointer] :: The non-periodic integrative corrective precipitation that has been.

  • % avg_time [real(:),pointer] :: The accumulated averaging time in each part of the cycle [T ~> s] or.

  • % avg_sst_anom [real(:,:,:),pointer] :: The time-averaged periodic sea surface temperature anomalies [C ~> degC],.

  • % avg_sss_anom [real(:,:,:),pointer] :: The time-averaged periodic sea surface salinity anomalies [S ~> ppt],.

  • % avg_sss [real(:,:,:),pointer] :: The time-averaged periodic sea surface salinities [S ~> ppt], or (at.

  • % diag [type( diag_ctrl ),pointer] :: A structure that is used to regulate the timing of diagnostic output.

  • % id_heat_0 [integer] :: Diagnostic handle for the steady heat flux.

  • % id_prec_0 [integer] :: Diagnostic handle for the steady precipitation.

Function/Subroutine Documentation

subroutine mom_controlled_forcing/apply_ctrl_forcing(SST_anom, SSS_anom, SSS_mean, virt_heat, virt_precip, day_start, dt, G, US, CS)

This subroutine determines corrective surface forcing fields using simple control theory.

Parameters:
  • g :: [inout] The ocean’s grid structure

  • sst_anom :: [in] The sea surface temperature anomalies [C ~> degC]

  • sss_anom :: [in] The sea surface salinity anomlies [S ~> ppt]

  • sss_mean :: [in] The mean sea surface salinity [S ~> ppt]

  • virt_heat :: [inout] Virtual (corrective) heat fluxes that are augmented in this subroutine [Q R Z T-1 ~> W m-2]

  • virt_precip :: [inout] Virtual (corrective) precipitation fluxes that are augmented in this subroutine [R Z T-1 ~> kg m-2 s-1]

  • day_start :: [in] Start time of the fluxes.

  • dt :: [in] Length of time over which these fluxes will be applied [T ~> s]

  • us :: [in] A dimensional unit scaling type

  • cs :: A pointer to the control structure returned by a previous call to ctrl_forcing_init.

Call to:

mom_error_handler::mom_error periodic_int periodic_real

function mom_controlled_forcing/periodic_int(rval, num_period) [integer]

This function maps rval into an integer in the range from 1 to num_period.

Parameters:
  • rval :: [in] Input for mapping [nondim]

  • num_period :: [in] Maximum output.

Return:

undefined :: Return value.

Called from:

apply_ctrl_forcing

function mom_controlled_forcing/periodic_real(rval, num_period) [real]

This function shifts rval by an integer multiple of num_period so that 0 <= val_out < num_period.

Parameters:
  • rval :: [in] Input to be shifted into valid range [nondim]

  • num_period :: [in] Maximum valid value.

Return:

undefined :: Return value [nondim]

Called from:

apply_ctrl_forcing

subroutine mom_controlled_forcing/register_ctrl_forcing_restarts(G, US, param_file, CS, restart_CS)

This subroutine is used to allocate and register any fields in this module that should be written to or read from the restart file.

Parameters:
  • g :: [in] The ocean’s grid structure.

  • us :: [in] A dimensional unit scaling type

  • param_file :: [in] A structure indicating the open file to parse for model parameter values.

  • cs :: A pointer that is set to point to the control structure for this module.

  • restart_cs :: [inout] MOM restart control struct

Call to:

mom_error_handler::mom_error

subroutine mom_controlled_forcing/controlled_forcing_init(Time, G, US, param_file, diag, CS)

Set up this modules control structure.

Parameters:
  • time :: [in] The current model time.

  • g :: [in] The ocean’s grid structure.

  • us :: [in] A dimensional unit scaling type

  • param_file :: [in] A structure indicating the open file to parse for model parameter values.

  • diag :: [in] A structure that is used to regulate diagnostic output.

  • cs :: A pointer that is set to point to the control structure for this module.

Call to:

mom_diag_mediator::register_diag_field

subroutine mom_controlled_forcing/controlled_forcing_end(CS)

Clean up this modules control structure.

Parameters:

cs :: A pointer to the control structure returned by a previous call to controlled_forcing_init, it will be deallocated here.