[MITgcm-support] SEAICE pkg, unstable HEFF

Mari Fjalstad Jensen Mari.F.Jensen at uib.no
Wed Mar 30 05:51:51 EDT 2016


Hi Martin,
thanks for your reply and comments!

Attached are data* and *_OPTIONS files, let me know if you need more.

Regarding the freshwater, I add ~1.5e-06 of precipitation (the area was
53000km^2, sorry), still a lot though, but not supposed to be 
realistic.. With 1e-06 precipitation I don't
get the instability.

Mari

On 29.03.2016 18:00, mitgcm-support-request at mitgcm.org wrote:

> Message: 1
> Date: Tue, 29 Mar 2016 14:10:41 +0200
> From: Mari Fjalstad Jensen <Mari.F.Jensen at uib.no>
> To: mitgcm-support at mitgcm.org
> Subject: [MITgcm-support] SEAICE pkg, unstable HEFF
> Message-ID: <56FA70C1.6060302 at uib.no>
> Content-Type: text/plain; charset=utf-8; format=flowed
>
> Hi,
> I am having some problems with the seaice pkg.
> I am doing some simulations with a run for a 1000*2250 km domain, 5km
> horz resolution and 30 depth levels, SEAICE pkg on.
>
> Freshwater is added through EmP in a roughly 25000 km^2 area.
> The run crashes after about 10 years when adding 0.08 Sv of
> precipitation. The problem seems to be in two grid cells where the
> sea-ice thickness (HEFF) increases with 50 m in one time step (400s).
> The grid cells are located just at the edge of where I add freshwater. I
> do not have this problem when adding less or no freshwater.
>
> Any help with which SEAICE parameters to change would be highly appreciated.
>
> # SEAICE parameters
>    &SEAICE_PARM01
>         SEAICEwriteState   = .TRUE.,
>         SEAICEadvScheme    = 33,
>         SEAICE_initialHEFF = 0.0,
>         SEAICE_deltaTtherm = 400.,
>         SEAICE_deltaTdyn   = 400.,
>         SEAICE_deltaTevp   = 20.,
>         SEAICE_multDim     = 1,
>         ICE2WATR           = 0.92D0,
>    SEAICEadvSnow = .FALSE.,
>    SEAICEuseFlooding  = .FALSE.,
>
> ----------
> I have tried varying diffusion/viscosity parameters and domain where I
> add freshwater without success..
>
> Best Regards,
> Mari
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Tue, 29 Mar 2016 14:52:53 +0200
> From: Martin Losch <Martin.Losch at awi.de>
> To: MITgcm Support <mitgcm-support at mitgcm.org>
> Subject: Re: [MITgcm-support] SEAICE pkg, unstable HEFF
> Message-ID: <4FFA44FC-51F3-4D10-B2CA-2FF4C053B8F5 at awi.de>
> Content-Type: text/plain; charset="utf-8"
>
> Hi Mari,
>
> there are many things that can go wrong with such a configuration, so that the information that you provide is not quite sufficient. If you want more help, I?d ask you to send all namelist files (data*) and all *_OPTIONS.h files that you have modified (ie., the *_OPTIONS.h files in the ?code? directory), in particular the SEAICE_OPTIONS.h and CPP_OPTIONS.h file.
>
> based on what you sent I can say this:
>> On 29 Mar 2016, at 14:10, Mari Fjalstad Jensen <Mari.F.Jensen at uib.no> wrote:
>>
>> Hi,
>> I am having some problems with the seaice pkg.
>> I am doing some simulations with a run for a 1000*2250 km domain, 5km horz resolution and 30 depth levels, SEAICE pkg on.
>>
>> Freshwater is added through EmP in a roughly 25000 km^2 area.
>> The run crashes after about 10 years when adding 0.08 Sv of precipitation. The problem seems to be in two grid cells where the sea-ice thickness (HEFF) increases with 50 m in one time step (400s). The grid cells are located just at the edge of where I add freshwater. I do not have this problem when adding less or no freshwater.
> How do you add this? Isn?t 0.08 Sv *1e06 (m^3/Sv) / (25000e6m^2) = 3.2e-06 m/s of water a pretty high precipitation rate? How much less do you need to add to avoid the instability?
>>
>> Any help with which SEAICE parameters to change would be highly appreciated.
>>
>> # SEAICE parameters
>> &SEAICE_PARM01
>>       SEAICEwriteState   = .TRUE.,
>>       SEAICEadvScheme    = 33,
>>       SEAICE_initialHEFF = 0.0,
>>       SEAICE_deltaTtherm = 400.,
>>       SEAICE_deltaTdyn   = 400.,
>>       SEAICE_deltaTevp   = 20.,
> If you want to use EVP, I recommend using the new schemes of Madlen Kimmritz, which is implemented in the most recent MITgcm, see Kimmritz etal 2015. On the convergence of the modified elastic-viscous-plastic method of solving for sea-ice dynamics. Journal of Computational Physics, 296, 90-100, doi:10.1016/j.jcp.2015.04.051, 2015, and "The adaptive EVP method for solving the sea ice momentum equation?, just accepted in Ocean Modelling: <http://mitgcm.org/~mlosch/adaptiveEVP_accepted.pdf>
> Some if this is already in the online-documentation. I recommend using parameters SEAICE_evpAlpha=SEAICE_evpBeta=500 and SEAICEnEVPstarSteps = 200 or so. That may not lead to fully converged solutions but they will be more or less smooth.
> But I think your solution will be just as sane with the default VP parameters (i.e. just comment out deltaTevp), and much better (if smoothness and stability count) with order 10 non-linear iteration steps (NSPEUDOTIMESTEPS = 10 or if you have recent code SEAICEnonLinIterMax=10).
>>       SEAICE_multDim     = 1,
>>       ICE2WATR           = 0.92D0,
>> SEAICEadvSnow = .FALSE.,
>> SEAICEuseFlooding  = .FALSE.,
> These two parameters only make sense if there is no snow in the simulations.
>
>>
>> ----------
>> I have tried varying diffusion/viscosity parameters and domain where I add freshwater without success..
>
> Martin
>
>>
>> Best Regards,
>> Mari
>>
>>
>> _______________________________________________
>> MITgcm-support mailing list
>> MITgcm-support at mitgcm.org
>> http://mitgcm.org/mailman/listinfo/mitgcm-support
>
>
>
>
> ------------------------------
>
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-support
>
>
> End of MITgcm-support Digest, Vol 153, Issue 30
> ***********************************************
>




