mom_oda_incupd module reference

This module contains the routines used to apply incremental updates from data assimilation.

More…

Data Types

oda_incupd_cs

oda incupd control structure

p3d

A structure for creating arrays of pointers to 3D arrays with extra gridding information.

Functions/Subroutines

initialize_oda_incupd_fixed()

This subroutine defined the control structure of module and register.

initialize_oda_incupd()

This subroutine defined the number of time step for full update, stores the layer pressure increments and initialize remap structure.

set_up_oda_incupd_field()

This subroutine stores the increments at h points for the variable whose address is given by f_ptr.

set_up_oda_incupd_vel_field()

This subroutine stores the increments at u and v points for the variable whose address is given by u_ptr and v_ptr.

calc_oda_increments()

apply_oda_incupd()

This subroutine applies oda increments to layers thicknesses, temp, salt, U and V everywhere .

output_oda_incupd_inc()

Output increment if using full fields for the oda_incupd module.

init_oda_incupd_diags()

Initialize diagnostics for the oda_incupd module.

oda_incupd_end()

This subroutine deallocates any memory associated with the oda_incupd module.

Detailed Description

Applying incremental updates requires the following: #. initialize_oda_incupd_fixed and initialize_oda_incupd

  1. set_up_oda_incupd_field (tracers) and set_up_oda_incupd_vel_field (vel)

  2. calc_oda_increments (if using full fields input)

  3. apply_oda_incupd

  4. output_oda_incupd_inc (output increment if using full fields input)

  5. init_oda_incupd_diags (to output increments in diagnostics)

  6. oda_incupd_end (not being used for now)

Type Documentation

type mom_oda_incupd/oda_incupd_cs

oda incupd control structure

Type fields
  • % nz [integer] :: The total number of layers.

  • % nz_data [integer] :: The total number of arbritary layers (used by older code).

  • % fldno [integer] :: The number of fields which have already been registered by calls to set_up_oda_incupd_field.

  • % inc [type( p3d )(50)] :: The increments to be applied to the field.

  • % inc_u [type( p3d )] :: The increments to be applied to the u-velocities.

  • % inc_v [type( p3d )] :: The increments to be applied to the v-velocities.

  • % ref_h [type( p3d )] :: Vertical grid on which the increments are provided.

  • % nstep_incupd [integer] :: number of time step for full update

  • % ncount [real] :: increment time step counter

  • % remap_cs [type(remapping_cs)] :: Remapping parameters and work arrays.

  • % incupddataongrid [logical] :: True if the incupd data are on the model horizontal grid.

  • % uv_inc [logical] :: use u and v increments

  • % diag [type(diag_ctrl),pointer] :: structure to regulate output

  • % id_u_oda_inc [integer] :: diagnostic id for zonal velocity inc.

  • % id_v_oda_inc [integer] :: diagnostic id for meridional velocity inc.

  • % id_h_oda_inc [integer] :: diagnostic id for layer thicknesses inc.

  • % id_t_oda_inc [integer] :: diagnostic id for temperature inc.

  • % id_s_oda_inc [integer] :: diagnostic id for salinity inc.

type mom_oda_incupd/p3d

A structure for creating arrays of pointers to 3D arrays with extra gridding information.

Type fields
  • % id [integer,private] :: id for FMS external time interpolator

  • % nz_data [integer,private] :: The number of vertical levels in the input field.

  • % mask_in [real(:,:,:),pointer, private] :: pointer to the data mask.

  • % p [real(:,:,:),pointer, private] :: pointer to the data.

  • % h [real(:,:,:),pointer, private] :: pointer to the data grid.

Function/Subroutine Documentation

subroutine mom_oda_incupd/initialize_oda_incupd_fixed(G, GV, US, CS, restart_CS)

This subroutine defined the control structure of module and register.

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

  • gv :: [in] ocean vertical grid structure

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

  • cs :: A pointer that is set to point to the control structure for this module (in/out).

  • restart_cs :: A pointer to the restart control structure.

