MOM_forcing_type module reference
This module implements boundary forcing for MOM6.
Data Types
Structure that contains pointers to the boundary forcing used to drive the liquid ocean simulated by MOM. |
|
Structure that contains pointers to the mechanical forcing at the surface used to drive the liquid ocean simulated by MOM. Data in this type is allocated in the module MOM_surface_forcing.F90, of which there are three versions: solo, coupled, and ice-shelf. |
|
Structure that defines the id handles for the forcing type |
Generic Interfaces
Allocate the fields of a (flux) forcing type, based on either a set of input flags for each group of fields, or a pre-allocated reference forcing. |
|
Allocate the fields of a mechanical forcing type, based on either a set of input flags for each group of fields, or a pre-allocated reference forcing. |
|
Allocate arrays if optional flag is present and true (works for 2D and 3D) |
|
Determine the friction velocity from a forcing type or a mechanical forcing type. |
Functions/Subroutines
This subroutine extracts fluxes from the surface fluxes type. It works on a j-row for optimization purposes. The 2d (i,j) wrapper is the next subroutine below. This routine multiplies fluxes by dt, so that the result is an accumulation of fluxes over a time step. |
|
2d wrapper for 1d extract fluxes from surface fluxes type. This subroutine extracts fluxes from the surface fluxes type. It multiplies the fluxes by dt, so that the result is an accumulation of the fluxes over a time step. |
|
This routine calculates surface buoyancy flux by adding up the heat, FW & salt fluxes. These are actual fluxes, with units of stuff per time. Setting dt=1 in the call to extractFluxes routine allows us to get "stuf per time" rather than the time integrated fluxes needed in other routines that call extractFluxes. |
|
Calculates surface buoyancy flux by adding up the heat, FW and salt fluxes, for 2d arrays. This is a wrapper for calculateBuoyancyFlux1d. |
|
Determine the friction velocity from the contenxts of a forcing type, perhaps using the evolving surface density. |
|
Determine the friction velocity from the contenxts of a forcing type, perhaps using the evolving surface density. |
|
Write out chksums for thermodynamic fluxes. |
|
Write out chksums for the driving mechanical forces. |
|
Write out values of the mechanical forcing arrays at the i,j location. This is a debugging tool. |
|
Write out values of the fluxes arrays at the i,j location. This is a debugging tool. |
|
Register members of the forcing type for diagnostics |
|
Accumulate the forcing over time steps, taking input from a mechanical forcing type and a temporary forcing-flux type. |
|
Accumulate the thermodynamic fluxes over time steps |
|
This subroutine copies the computational domains of common forcing fields from a mech_forcing type to a (thermodynamic) forcing type. |
|
This subroutine calculates certain derived forcing fields based on information from a mech_forcing type and stores them in a (thermodynamic) forcing type. |
|
This subroutine determines the net mass source to the ocean from a (thermodynamic) forcing type and stores it in a mech_forcing type. |
|
This subroutine calculates determines the net mass source to the ocean from a (thermodynamic) forcing type and stores it in a provided array. |
|
This subroutine copies the computational domains of common forcing fields from a mech_forcing type to a (thermodynamic) forcing type. |
|
Offer mechanical forcing fields for diagnostics for those fields registered as part of register_forcing_type_diags. |
|
Offer buoyancy forcing fields for diagnostics for those fields registered as part of register_forcing_type_diags. |
|
Conditionally allocate fields within the forcing type |
|
Allocate elements of a new forcing type based on their status in an existing type. |
|
Conditionally allocate fields within the mechanical forcing type using control flags. |
|
Conditionally allocate fields within the mechanical forcing type based on a reference forcing. |
|
Return flags indicating which groups of forcings are allocated |
|
Return flags indicating which groups of mechanical forcings are allocated |
|
Allocates and zeroes-out array. |
|
Deallocate the forcing type |
|
Deallocate the mechanical forcing type |
|
Rotate the fluxes by a set number of quarter turns |
|
Rotate the forcing fields from the input domain |
|
Homogenize the forcing fields from the input domain |
|
Homogenize the fluxes |
|
Detailed Description
Boundary fluxes
The ocean is a forced-dissipative system. Forcing occurs at the boundaries, and this module mediates the various forcing terms from momentum, heat, salt, and mass. Boundary fluxes from other tracers are treated by coupling to biogeochemical models. We here present elements of how MOM6 assumes boundary fluxes are passed into the ocean.
Note that all fluxes are positive into the ocean. For surface boundary fluxes, that means fluxes are positive downward. For example, a positive shortwave flux warms the ocean.
Surface boundary momentum fluxes
The ocean surface exchanges momentum with the overlying atmosphere, sea ice, and land ice. The momentum is exchanged as a horizontal stress (Newtons per squared meter: N/m2) imposed on the upper ocean grid cell.
Surface boundary mass fluxes
The ocean gains or loses mass through evaporation, precipitation, sea ice melt/form, and river runoff. Positive mass fluxes add mass to the liquid ocean. The boundary mass flux units are (kilogram per square meter per sec: kg/(m2/sec)).
Evaporation field can in fact represent a mass loss (evaporation) or mass gain (condensation in foggy areas).
sea ice formation leads to mass moving from the liquid ocean to the ice model, and melt adds liquid to the ocean.
Precipitation can be liquid or frozen (snow). Furthermore, in some versions of the GFDL coupler, precipitation can be negative. The reason is that the ice model combines precipitation with ice melt and ice formation. This limitation of the ice model diagnostics should be overcome future versions.
River runoff can be liquid or frozen. Frozen runoff is often associated with calving land-ice and/or ice bergs.
Surface boundary salt fluxes
Over most of the ocean, there is no exchange of salt with the atmosphere. However, the liquid ocean exchanges salt with sea ice. When ice forms, it extracts salt from ice pockets and discharges the salt into the liquid ocean. The salt concentration of sea ice is therefore much lower (around 5ppt) than liquid seawater (around 30-35ppt in high latitudes).
For ocean-ice models run with a prescribed atmosphere, such as in the CORE/OMMIP simulations, it is necessary to employ a surface restoring term to the k=1 salinity equation, thus imposing a salt flux onto the ocean even outside of sea ice regimes. This salt flux is non-physical, and represents a limitation of the ocean-ice models run without an interactive atmosphere. Sometimes this salt flux is converted to an implied fresh water flux. However, doing so generally leads to changes in the sea level, unless a global normalization is provided to zero-out the net water flux. As a complement, for models with a restoring salt flux, one may choose to zero-out the net salt entering the ocean. There are pros/cons of each approach.
Surface boundary heat fluxes
There are many terms that contribute to boundary-related heating of the k=1 surface model grid cell. We here outline details of this heat, with each term having units W/m2.
The net flux of heat crossing ocean surface is stored in the diagnostic array "hfds". This array is computed as
shortwave (SW) = shortwave radiation (always warms ocean)
longwave (LW) = longwave radiation (generally cools ocean)
latent (LAT) = turbulent latent heat loss due to evaporation (liquid to vapor) or melt (snow to liquid); generally cools the ocean
sensible (SENS) = turbulent heat transfer due to differences in air-sea or ice-sea temperature
mass transfer (MASS) = heat transfer due to heat content of mass (e.g., E-P+R) transferred across ocean surface; computed relative to 0 Celsius
frazil (FRAZ) = heat transferred to form frazil sea ice (positive heating of liquid ocean)
restore (RES) = heat from surface damping sometimes imposed in non-coupled model simulations .
restore (flux adjustments) = heat from surface flux adjustment.
Treatment of shortwave
The shortwave field itself is split into two pieces:
shortwave = penetrative SW + non-penetrative SW
non-penetrative = non-downwelling shortwave; portion of SW totally absorbed in the k=1 cell. The non-penetrative SW is combined with LW+LAT+SENS+seaice_melt_heat in net_heat inside routine extractFluxes1d. Notably, for many cases, non-penetrative SW = 0.
penetrative = that portion of shortwave penetrating below a tiny surface layer. This is the downwelling shortwave. Penetrative SW participates in the penetrative SW heating of k=1,nz cells, with the amount of penetration dependent on optical properties.
Convergence of heat into the k=1 cell
The convergence of boundary-related heat into surface grid cell is given by the difference in the net heat entering the top of the k=1 cell and the penetrative SW leaving the bottom of the cell.
The convergence of the penetrative shortwave flux is given by \(\mbox{pen}\_\mbox{SW (enter k)}-\mbox{pen}\_\mbox{SW (leave k)}\). This term appears for all cells k=1,nz. It is diagnosed as "rsdoabsorb" inside module MOM6/src/parameterizations/vertical/MOM_diabatic_aux.F90
Type Documentation
- type, public :: forcing
Structure that contains pointers to the boundary forcing used to drive the liquid ocean simulated by MOM.
Data in this type is allocated in the module MOM_surface_forcing.F90, of which there are three: solo, coupled, and ice-shelf. Alternatively, they are allocated in MESO_surface_forcing.F90, which is a special case of solo_driver/MOM_surface_forcing.F90.
- Parameters
omega_w2x
the counter-clockwise angle of the wind stress with respect
ustar
surface friction velocity scale [Z T-1 ~> m s-1].
tau_mag
Magnitude of the wind stress averaged over tracer cells, including any contributions from sub-gridscale variability or gustiness, rescaled to units that are more convenient for calculating turbulent fluxes and friction velocities [R Z2 T-2 ~> Pa]
ustar_gustless
surface friction velocity scale without any any augmentation for gustiness [Z T-1 ~> m s-1].
tau_mag_gustless
Magnitude of the wind stress averaged over tracer cells, without any augmentation for sub-gridscale variability or gustiness, rescaled to units that are more convenient for calculating turbulent fluxes and friction velocities [R Z2 T-2 ~> Pa]
buoy
buoyancy flux [L2 T-3 ~> m2 s-3]
sw
shortwave [Q R Z T-1 ~> W m-2]
sw_vis_dir
visible, direct shortwave [Q R Z T-1 ~> W m-2]
sw_vis_dif
visible, diffuse shortwave [Q R Z T-1 ~> W m-2]
sw_nir_dir
near-IR, direct shortwave [Q R Z T-1 ~> W m-2]
sw_nir_dif
near-IR, diffuse shortwave [Q R Z T-1 ~> W m-2]
lw
longwave [Q R Z T-1 ~> W m-2] (typically negative)
latent
latent [Q R Z T-1 ~> W m-2] (typically < 0)
sens
sensible [Q R Z T-1 ~> W m-2] (typically negative)
seaice_melt_heat
sea ice and snow melt or formation [Q R Z T-1 ~> W m-2] (typically negative)
heat_added
additional heat flux from SST restoring or flux adjustments [Q R Z T-1 ~> W m-2]
latent_evap_diag
latent [Q R Z T-1 ~> W m-2] from evaporating liquid water (typically < 0)
latent_fprec_diag
latent [Q R Z T-1 ~> W m-2] from melting fprec (typically < 0)
latent_frunoff_diag
latent [Q R Z T-1 ~> W m-2] from melting frunoff (calving) (typically < 0)
latent_frunoff_glc_diag
latent [Q R Z T-1 ~> W m-2] from melting glacier frunoff (typically < 0)
evap
(-1)*fresh water flux evaporated out of the ocean [R Z T-1 ~> kg m-2 s-1]
lprec
precipitating liquid water into the ocean [R Z T-1 ~> kg m-2 s-1]
fprec
precipitating frozen water into the ocean [R Z T-1 ~> kg m-2 s-1]
vprec
virtual liquid precip associated w/ SSS restoring [R Z T-1 ~> kg m-2 s-1]
lrunoff
liquid river runoff entering ocean [R Z T-1 ~> kg m-2 s-1]
frunoff
frozen river runoff (calving) entering ocean [R Z T-1 ~> kg m-2 s-1]
lrunoff_glc
liquid river glacier runoff entering ocean [R Z T-1 ~> kg m-2 s-1]
frunoff_glc
frozen river glacier runoff entering ocean [R Z T-1 ~> kg m-2 s-1]
seaice_melt
snow/seaice melt (positive) or formation (negative) [R Z T-1 ~> kg m-2 s-1]
carbon_content_lrunoff
carbon content associated with liquid runoff [R Z T-1 ~> kg m-2 s-1]
netMassIn
Sum of water mass fluxes into the ocean integrated over a forcing timestep [H ~> m or kg m-2]
netMassOut
Net water mass flux out of the ocean integrated over a forcing timestep, with negative values for water leaving the ocean [H ~> m or kg m-2]
heat_content_cond
heat content associated with condensating water [Q R Z T-1 ~> W m-2]
heat_content_evap
heat content associated with evaporating water [Q R Z T-1 ~> W m-2]
heat_content_lprec
heat content associated with liquid >0 precip [Q R Z T-1 ~> W m-2]
heat_content_fprec
heat content associated with frozen precip [Q R Z T-1 ~> W m-2]
heat_content_vprec
heat content associated with virtual >0 precip [Q R Z T-1 ~> W m-2]
heat_content_lrunoff
heat content associated with liquid runoff [Q R Z T-1 ~> W m-2]
heat_content_frunoff
heat content associated with frozen runoff [Q R Z T-1 ~> W m-2]
heat_content_lrunoff_glc
heat content associated with liquid runoff [Q R Z T-1 ~> W m-2]
heat_content_frunoff_glc
heat content associated with frozen runoff [Q R Z T-1 ~> W m-2]
heat_content_massout
heat content associated with mass leaving ocean [Q R Z T-1 ~> W m-2]
heat_content_massin
heat content associated with mass entering ocean [Q R Z T-1 ~> W m-2]
salt_flux
net salt flux into the ocean [R Z T-1 ~> kgSalt m-2 s-1]
salt_flux_in
salt flux provided to the ocean from coupler [R Z T-1 ~> kgSalt m-2 s-1]
salt_flux_added
additional salt flux from restoring or flux adjustment before adjustment to net zero [R Z T-1 ~> kgSalt m-2 s-1]
salt_left_behind
salt left in ocean at the surface from brine rejection [R Z T-1 ~> kgSalt m-2 s-1]
p_surf_full
Pressure at the top ocean interface [R L2 T-2 ~> Pa]. if there is sea-ice, then p_surf_flux is at ice-ocean interface
p_surf
Pressure at the top ocean interface [R L2 T-2 ~> Pa] as used to drive the ocean model. If p_surf is limited, p_surf may be smaller than p_surf_full, otherwise they are the same.
p_surf_SSH
Pressure at the top ocean interface [R L2 T-2 ~> Pa] that is used in corrections to the sea surface height field that is passed back to the calling routines. p_surf_SSH may point to p_surf or to p_surf_full.
accumulate_p_surf
If true, the surface pressure due to the atmosphere and various types of ice needs to be accumulated, and the surface pressure explicitly reset to zero at the driver level when appropriate.
BBL_tidal_dis
Tidal energy dissipation in the bottom boundary layer that can act as a source of energy for bottom boundary layer mixing [R Z L2 T-3 ~> W m-2]
ustar_tidal
tidal contribution to bottom ustar [Z T-1 ~> m s-1]
ustar_berg
iceberg contribution to top ustar [Z T-1 ~> m s-1].
area_berg
fractional area of ocean surface covered by icebergs [nondim]
mass_berg
mass of icebergs [R Z ~> kg m-2]
ustar_shelf
Friction velocity under ice-shelves [Z T-1 ~> m s-1]. as computed by the ocean at the previous time step.
frac_shelf_h
Fractional ice shelf coverage of h-cells, from 0 to 1 [nondim]. This is only associated if ice shelves are enabled, and are exactly 0 away from shelves or on land.
iceshelf_melt
Ice shelf melt rate (positive) or freezing (negative) [R Z T-1 ~> kg m-2 s-1]
shelf_sfc_mass_flux
Ice shelf surface mass flux deposition from the atmosphere. [R Z T-1 ~> kg m-2 s-1]
vPrecGlobalAdj
adjustment to restoring vprec to zero out global net [R Z T-1 ~> kg m-2 s-1]
saltFluxGlobalAdj
adjustment to restoring salt flux to zero out global net [R Z T-1 ~> kgSalt m-2 s-1]
netFWGlobalAdj
adjustment to net fresh water to zero out global net [R Z T-1 ~> kg m-2 s-1]
vPrecGlobalScl
scaling of restoring vprec to zero out global net ( -1..1 ) [nondim]
saltFluxGlobalScl
scaling of restoring salt flux to zero out global net ( -1..1 ) [nondim]
netFWGlobalScl
scaling of net fresh water to zero out global net ( -1..1 ) [nondim]
fluxes_used
If true, all of the heat, salt, and mass fluxes have been applied to the ocean.
dt_buoy_accum
The amount of time over which the buoyancy fluxes should be applied [T ~> s]. If negative, this forcing type variable has not yet been initialized.
gustless_accum_bug
If true, use an incorrect expression in the time average of the gustless wind stress.
C_p
heat capacity of seawater [Q C-1 ~> J kg-1 degC-1]. C_p is is the same value as in thermovar_ptrs_type.
ice_fraction
fraction of sea ice coverage at h-cells, from 0 to 1 [nondim].
u10_sqr
wind magnitude at 10 m squared [L2 T-2 ~> m2 s-2]
noy_dep
NOy Deposition [conc Z T-1 ~> conc m s-1]
nhx_dep
NHx Deposition [conc Z T-1 ~> conc m s-1]
atm_co2
Atmospheric CO2 Concentration [ppm]
atm_alt_co2
Alternate atmospheric CO2 Concentration [ppm]
dust_flux
Flux of dust into the ocean [R Z T-1 ~> kgN m-2 s-1]
iron_flux
Flux of dust into the ocean [conc Z T-1 ~> conc m s-1]
atm_fine_dust_flux
Fine dust flux from atmosphere [R Z T-1 ~> kg m-2 s-1]
atm_coarse_dust_flux
Coarse dust flux from atmosphere [R Z T-1 ~> kg m-2 s-1]
seaice_dust_flux
Dust flux from seaice [R Z T-1 ~> kg m-2 s-1]
atm_bc_flux
Black carbon flux from atmosphere [R Z T-1 ~> kg m-2 s-1]
seaice_bc_flux
Black carbon flux from seaice [R Z T-1 ~> kg m-2 s-1]
fracr_cat
per-category ice fraction [nondim]
qsw_cat
per-category shortwave [Q R Z T-1 ~> W m-2]
lamult
Langmuir enhancement factor [nondim]
tr_fluxes
This structure contains arrays of of named fields used for passive tracer fluxes. All arrays in tr_fluxes use the coupler indexing, which has no halos. This is not a convenient convention, but imposed on MOM6 by the coupler.
num_msg
Number of messages issued about excessive SW penetration
max_msg
Maximum number of messages to issue about excessive SW penetration
- type, public :: mech_forcing
Structure that contains pointers to the mechanical forcing at the surface used to drive the liquid ocean simulated by MOM. Data in this type is allocated in the module MOM_surface_forcing.F90, of which there are three versions: solo, coupled, and ice-shelf.
- Parameters
taux
zonal wind stress [R L Z T-2 ~> Pa]
tauy
meridional wind stress [R L Z T-2 ~> Pa]
tau_mag
Magnitude of the wind stress averaged over tracer cells, including any contributions from sub-gridscale variability or gustiness [R L Z T-2 ~> Pa]
ustar
surface friction velocity scale [Z T-1 ~> m s-1].
net_mass_src
The net mass source to the ocean [R Z T-1 ~> kg m-2 s-1]
omega_w2x
the counter-clockwise angle of the wind stress with respect to the horizontal abscissa (x-coordinate) at tracer points [rad].
p_surf_full
Pressure at the top ocean interface [R L2 T-2 ~> Pa]. if there is sea-ice, then p_surf_flux is at ice-ocean interface
p_surf
Pressure at the top ocean interface [R L2 T-2 ~> Pa] as used to drive the ocean model. If p_surf is limited, p_surf may be smaller than p_surf_full, otherwise they are the same.
p_surf_SSH
Pressure at the top ocean interface [R L2 T-2 ~> Pa] that is used in corrections to the sea surface height field that is passed back to the calling routines. p_surf_SSH may point to p_surf or to p_surf_full.
area_berg
fractional area of ocean surface covered by icebergs [nondim]
mass_berg
mass of icebergs per unit ocean area [R Z ~> kg m-2]
frac_shelf_u
Fractional ice shelf coverage of u-cells, nondimensional from 0 to 1 [nondim]. This is only associated if ice shelves are enabled, and is exactly 0 away from shelves or on land.
frac_shelf_v
Fractional ice shelf coverage of v-cells, nondimensional from 0 to 1 [nondim]. This is only associated if ice shelves are enabled, and is exactly 0 away from shelves or on land.
rigidity_ice_u
Depth-integrated lateral viscosity of ice shelves or sea ice at u-points [L4 Z-1 T-1 ~> m3 s-1]
rigidity_ice_v
Depth-integrated lateral viscosity of ice shelves or sea ice at v-points [L4 Z-1 T-1 ~> m3 s-1]
dt_force_accum
The amount of time over which the mechanical forcing fluxes have been averaged [T ~> s].
net_mass_src_set
If true, an estimate of net_mass_src has been provided.
accumulate_p_surf
If true, the surface pressure due to the atmosphere and various types of ice needs to be accumulated, and the surface pressure explicitly reset to zero at the driver level when appropriate.
accumulate_rigidity
If true, the rigidity due to various types of ice needs to be accumulated, and the rigidity explicitly reset to zero at the driver level when appropriate.
stk_wavenumbers
The central wave number of Stokes bands [rad Z-1 ~> rad m-1]
ustkb
Stokes Drift spectrum, zonal [L T-1 ~> m s-1] Horizontal - u points 3rd dimension - wavenumber
vstkb
Stokes Drift spectrum, meridional [L T-1 ~> m s-1] Horizontal - v points 3rd dimension - wavenumber
initialized
This indicates whether the appropriate arrays have been initialized.
- type, public :: forcing_diags
Structure that defines the id handles for the forcing type
- Parameters
id_prcme
Forcing diagnostic handles
id_evap
Forcing diagnostic handles
id_precip
Forcing diagnostic handles
id_vprec
Forcing diagnostic handles
id_lprec
Forcing diagnostic handles
id_fprec
Forcing diagnostic handles
id_lrunoff
Forcing diagnostic handles
id_frunoff
Forcing diagnostic handles
id_lrunoff_glc
Forcing diagnostic handles
id_frunoff_glc
Forcing diagnostic handles
id_net_massout
Forcing diagnostic handles
id_net_massin
Forcing diagnostic handles
id_massout_flux
Forcing diagnostic handles
id_massin_flux
Forcing diagnostic handles
id_seaice_melt
Forcing diagnostic handles
id_total_prcme
Forcing diagnostic handles
id_total_evap
Forcing diagnostic handles
id_total_precip
Forcing diagnostic handles
id_total_vprec
Forcing diagnostic handles
id_total_lprec
Forcing diagnostic handles
id_total_fprec
Forcing diagnostic handles
id_total_lrunoff
Forcing diagnostic handles
id_total_frunoff
Forcing diagnostic handles
id_total_lrunoff_glc
Forcing diagnostic handles
id_total_frunoff_glc
Forcing diagnostic handles
id_total_net_massout
Forcing diagnostic handles
id_total_net_massin
Forcing diagnostic handles
id_total_seaice_melt
Forcing diagnostic handles
id_prcme_ga
Forcing diagnostic handles
id_evap_ga
Forcing diagnostic handles
id_lprec_ga
Forcing diagnostic handles
id_fprec_ga
Forcing diagnostic handles
id_precip_ga
Forcing diagnostic handles
id_vprec_ga
Forcing diagnostic handles
id_net_heat_coupler
Forcing diagnostic handles
id_net_heat_surface
Forcing diagnostic handles
id_sens
Forcing diagnostic handles
id_LwLatSens
Forcing diagnostic handles
id_sw
Forcing diagnostic handles
id_lw
Forcing diagnostic handles
id_sw_vis
Forcing diagnostic handles
id_sw_nir
Forcing diagnostic handles
id_lat_evap
Forcing diagnostic handles
id_lat_frunoff
Forcing diagnostic handles
id_lat_frunoff_glc
Forcing diagnostic handles
id_lat
Forcing diagnostic handles
id_lat_fprec
Forcing diagnostic handles
id_heat_content_lrunoff
Forcing diagnostic handles
id_heat_content_frunoff
Forcing diagnostic handles
id_heat_content_lrunoff_glc
Forcing diagnostic handles
id_heat_content_frunoff_glc
Forcing diagnostic handles
id_heat_content_lprec
Forcing diagnostic handles
id_heat_content_fprec
Forcing diagnostic handles
id_heat_content_cond
Forcing diagnostic handles
id_heat_content_surfwater
Forcing diagnostic handles
id_heat_content_evap
Forcing diagnostic handles
id_heat_content_vprec
Forcing diagnostic handles
id_heat_content_massout
Forcing diagnostic handles
id_heat_added
Forcing diagnostic handles
id_heat_content_massin
Forcing diagnostic handles
id_hfrainds
Forcing diagnostic handles
id_hfrunoffds
Forcing diagnostic handles
id_seaice_melt_heat
Forcing diagnostic handles
id_carbon_content_lrunoff
Forcing diagnostic handles
id_total_net_heat_coupler
Forcing diagnostic handles
id_total_net_heat_surface
Forcing diagnostic handles
id_total_sens
Forcing diagnostic handles
id_total_LwLatSens
Forcing diagnostic handles
id_total_sw
Forcing diagnostic handles
id_total_lw
Forcing diagnostic handles
id_total_lat_evap
Forcing diagnostic handles
id_total_lat_frunoff
Forcing diagnostic handles
id_total_lat_frunoff_glc
Forcing diagnostic handles
id_total_lat
Forcing diagnostic handles
id_total_lat_fprec
Forcing diagnostic handles
id_total_heat_content_lrunoff
Forcing diagnostic handles
id_total_heat_content_frunoff
Forcing diagnostic handles
id_total_heat_content_lrunoff_glc
Forcing diagnostic handles
id_total_heat_content_frunoff_glc
Forcing diagnostic handles
id_total_heat_content_lprec
Forcing diagnostic handles
id_total_heat_content_fprec
Forcing diagnostic handles
id_total_heat_content_cond
Forcing diagnostic handles
id_total_heat_content_surfwater
Forcing diagnostic handles
id_total_heat_content_evap
Forcing diagnostic handles
id_total_heat_content_vprec
Forcing diagnostic handles
id_total_heat_content_massout
Forcing diagnostic handles
id_total_heat_added
Forcing diagnostic handles
id_total_heat_content_massin
Forcing diagnostic handles
id_total_seaice_melt_heat
Forcing diagnostic handles
id_net_heat_coupler_ga
Forcing diagnostic handles
id_net_heat_surface_ga
Forcing diagnostic handles
id_sens_ga
Forcing diagnostic handles
id_LwLatSens_ga
Forcing diagnostic handles
id_sw_ga
Forcing diagnostic handles
id_lw_ga
Forcing diagnostic handles
id_lat_ga
Forcing diagnostic handles
id_saltflux
Forcing diagnostic handles
id_saltFluxIn
Forcing diagnostic handles
id_saltFluxAdded
Forcing diagnostic handles
id_saltFluxBehind
Forcing diagnostic handles
id_total_saltflux
Forcing diagnostic handles
id_total_saltFluxIn
Forcing diagnostic handles
id_total_saltFluxAdded
Forcing diagnostic handles
id_vPrecGlobalAdj
Forcing diagnostic handles
id_vPrecGlobalScl
Forcing diagnostic handles
id_saltFluxGlobalAdj
Forcing diagnostic handles
id_saltFluxGlobalScl
Forcing diagnostic handles
id_netFWGlobalAdj
Forcing diagnostic handles
id_netFWGlobalScl
Forcing diagnostic handles
id_taux
Forcing diagnostic handles
id_tauy
Forcing diagnostic handles
id_ustar
Forcing diagnostic handles
id_omega_w2x
Forcing diagnostic handles
id_tau_mag
Forcing diagnostic handles
id_psurf
Forcing diagnostic handles
id_TKE_tidal
Forcing diagnostic handles
id_buoy
Forcing diagnostic handles
id_ice_fraction
Forcing diagnostic handles
id_u10_sqr
Forcing diagnostic handles
id_atm_fine_dust_flux
Forcing diagnostic handles
id_atm_coarse_dust_flux
Forcing diagnostic handles
id_atm_bc_flux
Forcing diagnostic handles
id_seaice_dust_flux
Forcing diagnostic handles
id_seaice_bc_flux
Forcing diagnostic handles
id_ustar_berg
Forcing diagnostic handles
id_area_berg
Forcing diagnostic handles
id_mass_berg
Forcing diagnostic handles
id_ustar_ice_cover
Forcing diagnostic handles
id_frac_ice_cover
Forcing diagnostic handles
id_lamult
Forcing diagnostic handles
id_clock_forcing
CPU clock id
Generic Interface Documentation
- interface allocate_forcing_type
Allocate the fields of a (flux) forcing type, based on either a set of input flags for each group of fields, or a pre-allocated reference forcing.
Callers call graph
Text view
mom::step_mom → mom_forcing_type::interface::allocate_forcing_type
mom_forcing_type::allocate_forcing_by_ref → mom_forcing_type::interface::allocate_forcing_type
mom_forcing_type::forcing_diagnostics → mom_forcing_type::interface::allocate_forcing_type
mom_ice_shelf::adjust_ice_sheet_frazil → mom_forcing_type::interface::allocate_forcing_type
mom_ice_shelf::initialize_ice_shelf_fluxes → mom_forcing_type::interface::allocate_forcing_type
mom_ice_shelf::shelf_calc_flux → mom_forcing_type::interface::allocate_forcing_type
mom_surface_forcing::set_forcing → mom_forcing_type::interface::allocate_forcing_type
- interface allocate_mech_forcing
Allocate the fields of a mechanical forcing type, based on either a set of input flags for each group of fields, or a pre-allocated reference forcing.
Callers call graph
Text view
idealized_hurricane::idealized_hurricane_wind_forcing → mom_forcing_type::interface::allocate_mech_forcing
mom::step_mom → mom_forcing_type::interface::allocate_mech_forcing
mom_forcing_type::allocate_mech_forcing_from_ref → mom_forcing_type::interface::allocate_mech_forcing
mom_forcing_type::mech_forcing_diags → mom_forcing_type::interface::allocate_mech_forcing
mom_ice_shelf::add_shelf_forces → mom_forcing_type::interface::allocate_mech_forcing
mom_ice_shelf::initialize_ice_shelf_forces → mom_forcing_type::interface::allocate_mech_forcing
mom_surface_forcing::neverworld_wind_forcing → mom_forcing_type::interface::allocate_mech_forcing
mom_surface_forcing::scurve_wind_forcing → mom_forcing_type::interface::allocate_mech_forcing
mom_surface_forcing::set_forcing → mom_forcing_type::interface::allocate_mech_forcing
mom_surface_forcing::wind_forcing_by_data_override → mom_forcing_type::interface::allocate_mech_forcing
user_surface_forcing::user_wind_forcing → mom_forcing_type::interface::allocate_mech_forcing
- interface myAlloc
Allocate arrays if optional flag is present and true (works for 2D and 3D)
- interface find_ustar
Determine the friction velocity from a forcing type or a mechanical forcing type.
Callers call graph
Text view
mom_bulk_mixed_layer::bulkmixedlayer → mom_forcing_type::interface::find_ustar
mom_diabatic_driver::diabatic_ale → mom_forcing_type::interface::find_ustar
mom_diabatic_driver::diabatic_ale_legacy → mom_forcing_type::interface::find_ustar
mom_diabatic_driver::layered_diabatic → mom_forcing_type::interface::find_ustar
mom_mixed_layer_restrat::mixedlayer_restrat_bml → mom_forcing_type::interface::find_ustar
mom_mixed_layer_restrat::mixedlayer_restrat_bodner → mom_forcing_type::interface::find_ustar
mom_mixed_layer_restrat::mixedlayer_restrat_om4 → mom_forcing_type::interface::find_ustar
mom_set_visc::set_viscous_ml → mom_forcing_type::interface::find_ustar
mom_vert_friction::vertvisc_coef → mom_forcing_type::interface::find_ustar
Functions/Subroutine Documentation
- subroutine extractFluxes1d(G, GV, US, fluxes, optics, nsw, j, dt, FluxRescaleDepth, useRiverHeatContent, useCalvingHeatContent, h, T, netMassInOut, netMassOut, net_heat, net_salt, pen_SW_bnd, tv, aggregate_FW, nonpenSW, netmassInOut_rate, net_Heat_Rate, net_salt_rate, pen_sw_bnd_Rate)
This subroutine extracts fluxes from the surface fluxes type. It works on a j-row for optimization purposes. The 2d (i,j) wrapper is the next subroutine below. This routine multiplies fluxes by dt, so that the result is an accumulation of fluxes over a time step.
- Parameters
G [in]
ocean grid structure
GV [in]
ocean vertical grid structure
US [in]
A dimensional unit scaling type
fluxes [inout]
structure containing pointers to possible forcing fields. NULL unused fields.
optics
pointer to optics
nsw [in]
number of bands of penetrating SW
j [in]
j-index to work on
dt [in]
The time step for these fluxes [T ~> s]
FluxRescaleDepth [in]
min ocean depth before fluxes are scaled away [H ~> m or kg m-2]
useRiverHeatContent [in]
logical for river heat content
useCalvingHeatContent [in]
logical for calving heat content
h [in]
layer thickness [H ~> m or kg m-2]
T [in]
layer temperatures [C ~> degC]
netMassInOut [out]
net mass flux (non-Bouss) or volume flux (if Bouss) of water in/out of ocean over a time step [H ~> m or kg m-2]
netMassOut [out]
net mass flux (non-Bouss) or volume flux (if Bouss) of water leaving ocean surface over a time step [H ~> m or kg m-2]. netMassOut < 0 means mass leaves ocean.
net_heat [out]
net heat at the surface accumulated over a time step for coupler + restoring. Exclude two terms from net_heat: (1) downwelling (penetrative) SW, (2) evaporation heat content, (since do not yet know evap temperature). [C H ~> degC m or degC kg m-2].
net_salt [out]
surface salt flux into the ocean accumulated over a time step [S H ~> ppt m or ppt kg m-2].
pen_SW_bnd [out]
penetrating SW flux, split into bands. [C H ~> degC m or degC kg m-2] and array size nsw x SZI_(G), where nsw=number of SW bands in pen_SW_bnd. This heat flux is not part of net_heat.
tv [inout]
structure containing pointers to available thermodynamic fields. Used to keep track of the heat flux associated with net mass fluxes into the ocean.
aggregate_FW [in]
For determining how to aggregate forcing.
nonpenSW [out]
Non-penetrating SW used in net_heat [C H ~> degC m or degC kg m-2]. Summed over SW bands when diagnosing nonpenSW.
net_Heat_rate [out]
Rate of net surface heating [C H T-1 ~> degC m s-1 or degC kg m-2 s-1].
net_salt_rate [out]
Surface salt flux into the ocean [S H T-1 ~> ppt m s-1 or ppt kg m-2 s-1].
netmassInOut_rate [out]
Rate of net mass flux into the ocean [H T-1 ~> m s-1 or kg m-2 s-1].
pen_sw_bnd_rate [out]
Rate of penetrative shortwave heating [C H T-1 ~> degC m s-1 or degC kg m-2 s-1].
Callees call graph
Callers call graph
Text view
- subroutine extractFluxes2d(G, GV, US, fluxes, optics, nsw, dt, FluxRescaleDepth, useRiverHeatContent, useCalvingHeatContent, h, T, netMassInOut, netMassOut, net_heat, Net_salt, Pen_SW_bnd, tv, aggregate_FW)
2d wrapper for 1d extract fluxes from surface fluxes type. This subroutine extracts fluxes from the surface fluxes type. It multiplies the fluxes by dt, so that the result is an accumulation of the fluxes over a time step.
- Parameters
G [in]
ocean grid structure
GV [in]
ocean vertical grid structure
US [in]
A dimensional unit scaling type
fluxes [inout]
structure containing pointers to forcing.
optics
pointer to optics
nsw [in]
number of bands of penetrating SW
dt [in]
The time step for these fluxes [T ~> s]
FluxRescaleDepth [in]
min ocean depth before fluxes are scaled away [H ~> m or kg m-2]
useRiverHeatContent [in]
logical for river heat content
useCalvingHeatContent [in]
logical for calving heat content
h [in]
layer thickness [H ~> m or kg m-2]
T [in]
layer temperatures [C ~> degC]
netMassInOut [out]
net mass flux (non-Bouss) or volume flux (if Bouss) of water in/out of ocean over a time step [H ~> m or kg m-2]
netMassOut [out]
net mass flux (non-Bouss) or volume flux (if Bouss) of water leaving ocean surface over a time step [H ~> m or kg m-2].
net_heat [out]
net heat at the surface accumulated over a time step associated with coupler + restore. Exclude two terms from net_heat: (1) downwelling (penetrative) SW, (2) evaporation heat content, (since do not yet know temperature of evap). [C H ~> degC m or degC kg m-2]
net_salt [out]
surface salt flux into the ocean accumulated over a time step [S H ~> ppt m or ppt kg m-2]
pen_SW_bnd [out]
penetrating SW flux, by frequency band [C H ~> degC m or degC kg m-2] with array size nsw x SZI_(G), where nsw=number of SW bands in pen_SW_bnd. This heat flux is not in net_heat.
tv [inout]
structure containing pointers to available thermodynamic fields. Here it is used to keep track of the heat flux associated with net mass fluxes into the ocean.
aggregate_FW [in]
For determining how to aggregate the forcing.
- subroutine calculateBuoyancyFlux1d(G, GV, US, fluxes, optics, nsw, h, Temp, Salt, tv, j, buoyancyFlux, netHeatMinusSW, netSalt)
This routine calculates surface buoyancy flux by adding up the heat, FW & salt fluxes. These are actual fluxes, with units of stuff per time. Setting dt=1 in the call to extractFluxes routine allows us to get "stuf per time" rather than the time integrated fluxes needed in other routines that call extractFluxes.
- Parameters
G [in]
ocean grid
GV [in]
ocean vertical grid structure
US [in]
A dimensional unit scaling type
fluxes [inout]
surface fluxes
optics
penetrating SW optics
nsw [in]
The number of frequency bands of penetrating shortwave radiation
h [in]
layer thickness [H ~> m or kg m-2]
Temp [in]
prognostic temp [C ~> degC]
Salt [in]
salinity [S ~> ppt]
tv [inout]
thermodynamics type
j [in]
j-row to work on
buoyancyFlux [out]
buoyancy fluxes [L2 T-3 ~> m2 s-3]
netHeatMinusSW [out]
Surface heat flux excluding shortwave [C H T-1 ~> degC m s-1 or degC kg m-2 s-1]
netSalt [out]
surface salt flux [S H T-1 ~> ppt m s-1 or ppt kg m-2 s-1]
Callees call graph
Text view
mom_forcing_type::calculatebuoyancyflux1d → mom_eos::eos_domain
mom_forcing_type::calculatebuoyancyflux1d → mom_eos::interface::calculate_density_derivs
mom_forcing_type::calculatebuoyancyflux1d → mom_eos::interface::calculate_specific_vol_derivs
mom_forcing_type::calculatebuoyancyflux1d → mom_forcing_type::extractfluxes1d
mom_forcing_type::calculatebuoyancyflux1d → mom_interface_heights::interface::thickness_to_dz
mom_forcing_type::calculatebuoyancyflux1d → mom_opacity::optics_nbands
mom_forcing_type::calculatebuoyancyflux1d → mom_opacity::sumswoverbands
Callers call graph
- subroutine calculateBuoyancyFlux2d(G, GV, US, fluxes, optics, h, Temp, Salt, tv, buoyancyFlux, netHeatMinusSW, netSalt)
Calculates surface buoyancy flux by adding up the heat, FW and salt fluxes, for 2d arrays. This is a wrapper for calculateBuoyancyFlux1d.
- Parameters
G [in]
ocean grid
GV [in]
ocean vertical grid structure
US [in]
A dimensional unit scaling type
fluxes [inout]
surface fluxes
optics
SW ocean optics
h [in]
layer thickness [H ~> m or kg m-2]
Temp [in]
temperature [C ~> degC]
Salt [in]
salinity [S ~> ppt]
tv [inout]
thermodynamics type
buoyancyFlux [inout]
buoyancy fluxes [L2 T-3 ~> m2 s-3]
netHeatMinusSW [inout]
surface heat flux excluding shortwave [C H T-1 ~> degC m s-1 or degC kg m-2 s-1]
netSalt [inout]
Net surface salt flux [S H T-1 ~> ppt m s-1 or ppt kg m-2 s-1]
Callees call graph
- subroutine find_ustar_fluxes(fluxes, tv, U_star, G, GV, US, halo, H_T_units)
Determine the friction velocity from the contenxts of a forcing type, perhaps using the evolving surface density.
- Parameters
G [in]
The ocean's grid structure
GV [in]
The ocean's vertical grid structure
US [in]
A dimensional unit scaling type
fluxes [in]
Surface fluxes container
tv [in]
Structure containing pointers to any available thermodynamic fields.
U_star [out]
The surface friction velocity [Z T-1 ~> m s-1] or [H T-1 ~> m s-1 or kg m-2 s-1], depending on H_T_units.
halo [in]
The extra halo size to fill in, 0 by default
H_T_units [in]
If present and true, return U_star in units of [H T-1 ~> m s-1 or kg m-2 s-1]
- subroutine find_ustar_mech_forcing(forces, tv, U_star, G, GV, US, halo, H_T_units)
Determine the friction velocity from the contenxts of a forcing type, perhaps using the evolving surface density.
- Parameters
G [in]
The ocean's grid structure
GV [in]
The ocean's vertical grid structure
US [in]
A dimensional unit scaling type
forces [in]
Surface forces container
tv [in]
Structure containing pointers to any available thermodynamic fields.
U_star [out]
The surface friction velocity [Z T-1 ~> m s-1]
halo [in]
The extra halo size to fill in, 0 by default
H_T_units [in]
If present and true, return U_star in units of [H T-1 ~> m s-1 or kg m-2 s-1]
Callees call graph
- subroutine MOM_forcing_chksum(mesg, fluxes, G, US, haloshift)
Write out chksums for thermodynamic fluxes.
- Parameters
mesg [in]
message
fluxes [in]
A structure containing thermodynamic forcing fields
G [in]
grid type
US [in]
A dimensional unit scaling type
haloshift [in]
shift in halo
Callees call graph
Callers call graph
Text view
mom_diabatic_driver::diabatic → mom_forcing_type::mom_forcing_chksum
mom_diabatic_driver::diabatic_ale → mom_forcing_type::mom_forcing_chksum
mom_diabatic_driver::diabatic_ale_legacy → mom_forcing_type::mom_forcing_chksum
mom_diabatic_driver::layered_diabatic → mom_forcing_type::mom_forcing_chksum
mom_ice_shelf::add_shelf_flux → mom_forcing_type::mom_forcing_chksum
mom_ice_shelf::shelf_calc_flux → mom_forcing_type::mom_forcing_chksum
- subroutine MOM_mech_forcing_chksum(mesg, forces, G, US, haloshift)
Write out chksums for the driving mechanical forces.
- Parameters
mesg [in]
message
forces [in]
A structure with the driving mechanical forces
G [in]
grid type
US [in]
A dimensional unit scaling type
haloshift [in]
shift in halo
Callees call graph
Callers call graph
- subroutine mech_forcing_SinglePointPrint(forces, G, i, j, mesg)
Write out values of the mechanical forcing arrays at the i,j location. This is a debugging tool.
- Parameters
forces [in]
A structure with the driving mechanical forces
G [in]
Grid type
mesg [in]
Message
i [in]
i-index
j [in]
j-index
Callees call graph
- subroutine locMsg(array, aname)
Format and write a message depending on associated state of array
- Parameters
array
Array to write element from
aname
Name of array
Callers call graph
- subroutine forcing_SinglePointPrint(fluxes, G, i, j, mesg)
Write out values of the fluxes arrays at the i,j location. This is a debugging tool.
- Parameters
fluxes [in]
A structure containing thermodynamic forcing fields
G [in]
Grid type
mesg [in]
Message
i [in]
i-index
j [in]
j-index
Callees call graph
Callers call graph
- subroutine locMsg(array, aname)
Format and write a message depending on associated state of array
- Parameters
array
Array to write element from
aname
Name of array
Callers call graph
- subroutine register_forcing_type_diags(Time, diag, US, use_temperature, handles, use_berg_fluxes, use_waves, use_cfcs, use_MARBL_tracers, use_glc_runoff, use_carbon_runoff)
Register members of the forcing type for diagnostics
- Parameters
Time [in]
time type
diag [inout]
diagnostic control type
US [in]
A dimensional unit scaling type
use_temperature [in]
True if T/S are in use
handles [inout]
handles for diagnostics
use_berg_fluxes [in]
If true, allow iceberg flux diagnostics
use_waves [in]
If true, allow wave forcing diagnostics
use_cfcs [in]
If true, allow cfc related diagnostics
use_MARBL_tracers [in]
If true, allow MARBL related diagnostics
use_glc_runoff [in]
If true, allow separate glacial runoff diagnostics
use_carbon_runoff [in]
If true, allow separate carbon runoff diagnostics
Callees call graph
Callers call graph
- subroutine forcing_accumulate(flux_tmp, forces, fluxes, G, wt2)
Accumulate the forcing over time steps, taking input from a mechanical forcing type and a temporary forcing-flux type.
- Parameters
flux_tmp [in]
A temporary structure with current thermodynamic forcing fields
forces [in]
A structure with the driving mechanical forces
fluxes [inout]
A structure containing time-averaged thermodynamic forcing fields
G [inout]
The ocean's grid structure
wt2 [out]
The relative weight of the new fluxes [nondim]
Callees call graph
- subroutine fluxes_accumulate(flux_tmp, fluxes, G, wt2, forces)
Accumulate the thermodynamic fluxes over time steps
- Parameters
flux_tmp [in]
A temporary structure with current thermodynamic forcing fields
fluxes [inout]
A structure containing time-averaged thermodynamic forcing fields
G [inout]
The ocean's grid structure
wt2 [out]
The relative weight of the new fluxes [nondim]
forces [in]
A structure with the driving mechanical forces
Callees call graph
Callers call graph
- subroutine copy_common_forcing_fields(forces, fluxes, G, skip_pres)
This subroutine copies the computational domains of common forcing fields from a mech_forcing type to a (thermodynamic) forcing type.
- Parameters
forces [in]
A structure with the driving mechanical forces
fluxes [inout]
A structure containing thermodynamic forcing fields
G [in]
grid type
skip_pres [in]
If present and true, do not copy pressure fields.
Callers call graph
- subroutine set_derived_forcing_fields(forces, fluxes, G, US, Rho0)
This subroutine calculates certain derived forcing fields based on information from a mech_forcing type and stores them in a (thermodynamic) forcing type.
- Parameters
forces [in]
A structure with the driving mechanical forces
fluxes [inout]
A structure containing thermodynamic forcing fields
G [in]
grid type
US [in]
A dimensional unit scaling type
Rho0 [in]
A reference density of seawater [R ~> kg m-3], as used to calculate ustar.
Callers call graph
- subroutine set_net_mass_forcing(fluxes, forces, G, US)
This subroutine determines the net mass source to the ocean from a (thermodynamic) forcing type and stores it in a mech_forcing type.
- Parameters
fluxes [in]
A structure containing thermodynamic forcing fields
forces [inout]
A structure with the driving mechanical forces
US [in]
A dimensional unit scaling type
G [in]
The ocean grid type
Callees call graph
Callers call graph
- subroutine get_net_mass_forcing(fluxes, G, US, net_mass_src)
This subroutine calculates determines the net mass source to the ocean from a (thermodynamic) forcing type and stores it in a provided array.
- Parameters
fluxes [in]
A structure containing thermodynamic forcing fields
G [in]
The ocean grid type
US [in]
A dimensional unit scaling type
net_mass_src [out]
The net mass flux of water into the ocean [R Z T-1 ~> kg m-2 s-1].
Callers call graph
- subroutine copy_back_forcing_fields(fluxes, forces, G)
This subroutine copies the computational domains of common forcing fields from a mech_forcing type to a (thermodynamic) forcing type.
- Parameters
fluxes [in]
A structure containing thermodynamic forcing fields
forces [inout]
A structure with the driving mechanical forces
G [in]
grid type
- subroutine mech_forcing_diags(forces_in, dt, G, time_end, diag, handles)
Offer mechanical forcing fields for diagnostics for those fields registered as part of register_forcing_type_diags.
- Parameters
forces_in [in]
mechanical forcing input fields
dt [in]
time step for the forcing [T ~> s]
G [in]
grid type
time_end [in]
The end time of the diagnostic interval.
diag [inout]
diagnostic type
handles [inout]
diagnostic id for diag_manager
Callees call graph
Text view
mom_forcing_type::mech_forcing_diags → mom_cpu_clock_infra::cpu_clock_begin
mom_forcing_type::mech_forcing_diags → mom_cpu_clock_infra::cpu_clock_end
mom_forcing_type::mech_forcing_diags → mom_diag_mediator::disable_averaging
mom_forcing_type::mech_forcing_diags → mom_diag_mediator::enable_averages
mom_forcing_type::mech_forcing_diags → mom_diag_mediator::interface::post_data
mom_forcing_type::mech_forcing_diags → mom_forcing_type::deallocate_mech_forcing
mom_forcing_type::mech_forcing_diags → mom_forcing_type::interface::allocate_mech_forcing
mom_forcing_type::mech_forcing_diags → mom_forcing_type::rotate_mech_forcing
- subroutine forcing_diagnostics(fluxes_in, sfc_state, G_in, US, time_end, diag, handles, enthalpy)
Offer buoyancy forcing fields for diagnostics for those fields registered as part of register_forcing_type_diags.
- Parameters
fluxes_in [in]
A structure containing thermodynamic forcing fields
sfc_state [in]
A structure containing fields that describe the surface state of the ocean.
G_in [in]
Input grid type
US [in]
A dimensional unit scaling type
time_end [in]
The end time of the diagnostic interval.
diag [inout]
diagnostic regulator
handles [inout]
diagnostic ids
enthalpy [in]
If present and true, the heat content associated with mass entering/leaving the ocean is provided by the coupler. Diagnostics net_heat_surface and heat_content_surfwater are computed using heat_content_evap instead of heat_content_massout.
Callees call graph
Text view
mom_forcing_type::forcing_diagnostics → mom_cpu_clock_infra::cpu_clock_begin
mom_forcing_type::forcing_diagnostics → mom_cpu_clock_infra::cpu_clock_end
mom_forcing_type::forcing_diagnostics → mom_diag_mediator::disable_averaging
mom_forcing_type::forcing_diagnostics → mom_diag_mediator::enable_averages
mom_forcing_type::forcing_diagnostics → mom_diag_mediator::interface::post_data
mom_forcing_type::forcing_diagnostics → mom_forcing_type::deallocate_forcing_type
mom_forcing_type::forcing_diagnostics → mom_forcing_type::interface::allocate_forcing_type
mom_forcing_type::forcing_diagnostics → mom_forcing_type::rotate_forcing
mom_forcing_type::forcing_diagnostics → mom_spatial_means::global_area_integral
mom_forcing_type::forcing_diagnostics → mom_spatial_means::global_area_mean
- subroutine allocate_forcing_by_group(G, fluxes, water, heat, ustar, press, shelf, iceberg, salt, fix_accum_bug, cfc, marbl, waves, shelf_sfc_accumulation, lamult, hevap, ice_ncat, tau_mag, carbon)
Conditionally allocate fields within the forcing type
- Parameters
G [in]
Ocean grid structure
fluxes [inout]
A structure containing thermodynamic forcing fields
water [in]
If present and true, allocate water fluxes
heat [in]
If present and true, allocate heat fluxes
ustar [in]
If present and true, allocate ustar and related fields
press [in]
If present and true, allocate p_surf and related fields
shelf [in]
If present and true, allocate fluxes for ice-shelf
iceberg [in]
If present and true, allocate fluxes for icebergs
salt [in]
If present and true, allocate salt fluxes
fix_accum_bug [in]
If present and true, avoid using a bug in accumulation of ustar_gustless
cfc [in]
If present and true, allocate fields needed for cfc surface fluxes
marbl [in]
If present and true, allocate fields needed for MARBL surface fluxes
waves [in]
If present and true, allocate wave fields
shelf_sfc_accumulation [in]
If present and true, and shelf is true, then allocate surface flux deposition from the atmosphere over ice shelves and ice sheets.
lamult [in]
If present and true, allocate langmuir enhancement factor
hevap [in]
If present and true, allocate heat content evap. This field must be allocated when enthalpy is provided via coupler.
ice_ncat [in]
number of ice categories
tau_mag [in]
If present and true, allocate tau_mag and related fields
carbon [in]
If present and true, allocate carbon fluxes
Callees call graph
- subroutine allocate_forcing_by_ref(fluxes_ref, G, fluxes, turns)
Allocate elements of a new forcing type based on their status in an existing type.
- Parameters
fluxes_ref [in]
Reference fluxes
G [in]
Grid metric of target fluxes
fluxes [out]
Target fluxes
turns [in]
If present, the number of counterclockwise quarter turns to use on the new grid.
Callees call graph
Text view
mom_forcing_type::allocate_forcing_by_ref → mom_coupler_types::interface::coupler_type_initialized
mom_forcing_type::allocate_forcing_by_ref → mom_coupler_types::interface::coupler_type_spawn
mom_forcing_type::allocate_forcing_by_ref → mom_forcing_type::get_forcing_groups
mom_forcing_type::allocate_forcing_by_ref → mom_forcing_type::interface::allocate_forcing_type
mom_forcing_type::allocate_forcing_by_ref → mom_forcing_type::interface::myalloc
- subroutine allocate_mech_forcing_by_group(G, forces, stress, ustar, shelf, press, iceberg, waves, num_stk_bands, tau_mag)
Conditionally allocate fields within the mechanical forcing type using control flags.
- Parameters
G [in]
Ocean grid structure
forces [inout]
Forcing fields structure
stress [in]
If present and true, allocate taux, tauy
ustar [in]
If present and true, allocate ustar and related fields
shelf [in]
If present and true, allocate forces for ice-shelf
press [in]
If present and true, allocate p_surf and related fields
iceberg [in]
If present and true, allocate forces for icebergs
waves [in]
If present and true, allocate wave fields
num_stk_bands [in]
Number of Stokes bands to allocate
tau_mag [in]
If present and true, allocate tau_mag
- subroutine allocate_mech_forcing_from_ref(forces_ref, G, forces)
Conditionally allocate fields within the mechanical forcing type based on a reference forcing.
- Parameters
forces_ref [in]
Reference forcing fields
G [in]
Grid metric of target forcing
forces [out]
Mechanical forcing fields
- subroutine get_forcing_groups(fluxes, water, heat, ustar, tau_mag, press, shelf, iceberg, salt, heat_added, buoy, carbon)
Return flags indicating which groups of forcings are allocated
- Parameters
fluxes [in]
Reference flux fields
water [out]
True if fluxes contains water-based fluxes
heat [out]
True if fluxes contains heat-based fluxes
ustar [out]
True if fluxes contains ustar
tau_mag [out]
True if fluxes contains tau_mag
press [out]
True if fluxes contains surface pressure
shelf [out]
True if fluxes contains ice shelf fields
iceberg [out]
True if fluxes contains iceberg fluxes
salt [out]
True if fluxes contains salt flux
heat_added [out]
True if fluxes contains explicit heat
buoy [out]
True if fluxes contains buoyancy fluxes
carbon [out]
True if fluxes contains carbon fluxes
- subroutine get_mech_forcing_groups(forces, stress, ustar, tau_mag, shelf, press, iceberg)
Return flags indicating which groups of mechanical forcings are allocated
- Parameters
forces [in]
Reference forcing fields
stress [out]
True if forces contains wind stress fields
ustar [out]
True if forces contains ustar field
tau_mag [out]
True if forces contains tau_mag field
shelf [out]
True if forces contains ice shelf fields
press [out]
True if forces contains pressure fields
iceberg [out]
True if forces contains iceberg fields
- subroutine myAlloc_2d(array, is, ie, js, je, flag)
Allocates and zeroes-out array.
- Parameters
array
Array to be allocated
is [in]
Start i-index
ie [in]
End i-index
js [in]
Start j-index
je [in]
End j-index
flag [in]
Flag to indicate to allocate
subroutine myAlloc_3d(array, is, ie, js, je, ks, ke, flag)
- Parameters
array
Array to be allocated
is [in]
Start i-index
ie [in]
End i-index
js [in]
Start j-index
je [in]
End j-index
ks [in]
Start k-index
ke [in]
End k-index
flag [in]
Flag to indicate to allocate
- subroutine deallocate_forcing_type(fluxes)
Deallocate the forcing type
- Parameters
fluxes [inout]
Forcing fields structure
Callees call graph
Callers call graph
Text view
mom_forcing_type::forcing_diagnostics → mom_forcing_type::deallocate_forcing_type
mom_ice_shelf::adjust_ice_sheet_frazil → mom_forcing_type::deallocate_forcing_type
mom_ice_shelf::initialize_ice_shelf_fluxes → mom_forcing_type::deallocate_forcing_type
mom_ice_shelf::shelf_calc_flux → mom_forcing_type::deallocate_forcing_type
mom_surface_forcing::surface_forcing_end → mom_forcing_type::deallocate_forcing_type
- subroutine deallocate_mech_forcing(forces)
Deallocate the mechanical forcing type
- Parameters
forces [inout]
Forcing fields structure
- subroutine rotate_forcing(fluxes_in, fluxes, turns)
Rotate the fluxes by a set number of quarter turns
- Parameters
fluxes_in [in]
Input forcing structure
fluxes [inout]
Rotated forcing structure
turns [in]
Number of quarter turns
Callees call graph
Text view
mom_forcing_type::rotate_forcing → mom_array_transform::interface::rotate_array
mom_forcing_type::rotate_forcing → mom_coupler_types::interface::coupler_type_copy_data
mom_forcing_type::rotate_forcing → mom_coupler_types::interface::coupler_type_initialized
mom_forcing_type::rotate_forcing → mom_forcing_type::get_forcing_groups
Callers call graph
Text view
- subroutine rotate_mech_forcing(forces_in, turns, forces)
Rotate the forcing fields from the input domain
- Parameters
forces_in [in]
Forcing on the input domain
turns [in]
Number of quarter-turns
forces [inout]
Forcing on the rotated domain
Callees call graph
Text view
mom_forcing_type::rotate_mech_forcing → mom_array_transform::interface::rotate_array
mom_forcing_type::rotate_mech_forcing → mom_array_transform::interface::rotate_array_pair
mom_forcing_type::rotate_mech_forcing → mom_array_transform::interface::rotate_vector
mom_forcing_type::rotate_mech_forcing → mom_forcing_type::get_mech_forcing_groups
Callers call graph
- subroutine homogenize_mech_forcing(forces, G, US, Rho0, UpdateUstar)
Homogenize the forcing fields from the input domain
- Parameters
forces [inout]
Forcing on the input domain
G [in]
Grid metric of target forcing
US [in]
A dimensional unit scaling type
Rho0 [in]
A reference density of seawater [R ~> kg m-3], as used to calculate ustar.
UpdateUstar [in]
A logical to determine if Ustar should be directly averaged or updated from mean tau.
Callees call graph
Text view
mom_forcing_type::homogenize_mech_forcing → mom_forcing_type::get_mech_forcing_groups
mom_forcing_type::homogenize_mech_forcing → mom_forcing_type::homogenize_field_t
mom_forcing_type::homogenize_mech_forcing → mom_forcing_type::homogenize_field_u
mom_forcing_type::homogenize_mech_forcing → mom_forcing_type::homogenize_field_v
mom_forcing_type::homogenize_mech_forcing → mom_spatial_means::global_area_mean_u
mom_forcing_type::homogenize_mech_forcing → mom_spatial_means::global_area_mean_v
- subroutine homogenize_forcing(fluxes, G, GV, US)
Homogenize the fluxes
- Parameters
fluxes [inout]
Input forcing struct
G [in]
Grid metric of target forcing
GV [in]
ocean vertical grid structure
US [in]
A dimensional unit scaling type
Callees call graph
subroutine homogenize_field_t(var, G, tmp_scale)
- Parameters
G [in]
The ocean's grid structure
var [inout]
The variable to homogenize [A ~> a]
tmp_scale [in]
A temporary rescaling factor for the variable that is reversed in the return value [a A-1 ~> 1]
Callees call graph
subroutine homogenize_field_v(var, G, tmp_scale)
- Parameters
G [in]
The ocean's grid structure
var [inout]
The variable to homogenize [A ~> a]
tmp_scale [in]
A temporary rescaling factor for the variable that is reversed in the return value [a A-1 ~> 1]
Callees call graph
Callers call graph
subroutine homogenize_field_u(var, G, tmp_scale)
- Parameters
G [in]
The ocean's grid structure
var [inout]
The variable to homogenize [A ~> a]
tmp_scale [in]
A temporary rescaling factor for the variable that is reversed in the return value [a A-1 ~> 1]