-------------- next part --------------
# $Header: /u/gcmpack/MITgcm/verification/lab_sea/input/data.exf,v 1.11 2007/04/18 19:57:21 heimbach Exp $
#
# *********************
# External Forcing Data
# *********************
 &EXF_NML_01
#
 useExfCheckRange  = .FALSE.,
 repeatPeriod      = 3.1104e+7,
 exf_iprec         = 64,
 exf_yftype        = 'RL',
#
 &

# *********************
 &EXF_NML_02
#
 hfluxstartdate1   = 19781216,
 hfluxstartdate2   = 180000,
 hfluxperiod       = 3.1104e+7,
#
 sfluxstartdate1   = 19781216,
 sfluxstartdate2   = 180000,
 sfluxperiod       = 3.1104e+7,
#
 ustressstartdate1 = 19781216,
 ustressstartdate2 = 180000,
 ustressperiod     = 3.1104e+7,
#
 vstressstartdate1 = 19781216,
 vstressstartdate2 = 180000,
 vstressperiod     = 3.1104e+7,
#
 atempstartdate1   = 19781216,
 atempstartdate2   = 180000,
 atempperiod       = 3.1104e+7,
#
 aqhstartdate1     = 19781216,
 aqhstartdate2     = 180000,
 aqhperiod         = 3.1104e+7,
#
 precipstartdate1  = 19781216,
 precipstartdate2  = 180000,
 precipperiod      = 3.1104e+7,
#
 uwindstartdate1   = 19781216,
 uwindstartdate2   = 180000,
 uwindperiod       = 3.1104e+7,
#
 vwindstartdate1   = 19781216,
 vwindstartdate2   = 180000,
 vwindperiod       = 3.1104e+7,
#
 swfluxstartdate1  = 19781216,
 swfluxstartdate2  = 180000,
 swfluxperiod      = 3.1104e+7,
#
 lwfluxstartdate1  = 19781216,
 lwfluxstartdate2  = 180000,
 lwfluxperiod      = 3.1104e+7,
#
 swdownstartdate1  = 19781216,
 swdownstartdate2  = 180000,
 swdownperiod      = 3.1104e+7,
#
 lwdownstartdate1  = 19781216,
 lwdownstartdate2  = 180000,
 lwdownperiod      = 3.1104e+7,
