MOM_hor_index module reference

Defines the horizontal index type (hor_index_type) used for providing index ranges

Data Types

hor_index_type

Container for horizontal index ranges for data, computational and global domains

Generic Interfaces

assignment(=)

Copy the contents of one horizontal index type into another

Functions/Subroutines

hor_index_init

Sets various index values in a hor_index_type.

HIT_assign

HIT_assign copies one hor_index_type into another. It is accessed via an assignment (=) operator.

rotate_hor_index

Rotate the horizontal index ranges from the input to the output map.

Detailed Description

The hor_index_type provides the declarations and loop ranges for almost all data with horizontal extent.

Declarations and loop ranges should always be coded with the symmetric memory model in mind. The non-symmetric memory mode will then also work, albeit with a different (less efficient) communication pattern.

Using the hor_index_type HI:

  • declaration of h-point data is of the form h(HI%%isd:HI%%ied,HI%%jsd:HI%%jed)

  • declaration of q-point data is of the form q(HI%%IsdB:HI%%IedB,HI%%JsdB:HI%%JedB)

  • declaration of u-point data is of the form u(HI%%IsdB:HI%%IedB,HI%%jsd:HI%%jed)

  • declaration of v-point data is of the form v(HI%%isd:HI%%ied,HI%%JsdB:HI%%JedB).

For more detail explanation of horizontal indexing see Horizontal indexing and memory.

Type Documentation

type, public :: hor_index_type

Container for horizontal index ranges for data, computational and global domains

Parameters
  • isc

    The start i-index of cell centers within the computational domain

  • iec

    The end i-index of cell centers within the computational domain

  • jsc

    The start j-index of cell centers within the computational domain

  • jec

    The end j-index of cell centers within the computational domain

  • isd

    The start i-index of cell centers within the data domain

  • ied

    The end i-index of cell centers within the data domain

  • jsd

    The start j-index of cell centers within the data domain

  • jed

    The end j-index of cell centers within the data domain

  • isg

    The start i-index of cell centers within the global domain

  • ieg

    The end i-index of cell centers within the global domain

  • jsg

    The start j-index of cell centers within the global domain

  • jeg

    The end j-index of cell centers within the global domain

  • IscB

    The start i-index of cell vertices within the computational domain

  • IecB

    The end i-index of cell vertices within the computational domain

  • JscB

    The start j-index of cell vertices within the computational domain

  • JecB

    The end j-index of cell vertices within the computational domain

  • IsdB

    The start i-index of cell vertices within the data domain

  • IedB

    The end i-index of cell vertices within the data domain

  • JsdB

    The start j-index of cell vertices within the data domain

  • JedB

    The end j-index of cell vertices within the data domain

  • IsgB

    The start i-index of cell vertices within the global domain

  • IegB

    The end i-index of cell vertices within the global domain

  • JsgB

    The start j-index of cell vertices within the global domain

  • JegB

    The end j-index of cell vertices within the global domain

  • idg_offset

    The offset between the corresponding global and local i-indices.

  • jdg_offset

    The offset between the corresponding global and local j-indices.

  • symmetric

    True if symmetric memory is used.

  • niglobal

    The global number of h-cells in the i-direction

  • njglobal

    The global number of h-cells in the j-direction

  • turns

    Number of quarter-turn rotations from input to model

Generic Interface Documentation

interface assignment(=)

Copy the contents of one horizontal index type into another

Functions/Subroutine Documentation

subroutine hor_index_init(Domain, HI, param_file, local_indexing, index_offset)

Sets various index values in a hor_index_type.

Parameters
  • Domain [in]

    The MOM domain from which to extract information.

  • HI [inout]

    A horizontal index type to populate with data

  • param_file [in]

    Parameter file handle

  • local_indexing [in]

    If true, all tracer data domains start at 1

  • index_offset [in]

    A fixed additional offset to all indices