Call to

mom_error_handler::mom_error

subroutine mom_oda_incupd/initialize_oda_incupd(G, GV, US, param_file, CS, data_h, nz_data, restart_CS)

This subroutine defined the number of time step for full update, stores the layer pressure increments and initialize remap structure.

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

  • gv :: [in] ocean vertical grid structure

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

  • nz_data :: [in] The total number of incr. input layers.

  • 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 (in/out).

  • data_h :: [in] The ODA h [H ~> m or kg m-2].

  • restart_cs :: A pointer to the restart control structure.

Call to

mom_remapping::initialize_remapping mom_error_handler::mom_error

subroutine mom_oda_incupd/set_up_oda_incupd_field(sp_val, G, GV, CS)

This subroutine stores the increments at h points for the variable whose address is given by f_ptr.

Parameters
  • g :: [in] Grid structure

  • gv :: [in] ocean vertical grid structure

  • cs :: oda_incupd control structure (in/out).

  • sp_val :: [in] increment field, it can have an

subroutine mom_oda_incupd/set_up_oda_incupd_vel_field(u_val, v_val, G, GV, CS)

This subroutine stores the increments at u and v points for the variable whose address is given by u_ptr and v_ptr.

Parameters
  • g :: [in] Grid structure (in).

  • gv :: [in] ocean vertical grid structure

  • cs :: oda incupd structure (in/out).

  • u_val :: [in] u increment, it has arbritary number of layers but

  • v_val :: [in] v increment, it has arbritary number of layers but

subroutine mom_oda_incupd/calc_oda_increments(h, tv, u, v, G, GV, US, CS)
Parameters
  • g :: [in] The ocean’s grid structure (in).

  • gv :: [in] ocean vertical grid structure

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

  • h :: [inout] Layer thickness [H ~> m or kg m-2] (in)

  • tv :: [in] A structure pointing to various thermodynamic variables

  • u :: [in] The zonal velocity that is being

  • v :: [in] The meridional velocity that is being

  • cs :: A pointer to the control structure for this module that is set by a previous call to initialize_oda_incupd (in).

subroutine mom_oda_incupd/apply_oda_incupd(h, tv, u, v, dt, G, GV, US, CS)

This subroutine applies oda increments to layers thicknesses, temp, salt, U and V everywhere .

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

  • gv :: [in] ocean vertical grid structure

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

  • h :: [inout] Layer thickness [H ~> m or kg m-2] (in)

  • tv :: [inout] A structure pointing to various thermodynamic variables

  • u :: [inout] The zonal velocity that is being

  • v :: [inout] The meridional velocity that is being

  • dt :: [in] The amount of time covered by this call [T ~> s].

  • cs :: A pointer to the control structure for this module that is set by a previous call to initialize_oda_incupd (in).

Called from

mom_diabatic_driver::diabatic_ale mom_diabatic_driver::diabatic_ale_legacy mom_diabatic_driver::layered_diabatic

subroutine mom_oda_incupd/output_oda_incupd_inc(Time, G, GV, param_file, CS, US)

Output increment if using full fields for the oda_incupd module.

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

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

  • gv :: [in] ocean vertical grid structure

  • param_file :: [in] A structure indicating the open file to parse for

  • cs :: ODA incupd control structure

  • us :: [in] A dimensional unit scaling

subroutine mom_oda_incupd/init_oda_incupd_diags(Time, G, GV, diag, CS, US)

Initialize diagnostics for the oda_incupd module.

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

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

  • gv :: [in] ocean vertical grid structure

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

  • cs :: ALE sponge control structure

  • us :: [in] A dimensional unit scaling

subroutine mom_oda_incupd/oda_incupd_end(CS)

This subroutine deallocates any memory associated with the oda_incupd module.

Parameters

cs :: A pointer to the control structure that is set by a previous call to initialize_oda_incupd.