USES:
use shr_kind_mod, only : r8 => shr_kind_r8 use spmdMod , only : masterproc, iam, npes, mpicom, comp_id use clm_varctl , only : iulog use clm_mct_mod use abortutils , only : endrunPUBLIC TYPES:
implicit none integer, public :: clump_pproc ! number of clumps per MPI processPUBLIC MEMBER FUNCTIONS:
public get_clump_bounds ! beg and end gridcell, landunit, column, ! pft indices for clump public get_proc_clumps ! number of clumps for this processor public get_proc_bounds_atm ! beg and end gridcell for atm public get_proc_bounds ! beg and end gridcell, landunit, column, ! pft indices for this processor public get_proc_total ! total number of gridcells, landunits, ! columns and pfts for any processor public get_proc_global ! total gridcells, landunits, columns, pfts ! across all processors public get_proc_global_atm ! total atm cells on all pes public get_clmlevel_gsize ! get global size associated with clmlevel public get_clmlevel_dsize ! get global size associated with clmlevel public get_clmlevel_gsmap ! get gsmap associated with clmlevelDESCRIPTION:
Module provides a descomposition into a clumped data structure which can be mapped back to atmosphere physics chunks.
REVISION HISTORY:
2002.09.11 Forrest Hoffman Creation. 2005.11.01 T Craig Rewrite 2006.06.06 T Craig Reduce memory, cleanupPRIVATE TYPES:
private ! (now mostly public for decompinitmod) integer,public :: nclumps ! total number of clumps across all processors integer,public :: numg ! total number of gridcells on all procs integer,public :: numl ! total number of landunits on all procs integer,public :: numc ! total number of columns on all procs integer,public :: nump ! total number of pfts on all procs integer,public :: numa ! total number of atm gridcells on all procs !---global information on each pe type processor_type integer :: nclumps ! number of clumps for processor_type iam integer,pointer :: cid(:) ! clump indices integer :: ncells ! number of gridcells in proc integer :: nlunits ! number of landunits in proc integer :: ncols ! number of columns in proc integer :: npfts ! number of pfts in proc integer :: begg, endg ! beginning and ending gridcell index integer :: begl, endl ! beginning and ending landunit index integer :: begc, endc ! beginning and ending column index integer :: begp, endp ! beginning and ending pft index integer :: abegg,aendg ! beginning and ending atm gridcell index end type processor_type public processor_type type(processor_type),public :: procinfo !---global information on each pe type clump_type integer :: owner ! process id owning clump integer :: ncells ! number of gridcells in clump integer :: nlunits ! number of landunits in clump integer :: ncols ! number of columns in clump integer :: npfts ! number of pfts in clump integer :: begg, endg ! beginning and ending gridcell index integer :: begl, endl ! beginning and ending landunit index integer :: begc, endc ! beginning and ending column index integer :: begp, endp ! beginning and ending pft index end type clump_type public clump_type type(clump_type),public, allocatable :: clumps(:) !---global information on each pe !--- i,j = 2d global !--- glo = 1d global sn ordered !--- gsn = 1d global sn ordered compressed !--- gdc = 1d global dc ordered compressed type decomp_type integer,pointer :: glo2gdc(:) ! 1d glo to 1d gdc integer,pointer :: gdc2glo(:) ! 1d gdc to 1d glo end type decomp_type public decomp_type type(decomp_type),public,target :: ldecomp type(decomp_type),public,target :: adecomp type(mct_gsMap) ,public,target :: gsMap_atm_gdc2glo type(mct_gsMap) ,public,target :: gsMap_lnd_gdc2glo type(mct_gsMap) ,public,target :: gsMap_gce_gdc2glo type(mct_gsMap) ,public,target :: gsMap_lun_gdc2glo type(mct_gsMap) ,public,target :: gsMap_col_gdc2glo type(mct_gsMap) ,public,target :: gsMap_pft_gdc2glo