#
 climsststartdate1  = 19781216,
 climsststartdate2  = 180000,
 climsstperiod      = 3.1104e+7,
#
 climsssstartdate1  = 19781216,
 climsssstartdate2  = 180000,
 climsssperiod      = 3.1104e+7,
#
 hfluxfile         = ' ',
 sfluxfile         = ' ',
 ustressfile       = ' ',
 vstressfile       = ' ',
 atempfile         = 'Tair.bin',
 aqhfile           = ' ',
 uwindfile         = 'Uwind.bin',
 vwindfile         = 'Vwind.bin',
 precipfile        = 'EmP.bin',
 lwfluxfile        = ' ',
 swfluxfile        = ' ',
 lwdownfile        = ' ',
 swdownfile        = ' ',
 runoffFile        = ' '
 climsstfile       = ' ',
 climsssfile       = ' ',
#
 &

# *********************
 &EXF_NML_03
 &

# *********************
 &EXF_NML_04
 &

-------------- next part --------------
C $Header: /u/gcmpack/MITgcm/pkg/seaice/SEAICE_OPTIONS.h,v 1.73 2013/03/07 08:32:48 mlosch Exp $
C $Name: checkpoint64y $

C     *==========================================================*
C     | SEAICE_OPTIONS.h
C     | o CPP options file for sea ice package.
C     *==========================================================*
C     | Use this file for selecting options within the sea ice
C     | package.
C     *==========================================================*

#ifndef SEAICE_OPTIONS_H
#define SEAICE_OPTIONS_H
#include "PACKAGES_CONFIG.h"
#include "CPP_OPTIONS.h"

#ifdef ALLOW_SEAICE
C     Package-specific Options & Macros go here

C--   Write "text-plots" of certain fields in STDOUT for debugging.
#define SEAICE_DEBUG

C--   Allow sea-ice dynamic code.
C     This option is provided to allow use of TAMC
C     on the thermodynamics component of the code only.
C     Sea-ice dynamics can also be turned off at runtime
C     using variable SEAICEuseDYNAMICS.
#define SEAICE_ALLOW_DYNAMICS

C--   By default, the sea-ice package uses its own integrated bulk
C     formulae to compute fluxes (fu, fv, EmPmR, Qnet, and Qsw) over
C     open-ocean.  When this flag is set, these variables are computed
C     in a separate external package, for example, pkg/exf, and then
C     modified for sea-ice effects by pkg/seaice.
#define SEAICE_EXTERNAL_FLUXES

C--   This CPP flag has been retired.  The number of ice categories
C     used to solve for seaice flux is now specified by run-time
C     parameter SEAICE_multDim.
C     Note: be aware of pickup_seaice.* compatibility issues when
C     restarting a simulation with a different number of categories.
c#define SEAICE_MULTICATEGORY

C--   run with sea Ice Thickness Distribution (ITD);
C     set number of categories (nITD) in SEAICE_SIZE.h
#undef SEAICE_ITD

C--   Since the missing sublimation term is now included
C     this flag is needed for backward compatibility
#undef SEAICE_DISABLE_SUBLIM

C--   Suspected missing term in coupled ocn-ice heat budget (to be confirmed)
#undef SEAICE_DISABLE_HEATCONSFIX

C--   Default is constant seaice salinity (SEAICE_salt0); Define the following
C     flag to consider (space & time) variable salinity: advected and forming
C     seaice with a fraction (=SEAICE_saltFrac) of freezing seawater salinity.
C- Note: SItracer also offers an alternative way to handle variable salinity.
#undef SEAICE_VARIABLE_SALINITY

C--   Tracers of ice and/or ice cover.
#undef ALLOW_SITRACER
#ifdef ALLOW_SITRACER
C--   To try avoid 'spontaneous generation' of tracer maxima by advdiff.
# define ALLOW_SITRACER_ADVCAP
#endif

C--   By default the seaice model is discretized on a B-Grid (for
C     historical reasons). Define the following flag to use a new
C     (not thoroughly) test version on a C-grid
#define SEAICE_CGRID

