io_decomp_land_to_x_y Function

public function io_decomp_land_to_x_y(land_x, land_y, mem_shape_spec, var_shape_spec, type) result(decomp)

Returns a parallel I/O decomposition mapping from a memory layout with a 'land' dimension to a netCDF variable layout with 'x' and 'y' dimensions, using the provided land_x and land_y arrays to determine the mapping from land indexes to x and y indexes.

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: land_x(:)

An array mapping land indexes to x (longitude) indexes.

integer, intent(in) :: land_y(:)

An array mapping land indexes to y (latitude) indexes.

type(dim_spec_t), intent(in) :: mem_shape_spec(:)

An array of dim_spec_t describing the shape and dimension names of the in-memory array. mem_shape_spec must include a dimension with name 'land' which is used to map to the x and y dimensions.

type(dim_spec_t), intent(in) :: var_shape_spec(:)

An array of dim_spec_t describing the shape and dimension names of the netCDF variable. var_shape_spec must include dimensions with names x and y which are used to map from the 'land' dimension described by mem_shape_spec.

integer, intent(in) :: type

The data type of the variable for which the decomposition is being created using CABLE_NETCDF_TYPE_* constants from cable_netcdf_mod.

Return Value class(cable_netcdf_decomp_t), allocatable