MOM_couplertype_infra module reference
This module wraps the FMS coupler types module
Generic Interfaces
This is the interface to spawn one coupler_bc_type into another. |
|
This function interface indicates whether a coupler_bc_type has been initialized. |
|
This is the interface to deallocate any data associated with a coupler_bc_type. |
|
Copy all elements of the data in either a coupler_2d_bc_type or a coupler_3d_bc_type into another structure of the same or the other type. Both must have the same array sizes in common dimensions, while the details of any expansion from 2d to 3d are controlled by arguments. |
|
Increment data in all elements of one coupler_2d_bc_type or coupler_3d_bc_type with the data from another. Both must have the same array sizes and rank. |
|
Rescales the fields in the elements of a coupler_2d_bc_type by multiplying by a factor scale. If scale is 0, this is a direct assignment to 0, so that NaNs will not persist. |
|
Redistribute the data in all elements of one coupler_2d_bc_type or coupler_3d_bc_type into another, which may be on different processors with a different decomposition. |
|
Write out checksums for the elements of a coupler_2d_bc_type or coupler_3d_bc_type |
Functions/Subroutines
This subroutine sets many of the parameters for calculating an atmosphere-ocean tracer flux and retuns an integer index for that flux. |
|
Generate a 2-D coupler type using a 1-D coupler type as a template. |
|
Generate a 3-D coupler type using a 1-D coupler type as a template. |
|
Generate one 2-D coupler type using another 2-D coupler type as a template. |
|
Generate a 3-D coupler type using a 2-D coupler type as a template. |
|
Generate a 2-D coupler type using a 3-D coupler type as a template. |
|
Generate a 3-D coupler type using another 3-D coupler type as a template. |
|
Copy all elements of the data in a coupler_2d_bc_type into another. Both must have the same array sizes. |
|
Copy all elements of the data in a coupler_3d_bc_type into another. Both must have the same array sizes. |
|
Copy all elements of the data in a coupler_2d_bc_type into a coupler_3d_bc_type. Both must have the same array sizes for the first two dimensions, while the extent of the 3rd dimension that is being filled may be specified via optional arguments. |
|
Increment data in all elements of one coupler_2d_bc_type with the data from another. Both must have the same array sizes. |
|
Increment data in all elements of one coupler_3d_bc_type with the data from another. Both must have the same array sizes. |
|
Rescales the fields in the elements of a coupler_2d_bc_type by multiplying by a factor scale. If scale is 0, this is a direct assignment to 0, so that NaNs will not persist. |
|
Rescales the fields in the elements of a coupler_3d_bc_type by multiplying by a factor scale. If scale is 0, this is a direct assignment to 0, so that NaNs will not persist. |
|
Increment data in the elements of a coupler_2d_bc_type with weighted averages of elements of a coupler_3d_bc_type |
|
Redistribute the data in all elements of one coupler_2d_bc_type into another, which may be on different processors with a different decomposition. |
|
Redistribute the data in all elements of one coupler_3d_bc_type into another, which may be on different processors with a different decomposition. |
|
Extract a 2d field from a coupler_2d_bc_type into a two-dimensional array. |
|
Set single 2d field in coupler_2d_bc_type from a two-dimensional array. |
|
Potentially override the values in a coupler_2d_bc_type |
|
Register the diagnostics of a coupler_2d_bc_type |
|
Write out all diagnostics of elements of a coupler_2d_bc_type |
|
Write out checksums for the elements of a coupler_2d_bc_type |
|
Write out checksums for the elements of a coupler_3d_bc_type |
|
Indicate whether a coupler_1d_bc_type has been initialized. |
|
Indicate whether a coupler_2d_bc_type has been initialized. |
|
Indicate whether a coupler_3d_bc_type has been initialized. |
|
Deallocate all data associated with a coupler_1d_bc_type |
|
Deallocate all data associated with a coupler_2d_bc_type |
Generic Interface Documentation
- interface CT_spawn
This is the interface to spawn one coupler_bc_type into another.
Callers call graph
Text view
mom_coupler_types::ct_spawn_1d_2d → mom_couplertype_infra::interface::ct_spawn
mom_coupler_types::ct_spawn_1d_3d → mom_couplertype_infra::interface::ct_spawn
mom_coupler_types::ct_spawn_2d_2d → mom_couplertype_infra::interface::ct_spawn
mom_coupler_types::ct_spawn_2d_3d → mom_couplertype_infra::interface::ct_spawn
mom_coupler_types::ct_spawn_3d_2d → mom_couplertype_infra::interface::ct_spawn
mom_coupler_types::ct_spawn_3d_3d → mom_couplertype_infra::interface::ct_spawn
- interface CT_initialized
This function interface indicates whether a coupler_bc_type has been initialized.
- interface CT_destructor
This is the interface to deallocate any data associated with a coupler_bc_type.
- interface CT_copy_data
Copy all elements of the data in either a coupler_2d_bc_type or a coupler_3d_bc_type into another structure of the same or the other type. Both must have the same array sizes in common dimensions, while the details of any expansion from 2d to 3d are controlled by arguments.
- interface CT_increment_data
Increment data in all elements of one coupler_2d_bc_type or coupler_3d_bc_type with the data from another. Both must have the same array sizes and rank.
Callers call graph
- interface CT_rescale_data
Rescales the fields in the elements of a coupler_2d_bc_type by multiplying by a factor scale. If scale is 0, this is a direct assignment to 0, so that NaNs will not persist.
- interface CT_redistribute_data
Redistribute the data in all elements of one coupler_2d_bc_type or coupler_3d_bc_type into another, which may be on different processors with a different decomposition.
- interface CT_write_chksums
Write out checksums for the elements of a coupler_2d_bc_type or coupler_3d_bc_type
Functions/Subroutine Documentation
- function atmos_ocn_coupler_flux(name, flux_type, implementation, param, mol_wt, ice_restart_file, ocean_restart_file, units, caller, verbosity) result(coupler_index)
This subroutine sets many of the parameters for calculating an atmosphere-ocean tracer flux and retuns an integer index for that flux.
- Parameters
name [in]
A name to use for the flux
flux_type [in]
A string describing the type of this flux, perhaps 'air_sea_gas_flux'.
implementation [in]
A name describing the specific implementation of this flux, such as 'ocmip2'.
param [in]
An array of parameters used for the fluxes
mol_wt [in]
The molecular weight of this tracer
ice_restart_file [in]
A sea-ice restart file to use with this flux.
ocean_restart_file [in]
An ocean restart file to use with this flux.
units [in]
The units of the flux
caller [in]
The name of the calling routine
verbosity [in]
A 0-9 integer indicating a level of verbosity.
coupler_index
The resulting integer handle to use for this flux in subsequent calls.
Callees call graph
Callers call graph
Text view
advection_test_tracer::register_advection_test_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
boundary_impulse_tracer::register_boundary_impulse_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
dome_tracer::register_dome_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
dyed_obc_tracer::register_dyed_obc_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
ideal_age_example::register_ideal_age_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
isomip_tracer::register_isomip_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
mom_ocmip2_cfc::flux_init_ocmip2_cfc → mom_couplertype_infra::atmos_ocn_coupler_flux
oil_tracer::register_oil_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
regional_dyes::register_dye_tracer → mom_couplertype_infra::atmos_ocn_coupler_flux
user_tracer_example::user_register_tracer_example → mom_couplertype_infra::atmos_ocn_coupler_flux
- subroutine CT_spawn_1d_2d(var_in, var, idim, jdim, suffix, as_needed)
Generate a 2-D coupler type using a 1-D coupler type as a template.
- Parameters
var_in [in]
structure from which to copy information
var [inout]
structure into which to copy information
idim [in]
The data and computational domain extents of the first dimension in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension in a non-decreasing list
suffix [in]
optional suffix to make the name identifier unique
as_needed [in]
Only do the spawn if the target type (var) is not set and the parent type (var_in) is set.
External calls
- coupler_types_mod
coupler_type_spawn (coupler_types_mod::coupler_type_spawn)
- subroutine CT_spawn_1d_3d(var_in, var, idim, jdim, kdim, suffix, as_needed)
Generate a 3-D coupler type using a 1-D coupler type as a template.
- Parameters
var_in [in]
structure from which to copy information
var [inout]
structure into which to copy information
idim [in]
The data and computational domain extents of the first dimension in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension in a non-decreasing list
kdim [in]
The array extents of the third dimension in a non-decreasing list
suffix [in]
optional suffix to make the name identifier unique
as_needed [in]
Only do the spawn if the target type (var) is not set and the parent type (var_in) is set.
External calls
- coupler_types_mod
coupler_type_spawn (coupler_types_mod::coupler_type_spawn)
- subroutine CT_spawn_2d_2d(var_in, var, idim, jdim, suffix, as_needed)
Generate one 2-D coupler type using another 2-D coupler type as a template.
- Parameters
var_in [in]
structure from which to copy information
var [inout]
structure into which to copy information
idim [in]
The data and computational domain extents of the first dimension in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension in a non-decreasing list
suffix [in]
optional suffix to make the name identifier unique
as_needed [in]
Only do the spawn if the target type (var) is not set and the parent type (var_in) is set.
External calls
- coupler_types_mod
coupler_type_spawn (coupler_types_mod::coupler_type_spawn)
- subroutine CT_spawn_2d_3d(var_in, var, idim, jdim, kdim, suffix, as_needed)
Generate a 3-D coupler type using a 2-D coupler type as a template.
- Parameters
var_in [in]
structure from which to copy information
var [inout]
structure into which to copy information
idim [in]
The data and computational domain extents of the first dimension in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension in a non-decreasing list
kdim [in]
The array extents of the third dimension in a non-decreasing list
suffix [in]
optional suffix to make the name identifier unique
as_needed [in]
Only do the spawn if the target type (var) is not set and the parent type (var_in) is set.
External calls
- coupler_types_mod
coupler_type_spawn (coupler_types_mod::coupler_type_spawn)
- subroutine CT_spawn_3d_2d(var_in, var, idim, jdim, suffix, as_needed)
Generate a 2-D coupler type using a 3-D coupler type as a template.
- Parameters
var_in [in]
structure from which to copy information
var [inout]
structure into which to copy information
idim [in]
The data and computational domain extents of the first dimension in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension in a non-decreasing list
suffix [in]
optional suffix to make the name identifier unique
as_needed [in]
Only do the spawn if the target type (var) is not set and the parent type (var_in) is set.
External calls
- coupler_types_mod
coupler_type_spawn (coupler_types_mod::coupler_type_spawn)
- subroutine CT_spawn_3d_3d(var_in, var, idim, jdim, kdim, suffix, as_needed)
Generate a 3-D coupler type using another 3-D coupler type as a template.
- Parameters
var_in [in]
structure from which to copy information
var [inout]
structure into which to copy information
idim [in]
The data and computational domain extents of the first dimension in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension in a non-decreasing list
kdim [in]
The array extents of the third dimension in a non-decreasing list
suffix [in]
optional suffix to make the name identifier unique
as_needed [in]
Only do the spawn if the target type (var) is not set and the parent type (var_in) is set.
External calls
- coupler_types_mod
coupler_type_spawn (coupler_types_mod::coupler_type_spawn)
- subroutine CT_copy_data_2d(var_in, var, halo_size, bc_index, field_index, exclude_flux_type, only_flux_type, pass_through_ice)
Copy all elements of the data in a coupler_2d_bc_type into another. Both must have the same array sizes.
- Parameters
var_in [in]
BC_type structure with the data to copy
var [inout]
The recipient BC_type structure
halo_size [in]
The extent of the halo to copy; 0 by default
bc_index [in]
The index of the boundary condition that is being copied
field_index [in]
The index of the field in the boundary condition that is being copied
exclude_flux_type [in]
A string describing which types of fluxes to exclude from this copy.
only_flux_type [in]
A string describing which types of fluxes to include from this copy.
pass_through_ice [in]
If true, only copy BCs whose value of pass_through ice matches this
External calls
- coupler_types_mod
coupler_type_copy_data (coupler_types_mod::coupler_type_copy_data)
- subroutine CT_copy_data_3d(var_in, var, halo_size, bc_index, field_index, exclude_flux_type, only_flux_type, pass_through_ice)
Copy all elements of the data in a coupler_3d_bc_type into another. Both must have the same array sizes.
- Parameters
var_in [in]
BC_type structure with the data to copy
var [inout]
The recipient BC_type structure
halo_size [in]
The extent of the halo to copy; 0 by default
bc_index [in]
The index of the boundary condition that is being copied
field_index [in]
The index of the field in the boundary condition that is being copied
exclude_flux_type [in]
A string describing which types of fluxes to exclude from this copy.
only_flux_type [in]
A string describing which types of fluxes to include from this copy.
pass_through_ice [in]
If true, only copy BCs whose value of pass_through ice matches this
External calls
- coupler_types_mod
coupler_type_copy_data (coupler_types_mod::coupler_type_copy_data)
- subroutine CT_copy_data_2d_3d(var_in, var, halo_size, bc_index, field_index, exclude_flux_type, only_flux_type, pass_through_ice, ind3_start, ind3_end)
Copy all elements of the data in a coupler_2d_bc_type into a coupler_3d_bc_type. Both must have the same array sizes for the first two dimensions, while the extent of the 3rd dimension that is being filled may be specified via optional arguments.
- Parameters
var_in [in]
BC_type structure with the data to copy
var [inout]
The recipient BC_type structure
halo_size [in]
The extent of the halo to copy; 0 by default
bc_index [in]
The index of the boundary condition that is being copied
field_index [in]
The index of the field in the boundary condition that is being copied
exclude_flux_type [in]
A string describing which types of fluxes to exclude from this copy.
only_flux_type [in]
A string describing which types of fluxes to include from this copy.
pass_through_ice [in]
If true, only copy BCs whose value of pass_through ice matches this
ind3_start [in]
The starting value of the 3rd index of the 3d type to fill in.
ind3_end [in]
The ending value of the 3rd index of the 3d type to fill in.
External calls
- coupler_types_mod
coupler_type_copy_data (coupler_types_mod::coupler_type_copy_data)
- subroutine CT_increment_data_2d(var_in, var, halo_size, scale_factor, scale_prev)
Increment data in all elements of one coupler_2d_bc_type with the data from another. Both must have the same array sizes.
- Parameters
var_in [in]
coupler_type structure with the data to add to the other type
var [inout]
The coupler_type structure whose fields are being incremented
halo_size [in]
The extent of the halo to increment; 0 by default
scale_factor [in]
A scaling factor for the data that is being added
scale_prev [in]
A scaling factor for the data that is already here
External calls
- coupler_types_mod
coupler_type_increment_data (coupler_types_mod::coupler_type_increment_data)
- subroutine CT_increment_data_3d(var_in, var, halo_size, scale_factor, scale_prev, exclude_flux_type, only_flux_type)
Increment data in all elements of one coupler_3d_bc_type with the data from another. Both must have the same array sizes.
- Parameters
var_in [in]
coupler_type structure with the data to add to the other type
var [inout]
The coupler_type structure whose fields are being incremented
halo_size [in]
The extent of the halo to increment; 0 by default
scale_factor [in]
A scaling factor for the data that is being added
scale_prev [in]
A scaling factor for the data that is already here
exclude_flux_type [in]
A string describing which types of fluxes to exclude from this increment.
only_flux_type [in]
A string describing which types of fluxes to include from this increment.
External calls
- coupler_types_mod
coupler_type_increment_data (coupler_types_mod::coupler_type_increment_data)
- subroutine CT_rescale_data_2d(var, scale)
Rescales the fields in the elements of a coupler_2d_bc_type by multiplying by a factor scale. If scale is 0, this is a direct assignment to 0, so that NaNs will not persist.
- Parameters
var [inout]
The BC_type structure whose fields are being rescaled
scale [in]
A scaling factor to multiply fields by
External calls
- coupler_types_mod
coupler_type_rescale_data (coupler_types_mod::coupler_type_rescale_data)
- subroutine CT_rescale_data_3d(var, scale)
Rescales the fields in the elements of a coupler_3d_bc_type by multiplying by a factor scale. If scale is 0, this is a direct assignment to 0, so that NaNs will not persist.
- Parameters
var [inout]
The BC_type structure whose fields are being rescaled
scale [in]
A scaling factor to multiply fields by
External calls
- coupler_types_mod
coupler_type_rescale_data (coupler_types_mod::coupler_type_rescale_data)
- subroutine CT_increment_data_2d_3d(var_in, weights, var, halo_size)
Increment data in the elements of a coupler_2d_bc_type with weighted averages of elements of a coupler_3d_bc_type
- Parameters
var_in [in]
coupler_type structure with the data to add to the other type
weights [in]
An array of normalized weights for the 3d-data to increment the 2d-data. There is no renormalization, so if the weights do not sum to 1 in the 3rd dimension there may be adverse consequences!
var [inout]
The coupler_type structure whose fields are being incremented
halo_size [in]
The extent of the halo to increment; 0 by default
External calls
- coupler_types_mod
coupler_type_increment_data (coupler_types_mod::coupler_type_increment_data)
- subroutine CT_redistribute_data_2d(var_in, domain_in, var_out, domain_out, complete)
Redistribute the data in all elements of one coupler_2d_bc_type into another, which may be on different processors with a different decomposition.
- Parameters
var_in [in]
BC_type structure with the data to copy
domain_in [in]
The FMS domain for the input structure
var_out [inout]
The recipient BC_type structure (data intent out)
domain_out [in]
The FMS domain for the output structure
complete [in]
If true, complete the updates
External calls
- coupler_types_mod
coupler_type_redistribute_data (coupler_types_mod::coupler_type_redistribute_data)
- subroutine CT_redistribute_data_3d(var_in, domain_in, var_out, domain_out, complete)
Redistribute the data in all elements of one coupler_3d_bc_type into another, which may be on different processors with a different decomposition.
- Parameters
var_in [in]
BC_type structure with the data to copy
domain_in [in]
The FMS domain for the input structure
var_out [inout]
The recipient BC_type structure (data intent out)
domain_out [in]
The FMS domain for the output structure
complete [in]
If true, complete the updates
External calls
- coupler_types_mod
coupler_type_redistribute_data (coupler_types_mod::coupler_type_redistribute_data)
- subroutine CT_extract_data(var_in, bc_index, field_index, array_out, scale_factor, halo_size, idim, jdim)
Extract a 2d field from a coupler_2d_bc_type into a two-dimensional array.
- Parameters
var_in [in]
BC_type structure with the data to extract
bc_index [in]
The index of the boundary condition that is being copied
field_index [in]
The index of the field in the boundary condition that is being copied, or the surface flux by default.
array_out [out]
The recipient array for the field; its size must match the size of the data being copied unless idim and jdim are supplied.
scale_factor [in]
A scaling factor for the data that is being added
halo_size [in]
The extent of the halo to copy; 0 by default
idim [in]
The data and computational domain extents of the first dimension of the output array in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension of the output array in a non-decreasing list
Callers call graph
External calls
- coupler_types_mod
coupler_type_extract_data (coupler_types_mod::coupler_type_extract_data)
- subroutine CT_set_data(array_in, bc_index, field_index, var, scale_factor, halo_size, idim, jdim)
Set single 2d field in coupler_2d_bc_type from a two-dimensional array.
- Parameters
array_in [in]
The source array for the field; its size must match the size of the data being copied unless idim and jdim are supplied.
bc_index [in]
The index of the boundary condition that is being copied
field_index [in]
The index of the field in the boundary condition that is being set. The surface concentration is set by default.
var [inout]
BC_type structure with the data to set
scale_factor [in]
A scaling factor for the data that is being added
halo_size [in]
The extent of the halo to copy; 0 by default
idim [in]
The data and computational domain extents of the first dimension of the output array in a non-decreasing list
jdim [in]
The data and computational domain extents of the second dimension of the output array in a non-decreasing list
Callers call graph
External calls
- coupler_types_mod
coupler_type_set_data (coupler_types_mod::coupler_type_set_data)
- subroutine CT_data_override(gridname, var, time)
Potentially override the values in a coupler_2d_bc_type
- Parameters
gridname [in]
3-character long model grid ID
var [inout]
BC_type structure to override
time [in]
The current model time
Callers call graph
External calls
- coupler_types_mod
coupler_type_data_override (coupler_types_mod::coupler_type_data_override)
- subroutine CT_set_diags(var, diag_name, axes, time)
Register the diagnostics of a coupler_2d_bc_type
- Parameters
var [inout]
BC_type structure for which to register diagnostics
diag_name [in]
name for diagnostic file, or blank not to register the fields
axes [in]
array of axes identifiers for diagnostic variable registration
time [in]
model time variable for registering diagnostic field
Callers call graph
External calls
- coupler_types_mod
coupler_type_set_diags (coupler_types_mod::coupler_type_set_diags)
- subroutine CT_send_data(var, Time)
Write out all diagnostics of elements of a coupler_2d_bc_type
- Parameters
var [in]
BC_type structure with the diagnostics to write
time [in]
The current model time
Callers call graph
External calls
- coupler_types_mod
coupler_type_send_data (coupler_types_mod::coupler_type_send_data)
- subroutine CT_write_chksums_2d(var, outunit, name_lead)
Write out checksums for the elements of a coupler_2d_bc_type
- Parameters
var [in]
BC_type structure for which to register diagnostics
outunit [in]
The index of a open output file
name_lead [in]
An optional prefix for the variable names
External calls
- coupler_types_mod
coupler_type_write_chksums (coupler_types_mod::coupler_type_write_chksums)
- subroutine CT_write_chksums_3d(var, outunit, name_lead)
Write out checksums for the elements of a coupler_3d_bc_type
- Parameters
var [in]
BC_type structure for which to register diagnostics
outunit [in]
The index of a open output file
name_lead [in]
An optional prefix for the variable names
External calls
- coupler_types_mod
coupler_type_write_chksums (coupler_types_mod::coupler_type_write_chksums)
- logical function CT_initialized_1d(var)
Indicate whether a coupler_1d_bc_type has been initialized.
- Parameters
var [in]
BC_type structure to be deconstructed
External calls
- coupler_types_mod
coupler_type_initialized (coupler_types_mod::coupler_type_initialized)
- logical function CT_initialized_2d(var)
Indicate whether a coupler_2d_bc_type has been initialized.
- Parameters
var [in]
BC_type structure to be deconstructed
External calls
- coupler_types_mod
coupler_type_initialized (coupler_types_mod::coupler_type_initialized)
- logical function CT_initialized_3d(var)
Indicate whether a coupler_3d_bc_type has been initialized.
- Parameters
var [in]
BC_type structure to be deconstructed
External calls
- coupler_types_mod
coupler_type_initialized (coupler_types_mod::coupler_type_initialized)
- subroutine CT_destructor_1d(var)
Deallocate all data associated with a coupler_1d_bc_type
- Parameters
var [inout]
BC_type structure to be deconstructed
External calls
- coupler_types_mod
coupler_type_destructor (coupler_types_mod::coupler_type_destructor)
- subroutine CT_destructor_2d(var)
Deallocate all data associated with a coupler_2d_bc_type
- Parameters
var [inout]
BC_type structure to be deconstructed
External calls
- coupler_types_mod
coupler_type_destructor (coupler_types_mod::coupler_type_destructor)