C--   Only for the C-grid version it is possible to
#ifdef SEAICE_CGRID
C     enable JFNK code by defining the following flag
# define SEAICE_ALLOW_JFNK
C     enable LSR to use global (multi-tile) tri-diagonal solver
# undef SEAICE_GLOBAL_3DIAG_SOLVER
C     enable EVP code by defining the following flag
# define SEAICE_ALLOW_EVP
# ifdef SEAICE_ALLOW_EVP
C--   When set use SEAICE_zetaMin and SEAICE_evpDampC to limit viscosities
C     from below and above in seaice_evp: not necessary, and not recommended
#  undef SEAICE_ALLOW_CLIPZETA
# endif /* SEAICE_ALLOW_EVP */
C     regularize zeta to zmax with a smooth tanh-function instead
C     of a min(zeta,zmax). This improves convergence of iterative
C     solvers (Lemieux and Tremblay 2009, JGR). No effect on EVP
# undef SEAICE_ZETA_SMOOTHREG
C     allow the truncated ellipse rheology (runtime flag SEAICEuseTEM)
# undef SEAICE_ALLOW_TEM
C     Use LSR vector code; not useful on non-vector machines, because it
C     slows down convergence considerably, but the extra iterations are
C     more than made up by the much faster code on vector machines. For
C     the only regularly test vector machine these flags a specified
C     in the build options file SUPER-UX_SX-8_sxf90_awi, so that we comment
C     them out here.
C# define SEAICE_VECTORIZE_LSR
C# ifdef SEAICE_VECTORIZE_LSR
C     Use modified LSR vector code that splits vector loop into two with
C     step size 2. This modification improves the convergence of the vector
C     code dramatically, so that is may actually be useful in general, but
C     that needs to be tested.
C#  define SEAICE_VECTORIZE_LSR_ZEBRA
C# endif
#else /* not SEAICE_CGRID, but old B-grid */
C--   By default for B-grid dynamics solver wind stress under sea-ice is
C     set to the same value as it would be if there was no sea-ice.
C     Define following CPP flag for B-grid ice-ocean stress coupling.
# define SEAICE_BICE_STRESS

C--   By default for B-grid dynamics solver surface tilt is obtained
C     indirectly via geostrophic velocities. Define following CPP
C     in order to use ETAN instead.
# define EXPLICIT_SSH_SLOPE
C--   Defining this flag turns on FV-discretization of the B-grid LSOR solver.
C     It is smoother and includes all metric terms, similar to C-grid solvers.
C     It is here for completeness, but its usefulness is unclear.
# undef SEAICE_LSRBNEW
#endif /* SEAICE_CGRID */

C--   When set limit the Ice-Loading to mass of 1/5 of Surface ocean grid-box
#undef SEAICE_CAP_ICELOAD
C--   When set use SEAICE_clipVelocties = .true., to clip U/VICE at 40cm/s,
C     not recommended
#undef SEAICE_ALLOW_CLIPVELS
C--   When set cap the sublimation latent heat flux in solve4temp according
C     to the available amount of ice+snow. Otherwise this term is treated
C     like all of the others -- residuals heat and fw stocks are passed to
C     the ocean at the end of seaice_growth in a conservative manner.
C     SEAICE_CAP_SUBLIM is not needed as of now, but kept just in case.
#undef SEAICE_CAP_SUBLIM

C--   Enable free drift code
#undef SEAICE_ALLOW_FREEDRIFT

#endif /* ALLOW_SEAICE */
#endif /* SEAICE_OPTIONS_H */

CEH3 ;;; Local Variables: ***
CEH3 ;;; mode:fortran ***
CEH3 ;;; End: ***

-------------- next part --------------
# Model parameters
# Continuous equation parameters
 &PARM01
 tRef=30*6.0,
 sRef=30*35.0,
 viscAz=1.E-5,
# viscAh=20.,
# viscA4=1.e+9,
 viscC2Smag=2.5,
 no_slip_sides=.TRUE.,
 no_slip_bottom=.TRUE.,
# diffK4T=1.e+9,
# diffKhT=30.,
 diffKzT=1.E-5,
# diffK4S=1.e+9,
# diffKhS=30.,
 diffKzS=1.E-5,
 f0=1.2e-4,
 beta=0.0E-11,
 tAlpha=0.2E-3,
 sBeta =0.8E-3,
 rigidLid=.FALSE.,
 implicitFreeSurface=.TRUE.,
 staggerTimeStep=.TRUE.,
 eosType='JMD95Z',
# momAdvection=.FALSE.,
 readBinaryPrec=64,
 hFacMin=0.1,
 bottomDragQuadratic=1.e-3,
 implicitDiffusion=.TRUE.,
 implicitViscosity=.TRUE.,
 tempAdvScheme=33,
 saltAdvScheme=33,
 useSingleCpuIO=.TRUE.,