Callees call graph
Callees of mom_hor_index::hor_index_init calls cluster_mom_domain_infra MOM_domain_infra cluster_mom_file_parser MOM_file_parser cluster_mom_hor_index MOM_hor_index mom_domain_infra::get_global_shape get_global_shape mom_domain_infra::interface::get_domain_extent get_domain_extent (interface) mom_file_parser::interface::log_version log_version (interface) mom_hor_index::hor_index_init hor_index_init mom_hor_index::hor_index_init->mom_domain_infra::get_global_shape mom_hor_index::hor_index_init->mom_domain_infra::interface::get_domain_extent mom_hor_index::hor_index_init->mom_file_parser::interface::log_version
Text view
Callers call graph
Callers of mom_hor_index::hor_index_init calls cluster_mom MOM cluster_mom_grid MOM_grid cluster_mom_hor_index MOM_hor_index cluster_mom_io_file MOM_io_file cluster_mom_oda_driver_mod MOM_oda_driver_mod mom::initialize_mom initialize_MOM mom_hor_index::hor_index_init hor_index_init mom::initialize_mom->mom_hor_index::hor_index_init mom_grid::mom_grid_init MOM_grid_init mom_grid::mom_grid_init->mom_hor_index::hor_index_init mom_io_file::open_file_nc open_file_nc [private/internal] mom_io_file::open_file_nc->mom_hor_index::hor_index_init mom_oda_driver_mod::init_oda init_oda mom_oda_driver_mod::init_oda->mom_hor_index::hor_index_init
Text view
subroutine HIT_assign(HI1, HI2)

HIT_assign copies one hor_index_type into another. It is accessed via an assignment (=) operator.

Parameters
  • HI1 [out]

    Horizontal index type to copy to

  • HI2 [in]

    Horizontal index type to copy from

subroutine rotate_hor_index(HI_in, turns, HI)

Rotate the horizontal index ranges from the input to the output map.

Parameters
  • HI_in [in]

    Unrotated horizontal indices

  • turns [in]

    Number of quarter turns

  • HI [inout]

    Rotated horizontal indices

Callers call graph
Callers of mom_hor_index::rotate_hor_index calls cluster_mom MOM cluster_mom_checksums MOM_checksums cluster_mom_hor_index MOM_hor_index cluster_mom_ice_shelf MOM_ice_shelf mom::initialize_mom initialize_MOM mom_hor_index::rotate_hor_index rotate_hor_index mom::initialize_mom->mom_hor_index::rotate_hor_index mom_checksums::chksum_b_2d chksum_B_2d [private/internal] mom_checksums::chksum_b_2d->mom_hor_index::rotate_hor_index mom_checksums::chksum_b_3d chksum_B_3d [private/internal] mom_checksums::chksum_b_3d->mom_hor_index::rotate_hor_index mom_checksums::chksum_h_2d chksum_h_2d [private/internal] mom_checksums::chksum_h_2d->mom_hor_index::rotate_hor_index mom_checksums::chksum_h_3d chksum_h_3d [private/internal] mom_checksums::chksum_h_3d->mom_hor_index::rotate_hor_index mom_checksums::chksum_pair_b_2d chksum_pair_B_2d [private/internal] mom_checksums::chksum_pair_b_2d->mom_hor_index::rotate_hor_index mom_checksums::chksum_pair_b_3d chksum_pair_B_3d [private/internal] mom_checksums::chksum_pair_b_3d->mom_hor_index::rotate_hor_index mom_checksums::chksum_pair_h_2d chksum_pair_h_2d [private/internal] mom_checksums::chksum_pair_h_2d->mom_hor_index::rotate_hor_index mom_checksums::chksum_pair_h_3d chksum_pair_h_3d [private/internal] mom_checksums::chksum_pair_h_3d->mom_hor_index::rotate_hor_index mom_checksums::chksum_u_2d chksum_u_2d [private/internal] mom_checksums::chksum_u_2d->mom_hor_index::rotate_hor_index mom_checksums::chksum_u_3d chksum_u_3d [private/internal] mom_checksums::chksum_u_3d->mom_hor_index::rotate_hor_index mom_checksums::chksum_uv_2d chksum_uv_2d [private/internal] mom_checksums::chksum_uv_2d->mom_hor_index::rotate_hor_index mom_checksums::chksum_uv_3d chksum_uv_3d [private/internal] mom_checksums::chksum_uv_3d->mom_hor_index::rotate_hor_index mom_checksums::chksum_v_2d chksum_v_2d [private/internal] mom_checksums::chksum_v_2d->mom_hor_index::rotate_hor_index mom_checksums::chksum_v_3d chksum_v_3d [private/internal] mom_checksums::chksum_v_3d->mom_hor_index::rotate_hor_index mom_ice_shelf::initialize_ice_shelf initialize_ice_shelf mom_ice_shelf::initialize_ice_shelf->mom_hor_index::rotate_hor_index
Text view
API generated with Flint · Rendered from reStructuredText