Each source code file contains a single module of the same name as the file (excluding the suffix .F), with the exception of the main driver file (ice.F). For example, the file ice_scaling.F contains the module ice_scaling. Within most modules are various data declarations and subroutines, along with protex commands for automatic documentation.
The modules can be organized as in Table 1 in the
approximate order of call in the driver file ice.F. The four modules at the
end of the table refer to optional and io routines.
|--ice_mpi_internal.F||Sets MPI tasks|
|--ice_timers.F||Timers for performance|
|--ice_model_size.F||Defines global domain, category, layer sizes|
|--ice_kinds_mod.F||Definitions of common data types|
|--ice_state.F||Defines ice state variables|
|--ice_domain.F||Local domain sizes; parallel info|
|---ice_constants.F||Sets physical constants|
|---ice_init.F||Parameter and variable initilizations|
|---ice_grid.F||Spatial grids, masks and boundary conditions|
|---ice_calendar.F||Calendar routines for managing time|
|---ice_flux.F||Assigns flux arrays: from, to coupler and internal|
|---ice_itd.F||Initilizes and redistributies ice in the itd|
|---ice_therm_driver.F||Driver for thermodynamics and itd|
|-----ice_atmo.F||Calculate atmosphere-ice stability based fluxes|
|-----ice_vthermo.F||Sets up vertical thermodynamics|
|-----ice_tstm.F||Energy conserving thermodynamics|
|-----ice_dh.F||Grow/melt snow/ice and adjust temperature profile|
|-----ice_itd_linear.F||Linear remapping scheme for itd|
|---ice_scaling.F||Scale fluxes to coupler|
|---ice_coupling.F||Message passing to and from coupler|
|---ice_history.F||Restart and history files|
|--ice_prnpnt.F||Print data for selected points|
|--ice_ocean.F||Slab ocean mixed layer|
This particular order of computations is necessary for coupled model accuracy as well as load balancing. For accuracy in radiant energy absorbed, the albedos used by the atmosphere in calculating the down shortwave should be the same as those used in the surface energy absorption in the sea ice thermodynamics. This requires that the snow/ice albedos be updated in the sea ice model after the thermodynamic calculation with the down shortwave is completed. For load balancing, the atmosphere and sea ice can run in parallel more efficiently if the atmosphere-ice surface exchange is separated from the rest of the sea ice thermodynamics. Hence, the sea ice model computes the atmosphere-ice fluxes as soon as it receives forcing data from the coupler, and returns the output fluxes to the coupler as soon as they are computed.
Because the sea ice model domain is limited globally, further improvements in load balancing arise from limiting the total amount of data exchanged between the sea ice model and the coupler (further explained in the Data Structure's section).
It should be noted that the coupler requires the fluxes to be in the form of per unit ice area (for it summation over ocean/land/ice fluxes in exchange with the atmosphere). Thus, the atmosphere-ice fluxes computed in the ice model (aggregated over thickness distribution) are further divided by the aggregate ice area (see module ice_scaling) before being sent to the coupler.