# vectorInvariantMomentum=.TRUE.,
 ivdc_kappa=1000.0,
 &
# Elliptic solver parameters
 &PARM02
 cg2dMaxIters=1000,
 cg2dTargetResidual=1.E-11,
 &
# Time stepping parameters
 &PARM03
 tauCD=0.,
 nIter0=3448872,
 nTimeSteps=2332800,
# startTime=0.0,
 deltaT=400.0,
 abEps=0.1,
 pChkptFreq=0.0,
 chkptFreq=86400,
 dumpFreq=1,
 monitorFreq=1,
 cAdjFreq=0,
 forcing_In_AB=.FALSE.,
 tauThetaClimRelax=0.0,
 &
# Gridding parameters
 &PARM04
 usingCartesianGrid=.TRUE.,
 usingSphericalPolarGrid=.FALSE.,
 dXspacing=5.e+3,
 dYspacing=5.e+3,
 delZ=20*50,10*100,
 &
 &PARM05
 checkIniTemp=.false.,
 bathyFile='topog.bin',
 EmPmRfile='EmP.bin',

 &
 &PARM06
 trestore=2592000., xr0=0.e+3,xr1=1000.e+3,yr0=0.0,yr1=200.e+3,
 WpmsqC=40.0,
 &

-------------- next part --------------
# SEAICE parameters
 &SEAICE_PARM01
      SEAICEwriteState   = .TRUE.,
      SEAICEadvScheme    = 33,
      SEAICE_initialHEFF = 0.0,
      SEAICE_deltaTtherm = 400.,
      SEAICE_deltaTdyn   = 400.,
      SEAICE_deltaTevp   = 20.,
      SEAICE_multDim     = 1,
#      SEAICE_tempFrz0    = -1.96,
#      SEAICE_dTempFrz_dS - 0.0,
#     SEAICEuseDYNAMICS  =.FALSE.,
#     LSR_ERROR          = 1.E-12,
#     SEAICE_tave_mnc    = .FALSE.,
#     SEAICE_dump_mnc    = .FALSE.,
#     SEAICE_mon_mnc     = .FALSE.,
      ICE2WATR           = 0.92D0,
# for backward compatibility only, in realistic runs
# this should always be turned on
 SEAICEadvSnow = .FALSE.,
 SEAICEuseFlooding  = .FALSE.,
 &

-------------- next part --------------
# Packages
 &PACKAGES
 usePTRACERS=.FALSE.
 useEXF=.TRUE.
 useSEAICE=.TRUE.
 usediagnostics=.TRUE.
 useKPP=.FALSE.
 &

-------------- next part --------------
C $Header: /u/gcmpack/MITgcm/pkg/exf/EXF_OPTIONS.h,v 1.30 2014/05/02 22:14:52 jmc Exp $
C $Name: checkpoint64y $

CBOP
C !ROUTINE: EXF_OPTIONS.h
C !INTERFACE:
C #include "EXF_OPTIONS.h"

C !DESCRIPTION:
C *==================================================================*
C | CPP options file for EXternal Forcing (EXF) package:
C | Control which optional features to compile in this package code.
C *==================================================================*
CEOP

#ifndef EXF_OPTIONS_H
#define EXF_OPTIONS_H
#include "PACKAGES_CONFIG.h"
#include "CPP_OPTIONS.h"

#ifdef ALLOW_EXF
#ifdef ECCO_CPPOPTIONS_H

C-- When multi-package option-file ECCO_CPPOPTIONS.h is used (directly included
C    in CPP_OPTIONS.h), this option file is left empty since all options that
C   are specific to this package are assumed to be set in ECCO_CPPOPTIONS.h

#else /* ndef ECCO_CPPOPTIONS_H */

C-- Package-specific Options & Macros go here

C   pkg/exf CPP options:
C   --------------------
C
C   > ( EXF_VERBOSE ) < replaced with run-time, logical parameter "exf_verbose".
C
C   >>> ALLOW_ATM_WIND <<<
C       If defined, 10-m wind fields can be read-in from files.
C
C   >>> ALLOW_ATM_TEMP <<<
C       If defined, atmospheric temperature and specific
C       humidity fields can be read-in from files.
C
C   >>> ALLOW_DOWNWARD_RADIATION <<<
C       If defined, downward long-wave and short-wave radiation
C       can be read-in form files or computed from lwflux and swflux.
C
C   >>> ALLOW_ZENITHANGLE <<<
C       If defined, ocean albedo varies with the zenith angle, and
C       incoming fluxes at the top of the atmosphere are computed
C
C   >>> ALLOW_BULKFORMULAE <<<
C       Allows the use of bulk formulae in order to estimate
C       turbulent and radiative fluxes at the ocean surface.
C
C   >>> EXF_READ_EVAP <<<
C       If defined, evaporation fields are read-in, rather than
C       computed from atmospheric state.
C
C   >>> ALLOW_RUNOFF <<<
C       If defined, river and glacier runoff can be read-in from files.
C
C   >>> ALLOW_RUNOFTEMP <<<
C       If defined, river and glacier runoff temperature
C       can be read-in from files.
C
C   >>> ATMOSPHERIC_LOADING <<<
C       If defined, atmospheric pressure can be read-in from files.
C   WARNING: this flag is set (define/undef) in CPP_OPTIONS.h
C            and cannot be changed here (in EXF_OPTIONS)
C
C   >>> EXF_SEAICE_FRACTION <<<
C       If defined, seaice fraction can be read-in from files (areaMaskFile)
C
C   >>> ALLOW_CLIMSST_RELAXATION <<<
C       Allow the relaxation to a monthly climatology of sea surface
C       temperature, e.g. the Reynolds climatology.
C
C   >>> ALLOW_CLIMSSS_RELAXATION <<<
C       Allow the relaxation to a monthly climatology of sea surface
C       salinity, e.g. the Levitus climatology.
C
C   >>> USE_EXF_INTERPOLATION <<<
C       Allows specification of arbitrary Cartesian input grids.
C
C   >>> EXF_CALC_ATMRHO
C       Calculate the local atm density as function of temp, humidity
C       and pressure
C
C   ====================================================================
C
C       The following CPP options:
C
C          ALLOW_ATM_WIND              (WIND)
C          ALLOW_ATM_TEMP              (TEMP)
C          ALLOW_DOWNWARD_RADIATION    (DOWN)
C          ALLOW_BULKFORMULAE          (BULK)
C          EXF_READ_EVAP               (EVAP)
C
C       permit the ocean-model forcing configurations listed in the
C       table below.  The first configuration is the default,
C       flux-forced, ocean model.  The next four are stand-alone
C       configurations that use pkg/exf, open-water bulk formulae to
C       compute the missing surface fluxes from atmospheric variables.
C       The last four configurations can be used in conjunction with
C       pkg/seaice to model ice-covered regions.  The forcing fields
C       in the rightmost column are defined in exf_fields.
C
C
C    WIND |TEMP |DOWN |BULK |EVAP |            actions
C    -----|-----|-----|-----|-----|-------------------------------------
C         |     |     |     |     |
C      -  |  -  |  -  |  -  |  -  | Read-in ustress, vstress, hflux,
C         |     |     |     |     | swflux, and sflux.
C         |     |     |     |     |
C     def | def | def | def |  -  | Read-in uwind, vwind, atemp, aqh,
C         |     |     |     |     | swdown, lwdown, precip, and runoff.
C         |     |     |     |     | Compute ustress, vstress, hflux,
C         |     |     |     |     | swflux, and sflux.
C         |     |     |     |     |
C     def | def |  -  | def |  -  | Read-in uwind, vwind, atemp, aqh,
C         |     |     |     |     | swflux, lwflux, precip, and runoff.
C         |     |     |     |     | Compute ustress, vstress, hflux,
C         |     |     |     |     | and sflux.
C         |     |     |     |     |
C     def |  -  |  -  | def |  -  | Read-in uwind, vwind, hflux,
C         |     |     |     |     | swflux, and sflux.
C         |     |     |     |     | Compute ustress and vstress.
C         |     |     |     |     |
C      -  | def |  -  | def |  -  | Read-in ustress, vstress, atemp,
C         |     |     |     |     | aqh, swflux, lwflux, precip, and
C         |     |     |     |     | runoff.  Compute hflux and sflux.
C         |     |     |     |     |
C     def | def |  -  |  -  | def | Read-in uwind, vwind, atemp, aqh,
C         |     |     |     |     | swflux, lwflux, precip, runoff,
C         |     |     |     |     | and evap.
C         |     |     |     |     |
C     def | def |  -  | def |  -  | Read-in uwind, vwind, atemp, aqh,
C         |     |     |     |     | swflux, lwflux, precip, and runoff.
C         |     |     |     |     | Compute open-water ustress, vstress,
C         |     |     |     |     | hflux, swflux, and evap.
C         |     |     |     |     |
C     def | def | def |  -  | def | Read-in uwind, vwind, atemp, aqh,
C         |     |     |     |     | swdown, lwdown, precip, runoff,
C         |     |     |     |     | and evap.
C         |     |     |     |     |
C     def | def | def | def |  -  | Read-in uwind, vwind, atemp, aqh,
C         |     |     |     |     | swdown, lwdown, precip, and runoff.
C         |     |     |     |     | Compute open-water ustress, vstress,
C         |     |     |     |     | hflux, swflux, and evap.
C
C   ====================================================================

C   Bulk formulae related flags.
#define  ALLOW_ATM_TEMP
#define  ALLOW_ATM_WIND
#define  ALLOW_DOWNWARD_RADIATION
#define  ALLOW_RUNOFF
#undef   ALLOW_RUNOFTEMP
#if (defined (ALLOW_ATM_TEMP) || defined (ALLOW_ATM_WIND))
# define ALLOW_BULKFORMULAE
# undef  ALLOW_BULK_LARGEYEAGER04
#endif
#if (defined (ALLOW_ATM_TEMP) && defined (ATMOSPHERIC_LOADING))
# undef  EXF_CALC_ATMRHO
#endif

C   Zenith Angle/Albedo related flags.
#ifdef ALLOW_DOWNWARD_RADIATION
# undef ALLOW_ZENITHANGLE
#endif

C   Use ocean_emissivity*lwdown in lwFlux. This flag should be defined
C   unless to reproduce old results (obtained with inconsistent old code)
#ifdef ALLOW_DOWNWARD_RADIATION
# define EXF_LWDOWN_WITH_EMISSIVITY
#endif

C   Relaxation to monthly climatologies.
#define ALLOW_CLIMSST_RELAXATION
#define ALLOW_CLIMSSS_RELAXATION

C   Allows to read-in seaice fraction from files (areaMaskFile)
#undef EXF_SEAICE_FRACTION

C   Use spatial interpolation to interpolate
C   forcing files from input grid to model grid.
#undef USE_EXF_INTERPOLATION
C   for interpolated vector fields, rotate towards model-grid axis
C   using old rotation formulae (instead of grid-angles)
#undef EXF_USE_OLD_VEC_ROTATION
C   for interpolation around N & S pole, use the old formulation
C   (no pole symmetry, single vector-comp interp, reset to 0 zonal-comp @ N.pole)
#undef EXF_USE_OLD_INTERP_POLE

#define EXF_INTERP_USE_DYNALLOC
#if ( defined (EXF_INTERP_USE_DYNALLOC) && defined (USING_THREADS) )
# define EXF_IREAD_USE_GLOBAL_POINTER
#endif

#endif /* ndef ECCO_CPPOPTIONS_H */
#endif /* ALLOW_EXF */
#endif /* EXF_OPTIONS_H */

-------------- next part --------------
C $Header: /u/gcmpack/MITgcm/model/inc/CPP_OPTIONS.h,v 1.51 2012/11/09 22:29:32 jmc Exp $
C $Name: checkpoint64y $

#ifndef CPP_OPTIONS_H
#define CPP_OPTIONS_H

CBOP
C !ROUTINE: CPP_OPTIONS.h
C !INTERFACE:
C #include "CPP_OPTIONS.h"

C !DESCRIPTION:
C *==================================================================*
C | main CPP options file for the model:
C | Control which optional features to compile in model/src code.
C *==================================================================*
CEOP

C CPP flags controlling particular source code features

C o Shortwave heating as extra term in external_forcing.F
C Note: this should be a run-time option
#define SHORTWAVE_HEATING

C o Include/exclude phi_hyd calculation code
#define INCLUDE_PHIHYD_CALCULATION_CODE

C o Include/exclude call to S/R CONVECT
#define INCLUDE_CONVECT_CALL

C o Include/exclude call to S/R CALC_DIFFUSIVITY
#define INCLUDE_CALC_DIFFUSIVITY_CALL

C o Allow full 3D specification of vertical diffusivity
#undef ALLOW_3D_DIFFKR

C o Allow latitudinally varying BryanLewis79 vertical diffusivity
#undef ALLOW_BL79_LAT_VARY

C o Include/exclude Implicit vertical advection code
#define INCLUDE_IMPLVERTADV_CODE

C o Include/exclude AdamsBashforth-3rd-Order code
#undef ALLOW_ADAMSBASHFORTH_3

C o Include/exclude nonHydrostatic code
#undef ALLOW_NONHYDROSTATIC

C o Allow to account for heating due to friction (and momentum dissipation)
#undef ALLOW_FRICTION_HEATING

C o Allow mass source or sink of Fluid in the interior
C   (3-D generalisation of oceanic real-fresh water flux)
#undef ALLOW_ADDFLUID

C o Include pressure loading code
#undef ATMOSPHERIC_LOADING

C o exclude/allow external forcing-fields load
C   this allows to read & do simple linear time interpolation of oceanic
C   forcing fields, if no specific pkg (e.g., EXF) is used to compute them.
#undef EXCLUDE_FFIELDS_LOAD

C o Include/exclude balancing surface forcing fluxes code
#undef ALLOW_BALANCE_FLUXES

C o Include/exclude balancing surface forcing relaxation code
#undef ALLOW_BALANCE_RELAX

C o Include/exclude GM-like eddy stress in momentum code
#undef ALLOW_EDDYPSI

C o Use "Exact Convervation" of fluid in Free-Surface formulation
C   so that d/dt(eta) is exactly equal to - Div.Transport
#define EXACT_CONSERV

C o Allow the use of Non-Linear Free-Surface formulation
C   this implies that surface thickness (hFactors) vary with time
#define NONLIN_FRSURF

C o Include/exclude code for single reduction Conjugate-Gradient solver
#define ALLOW_SRCG

C o Choices for implicit solver routines solve_*diagonal.F
C   The following has low memory footprint, but not suitable for AD
#undef SOLVE_DIAGONAL_LOWMEMORY
C   The following one suitable for AD but does not vectorize
#undef SOLVE_DIAGONAL_KINNER

C o ALLOW isotropic scaling of harmonic and bi-harmonic terms when
C   using an locally isotropic spherical grid with (dlambda) x (dphi*cos(phi))
C *only for use on a lat-lon grid*
C   Setting this flag here affects both momentum and tracer equation unless
C   it is set/unset again in other header fields (e.g., GAD_OPTIONS.h).
C   The definition of the flag is commented to avoid interference with
C   such other header files.
C   The preferred method is specifying a value for viscAhGrid or viscA4Grid
C   in data which is then automatically scaled by the grid size;
C   the old method of specifying viscAh/viscA4 and this flag is provided
C   for completeness only (and for use with the adjoint).
C#undef ISOTROPIC_COS_SCALING

C o This flag selects the form of COSINE(lat) scaling of bi-harmonic term.
C *only for use on a lat-lon grid*
C   Has no effect if ISOTROPIC_COS_SCALING is undefined.
C   Has no effect on vector invariant momentum equations.
C   Setting this flag here affects both momentum and tracer equation unless
C   it is set/unset again in other header fields (e.g., GAD_OPTIONS.h).
C   The definition of the flag is commented to avoid interference with
C   such other header files.
C#define COSINEMETH_III

C o Use "OLD" UV discretisation near boundaries (*not* recommended)
C   Note - only works with  #undef NO_SLIP_LATERAL  in calc_mom_rhs.F
C          because the old code did not have no-slip BCs
#undef  OLD_ADV_BCS

C o Use LONG.bin, LATG.bin, etc., initialization for ini_curviliear_grid.F
C   Default is to use "new" grid files (OLD_GRID_IO undef) but OLD_GRID_IO
C   is still useful with, e.g., single-domain curvilinear configurations.
#undef OLD_GRID_IO

C o Execution environment support options
#include "CPP_EEOPTIONS.h"

C o Include/exclude single header file containing multiple packages options
C   (AUTODIFF, COST, CTRL, ECCO, EXF ...) instead of the standard way where
C   each of the above pkg get its own options from its specific option file.
C   Although this method, inherited from ECCO setup, has been traditionally
C   used for all adjoint built, work is in progress to allow to use the
C   standard method also for adjoint built.
c#ifdef PACKAGES_CONFIG_H
c# include "ECCO_CPPOPTIONS.h"
c#endif

#endif /* CPP_OPTIONS_H */



More information about the MITgcm-support mailing list