    Notes on tags used in MITgcmUV
    ==============================

o testreport:
  - add process-id number to tar-file name when sending output with "scp".
o pkg/obcs(sponge):
  - fix bug in sponge relaxation time-scale for Salinity at the Southern OB;
  - remove special condition (non zero T / S) for temp and salt relaxation.
o pkg/layers:
  - fix bug in LAYERS_THERMODYNAMCS surface term code for LinFSConserveTr=F
o pkg/layers:
  - new header file "LAYERS_P2SHARE.h" with new parameter "layers_useThermo"
    allows calling S/R layers_fill only when it is necessary;
  - fix bug that leads to zero output for some of the LAYERS_THERMODYNAMCS
    diagnostics (LaTz, LaSz, LTto, LSto,LaTs,LaSs).

checkpoint69n (2026/05/08)
o pkg/seaice:
  - move seaice grid-variables from SEAICE.h into new header "SEAICE_GRID.h";
  - add missing metric terms to stress divergence (bug fix); new run-time parms
    SEAICEselectMetricTerms, default=2, =1 recover previous partial metric-terms
    (i.e., old results), tested in lab_sea.salt_plume ;
  - update all affected reference output (in cpl_aim+ocn, global_ocean.cs32x15,
    lab_sea & seaice_obcs, 19 total).
o pkg/mdsio:
  - when using pkg/cal, add date and time to ".meta" output file.
o pkg/shelfice:
  - use alternative way to compute freshWaterFlux based on heat balance ;
    keep old code under CPP option SHI_SALTBAL_FWFLX, and define this option
    in verification exp. shelfice_2d_remesh; update docs;
  - fix potential division by zero in saltFreeze & freshWaterFlux expressions;
  - fix bug related to SHELFICEadvDiffHeatFlux=T.
o pkg/obcs:
  - fix CPP logic in obcs_cost_driver.F to avoid compilation error.

checkpoint69m (2026/03/30)
o pkg/cost:
  - change ordering of calls in `cost_final.F`, profiles before ecco, as
    before PR 946 ; refine printing of cost per tile value to STDOUT.
  - drop condition on "useECCO" in shelfice_cost_final.F ; fix few missing
    or inconsistent CPP #ifdef.
o verification/global_ocean.cs32x15 & offline_exf_seaice:
  - in exp. "global_ocean.cs32x15", turn off useCAL in remaining FWD and AD
    tests and skip compilation of pkg/cal in FWD built. Also shift "nIter0"
    + rename pickup files in few secondary tests.
  - similarly, in exp. offline_exf_seaice, turn off and skip compilation of
    of pkg/cal in AD tests.
  - fix missing useCAL in 2 pkg/ctrl src files.
o pkg/cost,ctrl,ecco,obcs:
  - final cost-function always computed in "cost_final.F" (even if useECCO=T),
    calling individual {PKG}_COST_FINAL, each writing its own "costfunction_*"
    summary file. Similar changes in new "cost_driver.F", calling individual
    pkg "{pkg}_cost_driver.F";
  - make ctrl-cost (and obcs-ctrl-cost) available without pkg/ecco ; move all
    obcs-cost S/R from pkg/ecco to pkg/obcs ; and move+rename "data_errfile"
    (formerly in data.ecco) to "obcs_data_errfile" in "data.ctrl";
  - retire ALLOW_COST_DEPTH (covered by generic controls);
  - no changes to results ; adjust few namelists for special cases (obcs_ctrl,
    bottom_ctrl_5x5);
  - adjust store directives for combinations of pkgs kpp, seaice, shelfice
    with ALLOW_DEPTH_CONTROL.

checkpoint69l (2026/03/01)
o verification:
  - for secondary tests, change testreport to only run a single "prepare_run"
    from run-dir, after linking files from both ../input.${sfx}/ and ../input/.
  - adjust several verification exp. secondary tests accordingly and update
    instructions in README files + in the docs.
o pkg/streamice:
  - fix typo and S/R argument list within #ifdef ALLOW_PETSC adjoint code.
o tools:
  - fix PR 949 changes (location of "flow_tap") in Tapenade ad-optfile by
    using Makefile variable "TOOLSDIR".
o pkg/tapenade:
  - fix for Tang-Lin: add missing handwritten code for some pkg/streamice S/R
    and fix issues in ACTIVE_READ_XY/XYZ_D ;
  - turn back on Tapenade TLM test for experiment halfpipe_streamice.
o tapenade & genmake2:
  - in genmake2, import Tapenade command arguments from ad-optfile (adjoint_tap)
  - allow additional extra arguments with TAP_EXTRA, which can also be set using
    new command line option "-tap_extra" ;
  - add support for Tapenade to skip checkpointing with new "_FWD" and "_BWD"
    versions of manually written subroutine derivatives ;
  - test new "no-checkpointing" feature in halfpipe_streamice experiment
    with new reference output.
o pkg/gmredi:
  - remove OLD_VISBECK_CALC code ; rename S/R GMREDI_CALC_PSI_B ;
  - unless restricted to only uniform Kappa (including 2-D & 1-D scaling),
    define local 3-d vars for Kappa-Redi and Kappa-GM to simplify Tensor
    setting and Psi-Bolus code.

checkpoint69k (2026/01/25)
o model/src:
  - fix scaling from cg2g/cg3d TargetResWunit to CG-Tolerance (exact scaling
    if rAc is uniform) by using few more domain global quantities (in GRID.h).
  - adjust accordingly cg2g/cg3d TargetResWunit in all forward test exp. to keep
    identical results but switch off cg2dTargetResWunit in most AD exp. (except
    if using useNSACGSolver=T) to use cg2gTargetResidual (normalize cg2d RHS).
o verification:
  - after moving/merging (PR 944) fwd & adm tests from global_ocean_ebm into new
    host-exp global_oce_latlon, move former input dir and ref. output to replace
    sym-link in new host-exp and remove remaining files/dir in global_ocean_ebm.
o pkg/obsfit:
  - fix allocation of 2 local vars in obsfit_init_fixed.F
o pkg/profiles:
  - fix typo ; this allows to compile ALLOW_PROFILES_SAMPLESPLIT_COST code.
o pkg/gchem:
  - new routine gchem_insolation.F to replace pkg/bling & pkg/dic code,
    and now also usable on Curvilinear-Grid.
o tools/ci:
  - add two tapenade AD test experiments to GitHub action CI test.

checkpoint69j (2025/12/20)
o optim:
  - fix outdated ALLOW_SHIFWFLX_CONTROL option in "optim_read/writedata.F".
o pkg/obsfit:
  - new package "obsfit" for for model-observations comparisons (and cost
    contribution);
  - add secondary "obsfit" test in TAF-AD exp. global_oce_biogeo_bling.
o verification:
  - move "global_ocean_ebm" experiment forward tests to "global_oce_latlon" and
    adjust AD test for merging in global_oce_latlon, as a secondary "ebm" test.
  - disable test of global_ocean_ebm (to be removed later).
o pkg/seaice:
  - fix compilation of untested SEAICE_MODIFY_GROWTH_ADJ code.
o model/src:
  - add a STOP if using selectPenetratingSW > 0 in Atmospheric set-up.
o pkg/streamice & Tapenade:
  - introduce fixed-point treatment of Goldberg et al 2016 (GMD) for streamice
    nonlinear solver using Tapenade FP-LOOP pragma ; used in halfpipe_streamice
    exp. (with #define ALLOW_STREAMICE_FP_ADJ) ;
  - rename: streamice_vel_solve_openad.F --> streamice_vel_solve_fp.F
    + CPP option  ALLOW_STREAMICE_OAD_FP --> ALLOW_STREAMICE_FP_ADJ
  - skip differentiation of streamice_cg_solve.F with Tapenade, calling instead
    adstreamice_cg_solve (update "flow_tap" and stubs_tap_adj.F, add
    adFixedPoint.c in  ADFirstAidKit/ + links in pkg/tapenade);
  - for now, disable halfpipe_streamice exp. Tapenade Tang.-Lin test.
o pkg/grdchk:
  - fix grdchk location to allow to span several vertical level k ; test this
    in secondary test exp. "global_ocean.90x40x15.kapredi".
o pkg/mnc:
  - update grid-variable names in pkg/mnc NetCDF files (mostly matching GRID.h)
    and provide backwards compatibility in MATLab "load_grid.m" and for Python
    MITgcmutils (restore_MNC_keys).
o pkg/seaice:
  - new parameter "SEAICE_evpAreaReg" for regularizations of denomU/V in EVP
    solver ; tested in exp. seaice_obcs new secondary test "regDenom".

checkpoint69i (2025/11/14)
o pkg/cost:
  - fix multi-proc initialization of Tapenade adjoint cost-function.
o pkg & model:
  - remove pkg/timeave ; remove all ALLOW_TIMEAVE code ; remove all timeave
    related parameters from common blocks (in header files) and from src code
    and disable/retire these params.
  - also updates model_ad.flow, TAP_support/flow_tap, OAD_support and most
    */code_oad/cb2mFiles from verification.
o tools (Tapenade):
  - implement "-ncad" genmake2 option for Tapenade Makefile (similar to TAF),
    to append each forward src file to corresponding Tapenade-generated AD file,
    using new short script "append_fwd_src"; otherwise (default), put all
    adjoint (or Tang.Lin.) tapenade  fortran files "_b.f" (or "_d.f") into a
    single "adj/tlm/_tap_all.f" file, to be compiled to get an object file.
  - simply add symbolic-links within pkg/tapenade/ to the few files from
    "tools/TAP_support/ADFirstAidKit/" that are needed.
  - fix for case-insensitive file systems (e.g., on Mac-OS) and update optfile
    "darwin_arm64_gfortran" to use Tapenade on Mac-OS using with "docker".
o pkg/diagnostics:
  - add diagnostic "VSHEARSQ" for the square of vertical shear.

checkpoint69h (2025/10/23)
o pkg/ctrl:
  - account for shift in record number between original xx_gentim2d_file full
    time-series and "effective" sub-set version ; this was previously missing.
    Also enable some debug print from ctrl_get_gen_rec.F (if debugLevel >= 3).
o pkg/seaice:
  - fix compilation of seaice_growth_adx.F (left from PR #750).
o model, pkgs:
  - remove code within "#ifndef EXACT_CONSERV / #endif" bracket and remove
    completely CPP option EXACT_CONSERV.
o pkg/bling:
  - allows to specify a 2D field of light attenuation coefficient (k0_2d) from
    file "bling_k0_2dFile".

checkpoint69g (2025/09/12)
o verification/short_surf_wave:
  - fix Non-Hydrostatic pressure initialization issue with implicSurfPress=1/2
    by re-starting (nIter0=1) from pickup generated with implicSurfPress=1.
o tools/mpack-1.6:
  - fix compilation for recent version of gcc, to pass the compiler test in
    "configure" and md5 compilation with v15 (comply with C23 standard).
o pkg/streamice:
  - for OpenAD, adjust streamice_write_pickup.F to only write the forward
    components of state arrays to the binary pickups for later use.
o verification:
  - remove all pkg/timeave params from all exp. and no longer compile this
    pkg in any exp. ; also skip pkg/mnc compilation in 4 fwd test exp ;
  - switch few remaining exp. to #define EXACT_CONSERV so that no exp is
    compiled with this option undefined anymore.
o pkg/profiles:
  - fix "profilesDoNcOutput" feature (writing NetCDF model equivalents) so
    that it can be use with pkg/grdchk. Switch profilesDoNcOutput" to True in
    adjoint test exp.  global_oce_biogeo_bling (both in TAF & Tapenade test).
  - improve code readability, rename cost_profiles.F to profiles_cost.F
    and fix obvious multi-threading issues.

checkpoint69f (2025/07/10)
o model/src, pkg/kpp:
  - store shortwave penetration fraction in 3D field SWFrac3D and add run-time
    params "selectPenetratingSW" to chose between different short-wave heating
    options (only =1 currently implemented);
  - remove local (buggy) solution in pkg/seaice ;
  - add runtime-flag "KPPuseSWfrac3D", set to F by default, because this code
    can only approximately replace the original pkg/kpp-code ;
  - update TAF directives in pkg/kpp (mostly related to the code changes);
  - fix "global_ocean.cs32x15" exp bug in "in_p" and "seaice" tests, update FWD,
    ADM & TLM ref. output ; set KPPuseSWfrac3D to True in "1D_ocean_ice_column"
    (both FWD & ADM) test exp. with updated ref. output.
o pkg/streamice:
  - fix "new_partial" initialisation in streamice_adv_front.f (helps Tapenade)
o pkg/bling, pkg/dic:
  - additional store directives to avoid hidden recomputations.
o pkg/longstep:
  - add remaining GM-Redi matrix coefficients (extra-diagonal & diagonal terms)
    and Bolus transport stream function for time-averaging in longstep pkg and
    use saved values in longstep time-stepping.
o pkg/seaice:
  - fix 3 output formats to allow to run with gfortran v.15
  - also add "deep_anelastic.vecinv" to multi-threaded tests.
o pkg/mom_{common,fluxform,vecinv}:
  - mom_fluxform, new option, selectCoriScheme=4: use hFac averaged transport in
    Coriolis term so that column integral of tendency match Coriolis time
    column integral U,V.
  - mom_vecinv, new option, selectVortScheme=4: by-pass division by hFacZ and
    instead apply recip_hFacW/S on final tendency. Note: this fixes Angular-Mom
    (AM) conservation but breaks vorticity tendency matching advection of vort.
  - new 3-d Coriolis option, select3dCoriScheme=2,3: Alternative discretization
    using averaged transport; =3 (vs 2), an other alternative discretization of
    vertical momentum tendency gW.
  - deep-model, put gU,gV NH-metric terms inside vertical advection, to exactly
    conserves AM (+ simplify & speed up by skipping NH metric-terms gU,gV
    calculation). Add CPP option "MOM_USE_OLD_DEEP_VERT_ADV" (in
    MOM_COMMON_OPTIONS.h) to recover the explicit NH metric-term calculation.
  - mom_fluxform, new spherical Metric-terms option, selectMetricTerms=2,3: More
    accurate discretization similar to manual eq. 2.102 & 2.103 but centered at
    grid-cell corner; Also option (selectMetricTerms=3) to skip the gU spherical
    metric term by advecting uVel*dxC (simpler, faster and exactly conserve AM).
  - add diagnostics for Metric-Terms.
  - verification exp. "deep_anelastic", new secondary "vecinv" test + also
    update primary test ref output.

checkpoint69e (2025/05/01)
o pkg/atm_ocn_coupler:
  - update local copy of setdir.c and CPP_EEOPTIONS.h (were left behind);
  - improve "run_cpl_test" step 1 (pass options to genmake2) and step 2.
o tools/genmake2:
  - use specific "ad_config.template{0,1,2}" in different stages of TAF
    AD/TL built to avoid race condition issue with "make -jN".
o model/src:
  - no "addMass" contribution to initial (iter=0) vertical velocity ;
  - with selectAddFluid=1, fix missing implDiv2DFlow factor in "addMass"
    contribution to solver RHS ;
  - add a STOP if implDiv2DFlow < 1 with exactConserv=F, (was not right with
    useRealFreshWaterFlux=T or selectAddFluid=1) and remove untested pieces
    of code dealing with this case ;
  - when using cg2d/cg3dTargetResWunit, add missing implDiv2DFlow factor to
    solver tolerance setting (cg2d/cg3dTolerance) ;
  - upgrade "global_ocean.cs32x15.viscA4" exp. to test selectAddFluid=1
    with implDiv2DFlow=1/2 ; also update "short_surf_wave" exp. output.
o tools/genmake2:
  - with Tapenade, remove list NON_AD_F77_SRC_FILES from Makefile (not used),
    remove processing of "dontCompile", "keepOriginal" and "cb2mFiles" lists ;
  - otherwise, in Makefile, move NON_AD_F77_SRC_FILES and NON_AD_F90_SRC_FILES
    lists after AD_FILES and AD_F90FILES ;
  - simplify (remove intermediate targets) and improve the "-ncad" Makefile
    to ends cleanly when "staf" command fails.
o utils:
  - improve gluemnc description (usage, dependencies, and example).
o tools:
  - replace (obsolete) "egrep" with "grep -E" (or without "-E" if not needed).
o verification:
  - After merging (5 fwd tests + 2 AD) few exp. into new host-exp. (PR #830),
    move input dir and ref. output from merged exp. to replace sym-link in new
    host exp. and remove remaining files/dir (code, build, run) in merged-exp;
  - Add or update README.md in new host-exp and update list of exp. in the docs.
o pkg/rbcs:
  - fix error/warning cases and messages.
o pkg/autodiff:
  - alternative way (printResidualFreq >=0) to get CG2D output from cg2d_mad.F
  - remove 2 unused CPP options.
o tools, autodiff and others:
  - remove TAMC features, untested, unused and probably broken.

checkpoint69d (2025/03/01)
o tools:
  - changes to genmake2 to allow TAF to process F90 files with modules, for now
    only with "-ncad" option;
  - re-order list of src files sent to TAF (needed with current version of TAF);
  - add new scrip "f90mkdepend_taf" to add dependencies form TAF generated src
    code (Adjoint and Tang.Lin) in a file included into Makefile.
  - more logical and consistent ordering in Makefile target, *.F90 first then
    *.F77, *.c and *.h
  - add 2 new variables TAF_F77_FLAGS and TAF_F90_FLAGS (set from genmake_local
    or adjoint-optfile) to go into the TAF command.
o model/src and forcing:
  - for TEOS10, add new S/R to convert model surface Conservative Temperature
    to in-situ Temperature (SST) and compute and store model SST in new model
    field (in FFIELDS.h) "gcmSST", just a copy of model Pot.Temp with other EOS.
  - use model SST to compute surface forcing over open ocean in pkg/exf and
    pkg/bulk_force ; for now, leave ice/seaice freezing/melting unchanged.
  - switch test exp. global_ocean.cs32x15.in_p to use TEOS10 + update lab_sea
    Tapenade ref. output (affected @ machine truncation level).
o tools:
  - remove old backward compatibility feature, so that env.var ROOTDIR is no
    longer recognized by genamke2 ;
  - re-write "suggest_optfile_names" to use parts from "genmake2".
o utils/python:
  - make MITgcmutils compatible with numpy 2.0.0 again.
o testreport:
 - improve way of sending results tar file with "scp", now allowing to combine
   "ssh" then "scp".

checkpoint69c (2024/12/06)
o pkg/mom_common,fluxform,vecinv:
  - remove ISOTROPIC_COS_SCALING code from pkg/mom_vecinv/mom_vi_hdissip.F (was
    not right); add warning (or stop if side-drag) if used with pkg/mom_vecinv.
  - move 2 Cos-Scaling CPP options from CPP_OPTIONS.h to MOM_COMMON_OPTIONS.h
    to be used in horizontal viscosity formulation; more consistent use of
    GAD_OPTIONS.h where these 2 CPP options are used for horizontal diffusion.
  - update all verification exp. customized version of CPP_OPTIONS.h,
    GAD_OPTIONS.h and MOM_COMMON_OPTIONS.h.
o verification/atm_gray:
  - gray atmosphere test exp moved from "verification_other".
o model/src:
  - add few missing option header files (RBCS, SALT_PLUME, SHELFICE) in few
    src files ; also illustrate how to catch these (see SALT_PLUME.h and
    shelfice_ad_check_lev{1,2,3,4}_dir.h).
o eesupp + model:
  - remove FAST_BYTESWAP code and option
  - remove empty file AUTODIFF_MYFIELDS.h
o pkg/ctrl:
  - add a STOP when ALLOW_CTRL_OBCSN/S/W/E is defined but corresponding
    ALLOW_OBCS_NORTH/SOUTH/EAST/WEST is undef ; and fix the code so that, in
    that case, it will compile and reach the stop before running 1rst time-step
o model,pkg:
  - minor spell checking and formatting updates.
o pkg/bling:
  - size-dependent phytoplankton growth code cleaned up and related parameters
    can now be specified in data.bling;
  - clean up OPTIONS in pkg/bling code ( SIZE_NUT_LIM merged with SIZE_DEP_LIM,
    MULT_NUT_LIM merged with MIN_NUT_LIM ) and switch USE_QSW to #undef ; this
    fixes FWD exp. global_oce_biogeo_bling which a) use default BLING_OPTIONS.h
    and b) since no short-wave is provided, light was zero with USE_QSW defined.
o pkg/profiles:
  - add option to write model-equivalent profiles in a netcdf file, thus
    removing the need for post-processing tiled output files.
o pkg/grdchk:
  - write either "grd_ratio_ad" or "grd_ratio_ftl" depending on type of run
    and remove limitation to "useSingleCpuIO=F" when writing 2D files ;
  - write "costfunction0000" only once, from pkg/ecco.

checkpoint69b (2024/10/31)
o pkg/autodiff:
  - TAF-store directives for saltFlux (needed for #define EXCLUDE_FFIELDS_LOAD)
  - little cleaning of ctrl_map_forcing.F (remove duplicated EXCH calls, ...).
o tools/genmake2:
  - remove step that generates *.flowdir
o pkg/profiles:
  - fix missing pieces in this pkg for Tang-Lin model and get this tested in
    verification exp. global_oce_biogeo_bling.
o pkg/seaice:
  - if SEAICEaddSnowMass=T, include HSNOW in diagnostics "SIenph  ".
o utils/python/MITgcmutils/:
  - augment (llc, examples, ...) and update python utils
o tools/build_options:
  - update darwin_arm64_gfortran to be able to compile free-format F90 files.
o pkg/seaice:
  - add new lateral drag parameterisation for landfast ice (Liu etal 2022, JGR)
o verification/*/results:
  - update 5 adm + 3 tlm ref. output affected by TAF new version 6.4.5 & 6.5.0
o pkg/ecco:
  - implement sea-ice freeboard cost "m_freeboard".
o tools/xmakedepend:
  - fix xmakedepend to accept suffix longer than 1.c and add dependencies to
    Makefile from included headers in F90 src files.
o model/src:
  - Add new param "cg3dTargetResWunit" to skip the normalization of cg3d RHS
    by specifying the CG3D target residual in term of vertical-velocity units ;
  - Remove header files SOLVE_FOR_PRESSURE{3D}.h ; clean-up "post_cg3d.F" ;
  - switch test exp. global_ocean.cs32x15.viscA4 & short_surf_wave to use new
    param "cg3dTargetResWunit".
o tools/f90mkdepend:
  - add arguments to f90mkdepend to specify alternative file suffix (e.g.,
    for MacOS) + minor improvement in error message.

checkpoint69a (2024/09/08)
o tools/genmake2:
  - list of src files to Differentiate: change from simply "*.list" to commonly
    adopted "*_ad_diff.list" (to avoid accidents).
  - change Makefile to enable TAF to generate Tangent-Linear code from a mix
    of fixed-form (.F) and free-form (.F90) src code.
  - test free format *.F90 code in hs94.1x64x5/code_ad/ exp. for AD and TLM.
o pkg/dic:
  - save 3D pH (for calcite saturation calculation, useCalciteSaturation=T)
    for next time-step and store it in pickup files (for restart).
o eesupp/src:
  - new set of Global-Sum vector routines working with shared buffer
    (=> no needs for input/output to be in common block) and with
    GLOBAL_SUM_ORDER_TILES implemented ; and remove older versions.
o tools/genmake2:
  - change Makefile to enable TAF to generate adjoint from a mix of fixed-form
    (.F) and free-form (.F90) src code. Also fix for alternative suffix (e.g.,
    used on MacOS) to work without -ncad.
o tools/adjoint_options:
  - allow to pass -f08 flag to TAF by setting TAF_FORTRAN_VERS to "F08".
o pkg/mom_vecinv:
  - add more 3-D momentum tendency diagnostics (originally from Helen Pillar)
    for harmonic/bi-harmonic dissipation and for bottom + top friction
    tendency (under new CPP option: ALLOW_MOM_TEND_EXTRA_DIAGS).

checkpoint68z (2024/07/27)
o pkg/diagnostics:
  - to allow to use ADJ-diags in DIVA runs, change call sequence regarding
    TURNOFF_MODEL_IO and DIAGSTATS_INI_IO and simplify (fewer tests for
    "costfinal") the_model_main.F (+ shorten pkg/openad version) ;
  - restore the use of "diag_pkgStatus" (switch & check) in AD backward sweep
    with new small S/R for DIVA runs ;
  - turn on FWD and ADJ-diags in secondary lab_sea AD test "noseaice".
o pkg/bling:
  - clean-up "bling_light.F" (fix typo related to PHYTO_SELF_SHADING option,
    move k-loop outside) ; add CHL to bling_ad_check_lev{2,3,4}_dir.h and
    fix TAF storage directives ;
  - change "global_oce_biogeo_bling" AD test exp. (both TAF & Tapenade) to
    use PHYTO_SELF_SHADING (with #undef USE_QSW) and update ref. output.
  - also clean-up MDSIO_BUFF_WH.h (avoid common block that mixes r4 & r8 vars).
o pkg/obcs:
  - Neumann boundary conditions for sea ice variables, activate by setting
    new runtime parameter useSeaiceNeumann=.TRUE. in data.obcs ;
  - fewer (hidden) recomputations and no recomputation warnings when
    both ALLOW_OBCS_BALANCE and ALLOW_OBCS_STEVENS are defined.
o pkg/cost:
  - new runtime flag for pkg/cost "cost_mask_file", which can be used
    for flexible cost function definition.

checkpoint68y (2024/06/05)
o pkg/bling:
  - fix bigR setting when option CARBONCHEM_TOTALPHSCALE is defined.
o pkg/steep_icecavity + shelfice:
  - new package to be used together with pkg/shelfice to also account for
    melting at the vertical faces of a steep ice-shelf interface ;
  - allows to use non-zero (but constant) ice-shelf salinity ;
  - new FWD and (TAF) AD secondary test exp. (in isomip) using new pkg.
o pkg/bling:
  - fix/improve initialization of biomass for the 3 phytoplankton groups ;
  - add 2D diagnostics of optically integrated chlorophyll concentration
    within local-time window to be compared with satellite observation ;
  - improve TAF store directives (reduce recomputations).
o pkg/obcs (tides):
  - more efficient implementation of OB barotropic tidal velocity components,
    with both Cos & Sin of phase times Amplitude stored in common block ;
  - more flexible specification of OB tidal-components (only read-in components
    with non-zero tidal period) ;
  - allows to specify tangential component of barotropic tidal velocity at OB ;
  - rename all OBC tidal component input parameter (period, amplitude and
    phase of each OB barotropic tidal velocity component input files) ;
  - upgrade OB tidal example (in seaice_obcs/input.tides) with fewer tidal
    components (only 4) but including few tangential components.
o verification:
  - changing domain decomposition (more tiles) in global_with_exf experiment
    (both FWD & AD) and update ref. output ;
  - use correct CD-Scheme time-stepping in FWD exp. global_ocean_ebm and update
    ref. output ;
  - simplify global_ocean.90x40x15/code_ad (undef ALLOW_GENTIM2D_CONTROL,
    ALLOW_DIFFKR_CONTROL & ALLOW_3D_DIFFKR); remove kpp from global_oce_latlon
    (from both TAF & Tapenade code) ;
  - after adjusting new host experiment code, merge forward test:
      flt_example            --> exp4.with_flt
      global_with_exf        --> global_ocean_ebm.w_exf
      global_with_exf.yearly --> global_ocean_ebm.yearly
      natl_box               --> lab_sea.natl_box
      natl_box.longstep      --> lab_sea.longstep
    and TAF & Tapenade tests:
      global_with_exf        --> global_oce_latlon.w_exf
    For now, keep original set-up in place and add symbolic links into new
    host exp. for input dir and ref. output to run these as secondary test.
o pkg/obcs:
  - fix unusual division by zero in all 4 (N,S,E,W) orlanski main S/R.
o pkg/diagnostics:
  - new header file "DIAGNOSTICS_P2SHARE.h" (for now, just for useDiag4AdjOutp),
    and remove DIAGNOSTICS.h in any src code outside pkg/diagnostics;
  - new params "diag_dBugLevel" (default = main model "debugLevel");
  - add new arg "seqFlag" to DIAGNOSTICS_SWITCH_ONOFF and DIAGNOSTICS_SUMMARY
    and prevent "diagnostics_status" to be overwritten when using ADJ-diags.

checkpoint68x (2024/04/30)
o model/src:
  - more precise specific-volume anomaly expression for Ocean in P-coord;
    update reference output of all 3 Ocean in P test experiments.
o pkg/generic_advdiff:
  - adjust 2 SOM (Prather advection) store directives to reduce memory overhead
  - include OS7MP (advScheme 7) in AD code ; switch AD test experiment
    isomip.htd to use this advection scheme for Temp and Salt.
o pkg/ecco, ctrl:
  - put active_read calls within #ifdef ALLOW_AUTODIFF (missing in few places)
    and fall back to non-active read (from pkg/rw) if undef;
  - change argument order in few obcs related pkg/ecco S/R.
o pkg/seaice:
  - for seaice-dynamics, add missing mapping of (pkg/thsice) snowHeight to HSNOW
  - this affects results (unless SEAICEaddSnowMass=F); update seaice parameters
    in test global_ocean.cs32x15.icedyn and update reference output.

checkpoint68w (2024/03/05)
o pkg/ctrl, grdchk & optim:
  - clean and improve list of ctrl-var settings (in common blocks) and update
    ctrl-pack header files:
    a) define new character fields "ncvartype" for ctrl-var shape type and
       save ctrl-var (file) name "ncvarfname" ;
    b) re-define "ncvarindex" to point directly to genArr index (according to
       ncvartype) or 1,2,3,4 for N,S,E,W obcs-ctrl ;
    so that map of index (and grdchkvarindex) to file name, array shape and
    genArr specification is direct, code is simpler, more robust and efficient.
  - allow to specify grdchk ctrl-var by name in "data.grdchk" (more robust) ;
  - write ncvartype list to ctrl-pack header files ;
  - simplify definition of maxcvars to get much shorter "ncvar"-field lists ;
  - remove unnecessary common blocks, rename ctrl_init.F -> ctrl_init_fixed.F,
    call TURNOFF_MODEL_IO only once ;
  - adjust optimisation utility optim and provide backward compatibility
    regarding changes to ctrl-pack files ; also improve build process ;
  - update all "data.grdchk" in verification experiments.
o pkg/gmredi:
  - add GEOMETRIC parameterization (Mak etal, JPO, 2018) for GM coefficient,
    under GM_GEOM_VARIABLE_K CPP-option, turned on with "GM_useGEOM=T" and
    tested in exp. ideal_2D_oce, secondary test "geom".
o pkg/ecco:
  - add option ECCO_VARIABLE_AREAVOLGLOB to use the total time-varying volume
    to weight contributions to m_boxmean cost functions

checkpoint68v (2024/02/03)
o model/src:
  - change param "metricTerms" to integer param "selectMetricTerms" and change
    param "use3dCoriolis" to integer param "select3dCoriScheme" but keep former
    parameters in namelist (backward compatible).
  - remove un-used param "writeStatePrec" + also in experiment param file "data"
  - rotateGrid: fix missing 3-D Coriolis term to gV ; adjust usage restriction.
o pkg/ecco:
  - remove call to ECCO_CHECK from ecco_cost_init_fixed.F (but keep the other
    call from packages_check.F) and move ECCO_SUMMARY call to ecco_check.F
o pkg/shelfice:
  - put the update of kTopC code within "#ifdef ALLOW_SHELFICE_REMESHING/#endif"
    and add run-time switch "SHI_update_kTopC" to allow to turn it off.
  - Change the initial setting of "kTopC" to remain unaffected by machine
    truncation error and if using SHELFICEMassStepping, set it according to
    shelficeMassInit.
o verification/solid-body.cs-32x32x1:
  - update set up (faster flow, smaller planet ..) and fix initial Ps condition.
o pkg/ggl90:
  - revisit Langmuir Circulation (LC) mixing-length calculation: fix bugs in
    some "mxlMaxFlag" implementation and ensure it works with P-coordinate.
    Update vermix.gglLC ref. output and add new secondary AD test (with LC on)
    in global_oce_latlon experiment.

checkpoint68u (2023/12/10)
o pkg/seaice:
  - new/improved LSR convergence criteria (CPP: SEAICE_ALLOW_LSR_FLEX, run-time:
    SEAICEuseLSRflex) accounting for both Non-Lin and Linear solver residual;
    tested in offline_exf_seaice.dyn_lsr; also add 2-D diagnostics for residual.
o pkg/streamice:
  - rename STREAMICE_PETSC.h to STREAMICE_PETSC_MOD.h and rename
    STREAMICE_ARG_PETSC_mod code module to STREAMICE_PETSC_mod;
  - include STREAMICE_PETSC_MOD.h in src files rather than the module directly:
    this obviates the need for alphabetical order in names or serial compilation
o pkg/bling:
  - fix 2 small bugs in carbonate and aragonite saturation states: a) both Ksp
    coeff are fct of log of temperature (and not log10); b) add missing unit
    conversion factor to carbonate variable in OmegaC & OmegaAr calculation.
o pkg/grdchk:
  - new S/R to get CTRL var/file name from grdchk-index ; use it to simplify
    (with new arguments) the 3 routines that handle CTRL var/file perturbations
  - rename grdchk_init to grdchk_get_mask ; move GRDCHK_SUMMARY call ;
  - report (in summary & in results section) CTRL var/file name used in grdchk.
o pkg/dic:
  - fix loading of forcing file for the case DIC_forcingCycle = 0 ;
  - fix inconsistent timing params for loading initial surface-silica file ;
  - clean-up initialise-varia level S/R, now all called from dic_init_varia.F
    and move all forcing field initialisation to dic_ini_forcing.F ;
  - read and process pickup_dic meta file with error/warning (depending on
    pickupStrictlyMatch = T/F) if missing file or field.
o pkg/ctrl:
  - reduce pkg/ctrl/optim.h to just "optimcycle" and rename into OPTIMCYCLE.h ;
  - keep optim_readparms.F namelist unchanged and define variables locally.

checkpoint68t (2023/10/28)
o pkg/dic:
  - improve carbonate dissolution options (new params: selectCalciteDissolution)
    and fix a minor bug in dissolution rates according to Keir et al (1980);
  - change exp. so_box_biogeo secondary tests caSat0/3 to test option 2 & 3.
o pkg/gmredi:
  - fix setting of GM_ExtraDiag that was not (always) turned on with 3D Kappa
    read from file, with Bates-K3d or QG-Leith, therefore missing 2 terms in
    isopycnal diffusion tensor; update ref. output of MLAdjust.QGLthGM test ;
  - add more check and stop for the case #undef GM_NON_UNITY_DIAGONAL ;
  - add runtime parameter GM_isoFac_calcK to allow to scale dynamically computed
    Kappa contribution in the Redi-tensor (default = 1.).
o pkg/autodiff:
  - adjust call to S/R DIAGNOSTICS_SWITCH_ONOFF in autodiff_inadmode_set_ad.F
    so that snap-shot Adjoint diagnostics are filled within the same time-step
    as they are written to output file.
o pkg/ctrl:
  - rename ctrl_dummy.h to CTRL_DUMMY.h, remove unused variables & common blocks
  - retire CPP-flag ALLOW_HFACC/HFACC3D_CONTROL and remove related code.
o pkg/ctrl:
  - rename header file "ctrl.h" to "CTRL.h".
o utils/matlab/cs_grid:
  - update some basic matlab-scripts for CS-grid (split_*_cub.m,
    rotate_uv2uvEN.m, mk_psiLine_CS.m & use_psiLine.m) to a) also work with
    compact-format input; and (b) always assume "long-vector" are stored one
    face after the other (compact-format compatible);
  - new script to generate broken-lines (for computing meridional transport
    stream-function), simpler than the previous version in cs_grid/bk_line/;
  - update RGB-dims in 2 latloncap/ scripts to match pkg/exch2 convention.
o pkg/ctrl:
  - simplify file name handling in ctrl_map_ini_gentim2d.F to please TAF (fixes
    hs94.1x64x5 TL test) without upsetting Tapenade & OpenAD.
o pkg/autodiff + ecco:
  - fix a typo in AD-var output file name (addummy_in_stepping.F);
  - fix and improve weight output in pkg/ecco/cost_generic.F
o pkg/streamice:
  - implementation of parameterized depth-dependent ice-shelf melt rate ;
  - new subroutines added to accumulate misfit cost based on time-dependent
    surface elevation and velocity observations (+ calls in pkg/cost) ;
  - fix generic ctrl (ctrl_map_ini_{genarr,gentim2d}.F) for OpenAD and
    add mapping of STREAMICE arrays to generic controls ;
  - update exp. halfpipe_streamice OAD & Tap setup (remove customized *.F)
    and switch on new CPP option ALLOW_COST_STREAMICE (+adjust params files).
o pkg/autodiff:
  - fix a bug in ALLOW_AUTODIFF_WHTAPEIO code with ALLOW_DIVIDED_ADJOINT ;
  - refine grad-check + update output for AD test "lab_sea.noseaicedyn".

checkpoint68s (2023/09/11)
o verification:
  - change default ALLOW_IB_CORR (in pkg/ecco/ECCO_OPTIONS.h) to "#undef" and
    test that this code compiles in experiment global_oce_biogeo_bling ;
  - clean/update AD related CPP header files across all experiments and reduce
    differences with standard version in pkg autodiff, cost, ctrl and ecco.
o verification:
  - change global_oce_latlon TAF set-up to multi-tiles (4 tiles, as in code_oad
    & code_tap) and add SIZE.h_mpi to enable MPI tests (in all 3 code_* dir).
o model/src & pkgs, TAF storage dir:
  - rearrange and add storing of variables to reduce number of (unwarned)
    recomp. in fluxform & vecinv pkgs and in model/src (e.g., calc_phi_hyd.F) ;
  - add store directives in solve_tri/pentadiagonal.F to avoid recomputation
    warnings with SOLVE_DIAGONAL_KINNER defined ;
  - add CPP condition inside GAD SOM advection S/R (-> empty ".f" file if
    neither GAD_ALLOW_TS_SOM_ADV nor PTRACERS_ALLOW_DYN_STATE is defined ) ;
  - clean-up/refine many unnecessary store directives -> less TAF warnings ;
  - remove unnecessary checkpointing code from pkg/smooth_diff2/3d.F
o pkg/ggl90:
  - move computing the mixingLength to a dedicated routine ggl90_mixinglength.F
  - adjust/add TAF store directives to avoid hidden recomputations.
o pkg/seaice:
  - new option SEAICE_BGRID_DYNAMICS allows to remove/replace
    SEAICE_ALLOW_DYNAMICS by ( SEAICE_CGRID or SEAICE_BGRID_DYNAMICS ) ;
  - exclude more code if SEAICE_CGRID is undefined and clean up/rearrange
    SEAICE.h to form more consistent groups and common-blocks ;
  - update SEAICE_OPTIONS.h in verification experiments.
o pkg/mdsio:
  - Add 2 new arguments (kLo & kHi) to pkg/mdsio Slice I/O routines that allow
    to select which levels in Slice-array to read-in or to write-out to file.

checkpoint68r (2023/08/02)
o verification:
  - adjust amplitude of perturbation (grdchk_eps) to improve Fwd/Adj gradient
    check comparison in exp. global_ocean.90x40x15, global_with_exf & lab_sea ;
  - change location of grad-check (away from freezing Temp) in exp. OpenAD
    and rename experiment "OpenAD" to "global_oce_latlon".
o pkg/ctrl + pkg/grdchk:
  - define PARAMETER nobcs = 4 in CTRL_OBCS.h instead of SIZE.h ; update SIZE.h
    of all code_ad/oad/tap verification exp.
  - in pkg/grdchk, rename grdchk.h to GRDCHK.h and adjust src code to work
    without "nobcs" when OBCS_ALLOW_CONTROL is undefined.
o verification:
  - Remove duplicated parameter files from input_tap/ dir and adjust prepare_run
    accordingly ; remove few untested additional files (in OpenAD/ & lab_sea/).
o pkg/seaice:
  - rename ZMIN/ZMAX into SEAICE_ZMIN/ZMAX to avoid potential conflicts with kpp
    variables with the same name ; rename swfracb into SEAICE_SWFrac ;
  - fix a bug in computing SEAICE_SWFrac in pressure coordinates ; update exp.
    global_ocean.cs32x15.in_p reference output.
o pkg/seaice:
  - SEAICE_USE_GROWTH_ADX: fix a bug related to flooding and fix budget closure
    for linear free-surface case.
o pkg/ecco:
  - in cost_gencost_sshv4.F, enable to also process monthly data (previously,
    only daily) for SSH cost.
o pkg/ctrl:
  - remove left-over and unused code within ALLOW_NONDIMENSIONAL_CONTROL_IO
    (except in OBCS_CONTROL pack/unpack code); as a consequence, switch back
    ALLOW_PACKUNPACK_METHOD2 to #undef in exp. tutorial_global_oce_optim.
o pkgs:
  - for local filenames, replace character*(80) by character*(MAX_LEN_FNAM)
    declaration, where possible, especially in pkgs: autodiff, ctrl, ecco,
    profiles, smooth & grdchk.

checkpoint68q (2023/06/29)
o pkg/ggl90:
  - non IDEMIX code: fix bug (missing hFac) in matrix coefficient computation ;
  - fix RI-Number calculation for IDEMIX ; new flag GGL90_IDEMIX_CVMIX_VERSION
    (defined by default) to update IDEMIX to CVMix version ;
  - add new diagnostics ;
  - update Fwd ref. output of exp. isomip.obcs, global_ocean.90x40x15.idemix
    and global_ocean.cs32x15.in_p.
o pkg/tapenade + other Tapenade addition:
  - add new capability to use Tapenade to generate Adjoint & Tang-Linear model:
    new package (pkg/tapenade), new tools (tools/TAP_support), update genmake2
    and testreport ; add some docs (in progress);
  - modify src code & packages to work with tapenade ; add new code_tap/ &
    input_tap/ dirs (+ ref output) in 9 verification experiments to get
    tested with tapenade.

checkpoint68p (2023/05/07)
o pkg/seaice:
  - fix compile error related to ALLOW_AUTODIFF_TAMC/ALLOW_AUTODIFF mix-up
    in seaice_evp.F; also replace many ALLOW_AUTODIFF_TAMC by ALLOW_AUTODIFF
    where code is not specific to TAF/TAMC;
  - call S/R seaice_get_dynforcing every timestep to always have valid TAUX/Y;
  - move most of routine body of seaice_dynsolver.F inside the
    SEAICE_ALLOW_DYNAMICS block.
o pkg/ecco:
  - fix "sterGloH" output after a restart (issue related to Greatbatch
    correction) by writing & reading (small) new "pickup_ecco" files.
o pkg/ctrl:
  - fix record number (mostly in ctrl_map_ini_gentim2d.F) in case of restart,
    using corresponding xx_gentim2d_startdate1/2 as specified from data.ctrl;
    this finalizes (+ fix) changes made in PR #260 and #380;
  - also add more debug print (+new CPP option ALLOW_CTRL_DEBUG);
  - improve generic-control documentation in Chap.10 (State Estimation).
o pkg/mom_common:
  - new expression for quadratic drag coefficient, function of cell thickness &
    roughness length (logarithmic law of the wall); for now, only for z-Coords.
    Turned on with CPP option ALLOW_BOTTOMDRAG_ROUGHNESS (MOM_COMMON_OPTIONS.h)
    and run-time setting zRoughBot > 0 in data, PARMS01 namelist.
    Tested in exp. tutorial_plume_on_slope, new secondary test "roughBot".
o model/src & pkgs:
  Finish to remove code within retired CPP options:
  - remove orphan code within (many) removed ALLOW_()_CONTROL (as listed in
    PR #689 comments); remove seaice_ctrl_map_ini.F;
  - remove code within retired CPP options, remove call to COST_TRANSPORT,
    remove ALLOW_ECCO_BARSTORES and the 4 "ecco_ad_check_lev?_dir.h" files;
  - remove (check & stop) "using_cost_bp" & "using_cost_scat" from "data.ecco";
  - avoid few unused variables; use default CTRL_OPTIONS.h in exp. hs94.1x64x5.
o pkg/seaice:
  - SEAICE_USE_GROWTH_ADX: fix diagnostic SIatmFW and add diagnostic SIeprflx
    to close seaice mass and heat budgets.
o pkg/dic:
  - remove TAF storage dir for variable "OmegaC" (within wrong CPP option).

checkpoint68o (2023/03/13)
o model/src:
  - salt/temp/ptracer_integrate.F: optimise store directives
  - add mising "obcs_seaice_sponge.f" to obcs_ad_diff.list
o pkg/ecco:
  - smoothing in gencost_bpv4: allow to choose between a) call to smooth_basic2D
    (using a constant length, with run-time params replacing hard-coded values)
    or b) call to smooth_hetero2D (using a 2D field to be read in).
o pkg/obcs:
  -  update OBCS configuration summary.
o eesupp/inc, model/inc & pkgs:
  Clean CPP header files:
  - remove ALLOW_GENCOST_CONTRIBUTION from COST_OPTIONS.h (is already set in
    ECCO_OPTIONS.h);
  - move ALLOW_PACKUNPACK_METHOD2 from AUTODIFF_OPTIONS.h to CTRL_OPTIONS.h;
  - set EXCLUDE_WHIO_GLOBUFF_2D in MDSIO_OPTIONS.h (found in some customized
    AUTODIFF_OPTIONS.h);
  - list CPP options in pkg CPP header file (as undef) when used in any
    experiment local set-up;
  - fix typo in 2 CPP option names ; rename few (unused) pkg/fizhi CPP options;
  - update pkg dependence rule for pkg/bling ; avoid few unused variables.
o pkg/kl10:
  - get stratification from variable "SigmaR" (passed as argument) instead of
    recomputing locally in-situ density (less efficient and inaccurate when
    using Non-Linear EOS); update (kl10) ref output for internal_wave exp.
o pkg/ecco:
  - add new generic integral cost function "m_boxmean_vol" (e.g. to track
    volume of isoycnal layer); add it to lab_sea secondary AD test "noseaice"
    and update ref. AD output file.
o tools/build_options:
  - fix OpenMP option in ifort optfiles for modern intel compiler.

checkpoint68n (2023/02/08)
o pkg/seaice:
  - make all seaice-cost code independent of pkg/ecco and remove few
    SEAICE_COST.h from pkg/ecco ;
  - remove unused code related to ALLOW_SEAICE_COST_SMR_AREA (formerly used
    with ECCO_CTRL_DEPRECATED, seaice_cost_driver.F and S/R called from there),
    ALLOW_MEAN_SFLUX_COST_CONTRIBUTION + ALLOW_SSH_GLOBMEAN_COST_CONTRIBUTION,
    and retire associated parameters.
o pkg/dic:
  - rename CPP: CAR_DISS -> DIC_CALCITE_SAT and AD_SAFE -> DIC_AD_SAFE and put
    all carbonate-saturation code and 3D arrays inside #ifdef DIC_CALCITE_SAT
    block and time-ave arrays within #ifdef ALLOW_TIMEAVE ;
  - add run-time params: useCalciteSaturation, calcOmegaCalciteFreq, nIterCO3,
    selectCalciteBottomRemin, KierRateK, KierRateExp and WsinkPIC ;
  - switch order of arguments to "myTime, myIter, myThid" in few remaining
    pkg/dic S/R + S/R calls in pkg/gchem ;
  - update exp. so_box_biogeo (define CARBONCHEM_TOTALPHSCALE & DIC_CALCITE_SAT)
    + add 2 new secondary tests (caSat0 & caSat3) with useCalciteSaturation=T
    and using 3-D silicate input file.
o TAF tape keys:
  - rename many local taf keys to use shorter and more consistent names ;
  - pkg/thsice: fix bug in key computations.
o pkg/diagnostics (+doc):
  - fix index-loop range in diagnostics_sum_levels.F and document "fileFlags"
    and associated features (vertical interpolation & integral & hFac scaling).
o pkg/gmredi:
  - in gmredi_slope_limit.F, fix tape keys by using local tapes.
o pkg/ggl90:
  - cleaning: remove maskS multiplication in ggl90_calc_visc.F (no equivalent
    for KappaRU) and update "output_oadm.ggl90.txt" in OpenAD exp.
o pkg/ggl90:
  - Add code in pkg/ggl90 to parameterize Langmuir Circulation (LC) effects on
    vertical mixing (useLANGMUIR=T); follows: Tak et al, Ocean Modelling, 2023;
  - Primary effect is to increase mixing length scale due to LC ; the stokes
    velocity term is also included in the momentum equation (Coriolis term);
  - Tested in new secondary test "gglLC" in exp. "vermix".
o pkg/ecco:
  - fix out-of-bound array index issue in cost_gencost_sshv4.F;
  - fix a small bug in same S/R (skipping call to smooth_hetero2d(anom_slaobs, )
    if gencost_outputlevel(igen_lsc)=0.);
  - in same S/R, skip output of "_smooth" file  when smoothing is not applied.
o pkg/ctrl:
  - enable initial sea ice area/heff controls with correct definition of control
    indices;
  - move condition on useSEAICE inside seaice_init_varia.F (always initialize to
    zero) when compiling pkg/autodiff. Similar changes to shelfice_init_varia.F;
  - fix out-of-bounds index issue in ctrl_map_ini_genarr.F (igen_shiCDrag=0).
o pkg/dic:
  - enable to read in prescribed 3d silicate fields for calcite-saturation
    calculation and 3-D pH calculation (#define CAR_DISS).
  - add 5 new 3-D diagnostics related to calcite-saturation calculation.
  - fix 2-D silica input file from tutorial_global_oce_biogeo and add 3-D silica
    input file to so_box_biogeo exp. (currently unused).

checkpoint68m (2022/12/05)
o pkg/gmredi:
  - update Redi diffusion and GM (skew-flux or advective form) to also work with
    P-coordinates and most current tapering schemes ; change sign of sigmaR (for
    now, only within pkg/gmredi) to always be the same as stratification, i.e.,
    positive if stratified ; add 2 arguments to GMREDI_SLOPE_LIMIT for 'ldd97'.
  - with p-coord, keep sign of slope component unchanged (same as dSigmaX,Y)
    and flip sign (-gravitySign) of Redi-tensor extra-diagonal terms ; also keep
    stream-function components GM_PsiX & GM_PsiY unchanged and flip sign when
    computing bolus-transport (left handed coord).
  - add unit conversion factor between p and z coord. at level center, function
    of vertical profile of ref. density ; used inside slope-limiter and tapering
    function.
  - stop if trying to use P-coord with not yet updated gmredi pieces of code.
  - add a simple secondary test in front_relax exp. using GM and p-coord.
o pkg/autodiff:
  - cleanup tamc.h: remove unused parameters and nthreads_chkpkt as it is (and
    should be) always one; update all verification exp. code_ad versions.
  - simplify tape-key dependence on tile indices (remove thread grouping).
o pkg/ctrl:
  - add run-time variable ctrlDir to specify a directory different from default
    current directory for I/O of controls adjustment and adjoint gradient (xx
    and adxx), and other active files; used (as example) in lab_sea experiment.
o pkg/smooth:
  - add run-time variable smoothDir to specify a directory different from
    default current directory for I/O of smoothing operators.

checkpoint68l (2022/10/26)
o pkg/longstep:
  - fix initialization of LS_fwFlux ;
  - move params report & check to new S/R LONGSTEP_CHECK.
o model/src:
  - fix ocean r-star pressure gradient in case model top is not uniformly at r=0
  - update ref output of secondary test "isomip.obcs".
o tools/genmake2:
  - Remove unnecessary awk escape sequence ; this avoids a warning with recent
    GNU awk (5.0.1 and newer).
o tools/adjoint_options:
  - merge five ad-optfiles into single one with compact list of generic control
    variables and obcs-control variables ;
  - to use divided adjoint (DIVA), in genmake_local, set new flag USE_DIVA=1
    (replacing "adjoint_diva");
  - select which Fortran version is sent to TAF by setting TAF_FORTRAN_VERS
    to either F77, F90, or F95 (replacing "adjoint_f95") ;
  - to replace "adjoint_tamc_compatibility", in genmake_local, set new flag
    TAMC_COMPATIBILITY_MODE=1 ;
  - remove "-server fastopt.net" to use the default server (fastopt.de)
  - use the staf default server (currently "fastopt.de") instead of specific
    server "fastopt.net" ;
  - remove more commented lines (remove_comments_sed) in src code sent to TAF ;
  - remove obsolete "ad_taf_output.f.*" diff-patches in tools/ ;
  - remove "ad_optfile.local" files from some verification experiments ; keep
    example how to specify local optfile in verification/bottom_ctrl_5x5 ;
o pkg/streamice:
  - changes related to PETc solver interface to be compatible with PETSc
    version 3.8 and above and also available without MPI;
  - also make sure PETSc is not used at runtime by default.

checkpoint68k (2022/08/17)
o pkg/ctrl, ecco, ... :
  Remove untested and obsolete ECCO_CTRL_DEPRECATED code: From now on it is
  only possible to specify control parameters through generic controls.
  - retire associated pkg/ctrl and pkg/autodiff flags, such as: ctrlUseGen,
    xx_hflux_file, xx_hflux_startdate1, ..., ctrlSmoothCorrel2D/3D,
    useSmoothCorrel2DinAdMode. Most of these did not have any effect with
    undefined ECCO_CTRL_DEPRECATED, but were still allowed in data.ctrl.
    Now specifying them is an error and stops the run.
  - remove code that assumes ctrlUseGen=F
  - remove empty and unused subroutines:
    * pkg/ctrl: ctrl_weights.h, ctrl_map_ini_gen.F, ctrl_smooth.F,
        ctrl_map_ini.F, ctrl_map_ini_ecco.F, ctrl_map_ini.F, ctrl_map_ini_ecco.F
    * pkg/ecco: cost_forcing.F, cost_hyd.F, cost_internal_params.F, cost_ssh.F
        ecco_cost_summary.F
    * pkg/smooth: smooth_correl2dw.F
    * pkg/seaice: seaice_cost_areasst.F
  - adjust parameters in verification experiment that still contained retired
    parameters
  - switch global_ocean.cs32x15.thsice to using generic control variables
  Note: some untested code (notably pkg/admtlm, which did not compile before)
    will be more difficult to resurrect without the ECCO_CTRL_DEPRECATED code.
o pkg/ggl90:
  - adjust code to also work under an ice-shelf (with pkg/shelfice); idemix
    under ice-shelf not fixed yet.
  - turn on ggl90 in isomip experiment secondary test "obcs" and update
    reference output file.
o pkg/gmredi:
  - allow to read-in 3-D background isopycnal (Redi) and thickness (GM)
    diffusivity without pkg/ctrl: new 3-D arrays, new CPP options:
    GM_READ_K3D_REDI & GM_READ_K3D_GM and new input files: GM_K3dRediFile &
    GM_K3dGMFile (replacing retired GM_isopycK3dFile & GM_background_K3dFile).
  - update code for ALLOW_KAPGM_CONTROL & ALLOW_KAPREDI_CONTROL to use
    these new 3-D arrays (from GMREDI.h) and move setting of 3-D control arrays
    from from ini_mixing.F to gmredi_init_varia.F (+ adjust call condition);
  Note: need to define new option GM_INPUT_K3D_GM and/or GM_INPUT_K3D_REDI
    to use KAPGM_CONTROL and/or KAPREDI_CONTROL.
  - remove obsolete code & CPP option ALLOW_KAPGM/KAPREDI_CONTROL_OLD

checkpoint68j (2022/06/28)
o pkg/exf:
  - implement drag coefficient of Large and Yeager (2009), Climate Dynamics, 33,
    pages 341-364, within #ifdef ALLOW_DRAG_LARGEYEAGER09
o autodiff(TAF):
  - fix few taf recomputation and conflict warnings in: calc_3d_diffusivity.F
    (PCELL_MIX_CODE), pkg/bling & dwnslope_apply.F ; update reference AD output
    of exp. that use pkg/dwnslope (lab_sea).
o pkg/thsice:
  - fix bug in computation of ustar (case velocity=0) in thsice_calc_thickn.F;
  - introduce & document THSICE_REGULARIZE_CALC_THICKN flag.
o pkg/generic_advdiff (TAF):
  - in gad_advection.F, replace global tapes "comlev1_bibj_k_gad" &
    "comlev1_bibj_k_gad" by local tapes; avoid unnecessary recomputations, but
    recompute full routine (only) once in ad-routine;
  - this affects results when useApproxAdvectionInAdMode=T, since now all tapes
    are computed using approximate Adv-Scheme (inAdMode=T); udate AD ref. output
    of exp. global_ocean.cs32x15.seaice.
o pkg/shelfice:
  - Remove ALLOW_SHIFWFLX_CONTROL and all xx_shifwflx related code in favor of
    already implemented gentim2d;
  - move update of shelficeLoadAnomaly inside shelfice_step_icemass.F (within
    IF (SHELFICEMassStepping) ...);
  - fix storage dir for SHELFICEMassStepping, allowing to realFreshWaterFlux=T
    with ALLOW_AUTODIFF defined (remove STOP there). Still not working with
    OpenAD (add a STOP in shelfice_check.F).

checkpoint68i (2022/04/27)
o eesupp/src:
  - simplify reading parameter file, using single scratch file (instead of 2).
o verification, OpenAD:
  - make all OpenAD experiments use generic control variables, so that from now
    on, the ECCO_CTRL_DEPRECATED code is no longer tested in verification
    (neither in verification_other, where it never was tested), except for
    global_ocean.cs32x15.thsice (this is intentioal).
o autodiff(TAF):
  - avoid unnecessary local recomputations and associated warnings by storing to
    local tapes in: seaice/advect.F, gad_dst3fl_impl_r.F, gmredi_slope_limit.F,
    shap_filt_uv_s2.F, solve_pentadiagonal.F
o pkg/thsice:
  - fix store directives + modify code of thsice_calc_thickn.F, thsice_extend.F
    and thsice_solve4temp.F to avoid 28 recomputation warnings and recomputing
    the state unnecessarily;
  - define new tape and retire two old thsice related tapes (commented out for
    now) in the_main_loop.F;
  - change offline_exf_seaice.thsice experiment to be more sensitive to changes;
  - fixing a bug leads to smaller gradient errors and correct TLM cost function
    values and requires updating (both ADM and TLM) offline_exf_seaice.thsice
    and global_ocean.cs32x15.thsice reference output;
o pkg/ctrl:
  - fix issue in S/R CTRL_MAP_GENARR3D by explicitly set xx_gen to zero where
    wgenarr3d is zero ; also replacing 10^xx_gen with EXP(log(10)*xx_gen) for
    log10ctrl produces small differences at machine truncation level.
o eesupp & pkg/mdsio:
  - new (CPP) Macro to open read-only files with ACTION='read', added to
    most pkg/mdsio S/R (+ exf_interp_read.F); disable this in few old compiler
    optfiles (g77, pgf77) by adding EXCLUDE_OPEN_ACTION to DEFINES list.
o model:
  - new CPP option to exclude (= default) S/R CONVECTIVE_ADJUSTMENT_INI;
    to reproduce old results, define new option INCLUDE_CONVECT_INI_CALL in
    two verification experiments: exp2 and tutorial_tracer_adjsens.
  - add a check for INCLUDE_CONVECT_CALL if cAdjFreq <> 0.
o tools/build_options:
  - new optfile "darwin_arm64_gfortran" for Mac ARM 64-bit processor.
o pkg/gmredi:
  - add deep-factor to pkg/gmredi code to work with "deepAtmosphere=T".
o verification/cpl_aim+ocn:
  - add secondary test set-up using seaice dynamics (pkg/seaice) as part of
    ocean component and update script to handle option to run multiple test.
o verification/halfpipe_streamice:
  - update OpenAD test by removing ECCO_CPPOPTIONS.h (but, for now, keep local
    version: ctrl_map_gentim2d.F & ctrl_map_ini_genarr.F in code_oad).
o pkg/mypackage:
  - improve description (for a coding style example).
o model:
  - add option to apply a correction for net global fresh-water flux imbalance
    proportional to, fixed in time, 2-D weight field that is read-in from file ;
  - new integer selector "selectBalanceEmPmR" (=0: off, =1: uniform correction,
    =2: correction scaled by weight) that replaces logical switch "balanceEmPmR"
    with backward compatibility setting.

checkpoint68h (2022/03/22)
o pkg/ecco:
  - new src files: ecco_init_fixed.F & ecco_diagnostics_init.F ;
  - new SSH diagnostics: SSH,SSHNOIBC (with & w-out Inv.Barometer corr.: SSHIBC)
    STERICHT (steric height anomaly); and Bottom-Pressure/Mass: OBP & OBPGMAP ;
  - add arg myTime & myIter to S/R ECCO_PHYS and adjust calls ; change to use
    model "rhoInSitu" (instead of recomputed rho) for Greatbatch correction ;
    this affects cost "m_eta".
o pkg/ecco:
  - add new feature (within gencost) to evaluate cost-function contribution
    over specified density range (instead of depth range, see issue #483);
  - add few run-time parameters including logical switch: gencost_useDensityMask
  - test this new feature in lab_sea/input_ad.noseaice and update ref. output.
o pkg/ptracer (adjoint):
  - remove AUTODIFF_PTRACERS_SPLIT_FILES as it has no effect.
o pkg/generic_advdiff & seaice (adjoint):
  - avoid recomputation in Second-Order Moment (SOM) advection S/R by using
    local tapes ; reduce local tapesize in seaice_solve4temp.F ;
  - fix key and size of tapes in multi-dimensional advection routines and adjust
    maxcube value (2 or 3 if using CubedSphereExchange) in few exp. "tamc.h".
o pkg/mdsio:
  - retire all S/R from mdsio_rw_slice.F after replacing the last 2 calls to
    MDSWRITEFIELD{X,Y}Z in pkg/ctrl/ctrl_set_globfld_{x,y}z.F with calls to
    S/R WRITE_REC_{X,Y}Z_RL (from pkg/rw).
  - remove src file mdsio_rw_field.F & mdsio_rw_slice.F from NOOPTFILES list
    in few linux_amd64_ifort* optfiles.
  - move if statement out of "lengthBuff" loop in mdsio_{read,write}_whalos.F
o verification AD exp.:
  - remove ECCO_CPPOPTIONS.h from global_ocean_ebm/ and halfpipe_streamice/
    code_ad/ dir and replace by appropriate AUTODIFF/CTRL/COST_OPTIONS.h ;
  - for halfpipe_streamice AD exp., make necessary adjustments in pkg/streamice
    and remove ALLOW_GENTIM2D_CONTROL from store directive header files
    streamice_ad_check_lev?_dir.h ;
  - remove customized version of ctrl_map_gentim2d.F & ctrl_map_ini_genarr.F
    from halfpipe_streamice/code_ad/ and add corresponding code to pkg/ctrl.

checkpoint68g (2022/02/19)
o doc:
  - fix some math notation in docs.
o pkg/obcs:
  - avoid division by zero when useOBCStides=.True. and tidalPeriod=0.
o pkg/gmredi:
  - fix basic code to also work with dry grid cells near the top (e.g., under
    ice-shelf) and in this case, for now, stop if unsafe features are used ;
  - fix tapering 'ac02' and 'stableGmAdjTap' ;
  - add a secondary test, "input.top", in verification exp. front_relax to test
    GM with dry cells at the top (+ also 'ac02' tapering) ;
  - update few adm & tlm & oad ref. output from exp. global_ocean.90x40x15
    since adding better masking in gmredi_s{x,y}rtransport.F does affect AD &
    TLM gradient (@ machine truncation level).
o pkg/autodiff:
  - new CPP-flags allow to turnoff (default) autodiff_store/restore entirely:
    * New flags AUTODIFF_USE_STORE_RESTORE, AUTODIFF_USE_STORE_RESTORE_OBCS to
      turn on autodiff_store/restore, undefined by default ;
    * AUTODIFF_EXCLUDE_ADEXCH_RS to skip calls to some AD-exch (if missing).
  - improve comments in AUTODIFF_OPTIONS.h, fix some store directives for new
    default, which are:
       #define ALLOW_AUTODIFF_WHTAPEIO
       c#define AUTODIFF_USE_MDSFINDUNITS
       #undef AUTODIFF_USE_STORE_STORE_RESTORE
       #undef AUTODIFF_USE_STORE_STORE_RESTORE_OBCS
    and update local AUTODIFF_OPTIONS.h files from verification experiments.
  - experiment specific setting:
    * define AUTODIFF_EXCLUDE_ADEXCH_RS in exp.: hs94.1x64x5, obcs_ctrl & OpenAD
    * increase "nWH" value in local MDSIO_BUFF_WH.h for exp.:
      global_oce_biogeo_bling, offline_exf_seaice & tutorial_dic_adjoffline
  - add a TAF "INCOMPLETE" directive for TICES and wVel to avoid a TAF bug.
  - fix a TAF store directive to avoid extra call of "load_fields_driver"
    with EXF_SEAICE_FRACTION defined.
o pkg/gmredi:
  - rename S/R, CPP option (GM_BATES_K3D), on/off switch (GM_useBatesK3d),
    parameters (GM_Bates_*) and 3-D var (GM_BatesK3d) of Bates etal (JPO, 2014)
    scheme that computes 3-D field GM/Redi diffusivity (analog to Visbeck etal
    variable/option naming example).

checkpoint68f (2022/01/14)
o pkg/exf:
  - clean-up relative wind implementation so that uwind and vwind are kept
    unchanged (always vanilla atmospheric winds after interpolation) while
    relative wind is computed locally; add diagnostics for relative wind.
  - adjust pkg/seaice relative-wind code (+ clean-up SEAICE_GREASE code).
o pkg/kpp:
  - avoid updating input argument "kmtj" in S/R BLDEPTH (in: kpp_routines.F);
    this also remove/avoid 3 recomputation warnings for kmtj in adm (TAF) built.
o pkg/streamice:
  - fix regularised coulomb basal stress impl to avoid issues with adjoint ;
  - cancel metric terms in stress tensor for cartesian grid ;
  - allow (time-indep) velocities to be imposed from external file rather than
    solved for ;
  - allow for specification of log of controls as well as sqrt ;
  - allow termination of adjoint fixed point loop based on relative and absolute
    error ;
  - terminate adjoint fixed point loop when change between most recent iterates
    begins to increase (a sign of unstable growth from linear solve errors ?);
    update OAD output of exp. halfpipe_streamice (affected by this modif).
o pkg/seaice:
  - replace hard-coded parameters for JNKF line search by new runtime parameters
    SEAICE_JFNK_lsGamma and SEAICE_JFNK_lsLmax ;
  - increment line search counter after reporting and fix an if statement, so
    that zeroth step is not counted for more consistent debugging output.
o tools/build_options:
  - update pleiades optfile "linux_amd64_ifort+mpi_ice_nas"
  - rename/update optfile for UK HPC Archer2.
o pkgs:
  - remove/avoid unused variables from AD verification exp. built except from
    halfpipe_streamice (pkg/streamice); also clean-up a bit pkg/smooth.
o pkg/autodiff:
  - introduce separate tapes for integer arrays: the corresponding routines
    just convert between integer and double precision arrays and call the
    original adread/adwrite routines.
o pkg/atm_compon_interf:
  - only with Atm-Phys pkg, allow "regional coupling", i.e. coupled only where
    there is ocean, keeping Atm-Phys basic mixed-layer elsewhere.

checkpoint68e (2021/12/10)
o lsopt & optim:
  - update Makefiles and README.
o pkg/ctrl:
  - remove unused flag ALLOW_ECCO_OPTIMIZATION and associated code, always save
    "fcloc" to gradient vector file and save fcloc=0 to initial ctrl vector file
    (which is never used); also remove it from any code*/CTRL_OPTIONS.h.
o pkg/ctrl:
  - replace few calls to MDS_READ/WRITE_FIELD with corresponding call to
    pkg/rw READ/WRITE_REC_3D_RL ; also clean-up: ctrl_map_ini_gen.F
o tape related code (adjoint):
  - clean-up tape code in the init-phase, mainly in the_main_loop.F and in
    ctrl_map_ini_gentim2d.F ;
  - remove unused (ecco) cost_averages_bar_directives.h ;
  - adjust comments in (autodiff) adread_adwrite.F & in main_do_loop.F
o eesupp:
  - fix scratch file names when using PDAF.
o pkg/exf:
  - fix issue in interannual monthly forcing addition (case ${fld}period=0)
o model/src:
  - skip reading kapGM and kapRedi from ini_mixing.F when useGMRedi is .FALSE.
o pkg/exf:
  - add option for interannual monthly forcing with pkg/cal by setting
    ${fld}_period=-1. (like -12. indicates climatological monthly forcing),
    available with or without useExfYearlyFields ; update exp. global_with_exf
    SST forcing to test this new option with and without useExfYearlyFields.
o model/src:
  - define local arrays cg2d_q/v/z without overlaps in all 4 cg2d*.F
    and skip initialisation of cg2d_q in cg2d.F
o tools/genmake2:
  - new option to call OpenAD compiler in a singularity container (if provided);
    add option to testreport too and update OpenAD doc (in section 7.5).

checkpoint68d (2021/11/05)
o verification/*/results:
  - update few adm and tlm refence output to get closer agreement.
o verification/global_ocean.90x40x15:
  - no longer use old bug (fixed in Oct 2015) in KAPGM_CONTROL & KAPREDI_CONTROL
    code and update AD & TL ref. output for kapgm & kapredi tests ;
  - other small cleaning: finish removing OLD_THSICE_CALL_SEQUENCE code ; remove
    "cost_yftype" from experiments "data.ecco" ; move ALLOW_ECCO_OPTIMIZATION
    to the right header file.
o pkgs pp81, my82, opps & ggl90:
  - remove pkg/timeave and pkg/mnc output from these mixing packages (since
    this functionality is available with pkg diagnostics); add 1 diagnostics
    to pkg/opps (to replave TAVE output).
o tools/build_options:
  - add "-DAUTODIFF_USE_MDSFINDUNITS -DPROFILES_USE_MDSFINDUNITS" to DEFINES
    in g77 optfile ; this allows to run set-up with AUTODIFF_WHTAPEIO and/or
    with pkg/profiles using g77 (with S/R MDSFINDUNITS) while other compilers
    continue to use local version with extended range of I/O units number.
o pkg/ecco:
  - fix halo initialisation for argument "active_var" in cost_genread.F ;
  - change "facNum" expression in cost_gencost_transp.F, to be consistent with
    comment in src code, by adding missing factor "nSx"; also avoid division
    in PARAMETER statement.
o model/inc:
  - move potentially time dependent grid variable from GRID_RS to new common
    block GRID_VAR_RS (hFacW/S/W, etc.) and split common block CG2D_I_R into
    a _RL and a _RS part ; adjust AD common block accordingly.
o verification AD experiments:
  Update TAF AD exp. so that none relies anymore on ECCO_CTRL_DEPRECATED code:
  - remove #define ECCO_CTRL_DEPRECATED from experiments: 1D_ocean_ice_column,
    bottom_ctrl_5x5, global_with_exf, lab_sea, OpenAD, tutorial_dic_adjoffline,
    tutorial_global_oce_biogeo & tutorial_global_oce_optim ; use instead generic
    control and generic cost.
  - for now, keep experiment global_ocean.cs32x15 with both ECCO_CTRL_DEPRECATED
    code and generic control + generic cost.
  - also remove ECCO_CPPOPTIONS.h (use instead set of pkg specific OPTIONS
    header files) from these experiments above.
  - results unchanged except few digits in cost & ad-monitor for lab_sea &
    obcs_ctrl ; and few minor recomp. warnings count changes for
    tutorial_global_oce_biogeo (-4) and for tutorial_dic_adjoffline (+2).
  Update pkgs as needed:
  - pkg/ecco: fix field declarations for ecco_toolbox routines and cost_readgen,
    new toolbox routines ecco_offset, ecco_maskmindepth, make argument lists
    more consistent between ecco_toolbox routines and remove unused subroutines;
  - pkg/cost: fix ALLOW_COST_DEPTH contribution;
  - pkg/ctrl: add more "ifdef ECCO_CTRL_DEPRECATED" where necessary;
  - pkg/exf: add xx_snowprecip as generic control, adjust CPP-flags.
o pkg/gmredi:
  - remove condition (ifdef GM_NON_UNITY_DIAGONAL) around 3-D arrays Kux & Kvy
    to simplify how GMREDI is applied (e.g., gmredi_x/ytransport); fill up these
    2 arrays with constant value (gmredi_calc_tensor.F & offline_get_diffus.F)
    when GM_NON_UNITY_DIAGONAL is undef (to reproduce old results).
  - also with GM_NON_UNITY_DIAGONAL undef, fix ALLOW_KAPREDI_CONTROL averaging.
o tangent-linear:
  - fix few hand-written tangent-linear src code (in autodiff & ctrl pkgs);
  - add new target "ftlobj" to Makefile (similar to "obj" & "adobj" for forward
    and AD built) and corresponding switch in testreport ;
  - fix non-standard sed command (for Mac) in TLM testreport.

checkpoint68c (2021/10/02)
o pkg/seaice:
  - update some dynamics solver default so that now:
    a) SEAICEuseEVPstar = .TRUE. ; b) SEAICEuseEVPrev = .TRUE. ;
    c) LSR_ERROR = 1.e-5 (previously was 1.e-4) ;
  - put back old default in exp. lab_sea (primary test);
  - modify (simplify?) logic in seaice_readparms.F and seaice_check.F.
o pkg/grdchk:
  - allow to use "recglo" to specify a particular control time record for
    gradient check (was previously inactive).
o pkg/exf:
  - new parameters to reduce AD-exf monitor output:
    1) exf_adjMonFreq (def= adjMonitorFreq), = 0. suppresses all output
    2) exf_adjMonSelect: =1 (def): less output ; =3 as before, =0 : no output
  - fix some AD-common block name + content to match TAF directives (in
    common.flow) and TAF generated code.
  - skip monitor of model forcing AD-variables (unless monitorSelect=4).
o pkg/ecco + other:
  - fix few non-standard syntax (+ repeated setting of "gencost_msk_is3d").
o pkg/bling:
  - fix call to S/R BLING_BIO_NITROGEN when USE_SIBLING is defined.
o pkg/ecco:
  - put various dimensions related to gencost out of "ecco.h" into specific
    (new) header file "ECCO_SIZE.h" and rename "ecco.h" to "ECCO.h" ;
  - add gencost param "gencost_kLev_select" to select a vertical level (from 3-D
    array) to form 2-D gencost ; currently only used in drifter velocity cost ;
  - add a couple of costs based on 1) inverse barometer (IB) corrected model sea
    level for altimetry data comparison 2) OBP excluding contribution from
    global mean atmospheric pressure for comparisons with GRACE data.
o pkg/autodiff:
  - fix type (_RS vs_RL) of AD-vars in hand-written AD routine cg2d_mad.F and
    in adcommon.h, common block adgrid_rs.
o model/src:
  - fix missing initialisation of local working arrays that were previously
    in common block in CG2D.h (needed when using blank tiles).
o pkg/dic:
  - fix calculation of carbonate saturation state (with CAR_DISS defined) when
    #define CARBONCHEM_SOLVESAPHE ; no current test run with #define CAR_DISS.
o pkg/autodiff:
  - add code for Full-Adjoint of cg2d in renamed (from cg2d_sad.F) routine
    cg2d_mad.F (cg2d manual adjoint) ;
  - new runtime params cg2dFullAdjoint (data.autodiff), useNSACGSolver (data,
    default to "FALSE"), cg2dMinItersNSA (data, defaults to 0) ;
  - new sub-verification experiment bottom_ctrl_5x5.facg2d to test new
    Full-Adjoint capability ;
  - update primary test experiment bottom_ctrl_5x5 to always use a minimum
    number of 10 CG2D iterations (changes results but improves accuracy) ;
  - modify AD-experiment global_ocean.90x40x15.bottomdrag to use full nonlinear
    free surface (nonlinFreeSurf=4) and cg2dFullAdjoint=True.
  - move CG2D working arrays out of CG2D.h common blocks (not necessary)
    to local arrays within each cg2d S/R.

checkpoint68b (2021/08/24)
o pkg/ecco:
  - add time-series output of global mean steric height change at each time step
    (variable: sterGloH, with #define ALLOW_PSBAR_STERIC) ; turned on
    with run-time switch "ecco_output_sterGloH=T" ; add option to keep file open
    (+ single meta file writing) with "ecco_keepTSeriesOutp_open=T" switch.
o pkg/ggl90:
  - fix EXCH calls in pkg/ggl90 when IDEMIX is used: no additional EXCH when
    using zero horizontal diffusion of IDEMIX_E (IDEMIX_tau_h=0) but with
    IDEMIX_tau_h > 0, EXCH both IDEMIX_E and GGL90TKE ; this affects results
    of test experiment cs32.in_p and fix restart issue ;
  - more consistent/simpler idemix code: use model parameter value for PI,
    reduce number of IDEMIX global array, add TKE tendency from IDEMIX as output
    of S/R GGL90_IDEMIX ; use double product of IDEMIX_E instead of power of 2
    which affects results at machine truncation level ;
  - update some IDEMIX default param values (following Pollmann et al., 2017)
    but keep old default values in global_ocean.90x40x15.idemix ;
  - apply also option calcMeanVertShear to uStarSquare calculation (wind-stress
    magnitude) and switch on calcMeanVertShear in test experiment cs32.in_p.
o model/src + pkgs ggl90, exf & seaice: ocean in P-coordinate
  - read geopotential anomaly directly into phi0surf instead of via pLoad (was
    a hack), specified with new input filename "geoPotAnomFile" in data&PARM05 ;
  - adjust MXLDEPTH diagnostic for pressure coordinates ; make sure sigmaR is
    computed the same way in P-coord as it is in Z-coord.
  - for penetrating Short-wave and geothermal heating as well as for exf forcing
    and seaice, use the correct P-coord vertical index for bottom and surface ;
  - add a flag sIceLoadFac (in "data", default=1.) to be able to turn off
    seaice surface pressure loading, mainly for Z-coord (since not currently
    supported in P-coord) ;
  - use diagnostics "phiHydLow" for seaice dynamics with P-coord ocean to get
    surface tilt term (instead of using ETAN as in Z-coord); fix restart by
    adding phiHydLow (only if useSEAICE and usingPCoords) to main pickup file ;
  - in pkg/ggl90, apply simple scaling to get mixing-length in meters (from
    pressure) so that no parameter changes are necessary ; significant code
    changes regarding surface & bottom index + direction of vertical k loop ;
  - add secondary test "in_p" to experiment global_ocean.cs32x15 (similar to
    Z-coord secondary test "seaice" but using pkg/ggl90 and without pkg/gmredi).
o tutorial_reentrant_channel:
  - add python notebook (for analysis), add python script to generate input
    files (+ update matlab version) and update this tutorial docs.
o verification/vermix:
  - change ggl90 secondary test to use (pkg/ggl90) mxlMaxFlag=3 (instead of 2)
    and update reference output.
o pkg/ctrl:
  - move S/R CTRL_MAP_GENARR2D/3D out of file "ctrl_map_ini_genarr.F" into
    a new file "ctrl_map_genarr.F" ;
  - clean-up local versions of ctrl_map_gentim2d.F and ctrl_map_ini_genarr.F
    from code_ad dirs (i.e., minimize diff with standard version from pkg/ctrl).
o model/src:
  - improve REMOVE_MEAN_RL/RS subroutines (address issues raised in issue #501)
    including results independent of tile to proc mapping, correction extended
    to overlap regions, improve accuracy of _RS version when RS is real*4 and
    and enable the use 2-D mask maskInC/W/S when applied to 3-D array. Change
    argument list (add myIter, flip order + change mask arg from 3-D to 2-D).
o verification/global_ocean.90x40x15:
  - increase "grdchk_eps" from 1e-7 to 10 in AD test kapgm to improve
    accuracy of FD gradients ; update reference output.
o verification/OpenAD:
  - add ggl90 pkg to code_ad/packages.conf to get it tested in one TAF-AD exp.
o doc:
  - require sphinxcontrib-bibtex 2.0.0 or higher

checkpoint68a (2021/07/16)
o pkg/seaice:
  - clean up and simplify TAF store directives in do_oceanic_phys.F
    for seaice_model to avoid unnecessary recomputations ;
  - in testreport, count and report number of times s/r seaice_model is called.
o pkg/seaice:
  - fix (untested) multi-threading and recomputations in seaice_solve4temp.F
o files that include "tamc.h":
  - add missing declaration of local keys for TAF store-dir in pkg/obcs
    (ALLOW_OBCS_STEVENS) and pkg/bling (USE_BLING_V1, PHYTO_SELF_SHADING) ;
  - add missing AUTODIFF_OPTIONS.h in few places (e.g., in pkg/ebm), needed to
    get ALLOW_AUTODIFF_TAMC defined ;
  - change few ALLOW_AUTODIFF <-> ALLOW_AUTODIFF_TAMC ;
  - remove included "tamc.h" in few files from pkgs seaice, streamice, bling, +
    in exf_radiation, longstep_thermodynamics, obcs_sponge & pp81_ri_number S/R.
  - define ALLOW_OBCS_STEVENS in AD exp. obcs_ctrl (to check it compiles).
o pkg/ecco:
  - fix incorrect order of array indices for "objf_gencost" and "num_gencost"
    in 2 gencost v4 S/R (bpv4 & sstv4).
o eessup/inc & pkg/thsice:
  - Remove 2 CPP options for deprecated code and remove corresponding code:
    a) USE_OLD_MACROS_R4R8toRSRL (added in May 2009) and
    b) OLD_THSICE_CALL_SEQUENCE  (added in Jan 2013).
o pkg/shelfice:
  - fix missing local keys declaration in shelfice_thermodynamics.F for TAF
    storge dir. with SHI_ALLOW_GAMMAFRICT defined ;
  - remove included PACKAGES_CONFIG.h in many verification exp. "tamc.h".
o tools/build_options:
  - update gfortran optfile for MacBook Pro "darwin_amd64_gfortran" to work with
    gfortran version 10 (or higher), similar to linux version update.
o pkg/ctrl & other:
  - cleanup: move declarations of local variables from header files ctrl.h and
    AUTODIFF.h to the local variables section in the respective routines ;
  - move declaration of local keys and variables from header file tamc.h to
    subroutines where they are used.
  ==> IMPORTANT: This requires updating all customised versions of "tamc.h",
    from each and every TAF-AD setup.
  - remove tamc_keys.h + remove tamc (+tamc_keys) from all "cb2mFiles" lists ;
  - disentangle ALLOW_AUTODIFF/ALLOW_AUTODIFF_TAMC/ALLOW_OPENAD a bit more ;
  - remove unused variables where this is straightforward ;
  - remove a few i/jmin/max variables.

checkpoint67z (2021/06/12)
o veritication:
  - make testreport count and report the number calls of S/R load_fields_driver
    and do_oceanic_phys in AD-code (similar to TAF error & warning count).
o pkg/kpp:
  - add CPP-flags to turn off diffusivity matching at bottom of boundary layer ;
  - add CPP-flag to turn on taper shear mixing in the case of very small shear ;
  - add FLAG to turn on smooth regularisation of divisions by small numbers:
      1/(var+eps) instead of 1/MAX(var,eps) ;
  - fix a small masking error ;
  - fix some unfortunate loop ordering and spurious recomputations ;
  - add new diagnostics KPPshsq, KPPdVsq ;
  - update exp. vermix (which has KPP_ESTIMATE_UREF defined) reference output.
o model/src:
  - in the main code, add option and code for sound speed calculation with
    corresponding diagnostics ; turned on in exp. global_oce_biogeo_bling.
o model/src:
  - fix few loop range to allow to run with OLx,y=1 when momStepping=F ;
  - add check and stop if momStepping=T and overlap-size is smaller than 2.
o pkg/ggl90:
  - add 3 store directives for gg90tke in ggl90_calc.F and break some loops
    in two to help TAF without extra storage requirements.
o pkg/seaice:
  - adjust store directives in seaice_growth_adx.F:
    *) add store directives to avoid calling seaice_solve4temp in AD-mode
    *) adjust/remove/reorganise for good balance between storing and recomputing
    *) fix a small bug (full 4D arrays were stored instead of 2D for each bi,bj)
    *) local option "SEAICE_GROWTH_ADX_STORE_MORE" (not recommended)
       reduces the recomputations but increases the memory requirements.
  - update ref. AD output of experiment offline_exf_seaice (the only one using
    SEAICE_GROWTH_ADX): no Grad-Check changes but differences in AD-Monitor.
o pkg/ctrl & pkg/shelfice:
  - generalize masking procedure for control parameters, fixes procedure for
    ice-shelf controls ;
  - add ability to control base 10 logarithm in generic control arrays ;
  - add shiTransCoeffT, shiTransCoeffS, and shiCDrag as control variables ;
  - add ability to compute shelfice freshwater and heat fluxes through ecco
    package.
o store directives (model/src, pkg/exf, ...):
  - By adding many store directives for variables after they have been computed
    the corresponding s/r load_fields_driver, oceanic_phys, solve_for_pressure
    no longer need to be called in the AD-routine forward_step_ad.
    A as a consequence the forward part of forward_step is not recomputed,
    and there are far fewer store statements in the AD-code.
  - Most of the new store directives and many of the old ones are collected in
    two new files "check_lev1_dir_forcing.h" and "check_lev1_dir_ocephys.h" to
    avoid clutter in forward_step.F
  - More store directives in pkg/exf allow it to store the forcing fields
    instead of the level0/1 (e.g. aqh instead of aqh0 and aqh1), thereby
    reducing the number of stored exf-forcing variables by about two. This is
    also necessary to avoid calling load_fields_driver from forward_step_ad.
  - Additional small tweaks of store directives in forward_step.F have the
    effect that the recomputations are kept to a minimum in all of the AD
    verification experiments (and in verification_other/global_oce_[llc/cs32])
    and calling potentially expensive forward routines are not called (e.g.
    do_stagger_fields_exchange, which involves unnecessary exchanges).
  - Remove storage of gchemTendency in all checkpoint levels.
  - Results unaffected except if using real*4 storage (isbyte=4, e.g., in
    offline_exf_seaice, small changes in AD-monitor).

checkpoint67y (2021/05/05)
o pkg/shelfice:
  - Update kTopC when using SHELFICEMassStepping if ice-shelf retreat completely
    from one column or advance to cover new grid-cell ; add 4 levels TAF storage
    of kTopC (to prevent major recomputations).
  - Also prevent ice-shelf mass to become negative.
o pkg/mom_common & gmredi:
  - Adjust Smag and Leith code for use in Adjoint:
    a) protect against derivative of SQRT(0) in mom_calc_visc.F and
       gmredi_calc_qgleith.F ;
    b) add GM-Redi QG Leith routines to ad_diff lists.
o pkg/gmredi:
  - fix/remove 2 TAF recomputations in GMREDI_WITH_STABLE_ADJOINT code.
o pkg/generic_advdiff:
  - improve "slope" calculation in DST2 Flux-Limiter advection scheme to avoid
    potential over-flow arithmetic in division by small slope (issue #459),
    similar to what has been done in gad_dst3fl_*.F routines.
o pkg/diagnostics:
  - use Integer*8 conversion in diagnostics_out.F to get time-record to write
    in meta file (avoid integer overflow with large time & small diag-freq).
o pkg/mom_common:
  - initialise again hdiv in mom_calc_hdiv.F (in case it got dropped by TAF in
    calling S/R).
o model/src:
  - fix a bug in convective_adjustment.F AD code by adjusting store directives
    for theta and salt ; update experiment isomip reference AD output.
  - a little bit of cleanup: remove unnecessary store directives and options.
o pkg/shelfice:
  - change expression of pLoc in shelfice_thermodynamics.F to be simply the
    weight of the ice-shelf (= shelficeMass * gravity) replacing inaccurate
    estimate from "R_shelfIce". Add TAF directive storage of  prognostic
    variable "shelficeMass" in all 4 checkpointing levels. Update all reference
    output of experiments that use pkg/shelfice (isomip & shelfice_2d_remesh)
o verification/testreport
  - add ad-monitor of 3-D state variables to testreport summary output
o pkg/ggl90:
  - avoid division by zero in adjoint of S/R GGL90_CALC (sqrt related)

checkpoint67x (2021/04/12)
o pkg/seaice:
  - Addition to the sea ice package of 6 sea ice rheologies with different yield
    curves and flow rules ;
  - Add 4 new verification tests in offline_exf_seaice using new rheologies ;
  - Update documentation with description of new rheologies and how to use them.
o model, pkg & doc:
  - replace all occurrences of incorrect "psu" and "PSU" by "g/kg" in units and
    comments ; update the documentation accordingly.
o pkg/ctrl:
  - move to pkg/ctrl the local copy of ctrl_map_ini_genarr.F from verification/
    global_oce_biogeo_bling/code_ad/ with ptracers generic control. Improve for
    general number of ptracers control.
  - add missing diagnostics fill for diagnostics 'Um_ImplD' & 'Vm_ImplD' in
    impldiff.F (otherwise not filled when pkg/autodiff is compiled).
o pkg/autodiff:
  Include TICES of pkg/seaice into StoreSEAICE:
  - split AUTODIFF.h into two to be able to use nITD in the new AUTODIFF_STORE.h
  - rearrange and cleanup declarations, add CPP flags ALLOW_SEAICE/OBCS/EXF ;
  - clean up seaice section of autodiff_store/restore.F to remove unused storage
    space ;
  - changes AD results of global_ocean.cs32x15.seaice & seaice_dynmix, lab_sea &
    lab_sea.noseaicedyn => output_adm updated.
o model/src:
  - make sure the 3 recip_hFac{C,W,S} are reset after resetting the 3 hFac
    in ini_nlfs_vars.F when using Non-Lin FreeSurf with pkg/autodiff compiled
    (#define ALLOW_AUTODIFF): this fix problems in gradient-check if recip_hFac
    is used, e.g., in one {PKG}_INIT_VARIA S/R.
o pkg/autodiff & diagnostics:
  - Add interface routines to write to binary file and fill diagnostics of
    single (or pair) of Adjoint variable.
  - Rewrite addummy_in_stepping.F using set of new interface S/R to make it
    more compact and easier to add new control variables.
  - Add all current adjoint variables in addummy_in_stepping, ptracers_ad_dump,
    seaice_ad_dump & exf_adjoint_snapshots_ad to work with diagnostics package.
  - turn on Adjoint-variable diagnostics in adjoint verification experiments:
    *) global_oce_biogeo_bling (with ptracers AD-var diagnostics) and
    *) global_ocean.cs32x15.seaice (with seaice and exf AD-var diagnostics).
o model/src + pkg/mom_common:
  Fix AB time-stepping of QuasiHydrostatic with staggerTimeStep.
  - involves new CPP option "ALLOW_QHYD_STAGGER_TS" for storage of previous
    time-step Quasi-Hydro tendency to enable AB extrapolation in time when
    using staggerTimeStep.
  - field added to pickup file for restart ; allows to restart (but not perfect
    restart) if field is missing and pickupStrictlyMatch=F.
  - switch to staggerTimeStep=T in experiment "global_ocean.90x40x15.dwnslp"
    that uses QuasiHydrostatic to test this code; update corresponding output
    (as well as primary test output due to machine truncation).
o verification:
  In experiments: global_ocean.cs32x15, isomip, obcs_ctrl and offline_exf_seaice
    replace CPP flag ECCO_CTRL_DEPRECATED by the much nicer generic control
    variables GENARR/GENTIM2D variant.
    Also replace ECCO_CPPOPTIONS.h by CTRL/AUTODIFF/COST/ECCO_OPTIONS.h files.
  This required a number of changes to the general code to make the generic
    control variables work in a non-ecco context:
  - pkg/thsice: add AUTODIFF_OPTIONS.h and COST_OPTIONS.h header files to
    numerous routines ;
  - pkg/seaice: mask tendencies of HEFF/AREA/HSNOW in seaice_growth_adx.F to
    reproduce cost function values ;
  - pkg/shelfice: enable GENARR/GENTIM2D methods ;
  - pkg/obcs: move reading control variable out of S/R obcs_prescribe_read into
    S/R obcs_calc to be independent of parameter values unrelated to the
    adjoint ;
  - pkg/ctrl: make generic control variable work without pkg/cal (works only for
    time independent control variables), but issue a warning, bonus: make
    ctrlprec a runtime parameter that defaults to 64 ;
  - pkg/ctrl: fix flow directives for S/R ctrl_bound_2d/3d and add tangent
    linear versions of these subroutines ;
  - pkg/ecco: reorder CPP flags in ecco_cost_weights.F and remove unused
    variable 'wbaro', move calling S/R cost_obcs out of ECCO_CTRL_DEPRECATED
    code block in S/R ecco_cost_driver, reorganise CPP flags in
    cost_averagesinit.F, include CTRL_OPTIONS.h wherever ECCO_OPTIONS.h is
    included, because ECCO_CTRL_DEPRECATED is now set in CTRL_OPTIONS.h ;
  - model/src/the_main_loop.F: fix tape initialisation, bonus: suppress a
    benign warning ;
  - for each of the verification experiments remove ECCO_CPPOPTIONS.h and
    replace by CTRL_OPTIONS.h, CTRL_SIZE.h, sometimes COST/ECCO_OPTIONS.h,
    EXF_OPTIONS.h, adjust data.ctrl, data.grdchk, data.ecco ;
  - for global_ocean.cs32x15 compile both variants by keeping
    ECCO_CTRL_DEPRECATED in CTRL_OPTIONS.h and use runtime parameter ctrlUseGen
    to switch between methods (in global_ocean.cs32x15.thsice). This involves an
    extra (benign) recomputation warning in this verification experiment because
    of an if statement with ctrlUseGen in ctrl_init_variables.F

checkpoint67w (2021/03/06)
o verification/global_ocean.cs32x15:
  - fix Adjoint set-up by turning off CPP option "ALLOW_AUTODIFF_INIT_OLD" (that
    was intended to put back an old bug) and update all 4 ADM and all 4 TLM
    reference output files.
o pkg/exf:
  - replace wrong CPP option EXF_SALTFLX with ALLOW_SALTFLX in exf_monitor.F.
o model/src:
  - Output dxF, dyF, dxV, and dyU fields to mdsio grid output files.
o tools/build_options:
  - improve intel optfile for engaging (linux_amd64_ifort+impi_engaging).
o pkg/autodiff:
  - Improve, extend & clean-up switch to a simpler advection-scheme in AD-Mode
    with new parameter "useApproxAdvectionInAdMode to replace inAdMode:
    * If useApproxAdvectionInAdMode is True and advection scheme is set to 33
      use advection scheme 30 in AD-model in seaice_advection, gad_advection
      and gad_calc_rsh ; model stops when parameters are set inconsistently.
    * Defaults to False, but is reset to True if inAdExact = False to be
      backwards compatible.
  - Important change in the meaning of variable inAdMode: now it is always true
    after calling S/R AUTODIFF_INADMODE_SET_AD and always false after calling
    S/R AUTODIFF_INADMODE_UNSET_AD.
    The non-intuitive flags inAdTrue and inAdFalse, which could be T or F, have
    been removed from the code.
  - Remove unnecessary TAF related and inAdMode code from seaice_lsr.F, remove
    SOLV_MAX_TMP in LSR S/R and adjust SEAICElinearIterMax default accordingly.
  - Change AD exp. global_ocean.cs32x15.seaice to test this new functionality;
    gradient checks necessarily are poorer because AD advection is approximated.
o tools/build_options:
  - update standard optfile "linux_amd64_gfortran" to enable to be used with
    gfortran version 10 (or higher); update comments and clean-up for missing
    "nf-config".
o model/src & pkg/generic_advdiff:
  - Implement simple isotropic 3D Smagorinsky diffusivity:
    Smag diffusivity is assumed to be linearly dependent on 3D Smag viscosity
    (just scaled by inverse of a constant Prandtl number); setting involves:
     a) CPP Option: ALLOW_SMAG_3D_DIFFUSIVITY in CPP_OPTIONS.h (def. #undef)
     b) switching on 3D Smagorinsky by setting "useSmag3D = .TRUE." in first
        namelist of main parameter file "data" ; and, in the same namelist,
     c) setting smag coeff. "smag3D_diffCoeff" for diffusivity (similar to
     smag coeff. "smag3D_coeff" for viscosity), which results in constant
     Prandtl number = smag3D_coeff/smag3D_diffCoeff.
    Note: Since Smag3D_diffK is lagging by 1 time-step, needs to be stored
    in pickup files (for restart) when using synchronous time-stepping.
  - code is compiled in experiment tutorial_deep_convection and ready to use
    except smag3D_diffCoeff setting in input.smag3d/data is commented out.
  - also add few missing initialisations in "ini_dynvars.F" (just for
    consistency with coding practice but no practical side effect).
o pkg/ecco:
  - fix type of argument in S/R MDS_READVEC_LOC call inside cost_gencost_moc.F
o verification/lab_sea:
  - change lab_sea.hb87 from testing EVP to testing aEVP with some sensible
    parameters ; update reference output "output.hb87.txt"
o pkg/ecco:
  - Addition of meridional streamfunction maximum (MOC) as objective function
     within ecco/gencost code ;
  - MOC objective function tested in verification_other/global_oce_cs32.sens ;
  - allows to compute sensitivity to hflux/sflux with prescribed atmospheric
    state (not fluxes) with new flags CALC_HFLUX_SENS and CALC_SFLUX_SENS.

checkpoint67v (2021/02/03)
o tools/build_options:
  - add optfile for engaging similar to linux_amd64_ifort+impi but with -xAVX
o pkg/seaice:
  - move store directives of uice/vice to after calling S/R SEAICE_DYNSOLVER to
    avoid calling this routine in S/R seaice_model_ad which may trigger
    potential recomputation problems (e.g., with non-exact AD) ;
  - move if statement inside S/R SEAICE_BOTTOMDRAG_COEFFS : this enables to
    remove storage of "CbotC" without triggering recomputations ; compile this
    code in the AD-experiments of global_ocean.cs32x15 ;
  - remove unnecessary store directives related to pkg/seaice ;
  - fix/extend diagnostic "SIenph  " to work with all parameter configurations.
o pkg/autodiff: fix/improve viscFacAdj
  - fix treatment of viscFacAdj in mom_vecinv.F by removing storage of 2D
    viscosities if new flag AUTODIFF_ALLOW_VISCFACADJ is defined ;
  - add a runtime parameter "viscFacInFw" in autodiff_inadmode_unset_ad.F to
    replace hard-coded one ;
  - apply viscFacAdj to both viscAh/4_D and _Z ;
  - test compiling this code in tutorial_global_oce_optim.
o model/src:
  - move if statement out of i/j-loops in solve_tridiagnoal/pentadiagonal.F:
    *) this reduces TAF recomputation warnings by 4 ;
    *) potentially easier to optimise/vectorise for some compilers.
o tools/build_options:
  - adjust floating point options in: linux_ia64_ifort_ollie:
o pkg/ctrl:
  - fix two bugs related to writing and reading control variables and
    corresponding gradients:
   a) replace too large loop range endrec by diffrec in ctrl_map_ini_gentim2d.F;
   b) skip writing meta-files in REVERSE_SIMULATION mode (active_file_control.F)

checkpoint67u (2020/12/30)
o utils/python/MITgcmutils
  - add code to compute horizontal divergence of a vector field, gradient of a
    scalar field, and averages to c-points on an llc grid.
o pkg/seaice:
  - fix bug in seaice_lsr, spotted by Martin Vancoppenolle, that lead to solving
    stationary momentum equations (du/dt -> 0) for SEAICEnonLinIterMax>2 ;
  - fix minor bug in seaice_bottomdrag_coeffs.F: replace OLy with correct OLx ;
  - changing ordering of addition (to FORCEX,FORCEY) in seaice_lsr.F results in
    output differences at machine truncation level: update referece output of
    several experiments that use LSR solver.
o pkg/autodiff: fix flow directives for self-adjoint cg2d
  - new self-adjoint cg2d routine cg2d_sad.F mimics AD-code, but neglects
    (purposefully) the proper sensitivity propagation
  - extra storage of cg2d solver coefficients and preconditioner is required
  - change 2 AD-verification experments (global_ocean.cs32x15 and
    global_ocean.cs32x15.seaice) to test this code a little better:
    use full NLFS and nchklev_1 = 2

checkpoint67t (2020/11/30)
o pkg/kpp:
  - with CPP-option KPP_ESTIMATE_UREF, fix compilation errors + fix mixed layer
    depth determination ;
  - define KPP_ESTIMATE_UREF in verification/vermix ;
  - a little bit of cleanup.
o pkg/seaice:
  - small modifications of seaice_growth_adx.F to avoid recomputation warnings
    and to avoid potentially inefficient code ;
  - remove duplicate version of seaice_solve4temp ;
  - exclude code of seaice_growth.F if ALLOW_SEAICE_GROWTH_ADX defined ;
  - switch on SEAICE_USE_GROWTH_ADX AD in experiment offline_exf_seaice and
    update "output_adm.txt".
o eesupp/src:
  - add missing "stdio.h" in src code setdir.c
o tools/do_tst_2+2 & tst_2+2:
  - bug fix: replace some non-standard sed command with POSIX compatible syntax
  - remove second blank at beginning of 2 new lines in file "data".
o doc:
  - add new SO channel tutorial
  - update pkg/shelfice documentation
o optim:
  - fix a small bug by initialising myX/YglobalLo=1 in optim_nummod.F
o tools/do_tst_2+2:
  - for sending restart test output, add same hack in "send" option as in
    testreport, allowing to use "scp" (instead of an email).
o model/src:
  - fix 2 missing TAF initialisation directives in file "the_main_loop.F";
    this allows to use TAF recent version 5.0.9 (that does check for missing
    initialisation).
o pkg/seaice:
  - fix diagnostics additions (from PR #348) for case _RS is real*4.

checkpoint67s (2020/07/30)
o eesupp/src:
  - Improve formatting of output for large grids and many processors:
    adjust formats to actual length of nPx*nPy or Nx and Ny but
    keep minimal lengths to avoid changing the format for smaller domains;
  - also increase number of digits for printing tile & proc number in pkg/exch2
    log files and report to STDOUT.
o pkg/bling:
  - cleaning: remove USE_QSW_Z code ;
  - few more CPP options (NEW_FRAC_EXP & SIZE_DEP_LIM defined, SIZE_NUT_LIM
    undef) related to phytoplankton size and sinking organic matter ;
  - fix tiled TAF storage directives (were not right for multi-tile per proc);
    update ADM reference output of experiment global_oce_biogeo_bling (now
    gradient check are identical whether run on 1 proc - 4 tiles or 4 procs
    1 tile each).
o pkg/seaice:
  - Replace hard-coded minimum for DWATN by runtime parameter "SEAICEdWatMin":
    * allows to have zero drag by setting both SEAICEdWatMin and
      SEAICE_waterDrag to zero. Non-zero drag had been implemented because
      previous LSR solver could not handle zero entries on the main diagonal.
    * this fixes a bug (unexpected behavior) reported at MITgcm-support by
      Kaley Shrestha, but also allows to modify the somewhat arbitrary
      default minimum value of SEAICEdWatMin = 0.25 ;
    * freedrift code still requires non-zero drag coefficients,
      S/R SEAICE_CHECK catches this case.
o verification/*/packages.conf
  - Cleaning verification experiment "packages.conf":
    1) add a 1 line description at the top
    2) use pkg group "adjoint" in some experiments
    3) use similar ordering of pkgs in packages.conf:
      a) eesupp pkgs (e.g., exch2, coupler-pkgs)
      b) dyn-core pkgs (e.g., gfd pkgs, mom pkgs, cd_code, gad, obcs ...)
      c) SGS-scheme (+ atm physics) pkgs (filters, gmredi, vert.mixing ...)
      d) forcing pkgs (e.g., rbcs, exf, cal, ebm, cheapaml)
      e) other component pkgs (e.g., ice, land, ptracers, biogeo, flt)
      f) diagnostics pkgs (e.g., sbo, profiles, layers, diagnostics, timeave)
      g) I/O pkgs, e.g., mnc (+ mypackage at the end)
      -- blank line --
      h) adjoint related pkgs (e.g., autodiff, ctrl, cost ...)
    4) remove unused pkgs: kpp, sbo, timeave ; this results in reduced number of
       TAF recomputation warning for AD exp: bottom_ctrl_5x5 & global_ocean_ebm;
o tools/build_options:
  - add a symbolic link for optfile "linux_amd64_ifort" to "linux_amd64_ifort11"
o doc:
  - fix link and plot in doc/examples/baroclinic_gyre
o pkg/seaice:
  - Add new mechanical energy diagnostics ;
  - Move computation of stress diagnostics to seaice_dynsolver.F ; this change
    affects diagnostics SIpress, SItensil, SIpress, SIzeta, SIdelta, SIshear,
    because they are now filled after the current time step update, when they
    are actually available. Note: previously, for the first time step, these
    variables (and diagnostics) were not properly defined (or zero).

checkpoint67r (2020/06/04)
o pkg/ecco:
  - fix character length when checking for m_trHeat, m_trSalt & m_horflux_vol.
o pkg/autodiff:
  - add active read and write routines for global 1D vectors, to be used for
    compressed cost function vectors (note: not used yet, example to come soon).
o model/src & pkg/exf:
  - Reference atmospheric pressure for seawater EOS was assumed but was not
    explicitly set. New constant "eosRefP0" is added to make this more clear ;
  - Add main model reference surface pressure (surf_pRef) so that pLoad
    is now defined as the atmospheric pressure anomaly relative to surf_pRef ;
  - Account for differences in 2 ref pressure in EOS S/R ;
  - Fix few EOS references (in comments) ; fix and simplify S/R EOS_CHECK ;
  - Keep exf "apressure" field unchanged (still full atmospheric surface
    pressure) but now initialised to "surf_pRef" and fill "pLoad" with atmos.
    pressure anomaly relative to surf_pRef.
o pkg/streamice:
  - add option to specify "regularised coulomb" sliding law to better reflect
    dependence on subglacial water pressure close to the grounding line ;
  - above requires CPP option (due to new arrays) STREAMICE_COULOMB_SLIDING
    and r/t param streamice_allow_reg_coulomb ;
  - add diagnostic for streamice melt rate (BDOT_SI )
  - add parameter STREAMICEAdotFile to specify surface mass balance ;
  - add parameter streamice_maxnliter_Petsc to specify maximum no. of
    linear solves using PETSc in a single time step (not incl. in doc
    since PETSc is not part of standard build) ;
  - update references to PETSC_DEFAULT_DOUBLE_PRECISION to PETSC_DEFAULT_REAL in
    streamice_cg_solve_petsc.F; former seems to be deprecated in some versions
    of PETSc while latter is backward compatible ;
  - for BJACOBI (block jacobi) PETSc preconditioner, use PCICC (incomplete
    cholesky) rather than PCILU (incomplete LU) ;
  - for BJACOBI add parameter streamice_petsc_pcfactorlevels to control level
    of factor fill-in.

checkpoint67q (2020/03/19)
o pkg/shelfice, remeshing code:
  - simplify/clarify merging S/R call sequence: all done/called from main
    remeshing S/R SHELFICE_REMESHING :
      - remesh_c_mask : now only update geometry & surface fields at grid-cell
        center and compute merging remeshing weights for tracers;
      - remesh_uv_mask : now only update geometry & surface fields at grid-cell
        edges and prepare merging remeshing weights for velocity;
        also fix thin-wall setting without reading again thin-wall files ;
      - calls directly CALC_SURF_DR and UPDATE_SURF_DR
  - move adjustment of state variables into (new) dedicated
    S/R SHELFICE_REMESH_STATE and change loop range so that no further EXCH
    calls are needed ; also add missing code for ALLOW_ADAMSBASHFORTH_3 ;
  - move update of Rmin_surf (formerly in shelfice_remesh_rminsurf.F)
    before first call to S/R CALC_SURF_DR (where Rmin_surf is used)
    and in-line S/R SHELFICE_REMESH_RMINSURF into shelfice_remesh_uv_mask.F
  - add argument "wFld" and "myIter" to S/R SHELFICE_REMESH_CALC_W
  - fix so that it compiles and run when _RS is real*4 (#undef REAL4_IS_SLOW).
o model/src:
  - Fix for special value of R_low with pkg/shelfice:
    When bathymetry field value is just rF(k)+hFacMindrF(k)/2, R_low will
    deepen (by hFacMindrF(k)/2 ) to satisfy the hFacMin criteria. In this case:
      o if R_shelfIce value (from file) was exactly equal to initial bathymetry
        depth, original code would create a very thin grid cell of thickness
        factor hFacMin. Fix this problem by preventing deepening of R_low when
        initial R_low >= R_shelfIce.
      o if R_shelfIce value is deeper than original value, the problem does not
        show up for hFacC (column remains dry) but because of erroneous resetting
        of rSurfW/S (to be the MAX of rSurfW/S, rLowW/S) this could trigger the
        same type of artificial deepening at Western and Southern column edges
        (for hFacW and hFacS). Remove early resetting of rSurfW/S to fix this
        second issue (see issue #324).
  - Simplify correction for miss-match between Sum of level thickness at
    W & S edges and top minus bottom r-position: only adjust rSurfW/S
    (and not rLowW/S) as done previously for the case useMin4hFacEdges=T;
  - Non-lin free-surf in r coordinate: for consistency, use rSurfW & rSurfS
    (which account for adjustment, if any) instead of MIN of adjacent Ro_surf
    when calculating new thickness factor: hFac_surfW & hFac_surfS ;
  - Make thin-wall implementation available for sigma-coordinate ;
  - Record thin-wall position as kSurfW/S = Nr+2 (instead of = Nr+1 for
    a dry column).
o tools/build_options:
    rename optfile "linux_amd64_ifort" to "linux_amd64_ifort10-"
o verification:
  - new reentrant channel tutorial experiment, doc will follow soon.

checkpoint67p (2020/02/12)
o model/src:
  - rename array "surfaceForcingTice" to "adjustColdSST_diag" and change the
    description to better reflect what it is: a diagnostic for SST adjustment.
  - remove most of the TAF storage directive for "adjustColdSST_diag" that were
    not necessary once it's properly initialized.
o pkg/gmredi:
  - improve error handling
  - additional QGLeith config checks
  - standardise variable name capitalizations
o pkg/mom_common, mom_vecinv, mom_fluxform:
  - protect QGLeith code with ifdefs
  - additional QGLeith config checks (in model/src/config_check.F)
o verification:
  - rename dir "rotating_tank" to "tutorial_rotating_tank".
o pkg/flt:
  - improve pkg/flt doc and CPP brackets
o doc:
  - new front-page to tutorial chapter, also listing all verif experiments ;
  - add new section in ch3 about input file format.

checkpoint67o (2019/12/23)
o pkg/shelfice:
  - implement implicit ice-shelf drag, in the same way as implicit bottom drag,
    using the same run-time switch "selectImplicitDrag".
  - change 3-D diagnostics of ice-shelf drag tendency (SHIUDrag & SHIVDrag) to
    2-D diagnostics of ice-shelf drag stress (SHI_TauX & SHI_TauY).
  - update 4 forward reference output files of experiment "isomip".
  - switch on implicit drag in experiment shelfice_2d_remesh (to get it tested).
o pkg/shelfice:
  - addition of functionality described in Jordan et al (2017), "Ocean-Forced
    Ice-Shelf Thinning in a Synchronously Coupled Ice-Ocean Model";
    allows "remeshing" of grid-cells in vertical in response to changing free
    surface due to ice shelf mass change:
    At SHELFICEremeshFrequency interval, checks for cells that are too thick or
    too thin and adjusts R_surf & eta accordingly, and updates state variables ;
  - new main remeshing S/R SHELFICE_REMESHING calling additional S/R in files
     shelfice_remesh_c_mask.F, shelfice_remesh_uvmasks.F,
     shelfice_remesh_rminsurf.F and shelfice_remesh_calc_w.F
    and called directly from top of FORWARD_STEP ;
  - all new code and call protected under #define ALLOW_SHELFICE_REMESHING ;
  - add field "R_shelfice" to pkg/shelfice pickup files for restart ;
  - verification/shelfice_2d_remesh/*: new verification experiment
    to test remeshing functionality.
  - additional options to SHELFICEboundaryLayer:
    a) SHI_withBL_uStarTopDz, to compute uStar from uVel,vVel avergaged over
       top Dz thickness first and then average horizontally ;
    b) SHI_withBL_realFWflux, to use real Fresh-Water flux (and adjust
       advective surface flux) with SHELFICEboundaryLayer.
o pkg/ecco:
  - change S/R ECCO_READWEI to read in uncertainty file and compute weight
    as 1/sigma if nosumsq is provided as a preprocessing option, or 1/sigma^2
    if not. This is the expected behavior based on the "generic cost function"
    section of the documentation.
o verification:
  - new experiment "global_oce_biogeo_bling" move here from verification_other.
o pkg/cheapaml:
  - rewrite advection-diffusion of BL atmospheric variables to use Flux-Form
    formulation. Affects results (unless cartesian grid is used).
  - apply special treatment of diffusive flux at Northern & Southern boundaries
    only if .NOT.cheapamlYperiodic (previously unconditional, gad_diff_2d_y.F);
  - Skip calls to AB-2 when using "useFluxLimit=T" option since advection scheme
    used then is DST3FL which does not need AB at all. Affects results if
    useFluxLimit=T" is used.
  - clean-up (rename/remove all "gad_*.F" files) and simplify by using few more
    pkg/generic_advdiff S/R (instead of local copies).
  - update output of experiment "cheapAML_box" (and in separated PR, experiment
    "offline_cheapaml" in verification_other)
o pkg/ctrl:
  - Tangent Linear mode: allows to initialise g_xx fields with user-provided
    g_xx file (default unchanged, i.e., initialised to zero).

checkpoint67n (2019/11/26)
o pkg/ctrl:
  - add doc & storage dir for initial velocity control option.
o pkg/autodiff:
  - sort out checkpoint_lev1_dir header file for when pkg/ecco is used
    with #undef NONLIN_FRSURF ; similar update in pkg/cd_code & pkg/ptracers;
    this fixes issue #68.
  - clean-up and fix pkg/autodiff checkpoint_lev?_dir to be able to compile
    with #define EXCLUDE_FFIELDS_LOAD.
o model/src:
  - allows to specify time-dependent (periodic) geothermal heat-flux
    with "periodicExternalForcing".
o pkg/diagnostics:
  - add diagnostics for thickness factor hFacC, hFacW & hFacS.
o pkg/dic:
  - Fix carbonate chemistry coefficient issues (#269). This affects results when
    either CARBONCHEM_TOTALPHSCALE or CARBONCHEM_SOLVESAPHE are defined.
    Update output of verification experiment "so_box_biogeo".
o doc:
  - fix description of zero-layer thermoydnamics
o verification/*/results/output.txt:
  - update reference machine from baudelaire.mit.edu (running fc13)
    to villon.mit.edu (running Ubuntu 18 LTS) and update few output.txt
  - change travis Docker settings accordingly + update documentation.

checkpoint67m (2019/10/16)
o doc/examples:
  - Convert remaining old doc tutorials from latex to rst files and add them
    to current MITgcm documentation.
o pkg/ptracers:
  - new diagnostics Tp_gTr01, ... for ptracer total transport tendencies
    (before gchem_forcing_sep); this includes advection and diffusion terms,
    but also anything added in gchem_add_tendency.
o doc & verification/tutorial_baroclinic_gyre:
  - split doc for tutorial experiments into separate files
  - update configuration for baroclinic gyre tutorial
  - update documentation for baroclinic gyre tutorial
  - formatting and font changes in algorithm chapter
o doc:
  - add rtfd config file to control build behaviour and options.

checkpoint67l (2019/08/29)
o QG-Leith viscosity:
  - pkg/mom_common: bug fix for QG Leith viscosity
  - pkg/gmredi: bug fix for QG Leith coefficient
  - update output of experiments MLAdjust.QGLeith & MLAdjust.QGLthGM
o pkg/obcs:
  - new feature to balance surface flux of freshwater or ice shelf mass by
    outflow through open boundary conditions:
    * requires splitting S/R obcs_calc to move call to S/R obcs_balance and S/R
      obcs_add_tides after S/R external_forcing_surf call in do_oceanic_phys.F
    * add contribution for EmPmR of the current time step and the
      shelficeMassDynTendency (new S/R shelfice_netmassflux_surf).
  - add new secondary test exp. "isomip.obcs" to text this new feature.
o pkg/mom_common & model/src:
  - new S/R MOM_U/V_BOTDRAG_COEF used both for explicit and implicit bottom drag
    computation (thus replacing both MOM_U/V_BOTTOMDRAG in explicit case and
    MOM_U/V_BOTDRAG_IMPL in implicit case) to return a drag coefficient.
    This modification affects results at machine truncation level.
  - change diagnostics 'Um_dPHdx' & 'Vm_dPHdy' to 'Um_dPhiX' & 'Vm_dPhiY'
    for full pressure gradient tendencies (including surf & NH contribution);
  - remove bottom drag tendency diags (UBotDrag & VBotDrag); add bottom stress
    diagnostics and implicit viscous tendency diagnostics, both accurate also
    if using implicit bottom drag (selectImplicitDrag=2).
o pkg/exf:
  - re-arrange EXF interpolation header files: move setting of "MAX_LAT_INC"
    from EXF_PARAM.h to EXF_INTERP_SIZE.h (more logical place). But to avoid
    having to include EXF_INTERP_SIZE.h each time EXF_PARAM.h is included,
    move EXF interpolation parameters outside EXF_PARAM.h in new header file:
    EXF_INTERP_PARAM.h
  - add S/R to define input grid setting (stored in EXF_INTERP_PARAM.h) to be
    used for EXF interpolated fields as default input grid.
o compon_interf pkgs:
  - fix bi loop range in few initialisation subroutines (2 in each pkg),
    fixing issue #270

checkpoint67k (2019/07/19)
o model/src:
  - fix format in printing 1 error message from S/R SET_PARMS
o pkg/bling:
  - add missing components of SIBLING
  - add Manizza et al 2005 light attenuation. Enable with PHYTO_SELF_SHADING
  - Replace hard coding of max mixing depth with runtime parameter MLmix_max
o pkg/ctrl:
  - fix reccord number setting in S/R CTRL_GET_GEN_REC ("startrec" substracted
    for no reason).
o doc:
  - add a sub-section about optim_m1qn3
o pkg/ctrl:
  - fix in rescaling option for control vector ("doscaling/noscaling" option,
    S/R CTRL_MAP_INI_GENARR & CTRL_MAP_INI_GENTIM2D); proper counting of
    non-zero control vector when weight-mask is different from ocean-mask.
    Expect differences only when (a) weight-mask is different from ocean mask
    and (b) xx_genarr2d_preproc='noscaling' (doscaling=.false.).
o pkg/exf:
  - new run-time parameter "diags_opOceWeighted" (default=T) to weight some exf
    surface diagnostics (all net and upward fluxes) with open-ocean fraction.
    Option is turned off when no sea-ice pkg (seaice or thsice) is used.
  - new S/R EXF_WEIGHT_SFX_DIAGS to do some exf diags as open-ocean weighted
    according to input argument ice fraction. Called from the right location
    in time-stepping to get diagnostics that are consistent with wind-stress
    and buoyancy fluxes that ocean receive.

checkpoint67j (2019/06/18)
o pkg/bling:
  - Cleanly seperate NBLING (default), BLING_V1 (enabled with USE_BLING_V1),
    and also add Silica option (enabled with USE_SIBLING);
  - New algorithm for calculating mixed layer depth (old enabled with
    BLING_USE_THRESHOLD_MLD);
  - Options for updated carbon chemistry (from J. Lauderdale) enabled with
    CARBONCHEM_SOLVESAPHE or CARBONCHEM_TOTALPHSCALE ;
  - And other minor spring cleaning changes;
  - update calls in pkg/gchem for BLING(V1) or NBLING (with Silica).
o pkg/salt_plume:
  - fix calculation index range in salt_plume_apply.F (#ifdef SALT_PLUME_VOLUME)
o pkg/ecco:
  - fix/simplify local file names in ecco_cost_init_barfiles.F (within
    #ifdef ALLOW_GENCOST_CONTRIBUTION ).
o pkg/mom_vecinv:
  - add 2 Coriolis schemes which satisfy: d/dt U = f V ; d/dt V = -f U
    (with U,V = vertically integrated flow).
  - add new run-time coriolis-scheme selector "selectCoriScheme" to replace
    "useJamartWetPoints" and "useEnergyConservingCoriolis"; but keep these 2
    in namelist (backward compatible) to set "selectCoriScheme" accordingly.
o pkg/ctrl:
  - Fix bug in ctrl_map_ini_genarr.F regarding missing initialization of
    igen_uvel & igen_vvel (just like all the other variables).
o pkg/dic:
  - Implement SolveSAPHE (Munhoven, 2013), a robust algorithm to calculate
    oceanic pH/pCO2 ; compiled when CARBONCHEM_SOLVESAPHE is defined (in
    DIC_OPTIONS.h) and used when (in data.dic) selectPHsolver > 0 ;
    Add several options for selecting dissociation coefficients, available
    when CARBONCHEM_SOLVESAPHE is defined.
  - Change experiment "so_box_biogeo" to compile with CARBONCHEM_SOLVESAPHE
    defined and add secondary test "saphe" (dir: input.saphe) to this experiment
    to test GENERAL pH solver (selectPHsolver=1).
o pkg/seaice:
  - add alternative version of seaice thermodynamics two routines that provide
    accurate adjoint. Switched by defining CPP option: ALLOW_SEAICE_GROWTH_ADX
o pkg/mdsio:
  - in meta file, write number of records with longer format (10 digits vs 5
    previously) to accommodate large number of floats.

checkpoint67i (2019/05/08)
o autofdiff:
  - fix to avoid TAF recomputations in ggl90 & salt_plume pkgs
    and in model/src PCELL_MIX_CODE.
o pkg/mom_common & pkg/gmredi:
  - add quasi-geostrophic variant of Leith dynamic visocity
  - use the quasi-geostrophic Leith dynamic visocity as GM diffusivity
  - new verification experiment to test QG-Leith (variant of MLAdjust)
  - updated documentation about new option
o pkg/seaice:
  - add Hlimit to seaice namelist in data.seaice
  - use verification seaice_itd.thermo to test this feature with default
    values (experiment does not change)
  - clean up related output in seaice_init_fixed.F a little
o verification/testreport:
  - for file run_ADM_DIVA, fix sed search syntax so that it works with BSD-sed
o model/src:
  - fix small bug (wrong balanceEmPmR report) in config_summary.F, spotted by
    Christopher Wolfe ; add report of balancePrintMean to summary.
o verification/verification_parser.py
  - ensure Travis test suite fails when a build or a run fails.

checkpoint67h (2019/03/21)
o tools/genmake2:
  - fix option "-nocat4ad" for latest version of TAF: now needs to add TAF
    option "-fixed" to process *.flowdir files with newer (after 4.1.1) version
    of TAF (otherwise assumed now to be in free format).
o model/src:
  - remove argument tFld & sFld from S/R CALC_PHI_HYD and from 2 related S/R
o tools/genmake2:
  - allow to skip "check_fortran_compiler" part (as, e.g., in opt-file:
     tools/build_options/linux_ia64_cray_archer).
o verification/tutorial_barotropic_gyre:
  - add 1rst tutorial documentation to new manual and update corresponding setup
o pkg/atm_phys:
  - add 3-D input file for stratospheric ozone
  - add code from Matt Kasoar for SW absorption by stratospheric ozone,
    based on following papers:
    Lacis and Hansen (JAS, 1974) and Forster and Shine (JGR, 1997).
  - turned on using 2 local run-time parameter: ozone_in_SW (downward)
    and two_stream_SW (also in upward); default are off.
  - clean up S/R "radiation_up": rename "net" to "flux_lw" (better name)
    and remove un-used local (dyn-allocated) arrays.
  - also avoid division by zero in Rel-Humid diagnostics (atm_phys_driver.F)
o pkg/seaice:
  - fix missing update of sIceLoad in the case usePW79thermodynamics=F.
o pkg/dic:
  - Adjust unit conversions for dissociation coefficients aks, aksi, and akf
    (#define CARBONCHEM_TOTALPHSCALE).
o tools/genmake2:
  - improve Fortran Compiler check, section: running MPI executable ; also
    refine the "conclusion" printed message.

checkpoint67g (2019/01/03)
o doc:
  - add documentation for pkg/streamice
o model/src:
  - change ordering of pkg calls in initialisation: streamice / shelfice and
    then seaice / salt_plume / thsice;
  - fix thin ice-shelf issue with pkg/seaice ; implemented by updating (recently
    added) seaice masks (requiring new ordering of calls).
o pkg/shelfice:
  - allow to include thin ice-shelf (i.e., such that hFacC(k=1) > 0 ) when
    using pkg/thsice, by preventing seaice to form where there is an ice-shelf.
  - prevent short-wave heating below an ice-shelf (previously still happening
    below thin ice-shelf); also fix Qnet there (but only for diagnostics).
o pkg/seaice:
  - move initialisation of masks and metric coefficients and KGEO from
    seaice_init_varia.F to seaice_init_fixed.F
  - remove all reference to global masks maskC/maskW/maskS:
   * introduce new masks SIMaskU/V
   * initialise HEFFM/SIMaskU/V as copies of surface maskC/W/S
   * replace maskC/W/S with HEFFM/SIMaskU/SIMaskV; in some places this requires
     including SEAICE.h and as a consequence renaming a few local variables to
     avoid name overlap
  - remove TAF storage directives for "heffm" (no longer needed) and simplify
    seaice calls and TAF storage dir in do_oceanic_phys.F
o pkg/monitor:
  - fix local array declaration in mon_stats_latbnd_rl.F
o tools/example_scripts:
  - remove all files in tools/example_scripts/
    (updated testing scripts are all in MITgcm_contrib/test_scripts)
o verification:
  - remove un-tested experiments: cpl_atm2d+ocn, tidal_basin_2d and
    tutorial_offline

checkpoint67f (2018/11/23)
o pkg/seaice:
  - add advection ppm and pqm advection schemes ;
  - test new scheme in verification/offline_exf_seaice.dyn_lsr
o pkg/generic_advection:
  - regularize ppm and pqm advection schemes:
  - replace unsafe division in the case of numerical underflows by
    regularized expression sign(max(abs(uCFL),1.d-20),uCFL) and similar,
    in anology to other advection routines, e.g. gad_os7mp_adv_x/y/z.F
  - affects verification/advect_xz at truncation level -> updated
o eesupp & model:
  - add entry points for 2-way nesting pkgs.
o pkg/dic:
  - fix out-of-bounds error in S/R CAR_FLUX_OMEGA_TOP (#define CAR_DISS)
o pkg/streamice:
  - new implementation of grounding line smoothing by smoothing of basal
     traction in partly grounded cell, in streamice_upd_ffrac_uncoupled.F
  - rename CPP directives: previous smoothing functionality now enabled with
    STREAMICE_SMOOTH_FLOATATION2, new functionality enabled via
    STREAMICE_SMOOTH_FLOATATION
  - affects verification/halfpipe_streamice, FWD, TAF and OpenAD adjoint.
o pkg/atm_phys:
  - change IR absorption formulation regarding the dependence on Water-Vapor
    in the case wv_exponent = -1 ; update results of experiment "atm_gray.ape"
    from verification_other repos.
o pkg/seaice: clean up advection and SEAICE_ITD
  - make SEAICEmultiDimAdvection a global variable that is set in
    seaice_readparams.F
  - do not allow SEAICE_ITD with old 2nd order advection scheme anymore
  - re-organize SEAICE_ITD code in seaice_advdiff.F
  - make it possible to compile pkg/seaice without pkg/generic_advdiff
o pkg/autodiff:
  - created addummy_for_etan.F to correctly print adjoint variable for etaN

checkpoint67e (2018/10/16)
o pkg/seaice:
  - fix possible division by zero if LSR_mixIniGuess > 0
o pkg/streamice:
  - fix bugs relating to ice front advance:
    streamice_advect_thickness.F -- overlap update of array passed to
     streamice_adv_front which was leading to spurious ice area values
    streamice_init_varia.F -- proper initialisation of area_shelf_streamice
     which is used for ice front advance (only affects diagnostics)
o verification/*/data
  - set "rhoConst" instead of "rhoNil" (unless using Linear EOS)
  - for net surface heat flux, set "surfQnetFile" instead of "surfQfile"
    (unless net surface shortwave is also specified).
  - fix OpenAD/input_oad.kpp set-up where net surface heat flux was used
    as net heat-flux minus short-wave and update the output.

checkpoint67d (2018/09/04)
o doc:
  - update few pieces of documentation including addition (in "getting_started"
    section) of main CPP OPTIONS description and main code full list of
    run-time parameters.
o pkg/generic_advdiff:
  - move masking of (explicit) vertical diffusive flux to S/R that compute each
    contribution (pass maskUp as a new argument): This ensures that diagnostics
    of explicit vertical diffusive flux are properly masked.
o tools/do_tst_2+2
  - Fix up to use absolute paths for results directories.
o pkg/seaice: some new and hopefully more sensible defaults:
  - SEAICEscaleSurfStress = .TRUE.
  - SEAICEaddSnowMass = .TRUE.
  - SEAICEadvScheme = 77
  - SEAICE_useMultDimSnow = .TRUE.
  - SEAICE_Olx/y = Olx/y - 2
  - SEAICEetaZmethod = 3
  - SEAICE_drag = 0.001
  - CPP-flag SEAICE_ZETA_SMOOTHREG defined by default
  - change SEAICE_waterDrag default to 5.5e-3 and add reference density
    rhoConst to scale it. Add a warning if SEAICE_waterDrag > 1.
    This change also involves a slight re-organization (= simplification)
    in seaice_oceandrag_coeffs.F
  - all verification experiments are affected, so that all but four
    data.seaice are adjusted to restore the old defaults. The four experiments
    that use the new defaults are
    + global_ocean.cs32x15.seaice
    + offline_exf_seaice
    + offline_exf_seaice.dyn_jfnk
    + offline_exf_seaice.dyn_lsr
  - updated documentation
o pkg/dic:
  - Promote constants in S/R CARBON_COEFFS_PRESSURE_DEP and
    S/R CAR_FLUX_OMEGA_TOP to double precision.
o pkg/seaice:
  - fix bug in seaice B-grid code (call to seaice_advdiff, see issue #134);
    Note: B-grid code not tested in any verification exp. (only compiled in one)
    so no need to update any output.txt
o pkg/diagnostics:
  - Print adjoint variables for theta, salt, uvel, vvel, wvel, and etan
    through diagnostics package.
o pkg/shelfice:
  - fix ice shelf mask for very-thin ice shelf case, when hFacMin
    and hFacMinDr criteria leave no room for ice (hFac(k=1)=1).
    Note: thin ice-shelf that results in 0< hFac(k=1) <1 still need
    to be fixed when using any seaice pkg.
o pkg/ecco:
  - Replace "mskTrVol" and "gencost_errfile" with "gencost_mask" in
    "cost_gencost_transp", mirroring "m_horflux_vol".
  - Document and warn user (via STDERR) of potential issues with using
    "cost_gencost_transp" to compute volume, heat, or salt transport.

checkpoint67c (2018/06/26)
o pkg/generic_advdiff:
  - Add per tracer run-time param to switch on/off Smolarkiewicz-Hack:
    Run-time switch for Temp & Salt are set from main param file "data"
    (default value = FALSE); and for pTracers, they are set from parameter
    file "data.ptracers" (default value = TRUE).
  - Add a test in verification exp. global_ocean.90x40x15.down_slope for
    Smolarkiewicz-Hack (switched on for Salt and pTracer(1)) but results
    remains unchanged since, in this exp., Salt & pTr(1) are well above 0.
o pkg/mdsio:
  - apply same substitution to remaining calls to MDSREADFIELD/MDSWRITEFIELD
    in pkg/ctrl and in pkg/seaice.
  - disable the use of obsolete MDSREADFIELD and MDSWRITEFIELD S/R (unless
    USE_OBSOLETE_MDS_RW_FIELD is defined).
o pkg/ecco:
  - replace calls to (obsolete) MDSREADFIELD and MDSWRITEFIELD with calls to
    pkg/rw S/R: READ_REC_3D_RL and WRITE_REC_3D_RL ; this enable to use pkg/ecco
    without pkg/autodiff.
o verification exp:
  - update few (10) adm & tlm output after latest TAF update, from version 3.9.0
    to version 3.9.6 on May 16-18.

checkpoint67b (2018/05/05)
o pkg/exf/exf_wind.F:
  - fix a bug detected by Stanislav Martyanov: replace wStress by SQRT(wStress)
    in computing ustar ; this bug does not appear to affect the verification
    experiments but has been around for a while (inherited from the ecco-branch)
o pkg/seaice:
  - new run-time parameter to skip the update of ocean surface stress ; could be
    useful for testing or when seaice-dynamics is off (add a warning otherwise).

checkpoint67a (2018/03/10)
o pkg/layers
  - add Moist Static Energy coordinate in layers package
o pkg/aim_v23:
  - change parameter "aim_abs_pCO2" default value (used if aim_select_pCO2=1,3)
    to calibrated value (from David Ferreira).
o pkg/layers
  - fixed up units reported in diagnostics for THETA and SALT term induced layer
    thickness changes.
o pkg/seaice:
  - move wind-stress over seaice out of SEAICE.h into local seaice_dynsolver.F
    common block ; move initialisation of TAUX & TAUY accordingly and add them
    to argument list of S/R SEAICE_OCEAN_STRESS (like SEAICE_GET_DYNFORCING).
    This enable to remove CPP option "SEAICE_EXCLUDE_WIND_STRESS" (hack from
    June 2016) in pkg/dic/dic_fields_update.F
o doc:
  - first addition of reST/sphinx documentation (formerly in
    https://github.com/altMITgcm/MITgcm/doc/), converted from original MITgcm
    LaTeX manual in: https://github.com/MITgcm/manual-archive with edits
    (including new sections) from @jrscott and @edoddridge ;
  - update section on Ocean State Estimation packages by @gaelforget ;
  - updated seaice pkg description by @mjlosch.

checkpoint67 (2018/02/05)
o add Sphinx configuration for documentation on https://mitgcm.readthedocs.io
o add Travis configuration for testing pull requests
o migrate from CVS to Git (2018/01/31)

checkpoint66o (2018/01/30)
  => Final CVS tag ; disable CVS check-in.

checkpoint66n (2018/01/18)
o pkg/seaice & down_slope:
  - remove few files from ${pkg}_ad_diff.list (when calling S/R is not in
    any *_ad_diff.list)
o pkg/shelfice:
  - account for "shelficeLoadAnomaly" in computation of initial pressure
    that is used in EOS (case selectP_inEOS_Zc >= 2).
o pkg/aim_v23:
  - merge namelist "AIM_PAR_CO2" into "AIM_PARAMS" and replace Aim_CO2_Flag=2
    option with aim_select_pCO2=2 (using #define ALLOW_AIM_CO2);
  - add option to derive LW absorption in CO2 band as function of pCO2,
    using either prescribed pCO2 (aim_select_pCO2=1), or computed pCO2
    from well-mixed atm-box (aim_select_pCO2=3).
o pkg/gchem, changes to enable to use several geo-chemistry pkgs together:
  - new CPP option GCHEM_ADD2TR_TENDENCY around definition of gchemTendency
    array (replacing #ifndef GCHEM_SEPARATE_FORCING) ;
  - in GCHEM_FIELDS.h, change dimension of array "gchemTendency"
    from PTRACERS_num to GCHEM_tendTr_num ; this later one is set in new header
    file: GCHEM_SIZE.h, to be included anytime GCHEM_FIELDS.h is included ;
  - new set of S/R, called from GCHEM_TR_REGISTER, to record rank (in pTracer
    array) and number of tracers for each geo-chemistry pkg ;
  - check that GCHEM tracers all fit in pTracer and gchemTendency arrays ;
  - initialise gchemTendency array in gchem_init_vari.F ;
  - fix storage directives for gchemTendency ;
  - add some entry points for new geo-chemistry pkg SPOIL.
o verification/isomip:
  - update secondary test (input.htd): a) drop cd_scheme, useJamartWetPoints=T
    and increase viscAh ; b) use ivdc_kappa with implicit Diff & Visc ;
    c) switch off SHELFICEboundaryLayer, turn on pCellMix_select (=20) and
    use SHELFICEselectDragQuadr=1 ; add new set of pickup files.
o pkg/shelfice:
  - Replace CPP option: SHI_USTAR_WETPOINT with run-time parameter:
     SHELFICE_oldCalcUStar (default=F <--> #define SHI_USTAR_WETPOINT)
    but keep only original (old) formula in SHELFICEboundaryLayer code.

checkpoint66m (2017/12/12)
o add another hook (S/R PDF_FINALIZE) for the Parallel Data Assimilation
    Framework PDAF (http://pdaf.awi.de/) in the_main_loop.F
o pkg/autodiff:
  - fix pkg/exf AD variable output (mainly ADJprecip), left from pkg/exf modif
    on Jan 27, 2017. Try also to fix ADJrunoff and TLM output (but less clear).
o pkg/obcs:
  - add simpler setting (single value) of OB indices for the case where
    indices are uniform over the full section (Bruno Deremble contribution).
o pkg/rbcs:
  - increase size of "relaxMaskFile" to read-in from namelist and save it
    (+check) into new (renamed) "relaxMaskTrFile" array.
o model/src:
  - option (interViscAr_pCell, interDiffKr_pCell) to account for true vertical
    distance (including hFac) in vertical viscous flux and diffusive flux ;
  - add option to increase vertical mixing (for both momentum and tracers)
    near surface and/or bottom where partial cell is too thin ;
  - for now, both additions above are within: #ifndef EXCLUDE_PCELL_MIX_CODE ;

checkpoint66l (2017/10/24)
o pkg/kpp, ggl90 & ebm:
  - read namelist without IOSTAT=errIO to force to stop if there is an error
    in the parameter file namelist.
o pkg/cheapaml: major changes to relaxation coefficient setting:
  - rename parameters cheapaml_taurelax & cheapaml_taurelaxocean (in days)
    to cheap_tauRelax & cheap_tauRelaxOce (now in seconds);
  - if using cheapMaskFile, set relaxation coeff to: cheapMask/tauRelax
    (instead of 1/cheapMask over ocean and 1/tauRelax over land);
  - with cheapMaskFile unset: set relaxation coeff according to land/ocean mask
    (unchanged) but skip increase near domain edges for periodic domain (in X
    or Y dir) when cheapamlX/Yperiodic=T ; also fix linear increase (over
    Cheapaml_mask_width grid points) of coeff towards domain edges (previously
    was increasing away from edges). Update output of experiment "cheapAML_box".
o pkg/cheapaml:
  - move setting of (fixed in time) relaxation coefficient
    from cheapaml_init_varia.F to cheapaml_init_fixed.F
o pkg/exf:
  - add specific forcing field for tides to feed model new geopotential anomaly
    forcing, for now within #ifdef EXF_ALLOW_TIDES.
  - remove from common block unused params: exf_inscal_sst & exf_inscal_sss.
o model:
  - add new 2-d forcing field for time-dependent geopotential anomaly (e.g.,
    tidal forcing), in m^2/s^2 ; add run-time param to allow to turn it off.
o eesupp/src:
  - shift standardMessageUnit in eeboot.F and I/O units in mdsfindunit.F
    for coupling to GEOS AGCM: HACK_FOR_GMAO_CPL option in CPP_EEOPTIONS.h

checkpoint66k (2017/09/20)
o model/src:
  - add missing CPP brackets (ALLOW_COST, ALLOW_CTRL in load_fields_driver.F
    and the_model_main.F)
o ctrl:
  - use zeroRL in place of fc when ALLOW_COST is not compiled (in ctrl_pack.F)
  - call MDS_READ_FIELD / MDS_WRITE_FIELD instead of deprecated
    mdsreadfield / mdswritefield (in ctrl_get_gen.F, ctrl_map_ini_gen.F,
    ctrl_map_ini_genarr.F, and ctrl_map_ini_gentim2d.F )
o eesupp:
  - add CPP option to activate some pieces of code for coupling to GEOS AGCM;
  - shift commonly used IO unit (in eeboot.F) for coupling to GEOS AGCM.
o pkg/bling:
  - bling_production: Fix typo in calcium carbonate uptake. Also rearranging
    and cleaning
o model/src:
  - move k loop inside correction_step.F (+ update calling S/R)
  - collect implicit pressure gradient tendencies in local 2-D array;
    affect results (at machine truncation level) when using 3-D solver; update
    output of exp.: exp4 (x1), global_ocean.cs32x15 (x2),hs94.cs-32x32x5.impIGW,
                    rotating_tank, short_surf_wave,tutorial_deep_convection (x2)
                    & tutorial_plume_on_slope.

checkpoint66j (2017/08/15)
o pkg/ptracers:
  - fix surface forcing under ice-shelf (useShelfIce=T).
o pkg/atm_phys:
  - use hFac weighted average when applying A-grid atm-phys momentum tendency
    to C-grid dynamics; this ensures wind-stress match mom tendency.
o eesupp/src:
  - change default for opening scratch files to avoid STATUS='SCRATCH'
  - close scratch files with STATUS='DELETE'
  - changes affect eeset_parms.F and open_copy_data_file.F and many routines
    that read namelists (because they close the scratch files)
  - you can revert to old default by setting USE_FORTRAN_SCRATCH_FILES
    in CPP_EEOPTIONS.h (tested in ideal_2D_oce/code & lab_sea/code_ad)
o pkg/atm_phys:
  - fix unset arguments in (unused) S/R surface_flux_0d.
o eesupp/src:
  - add argument "procId" to S/R EESET_PARMS to fix  scratchFile1 & 2 setting
    (case TARGET_BGL or TARGET_CRAYXT) for early call (from eeboot_minimal.F):
    called with myProcId in eeboot.F and with mpiMyWId in eeboot_minimal.F
o pkg/streamice:
  - remove blank between _EXCH_XY_RL and "()", which my Apple Xcode
    preprocessor /usr/bin/cpp cannot interpret; 3 instances in total in
    streamice_driving_stress_fd.F and streamice_advect_2dtracer.F
o pkg/diagnostics:
  - new option to allow to cumulate thickness-factor (hFac) weighted field
    (if field permitted); implemented by changing sign of "jdiag" pointer
    (> 0: cumlulate field, < 0: cumulate hFac weighted field).
    a) restricted to 3-d (Nr levels), level centered diagnostics at U,V or Cell
       center position (gcode(2)='U','V','M' & gcode(3,5,9:10)='R',' ','MR')
    b) for now, activated by setting fileFlags 3rd character to 'h'.

checkpoint66i (2017/07/18)
o pkg/cheapaml:
  - add parameter "useRelativeWind", default set to False; this change the
    previous setting which was always using relative wind.
o add hooks for the Parallel Data Assimilation Framework PDAF
    (http://pdaf.awi.de/) in eeboot_minimal.F and the_main_loop.F;
    to use set CPP-flag USE_PDAF in CPP_EEOPTIONS.h
o pkg/exf:
  - interpolation of vector fields (exf_interp_uv.F): fix bug in calculation
    of South-Pole mean value.
  - interpolation near the poles, case where second additional row is at the
    pole (or beyond the pole and moved to the pole): change first addition row
    value to a linear interpolation between pole and 1rst (S.pole)/last (N.pole)
    row (instead of just a copy of it).
o pkg/seaice:
  - prevent JFNK and KRYLOV solvers from trying to reduce a residual of 0
  - add the option to compute no-slip du/dy, dv/dx (i.e.
    the offdiagonal strain rate e12) by a second order approximation
    on the boundary; works only with JFNK, KRYLOV, or EVP solvers, because
    it is too messy to implement for the implicit LSR matrix.
    SEAICE_2ndOrderBC = .FALSE. by default

checkpoint66h (2017/06/02)
o pkg/seaice:
  - add new routines to compute stress tensor components and stress tensor
    divergence to be reused in s/r seaice_lsr and s/r seaice_calc_lhs
  - change names of diagnostics SIsigI/II (commonly used for invariants)
    to SIsig1/sig2 (more common for principal components) to avoid confusion
o pkf/exf:
  - add a stop if useRelativeWind with un-updated uwind/vwind (e.g., constant);
    similarly, stop if rotateStressOnAgrid with constant wind-stress.
o pkg/seaice:
  - remove (comment out) diagnostics SIuwind,SIvwind,SIfu,SIfv (duplicate of
    EXFuwind,EXFvwind,oceTAUX,oceTAUY) and point them to their equivalent.
  - add diagnostics of wind-stress over seaice (SItaux,SItauy) and seaice
    fraction weighted wind stress over ocean+seaice (SIatmTx,SIatmTy).
o pkg/diagnostics:
  - small piece of code to rename (old) diagnostics, when namelist is processed.
o model/src:
  - new run-time param (useMin4hFacEdges) to select method for setting hFacW,S:
    originally, set as minimum of adjacent hFacC factor ; now (new default)
    computed from rSurfW,S and rLowW,S by applying same rules as for hFacC.
    Only matters when useShelfIce=T with particular ice-shelf cavity geometry.
o pkg/seaice:
  - add momemtum advection, off by default, still in test phase
    most of the momentum advection code is adapted and reused from mom_vecinv
o pkg/mom_vecinv:
  - pass these runtime flags:
    selectVortScheme, highOrderVorticity, upwindVorticity, useJamartMomAdv
    as formal parameters to s/r mom_vi_u/v_coriolis, mom_vi_u/v_coriolis_c4,
    so that these routines can also be used in pkg/seaice.

checkpoint66g (2017/04/24)
o model/src:
  - more robust ordering of column thickness integral (=Sum_k(drF*hFac) )
    to get same expression (regarding machine truncation) in different places
    in ini_masks_etc.F (e.g., rSurfC,W,S is now exactly zero when it should).
    Update forward output of experiments: global_ocean.cs32x15 (all 5 except
    viscA4), isomip (x3), tutorial_global_oce_in_p & tutorial_plume_on_slope.
o pkg/shelfice:
  - ALLOW_SHIFWFLX_CONTROL: move setting of maskSHI from shelfice_update_masks.F
    to shelfice_init_fixed.F
  - change S/R SHELFICE_UPDATE_MASKS to SHELFICE_INIT_DEPTHS (still called from
    ini_masks_etc.F for now) to update ocean upper boundary position according
    to ice-shelf topography (instead of directly updating hFacC).
o model/src:
  - move call to CTRL_INIT & CTRL_ADMTLM from the middle to the bottom of
    packages_init_fixed.F to allow other pkgs to set mask and weight fields.

checkpoint66f (2017/04/06)
o model/src:
  - add specific run-time param to select level of printed plot-field-maps,
    set by default to debugLevel. Remove internal param "printDomain".
o pkg/seaice:
  - add flag to add snow mass to seaiceMassC/U/V, the default is
    SEAICEaddSnowMass=.FALSE., not to change previous results
o pkg/bling
  - Bug fix in bling_production regarding unit conversion for diagnostics
    being put in the wrong place
o model/src:
  - add back recomputation of rSurfW & S to ensure consistent column thickness
    (needed for rStar) between Sum_k(hFac*drF) and rSurf-rLow, for now only
    when using pkg/shelfice; was initially added on 2012/06/01 (ini_masks_etc.F
    revision 1.51) but was removed accidentally on 2014/02/08 (v1.53).
o pkg/autodiff:
  - clean-up "checkpoint.flow"
o pkg/rw (Contribution from Jody Klymak):
    option to set mds file suffix as function of time in simulation:
    *) new input parameter "rwSuffixType" (read from PARM03 namelist)
       to select file suffix format; by default (=0), use iteration number;
    *) add simple routine to return file suffix according to rwSuffixType;
    *) in model/src and in most pkgs (except: atm2d, fizhi, regrid & streamice),
       use new S/R to get file suffix, except for debug output file (diagFreq)
       and pkgs offline & rbcs input files.
o pkg/rw:
  - uniform processing of "I10" suffix across writing fld routines; used to
    simplify debug writing of cg2/3d_b/x in solve_for_pressure.F & post_cg3d.F
    (similar to cg3d.F, cg3d_ex0.F)
o pkg/mom_vecinv:
  - highOrderVorticity in selectVortScheme=2 case: fix c4 coeff in splitted
    vorticity flux (keep same sum in case vBarXm=vBaXp, uBarYm=uBarYp).
o pkg/bling:
  - Many small changes intended to clean the code.
    Unnecessary ADJOINT_SAFEs removed ;
    removed BLING_COST.h BLING_CTRL.h bling_cost.F ;
    diagnostics added.

checkpoint66e (2017/03/14)
o pkg/exf:
  - interpolation with #undef EXF_INTERP_USE_DYNALLOC: move buffer size
    definition outside EXF_PARAM.h in new header file: EXF_INTERP_SIZE.h;
    use fixed size buffer (passed to S/R EXF_INTERP & EXF_INTERP_UV) to
    avoid any dynamic allocation ;
  - S/R EXF_CHECK: add new check & stop when file-name is defined but not
    read-in ; add warning when file is read-in but not used within pkg/exf ;
    + check for buffer-size (if #undef EXF_INTERP_USE_DYNALLOC).
  - update exf_summary.F (print {FLD}RepCycle).
o verification/global_with_exf:
  - switch on exf interpolation in AD test (just like the forward test)
o pkg/mom_vecinv:
  - add storage directives to avoid recomputations within mom_vecinv.F
    which were generating seg. fault with gfortran -devel
o pkg/ctrl, pkg/smooth:
  - initialize array halos which were generating seg. fault with
    gfortran -devel in adjoint mode
o pkg/exf:
  - for each input field, enable to specify a field specific repeat-cycle
    ({FLD}RepCycle) which defaults to pkg/exf main "repeatPeriod".
o verification/lab_sea:
  - update AD results of primary test and noseaicedyn test after switching
    to new version of TAF (5.3.13 vs 5.3.2 before); agreement with gradient
    check stays about the same.
o pkg/exf:
  - fix bug in exf_zenithangle.F for cases select_ZenAlbedo > 0 with useCAL=T.
  - exf_check: MAX_LAT_INC need only be "loc_nlat-1", not equal to loc_nlat
o pkg/bling, USE_EXFCO2 code:
  - add parameter "apco2RepCycle" (set to pkg/exf "repeatPeriod" by default);
  - update calls to EXF S/R (use new version: EXF_INIT_FLD & EXF_SET_FLD).
o pkg/exf:
  - rename S/R EXF_INIT to EXF_INIT_VARIA ;
  - add arguments: fldName (for debug msg) and fldRepeatCycle (set to
    repeatPeriod) to S/R EXF_SET_UV and to S/R EXF_SET_GEN (renamed EXF_SET_FLD)
    and update calls in pkg/exf calling S/R (exf_getffields.F & exf_getclim.F) ;
  - add argument: fldName (for debug msg) to S/R EXF_INIT_GEN (renamed
    EXF_INIT_FLD) and update calls in exf_init_varia.F
  - For now, for backward compatibility, keep a simplified version of S/Rs
    EXF_SET_GEN & EXF_INIT_GEN in file exf_set_gen.F
  - add and pass new arguments: fldName (for debug msg) and fldRepeatCycle
    to S/R EXF_GetFFieldRec ; update calls in pkg/obcs/obcs_exf_load.F
o tools/genmake2:
  - replace "bc -l" (only used once) by "expr" (already used).
o verification/global_ocean.cs32x15:
  - turn off pkg/cal (useCAL=F) in secondary FWD exp. "icedyn".
    Note: exf setting (data.exf) can be compared to other exf secondary exp
    "seaice" (kept with useCAL=T) which has same time dependent forcing.

checkpoint66d (2017/02/13)
o pkg/exf:
  - remove setting of useCAL=T when using pkg/exf (useEXF=T); add warning
    early on (in packages_boot.F) to stress this change in pkg setting.
  - In (most) verification exp. that use pkg/exf, add useCAL=.TRUE. to data.pkg
o model/src:
  - move call to ecco_phys to end of time step; this may induce minor
    cost function changes by shifting time averages by one time step
    for some variables; this revision resulted in changed adjoint results
    in MITgcm_contrib/verification_other/global_oce_cs32
o pkg/exf:
  - Change EXF_READ_EVAP to only activate code within #ifdef ALLOW_ATM_TEMP ;
    this prevents to read evap when ALLOW_ATM_TEMP is undef and other fields,
    e.g. precip, are not available.
o pkg/flt:
  - flt_init_varia.F: use pickupSuff if specified
  - add code (within #ifdef DEVEL_FLT_EXCH2) and test case as a first,
    intermediate, step towards completing pkg/exch2 support within pkg/flt;
    ifdef DEVEL_FLT_EXCH2 then:
    - flt_init_fixed.F: comment out stop
    - flt_exch2.F: conserve ipart, jpart (grid coordinates)
    - exch2_recv_get_vec.F: transform ipart, jpart (grid coordinates)
    - flt_mapping.F: attempt to fix longitude diagnostic near date-line
    - flt_init_varia.F: hack initialization (for testing purposes w. LLC90)
o tools/genmake2 & pkg/pkg_depend:
  - define new type of pkg dependency rule ("=pkg_x"), less strict than
    the "+" rule, that add the dependent pkg (pkg_x) unless it's disabled
    (-pkg_x in packages.conf).
  - change pkg/exf dependency rule from "exf +cal" to "exf =cal";
  - add "+cal" to dependency list of pkg/ecco (needed to compile).
  - simplify FWD experiment "offline_exf_seaice" by removing pkg/cal.
o utils/matlab:
  - adding ocean_basin routines for defining basin masks.
o pkg/exf:
  - new S/R EXF_GETFFIELD_START replacing EXF_GETFIELD_START, but with more
    arguments, allowing to check (and stop) if parameter setting of
     {FLD}startdate1 & date2 and of {FLD}StartTime are consistent with
    useCAL= T or F. For now, kept a simplified version of EXF_GETFIELD_START
    for backward compatibility.
  - change accordingly calls in exf_init_fixed.F + default {FLD}StartTime in
    exf_readparms.F ; apply same changes to pkg/icefront (for SGRunOff field).
o pkg/bling (USE_EXFCO2 code):
  - fix missing setting of apco2StartTime according to apco2startdate1 & date2
    by adding a call to S/R EXF_GETFFIELD_START.
o pkg/exf:
  - allows to compile without pkg/cal (but disabled by current dependency
    rules, i.e., default "pkg/pkg_depend"). Minimal changes to enable to
    run with useCAL=F ; this involves setting directly {FLD}StartTime instead
    of {FLD}startdate1 & date2 ; consistency check not yet coded.
o verification/global_ocean.cs32x15:
  - fix all data.exf for a shift of 1 day in all field startdate1 so that it now
    corresponds to middle of 1rst month; update outputs (2 fwd + 3 adm + 3 tlm).
o pkg/exf:
  - allow to use EXF_ZENITHANGLE without pkg/cal + simplify (saving some
    calculations); change FWD experiment global_ocean.cs32x15
    (#define ALLOW_ZENITHANGLE) to test/check that this code compiles.
o pkg/exf:
  - In preparation for addition to NAMELIST, rename internal (_RL) parameter
     {FIELD}startdate to {FIELD}StartTime
    Note: new name also fit better the content, i.e, a start time in second.
o eesupp/src:
  - add 1 argument to S/R EEBOOT & EEBOOT_MINIMAL for interface with ESMF
o pkg/exf:
  - add option ALLOW_READ_TURBFLUXES (and corresponding set of parameters)
    to allow to read-in Sensible & Latent Heat flux ;
  - simplify pkg/exf main options:
    1) move small piece of code (case ALLOW_ATM_TEMP undef) out of
       exf_bulkformulae.F into exf_wind.F so that exf_bulkformulae.F is
       compiled only when both ALLOW_ATM_TEMP & ALLOW_BULKFORMULAE are defined;
    2) make call to EXF_RADIATION and to EXF_WIND independent of CPP option
       ALLOW_BULKFORMULAE which now only applies to S/R EXF_BULKFORMULAE ;
    3) improve options documentation in EXF_OPTIONS.h.
o pkg/ecco:
  - cost_gencost_customize.F,ecco.h,ecco_phys.F,ecco_readparms.F, and
    ecco_summary.F: add passive tracer cost functions to gencost;
    m_ptracer and m_boxmean_ptracer
o pkg/ctrl:
  - ctrl_map_forcing.F: pass myIter and myTime to ctrl_map_forcing as input
    parameters; move myIter .EQ. nIter0 inside ctrl_map_forcing; add to list
    of implemented gentim2d contol parameters: xx_qnet, xx_empmr, xx_qsw,
    xx_sst, xx_sss, xx_pload, xx_saltflux, xx_fu, xx_fv, xx_fe, xx_fn
o model/src:
  - forward_step.F: pass myIter and myTime to ctrl_map_forcing as input
    parameters; move myIter .EQ. nIter0 inside ctrl_map_forcing
o pkg/exf:
  - exf_getffields.F: add to list of implemented gentim2d contol parameters:
    xx_lwflux, xx_swflux, xx_evap, xx_apressure, xx_areamask

checkpoint66c (2017/01/19)
o verification:
  - add new option "-src" to testreport to only produce source code (*.f),
    including taf output src code (if using '-adm'/'-tlm' option).
o pkg/exf:
  - add saltflx :: Net upward salt flux in psu.kg/m^2/s
o pkg/diagnostics:
  - add run-time variable diagMdsDir to specify a subdirectory for
    diagnostic output when mds is being used and mdsioLocalDir is not.
o pkg/mnc:
  - mnc_utils.F: edit stop message
o pkg/autodiff:
  - autodiff_ini_model_io.F: PRINT_MESSAGE, clean-up comments, add _*_MASTER,
    add HAVE_SYSTEM bracket around system call to mkdir
o pkg/profiles:
  - profiles_findunit.F, profiles_init_fixed.F, profiles_interp.F,
    profiles_readparms.F: call ALL_PROC_DIE before 'stop'
  - profiles_ini_io.F: use PRINT_MESSAGE, clean-up comments, add _*_MASTER,
    add HAVE_SYSTEM bracket around system call to mkdir
o pkg/smooth:
  - smooth_filtervar2d.F, smooth_filtervar3d.F: call ALL_PROC_DIE before 'stop'
  - smooth_init2d.F, smooth_init3d.F: move print statements to readparms
  - smooth_readparms.F: add cleaner print statements from smooth_init?d.F
o pkg/exf:
  - check: count errors and stop cleanly at the end (call to ALL_PROC_DIE);
    issue error message when climsst_interpMethod.GT.0 and climsst_lon_inc > 500
    generalize tests on interpMethod, nlat, and lon_inc to all exf variables.
  - summary: skip detailed field report if not used (empty file-name).
o tools/xmakedepend:
  - In case line editor "ed" is missing, switch to "sed" command to clean-up
    Makefile from previous dependencies (anything after "# DO NOT DELETE" line).
o pkg/exf:
  - change definition of "hflux" input file to always include Short-Wave;
    this is now consistent with hflux computation (if using bulk-formulae)
    and hflux diagnostic & documentation (in EXF_FIELDS.h).

checkpoint66b (2016/12/01)
o model & momentum pkgs:
  - implement fully implicit bottom friction combined with implicit surf.
    pressure, for now, only in hydrostic formulation:
    + to use: compile with #define ALLOW_SOLVE4_PS_AND_DRAG in CPP_OPTIONS.h
      and run with selectImplicitDrag=2 ;
    + currently missing diagnostics of bottom drag and vert. viscosity tendency;
  - partial implicit time-stepping (bot. friction + vert. visc first, then
    surf. press) corresponding to selectImplicitDrag=1 should be applicable
    to NH formulation but not available until we solve for surf. pressure
    increment (instead of full etaN).
  - change exp. global_ocean.cs32x15.thsice to test implicit bottom drag
    with implicit vertical viscosity.
o pkg/seaice: add linear remapping scheme (Lipscomb 2001) to ITD model
  - this is a first version that includes many regularisations that may
    not all be necessary, to be sorted out,
  - turned on by runtime parameter SEAICEuseLinRemapITD (true by default)
  - change one verification experiment in seaice_itd to use and test new code
  - seaice_growth: catch a case where the argument of log can be zero
    or smaller (important for code stability)
o model/src:
  - modify SOLVE_DIAGONAL_LOWMEMORY version of solve_tridiagonal.F
    & solve_pentadiagonal.F to enable to re-used inverse matrix for solving
    similar A.X'=Y' system (with same matrix A) in subsequent calls;
    switch based on errCode (In/Out) argument value; in calling routines,
    initialise errCode before first call.

checkpoint66a (2016/10/18)
o pkg/bling:
  - BLING package now loads in atmospheric pCO2 file using exf package routines
    Enable with #define USE_EXFCO2 in BLING_OPTIONS.h
o model/src & pkg/ptracers:
  - with INCLUDE_IMPLVERTADV_CODE defined, also call MOM_U,V_IMPLICIT_R &
    GAD_IMPLICIT_R (instead of IMPLDIFF) when just implicitViscosity and
    implicitDiffusion (respectively) are used (even without momImplVertAdv
    or temp,salt,PTRACERS_ImplVertAdv).
o model/src & generic_advdiff:
  - add parenthesis in main diagonal calculation of implicit vertical
    diffusion matrix (impldiff.F & gad_implicit_r.F).
    This affects results at machine truncation level; update output of many
    verification experiments (31 fwd ; 10 adm ; 8 tlm ; 3 oad).
o pkg/mom_commom & generic_advdiff:
  - add deep atmosphere and anelastic scaling factor in implicit vertical
    advection routines (mom_u,v_implicit_r.F & gad*_impl*_r.F).
o model/src:
  - remove few unnecessary temp array copies in solve_tridiagonal.F
    & solve_pentadiagonal.F

checkpoint65z (2016/09/28)
o pkg/seaice: fix multithreading for seaice_fgmres.F
  - remove unecessary variables from common blocks
  - use extra dimension MAX_NO_THREADS for all variables of the Krylov space
    basis, that are stored in commom blocks (including integer variable i1)
  - clean up code a little by removing commented lines that refer to
    original code
  - turn on multi-threaded test for experiment offline_exf_seaice.dyn_jfnk.
o MITgcm manual:
  - add uptodate pkg/ecco documentation to the manual (section 8.1; ecco.tex),
    preliminary documentation for generic controls (8.3; ctrl.tex),
    a placeholder for smooth (8.4; smooth.tex), and comment out the deprecated
    ecco_costfunction.tex
o pkg/ecco:
  - update and cleanup list of CCP options
  - re-assign gencost_mask to specify masks rather than gencost_errfile; 'c'
    is now always passed to cost_generic; gencost_mask is now MAX_LEN_FNAM
  - add checks that retired run-time options are not used, and in relation
    to gencost_mask and gencost_errfile
  - finish deprecating gencost_scalefile, gencost_smooth2Ddiffnbt, and
    gencost_nrecperiod
  - fix m_eta computation for virtual salt flux case
  - add m_horflux_vol case (selected via gencost_barfile) that computes
    transports via cost_gencost_boxmean (gencost_flag=-3)
  - use gencost_flag more systematically (i.e., avoid using gencost_name)
    for code switches (aside from physical variable selection)
o pkg/seaice: make seaice_fgmres.F fit for multithreading; this first
  attempt appears to be a bit of a hack and my need some repair down the road
o pkg/exf:
  - interpolation near South Pole: fix criteria on input field latitude.
o pkg/icefront & pkg/exf:
  - move setting of icefront Sub-Glacial RunOff forcing (currently unused)
    from pkg/exf (read from data.exf) to pkg/icefront (read from data.icefront)
o pkg/exf:
  - replace CPP option ALLOW_EXF_OUTPUT_INTERP with run-time parameter
    "exf_output_interp" (in namelist: EXF_NML_04); change output file name
    (add suffix "_out" instead of a prefix); keep same record number as in
    input file but always write record 1 first (to avoid a STOP in I/O S/R).
    Change output file content by writing interpolated field before applying
    land-sea mask (helpful for debug).
  - 2 compon. vector interpolation with rotation: apply scaling factor on
    each compon. (Eastward and Northward) just before rotation.
o pkg/bling:
  - Cleaned package. Removed not needed code and comments.
  - adjoint example now works
    (MITgcm_contrib/verification_other/global_oce_biogeo_bling/code_ad)
o pkg/ptracers:
  - add Bruno Deremble's code to complete the linear surface correction
    for tracer conservation;
  - enabled for individual ptracers by PTRACERS_linFSConserve(iTr)=.TRUE.

checkpoint65y (2016/07/29)
o pkg/debug (stats):
  - change GLOBAL_SUM to GLOBAL_SUM_TILE (result independent of tile to
    proc/thread mapping);
  - fix Min & Max for case where 1 thread has only empty tiles;
  - use RL variable to count number of wet grid points (with big domain,
    can be too large to fit into integer*4).
o pkg/monitor:
  - use RL variable to count number of wet grid points (but used only for del2)
  - add new routine to compute Advective CFL within tracer time-stepping with
    writing delayed until next monitor output.
o pkg/obcs:
  - fix bug in OBCS_BALANCE_FLOW (OBCS_balanceFacN misspelled OBCS_balanceFacW)
o pkg/cal:
  - calandar-dump: treat case myTime < timePhase in the same way as in
    eesupp/src/diff_phase_multiple.F (when not using calandar-dump).
o pkg/dic & seaice:
  - fix compilation of ocean component for coupled atm+ocn model with
    seaice dynamics & dic.

checkpoint65x (2016/06/11)
o add a license text file in main MITgcm tree.
o added pkg/bling:
  - intermediate complexity biogeochemical model
  - see bling_description.txt for details
  - verification experiment is global_oce_biogeo_bling (for now, in
    Contrib/verification_other/); tested daily on baudelaire with gfortran.
  - add entry point in pkg/gchem for new pkg "bling".
o pkg/seaice: fix tensile stength computation
  - replace global field tensileStrength by tensileStrFac
  - tensileStrFac can be computed once in S/R seaice_init_varia
  - fortunately that does not affect any verification results

checkpoint65w (2016/05/12)
o pkg/ctrl/ctrl.h: fix a comma in common block list, so that code compiles
     with ECCO_CTRL_DEPRECATED defined
o verification/global_ocean.cs32x15:
  - change secondary test "viscA4" to also test "selectP_inEOS_Zc=3"
    with "selectNHfreeSurf=1".
o model/src (non-hydrostatic free-surface):
  - More "natural" expression of NH free-surface term (case selectNHfreeSurf=1):
    was: tmpSurf/(1+tmpSurf); changed to: 1/(1+Gamma) with Gamma=1/tmpSurf.
  - Calculate surface vertical velocity after 2-D solver adjustment (accounts
    for EmPmR if RealFreshWaterFlux); used in RHS (cg3d_b) if exactConserv
    and used to compute dPhiNH (in post_cg3d.F) if selectNHfreeSurf=1.
    This fixes EmPmR contribution when selectNHfreeSurf=1 & RealFreshWaterFlux.
  - Update output (changes at machine truncation level) of verification exp:
    exp4 (11 digits for cg2d), global_ocean.cs32x15.viscA4 (11.d),
    short_surf_wave (13.d) and tutorial_deep_convection.smag3d (12.d).
o pkg/seaice: ITD code
  - fix picking up from a single category model by initialising
    heff/area/hsnowITD = 0. in seaice_itd_pickup.F
  - split a long warning message in seaice_check_pickup.F into two lines,
    because NEC SX-ACE cannot deal with the long line.
o model/src:
  - fix missing dPhiNH in pressure_for_eos.F (case: selectP_inEOS_Zc=3)
o pkg/seaice:
  - add missing checks for SEAICE_ALLOW_KRYLOV and SEAICE_ALLOW_BOTTOMDRAG
o pkg/seaice:
  - add basal stress as parameterisation for grounding ice
    following Lemieux et al. (2015)
  - turn on by setting new parameter SEAICEbasalDragK2 to a value
    larger than 0. Lemieux et al. (2015) recommend 15.
  - The adjoint complains with extra recomputations so there is also a
    new cpp-flag SEAICE_ALLOW_BOTTOMDRAG that is undefined by default in
    order to postpone the problem
  - compile the new code in lab_sea
o verification/halfpipe_streamice:
  - update both TAF and OpenAD adm output (machine truncation differences)

checkpoint65v (2016/04/08)
o verification/advect_xz:
  - increase overlap size from 3 to 4 and add new secondary test for PQM
    advection scheme (with mono & wino limiter).
  - change main exp. to test PPM (with weno limiter) adv.scheme on Temp.
o model/src:
  - new parameters "top_Pres" & "seaLev_Z" (replacing Ro_SeaLevel and recently
    added phi0Ref) to set vertical axis origin and phiRef origin;
    keep Ro_SeaLevel for backward compatibility (with a warning).
   According to coordinate and fluid type:
    OCN in Z: top_Pres(Ref) (=rhoConst*PhiRef(1)), seaLev_Z (=rF(1), @ the top)
    ATM in Z: top_Pres(Ref) (=rhoConst*PhiRef(1)), seaLev_Z (=rF(Nr+1) @ bottom)
    OCN in P: top_Pres (=rF(Nr+1)), seaLev_Z (= PhiRef(Nr+1)/g, @ the top)
    ATM in P: top_Pres (=rF(Nr+1)), seaLev_Z (= PhiRef(1)/g, @ the bottom)
  - remove Ro_SeaLevel from ATM experiment parameter files;
  - in tutorial_global_oce_in_p, remove Ro_SeaLevel and set top_Pres to the
    complement; update output.txt (changes at machine truncation level).
o pkg/seaice/seaice_evp.F
  - simplify computation of deltaZ and zetaZ to simple averaging following
    Bouillon et al. (2013). This removes a lot of code, but also changes
    verification experiment lab_sea.hb87 -> updated

checkpoint65u (2016/03/14)
o pkg/generic_advdiff:
  - from Darren: add PPM and PQM advection schemes (number 40-42 and 50-52)
    with 2 types of limiter (see: Engwirda & Kelley, submit. to JCP);
    Note (from Darren): unlimited PPM/PQM scheme (40 & 50) are just for
    testing and not for actual use.
o model/src:
  - add parameter "phi0Ref" to specify reference [pressure/geo] potential at
    origin r = rF(1);
  - add options (parameter selectP_inEOS_Zc) to select which pressure to use
    in EOS for height coordinate: enable to include NH Pressure or to use
    more accurate pressure vertical profile; options not linked to EOS type
    (as previously, e.g., JMD95P/JMD95Z) but set default according to EOS type;
  - start to implement variable gravity (along vertical): for now, only with
    z-coords (not even z*).
  - add Ideal Gas equation of state for height coordinate.
  - update OpenAD output (affected at machine truncation level) of exp:
    global_ocean.90x40x15, OpenAD (std) and tutorial_global_oce_biogeo.
o pkg/exf:
  - add ALLOW_EXF_OUTPUT_INTERP cpp switch to output the result
    of exf interpolation (before any rescaling, rotation or interpolation
    to velocity point) for each field that gets loaded from file. This option
    identically mimics the input file organization (e.g. record numbers in year
    by year input files) besides the change in horizontal grid.
  - add rotateStressOnAgrid run-time switch so that wind stress fields
    can be provided on the A-grid in zonal/meridional direction and
    rotated on the fly. This only applies to the case when the exf
    interpolation is off and rotateStressOnAgrid is false by default.
o model/src:
  - rename internal parameter "useDynP_inEos_Zc" to "storePhiHyd4Phys" (since
    it's also used with pkg/atm_phys) and add few more parameters (but still
    inactive, src code yet to come)

checkpoint65t (2016/02/10)
o pkg/atm_phys:
  - from Ruth Geen: add optical depth dependence on CO2 concentration.
o model/src:
  - fix vertical inter/extra-polation of density factor rhoFacF (for anelastic)
    for the case setCenterDr=T (delRc set from "data"); add output of rhoFacC&F.
    Update output of exp. deep_anelastic (changes at truncation level).
o tools:
  - add a hack in "remove_comments_sed" (used only with TAF) for recent
    version of OpenMPI (shipped with FC.23): comment out the new header
    file "mpif-sizeof.h" which causes problems to TAF.
o pkg/seaice:
  - change the termination criterion so that maxits (SEAICElinearIterMax)
    has an effect
  - unify iteration parameters for implicit solvers (JFNK and Picard)
    SEAICEnonLinIterMax replaces SEAICEnewtonIterMax/NPSEUDOTIMESTEPS
    SEAICElinearIterMax replaces SEAICEkrylovIterMax/SOLV_MAX_ITER
    SEAICEpreLinIterMax replaces SOLV_MAX_ITER in preconditioner
    SEAICEpreNL_IterMax replaces NPSEUDOTIMESTEPS in preconditioner
    SEAICEnonLinTol     replaces JFNKgamma_nonlin
  - remove S/R SEAICE_FGMRES_DRIVER and put content into S/R SEAICE_JFKN
  - add new Picard-Krylov solver, compile with SEAICE_ALLOW_KRYLOV and
    use with SEAICEuseKrylov
o pkg/seaice/seaice_lsr.F
    fix small bug: replace zetaZ by zetaZloc in S/R seaice_lsr_rhsu/v; only
    relevant if SEAICEuseStrImpCpl=T, and even then it does not seem to have
    an effect.
o pkg/seaice: add two new parameters
  - SEAICEuseLSR to simplify the logic in seaice_dynsolver (this
    parameter is not in any namelist)
  - SEAICEusrPicardAsPrecon to allow s/r seaice_lsr to be used as
    a preconditioner for the non-linear Newton iteration of the JFNK
    solver
o pkg/seaice/seaice_lsr.F: replace 1./SEAICE_deltaTdyn with recip_deltaT,
  affects some experiments at truncation level:
  - global_ocean.cs32x15.icedyn (11 digits),
  - global_ocean.cs32x15.seaice (11 digits),
  - seaice_itd (12 digits), seaice_itd.lipscomb07 (12 digits) -> update
  - also update global_ocean.cs32x15 adjoint and tangent-linear results
o pkg/salt_plume & pkg/thsice:
  - for coupled  set-up with pkg/thsice in ATM and pkg/salt_plume in OCN,
    connect salt_plume flux to ATM-OCN coupling pkgs interface:
   a) in ATM: also cumulate salt-plume flux in S/R THSICE_SALT_PLUME (for
     export to coupler interface) even without compiling pkg/salt_plume ;
   b) in OCN: apply coupler salt-plume flux to pkg/salt_plume field
     (saltPlumeFlux) just before exch call, in S/R SALT_PLUME_DO_EXCH.
o pkg/dic:
  - use the updated seaice fraction (from seaice pkgs) for DIC forcing
    instead of the previous time-step value ; done in new S/R DIC_FIELDS_UPDATE
    called from the top of dic_biotic_forcing.F (instead of in DIC_FIELDS_LOAD);
  - move also update with values from ATM-OCN Coupler in the same new S/R
    (previously done in ocn_apply_import.F).
o tools/adjoint_options:
  - specify explicitly "-f77" or "-f90" in default ad-optfile since TAF (default)
    has been changed on Jan 14, 2016.
o pkg/ggl90:
  - add alternative discretisation of vertical shear (off by default), to
    compute the mean (@ grid-cell center) of vertical shear compon instead of
    vertical shear of mean flow (@ grid-cell center).
  - add correct parenthesis in ALLOW_GGL90_SMOOTH code to get the same truncated
    results on adjacent faces of cubed-sphere grids; this fix the restart.
o pkg/atm_compon_interf:
  - skip time-ave over cpl_atmSendFrq of Sea-Level Pressure (atmSLPr) and just
    pass last value, stored directly before export to CPL ;
    Note: this affects results of Coupled set-up where OCN uses useImportSLP=T
  - remove atmSLPr from pickup files (no longer needed for restart)

checkpoint65s (2016/01/13)
o eesupp & genmake2:
   - first check for Function ETIME and, if it fails, then check for subroutine
     ETIME and consistent output; use the appropriate version in timers.F
o model/src:
  - to check restart test, add option to apply EXCH to U,V earlier, just before
    integr_continuity; turned off by default.
o pkg/dic:
  - remove CPP option USE_ATMOSCO2 (not needed)
o tools/tst_2+2:
  - try to ignore difference between +0 and -0 in binary file, causing test
    to fail for no good reason.
o eesupp & genmake2:
  - put back modif from Jinxuan Zhu - change etime fct call to S/R call -
    but also check (in genmake2) that test runs and returns meaningful results.
o coupler pkgs:
  Finish implementation of optionally-exchanged variable switches (started on
   Nov 12) with addition of few more exchanged fields, including 2-way exchange
   of pkg/thsice vars to allow to use seaice dynamics (from pkg/seaice) & seaice
   advection in OCN component; this requires sequential coupling.
  coupler (pkg/atm_ocn_coupler):
  - add argument msgUnit and iter number to CPL_SEND/RECV_ATM/OCN_FIELDS
    routines (useful for debug).
  - only export/import optionally exchanged fields (RunOff, seaice, Salt-Plume
     flux, DIC fields) if corresponding switch is ON.
  - add option to export RunOff to OCN (to use for DIC river input)
  - add 2-way thSIce vars exchange; check for consistent cpl_sequential setting.
  components (pkg/atm_ & ocn_compon_interf):
  - to save memory space in ATM & OCN comp: add some #ifdef ALLOW_${PKG} around
    optionally exchanged fields; add a check & stop in cpl_readparms.F.
    ATMCPL.h: ALLOW_LAND for RunOff, ALLOW_THSICE for seaice, ALLOW_AIM for CO2;
    OCNCPL.h: ALLOW_SALT_PLUME, ALLOW_DIC for DIC, ALLOW_THSICE for 2-W thsice.
  - rename:   fracIce     -> sIceFrac_cpl (<- match coupler var name)
    + in ATM: fracIceTime -> sIceFracTime ; seaIceTime -> sIceMassTime.
  - add 2-way thSIce vars exchange ; add Salt-Plume flux ; add RunOff in OCN.
  - hold in common block coupler optionally-exchanged variable switch
    and set default "useImportXXX" accordingly; + check & stop if inconsistent.
  - add diagnostics for all imported fields from coupler (in both OCN & ATM);
    this is intended to replace the OCN cplFldtave.* output files (not updated
    to contain new additional exchanged fields).
o pkg/dic:
  - fix an other bug (also from 2014/08/30) in dic_atmos.F, in dic_int1=3 code.
o pkg/thsice:
  - when coupled to ATM (useCoupler) with thSIce_skipThermo=T, skip reading
    and writing of thsice pickup files.
o pkg/atm_compon_interf:
  - move all field individual export-call out of cpl_export_import_data.F
    into new S/R ATM_EXPORT_FIELDS
o pkg/atm_compon_interf:
  - store state variables (for now, only thSIce fields) just before beeing
    exported (in cpl_export_import_data.F, like on ocean side) instead of from
    atm_store_my_data.F like all exported fluxes.
  - new version of pickup_cpl: write field names into meta file and read meta
    file to find field postion in pickup. Also only write/read fields meeded for
    restart (same logic as main pickup file ; also using pickupStrictlyMatch)
o pkg/dic:
  - fix bug (added on 2014/08/30) in dic_atmos.F for the case dic_int1= 2 or 3.
o pkg/seaice: add new parameter SEAICEpressReplFac to choose between
    pressure replacement method (=1., default) or original Hibler (1979) (=0.)
    value can be from domain [0,1] to average between the two methods
o pkg/atm_phys:
  - allow to provide 2-d map of albedo and mixed-layer depth from files (but
    hold fixed in time).

checkpoint65r (2015/12/21)
o pkg/seaice:
    fix bug in tridiagonal solvers for SEAICE_OLx/y>0, this affects the JFNK
    solver (offline.dyn_jfnk) and global_ocean.cs32x15.seaice -> updated
o pkg/seaice:
  - fix a bug in computing areaS in (J-J -> J-1) that affects runs
    when SEAICEscaleSurfStress=.TRUE.,
  - apply areaW and areaS in S/R seaice_calc_lhs
o pkg/atm_phys:
  - add diagnostics for 3-D, Nr+1 levels diagnostics of radiative fluxes
    (shortwave & longwave, net & downward) and diagnostics of temp. tendency
    for individual contribution (convection, LSC cond, radiation)
  - add Ruth Geen etal, GRL 2016, radiation options (see paper supp.
    information); activated with: solar_exponent=0. and wv_exponent=-1.
o pkg/ggl90:
  - within IDEMIX add upper limit for horizontal group velocity to
    avoid instability problems in the explicit horizontal diffusion term for
    long time steps or high resolution
o pkg/diagnostics:
  - simplify setting of local-array size in diagstats_output.F: uses "numLevels"
    (from DIAGNOSTICS_SIZE.h) to allow to write out more than Nr levels.
o testreport:
  - remove "-v" (verbose option) in default mpirun command.
o pkg/seaice/seaice_growth:
  - catch potential division by zero in ITD code, does not change
    verification results
o pkg/ecco:
  - retire old codes to the Attic. The calls to retired functions are
    left in a commented form in case they ever need to be re-activated.
  - ecco_check.F: issue warning if any old CPP option is
    defined that corresponds to retired codes -- then stop.
o pkg/atm_compon_interf:
  - change seaice fraction (use for OCN dic surf.flux) stored and sent to
    coupler: use last time-step value instead of average over cplSendFrq_iter
    time-step, similar to what is done for seaIceMass.
    This will affect results (pkg/dic) of coupled ATM-OCN+dic set-up.
o eesupp & genmake2:
  - from Jinxuan Zhu: change etime fct call to S/R call (fix gfortran ETIME);
    <= remove until a fix is found for some ifort version on ia32 machine.
o pkg/seaice/seaice_evp:
  - refine residual computation

checkpoint65q (2015/11/18)
o pkg/seaice/seaice_evp:
  - fix residual computations so that they no longer affect the actual
    simulation code
  - fix seaice_readparams to be able to actually set new parameters
    SEAICEaEVPcStar and SEAICEaEVPalphaMin, also fix logic a little
o model/src:
  - fix wrong truncation (single prec) from "FLOAT" function in expressions
    like: deltaT*FLOAT(myIter) when myIter is large:
     a) replaced by DFLOAT (if not seen by TAF);
     b) remove "FLOAT" and use implicit type conversion (if seen by TAF).
o pkg/aim_v23:
  - write/read the expected CO2 pickups (from S/R AIM_DO_CO2): fix reading
    when pickupSuff is set ; do write rolling pickups + at the end of the run.
o pkg/atm_ocn_coupler + ocn_compon_interf:
  - in prep for using pkg/seaice Dyn in coupled set-up, implement sequential
    coupling option-1: ATM -(cpl)-> OCN and then OCN -(cpl)-> ATM ;
    add corresponding call in DO_OCEANIC_PHYS.
o coupler pkgs:
  Start a new way to set-up optionally-exchanged variables (previously, only
   there for exchange_DIC): switch on/off from 1 place, at run-time, in coupler
   data.cpl (new) instead of at compile time in ATMIDS.h & OCNIDS.h ;
   send switch to ATM & OCN compon before reading their own "data.cpl" (so that
   compononent param default can be set accordingly).
  Note: this new switch (cpl_exchange_[xxx]) is not a per variable switch
   but rather applies to a group a fields (going both ways like for DIC)
   and corresponds to an option of coupling config.
  coupler (pkg/atm_ocn_coupler):
  - change parameter file from "data" to "data.cpl" (in cpl_read_params.F),
    and read namelist directly (without eessup S/R calls) instead of
    in the very un-flexible old way, 1 param per line, in fixed order;
  - add error-counter to track errors (e.g., missing "data.cpl") and to stop
    cleanly in CPL_CHECK_CPLCONFIG
  - add new coupling-exchange selectors (some not yet active) including
    cpl_exchange_DIC (to set to 3 to replace atmCpl_exchange_DIC=T in ATMIDS.h
                                         and ocnCpl_exchange_DIC=T in OCNIDS.h);
  - add 2 new S/R (CPL_SEND_ATM/OCN_CPLPARMS) to send coupler-params to each
    component ; called directly from coupler.F, after comp. registrations;
  - rename few variable-ID names (in ATMIDS.h & OCNIDS.h):
     atm/ocnSeaIceName --> atm/ocnSIceMassName ; atm/ocnFCO2Name ->
      -> atm/ocnCO2FluxName ; atm/ocnWSpdName --> atm/ocnWindSpdName
  components (pkg/atm_ & ocn_compon_interf):
  - add ATM/OCN_CPL_OPTIONS.h in component pkgs and include the corresponding
    CPP header file in all pkg source files.
  - move checking of comp. configs out of cpl_exch_configs.F into new S/R
    ATM/OCN_CHECK_CPLCONFIG;
  - add error-counter to track errors (e.g., in "data.cpl") and to stop
    cleanly in ATM/OCN_CHECK_CPLCONFIG;
  - add new S/R CPL_IMPORT_CPLPARMS to import coupling-exchange selectors
    from coupler ; called from initialise_fixed.F, after PACKAGES_BOOT and
    before PACKAGES_READPARMS;
  verification/cpl_aim+ocn/:
  - update ATMIDS.h & OCNIDS.h (in shared_code) and use new parameter file
    "data.cpl" for coupler (in input_cpl).
o eesupp/inc:
  - change the MPI-global-sum default (in CPP_EEOPTIONS.h) to:
    #define GLOBAL_SUM_ORDER_TILES (only affects MPI built of global_sum_tile.F)
    to always cumulate tile local-sum in the same order (still uses
    MPI_Allreduce like standard code).
  - in verification experiment code, remove local CPP_EEOPTIONS.h_mpi files
    that are now identical to standard version (in eesupp/inc).
o pkg/shelfice:
  - add SHELFICETransCoeffTFile for initializing spatially varying
    heat and salt transfer coefficients
o pkg/atm_compon_interf & ocn_compon_interf:
  - combine into 1 (new) S/R CPL_EXPORT_IMPORT_DATA the two previous
    S/R CPL_EXPORT_MY_DATA & CPL_IMPORT_EXTERNAL_DATA
  - move bi,bj loops inside S/R OCN_STORE_MY_DATA
o pkg/atm_ocn_coupler:
  - initialise to zero ATMVARS.h & OCNVARS.h arrays.
o pkg/rbcs:
  - select RBCS-mask for Temp & Salt the same way as for pTracer ; this allows
    to compile with maskLEN=1 when all tracers use the same RBCS-mask.
  - add a short report (to STDOUT) about RBCS-mask settings.

checkpoint65p (2015/10/23)
o pkg/seaice/seaice_evp.F: fix store directives and key computations, since
    there is no adjoint test for EVP, we don't know what it does to the adjoint
    solution, but at least there are no more recomputation warnings left
o pkg/seaice/seaice_evp.F: slight modification of averaging so that EVP stands
    a chance of giving the same results as a fully converged VP (JFNK) solver
o tools/adjoint_options/adjoint_diva:
  - fix bug (typo) in Tang-Linear FLAGS setting for MPI + DIVA
o pkg/streamice:
  - spotted bug in streamice_driving_stress using dyG where should have been dxG
o pkg/exf:
  - remove STOP statement that prevented to use wind or (wind-)stress
    interpolation for constant-in-time forcing fields (wind/stress period = 0).
o pkg/seaice:
  - replace SEAICE_EVP_USE_ADAPTATION by run time parameters, requires
    5 additionals 2D fields and 6 new store directives
  - change logic in seaice_readparms.F: EVP code can now be turned on in
    various ways, setting SEAICE_deltaTev is no longer required,
    alternatively set SEAICE_evpAlpha/Beta, SEAICEuseEVPstar, SEAICEuseEVPrev,
    or SEAICEaEVPcoeff
o pkg/shelfice/shelfice_thermodynamics.F
  - redefining uLoc/vLoc to u/v, instead of 2u/v
o pkg/seaice/seaice_evp.F: introduce "adaptive EVP" by Madlen Kimmritz
  - this is an intermediate state of a truely converging EVP that has
    the potential of outperforming implicit VP methods, I do not recommend
    using it yet.
  - for now, "adaptive EVP" is turned on by setting SEAICE_EVP_USE_ADAPTATION
    and all parameters are hardwired
  - for convergence it still requires very smooth regularisations, that means,
    if SEAICE_DELTA_SMOOTHREG is defined, deltaCreg=deltaC+deltaMin, which is
    different from the VP case with deltaCreg=sqrt(deltaC**2+deltaMin**2); also
    specific averaging appears to be required, still subject to tuning
  - still needs cleaning and I need to turn parameter into runtime parameters
  - add code to compute and print residuals of iteration, compile with
    defining ALLOW_SEAICE_EVP_RESIDUAL to enable it
o pkg/seaice/seaice_evp.F: fix a bug (factor of four in front of e12Csq)
  that entered with r1.54 on Sep04, 2015, -> update results

checkpoint65o (2015/09/14)
o pkg/mom_vecinv & mom_common:
  - add deep-atmosphere geometry factor in mom_calc_visc.F + in routines
    called from there.
  - add anelastic and deep-atmosphere geometry factor in pkg/mom_vecinv ; this
    allows to use Vector-Invariant form in deep atmos and anelastic formulation
o pkg/seaice: introduce fast ice parameterisation following Itkin et al. (2015)
  and Koenig-Beatty+Holland (2012)
  - two new parameters SEAICE_tensilFac and SEAICE_tensilDepth
  - global 2D field tensileStrength, computed in seaice_calc_ice_strength
  - requires an extra input argument for S/R seaice_calc_viscosities
  - tensileStrength's depth dependence is different from Itkin et al. (2015)
    (to be changed and played with, for now exponential)
o pkg/seaice: introduce new parameter SEAICEscaleSurfStress (default = .FALSE.)
  - if TRUE scale ice-ocean and ice-atmosphere stress acting on sea ice
    by AREA according to Connelly et al. (2004), JPO.
  - For EVP and the LSR solver, the implicit part of the drag term is
    the only non-zero term in the denominator when there is no ice (which
    prevented running the model with zero ice-ocean drag). If
    SEAICEscaleSurfStress = .TRUE., this results in a division by zero
    (or zero main diagonals BU/BV) which need to be caught. A practical
    consequence is that for open water, the momentum equation reduce
    to trivially 0 = 0 + 0 (for EVP). For LSR, BU/BV are reset to 1, if
    they happen to be zero, often leading to a non-zero solution over
    open water.
o pkg/seaice: revise EVP code (seaice_evp.F) in preparation for a more
    efficient EVP method.
  - introduce area-weighted averages for e12 (analogously to
    seaice_calc_viscosities.F); this totally changes lab_sea.hb87 (2 digits
    remain, but also changing the order of terms in the previous average
    changed the results as much) -> update experiment
  - add SEAICE_DELTA_SMOOTHREG code
  - disentangle computation of zetaC/deltaC and zetaZ/deltaZ, also for
    TEM-code
  - adjust loop bounds so that only required fields are computed
  - add new averaging code for zetaZ/deltaZ (again similar to
    seaice_calc_viscosities.F), inactive by default for now (will change
    results again), but will replace old code eventually
o eesupp/src:
  - add an other alternative for multi-proc GLOBAL_SUM (in global_sum_tile.F)
    to always cumulate tile local-sum in the same order
    (option #define GLOBAL_SUM_ORDER_TILES in CPP_EEOPTIONS.h).
    Still uses MPI_Allreduce (like standard code) but on array of tiles
    and should be faster than GLOBAL_SUM_SEND_RECV code.
  - switch almost all verification experiments that use GLOBAL_SUM_SEND_RECV
    (defined in CPP_EEOPTIONS.h_mpi) to GLOBAL_SUM_ORDER_TILES instead.
  - add CPP_EEOPTIONS.h_mpi with GLOBAL_SUM_ORDER_TILES defined in 14 more exp.:
     aim.5l_cs, cheapAML_box, deep_anelastic, dome, fizhi-cs-32x32x40,
     fizhi-cs-aqualev20, fizhi-gridalt-hs, global_ocean_ebm, matrix_example,
     natl_box, solid-body.cs-32x32x1, tutorial_advection_in_gyre,
     tutorial_baroclinic_gyre and tutorial_held_suarez_cs.

checkpoint65n (2015/07/29)
o pkg/thsice:
  - add a warning when used with pkg/aim but without updating SST
    (stepFwd_oceMxL=F & useCoupler=F & tauRelax_MxL<>-1 ).
o pkg/offline:
  - change where Offline-Fields are loaded, from load_fields_driver.F to
    directly within FORWARD_STEP, just after updating iter number and time;
  - move setting of GM and KPP diffusivity out of OFFLINE_FIELDS_LOAD into new
    S/R OFFLINE_GET_DIFFUS that is called towards the end of DO_OCEANIC_PHYS;
   These changes allow:
    a) to recover exactly on-line results using deltaToffline=deltaTClock,
    tested (using offlineIter0= nIter0 -1 and offlineTimeOffset= -deltaT/2)
    both with Lin & Non-Lin Free-Surf, both with staggerTimeStep & synchronous
    time-step, both with GM & KPP files and with recomputing these fields;
    b) no needs to switch on staggerTimeStep anymore;
    c) simplify rescaling of offline horiz. velocity with Non-Lin Free-Surf.
  - update output of experiment tutorial_dic_adjoffline (only 3 digits left).
o pkg/offline:
  - change (rarely used) offset-iteration parameter to an offset time (in s):
    can easily recover previous offset-iter effect by setting offset-time
    (offlineTimeOffset) to offset-iter x deltaToffline;
  - do not turn-off Temp & Salinity surface relaxation when using KPP (used
    in KPP as part of surface buoyancy forcing) in offline run.
  - fix ptracers KPP non-local term in the case where KPP is re-computed.
o OpenAD
  - Adding preliminary ggl90 test to OpenAD verification.
    Config. with ggl90 currently diverges after 64 time steps
    so will need more work to become more stable
  - Adding preliminary kpp test to OpenAD verification.
    required small tweakes in kpp_routines.F
  - Merge and update from Krishna Narayanan's contrib area:
    * Add one variable for preliminary OpenAD DIVA
    * Add replacement time-stepping for OpenAD DIVA
    * genmake2 flag -diva (but only for OpenAD; preliminary)
    * required modifs for OAD_support
    successful preliminary test for tutorial_global_oce_biogeo/
o pkg/seaice:
  - initialise deltaC in seaice_lsr, cosmetic changes in seaice_lsr
  - add cpp-flag SEAICE_DELTA_SMOOTHREG for option of regularising
    delta with a smooth function in s/r seaice_calc_viscosity
    (no effect on EVP)
  - rename local suffix "sqr" into "sq" for more consistent variable names
o pkg/seaice:
    add new parameter SEAICE_deltaMin that is used ***only***
    for regularizing Delta (and nothing else, like the parameter
    which is also used for all sorts of things SEAICE_EPS).
    Defaults to SEAICE_EPS for backward compatibility only.
o pkg/seaice: replace erroneously storing e12Csqr on the wrong tape with
    the wrong key by inialising it before use -> fixes a recomputation
    problem but does not fix the gradient
o pkg/layers:
  - move resetting of flux arrays to outside the iLa loop
    (this caused layers_diapycnal to not work with more than one layer coord.)
  - fix bug in calculation of layers_recip_delta in layers_init_fixed.F
o pkg/layers:
  - remove from common block 3D layers fields (used to diagnose transport
    in tracer coords) and declare them as local arrays in layers_calc.F
o pkg/seaice:
  - Rename SEAICE_VECTORIZE_LSR_ZEBRA to SEAICE_LSR_ZEBRA and define it
    in lab_sea forward experiment (changes results -> updated)
  - update adjoint experiment lab_sea after cleaning up seaice_lsr_tridiagu/v
o pkg/seaice: modify seaice_lsr.F in order to improve the gradient
   computations; for SEAICE_VECTORIZE_LSR
  - move the loops over which the tridiagonal solvers (seaice_lsr_tridiagu/v)
    sweep to the outside,
  - remove store directives and add "CADJ loop sequential" directives
    in analogy to model/src/solve_tridiagonal.F
  - replace many "#ifdef SEAICE_VECTORIZE_LSR_ZEBRA" by variable loop
    boundaries to yield more readable code. This has also the charming side
    effect that your can use SEAICE_VECTORIZE_LSR_ZEBRA without
    SEAICE_VECTORIZE_LSR (i.e. adjoint without recomputations in
    seaice_lsr_tridiagu/v now requires either of these flags, vectorization
    still requires SEAICE_VECTORIZE_LSR with SEAICE_VECTORIZE_LSR_ZEBRA as
    an additional option)
   The tridiagonal solvers are now completely analoguous to solve_tridiagonal.F
   but the adjoint gradients (which are affected by this change) still explode.
o coupler (atm & ocn _compon_interf):
  - avoid using Exch2 IO mapping if not suitable.

checkpoint65m (2015/06/15)
o pkg/layers:
  - clean-up old parameters setting (from Sep 2012):
    + remove old parameters setting from common block (declared locally);
    + stop if any old parameter is mixed with new parameters;
    + check for valid or consistent parameter setting (e.g., layers_name)
  - check that layers_bounds for Pot.Density are in the right range;
    this is supposed to catch un-updated setting after recently shifting
    potential density field "prho" by -1000 (now in "sigma" scale).
o pkg/layers:
  - Added missing call to layers_fill for keeping track of tottend in
    pkg/diagnostics/diagnostics_fill_state.F
o pkg/layers:
  - added CPP flux LAYERS_FINEGRID_DIAPYCNAL to disable fine-grid binning
    of diapycnal fluxes
o pkg/layers:
  - reverted changes to interpolation to previous treatment; there
    was never actually a problem
o pkg/layers:
  - fix interpolation of layers tracers in the presence of partial cells
  - add lots of new functionality to compute water mass transformation
    (enabled by CPP flag LAYERS_THERMODYNAMICS)
  - add new calls from main code (diags_oceanic_surf_flux.F,
    thermodynamics.F, impldiff.F) and gad to save the necessary fields
    for layers_thermodynamics calculations
o pkg/ptracers:
  - add capability of stepping a passive tracer forward without advection
    by setting PTRACERS_advScheme to 0.
o pkg/diagnostics:
  - add few (threads) _BARRIER around any update of "diag_pkgStatus".
o pkg/layers:
  - shift potential density field "prho" by -1000 for density layer averaging so
    that it corresponds to usual "sigma" definition (i.e., rho(p=const)-1000);
    Note that density bin boundaries (layers_bounds in data.layers) have
    to be set accordingly (i.e., shifted, in sigma scale).
o pkg/layers:
  - fix snap-shot output of layer thickness @ V.pt and output of pot.density
  - fix calculation of layer non-weighted velocity and layer probability
  - add diagnostics for pot.density used for layer averaging
o pkg/seaice:
  - seaice_calc_viscosity.F: change computation of deltaC**2 to ensure
    positiveness, modify a few comments and improve variable names,
  - the changed computation of deltaC affects most seaice-related
    experiments at the truncation level.
    seaice_itd.thermo is affected by far the most, with
    only 7 digits of agreement remaining; update experiments.

checkpoint65l (2015/05/04)
o pkg/shelfice:
  - in shelfice_thermodynamics.F, if SHELFICEBoundaryLayer=.true., then set
    factor drKp1 to zero where it is negative (ie. do not use
    SHELFICEBoundaryLayer if hFacC>1)
  - the same for factor drLoc in shelfice_forcing.F
o tools/genmake2: move FEXTRAFLAGS from FFLAGS to FOPTIM to avoid a problem
    with modules in ptracers, when using testreport option "-small_f"
o pkg/seaice/seaice_growth.F (in case of SEAICE_ITD)
  - replace tmpscal1**1.36 by faster exp(1.36*log(tmpscal1))
o verification/testreport
  - add new option -small_f
    with this option testreport first makes the target small_f (*.f files)
    before running make (all). This is useful for explicit inlining when
    all sources need to be full available.
o pkg/exf/exf_interp.F:
    remove previous changes related to reverse (decreasing) input grids latitude

checkpoint65k (2015/04/01)
o pkg/ecco:
    fix missing cosphi initialization; use eccoiter in place of optimcycle;
    if autodiff is not compiled then use READ_REC_XY_RL/READ_REC_XYZ_RL
    instead of active read/write
o pkg/ctrl:
    if autodiff is not compiled then use READ_REC_XY_RL/READ_REC_XYZ_RL
    instead of active read/write.
o pkg/autodiff: make autodiff_readparms.F and autodiff_whtapeio_sync.F
    return if .NOT.useAUTODIFF
o pkg/seaice: add CPP brackets (cost function related).
o model/src:
    add useAUTODIFF run time switch.
o pkg/exf/exf_interp.F:
    add code to allow input grids with latitude starting in the north (i.e. when
    j=1 corresponds to northern edge of field); modify global_with_exf to test
    this feature.
o verification/testreport:
  - replace "grep -A3" with POSIX conformal sed command, because there are
    implementations of grep that cannot do contextual searches
  - replace "cat -n" by "nl" (two occurrences), because not all implementations
    of "cat" have the option "-n"
o model/src:
    add new file gsw_teos10.F that contains 3 functions, more or less a copy
    of the gsw_toolbox.f90 of the TEOS-10 fortran interface, that are used to
    convert from conservative to potential temperature. For now they are not
    called anywhere.
o pkg/ggl90: make "useIDEMIX" useful
  - re-organize code in s/r ggl90_calc a little to move computations that
    are different for idemix into separate loops (changes verification
    experiment idemix at truncation level, 12 digits remain -> updated)
  - requires 2 new 2D fields KappaM, verticalShear
  - make hFacI and recip_hFacI local 3D variables that are passed to
    s/r ggl90_idemix
  - fix and improve some comments

checkpoint65j (2015/02/25)
o pkg/openad
  - synchronize seawater.F with version in model/src: replace routine
    body of sw_temp by calling sw_ptmp and fix/add a few comments.
o pkg/mnc:
  - change default value of pickup_read/write_mnc params to FALSE
    (since few features are missing in reading MNC pickup files).
o model/src:
  - change default (background) vertical diffusivity for salt to be the
    temperature (background) vertical diffusivity.
  - change background vertical diffusivity in vertical mixing pkgs ggl90,
    kl10, my82 and pp81 from temperature diffusivity to salinity diffusivity.
    This makes ptracers default diffusivity (that uses salt diffKr) more
    consistent with vertical mixing schemes.
o verification/testreport:
  - fix typo in "-pcls" option ;
  - put temp files in /tmp (instead of in local dir)
  - add option "-ncad" to use genmake2 new option "-nocat4ad"
  - allow to use "-j" option (for multi-procs make) for AD, OAD and TLM.
o pkg/ggl90 (idemix code):
  - apply few fixes ; add some missing "_d 0" ; update output of exp.
    global_ocean.90x40x15.idemix
o OpenAD
  - enable active file I/O and begin removal of work-around code
    for OpenAD for handling control variables (memory vs. active files)
  - new CPP options file OPENAD_OPTIONS.h
  - revert to genarr2d gradient check for hs94.1x64x5
  - (genarr3d tested by tutorial_global_oce_biogeo, tutorial_tracer_adjsens)
  - gentim2d works for halfpipe_streamice but not yet hs94.1x64x5
o tools/genmake2:
  - add option for an alternative Makefile (from Martin) where multiple
    source files are sent to TAF (instead of all in one file).
o pkg/ggl90: add IDEMIX (Olbers and Eden, 2013)
  - code provided by Carsten Eden as an extension of ggl90
  - so far the code is turned on within ggl90 by setting a CPP-flag at
    compile time; a runtime flag implementation is not yet complete
  - tested in new verification experiment global_ocean.90x40x15.idemix
o verification:
  - reduce length of the AD test run by half for experiments
    global_ocean.cs32x15 (std + thsice) and isomip
  - enable active file I/O for OpenAD, adjust verifications accordingly
  - halfpipe_streamice: change gradient check from genarr2d to gentim2d
o verification/testreport:
  - fix two non-POSIX sed statements so that there are no error messages
    on Mac OS X
  - replace hostname -s with hostname | sed 's/\..*$//'
o model/src/seawater.F:
  - simplify SW_TEMP to just calling SW_PTMP with P and PR exchanged
    (following the matlab code), which would have avoided the bug caught
    by Matt (see below) in the first place
o pkg/shelfice:
  - implement alternative discretisation of quadratic drag (selectBotDragQuadr)
    and true distance in no-slip BC (bottomVisc_pCell) similar to bottom-drag.
  - fix sign of friction tendency (no-slip BC) and fix u,v drag for thin
    ice-shelf case (i.e., within surface level).
  - add config summary in shelfice_check.F
  - remove global variable recip_SHELFICElatentHeat and replace by a local
    variable recip_latentHeat
  - introduce diagnostics for friction velocity uStar (in case of
    SHELFICEuseGammaFrict)
  - change verification experiment isomip.htd:
    + start from pickup (as input_ad at nIter0=8640)
    + start from SHELFICEmassFile instead of SHELFICEloadAnomaly file
    + test SHELFICEuseGammaFrict = .TRUE.
    + test SHELFICEadvDiffHeatFlux = .TRUE.
o model/src:
  - fix bug (Thanks to Matt) in function SW_TEMP (to convert Pot.Temp to
    in-situ Temp) and in routine SW_TEMP (in pkg/openad);
    update output of experiments global_with_exf.yearly and isomip (all 6).
o pkg/shelfice:
  - change setting of kTopC to also be zero where there is no ice-shelf.
  - zero out surface forcing arrays (for now, for T & S + EmPmR) where
    ice-shelf is.
  - first attempt to get RealFreshWaterFlux effects: for now, only without
    SHELFICEboundaryLayer ; not consistent if using synchronous time-stepping.
o pkg/seaice: add the option to prescribe a fixed thickness PDF
  for thermodynamic calculations
  - because of divisions of the type 7/7 not exactly equal to 1, this change
    affects results of some verification experiments by up to 4 digits:
    global_ocean.cs32x15.seaice, lab_sea, lab_sea.fd, lab_sea.salt_plume,
    seaice_obcs, seaice_obcs.seaiceSponge, seaice_obcs.tides
    adjoint: lab_sea, lab_sea.noseaicedyn
    -> updated

checkpoint65i (2015/01/23)
o model/src:
  - change units of frictionHeating field from W to W/m^2
  - fix bug in frictional heating from stratospheric drag in
    S/R ATM_PHYS_TENDENCY_APPLY_V
  - with synchronous time-stepping: move resetting to zero of frictionHeating
    field from load_fields_driver.F to thermodynamics.F ;
  - add diagnostics for frictional heating.
o model/src & gmredi K3D:
  - add frictionHeating field to pickup-files (for synchronous time-stepping)
  - move ALLOW_EDDYPSI block out of DYNVARS.h and merge it into FFIELDS.h
  - rename uMean,vMean --> uEulerMean,vEulerMean (+ change diagnostics name
    and name in pickup file).
  - fix arguments of few DIAGNOSTICS_FILL calls in gmredi_k3d.F
o model/src:
  - move (from ini_forcing.F) initialisation of all arrays in header file
    FFIELDS.h into new S/R ini_ffields.F ; this fix broken restart
    (since Nov 2012) with option selectAddFluid=1.
o pkg/shelfice:
  - change units (+ document) of newly added field "shelfIceMassDynTendency"
  - upgrade from _RS to _RL shelficeMass & shelficeLoadAnomaly arrays.
o pkg/obcs: re-organize obcs_calc_stevens.F to prepare for passive tracers
o pkg/seaice: two new runtime parameters:
  - SEAICE_cStar replaces the hard wired "20" in the strength formulation,
    long overdue
  - SEAICE_tensilFac: preparation for Koenig-Beatty+Holland (2012)
    parameterization of tensil stress for fast ice (does not do anything yet)
o pkg/seaice/seaice_check.F: left over from restricted addtive Schwarz method
    for LSR: move checking overlaps out of JFNK-if-block
o pkg/atm_phys:
  - move copy of grid and dynamical fields out of atm_phys_driver.F into
    new S/R ATM_PHYS_DYN2PHYS.
  - fix level height for Linear Free-Surf case (to be consistent with
    fixed-in-time pressure levels).
o pkg/mom_common (bottomdrag):
  - average bottomDragFld (ALLOW_BOTTOMDRAG_CONTROL) from grid-cell center
    to correct location (U & V point) in S/R MOM_U/V_BOTTOMDRAG;
    update output (adm & tlm) of experiment global_ocean.90x40x15.bottomdrag.
o pkg/shelfice (u/v_drag):
  - add one argument (the other velocity component) to S/R SHELFICE_U/V_DRAG;
  - use SHELFICEDragLinear & SHELFICEDragQuadratic in shelfice_v_drag.F
    (now similar to shelfice_u_drag.F)
  - remove condition on bottomDragTerms when calling SHELFICE_U/V_DRAG
    from mom_vecinv.F (similar to mom_fluxform calls).
o pkg/mom_common (bottomdrag):
  - add one argument (the other velocity component) to S/R MOM_U/V_BOTTOMDRAG;
  - add options for alternative discretisation of velocity norm in quadratic
    bottom drag: averaging of grid-cell-center KE to U.point and V.point
    (selectBotDragQuadr=0, original code) can produce noisy patterns; this
    improves when averaging only the other component (e.g. vVel for U bottom
    drag) using wet-point method (selectBotDragQuadr=2) or not (=1).
  - add options (bottomVisc_pCell) to account for partial-cell in bottom
    friction (no-slip BC) thus getting the true distance from the bottom;
    off by default since this also reduces model stability (explicit bottom
    friction). Changes produce different machine truncation with linear-drag
    + no-slip BC: update output of experiments exp4.stevens (10 digits) and
    front_relax (bvp & mxl, 10 & 11 digits).
o model/src & mom pkgs:
  - add one more level to vertical viscosity local arrays (Nr+1, previously Nr)
    since no-slip bottom BC uses viscosity @ k+1 to update velocity @ level k
  - for now and until vertical mixing scheme are updated to fill up level Nr+1,
    just copy level Nr value to level Nr+1.
o doc:
  - add notes form Abhisek Chakraborty on how to close Heat & Salt budgets.
o pkg/shelfice:
  - shelfice_init_varia.F, shelfice_init_fixed.F, shelfice_readparms.F,
    SHELFICE.h: move array shelficemass to init_varia, initialise
    from array shelficemassinit, which is set in init_fixed and
    has option to be set from file; introduce array
    shelficeMassDynTend array, set thru file in init_fixed
  - NEW FILE: shelfice_step_icemass.F: update shelficemass from either
    shelfIceFreshWaterFlux and shelficeMassDynTend or H_streamice in
    pkg/streamice
  - shelfice_thermodynamics.F: call shelfice_step_icemass if
    SHELFICEMassStepping = .true.
  - shelfice_ad_diff.list: add new subroutine shelfice_step_icemass.f

checkpoint65h (2014/12/17)
o verification/global_ocean.90x40x15, global_ocean_ebm:
  - update to generic controls.
o pkg/ctrl:
  - ctrl_map_ini_genarr.F: test for igen>0
  - ctrl_init_variables.F: add call to CTRL_MAP_INI_GENTIM2D.
  - move gentim2d part of ctrl_map_ini_genarr.F to
    new separate routine : ctrl_map_ini_gentim2d.F
  - ctrl_cost_driver.F,ctrl_init.F ctrl_map_ini_genarr.F:
    add time variable weights and cyclic controls (time mean,
    seasonal cycle, etc) capabilities to gentim2d
o pkg/ecco:
  - move reading of error, conversion to weights from
    ecco_cost_init_fixed.F to ecco_toolbox.F (ecco_readwei)
o global_oce_llc90, cs32:
  - activte sbo.
  - CTRL_SIZE.h : add maxCtrlProc.
  - activate the new genctrl capabilities.
  - update following reorganization of global_oce_input_fields.tar.gz
o pkg/ctrl/ctrl_ad_diff.list:
  - add missing ctrl_init_rec.f
o tools/OAD_support/keepOriginal:
  - add ctrl_init_rec.F
o model/src/the_main_loop.F, pkg/ctrl/ctrl_map_ini_genarr.F:
  - avoid recomputations of xx_gentim2d_dummy.
o momentum diagnostics:
  - move filling of diagnostics Um_Diss & Vm_Diss from mom_fluxform.F and
    mom_vecinv.F to timestep.F (to include Smag-3D contribution).
o pkg/seaice/seaice_lsr.F:
  - fix computation of BU/BV, make sure they are non-zero, only necessary
    for cubed sphere exchanges and SEAICE_OLx/y>0.
    This makes calling s/r fill_cs_corner_rl obsolete (removed).
o verification/global_ocean.cs32x15/input.seaice
  - add test for strong implicit coupling and restricted addtive Schwarz
    methods for LSR
  - update results/output.seaice.txt
o verification/tutorial_global_oce_biogeo:
  - AD & OAD set-up: switch off ALLOW_OLD_VIRTUALFLUX (like in fwd set-up)
    and set PTRACERS_EvPrRn(1,2) to zero (for DIC & ALK);
    update output_adm,_oadm,_tlm.txt
o pkg/dic:
  - change default to "#undef ALLOW_OLD_VIRTUALFLUX" in DIC_OPTIONS.h
  - add a stop when ALLOW_OLD_VIRTUALFLUX is defined and PTRACERS_EvPrRn
    for tracer 1 & 2 is set (to avoid double counting of dilution effect).
o verification/tutorial_global_oce_biogeo:
  - AD & OAD set-up: do not set PTRACERS_EvPrRn for tracer 1 & 2 since
    dilution is already added by pkg/dic ALLOW_OLD_VIRTUALFLUX ;
    update output_adm,_oadm,_tlm.txt
o eesupp/src:
  - add fill_cs_corner_rl.F (_RL-copy of fill_cs_corner_rs.F)
    and call it in seaice_lsr when using nonzero SEAICE_OLx/y
o pkg/seaice: introduce strongly implicit coupling, intended for stabilizing
  LSR (following Hutchings et al. 2004)
  - introduce zetaZ as a global variable (requires adjustments in
    seaice_evp.F and seaice_jfnk.F) and compute analoguously to etaZ
    in seaice_calc_viscosities.F
  - new flag SEAICEuseStrImpCpl (default off)
  - add new terms zetaZ*du/dy and zetaZ*dv/dx on both sides of the
    momentum equations
  - JFNK-solver (preconditioner) adjusted to allow using this method
    (where it does not have any positive effect)
o pkg/seaice
  - add overlap for restrictive additive Schwartz method also to LSR, but
    turn it off by default (because it only seems to work for non-cubed
    sphere/llc topologies)
o pkg/autodiff
  - add extra exchanges in addummy_in_steppging also for mnc output
o pkg/seaice:
  - add extra exchanges before dumping adjoint fields in seaice_ad_dump.F
    to avoid stripes in the adjoint output (similar to addummy_in_stepping.F)
o pkg/obcs:
  - add option to specify domain-connected piece Id along OB though files
    (for now, only used to diagnose PhiVel; default =1 -> global correction)
  - modify obcs_diag_balance.F to process each connected-part separately;
    exclude OB where Id = 0 but keep the full divergence there (-> constant
    Psi along this portion of OB and all inflow derived from grad(Phi))
  - add example of OB-conect files in verification/so_box_biogeo/input.
o pkg/diagnostics:
  - improve treatment of Open-Boundaries in Velocity-Potential calculation:
  a) use non zero matrix element across OB and solve for Phi 1 grid point
     outside OB (i.e, where tracer OBCS are applied).
  b) global imbalance of inFlow/outFlow across OB: instead of modifying
     velocity across OB, spread it uniformly along the OB in the RHS.

checkpoint65g (2014/11/19)
o pkg/diagnostcis:
  - add preconditioner off-diagonal factor (diagCG_pcOffDFac) as run-time param
o pkg/my82,pp81,kl10:
  - fix ALLOW_3D_DIFFKR implementation (previously had no effect): use 3-D
    field diffKr as background diffusivity to set minimum diffusivity value.
o pkg/seaice:
  - add new parameter SEAICEuseEVPrev (for revisited EVP by
    Bouillon et al 2013)
  - add SEAICE_evpAlpha/Beta to namelist
  - modify seaice_evp code to able to use SEAICEuseEVPrev. These changes
    involve trivial re-ordering of divisions/multiplications that should not
    have any effects, but ... they do change the results of lab_sea.hb87 so
    that only 2 digits of agreement remain, in line with the general
    instability/fragility of the evp-code. For now, I do not care and just
    update the verification experiment
o pkg/ctrl : add generic pre-processing (xx_genarr2d_preproc etc)
  - remove xx_genarr2d_numsmooth etc
  - use xx_genarr2d_preproc etc instead
  - carry out smooth_correl2D at initialization stage rather than during
    time stepping.
  - get smoothOpNb from xx_gentim2d_preproc
o global_oce_cs32 :
  - add test of generic ecco capabilities.
o pkg/exf/exf_getsurfacefluxes.F :
  - add to tmpUE/tmpVN rather than re-initializing them (conventional behavior).
o pkg/ctrl,ecco :
  - omit un-necessary arguments to ctrl_cost_gen.F unless ECCO_CTRL_DEPRECATED
    is defined.
o pkg/seaice: add diagnostics for Delta (deformation parameter)
o model/src:
  - when ALLOW_3D_DIFFKR is defined, add a Warning if any of the vertical
    diffusivity (background) is specified but ignored.
o verification:
  - in testreport, convert hostname to lower case for default output dir name
o model, pkg : add useCTRL, useECCO parameters (on/off run time switch).
o pkg/dic: add modifications from Hajoon:
  - add iron sedimentation flux function of the flux of PO4 out of bottom layer
  - light attenuation: add self-shading effect by climatological Chlorophyll
    (read from file).
o pkg/seaice/seaice_preconditioner.F : fix cpp flags, so that code also
    compiles when SEAICE_ALLOW_DYNAMICS is undefined
o global_oce_llc90,cs32 : ecco_v4 verification exps now use separate
    AUTODIFF_OPTIONS.h, CTRL_OPTIONS.h, ECCO_OPTIONS.h rather than
    ECCO_CPPOPTIONS.h (i.e. replacing the deprecated, circumvoluted,
    approach where CPP_OPTIONS.h includes an omnipotent
    ECCO_CPPOPTIONS.h that superseeds pkgs '_OPTIONS.h').
o pkg/ctrl/ctrl_map_ini_genarr.F : include GMREDI_OPTIONS.h where
    ALLOW_3D_KAPGM, ALLOW_3D_KAPREDI (to be added later) belong.
o pkg/seaice/SEAICE_SIZE.h : replace ALLOW_AUTODIFF_TAMC with ALLOW_AUTODIFF
    to avoid needing AUTODIFF_OPTIONS.h anytime SEAICE_SIZE.h is included
    (it seems that THSICE_SIZE.h, PTRACERS_SIZE.h have the same issue...)
o model/src, pkg/smooth, profiles, salt_plume, seaice, exf, ecco, ctrl :
  add ECCO_OPTIONS.h, AUTODIFF_OPTIONS.h, CTRL_OPTIONS.h when needed
  - ECCO_OPTIONS.h is needed when including ecco_cost.h, ecco.h
  - AUTODIFF_OPTIONS.h is needed when including tamc.h, tamc_keys.h
  - CTRL_OPTIONS.h is needed when including ctrl.h, optim.h, etc
o pkg/ctrl,ecco,exf :
  - remove variables associated with NON-generic costs,
    unless ECCO_CTRL_DEPRECATED is defined.
  - remove NON-generic NON-obcs controls,
    unless ECCO_CTRL_DEPRECATED is defined.
o pkg/ctrl : added ctrl_local_params.h
o pkg/ecco : added ecco_local_params.h
o verification : added ECCO_CTRL_DEPRECATED to most as and oad
    experiments, which will progressively be removed once the
    experiments are revised to use only generic controls/costs.

checkpoint65f (2014/10/13)
o pkg/ctrl, ecco, seaice : minor changes in headers
o global_oce_llc90,cs32 : ecco_v4 verification exps now test generic
    cost function and control capabilities added since checkpoint65c.
o pkg/ctrl: regroup all obcs ctrl variables in CTRL_OBCS.h.
o pkg/ecco: increase modularity and improve logic
  - ecco_toolbox.F (new) : basic operations that are often used,
    including ecco_zero, ecco_cp, ecco_cprsrl, ecco_diffmsk,
    ecco_addcost, ecco_add, ecco_div, ecco_readbar.
  - cost_gencal.F (new) : determine filnames and records.
  - cost_genread.F, cost_generic.F : condense code using ecco_toolbox.
  - cost_generic.F : use spzeroloc rather than hard-coded -9999,
    and exploit the above functions leading to more compact code.
  - cost_genread.F : rm un-necessary arguments, re-arrange args order.
  - ecco_check.F, ecco_readparms.F : bring logic up to date (using_tpj,
    using_ers, using_gfo, using_mdt is now only defined within gencost)
o pkg/ecco: extend generic cost capabilities
  - pkg/ecco : added 3D gencost (ALLOW_GENCOST3D), added gencost
    capabilities via gencost_preproc (+ _c,_i,_r related params),
    gencost_posproc (+ _c,_i,_r related params), gencost_nrecperiod,
    gencost_outputlevel arguments to cost_generic
  - pkg/ecco/cost_genread.F (new) : interface between cost_generic
    and active_read, making room for gencost_preproc to take effect.
    Added preproc code ('climmon') to replace GENERIC_BAR_MONTH.
  - pkg/ecco/cost_generic.F :
    compute and store misfit maks*(model-data) in localdif that is
    then used in cost and for output, output misfit if outlev.GT.0
  - pkg/ecco/cost_averagesfields.F : depend on gencost_barskip
    rather gencost_barfile for deciding whether to write barfile
  - pkg/ecco/ecco_cost_driver.F : extract call to cost_profiles from cost_hyd
  - pkg/ecco/ecco_cost_init_fixed.F : extract gencost weights from
    ecco_cost_weights, re-activate ecco_summary, determine gencost_barskip
  - pkg/ecco/ecco_summary.F : report gencost variables
  - pkg/ecco/cost_gencost_customize.F : treat case of scatterometer costs
o pkg/sea/SEAICE_OPTIONS.h : add ALLOW_COST_ICE, ALLOW_SEAICE_COST_SMR_AREA
o pkg/ecco: internal re-organization
  - resolve un-necessary dependancies within pkg/ecco and to pkg/ctrl
    (rm includes of optim.h and ctrl.h, replace optimcycle with eccoiter,
    mv relevant variables definition from ecco_cost.h to ecco.h,
    make sure gencost routines only include ecco.h)
  - throughout : add missing CCP switches, rm unused variables,
    and rm un-necessary CPP switches
  - throughout gencost routines : replace modelstartdate with
    gencost_startdate when needed
  - cost_bp_read.F : use arguments, instead of common blocs
    so that it can be used also by (new) cost_gencost_bpv4.F
  - ecco_init_varia.F : initialize RHOsumGlob_0, VOLsumGlob_0
  - ecco_phys.F : compute etanFull
  - ecco_readparms.F : rename using_topex as using_tpj, add
    bpv4-grace to gencost list, initialize added parameters
  - ecco_summary.F : include SIZE.h needed for augmented ecco.h

checkpoint65e (2014/09/28)
o pkg/obcs:
  - replaced the just-added CPP options with run-time variables
    (see pkg/obcs/OBCS_PARAMS.h for details)
o pkg/obcs:
  - add additional CPP options for sponge boundary layers
    (see pkg/obcs/OBCS_OPTIONS.h for details)
o pkg/atm_phys:
  - implement simple (obliquity only, assuming circular planet orbit)
    seasonal cycle for incoming insolation ; used when run-time parameter
    "select_incSW" is set to 1 ; by default (=0), uses old unchanged formula.
o pkg/exf, pkg/ecco, pkg/ctrl:
  - add ctrlUseGen and .NOT.ctrlUseGen exclusive brackets
  - activate gentim2d for xx_atemp,xx_aqh,xx_swdown,xx_lwdown,xx_precip
  - implement gentim2d for xx_tauu, xx_tauv
o pkg/ctrl, pkg/ecco :
  - fix and complement the generic controls implementation
o pkg/exf/exf_getclim.F, exf_getffields.F, exf_getsurfacefluxes.F,
    pkg/shelfice/shelfice_thermodynamics.F,
    verification/hs94.1x64x5/code_ad/ctrl_map_gentim2d.F,
    verification/hs94.1x64x5/code_oad/ctrl_map_gentim2d.F :
  - add weight in CTRL_GET_GEN calls
o pkg/ctrl :
  - ctrl_get_gen.F : add weight as input parameter, and apply
    it directly rather than using smooth_correl2Dw (to be retired).
  - ctrl_map_gentim2d.F : add wgentim2d in CTRL_GET_GEN call
o pkg/ctrl :
  - introduce run time switch ctrlUseGen (in ctrl.h, ctrl_check.F,
    ctrl_init_variables.F, ctrl_readparms.F, ctrl_summary.F)
  - re-activate ctrl_summary (call in ctrl_init.F)
o pkg/ctrl/ctrl_cost_gen.F :
  - fix CCP brackets, remove un-necessary myiter, mytime
o pkg/ecco, pkg/ctrl :
  - remove cost_genctrl.F (now pkg/ctrl/ctrl_cost_driver.F)
  - remove cost_forcing_gen.F (now pkg/ctrl/ctrl_cost_gen2d.F)
  - add ctrl_cost_driver.F (replaces pkg/ecco/cost_genctrl.F)
  - add ctrl_cost_gen2d.F (replaces pkg/ecco/cost_forcing_gen.F)

checkpoint65d (2014/09/15)
o pkg/ctrl/CTRL_GENARR.h, ctrl_readparms.F :
  - add xx_genarr2d_bounds,xx_genarr3d_bounds,
    xx_genarr2d_numsmooth, xx_genarr3d_numsmooth
o pkg/ctrl/ctrl_map_ini_genarr.F :
  - remove compilation failure
  - replace hard coded example
  - use ctrl_map_ini_gen2D, 3D
o pkg/ctrl/ctrl_pack.F, ctrl_unpack.F :
  - on/off switch based upon xx_genarr2d_weight,3d
o src/packages_init_variables.F :
  - regroup pkg/estimation calls
  - remove CTRL_MAP_INI, CTRL_MAP_INI_ECCO
    (moved to ctrl_init_variables)
o cost/cost_init_varia.F :
  - remove ecco_cost_init_varia
    (moved to ecco_init_varia)
o ctrl/ctrl_init_variables.F :
  - add CTRL_MAP_INI, CTRL_MAP_INI_ECCO
  - add CTRL_MAP_INI_GENARR, SEAICE_CTRL_MAP_INI
o ctrl/ctrl_map_ini.F :
  - remove ctrl_map_ini_genarr, seaice_ctrl_map_ini
    (moved to ctrl_init_variables)
o ctrl/ctrl_map_ini_ecco.F :
  - remove ECCO_PHYS (mv to ecco_init_varia)
  - remove seaice_ctrl_map_ini (mv to ctrl_init_variables)
o ecco/ecco_ad_diff.list :
  - add ecco_init_varia.f
o ecco/ecco_init_varia.F
  - new routine
o pkg/streamice:
  - move call to STREAMICE_INITIALIZE_PETSC from the_model_main.F
    to streamice_init_fixed.F ; fix setting of STREAMICEisOn.
  - from model/src, only call pkg/streamice routines if useStreamIce is TRUE.
o pkg/generic_advdiff:
  - fix bug causing negatives in GAD_SMOLARKIEWICZ_HACK, introduced 8/8/2014.
o pkg/exf:
  - exf_getffields.F : add xxg_atemp, xxg_aqh, xxg_swdown, xxg_lwdown,
     xxg_precip capability
  - exf_wind.F : no need for ALLOW_WSPEED_CONTROL cpp switch
o pkg/ctrl:
  - ctrl_pack.F, ctrl_unpack.F : omit (un)packing of undefined xx_gentim2d
o model/src/load_fields_driver.F :
  - move call to CTRL_MAP_GENTIM2D ahead of BULKF_FIELDS_LOAD, EXF_GETFORCING
    so xx_gentim2d can be applied to e.g. exf fields in a timely manner.
o OpenAD verification experiments:
  - Include explicitly AUTODIFF_OPTIONS.h, COST_OPTIONS.h, and CTRL_OPTIONS.h
    in src files (to enable to skip the ECCO_CPPOPTIONS.h);
    for now, only in pkgs used in OpenAD verification experiments.
  - Change all except one (halfpipe_streamice) OpenAD experiments to use pkg
    specific option file (AUTODIFF_OPTIONS.h, COST_OPTIONS.h & CTRL_OPTIONS.h)
    instead of using ECCO_CPPOPTIONS.h (with all relevant options in it).
    This applies to both TAF (*/code_ad/) and OpenAD (*/code_oad/) tests.
o OpenAD verification tests:
  - finish removing ALLOW_AUTODIFF_OPENAD (replaced by ALLOW_OPENAD);
  - finish replacing ALLOW_AUTODIFF_TAMC by ALLOW_AUTODIFF (except for
    tape/storage which are specific to TAF/TAMC) in pkgs used in OpenAD exp.
  - leave ALLOW_AUTODIFF_TAMC undef in OpenAD verification tests (*/code_oad/)
    and remove local copy of "tamc.h" (needed only if ALLOW_AUTODIFF_TAMC).
o model/src & generic_advdiff:
  - change hard-coded loop-range in S/R APPLY_FORCING_T/S to set T & S
    forcing over 0:sNx+1, 0:sNy=1 (instead of just 1:sNx,1:sNy): Model
    dynamics requires valid tracer forcing only over tile interior but, for
    some diagnostics, may need to extend it over 1 point in tile halo region.
  - in gad_calc_rhs.F, update calls to gmredi_x/ytransport to get valid
    tendency over i,j_Min,Max range. This allows to simplfy i,j_Min,Max
    setting in temp/salt/ptracer_integrate.F
o pkg/dic:
  - multiply tracer tendencies by maskInC (if ussing OBCS) before updating
    gchem tracers: this allows to skip the 2nd call to OBCS_APPLY_PTRACER
    in gchem_forcing_sep.F
o pkg/autodiff & obcs:
  - add storage of current OB values for U & V (was already done for T & S).

checkpoint65c (2014/08/30)
o pkg/dic:
  - take out of dic_atmos.F the initialisation part (corresponding to istate=0)
    and move it to new S/R DIC_INI_ATMOS ; also simplify the dependencies for
    AD compilers (but still a Pb with multi-threading and Ajoint dependencies).
o verification:
  - new experiment testing OBCS and DIC pkgs, using params & output from
    tutorial_global_oce_biogeo but limited to a sub-domain around Drake
    passage: take OBCS from the last year of a 2 yrs simulation and initial
    conditions from t=1.yr while keeping the same forcing.
o model/src:
  - when allowFreezing=T, only reset below freezing initial Temp to Tfreezing
    (at any k) if checkIniTemp is not set to FALSE (default checkIniTemp=T).
o pkg/diagnostics (Stats-Diags):
  - re-write S/R DIAGSTATS_CALC (more similar to TARGET_NEC_SX part) to:
    a) refine region where stats are computed, excluding where arrhFac=0 ;
    b) fix missing interior mask (use with OBCS) in 3-D fields statistics;
    c) extend regional stats over the region edges (for U or V pt location).
o pkg/gchem:
  - add a (2nd) call to OBCS_APPLY_PTRACER in gchem_forcing_sep.F (needed since
    pkg/dic is currently changing/updating ptracers values beyond the OB).
o verification (hs94):
  - convert Held & Suarez external_forcing.F (from hs94.cs, with Sigma-coords
    bits) to apply_forcing.F and undef USE_OLD_EXTERNAL_FORCING in experiments
    hs94.cs-32x32x5 and tutorial_held_suarez_cs ; also use the same version of
    apply_forcing.F in 2D hs94 (fwd, ad & oad) but keep LatLon hs94 unchanged.
o pkg/ptracers:
  - implement Adams-Bashforth on pTracers (instead of on tracer tendency),
    switched on by setting PTRACERS_doAB_onGpTr=F (default set to doAB_onGtGs)
  - change exp4 secondary test (input.nlfs) to test AB on T & S & pTracer
    with AB-2 code (so that it get tested).
o model/src:
  - allow to apply Adams-Bashforth on Temp & Salt (instead of on gT,gS)
    with AB-2 code (previously only available with AB-3 code).
    Also move the code (call to ADAMS_BASHFORTH S/R) form thermodynamics.F
    to temp/salt_integrate.F (since the 2nd part of gt/sNm1 update is done
    there, by calling CYCLE_AB_TRACER).
o pkg/generic_advdiff:
  - change Tracer argument (drop bi,bj indices) in S/R GAD_CALC_RHS,
    GAD_C2_ADV_R, GAD_U3_ADV_R, GAD_C4_ADV_R, GAD_DIFF_R, GAD_BIHARM_R
    + also in GMREDI_X/Y/RTRANSPORT ; and update corresponding calls in
    S/R temp/salt/ptracers_integrate.F
o model/src & pkg/ptracers:
  - remove common block variables gT,gS (in DYNVARS.h), except when
     USE_OLD_EXTERNAL_FORCING is defined; update TAF storage accordingly.
  - remove common block variable gPtr.
o model/src & pkgs:
  - change gTracer (and/or tracer) argument (drop bi,bj indices) in S/R
     ADAMS_BASHFORTH(2&3), CYCLE_(AB_)TRACER, FREESURF_RESCALE_G,
     IMPLDIFF, SOLVE_TRIDIAGONAL & _PENTADIAGONAL, GAD_SOM_ADVECT,
     GAD_ADVECTION, GAD_CALC_RHS, GAD_IMPLICIT_R, TIMEAVE_CUMUL_DIF_1T
  + change accordingly all calling S/R.
  - use local temperature/salinity/ptracer tendency array (without bi,bj)
    in S/R temp/salt/ptracers_integrate.F
o pkg/seaice:
  - move computation of stress contributions to rhsU/V in s/r seaice_lsr
    to separate s/r seaice_lsr_rhsu/v in order to be able to re-use code
  - make u/vIceC local variables if SEAICE_CGRID is defined only to be used
    in seaice_lsr
  - seaice_lsr.F: make local 4D arrays UXX, VYY, etc 2D
    in s/r seaice_lsr_calc_coeffs
o pkg/mdsio:
  - in MDS_READ/WRITE_FIELD, stop if file-name (+prefix) is too long
    (e.g., > MAX_LEN_MBUF -90 ) or, in INI_MODEL_IO, if mdsioLocalDir is
    too long (e.g., > MAX_LEN_FNAM/2 )

checkpoint65b (2014/08/12)
o pkg/matrix:
  - pass, as argument, updated tracer field to S/R MATRIX_STORE_TENDENCY_EXP
o model/src:
  - fix initialisation of geothermalFile; compile geothermal-flux code in
    natl_box verification experiment.
o model/src & pkg/down_slope:
  - push the k loop inside S/R TIMESTEP_TRACER (now called outside the k loop).
  - in dwnslp_apply.F, update tracer tendency instead of the future tracer
    field and call S/R DWNSLP_APPLY before TIMESTEP_TRACER; this affects
    results at machine truncation level: update output of experiments
    global_ocean.90x40x15.dwnslp (FWD) and lab_sea.noseaicedyn (AD).
o pkg/diagnostics (Stats-Diags):
  - do not cumulate the full volume when DIAGNOSTICS_FILL is
    called with bibjFlg < 0 (no increment of the counter for 2D/3D diag);
    This fix the mean statistics when DIAGNOSTICS_FILL is called multiple
    times (but Min,Max and StD are still wrong).
o model/src:
  - add geothermal flux forcing: read in ini_forcing.F as time-constant
    field "geothermalFlux" applied in S/R APPLY_FORCING_T (apply_forcing.F)
o model/src:
  - move CYCLE_TRACER calls from tracers_correction_step.F to temp/salt/ptracer
    _integrate.F so that, when leaving S/R THERMODYANMICS, theta,salt and pTrac
    arrays are already updated while adjustments (filters, conv.adjustment) are
    still applied later, in S/R TRACERS_CORRECTION_STEP.
o model/src:
  - store in common bloc array "rhoInSitu" the virtual potential temperature
    anomaly that is used to compute geopotential: this make the atmos code
    more similar to ocean code which already uses rhoInSitu in calc_phi_hyd.F
o pkg/seaice/seaice_lsr.F
  - rename integer variable ilcall to ipass (that's what it is called
    in the residual diagnostics
  - change time stepping for NPSEUDOTIMESTEP > 2 (does not change the
    default) for improved non-linear convergence of the first few steps
  - adjust a few comments and add new ones to explain some of the store
    directives
o pkg/generic_advdiff (& ptracers):
  - re-work the code to check for valid advection scheme and for minimum
    size of overlap (now stored in local common bloc in gad_advscheme.F)
o pkg/seaice: another attempt to make the adjoint work for sea ice dynamics
  - re-initialize more variables in seaice_lsr: u/vIceC, u/vIceNm1
  - add an auxilliary variable "bet" and fix store directives and keys in
    seaice_lsr_tridiagu/v, this seems to do the trick (i.e. more or
    less exact gradients in my tests); but there are still
    recomputation warning (although gradients are sort of OK), when
    SEAICE_LSR_VECTORIZE is not defined, so this flag and
    SEAICE_LSR_VECTORIZE_ZEBRA are recommended for efficiency.
  - update verification experiments lab_sea.
  - change some comments in S/R seaice_calc_viscosities
o model/src:
  - if staggerTimeStep=T, always apply exchange to velocity field in
    do_stagger_fields_exchanges.F instead of in do_fields_blocking_exchanges.F
    (independent of using multi-dim advection or not); no effect on FWD run
    but affects AD results (at machine truncation level): update output of
    experiment 1D_ocean_ice_column (ad: 12 digits), hs94.1x64x5 (ad,oad: 13.d)
    and isomip (oad: 12.d).
o pkg/generic_advdiff:
  - stop if doAB_onGtGs is set to FALSE but ignored
  - refine warning related to stability of tracer time-stepping
    regarding internal wave dynamics.
  - setting of AdamsBashforth_T,S when doAB_onGtGs=F: remove condition
    on staggerTimeStep & implicitIntGravWave (will now get a warning
    if potentially unstable).
o pkg/kl10:
  - add new pkg "kl10" for mixing due to internal wave breaking, from
    http://www.sciencedirect.com/science/article/pii/S1463500310000144
    (contribution from Jody Klymak), tested in verification experiment
    verification/internal_wave/input.kl10/
o isomip experiment:
  - test pkg/shelfice with Non-Lin Free-Surf in one of the FWD set-up
    (input.htd) and update the output.
o cd_code experiments:
  - use default cd_code options (#undef CD_CODE_NO_AB_MOMENTUM &
    #undef CD_CODE_NO_AB_CORIOLIS) in experiments: cfc_example (fwd)
    global_ocean.90x40x15 (ad & oad) and OpenAD (ad & oad) and
    update the corresponding output.
o pkg/seaice:
  - reduce the number of include files and store directives in
    S/R seaice_lsr_tridiagu/v
  - change the order of loops in one case in S/R seaice_lsr_tridiagv
    (only for SEAICE_VECTORIZE_LSR_ZEBRA defined), which allows me to
    get rid off one store directive (a TAF bug?)
  - add one more instance of ifdef SEAICE_VECTORIZE_LSR_ZEBRA in
    S/R seaice_lsr_tridiagv to change the loop range for consistency
  - remove ilcall, m from parameter list of S/R seaice_lsr_tridiagu/v
  - fix a bug that affects the JFNK solver: replace sNx/y by i/jMax in
    S/R seaice_lsr_tridiagu/v (requires update of
    offline_exf_seaice/input.dyn_jfnk)

checkpoint65a (2014/07/27)
o model/src:
  - Non-Lin Free-Surf in p/z coords: allows hFacW,S to be larger than
    surrounding hFacC=1 @ edge of a step with different kSurfC on either side
    (topo in p-coords, ice-shelf in z-coords); update output of experiments
    tutorial_global_oce_in_p and isomip (both AD and OpenAD output).
o model/src:
  - collect momentum forcing tendency into local 2-D array (passed as argument
    to apply_forcing S/R); this simplifies mom. Forcing diagnostics and CD_CODE
    parts in timestep.F (without CD_CODE_NO_AB_MOMENTUM defined = the default);
    affects results at machine truncation level (e.g., if using OBCS_SPONGE).
  - collect T & S forcing tendency into local 2-D array (passed as argument to
    apply_forcing S/R); add 3-D diagnostics for temp & salt forcing tendency.
    affects results at machine truncation level (e.g., ocean: if using
    SHORTWAVE_HEATING ; atmos: if using FrictionHeating or (atm_Rq<>0) moist
    correction due to vertical advection).
  - update output of experiments: fizhi-cs-32x32x40 (13 digits),
    global_ocean.cs32x15 (fwd: icedyn, seaice, thsice, all 3 @ 11d; adm & tml:
    seaice_dynmix & thsice, fwd grd @ 3 & 8), hs94.1x64x5 (ad grd @ 13),
    obcs_ctrl (ad & fwd grd @ 12 & 7).
o pkg/ptracers & diagnostics:
  - use ptracers (short) name (instead of long one) to make ptracers diagnostics
    title (to avoid some unexpected truncation); sort out ptracers diags units.
  - collect ptracer forcing tendency into local 2-D array (passed as argument
    to apply_forcing S/R); add 3-D diagnostics for ptracers forcing tendency.

checkpoint65 (2014/07/18)
o pkg/fizhi:
  - add parenthesis around fizhi tendencies in fizhi_tendency_apply.F: this
    affects results at machine truncation level. Update output of experiments
    fizhi-cs-32x32x40 (12 digits for cg2d) & fizhi-cs-aqualev20 (13 digits).
o pkg/seaice: more clean up
  - rename TAF common block tapes to be more consistent and remove
    unnecessary duplicates
  - add store directives to remove more recomputations, but use smaller
    tapes (and adjust keys) when SEAICE_LSR_ADJOINT_ITER is undefined.
    The idea behind this flag is to reduce the memory footprint when the
    adjoint of the LSR is not required. As of now, defining the flag
    SEAICE_LSR_ADJOINT_ITER increases 4 common block tapes for 2D field by
    a factor of SOLV_MAX_FIXED (=500 by default in SEAICE_SIZE.h).
    For experiment offline_exf_seaice, this means on a linux box with gfortran
    nearly a factor of 10 (but keep in mind there is mostly seaice code in
    this experiment):
    > size mitgcmuv_ad
    text    data        bss     dec        hex
    5100659 1216  220458952  225560827  d71c8fb
    5339425 1200 1868783272 1874123897 6fb4dc79 (SEAICE_LSR_ADJOINT_ITER)
    but only a moderate increase of 36% for global_ocean.cs32x15:
    text    data        bss     dec        hex
    6695027 1648 1014578664 1021275339 3cdf6ccb
    6695203 1648 1382505320 1389202171 52cd8afb (SEAICE_LSR_ADJOINT_ITER)
  - note: there are still recomputations in global_ocean.cs32x15 and
    offline_exf_seaice and the gradient agreement changes (gets a
    little worse) for global_ocean.cs32x15 (-> update output_adm.seaice.txt)
  - in general, the AD gradients still are wrong
o OpenAD
  - clean up code_oad/ directories somewhat by moving files
    dontCompile, dontTransform, keepOriginal to OAD_support/
o model/src:
  - using MOM fluxform and Non-Lin Free-Surf with momDissip_In_AB=F
    (not currently tested): add dissipation terms before NLFS rescaling of
    tendencies (previously done after).
o pkg/diagnostics:
  - write stats-diags in ascii file with more digits (same as in monitor).
o pkg/down_slope:
  - drop the bi,bj dimension of argument recip_hFac in S/R DWNSLP_APPLY; with
    NLFS (not tested), use new recip_hFac value in order to conserve tracer.
o model/src:
  - new file "apply_forcing.F" containing all the code previously in
    external_forcing.F, but with new argument list: pass, as new argument,
    the current level tendency array to update (instead of a direct update
    of the common bloc array). Change the corresponding calls.
  - add CPP option USE_OLD_EXTERNAL_FORCING (default is undef) to use
    EXTERNAL_FORCING_U,V,T,S subroutines (for backward compatibility).
o pkg/seaice/seaice_lsr, a little bit of clean up
  - rearrange some code blocks, so that now all calculations for
    setting up the right-hand-sides done within one single block
    (I find that easier to read and understand)
  - rearrange freedrift-code to reduce the number of ifdefs
  - adjust some indentations and comments

checkpoint64z (2014/07/10)
o model/src and several pkgs:
  - change argument list of all S/R called from external_forcing.F and
    called from ptracers_forcing.F (renamed to ptracers_apply_forcing.F)
    to pass, as argument, the current level tendency array to update
    (instead of a direct update of the common bloc array).
  - change also (in the same way) argument list of PTRACERS_APPLY_FORCING;
  - rename taueddy_external_forcing.f to taueddy_tendency_apply.F
o pkg/seaice/seaice_lsr.F
  - always initialize local arrays in seaice_lsr_tridiagu/v
  - add more local tapes to seaice_lsr_tridiagu/v
  - move storing u/vice(:,:,bi,bj) out of seaice_lsr_tridiagu/v, but
    keep it in bi/bj loop; this seems to be essential
  - gradients are still wrong but only by 4-7 orders of magnitude
    instead of 15 orders of magnitude, lab_sea improves a little
o pkg/seaice
  - (pkg/autodiff) remove storing/restoring of seaiceMaskU/V that
    generates unnecessary code in seaice_lsr_ad
  - add more store directives in seaice_lsr to avoid unnecessary code
    in seaice_lsr_ad
  - exclude some residual computations in seaice_lsr when
    ALLOW_AUTODIFF_TAMC is defined in order to avoid unnecessary code
    in seaice_lsr_ad
  - add more storing, a new tape (model/src/the_main_loop.F) and
    another key for SEAICE_LSR_VECTORIZE_ZEBRA (the local keys ilockey
    and klockey should be checked by a specialist)
  - modify ( define SEAICE_VECTORIZE_LSR and SEAICE_LSR_ADJOINT_ITER )
    and update lab_sea after previous changes in pkg/seaice below
o pkg/autodiff:
  - introduce useSmoothCorrel2DinAdMode, SEAICEapproxLevInAd, and
    viscFacInAd : run time parameters allowing for adjoint switches
    note : logic for useSmoothCorrel2DinAdMode is in ctrl_readparms.F
o pkg/ecco:
  - introduce cost_gencost_boxmean.F that computes a box mean
    temperature (for use in adjoint sensitivity studies).
o model/src/set_defaults.F : initialize viscFacAdj to 1.
o pkg/mom_common/mom_calc_visc.F:
  - ifdef ALLOW_AUTODIFF then include viscFacAdj factor.
o pkg/seaice/seaice_summary.F:
  - statement for SEAICEadjMODE now in autodiff_readparms.F
o pkg/seaice:
  - remove some store directives and add new ones in an effort to get
    finally rid off the recomputation warnings. This is successful
    when SEAICE_VECTORIZE_LSR ***and*** SEAICE_LSR_ADJOINT_ITER are
    defined (i.e. no extensive recomputation warnings left), but there
    are still too many recomputations on the solver iteration level
  - define SEAICE_VECTORISZE_LSR in offline_exf_seaice/code_ad/SEAICE_OPTIONS.h
  - move definition of MPSEUDOTIMESTEPS into TAMC-block in
    SEAICE_SIZE.h
  - add a store directive in S/R seaice_calc_viscosities
o pkg/seaice (ITD code):
  - fix definition of Hlimit for multi-threaded case
  - use double precision arithmetic to compute Hlimit: this affects results;
    update output of experiment seaice_itd.
o replace content of verification/seaice_itd
  - instead of a 1D column use the configuration of offline_exf_seaice
    to test the ice thickness distribution code with ridging
  - this is a first shot at this experiment
  - change of some defaults of ridging parameters SEAICEhStar (from
    100 to 25) and SEAICEmuRidging (from 5 to 3) in seaice_readparms.F
    and lot of new comments.

checkpoint64y (2014/06/20)
o pkg/seaice/seaice_reg_ridge.F:
  - modify the regularization of very small volumes of ice; only check
    total volume HEFF, and do not apply correction to individual ice
    classes because that leads to funny patterns in the heat and fw-fluxes
    into the ocean. Adjust seaice_itd/results/output.txt
  - replace nITD by SEAICE_multDim in loop-ranges
o pkg/exf:
  - add code to process the case field period = -12. with UV interpolation.
  - move debug print (formerly active when exf_verbose=T) from EXF_getFFieldRec
    into S/R that calls it (i.e., exf_set_gen.F, exf_set_uv.F & obcs_exf_load.F)
o verification/global_with_exf:
  - switch all fields period to -12. (was previously untested) in input/data.exf
    (but keep secondary test ".yearly" unchanged); update the reference output.
o pkg/cal:
  - new calendar type "noLeapYear" for 365 days calendar without any leap year.
o pkg/exf:
  - new integer parameter "exf_debugLev" (default set to main model debugLevel)
    to replace logical switch "exf_verbose"
  - report in STDOUT when loading a new record (if exf_debugLev >= 3)
o pkg/sbo:
  - update from Katherine Quinn: evaluate mass directly from density and SSH
    (budget using Finite Volume method) instead of from bottom pressure.
  - allow testreport to collect few selected SBO output ; tested in exp.
    global_ocean.90x40x15 (after updating the results, to include SBO output).
  - fix some multi-threading issues (in output part).
o model/src & most packages:
  - always call {PKG}_READPARMS even if corresponding use{PKG}=F;
  - in {PKG}_READPARMS, in case use{PKG}=F: add a call to new S/R
    PACKAGES_UNUSED_MSG to print a weak warning when parameter file
    "data.{pkg}" exist ; and leave the S/R (return) just after.
  - more standard LAND pkg interface (land_init_fixed.F, land_check.F).
    + call LAND_READPARMS from packages_readparms.F
o pkg/seaice:
  - remove code that resets useThSice in S/R seaice_readparms and
    replace it by a warning in S/R seaice_check
  - remove parameter MULTDIM, replace with nITD and runtime
    parameter SEAICE_multDim (still hard-wired to nITD if
    SEAICE_ITD is defined)

checkpoint64x (2014/05/24)
o verification/lab_sea:
  - update adjoint and TLM output following changes to pkg/salt_plume
  - un-do the update after putting back local recip_Cp in few places.
o pkg/salt_plume: modifications by An Nguyen:
  - add capability to do brine rejection (salt-plume) as function of
    volume+tracers (instead of only salinity tracer).
  - conserve volume by exchanging volume from each kLev to above to
    accommodate in-coming brine volume
  - store surface and klev exchanged fraction + volume in 4 new 3-d arrays
  - switch KPP surf buoyancy due to brine forcing to 3-d
    (3 more 3-d arrays, 2 for SPforcing[T,S], 1 for boplume)
  - add salt_plume_volfrac, salt_plume_apply, salt_plume_tendency_apply_t
  - unrelatedly, also add ad-hoc capability to vary salt_plume scheme
    in East/West Arctic.
o pkg/sbo:
  - incorporate modifications from Katherine Quinn to enable the use of sbo
    pkg in ECCO-v4 set-up ; remove SBO-TimeAve output ; add monitor-like
    output for future testreport verification (unfinished).
o pkg/atm_phys:
  - change diagnostics (AtPh_Trf & AtPh_Qrf) of DARGAN_BETTSMILLER S/R:
    skip the reseting of t_ref & q_ref to initial t & q ; this preserve the
    output of S/R CAPECALCNEW (Parcel temp & q) for diagnostics.
o pkg/seaice
  seaice_calc_ice_strength.F: modify expression to avoid divisions
    (affects truncation)
  seaice_do_ridging.F: clean up the insectarium
  - fix a bug that was compensated by areaScaling (-> remove areaScaling code)
  - added SEAICEsnowFracRidge to redistributed snow (2nd bug)
  - set closing/openingRate to zero where no extra iteration is need (3rd bug)
  - add some debugging information and error messages (warnings)
o model/src: modifications relatd to atmosphere p*:
  - Switch to more accurate p* coordinate slope term (calc_grad_phi_hyd.F)
  - With p* or Sigma-P, use constant reference Pot.Temp (thetaConst) instead
    of vertical profile tRef in geopotential background and anomaly.
  - Acount for true p* correction in theta <-> T conversion in pkg/aim_v23
    and pkg/atm_phys.
  - Update FWD output of experiments: aim.5l_cs (x2), fizhi-cs-32x32x40,
    fizhi-cs-aqualev20, fizhi-gridalt-hs, tutorial_held_suarez_cs, cpl_aim+ocn.
o pkg/seaice: fix a bug in seaice_prepare_ridging.F, forgot a sqrt
o pkg/ptracers: compute ptracer source/sink due to linear free surface.
    not used right now, but can be used in BGC packages to fix conservation.
o pkg/dic, pkg/gchem: move tracer_meanarea to gchem, so it can be used by
    other packages too.
o pkg/seaice/seaice_calc_ice_strength.F: replace SEAICE_rhoSnow by
    SEAICE_rhoIce in the Rothrock (1975)-type strength calculations (bug fix)
o model/src:
  - since we have several heat capacity (even in model/src), define "recip_Cp"
    as local variable (no longer in common block) to avoid any confusion.
  - add thetaConst in PARAMS.h (to be used with pStar or sigma-P coords).
o pkg/exf:
  - from Jeff Scott: add option (#define EXF_CALC_ATMRHO) to calculate local
    air density as function of air Temp, Humidity and atm pressure.

checkpoint64w (2014/05/02)
o verification:
  - update output_adm.txt files for experiment global_ocean.cs32x15 (seaice &
    seaice_dynmix) and lab_sea (primary test & noseaicedyn): moving/changing
    code from seaice_growth.F & seaice_advdiff.F to new ridging routines
    seaice_reg_ridge.F seaice_do_ridging.F affects AD gradient
    (down to 8-7 matching digits for global_ocean and 5-6 for lab_sea).
o model/src: for atmosphere in p* coords:
  - store factor rStarFacC**atm_kappa (= pStarFacK) in common block
  - implement more accurate p* coordinate slope term (in calc_grad_phi_hyd.F),
    but not yet activated.
o pkg/seaice: fix restart problem for ITD with new ice strength parameterisation:
  - move computation of opnWtrFrac = 1-AREA to before computing ice strength
  - this changes the results (but not for any verification experiment, because
    none tests this), but avoids having an extra field in the restart files
o pkg/seaice: remove global variable TICE (not needed)
  - replace by TICES or local variable where necessary (cost_seaice_test,
    seaice_diagnostics_state)
  - move copying TICE to TICES from seaice_check_pickup to seaice_read_pickup
  - use specific read/write routines for reading and writing individual leves
    of a multilevel field
o pkg/ctrl & model/inc:
  - move additional anomaly fields of control vars (related to options:
     ALLOW_KAPGM_CONTROL, ALLOW_KAPREDI_CONTROL and ALLOW_BOTTOMDRAG_CONTROL)
    from DYNVARS.h into new header file: CTRL_FIELDS.h
o pkg/seaice: some small modifications to the ridging code
  - make fw2ObyRidge a global variable and add the freshwater flux to
    seaice_growth
  - pass actual thickness from seaice_prepare_ridging, so that it is
    computed only in one place and compute it in the same way as in
    seaice_growth
  - initialise more fields in seaice_do_ridging that where cause floating
    point exceptions over land
o pkg/seaice: preparations for ridging code and first real ridging code
  - move most of "PART 1" of S/R seaice_growth into a new and separate
    S/R seaice_reg_ridge that will both regularize the state variable after
    advection call the actual ridging routine;
  - requires to make 5 fields global fields: d_HEFFbyNEG,d_HSNWbyNEG,
    d_AREAbyRLX,d_HEFFbyRLX,saltFluxAdjust;
  - remove ridging code from seaice_advdiff
  - clean up remaining part 1 of seaice_growth in an attempt to make it
    more readable (this is probably subjective)
  - call seaice_itd_redist once in the initialisation phase to have the initial
    conditions in the correct category
  - finally: add new ridging routine for ITD code

checkpoint64v (2014/04/11)
o pkg/ecco:
  - add runtime parameters mdt[start,end]date[1,2]
  - rename variable "tpmean" as "mdt" and "topexmeanfile" as "mdtdatfile"
o pkg/seaice:
  - make deltaC a global variable, so that it can be used in ridging code
  - first step towards ridging: introduce new routines that compute
    ice strength based on ridging parameters
  - add diagnostic for HSNOWITD
  - add opnWtrFrac as a global variable (required for ridging scheme)
o pkg/salt_plume + pkg/seaice/seaice_growth.F
  - add SALT_PLUME_IN_LEADS flag to activate pkg/salt_plume only when ice
    AREA exceeds a threshold (code contributed by I.Fenty in 2011)
o verification/hs94.1x64x5:
  - leave ALLOW_AUTODIFF_TAMC undefined in code_oad/AUTODIFF_OPTIONS.h
  - do not use ECCO_CPPOPTIONS.h anymore for TAF & OpenAD Adjoint tests.
o autodiff:
  - Start to include explicitly AUTODIFF_OPTIONS.h, COST_OPTIONS.h,
    and CTRL_OPTIONS.h in src files (to enable to skip the ECCO_CPPOPTIONS.h)
    For now, only in pkgs used in verification/hs94.1x64x5.
  - Replace ALLOW_AUTODIFF_TAMC by ALLOW_AUTODIFF (except for tape/storage
    which are specific to TAF/TAMC).
  - Replace ALLOW_AUTODIFF_OPENAD by ALLOW_OPENAD:
    since ALLOW_OPENAD is defined in PACKAGES_CONFIG.h (any time pkg/openad
    is compiled), this simplifies/reduces which *_OPTIONS.h file to include.
  - OpenAD: change Makefile to generate the appropriate AD_CONFIG.h when
    building mitgcmuv_ad (make adAll).
o pkg/ecco:
  - cost_gencost_seaicev4.F:
     reformulate proxy cost as function of sst and local param SEAICE_freeze
     change cost names from siv4-[sst,vol] to siv4-[deconc,exconc]
  - add stop statement if old names siv4-[sst,vol] are used
  - add snapshots + cost reports for atmospheric longwave
  - remove factor 0.1 in front of wtau[u,v]
  - replace never used flag ALLOW_TMI_COST_CONTRIBUTION with
     ALLOW_TMI_SST_COST_CONTRIBUTION
o pkg/atm_phys:
  - add some diagnostics for Short-wave and for convection S/R.
o pkg/seaice/seaice_growth:
  - fix a bug in the lateral melt parameterization for SEAICE_ITD
    in seaice_growth; tempFrz needs to be computed inside the i/j-loop
  - rearrange loop order for better vector code in the same code block
  - rewrite the floeDiameter formula to have fewer divisions
  -  (miraculously) none of this changes the results of seaice_itd
o pkg/smooth:
  - move param smooth2Ddiffnbt to pkg/ecco
o pkg/salt_plume:
  - salt_plume_frac.F:
     clean up local param names
     reformulate (1-frac) to frac; original 1-frac was based on swfrac code
o pkg/rw:
  - add RS version of S/R READ_MFLDS_LEV.
o pkg/streamice:
  - fix the restart test by writing/reading pickup_streamice files.
o pkg/seaice:
  - refine checks for jfnk-related parameters
  - comment out if statement with SEAICEuseIMEX parameter as long as there
    is no IMEX code to avoid confusion and surprises

checkpoint64u (2014/03/07)
o verification/MLAdjust:
  - rename secondary test suffix:
     1.leith  -> A4FlxF  + switch to flux-form & add side-drag
     0.leithD -> AhFlxF  + switch to flux-form
     0.smag   -> AhVrDv  (use Vorticity-Div. visc form) + add side-drag
     0.leith  -> AhStTn  (use Strain-Tension visc form) + add side-drag
o pkg/mom_vecinv:
  - remove unused arguments from S/R MOM_VI_HDISSIP & MOM_HDISSIP (as it used
    to be before mom_calc_visc.F)
  - skip the call to MOM_CALC_TENSION & MOM_CALC_STRAIN if not needed.
  - add 2nd copy of vort3 & strain that knows about lateral BC (free/no slip):
    this is simpler for the adjoint and for diagnostics.
o model/src + pkg/momentum:
  - add input files for  2-D additional Western and Southern cell-edge wall
     (e.g., to add "thin-wall" where it is =1).
  - fix sideDrag option for thin-walls with Non-Lin Free-Surf
    using 2nd hFacZ that is computed from initial (fix domain) hFac
  - known limitations of thin wall implementation: not yet coded for sigma
    coords; not working with CD-scheme neither.
o pkg/seaice:
  - rename recently introduced parameters from (wrong name) AB to
    BDF (backward difference time discretisation)
  - retire runtime parameters SEAICEuseAB2, SEAICE_abEps
o tools/adjoint_options:
  - remove setting of "OPENAD=true" (now set by command line "genmake2 -oad")

checkpoint64t (2014/02/01)
o pkg/ecco
  - add compile flag ALLOW_GENCOST_TIMEVARY_WEIGHT in ECCO_OPTIONS.h and
    runtime logical flag gencost_timevaryweight to read daily sea-ice sigma
  - replace hard-coded record number and period which only work for monthly
    with read-in runtime param that works for other periods (month,day,year)
o pkg/thsice
  - corrected store directive fixes thsice adjoint gradient checks
o genmake2 & testreport:
  - add genmake2 option "-oad" to generate a Makefile for OpenAD built and
    in this case, use tools/adjoint_options/adjoint_oad as default AD optfile.
    Update testreport accordingly. No need to set "export OPENAD=true"
    in adjoint_options/adjoint_oad anymore (will be removed later).
o pkg/shelfice:
  - put T & S shelfice forcing into model surfaceForcing_T,_S (for now,
    only if SHELFICEboundaryLayer=F); Change model/src/external_forcing.F
    so that surface forcing applies to k=kSurf if using pkg/shelfice.
o pkg/ctrl, pkg/grdchk, pkg/ecco:
  - Changes to make GENARR more modular (i.e. invisible if not used)
o model/src/temp_integrate.F and salt_integrate.F
  - re-include store directives that were removed on Dec 27th.
o model/src/external_forcing_surf.F
  - add storage directives for EmPmR and PmEpR to avoid recomputation of
    seaice_model in the adjoint that is problematic when seaice_model is
    turned off in the adjoint. The resolved issue dated back to July when
    EXTERNAL_FORCING_SURF call was moved.
    Update global_ocean.cs32x15/*/output_adm.seaice_dynmix.txt accordingly.
o pkg/exf/exf_check.F
  - fix a small bug again (originally found by Wentao Liu, now found again)
  - streamline error output
o pkg/streamice and aim_v23:
  - replace a few "_EXCH_XY_RL (" with "_EXCH_XY_RL(", so that
    Apple's /usr/bin/cpp knows what to do:
    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
    Target: x86_64-apple-darwin13.0.0

checkpoint64s (2014/01/05)
o tools/adjoint_options:
  - switch to fastopt.net TAF server (instead of default fastopt.de) for
    AD optfiles adjoint_diva & adjoint_f95 (similar to adjoint_default).
o model/src:
  - remove some unnecessary TAF storage directives in forward_step.F and
    in dynamics.F (note: not always removed by TAF, e.g., double storage
    of kappaRU,kappaRV in former version of dynamics.F).
o model/src & pkg/ptracers:
  - call directly GAD_IMPLICIT_R & IMPLDIFF + DWNSLP_APPLY from temp_integrate.F
    salt_integrate.F and ptracers_integrate.F (instead of from thermodynamics.F)
    and remove ptracers_dwnslp_apply.F & ptracers_implicit.F
  - call MATRIX_STORE_TENDENCY_EXP for each tracer (in ptracers_integrate.F)
  - add fZon & fMer as output argument of S/R GAD_CALC_RHS.
  - update TAF AD-output of experiments global_ocean.90x40x15 (13 for AD-grad).
o useSingleCpuInput separates single-CPU input from single-CPU output;
    for now only implemented for in exf_interp_read.F
o verification/advect_xy:
  - fix missing EXCH call in local version of ini_salt.F and update output.
o momentum diagnostics:
  - fix which deltaT is used in Total-Tendency diagnostics.
  - fix typo in diagnostics for momentum tendency from AB.
o pkg/seaice/seaice_lsr.F: fix an initialisation bug for the
    SEAICE_VECTORIZE_LSR_ZEBRA option that lead to NaNs on a NEC-SX8

checkpoint64r (2013/12/08)
o verification/*/results:
  - Update reference output of experiments that were passing with just 13 digits
     (make it easier to detect future changes in results)
o model/src & pkg/ptracers:
  - move calls to GAD_ADVECTION (Multi-Dim advection) from thermodynamics.F to
    inside temp_integrate.F and salt_integrate.F and from ptracers_advection.F
    to inside ptracers_integrate.F ; remove ptracers_advection.F
o coupling interface pkgs:
    [atm_compon_interf, ocn_compon_interf & atm_ocn_coupler]
  - change the config check to test the agreement of Ocean Depth
    with ATM land/sea mask (instead of ATM orography);
  - send to coupler the number of coupler time-steps to do for this run:
    this allows to check for consistency and don't need anymore to be
    specified in parameter file "data";
  in coupler:
  - check consistency of RunOff map versus Ocean Depth and ATM land/sea mask.
  - improve report to log-file of config setting (pass log-file unit to few S/R)
o pkg/compon_communic:
  - add coupling send/receive for non-tiled integer vector;
  - add S/R to check and stop if any proc has an error (similar to
    eesupp/src/stop_if_error.F but single thread and across Comm_World).
o pkg/exch2:
  - in exch2*_get_rx[1,2]: use new list "W2_tileIndex" to replace search
    through list of all tiles my proc owns.
o model/src:
  - AUTODIFF only: in calc_adv_flow.F, recompute rTransKp (instead of copying
    from rTrans) to simplify dependencies (no need to store rTrans anymore in
    calling S/R); this affects AD results at machine truncation level:
    update AD-output (TAF) of experiments: 1D_ocean_ice_column,
    bottom_ctrl_5x5 & obcs_ctrl (12 digits for AD grad, same FWD grad).
o tools/build_options:
  - simplify Warnings options (-ieee & -devel cases) in linux_amd64_gfortran
o coupling interface pkgs:
    [compon_communic, atm_compon_interf & ocn_compon_interf]
  - move declaration of local array "ibuf" out of header file "CPLR_SIG.h"
    to each S/R that needs it; remove un-used variables.
  - change component tile registration (cpl_register.F in both compon_interf
    and mitcomponent_tile_register.F) to pass the full list of tiles
    information (including bi,bj) in 1 vector (instead of in a bi,bj matrix).
  - with pkg/exch2: adopt the same convention used for I/O to define mapping
    towards coupler global array (unless W2_useE2ioLayOut=F):
     a) can now use different tiling between atm & ocn comp.
     b) no needs to modify the run-Off map when changing tiling (was needed
        even if using the same tiling between atm & ocn).
     c) will allow to run with blank-tiles in 1 component (e.g., for ocean
        full land tiles); not yet tested.
  - check for valid mapping from comp. tile to coupler global array
  - improve report of tile registration results to log file.
o pkg/exch2:
  - in eesupp/src/eeboot.F: move call to W2_EEBOOT before Coupler
    tile-registration (CPL_REGISTER);
  - activate (un-comment) definition and setting of "W2_tileIndex" list to
    store the local bi,bj indices of each tile;
  - also print bi,bj in local report to log file;
  - fix pkg/debug/debug_cs_corner_uv.F for the case nSy > 1 (left from
    Jun 2009 modif of pkg/exch2).
o testing on baudelaire:
  - run 2 tests at a time: no significant slow down (since enough cpu) and
    get the full set of test done earlier
  - switch the ifort test to "-devel" ; run the OpenAD test everyday.
o model/src/thermodynamics.F and routines called from it:
  - pkg/gmredi: gmredi_residual_flow.F (replacing gmredi_calc_uvflow.F &
    gmredi_calc_wflow.F) to update eulerian velocity (input) into residual
    velocity (outp) by adding bolus velocity.
  - model/src: calc_adv_flow.F (replacing calc_common_factors.F) to compute
    mass transport from velocity + lateral grid cell area
  - rename calc_gt.F to temp_integrate.F (includes call to TIMESTEP_TRACER)
  - rename calc_gs.F to salt_integrate.F (includes call to TIMESTEP_TRACER)
 in thermodynamics.F
  - remove k from thermodynamics.F and move it to temp_integrate.F
    salt_integrate.F and ptracers_integrate.F (now done inside the tracer
    loop).
  - compute locally (in thermodynamics.F) 3-D velocity field that is used to
    advect tracers; pass it as argument to GAD_ADVECTION, GAD_SOM_ADVECT,
    PTRACERS_ADVECTION, TEMP_INTEGRATE, SALT_INTEGRATE, PTRACERS_INTEGRATE,
    GAD_IMPLICIT_R and PTRACERS_IMPLICIT
  - update AD-output (TAF & OAD) of experiments: 1D_ocean_ice_column,
    global_ocean.90x40x15, tutorial_global_oce_biogeo and
    tutorial_tracer_adjsens (+ TLM output).
o tools/OAD_support and (verification/*/) code_oad:
  - OAD_support/cb2mGetModules.csh: add PACKAGES_CONFIG.h in header file to
    module conversion ; remove unneeded CPP_EEOPTIONS.h.
  - code_oad/CPP_OPTIONS.h: remove PACKAGES_CONFIG.h and use a more standard
    version (closer to model/inc/CPP_OPTIONS.h).
o model/src:
  - remove parameter "useOldFreezing" from PARAMS.h and push it to the
    retired list of parameters (routine FREEZE has been replace by surface
    freezing (10.yrs ago) and by pkg/frazil (interior freezing).
o pkg/gmredi:
  - add option (GM_CALC_TRANSP_FROM_VEL) to compute transport directly from
    velocity (same scheme but affects machine truncation) for GM_AdvForm.
  - update output of FWD experiments: front_relax.bvp,
    global_ocean.90x40x15.dwnslp, global_ocean.cs32x15 and ideal_2D_oce.

checkpoint64q (2013/11/17)
o verification:
  - generate new output on baudelaire (gfortran, -ieee) for OpenAD experiments
    tutorial_global_oce_biogeo and global_ocean.90x40x15.
  - generate new output (growth & melt) for seaice_itd experiment after
    updating the input pickup_seaice files (previously wrong).
o pkg/cost:
  - define a "final cost function" for each tile, and use GLOBAL_SUM_TILE_RL
    (instead of _GLOBAL_SUM_RL) to get the final cost from all procs & threads:
    o this fixes global-sum value if multi-threads (since GLOBAL_SUM_RL
      cannot be applied to var in common block).
    o allows to get results independent of tile-per-proc setting (if using
      slower GLOBAL_SUM_SEND_RECV option).
  - update accordingly: seaice_cost_final.F, shelfice_cost_final.F,
    thsice_cost_final.F and ecco_cost_final.F (this one affects lab_sea
    forward gradients: update output).
  - update */code_oad/externalDummies.F by adding dummy GLOBAL_SUM_TILE_RL
    S/R and, for most exp., also comment out GLOBAL_SUM_R8.
o pkg/mom_common:
  - move to pkg/mom_common and model/src (previously in tutorial_deep_convection
    code) 2nd version of isotropic 3-D Smagorinsky code interface: strain and
    viscosity are locally declared in dynmics.F and pass as argument to CALC_GW;
    ensure that all field value that are used are set.
o tutorial_deep_convection (smag3d):
  - add missing scaling in mom_calc_smag_3d.F;
  - set smag3D_coeff in input.smag3d such that results do not change.
o pkg/dic:
  - change dic_cost.F to compute cost on each tile first and then apply
    GLOBAL_SUM_TILE_RL: this affects forward gradient of AD experiments
    tutorial_dic_adjoffline & tutorial_global_oce_biogeo; update output.
  - remove kLev argument and use GLOBAL_SUM_TILE_RL in tracer_meanarea.
o eesupp/src & pkg/mdsio:
  - remove gather/scatter_vector.F (from eesupp) and mdsio_read/writevector.F
    (from pkg/mdsio) since they are no longer used for tape IO.
  - move simple C subroutine "setdir.c" from pkg/compon_communic to eesupp/src
    (+ keep a copy in pkg/atm_ocn_coupler).
o verification/isomip:
  - split domain in 8 squared tiles (instead of just 2) for FWD, AD & OAD tests.
o tools/build_options:
  - optfile linux_amd64_ifort11, fast (no ieee) case:
    to get a working restart for all experiments, add "-fp-model source"
    to FOPTIM (also remove "-opt-streaming-stores auto" <- this is the default).

checkpoint64p (2013/10/20)
o pkg/autodiff:
  - adread_adwrite.F: when type and length do not match ALLOW_AUTODIFF_WHTAPEIO
    criteria, return to simple (default) tape IO format.
o pkg/mdsio (+ eesupp/src):
  - rewrite/simplify tape-IO S/R (new S/R MDS_READ/WRITE_TAPE replace
    previous MDSREAD/WRITEVECTOR) with 2 array argument from each type (R4/R8);
  - fix globalFile and singleCpuIO options using simpler global mapping.
  - new pairs of scatter/gather vector S/R (one for each type, generated from
    template) corresponding to simpler global mapping.
  - adread_write.F: switch to new S/R (but leave old calls commented) and write
    to globalFile when parameter globalFiles is set to True.
  - switch on useSingleCpuIO in AD experiments: global_ocean.90x40x15 & isomip.
o pkg/autodiff:
  - adread_adwrite.F: add a hack for RS arrays (when RS=real*4);
    with ALLOW_AUTODIFF_WHTAPEIO defined, since corresponding (real*4) is
    missing, just add a STOP if array type do not match.
o pkg/exf:
  - to allow to use seaice-fraction from pkg/exf in other pkgs than pkg/seaice:
     rename CPP option EXF_ALLOW_SEAICE_RELAX to EXF_SEAICE_FRACTION
     and rename array obsSIce to exf_iceFraction.
o tutorial_deep_convection:
  - add 1rst version of isotropic 3-D Smagorinsky code (from Louis-Philippe),
    for now all in this exp. code dir.
  - add secondary test using Smag-3D viscosity (keep very low backgroud visc for
    testing) and flux-limter advection scheme for Temp. (no explicit diffusion).
o eesupp/src:
  - added SINGLE_DISK_IO option because reading of parameter files on
    very large number of processors did not work with existing set-up

checkpoint64o (2013/09/25)
o pkg/atm_phys & atm_compon_interf:
  - allows for coupling of gray-atmosphere (atm_phys) with ocean.
o tools/build_options:
  - switch from "-fPIC" to "-mcmodel=medium" in optfiles: linux_amd64_gfortran
    & linux_amd64_ifort11 and in linux_amd64_g77 & linux_amd64_open64 also
    remove CPP setting (was identical to genmake2 default).
o pkg/gmredi & model/src: Some updating and work done on the residual model.
  - created new file model/src/calc_eddy_stress.F to calculate the eddy stress.
  - fixed up the calculation of the eddy stress and how it is added to the
    external forcing via taueddy_external_forcing.F
  - at the moment, it is very experimental and only works with the variable eddy
    diffusivity calculated in gmredi_k3d.F
o pkg/seaice/seaice_check.F: add a check to catch the case of specifying
    lw/swfluxfile instead of lw/swdownfile in data.exf together with pkg/seaice
o testreport (& tools/do_tst_2+2):
  - for MPI test, set default COMMAND to 'mpirun -v -np TR_NPROC ./{executable}'
o tools/build_options: linux_amd64_gfortran & linux_amd64_ifort11:
  - remove CPP='cpp -traditional -P' (this is genmake2 default)
  - add switch (for big setups) to use 'medium' memory-model (but leave it
    commented out for now). Note: needed with FC 19 to compile big setups.
o pkg/atm_compon_interf:
  - regroup per field origin (model & pkgs) the coupling storage routines
     (which accumalate in time each coupling field)
  - move bi,bj loops inside atm_store_my_data.F and store also wind-stress;
    update accordingly + simplify aim_do_physics.F

checkpoint64n (2013/08/26)
o pkg/bbl:
  - update formulation to reduce dispersion of tracer properties in bbl
  - replaced horizontal and vertical transport parameters with velocities
  - changes results for verification/global_with_exf.yearly
o verification/halfpipe_streamice:
  - change to matrix construction; update both Fwd & AD output.
o verification/tutorial_tracer_adjsens:
  - OpenAD test: switch to vector-invariant momentum since fluxform with
    rStar causes problems with OpenAD; update output.
o tools:
  - genmake2: define a common prefix for all temp-file names ; move them
    to local /tmp disk (but would be easy to move them back);
  - xmakedepend: apply the same switch for temp-files.
o pkg/offline:
  - changes for use with rStar (NLFS): assume that we continue to provide
    UVELMASS/hFacW_ini & VVELMASS/hFacS_ini (hFacWi,S_ini as written in grid
    output files) and apply r* scaling at each time-step (function of the time
    varying Eta field); use normal pickup files (needed for restart with NLFS).
o adjoint with OpenAD:
  - move OpenAD-specific files from verification/OpenAD/code_oad_all to a new
    package openad.  This package has to be compiled for all runs with OpenAD
    instead of specifying code_oad_all as a modification directory.
  - link the fortran templates from tools/OAD_support to the build directory
    for preprocessing to avoid conflicts between different setups compiled
    simultaneously and simplify cleanup.
o pkg/exf:
  - in exf_getforcing.F: comment out most of the EXCH calls (fields used by
    main model or other pkgs are exchanged in EXF_MAPFIELDS).
o model/src:
  - do_stagger_fields_exchanges.F: skip EXCH calls when using pkg/offline
    (similar to do_fields_blocking_exchanges.F).
o tools/genmake2:
  - remove TAF output src code just before calling staf (when not doing a fresh
    built, will stop if things go wrong with staf).
  - fix target "adobj" (left from TAF version-2 transition)
o pkg/diagnostics:
  - add a parameter to track the status of pkg/diagnostics activation;
    this replace/extend the use of logical param "settingDiags" (to check
    when adding diag to the list) to also check any DIAGNOSTICS_[]FILL* call.
    New S/R to print error message and stop when pkgStatus is not right.
  - to try: add a warning when "data.diagnostics" exist but useDiagnostics=F.

checkpoint64m (2013/08/13)
o model/inc:
  - move FCORI_MACROS.h from PARAMS(_MACROS).h to GRID_MACROS.h (left from
    8 yrs ago modif when Coriolis arrays were moved from PARAMS.h to GRID.h)
o pkg/kpp & aim_v23:
  - only call DIAGNOSTICS_FILL when useDiagnostics=TRUE.
o pkg/seaice:
  - restore (last time on 2011/12/24) ability to compile pkg/seaice with
    undefined pkg/exf ALLOW_ATM_TEMP or ALLOW_RUNOFF CPP-options.
  - only call DIAGNOSTICS_FILL when useDiagnostics=TRUE.
o eesupp/src:
  - fix check for overlap-size argument (myOLn.GT.MAX_OLY_EXCH)
    in exch1_rx[_ad].template (thanks to Francois Lefeuvre report).
o switch to TAF version-2:
  - add flow directives to "freeze" naming convention for ad-routines that
    are used in I/O routines of adjoint state and associated common blocks
    that are used in adcommon.h (backward compatible with version-1)
  - update all ad-optfiles (in tools/adjoint_options + few local to some
    verification exp) to switch to latest TAF version (currently 2.5.5);
    merge "*_mpi" adoptfiles into the corresponding non-mpi (but commented
    out except for diva).
  - the major change with TAF version-2 is that both the differentiated
    routines and the forward routines (new) are returned as part of the TAF
    output source code. Update genmake2 accordingly.
  - new output for AD experiment tutorial_global_oce_biogeo (better AD gradient
    with version-2 when compared to TLM or FWD gradient); other experiments
    output show minor changes (machine truncation level); update the few AD &
    TLM output with 12 matching digits only (some prior to version-2 switch).

checkpoint64l (2013/08/05)
o model/src:
  - in dynamics.F, skip the call to CALC_VISCOSITY if momViscosity=F
  - main_do_loop.F: no longer includes additional (AUTODIFF) header files
    when using TAF but only if using OpenAD.
o pkg/mom_common+fluxform+vecinv:
  - always set horiz. viscosity arrays to background value before calling
    MOM_CALC_VISC (in MOM_FLUXFORM & MOM_VECINV) and call S/R MOM_CALC_VISC
    only when using variable horiz. viscosity (useVariableVisc=T);
  - simplify mom_vecinv.F (only 1 block for momViscosity).
o pkg/mom_common: variable horiz. viscosity in NH code
  - move horiz-viscosity 3-D arrays viscAh_W & viscA4_W (used in calc_gw.F)
    from model/inc/NH_VARS.h to pkg/mom_common/MOM_VISC.h
  - store in common block (in MOM_VISC.h) logical parameters: useHarmonicVisc,
    useBiharmonicVisc & useVariableVisc.
  - fix old bug (already in 1rst implementation of variable horizontal viscosity
    in calc_gw.F, version 1.27, 2006/06/20):
    horizontal bi-harmonic viscosity in gW was missing when wiscA4W=0
    even if variable bi-harmonic viscosity (e.g., viscA4Grid) was non-zero.
  - change background horiz viscosity in vertical momentum (gW) to always be
    viscAhW,viscA4W (instead of switching to viscAhD, viscA4D when using
    any type of variable viscosity, e.g., viscAh/4Grid)
  - change default value of viscAhW,viscA4W to viscAhD,viscA4D (instead of
    viscAh,viscA4) which default to viscAh,viscA4 :  this avoid missing
    horiz. viscosity in W eq when just setting viscAhD/Z,viscA4D/Z (since
    default viscAh,viscA4 is zero).
o model/src:
  - extend length of drC & recip_drC from Nr to Nr+1.
o Divided Adjoint (DIVA) with MPI:
  - genmake2: do not create local ./mpi_headers dir when no file to copy into.
  - remove option ALLOW_DIVIDED_ADJOINT_MPI (replaced by ALLOW_DIVIDED_ADJOINT
    and ALLOW_USE_MPI) from model/src code and from ECCO_CPPOPTIONS.h.

checkpoint64k (2013/07/23)
o tools/OAD_support:
  - avoid the need for file "oadtempflile" in insertTemplateDir.bash
    and remove it from genmake2.
o tools/build_options:
  - remove MPI_HEADER_FILES_INC setting (no longer used) and comment out
    MPI_HEADER_FILES list (let genmake2 find the missing headers)
o verification/halfpipe_streamice:
  - change to driving stress formulation; update both Fwd & AD output.
o tools/genmake2 and Divided Adjoint with MPI:
  - remove default setting of MPIINCLUDEDIR from $MPIHOME (always been broken);
  - only create local ./mpi_headers dir if using MPI and MPIINCLUDEDIR is set;
  - add new variable (LOCAL_MPI_HEADERS, replace MPI_HEADER_FILES_INC) in
    Makefile, which is set by genmake2, and check which mpi-headers are needed.
    Note: need to update adjoint_options/adjoint_diva_mpi accordingly.
  - update target "CLEAN" (to also remove ./mpi_headers/ dir).
o testreport:
  - changes for Divided Adjoint Run: when file "run_ADM_DIVA" is present,
    perform additional runs (number of additional runs is "add_DIVA_runs" taken
    from file run_ADM_DIVA ; should match "nchklev_3" in file "code_ad/tamc.h").
o verification/lab_sea (AD test):
  - change to test Divided Adjoint Run in this set-up (both standard AD test
    and 2 secondary AD test: noseaice + noseaicedyn); drop the evp AD test.
o pkg atm_ & ocn_compon_interf:
  - remove cpl_earlyExpImpCall=F option (was mainly a hack added for the old
    staggerTimeStep implementation) and disable (retired) corresponding
    parameter.
o pkg/offline:
  - comment out unused field-array: ICEM, ConvectCount, hflx[01], icem[01];
  - add S/R OFFLINE_CHECK to print offline parameter summary
    and stop if loading a file that is not used;
  - enable to calculate GMRedi tensor, KPP mixing and convective index
    when the corresponding file(s) is/are not specified (but pkg is used).
  - comment out resetting of monitorFreq (to endTime) since it still useful
    for monitoring CFL numbers and checking offline fields.
o OpenAD:
  - do not define OAD_DEBUG (in tools/adjoint_options/adjoint_oad) to get
    smaller standard output) and generate new (smaller) output (on baudelaire
    using gfortran with -ieee) for exp. tutorial_tracer_adjsens
o model/src:
  - call EXTERNAL_FORCING_SURF outside bi,bj loops (in do_oceanic_phys.F),
    (where external_forcing_adjust was called) and change list of arguments;
  - merge external_forcing_adjust.F into external_forcing_surf.F
  - put surface relaxation of SST & SSS in new S/R (forcing_surf_relax.F)
    which also contains balancing surface relaxation (ALLOW_BALANCE_RELAX,
    previously in file "balance_relax.F", now removed); remove corresponding
    arrays in FFIELDS.h.
  - EXTERNAL_FORCING_SURF is now called when using pkg/offline; implement
    a hack for getting back surfaceForcingS (loaded from file) when using
    ALLOW_OLD_VIRTUALFLUX (pkg/dic, in DIC_OPTIONS.h) in offline set-up.
  - update output of AD test experiment global_ocean.cs32x15.seaice_dynmix
    (was getting only 11 digits for AD-grad, due to different truncation
     error in AD code).

checkpoint64j (2013/07/04)
o pkg/offline:
  - to enable the use of other features with pkg offline (e.g., obcs),
    also call S/R DO_OCEANIC_PHYS in offline run - more modifs to come.
  - comment out "allowFreezing" (now active) in 2 offline testing exp.
o pkg/exf ALLOW_RUNOFTEMP
  - fix sign and make compatible with temp_EvPrRn .NE. UNSET_RL
  - ahdded RUNOFTEMP test to verification/global_ocean.cs32x15/input.seaice
  - changes verification/global_ocean.cs32x15/results/output.seaice.txt
o pkg/atm_phys:
  - allows to add some damping on uVel,vVel (strength only function of k).
o verification, ad-tests:
  - reduce length of the simulation for AD test: global_ocean.cs32x15.seaice,
    global_ocean_ebm and offline_exf_seaice.thsice.
o verification/halfpipe_streamice:
  - found a bug in s/r pkg/streamice/streamice_advect_thickness which caused
    flux input boundary conditions to be ignored; a fix for this bug changed
    verification results for forward test.
  - add adjoint test.
o pkg/ptracers:
  - allow to restart without SOM pickup (resetting SOM to zero).
o pkg/gmredi:
  - New parameterisation for the calculation of K and (GM_PsiX,GM_PsiY) added.
  - It uses mixing length theory and suppression by steering level effects to
    calculate a diffusivity used in the Redi tensor (see Bates et al., submitted
    to JPO, for more details).
  - It also uses the diffusivity to calculate an eddy induced streamfunction
    based on a PV closure (rather than a buoyancy closure as in GM).
  - New files added to pkg/gmredi:
    gmredi_k3d.F calculates the diffusivity for the Redi tensor and the eddy
      induced overturning streamfunction (called from gmredi_calc_tensor)
    gmredi_calc_eigs.F calculates the eigenvalues and eigenvectors required
      for use in gmredi_k3d
    gmredi_calc_urms.F calculates the the rms eddy velocity used to calculate
      the eddy diffusivity

checkpoint64i (2013/06/18)
o pkg/cheapaml:
  - take src files from MITgcm_contrib/verification_other/offline_cheapaml/code
    that enable the use of seaice (pkg/thsice thermo & pkg/seaice dynamics)
    with pkg/cheapaml.
o utils/python: add subpackage for cubed sphere function, first example is
    simple cs.pcol to plot 2D fields on a map
o pkg/streamice:
  - This is a new package in MITgcm, which solves dynamic equations for ice
     sheets and ice streams
  - At the moment it is independent of atmosphere/ocean dynamics, or any
    other physical packages in MITgcm, even ShelfIce (although it is anticipat-
    ed that this will change)
  - There is a new verification exercise that tests it, halfpipe_streamice,
    evolves a 40x80 km ice stream/ice shelf (at coarse resolution) in a
    rectangular embayment
  - halfpipe_streamice is forward-only for now, will have TAF test soon
  - for questions, email dgoldber@mit.edu
o pkg/thsice:
  - fix filling of snow-precip diagnostic (SIsnwPrc) (left from the removing
    of snowPrc from common bloc, on May 2nd, thsice_step_fwd.F revision 1.40);
  - remove diagnostics 'SI_FrcFx' ( now identical to 'SI_Fract' with new
     call sequence: ice-Thermo(thsice),ice-Dyn,ice-Advect );
  - allow precip from pkg/cheapaml to make snow over seaice.
o pkg/cfc:
  - move in separated header file (CFC_ATMOS.h) time-serie arrays of Atmos CFC
  - remove atmos CFC 2-D arrays from common bloc (now local variables)
  - change some hard-coded constant to run time parameter for reading and
    and interpolating atmospheric CFC ; keep same default as previously.
  - more flexible reading of Atmos CFC (number of records no longer hard-coded)
  - put arguments in standard order: myTime, myIter, myThid
  - use standard S/R GET_PERIODIC_INTERVAL for time interpolation of
    atmospheric CFC ; fix for the case myIter < PTRACERS_iter0.
  - fix calculation of surf tendencys for partial-cell and/or Non-Lin Free-Surf
  - new routine to print summary of CFC params and check for consistency.
o pkg/seaice: add uice/vice to the parameter list of s/r seaice_advdiff,
  similar to thsice_advdiff.
  Note that for the B-grid case the routine parameters uc/vc are overwritten.
o pkg/cfc:
  - change time interpolation for atmospheric CFC-11 (now same as for CFC-12);
    update output (CFC-11) of experiment cfc_example and tutorial_cfc_offline.
  - fix interpolation of atmphspheric CFC between Sorthern and Northern
    hemisphere value.
o pkg/seaice:
  - allow to use seaice dynamics without pkg/exf (e.g., using pkg/cheapaml)
o pkg/seaice: add Adams-Bashforth2 time discretization for ice dynamics;
              so far only for JFNK-solver, turn on with SEAICEuseAB2 = .TRUE.
  - requires an additional time level that is stored in the pickup
  - you can start with AB2 from a pickup without this time level with
    pickupStrictlyMatch = .false.

checkpoint64h (2013/05/26)
o pkg/cheapaml:
  - replace one ()**.5 with SQRT + use temp var "cdu = tau/Du" (coare3_flux);
    affect machine truncation (but exp cheapAML_box still pass with 13 digits).
  - consistent treatment of uWind,vWind location: assume everywhere in
    pkg/cheapaml that they are on C-grid (@ uVel,vVel location)
    (Note: was already the case for Tair,Qair advection);
    add option (INCONSISTENT_WIND_LOCATION) to recover old results.
  - compute diabatic forcing only in the interior (excluding overlap regions)
  - fill in array "Qsw" (for short-wave heating);
  - add diagnostic for precip ; fill-in diagnostics for cheapAML state vars
    before any update (consistent with MITgcm state var diagnostics);
  - cheapaml_fields_load.F & cheapaml_init_varia.F : only fill outer edges if
    non periodic ; + adjusted for uWind,vWind (C-grid).
o pkg/seaice:
  - remove dependence of pkg/seaice versus pkg/exf (file: pkg/pkg_depend) and
    add explicitly pkg/exf in experiments that currently use pkg/seaice.
  - allows to compile pkg/seaice without pkg/exf.
o tools/OAD_support:
  - use a local copy (ourRWCPinBd) to ensure index ourRWCP stays within bounds
    of array "ourStepOf" in function rvNextAction (revolve.F90).
o pkg/aim_compon_interf renamed to pkg/atm_compon_interf
  - change pkg name (to be used with other atmospheric physics pkg)
    but by-pass CVS when making the new pkg so that we keep the CVS history.
o pkg/offline:
  - call OFFLINE_FIELDS_LOAD from pkg/offline/offline_init_varia.F
    (previously called from pkg/dic_surfforcing_init.F)
o model/src:
  - re-order sequence of calls within packages_init_variables.F, using
    standard order, except for:
     DIAGNOSTICS_INIT_VARIA and OFFLINE_INIT_VARIA (called @ the top),
     CTRL_MAP_INI and OBCS_INIT_VARIABLES (called @ the bottom)
o new pkg: atm_phys
  - add entry point and source code (previously in contrib
      verification_other/atm_gray/code_gray/) for new pkg "atm_phys"
    (atmospheric physics pkg from P. O'Gorman and T. Schneider, JCl, 2008).
  - re-order sequence of calls within packages_readparms.F,
     packages_init_fixed.F and packages_write_pickup.F
    (but skip packages_init_variables.F because of TAF issues).
  - update contrib/*/atm_gray/ experiment.
o pkg/seaice (ITD code):
  - simplify and fix the writing of pickup-files for ITD case
o pkg/seaice (ITD code):
  - introduce floe size dependent lateral melt for ITD case;
  - cleaning (avoid division by zero, change to f77 syntax, remove tabs)
  - update seaice_itd experiment main output.
o pkg/thsice:
  - remove snowPrc from common block THSICE_FLUX, in THSICE_VARS.h and
    declared it locally (without bi,bj) in thsice_main.F & aim_do_physics.F;
    changed accordingly pkg/atm2d.

checkpoint64g (2013/05/01)
o pkg/exf ALLOW_RUNOFTEMP
  - if defined,  river and glacier runoff temperature can be read-in from
    runoftempfile; runoftempfile needs to have same format as runofffile
o pkg/thsice (& pkg/bulk_force):
  - In case Energy-Reference-Level (ERL) is used (temp_EvPrRn=0), account
    for energy content of Precip + RunOff & Evap (like with pkg/exf).
  - change computation domain to always be the interior (without overlap).
  - fix bug (wrong overlap) when using EXF and stressReduction > 0.
o verification/tutorial_global_oce_biogeo:
  - add preliminary OpenAD setup (still has problems)
o pkg/seaice:
  - turn some parameters for choosing the convergence criterion of
    the inexact Newton method (JFNK) into runtime parameters for convenience
  - clean up seaice_calc_viscosities.F: remove/retire two options for
    SEAICetaZmethod (1,2), introduce area weighting for method 3; this changes
    the results of lab_sea/input because a division has been replaced by
    a multiplication with the reciprocal (sumNorm)
  - modify offline_exf_seaice/input.dyn_jfnk/data.seaice to improve
    convergence of solver (changes results, of course), and to test some
    new features
o model/src:
  - remove unused (since Aug 2006) S/R SET_WRITE_GLOBAL_PICKUP and its call.
  - remove unused forcing field "dQdT" and associated parameter "dQdTFile".
  - move forcing adjustment (balancing surface forcing) in specific S/R
    where might also be applied exchanges (if needed) to forcing arrays.
o pkg/shelfice:
  - allow to specify the Ice-Shelf mass per unit area (instead of
    shelficeLoadAnomaly) and do the conversion from one to the other
  - move loading from file of shelficeLoadAnomaly from SHELFICE_INIT_VARIA
    to SHELFICE_INIT_FIXED: (a) avoid some TAF recompution issues and
    (b) will be loaded in time (before calling INI_PRESSURE) in case it is
    needed in phi0surf for initial pressure calculation when useDynP_inEos_Zc
  - update isomip experiment forward output (get machine truncation error
    from conversion shelficeLoadAnomaly -> shelficeMass -> shelficeLoadAnomaly)
o verification/offline_exf_seaice:
  revise data.seaice in input.thermo and input_ad and update results accordingly
    HO = 0.2, SEAICE_areaLossFormula = 2,
    SEAICE_growMeltByConv = .TRUE.,
    SEAICE_doOpenWaterMelt = .TRUE.,
  Improve consistency with input.thsice and fix the spurious 500m ice corners
o verification/global_ocean.cs32x15:
  - set Energy Reference Level to liq. water @ 0 degC: temp_EvPrRn=0.,
    in icedyn (thsice+seaice-dyn) test and update output.
o verification/offline_exf_seaice:
  - adjust list of tested variables (with testreport) and update
    standard test output with better slection of monitored fields.
o pkg/cd_code:
  - swtich off Adams-Bashforth on the 1rst iteration. Update output of
    experiment lab_sea.hb87
o tools/genmake2:
  - change default makedepend from the system default to tools/xmakedepend:
    When no makedepend is specified, select tools/xmakedepend it the test pass,
    otherwise select the system default (if exist and pass the test) or
    try to build cyrus-makedepend ; stop if none of the 3 works.
o pkg/exf & pkg/thsice:
  - In case Energy-Reference-Level (ERL) is used (temp_EvPrRn=0), account
    for energy content of Precip + RunOff & Evap. Assumes:
   1) Rain has same temp as Air.
   2) Snow has no heat capacity (consistent with seaice & thsice pkgs)
   3) Run-Off comes at the temp of surface water (with same Cp)
   4) Evap over ocean is released to the Atmos @ surf-temp (=SST); should be
    put directly into Latent Heat flux & should use water-vapor heat capacity.
   5) Evap over snow/seaice (pkg/thsice) assumes constant Lf+Lv (consistent
    with snow having no Cp) => water vapor is released to Atmos @ 0^oC (=ERL).
o pkg/seaice: simplify the use of CPP flags in JFNK-related files
    (compile when SEAICE_ALLOW_JFNK is defined)
o pkg/thsice:
  - fix oceanic flux diagnostics & timeave (left from new sequence of calls
    implementation): move THSICE_AVE call after the advection (called directly
    from thsice_do_advect.F).
o verification/global_ocean.90x40x15 and OpenAD:
  New experiment for OpenAD is identical to the one in input_ad except that
    multiDimAdvection=.FALSE.,
  There is still an issue with this.
o pkg/thsice:
  - account for ice velocity (ocean relative velocity) in turbulent heat flux
    at the base of the ice; update output of global_ocean.cs32x15 (icedyn)
    and offline_exf_seaice (main test).

checkpoint64f (2013/03/31)
o verification/OpenAD:
  - new (smaller, without OAD_DEBUG) output_oadm.txt generated using gfortran.
o verification/isomip, pkg/shelfice and OpenAD:
  - add OpenAD setup to this exp and make shelfice package work with OpenAD
o verification/tutorial_global_oce_biogeo:
  - update AD and TLM output after turning off ALLOW_FE (in DIC_OPTIONS.h)
o verification/offline_exf_seaice:
  - replace adjoint experiment (now similar to fwd input.thermo/ setup).
o verification/tutorial_tracer_adjsens, pkg/ptracers and OpenAD:
  - add OpenAD setup to this exp and make ptracers package work with OpenAD
o pkg/seaice/seaice_evp.F:
   mask the asymmetric contribution of the ice-ocean stress (when
   the turningAngle is non-zero) over open water to avoid stripes
   in the EVP-solutions after many EVP-substeps. This does not change
   the verification experiment (because turningAngle=0 in that experiment),
   but will affect other EVP solutions with turningAngle.ne.0
o verification, AD & TLM output:
  - new TAF version 2.3.10 (previously 2.3.8) add more parenthesis in multiple
    additions and multiplications which affect results at machine truncation
    level. Update few AD output (1D_ocean_ice_column, bottom_ctrl_5x5,
    lab_sea.noseaicedyn & offline_exf_seaice) and TLM output
    (1D_ocean_ice_column & tutorial_tracer_adjsens.som81) which had only 12
    digits of matching.
o pkg/seaice:
   modify lsr-algorithm so that it vectorizes AND converges by using a
   "zebra" method: split vector loop into two with step size 2; this
   solves a general convergence problem for the JFNK solver on a vector
   computer. It has the potential to even improve convergence for
   non-vector machines, but it does change the results so it is turned
   off by default. To turn on define CPP-flags SEAICE_VECTORIZE_LSR and
   SEAICE_VECTORIZE_LSR_ZEBRA in SEAICE_OPTIONS.h

checkpoint64e (2013/03/05)
o pkg/ecco and several verification experiments:
   Remove special versions of the_model_main.F, the_main_loop.F, forward_step.F
   from ecco package, and revert to unified routine in model/src/
   Adjust verification experiments accordingly, especially gloal_oce_llc90
   Should conclude long-standing work by Gael to reconsile the_main_loop with
   ECCO and will enable OpenAD's revolve loop in ECCO setup.
o pkg/generic_advdiff:
  - implement compressible flow method for multi-dim advection (similar to
    gad_som_advect.F); add new option "GAD_MULTIDIM_COMPRESSIBLE" (since
    TAF generates many recomputations) to use it; no yet coded with implicit
    vertical advection.
  - change experiment advect_cs (new output) and advect_xy (same output)
    to test compressible flow multi-dim advection.
o pkg/generic_advdiff:
  - fix SOM advection for unusual cases (linear Free-Surf in r*, other
    cases where linear Free-Surf is not @ k=1, e.g., useShelfIce)
o pkg/seaice:
  - fix bug in the no-slip implementation in seaice_calc_strainrates.F, this
    bug affects two verification experiments (lab_sea and lab_sea.hb87),
    recover old (wrong) results by setting noSlipFac = 2. in
    seaice_calc_strainrates.F;
  - add another averaging method for etaZ (etaZmethod=3), a mix of 2 and 0
  - add runtime parameter SEAICE_JFNKepsilon for that finite difference
    gradient in the Jacobian times vector operation (s/r seaice_jacvec)
  - fix line search in seaice_jfnk.F (s/r seaice_jfnk_update)
o pkg/seaice: reorganize seaice_lsr.F to be able to reuse more code:
  - new subroutines seaice_lsr_tridiagu/v
  - introduce loop bounds i/jmin/max to be able to use a restricted
    additive Schwarz method, but not used for now.
  - rename SEAICE_CALC_LSR_COEFFS into SEAICE_LSR_CALC_COEFFS
  - use new subroutines seaice_lsr_tridiagu/v in s/r seaice_preconditioner
o OpenAD support
   Reorganize S/R call for overall time-stepping loop to facilitate
   OpenAD revolve loop replacement
   (new S/R main_do_loop.F)
o model/src:
  - add 3-D array 3rd dimension to argument list of S/R ADAMS_BASHFORTH2/3;
  - pkg/cheapaml: remove local S/R ADAMS2d and use instead standard S/R
    ADAMS_BASHFORTH2.
o pkg/cheapaml:
  - add new parameter (default=F, same as before) to disable full domain
    (including land) periodicity in X & Y dir.
  - new S/R CHEAPAML_COPY_EDGES to copy relaxation field into edges of
    prognostics field ; merge the 2 S/R cycle_2d_tracer and timestep_2d_tracer
    into single S/R CHEAPAML_TIMESTEP.

checkpoint64d (2013/02/17)
o pkg/monitor (angular momentum):
  - do not add Eta contribution to the total AM if using rigid-lid;
  - correct for Adams-Bashforth in zonal-wind part (instead of in AM_eta).
  - horizontal discretisation: compute Zonal wind contribution separately for
    each component (instead of from cell centered averaged) and use the 4
    grid-cell corner averaged value of Omega*(R*cos_Phi)^2 in AM_eta part.
  - Check that AM is conserved with linear dynamics (momAdvection=F and linear
    FreeSurf) if using vectorInvariant momentum.
o model/src (horizontal grid):
  - move initialisation of all horizontal grid arrays to null value
    from specific horizontal grid S/R to main S/R INI_GRID;
  - add 2 new arrays to project model C-grid velocity on to zonal direction
    (similar to AngleCosC & -AngleSinC but at U and V point location) and
    compute them in S/R CALC_GRID_ANGLES.
o pkg/seaice: replace a hard coded parameter by a runtime parameter
    SEAICE_JFNK_tolIter
o pkg/seaice: introduce a restricted additive Schwarz (RAS) method in
    preconditioner for JFNK (run LSR into the overlaps as far as possible,
    i.e OLx/y-2, but overwrite the solution in the overlaps)
  - extend loop range in seaice_calc_viscosity
  - add new parameters SEAICE_OLx/y (default = OLx/y-2)
  - add flexible loop ranges to seaice_preconditioner, seaice_calc_lsr_coeffs
  - slightly modify loops in tridiagonal solver lsr-preconditioner
  - by default remove the extra exchange in seaice_preconditioner with a
    replacement of an undocumented CPP flag by SEAICE_PRECOND_EXTRA_EXCHANGE
  - modify offline_exf_seaice so that old results without RAS are reproduced
    for output.dyn_jfnk.txt
  in seaice_fgmres.F (unrelated to RAS)
  - add a cpp-flag option for a re-ordered mapping (potentially more
    efficient), but because this changes the results, turn it off by
    default
  - replace the save statement by local common blocks
o utils/matlab:
  - fix tile-offset in rdmnc.m when output was produced using EXCH2.
  - update cs_grid/bk_line scripts to use load_grid.m (in utils/matlab)
    instead of local script "load_cs.m".
o pkg/seaice:
  - fix a serious bug in seaice_fgmres.F, s/r seaice_scalprod, connected
    to the scalarProductMetric and the unrolling. By chance this does not
    change the verification experiment, because of the particular domain
    decomposition
o pkg/diagnostics:
  - change default missing_value from UNSET_RL to -999.
o pkg/layers: improve vectorization of layers_fluxcalc.F
  - step 1: split loops, make TatU/V 2D arrays. This alone reduces the cpu
    time spent in this routine by more than a factor of 3 on an NEC-SX8
  - step 2: replace search algorithm by a bisection algorithm found in
    Press et al. Numerical Recipes in Fortran. This algorithm can be
    vectorized and finds the correct bin in approx. log2(Nlayers) steps.
    For now, use this algorithm only for TARGET_NEC_SX defined.
  - moved the search algorithm into a separate subroutine, that is kept
    within the same file for automatic inlining.
  - modified catching potential errors
o pkg/ecco:
  - add compile switches ALLOW_SHALLOW_ALTIMETRY and ALLOW_HIGHLAT_ALTIMETRY.
o model/src, pkg/autodiff, pkg/ctrl, pkg/grdchk :
  - modifications for ALLOW_GENTIM2D_CONTROL
  -- forward_step.F, the_main_loop.F : pass options and arrays for adjoint tapes.
  -- load_fields_driver.F : add call to CTRL_MAP_GENTIM2D( myTime, myIter, myThid )
  -- add xx_gentim2d0/1 in ctrl_ad_check_lev1_dir.h checkpoint_lev1_directives.h etc
  -- use ctrl_swapffields.F (new) instead of exf_SwapFFields.F in ctrl_get_gen.F
o model/src:
  - account for moist thermodynamics in (dry) potential temperature equation;
    update results of experiments: aim.5l_cs (x2), fizhi-cs (std + aqualev)
    and cpl_aim+ocn.
  - also switch to standard compiler (gfortran, was using ifort previously)
    for fizhi-cs experiments reference output.
o pkg/ctrl:
  - 1st step toward generic time-varying control variable (2D) via CPP option
    ALLOW_GENTIM2D_CONTROL
  - note new namelist ctrl_nml_genarr in data.ctrl
o verification/global_ocean.cs32x15:
  - switch off OLD_THSICE_CALL_SEQUENCE (both forward and AD code) to use new
    thsice calling sequence and update "output.icedyn.txt" output file.
o pkg/ptracers:
  - from Ryan A.: code to allow to restart a tracer at regular time interval
    specifying a reset frequency and a reset-phase (for each tracers).
o pkg/thsice:
  - implement new sequence of calls for thsice+seaice:
      previously:   ice-Dyn,ice-Advect,ice-Thermo(thsice)
      new sequence: ice-Thermo(thsice),ice-Dyn,ice-Advect
  - allows (with temporary CPP option "#define OLD_THSICE_CALL_SEQUENCE"
    in CPP_OPTIONS.h) to recover old sequence;
  - update diagnostics for Intermediate State thsice diagnostics: now filled
    just before advection (instead of just after advection in old sequence);
  - update output of experiment offline_exf_seaice (standard test);
  - in global_ocean.cs32x15 exp., postpone output.icedyn.txt update
    by setting #define OLD_THSICE_CALL_SEQUENCE in CPP_OPTIONS.h
o pkg/aim_v23:
  - use tiled array for aim_CO2 and surface wind speed for export to coupler;
  - use standard pkg/mdsio routines to read & write CO2 pickup file;
  - in-line S/R AIM_AIM2DYN_EXCHANGES in aim_do_physics.F;
  - Implement new sequence of calls for seaice advection (with thsice and
    seaice diffusion): do ice advection after ice-Thermodynamic (previously
    was done before); change aim_do_physics.F (split the bi,bj loops block);
  - use same CPP option (OLD_THSICE_CALL_SEQUENCE) to recover old sequence;
o pkg/thsice:
  - add a missing EXCH of sIceLoad in thsice_main.F (ocean set-up) for the case
    where just seaice diffusion is used without seaice-dynamics.

checkpoint64c (2013/01/18)
o pkg/seaice:
  - add a parameter JFNKres_tFac that can replace JFNKres_t
    (= JFNKres_tFac*JFNKresidual before JFNK solver)
  - add a line search option to the JFNK solver
  - move update of u/vIce and computation of initial residual into a separate
    routine (same file); makes the code a little easier to read (?)
  - the line search requires computation of the residual and for some reason
    I cannot do the update of u/vIce at the beginning of the Newton loop
    without changing the results, so we move computation of the new residual
    also to the end of the Newton loop, even without the line search
o pkg/mdsio:
  - write missing value (corresponding to undefined array value) to meta files;
    skip this if missing value is one (UNSET_RL would be a better value for the
    case of undefined missing value but it's current the default missing-value);
    Also update mdsio_read_meta.F (reading timeInterval & missing-value).
o pkg/exf & thsice:
  - for diagnostics purpose, fill-up and update Qsw array (+ fill the
    diagnostics) even when SHORTWAVE_HEATING is #undef;
o verification/cfc_example:
  - turn on pkg/layers with pkg/diagnostics (to test pkg/layers and to
    illustrate how to use it).
o verification/offline_exf_seaice:
  in input: add SEAICErestoreUnderIce=.TRUE., and reduce size of forcing
    files to only one time-record.
  in input.thermo: narrow the 2 bands of low initial ice-concentration near
    N & S edges; switch on SEAICErestoreUnderIce=T; use pkg/diagnostics for
    snapshot output; same mcPheePiston value as in thsice with
    surf-current=0.2m/s.
  in input.thsice: similar set-up as in input.thermo (channel with same seaice
    initial conditions).
o verification/cfc_example:
  - update file "data" with more standard choice (default rotationPeriod,
    exactConserv=T, reduce ivdc_kappa to 10, remove multiDimAdvection=F,
    set deltaTFreeSurf to deltaTtracer) and update the output.
o pkg/layers:
  - fix bolus part so that it compiles with #undef GM_BOLUS_ADVEC;
  - ensure that "layers_bolus" is switched to False when useGMRedi=False.
o verification/offline_exf_seaice:
  - set all {field}period to zero for constant-in-time forcing (not tested
    anywhere else).
o verification/offline_exf_seaice:
  - dyn_lsr  : use pkg/seaice S/R (instead of pkg/thsice) to advect sea-ice;
  - dyn_jfnk : use pkg/thsice S/R (instead of pkg/seaice) to advect sea-ice.
o model/src:
  - implement Finite-Volume method for (hydrostatic) presure gradient
    from S.-J. Lin (QJRMS 1997), for atmosphere using sigma-coordinate.
o pkg/seaice: implement EVP* by Lemieux et al. (2012).
  - In order to be compatible with the default EVP code, this requires changing
    the EVP code around a little; and because any small change immediately
    breaks the lab_sea.hb87 verification experiment, the reference output is
    updated two times (each time the remaining aggrement was only 2 digits):
    - after replacing 1/dt by 1*recip_dt with a precomputed recip_dt
    - after replacing 1/(1+0.5*dt/tau) by a/(a+1), with a=2*tau/dt
    The adjoint test lab_sea.evp also needed to be updated.
  - Turn on EVP* by setting SEAICE_deltaTevp as before, and setting
    SEAICEuseEVPstar=.true.; for EVP* SEAICE_deltaTevp does not need to be
    a factor of SEAICE_deltaTdyn, and you can set the number of EVP steps
    explicitly with SEAICEnEVPstarSteps (thereby overriding the default of
    INT(SEAICE_deltaTdyn/SEAICE_deltaTevp)). Controlling EVP* is deliberately
    kept obscure, because I need to test it a little more.
o pkg/cheapaml:
  - fix few incorrect type (_RL/_RS) in subroutine calls.
o pkg/seaice:
  - new S/R SEAICE_MAP_RS2VEC (similar to SEAICE_MAP2VEC) to map _RS arrays
    to _RL vector; this fixes JFNK code when compiling with "-use_r4" option.
o model/src:
  - add a warning if using select_rStar=2 with nonlinFreeSurf <> 4;
    change (in input_ad*/data) select_rStar from 2 to 1 for AD verification
    experiments global_ocean.cs32x15 & tutorial_tracer_adjsens (+ update output)
o pkg/cheapaml:
  - replace "273.1 _d 0" by celsius2K in pkg/cheapaml/cheapaml.F and
    update output of experiment cheapAML_box.
  - store in CHEAPAML.h coeffs ssq[0:2] for saturation specific humidity,
    and set them only in one place (cheapaml_readparms.F).
  - replace "273.16 _d 0" by celsius2K & replace "3.14159 _d 0" by constant "PI"
  - remove re-setting of main-model parameter "celsius2K" (in cheapaml_readparms)
    and re-setting of cheapAML params "lath" & "p0" (in cheapaml_init_varia).
o model/src/the_main_loop.F:
  - fix revision 129 : need both ALLOW_ECCO and ALLOW_ECCO_EVOLUTION.
o pkg/seaice:
  - remove legacy branch code.
  - retire SEAICE_GROWTH_LEGACY and SEAICE_CAP_HEFF accordingly.
o verification/*/code*/SEAICE_OPTIONS.h:
  - remove documentation for retired CPP flags (SEAICE_GROWTH_LEGACY,
    SEAICE_CAP_HEFF).
o pkg/cheapaml:
  - use standard routine (S/R GET_PERIODIC_INTERVAL) to decide when it is time
    to load new forcing fields.
  - add missing "_d 0" where it's needed; + some editing (improve indentation).
  - remove switch to "-r8" compiler option (no longer needed) in verification
    cheapAML_box, keep same output (small trucation error differences).
o verification/offline_exf_seaice:
  - add thermodynamics only test.
o verification/cheapAML_box:
  - split the domain in 8 (2x4) tiles; add MPI and multi-threaded test;
    keep same output (same 14 digits for cg2d).
  - switch on "-r8" compiler option (some numerical values are missing
    the "_d 0") and update output (only 6 digits for cg2d were preserved).

checkpoint64b (2012/12/24)
o pkg/cheapaml:
  - remove un-used variables (Qnet,EmPmR) from pickup files.
  - store tendency of advected variables into cheapaml pickup file
    and fix the AB-2 restart.
o verification/offline_exf_seaice and lab_sea adjoint:
  - switch to new code (#undef SEAICE_GROWTH_LEGACY).
  - switch to 4 time steps in offline, consistent with lab_sea.
  - match parameters from SEAICE_GROWTH_LEGACY branch in data.seaice.
  - update results after change of experiment seaice.
o pkg/seaice:
  - remove option SEAICE_MULTICATEGORY; has been replaced with run-time
    parameter SEAICE_multDim. Issue a warning if SEAICE_MULTICATEGORY is
    still defined since SEAICE_multDim needs to be set to MULTDIM value (from
    SEAICE_SIZE.h) to recover previous #define SEAICE_MULTICATEGORY default.
o model/src:
  - add run-time parameter to select CG2D solver minimum-residual solution
    (in case of a poor convergence).
o pkg/seaice/seaice_lsr.F
  - move calculation of matrix coefficients into new
    S/R SEAICE_CALC_LSR_COEFFS; for now this routine remains in the same
    file; the main purpose of this change is to be able to reuse the code
    in S/R SEAICE_PRECONDITIONER
  - modify the computation of the residual so that the mass of sea-ice
    is not used twice; this simplifies the calculations, but since
    the residual is never used except when LSR_mixIniGuess.ge.4---and this is
    not tested in testreport---this does not affect the testreport results.
o verification/seaice_obcs:
  - disable SEAICE_GROWTH_LEGACY; reset input files to match those of
    verification/lab_sea/input.salt_plume; changes results/output.txt*
o model/src:
  - adapt quasi-hydrostatic formulation to work with p or p* coordinate.
o pkg/seaice:
  - improve description of parameters in seaice_fgmres.F and start
    cleaning up the code
  - change name of SCALPROD to SEAICE_SCALPROD and modify meaning of
    second argument
  - add a metric based on grid cell area to SEAICE_SCALPROD; update
    results of offline_exf_seaice.dyn_jfnk
  - compute initial residual norm in seaice_jfnk based on SEAICE_SCALPROD
o pkg/aim_v23:
  - fix an other bug in dissipation heating (grid-cell area was missing).
o model/src + pkg/seaice:
  - add global (multi-tile) linear solver for pair of tri-diagonal system
    along X and Y lines, respectively for U and V component.
    Note: 1) MPI and cube-exchange not yet coded.
        2) probably not accurate for poorly conditioned / large size problem.
  - add option for SEAICE_LSR to use global (multi-tile) tri-diagonal solver;
    default: not compiled and not used.
o pkg/seaice:
  - first attempt at a multi-threaded fgmres solver for the JFNK solver:
    introduce bi/bj loops and use global_sum_tile_rl instead of
    mpi_allreduce in seaice_fgmres.F
  - improve diagnostics output for fgmres solver (seaice_fgmres.F)
  - replace a few unnecessary goto statements by if-blocks  (seaice_fgmres.F)
  - add a verification experiment for JFNK in offline_exf_seaice
o verification:
  - change (for now, only fwd test) offline_exf_seaice experiment:
    use a re-entrant channel with idealized coastline (trapezoidal shape)
    at southern boundary to explore seaice dynamics and thermodynamics
    with simple forcing. Main set-up has dynamics+thermo and SST relaxation;
    secondary test (input.thsice) use thermodynamics only with SST relaxation.
  - add seaice-dynamics only secondary test using LSR and pkg/thsice advection.
o pkg/exf:
  - disable "sstExtrapol" when Nr=1
o verification:
  - add new experiment "cheapAML_box" (simple 1 layer set-up from Bruno Deremble)
    to test pkg/cheapaml.
o pkg/aim_v23 & pkg/shap_filt:
  - fix dissipation heating (erroneous gravity multiplication factor).
o pkg/seaice:
  - remove unused field pressPre from jfnk solver
  - rename two subroutines in seaice_preconditioner.F
o eesupp/src:
   - S/R MDSFINDUNIT avoids reserved unit numbers (scrUnit1, eeDataUnit ...)
o pkg/seaice/seaice_preconditioner.F: fix preconditioner once again
   - remove wrong parts of the rhs and the lhs (were in there
     because I did not understand the concept of this preconditioner)
   - add an exchange between u- and v-sweep. This increases communication
     by a factor of two but improves the convergence of jfnk. Ideally,
     one would like the u- and v-sweep to be independent. So far within
     undocumented ifdefs
   - reorganize the extra computations for printing the residuals
o tools/genmake2:
  - comment out the "mpif.h" include in NetCDF test programm (for MPI built)
    since it's not necessary (and was preventing to use MNC in some cases).

checkpoint64a (2012/11/16)
o pkg/autodiff:
  - improve pkg-internal logical parameter switch (inAd/inFwd mode) so that
    autodiff_readparms.F no longer depends on calling order (within
    packages_readparms.F) and no longer requires to include ${PKG}_PARMS.h):
    rename param turnFreeDriftInAdMode to SEAICEuseFREEDRIFTswitchInAd
    and change param SEAICEuseDYNAMICSinAdMode to SEAICEuseDYNAMICSswitchInAd.
o pkg/obcs:
  - adding tidal velocity forcing capability to obcs
    for usage example, see verification/seaice_obcs/input.tides
o pkg/seaice:
  - turn the LSR-relaxation parameters WFAU/V into runtime parameters
    SEAICE_LSRrelaxU/V
  - introduce runtime parameter SEAICEetaZmethod (=0 by default)
o pkg/aim_v23:
  - implement heating from friction (bottom friction and stratospheric drag).
o pkg/shap_filt:
  - fix diagnostic "SHAP_dKE" (was 2 time smaller); implement heating from
    dissipation but only for Shap_funct=2, active when addFrictionHeating=T.
o model/src:
  - move AddMass common block from DYNVARS.h to FFIELDS.h; allow to read-in
    time-constant addMass field from file (addMassFile);
  - support for heating due to friction (and Kinetic Energy dissipation):
    add option, run-time switch and 3-D field array + support code ; each pkg
    or S/R can add heating contribution (if there is a sink of KE); the sum is
    accounted for as a Temperature tendency term (EXTERNAL_FORCING_T).
o pkg/seaice:
  - complete merge of ITD code into seaice_growth.F
    from MITgcm_contrib/torge/itd/code/
    no verification so far, but Torge Martin tested
    "1-D test case and Beaufort set up;
    deliver okay results after 1 model year."
  - complete merge of SEAICE_SIZE.h into all relevant routines
  - move computation of eta at Z-points into calc_viscosities
    + introduce global field etaZ
    + add different methods for computing etaZ, for now the old
      method (simple averages of eta to Z-points) is hardwired
    + replace etaMeanZ by etaZ in seaice_lsr, seaice_calc_residual,
      seaice_preconditioner
  - simplify computations for SEAICE_ZETA_SMOOTHREG
  - seaice_preconditioner:
    + replace one remaining press by pressLoc (mistake)
    + adjust printing of residuals
  - improve I/O of diagnostics of JFNK in seaice_jfnk.F:
    + add (SEAICE.h) and rename some counters (initiliased in
      seaice_init_fixed.F)
    + add _BEGIN/END_MASTER (myThid)  around print statements
    + print total number of iterations and failures over SEAICE_monFreq
      interval to STDOUT
  - move control over output-messages by fgmres to seaice_jfnk to save
    some operations
  - move resetting initial guess for fgmres outside of seaice_fgmres_driver
    in order to make restarts with sol .ne. zero (fgmres with restarts)
    (seaice_jfnk.F, seaice_fgmres.F)
  - seaice_calc_l/rhs.F: replace maskW/S by maskInW/S; this fixes
    a serious convergence problem when open boundaries are involved
o pkg/ggl90: fix computation of control volumes for the case of
  ALLOW_GGL90_HORIZDIFF (probably not used very often): move control volumes
  up half a grid cell from C-centered to W-centered (pointed out by C. Eden)
o pkg/seaice: simplify seaice_evp by avoiding use of extra fields u/vIceC
o pkg/autodiff
  - Add inAdMode switch for SEAICEuseDYNAMICS:
    SEAICEuseDYNAMICSinAdMode
    (extend logic in ADAUTODIFF_INADMODE_SET)
o pkg/seaice
  - Step 1 of merging ice-thickness distribution (ITD) code from
    MITgcm_contrib/torge/itd/ (author: Torge Martin)
    The code implements concept laid out in Thorndike et al. (1975);
    code is enabled via CPP flag SEAICE_ITD
    nITD (in SEAICE_SIZE.h) defines number of ice thickness categories;
    code is not complete yet!!
  - SEAICE_SIZE.h now included in almost all seaice routines
o verification (using seaice):
  - switch back seaice-dynamics (+ lower SOLV_MAX_ITERS) in ADM exp.
    global_ocean.cs32x15.seaice ; update results.
  - compile B-grid dynamics in FW test exp 1D_ocean_ice_column ;
  - compile C-grid dynamics with #define SEAICE_ALLOW_JFNK in FW test exp
    offline_exf_seaice (previously compiling B-grid).
o pkg/exf:
  - fix some STOP conditions in exf_check.F (from Aug 28, modifs did not allow
    to specify neither just 1 comp of wind or wind-stress, nor no surface momentum
    forcing): just replace CPP option ALLOW_ATM_WIND with run-time param useAtmWind.
o pkg/layers (adjust changes from Sept 19):
  - do snap-shot output and fill diagnostics from inside iLa loop (layers_calc.F)
    this allows to remove "layers_maxNum" dimension from all layers arrays.
o pkg/layers (adjust changes from Sept 19):
  - remove ALLOW_LAYERS_OUTPUT ; fix snap-shot and time-ave output ;
  - snap-shot extended to all type of layers (not just the 1rst type);
  - remove layers variables when corresponding CPP option is undef.
o pkg/layers:
  - rename pkg/layers variable and add new output (layer exist & un-weighted
    velocity in layer)
o pkg/seaice:
  - simplify (?) ocean-drag coefficent computations by using
    the same routine in all three solvers (saves some code lines)
  - remove global fields DRAGA and DRAGS from C-grid code and
    declare them locally in lsr.F (the only place where they are
    still used)
  - update AD output of lab_sea.evp (very sensitive anyway).
o pkg/seaice: add Jacobian-free Newton Krylov solver for ice dynamics
  (Lemieux et al. 2010, 2012). Turn on with the usual SEAICE_ALLOW_JFNK
  and SEAICEuseJFNK=.true. A few things to note:
  - involves a FGMRES, that is parallel but very inefficient,
    because of many scalar products (global sums) in the Gram-Schmidt
    orthogonalization method. Needs to be replaced. Original code
    from J.-F. Lemieux
  - preconditioner for FGMRES is a stripped down version of LSOR
  - SOLV_MAX_ITERS is now used for LSOR as a solver and as a
    preconditioner. For the preconditioner, the default is set to 10.
  - Jacobian times vector is computed with finite differences
  - marginally related to JFNK-solver: add a smooth regularization for
    zeta with tanh that will improve convergence (Lemieux and Tremblay,
    2009) for any implicit solver (not implemented for EVP because EVP
    does not need this regularization in the first place). Define
    SEAICE_ZETA_SMOOTHREG in SEAICE_OPTIONS.h to use.
o eesupp/src:
  - check in genmake2 that intrinsic S/R flush is available.
  - add S/R to flush IO unit (if intrinsic S/R flush is available)
  - flush standard & error msg unit before MPI termination
  - if debugMode, flush IO unit after printing msg
o pkg/ctrl:
  - ctrl_unpack.F, ALLOW_GENARR3D_CONTROL code: fix missing argument in call
    to ctrl_set_unpack_xyz.

checkpoint64 (2012/10/09)
o pkg/shelfice
  - in mom_fluxform.F, mom_vecinv.F:
    CALL SHELFICE_V_DRAG(bi,bj,k,vFld,KE,KappaRU,vF,myThid)
    Bug fix KappaRU -> KappaRV
    does not change verification/isomip but may change other setups
    (presumably constant KappaRU=KappaRV)
  - fix diagnostics SHIU/Vdrag (thanks to Tom Millgate)
o pkg/obcs:
  - fixed some indexing bugs in obcs_seaice_sponge.F
  - added obcs relaxation subroutines for HSALT and HSNOW
  - changes verification/seaice_obcs/results/obcs_seaice_sponge.F
o pkg/seaice:
  - add "multicategory" parameterization for snow in analogy to ice,
    default is off for now.
o pkg/obcs:
  - added obcs_seaice_sponge.F for obcs relaxation of seaice variables;
    see verification/seaice_obcs/input.seaiceSponge for example application.
  - remove local commom bloc "OBCS_GLOBAL" in obcs_readparms.F and do all the OB
    index setting by master-thread. This fix multi-threads Pb in previous modifs.
o pkg/layers :
  - add diagnostics to pkg/layers
  - move the meat of pkg/layers from layers_calc.F to layers_fluxcalc.F
    (from R.Tulloch). Layers_calc.F now calls layers_fluxcalc.F accordingly.
o pkg/generic_advdiff/gad_implicit_r.F :
  - fix ADVr diagnostics in case of both implicit vertical advection and diffusion.
o pkg/seaice/seaice_growth.F:
  - fix SItflux diagnostics in virtual salt flux + balanceEmpmr case.
o pkg/obcs:
  - change default setting of OBCS_UVICE_OLD from defined to undef;
  - use new parameter OB_indexNone for null index value (instead of hard-coded 0)
    in all pkg/obcs code and in other pkgs; remove k loop in obcs_check_depths.F;
  - pass OB_indexNone as (new) argument to S/R CTRL_MASK_SET_[X,Y]Z;
  - change OB null index value (OB_indexNone) to -99 ; this fix the problem
    with Southern & Western OB at a tile edge (at least in a simple set-up).
o pkg/obcs:
  - change settings of OB index in case OB coincides with tile edge (shared by
    2 tiles), so that common OB location is registered by both tiles (instead of
    only 1). However, for Southern and Western OB, index value = 0 is not
    recognized as valid OB index (=default null value) and needs to be fixed.
  - modify accordingly OBCS_BALANCE_FLOW and OBCS_MONITOR (avoid double counting)
  - new parameter "OB_indexNone" for null index value (for now, still zero)
    to replace hard-coded null index value of zero.
o pkg/exch2:
  - improve W2_USE_E2_SAFEMODE (faster) and W2_E2_DEBUG_ON:
    always check buffer-size (but outside the loop); move checking for valid
    index from W2_USE_E2_SAFEMODE to W2_E2_DEBUG_ON; in W2_E2_DEBUG_ON,
    print each tile and point connection only if |W2_printMsg|>= 2 and 3.
o pkg/ctrl (pack & unpack):
  - in ctrl_pack.F & ctrl_unpack.F, use the same local file-name variable
    (locally defined) for different variables (+ remove the variable-specific
    file name in CTRL_GENARR.h). For now, only implemented for GENARR2/3D_CONTROL
    (to be extended to other local file names in ctrl.h).
o pkg/flt:
  - add a FLT_Iter0 option (similar to PTRACERS_Iter0).
o pkg/mdsio:
  - fix missing STOP in mdsio_readvec_loc.F (case ioUnit=0) when file is missing
o tools/genmake2:
  - add similar dependences for target EXE_AD & EXE_FTL as we have for EXECUTABLE
    (added by Alistair in version 1.51 for building without make depend);
  - remove Header files list (H_SRC_FILES) from the dependence of targets
     ad_input_code.f & ftl_input_code.f (not clear why it was added in the first
    place in version 1.23): this save going through staf when unrelated header
    file has been modified.
   Note: for an intermediate target (e.g., ad_input_code.f or adtaf) without
    "make depend" step, still need to do "make links" before "make adtaf".
o eesupp/src (+ few pkg src files) & genmake2:
  - finish to remove ALWAYS_USE_MPI in source code that TAF does not see;
  - no longer set ALWAYS_USE_MPI in Makefile (was done by genmake2).
  - improve genmake2 checking for ALLOW_${PKG} in CPP_OPTIONS.h files (distinguish
     upper/lower case ; account for space between "#" and undef/define)
o pkg/flt (with exch2):
  - cleaning: fix so that it compiles; move remaining MPI calls out of flt_exch2.F;
  - simplify threads synchronisation; fix (many issues) multi-threaded with MPI.

checkpoint63s (2012/09/05)
o pkg/ecco:
  - remove #ifdef ALLOW_SMOOTH_CORREL3D brackets.
  - add more relevant #ifdef ALLOW_SMOOTH ones.
  - sort out useAtmWind, useSMOOTH, ctrlSmoothCorrel2D.
o pkg/ctrl:
  - CTRL_OPTIONS.h : document CPPs related to smoothing; ALLOW_SMOOTH_CORREL2D/3D,
    ALLOW_CTRL_SMOOTH, ALLOW_SMOOTH_CTRL2D, ALLOW_SMOOTH_CTRL3D.
  - ctrl.h : document run time params doInitXX, doMainPack, doMainUnpack, doPackDiag,
    doSinglePrecTapelev (audodiff param!), ctrlSmoothCorrel2D (new) and
    ctrlSmoothCorrel3D (new).
    The added ctrlSmoothCorrel2D/3D replace the old ALLOW_SMOOTH_CORREL2D/3D CPP.
  - ctrl_readparms.F : initialise ctrlSmoothCorrel2D/3D and read from namelist.
  - ctrl_init.F ctrl_pack.F ctrl_unpack.F : switch off ustress/vstress
    controls when useAtmWind, and vice versa.
  - ctrl_map_ini_ecco.F : UVEL0, VVEL0, edtaux, edtauy cannot be smoothed as tracers.
  - ctrl_get_gen.F : replace #ifdef ALLOW_SMOOTH_CORREL2D with
      #ifdef ALLOW_SMOOTH, IF ctrlSmoothCorrel2D, IF useSMOOTH.
  - ctrl_map_ini_gen.F : replace #ifdef ALLOW_SMOOTH_CORREL3D with
      #ifdef ALLOW_SMOOTH, IF ctrlSmoothCorrel3D, IF useSMOOTH.
  - ctrl_set_pack_xy[z].F, ctrl_set_unpack_xy[z].F:
    replace ALLOW_SMOOTH_CORREL2D/3D brackets with ctrlSmoothCorrel2D/3D.
o pkg/smooth:
  - remove un-necessary includes.
  - remove ALLOW_SMOOTH*D and ALLOW_SMOOTH_CORREL*D brakets.
    Those CPP options were never defined, and not necessary.
o model/src:
  - fix CPP brackets in ini_mixing.F (GM_background_K belongs to gmredi).
  - standard treatment of useSMOOTH.
o pkg/autodiff:
  - add LOGICAL useGGL90inAdMode, useGGL90inFwdMode, useSALT_PLUMEinAdMode,
    useSALT_PLUMEInFwdMode allowing to switch off ggl90 and salt_plume adjoint.
o pkg/exch2:
  - add "if usingMPI" where it was missing (in exch2_rx?_cube*.template)
    + start to remove ALWAYS_USE_MPI in source code that TAF does not see.
  - make new S/R W2_MAP_PROCS out of w2_eeboot.F to setup exch2 CommonFlag
    and tiles to process mapping.
  - re-arrange 3 header files (W2_EXCH2_PARAMS.h, _BUFFER.h & _TOPOLOGY.h)
    moving /EXCH2_FILLVAL_RX/ & /W2_EXCH2_COMMFLAG/ to W2_EXCH2_TOPOLOGY.h;
    rename "exch2_tProc" to "W2_tileProc" and move seting of e2FillValue_RX
    from w2_eeboot.F to w2_readparms.F.
o eesupp/src:
  - set exchNeedsMemsync & exchUsesBarrier according to "usingMPI" (instead of
    ALWAYS_USE_MPI) + moved from ini_communication_patterns.F to eeset_parms.F;
    also move setting of exchCollectStatistics from exch_init.F to eeset_parms.F
  - in eedie.F and all_proc_die.F, always call MPI_FINALIZE when ALLOW_USE_MPI
    is defined (remove condition on usingMPI) to match cases where MPI_INIT
    has been called.
  - fix bug I put in previous modif of exch_sm_3d_rx.template (not much used);
  - change default (non-MPI) value of myPid (from 1 to 0) to match MPI settings
    (so that on 1 proc, get same myPid independently of usingMPI)
  - add a stop if multi-procs but usingMPI=F ; stop also if usingMPI=T and
    useCubedSphereExchange with EXCH-1 (safer).
  - add "if usingMPI" where it was missing (+ start to remove ALWAYS_USE_MPI).
o pkg/ggl90:
  - fix bug in filling corner mask array "mskCor" (FILL_CS_CORNER_TR_RL call)
    used in ALLOW_GGL90_SMOOTH code.
o pkg/flt:
  - fix typo in FLT_WITHOUT_Y_PERIODICITY (the effect was to ignore stopping
    floats at the Southern end of the domain).
o eesupp/inc:
  - add a list of CPP-options which can be set by Makefile (DEF_IN_MAKEFILE.h);
    but not used (and not to be used) anywhere, just for documentation.
o pkg/autodiff, exf, ptracers & seaice (AD & TL output):
  - comment out the very nasty "writeBinaryPrec = writeStatePrec" line, since:
    a) can damage previously written records in any other multi-record files.
    b) if needed, can easily do it cleanly, by calling S/R WRITE_REC_3D_RL/S.
o tools/genmake2:
  - define variable MAKE within Makefile and use it in place of 'make';
  - update AD_CONFIG.h (if needed) before building any of the executable
    (forward, adjoint or tangent-lin); this involves a 2nd invocation of make;
    and add the usual #ifndef/#define AD_CONFIG_H in AD_CONFIG.h;
  - always print usual warning comment 'this file is automatically generated'
    from script convert_cpp_cmd2defines (+ remove this warning from genmake2).
o pkg/cheapaml:
  - updated to correspond to the code used in accepted paper (Nico Wienders).
o pkg/exf:
    added run time switch useAtmWind to replace ALLOW_ATM_WIND cpp switch.
    ALLOW_ATM_WIND now just sets the useAtmWind default (see exf_readparms.F)
    and force defines ALLOW_BULKFORMULAE (EXF_OPTIONS.h).
o pkg/exf, autodiff, ctrl, ecco and seaice:
    remove ALLOW_ATM_WIND brackets, or replace them with useAtmWind ones.
o pkg/ctrl, ecco:
    allow to compile both ALLOW_U/VSTRESS_CONTROL and ALLOW_U/VWIND_CONTROL.
    Depending on useAtmWind, one is inactive, and the other is active (see
    exf_getffields.F/exf_getsurfacefluxes.F).
o tools/genmake2:
  - improve error msg when failing in 2nd test of check_for_broken_Ff
  - fix option '-makefile' short-name (-mf according to genmake2 -help)
  - source local config file "genmake_local" just after processing the genmake2
    command arguments (previously done before processing arg).
o pkg/grdchk:
  - add a call to TURNOFF_MODEL_IO for Tangent-Linear run (in this case, call
    to this routine from cost_final has been dropped in g_cost_final)
  - improve printed information (more explicit msg, no longer using "print *,"
     fix fcpertminus printed value).
o model/src:
  - move call to COST_INIT_VARIA out of packages_init_variables.F directly
    into initialise_varia.F (just after calling PACKAGES_INIT_VARIABLES):
    this prevents getting cost-funct reset in adinitialise_varia recomputations.
o pkg/dic:
  - move initialisation of "freefe" array from from dic_biotic_forcing.F to
    fe_chem.F: this prevents TAF from dropping this initialisation in TLM code.
o pkg/grdchk:
  - grdchk_main.F : added CALL GLOBAL_SUM_INT( ierr , myThid )
  - grdchk_getadxx.F etc. : omit I/O if ierr.EQ.0
o pkg/autodiff/ctrl/grdchk :
  - attempt to sort out what works and what does not,
    with regard to I/O, and to warn/stop accordingly.
o pkg/grdchk:
  - attempt to fix grdchk in the case of useSingleCpuIO.
  - "if ( myProcId .EQ. grdchkwhichproc .AND. ierr .EQ. 0 )"
   statements were moved from grdchk_main.F and into
   grdchk_getadxx.F grdchk_getxx.F grdchk_setxx.F.
  - a global sum is applied to record numbers icvrec/layer
   out of grdchk_loc so that they be passed to I/O routines.
o pkg/smooth:
  - fix recomputation that appeared with nlfs : use smooth_recip_hFacC,
    smooth_hFacW, smooth_hFacS (copied at init_fixed) in 3d case.
o verification/testreport:
  - add option '-tlm' for Tangent-Linear test (-adm,-oad,-tlm are all exclusive);
  - can also use compressed (gzip) reference output file;
  - change format (in pkg/grdchk) of TLM output (+ add forward gradient)
    to be easier to collect by testreport.
  - update existing TLM output (half out-of-date by more than 3 yrs).
  - report NETCDF & LAPACK settings (from genmake2) in output dir.
  - report run-time in each individual summary (previously only for AD test);
    for TLM test, add also TAF version.
  - add daily TLM test on (old) aces cluster + weekly test on baudelaire.

checkpoint63r (2012/08/15)
o tools/genmake2:
  - fix Makefile for target ftlall (+ update files to clean after make ftlall)
o pkg/ecco/ecco_cost_final.F :
  - fix fc print statements (to stdout and costfunction0000) so
    that the printed value is always after the global sum.
o pkg/seaice/seaice_dynsolver.F :
  - fix ice strength assymptote at SEAICE_area_max<1
    (no change for the standard case of SEAICE_area_max=1)
o some cleaning:
  - pkg source files: ensure that all *.F files from each pkg included the
    corresponding ${PKG}_OPTIONS.h file (except stand-alone src file which
    only includes CPP_EEOPTIONS.h); fix S/R CTRL_SMOOTH ; update AD experiment
    code_ad/*.F src files; add new option-file in pkg/admtlm + corresponding
    includes;
  - model/src: add PACKAGES_CONFIG.h wherever ALLOW_AUTODIFF[_TAMC] is used.
  - ALLOW_DIFFKR_CONTROL: add a stop in S/R CTRL_CHECK in case ALLOW_3D_DIFFKR
    is undef; also define /DYNVARS_DIFFKR/ common block in DYNVARS.h when
    ALLOW_DIFFKR_CONTROL is defined, to allow to compile and reach this stop.
  - update option-file CPP_OPTIONS.h of all AD experiments:
    * no longer include PACKAGES_CONFIG.h ;
    * includes ECCO_CPPOPTIONS.h if PACKAGES_CONFIG.h has been included ;
    * def/undef ALLOW_3D_DIFFKR independently of ALLOW_DIFFKR_CONTROL (before
      including ECCO_CPPOPTIONS.h).
o pkg/cost, pkg/ctrl, pkg/ecco option-file:
  - clean-up and split content of old pkg/ecco/ECCO_CPPOPTIONS.h file into
    separated pkg option-file (done according to old doc from ECCO_CPPOPTIONS.h,
    not necessary accurate).
  - add a template for option-file ECCO_CPPOPTIONS.h, mostly empty, in
    pkg/autodiff, i.e., the 1rst pkg to compile for adjoint built, with lines to
    deliberately break compilation (a remainder that it needs to be customized)
  - in pkg/ecco, includes ECCO_OPTIONS.h instead of COST_OPTIONS.h
  - rename COST_CPPOPTIONS.h to COST_OPTIONS.h
  - rename CTRL_CPPOPTIONS.h to CTRL_OPTIONS.h
o tools/genamke2:
  - check for lapack.
o pkg/cost and pkg/ecco : attempt to sort out some of the limiting intricacies.
  - pkg/cost.cost_final.F : allow for use of pkg/ecco and pkg/cost cost functions
    jointly. The exclusive ifdefs were removed, to add costs terms (when defined)
    from both packages.
  - the fc global sum in pkg/ecco/ecco_cost_final.F was removed accordingly.
  - for objf_atl we use either the pkg/ecco or the pkg/cost term depending on CPPs.
  - pkg/ecco and model/src : add CPP brackets around pkg/cost and pkg/ctrl includes
    of "CTRL_SIZE.h" "ctrl.h" "ctrl_dummy.h" "optim.h" / "cost.h" accordingly.
o pkg/cost : add comments to explain special and/or untested setups.
o pkg/exf:
  - use EXF_OPTIONS.h to set pkg/exf options except if done in ECCO_CPPOPTIONS.h
    (previously, ALLOW_AUTODIFF_TAMC was controling this switch).
o verification/*/code_ad:
  mimimal cleaning of AD experiments ECCO_CPPOPTIONS.h option-file:
  - reccord when this file is included (define ECCO_CPPOPTIONS_H)
  - remove the most obvious obsolete features (e.g., #define ALLOW_COST not
    allowed since Oct 2003 in any option-file except in PACKAGES_CONFIG.h)
o pkg/seaice :
  - added possibility to change ice strength/PRESS0 relationship to
    HEFF, according to the following run time parameters
    SEAICEpresPow0 :: HEFF exponent for ice strength below SEAICEpresH0 (integer, >0)
    SEAICEpresPow1 :: HEFF exponent for ice strength above SEAICEpresH0 (integer, >0)
    SEAICEpresH0   :: HEFF threshold for ice strength            (m)
o pkg/ggl90 :
  - added run time flag mxlSurfFlag to include the code that ensure
    mixing between first and second level (previously included as a comment)
o verification/1D_ocean_ice_column/input_ad/data.autodiff :
  - add test of newly added dumpAdByRec=T option where
    we write all records to one file per variable.
o verification/global_ocean.cs32x15/code_ad/CPP_OPTIONS.h :
  - switch to #define ALLOW_BALANCE_RELAX and ALLOW_BALANCE_FLUXES
    to check that this code is ok with taf and compiles in adjoint.
o pkg/autodiff :
  - added run time param dumpAdByRec : ad dump format switch.
    If true then write all records to one file per variable.
    Else write one file per record (remains the default).
  - revise seaice_ad_dump.F and exf_adjoint_snapshots_ad.F accordingly.
o pkg/seaice:
 - Added SEAICEuseTILT run time switch : if set to
   false then omit the tilt term in seaice dynamics.
 - Fix free drift calculation.
o pkg/shelfice:
  When initializing SHELFICEDragQuadratic, set default to be
  consistent with shiCdrag in case SHELFICEuseGammaFrict is used,
  but retain option to set it independently
  (inconsistenty spotted by Veronique Dansereau)
o eesupp/inc:
  - in EEPARAMS.h, add real-type constant for some frequently used simple number
     (0,1,2,1/2), with name explicitly referring to RS/RL type.
o model/src:
  - move balancing of relaxation terms to new S/R balance_relax.F.
o pkg/autodiff:
  re-write active I/O high-level (control) S/R:
  - rename  S/R ACTIVE_READ/WRITE_RL to ACTIVE_READ/WRITE_3D_RL
  - add 1 more argument (useCurrentDir) to replace the "_LOC" 2nd set of S/R.
  - use standard pkg/mdsio I/O routines (MDS_READ/WRITE_SEC_XZ/YZ  and
    MDS_READ/WRITE_FIELD); change loops to multi-threads.
  - update and merge active_file_control_slice.flow into active_file_control.flow
  - update the calls in lower level S/R (active_file.F, active_file_g.F and
    active_file_ad.F) keeping the argument list and function unchanged.
  - also update lower-level "_LOC" version (call same S/R with "useCurrentDir
    =.TRUE.") and remove high-level (control) _loc version (not called anymore).
  - new low-level active I/O routines, one for each type (RL/RS), for active var
    of various (XY,XZ,YZ) shape and level number (arguments: arrShape, myNr);
    fix ctrl_init_wet.F & ecco_cost_weights.F by calling the new S/R with the
    right type.
o autodiff and RS=real*4:
  - call the right type (_RS instead of _RL) of S/R in few output S/R (pkg/exf
    ad-monitor and snapshots); disable arrType='RS' in mdsio_gl*.F ;
  - change argument type of 3-D mask argument to _RS to match type in the call
    (in seaice_cost*.F, ctrl_*_gen.F and *ctrl_bound.F); to be continued.
o pkg/thsice:
  - re-anable balanceEmPmR when useSEAICE=T with useThSIce=T.
  - option to correct ocean fresh-water flux for imbalance of Atmos+Land
    fresh-water flux: uniform correction or proportional to local precip.
o pkg/ctrl:
  - new header file CTRL_SIZE.h for parameters maxCtrlArr2D, maxCtrlArr3D
  - redefine CPP option ALLOW_BOTTOMDRAG_CONTROL to
                        ALLOW_BOTTOMDRAG_CONTROL_NONGENERIC
  - verification/hs94.1x64x5/ tests ALLOW_GENARR{2D,3D}_CONTROL

checkpoint63q (2012/07/30)
o pkg/autodiff:
  note about monitor and snap-shot of ad-variables:
  a) need to apply ADEXCH before monitor or output of ad-vars to include
   overlap contributions (was done for adjDump but missing for monitor).
  b) since ADEXCH implies adding overlap values to interior array, machine
   truncation error is expected when adding an ADEXCH call in the middle of
   the time-stepping (although mathematically identical).
  modifs:
  - fix some incorrect type (RL/RS, UV/scalar) in ADEXCH calls and ad-vars
    declaration (adEddyPsiX,adEddyPsiY in adcommon.h).
  - add new run-time params (dumpAdVarExch & mon_AdVarExch) to select how  to
    apply ADEXCH before monitor or snap-shot of ad-variables:
       =0 : no ADEXCH ; =1 : do ADEXCH ; =2 : apply ADEXCH on a local copy.
  - implement new method (copy+adexch) for snap-shot and monitor of main model
    ad-vars (initially not used by default -> output unchanged).
  - change default (set to 2) to use new method and update few output_adm.txt
    with accurate ad-monitor (global_ocean.90x40x15, tutorial_global_oce_biogeo
    and both tutorial_tracer_adjsens tests).
  - switch 2 global_ocean.cs32x15 AD-tests to AB-2 (seaice_dynmix & thsice)
    and turn off momDissip_In_AB in the 2 other (needed for stable AB-3).
o pkg/ctrl:
  enable the use of a variable number (maxCtrlArr2D, maxCtrlArr3D) of
  generic control variables via
  #define ALLOW_GENARR2D_CONTROL and/or #define ALLOW_GENARR3D_CONTROL
  Only required customization should be S/R ctrl_map_ini_genarr.F
  (routine in repository contains example)
o pkg/exf:
  - fix and refine checking of surface-relaxation setting when using EXF
o verification (adjoint exp):
  - reduce length of simulation by half for experiment global_ocean.cs32x15
    (std, seaice & seaice_dynmix) and exp tutorial_dic_adjoffline; update output.
o pkg/mom_common (mom_u/v_bottomdrag), pkg/shelfice (shelfice_u/v_drag)
  - replace if statements KE.ne.0 with KE.gt.0 to avoid sqrt of negative numbers
    of KE that can occur with aggressive optimization
  + put quadratic bottom drag calculation in separated loops (only done if
    using bottomDragQuadratic)
o model/src: CG2D_NSA
  - clean-up:  stop if cg2dNormaliseRHS=T and AUTODIFF
     and replace GLOBAL_SUM calls with GLOBAL_SUM_TILE.
  - in test-exp that uses CG2D_NSA (bottom_ctrl & tutorial_tracer_adjsens),
     change cg2d residual target to be expressed in Wunits (=> do not normalise
     RHS ; this fix global_max Pb with TAF); update output.
o verification/tutorial_tracer_adjsens:
   improve parameter consistency (and get rid of warnings):
   - use deltaTFreeSurf=deltaTtracer (better with NonLin FreeSurf);
   - switch Temp Adv Scheme from 81 to 80 (no limiter since theta < 0 is physical)
   - use staggerTimeStep (for stability) in som81; use default rotation period.
o pkg/exch2:
  - with empty facet: fix compact-format (W2_mapIO=1) definition (was previously
    reset to 0 = 1 long line in X)
o pkg/mdsio:
  - fix reading of dimensions from meta file for large-size domain
o model/src:
  - fix saltIsActiveTr setting for IdealGas eosType (eosType is 6 character long);
  - to refine CS-grid check, add logical flag "hasWetCSCorners": true if using
    Cubed-Sphere Exch with CS-corners inside the domain;
    make new S/R INI_GLOBAL_DOMAIN from code in ini_linear_phisurf.F to calculate
    globalArea and to set hasWetCSCorners.
  - add warning if usingCurvilinearGrid and momAdvection in flux-form (missing
    metric terms); stop if hasWetCSCorners=T and momAdvection in flux-form.
  - re-activate the stop if useCDscheme and hasWetCSCorners=T (previously if
    useCDscheme and useCubedSphereExchange).
o pkg/seaice/seaice_growth.F :
  - compute the SEAICE_DISABLE_HEATCONSFIX term accordingly
    for the (.NOT.useRealFreshWaterFlux).OR.(nonlinFreeSurf.EQ.0)
    when the previous code was not correct.
  - in all cases diagnoze the boundary condition mismatch to SIaaflux
  - in the case of useRealFreshWaterFlux.AND.(nonlinFreeSurf.GT.0) add
    that term to QNET (essentially to set the melt/freeze water to 0degC).
    when SEAICEheatConsFix is true, so that the ocean+ice budget heat is closed.
o verification/global_ocean.cs32x15/input.seaice :
  - add SEAICEheatConsFix in data.seaice, ensuring closed ocean+ice heat budget.
  - add diagnostics (commented out) for budget test using my matlab codes (gcmfaces).
  - update results (output.seaice.txt) accordingly.
o verification/lab_sea/input/data.seaice :
  - remove SEAICEheatConsFix, which is now be tested
    in global_ocean.cs32x15. The presently coded fix
    is only consistent with real fresh water + nlfs.
  - update results (output.txt) accordingly.
o pkg/salt_plume: added diagnotic for salt tendency (oceSPtnd).
o AD_CONFIG.h file:
  - in genmake2: remove "#undef ALLOW_ECCO_OPTIMIZATION" from AD_CONFIG.h;
  - remove #include "AD_CONFIG.h" from all included OPTIONS files and
    add it explicitly in each fortran src file where it is needed.
    motivation: header file AD_CONFIG.h is generated/modified after "make depend"
    thus introducing potentially wrong dependency; therefore, better to include
    it only where it's really needed, and after any other included OPTIONS file
    (less tempting to bring conditional includes according to ALLOW_ADJOINT_RUN
    or ALLOW_TANGENTLINEAR_RUN).

checkpoint63p (2012/07/06)
o pkg/autodiff:
  - rename S/R INI_AUTODIFF to AUTODIFF_INIT_VARIA ;
  - create new header file "AUTODIFF_PARAMS.h" for pkg/autodiff parameters
    which are now read from new parameter file "data.autodiff" (inAdExact
    previously in "data", use{KPP/GMRedi/SEAICE}inAdMode previously in data.pkg)
  - add file "data.autodiff" in all verification/*/input_ad/ directories.
  - add run-time parameter to turn On/Off SEAICEuseFREEDRIFT in adjoint/forward
    mode (used in global_ocean.cs32x15.seaice_dynmix test exp.)
o verification/tutorial_tracer_adjsens/
  - add extra sub-verification which uses "SOM" advection scheme
    (2nd Order-Moment Advection Scheme, Prather Limiter) with
      #define GAD_ALLOW_TS_SOM_ADV in GAD_OPTIONS.h
    and in data:
      multiDimAdvection=.TRUE.,
      tempAdvScheme=81,
      saltAdvScheme=81,
o model/src:
  - introduce ALLOW_BALANCE_RELAX which allow the removal
   of the global mean of relaxation terms by setting
   balanceThetaClimRelax and balanceSaltClimRelax
  - disable balanceEmPmR and balanceQnet in the case when useSeaice.
   This case is now treated appropriately in seaice_growth.F
o pkg/seaice:
  - do balanceEmPmR and balanceQnet based on the net fluxes
    (SItflux) that enter the ocean+ice system rather than QNET
    and EMPMR. Works best in real fresh water.
  - SIatmFW, SIatmQnet, and SItflux computations had to be moved
    out of the diagnotics bloc, and stored in global arrays.

checkpoint63o (2012/06/29)
o vertical mixing schemes:
  - remove unused S/R CALC_BUOYANCY (left from branch-atmos merging)
  - replace computation of density (in Function STATE1, opps_calc.F) by a call
    to S/R FIND_RHO_SCALAR
  - pass sigmaR to S/R PP81_CALC, MY82_CALC (but not yet used) and to GGL90_CALC
    and use it for N^2 calculation in ggl90_calc.F (save 2 density computations);
    affects output (vermix.ggl90) at truncation level.
o testreport:
  - change adjustment of SIZE.h for mpi+mth testing: preserve enough tiles
    (nSx,nSy) for the number of threads (from eedata.mth)
o model/src:
  - remove 2nd set of calls at the top of initialise_varia.F (Adjoint part)
    related to Non_Lin Free-Surf or Bottom-Control (but not longer necessary).
o verification/tutorial_tracer_adjsens/
  - compile with ALLOW_CG2D_NSA
  - run with nonlinFreeSurf=3
  - update reference output_adm.txt
o tools/genmake2:
  - add "-DHAVE_NETCDF" to the DEFINES list when NetCDF is available ;
    refine usePROFILES switching off (only when NetCDF is not available).
o verification (atmospheric set-up):
  - change eosType='IDEALGAS' to eosType='IDEALG' to match variable declaration
o pkg/profiles : refine profiles and files handling.
o model/src and pkg/ecco : introduce run-time switch usePROFILES.
o model/src/the_main_loop.F, forward_step.F and pkg/exf/EXF_OPTIONS.h :
  - changes to use model/src/the_main_loop.F rather than the ecco version
    in ecco type adjoint runs.
o model/src:
  - move computation of recip of grid distance & area from INI_MASKS_ETC to INI_GRID
  - move setting of h0Fac[C,W,S] from INI_LINEAR_PHISURF to INI_MASKS_ETC
  - update_masks_etc.F: rename SMOOTH*_R4,R8 function to the corresponding type (RS,RL)
o model/src:
  - fix S/R UPDATE_CG2D for ALLOW_DEPTH_CONTROL case (was empty before);
    update output of test experiment bottom_ctrl_5x5.
o pkg/generic_advdiff:
  - implement vertical bi-harmonic diffusion (for now, only for T & S and
    only explicitly).
o verification/bottom_ctrl_5x5/
  update reference output (results changed quite some time ago,
  not sure when; but new reference results look ok in terms of grdchk)
o verification/1D_ocean_ice_column/
  For verification purposes, the exact adjoint rather than an approx.
  should be used (e.g., to comare against F.D. or TLM).
  removed autodiff_inadmode*_ad.F routines in code_ad/
  Update results/ accordingly.
o pkg/cal:
  - change cal_getdate.F so that output date is function of input time only
    (less ambiguous, not mixed up with input iteration number).
  - fix calendarDumps for non-zero phase-lag (S/R CAL_TIME2DUMP).
o pkg/diagnostics:
  - implement calendarDumps also for stats-diags
  - implement calendarDumps also for snap-shot output (negative freq)
  - for now, ignores calendarDumps if non-zero phase-lag.

checkpoint63n (2012/06/04)
o model/src:
  - recompute rSurfW & S to ensure consistent column thickness (needed for rStar)
    between Sum_k(hFac*drF) and rSurf-rLow, for now only when using pkg/shelfice;
  - use h0FacC, W & S to compute hFac_surfC, W & S in calc_surf_dr.F (more
    similar to calc_r_star.F); update results of experiment internal_wave and
    tutorial_global_oce_in_p (affected @ truncation level).
o pkg/shelfice:
  - add parameterisation of advective-diffusive flux into the ice shelf
    according to Holland and Jenkins (1999), eq.22-33, as suggested by Jan De Ryd
  - simply eps3/3a computation
o eesupp:
 - add new CPP option (DISCONNECTED_TILES) to disconnect tiles (no exchange
   between tiles, just fill-in edges assuming locally periodic subdomain) and
   add corresponding exchange subroutines (EXCH0);
 - new CG-solver version (_EX0) for disconnected-tiles special case.
o model/src (CG-solvers):
 - modify Single-Reduction version (CG2D_SR) in case cg2dMaxIters is reached
   (similar final residual output and max-Iter number as with standard version);
 - allows to store and use lowest-residual solution (standard & _SR versions);
 - cleaning up (remove old, commented out code, LETS_MAKE_JAM ...).
 - by default, also compile CG2D_SR version (define ALLOW_SRCG in CPP_OPTIONS.h)
o eesup/src:
 - global_vec_sum.F cleaning: add a BARRIER ; update comments ; remove ndef
   ALWAYS_USE_MPI (no longer needed after fixing usingMPI settings - March 2012)
o pkg/salt_plume added to lab_sea/input_ad.noseaicedyn

checkpoint63m (2012/04/27)
o pkg/shelfice:
 - account for partical cells in surface level below ice-shelf for hydrostatic
   pressure calculion (set uniformFreeSurfLev to F); update isomip experiments.
o ad test experiments:
 - update and rename to "ad_optfile.local" local AD-optfile specific to a
   particular adjoint verification experiment (in verification/*/code_ad/)
o pkg/seaice & pkg/exf:
 - Part two of ECCO-CLIVAR code merges.
   Completes merge of seaice area relax. code.
   Requires unified CPP option EXF_ALLOW_SEAICE_RELAX
   to be set in EXF_OPTIONS.h since this pkg controls its I/O
   (and avoids second CPP option in SEAICE_OPTIONS.h)
 - change default value of costIceStart & costIceEnd to a valid date.
 - add snowPrecip to HSNOW in seaice_growth
o pkg/ptracers:
 - move ptracers summary and setup check into separated S/R ; add a check for
   valid PTRACERS_Iter0 value (error+stop or just warning).
o pkg/cal (+ pkg/ecco):
 - avoid calling a S/R with 2 times the same arg (FWD: unless both are only used
   as input; and for AD, unless both are not differentiable (e.g., k index)).
o model/src:
 - define internal flag "uniformFreeSurfLev" (=T when free-surface level-index
   is everywhere k=1) to speed-up some calculations (by pass kSurf reference);
   temporary set to usingZCoords value (to be changed to F when using shelfice).
 - hydrostatic pressure: implement partial cell near the surface also for
   Z-coordinates (for the case where uniformFreeSurfLev=F); replace test on
   usingZCoords with test on uniformFreeSurfLev where needed (in NonHyd code).
o pkg/ctrl/ctrl_init.F:
 - add a formal parameter to s/r ctrl_init_rec to print
   xx_$(ctrl_valiable)_file for easier debugging
 - move call of cal_* routines into the if-block where they are really
   needed so that xx_$(ctrl_variable)_period can be 0 or -12 without having
   to specify a startdate
o pkg/seaice:
 - update comments in SEAICE_OPTIONS.h (+ similar update of lab_sea/code and
   global_ocean.cs32x15/code versions).
 - turn on seaice Multi-category (in data.seaice, SEAICE_multDim=7) for
   verification experiment global_ocean.cs32x15.seaice and update results.
o pkg/exf:
 - new S/R EXF_GETFIELD_START to return starting-time of a forcing field
   (according to useExfYearlyFields).
o pkg/cal:
 - move calendar setting & summary (previously in cal_readparams.F) into new
   S/R CAL_INIT_FIXED to be called later in the initialisation process, once
   length of the simulation is set (after SET_PARMS call); This is an attempt
   to fix Pb when, e.g.: pkg/longstep, modifies the length of the run.
 - For safety: keep a record of pkg/cal parameter settings status
           to allow to STOP if one pkg/cal S/R is called too early.
 - add a stop in all basic pkg/cal subroutines if called before setting is done.
 - modify cal_getdate.F: stop when nothing was returned;
   if called with myIter=-1, simply retrun modelBaseDate (1,2 = startDate_1,_2);
   this allows to remove "cal.h" from seaice_read_parms.F & init_mnc_vars.F.

checkpoint63l (2012/04/04)
o pkg/bbl:
  - fix call to FIND_RHO_2D in bbl_calc_rho.F (case multi-tiles per proc);
    update global_with_exf output.yearly.txt file.
o pkg/cal:
  - start to clean-up cal_set.F ; fix for the case where baseTime is non-zero.
  - remove 2 unsused and very short (1 line only) functions ;
  - remove unsused subroutines from AD-Diff list.
o model/src:
  - start to implement clean wait to stop in initialization S/R (config_check.F,
     packages_check.F, ini_parms.F and pkg/obcs/obcs_check.F + pkg/mypackage)
o folowing PRINT_MESSAGE changes:
  - remove reminder multiple print to the same file (STDOUT) when multi-threads.
o pkg/bbl:
  - modification so it can work with z*
  - replace deltaT with dTtracerLev(k) for asynchronous time stepping
  - global_with_exf/input.yearly verification; changes output.yearly.txt
o eesupp/src:
  - PRINT_MESSAGE: use OpenMP critical instruction (similar to PRINT_ERROR);
    writing to unit 0 (if unit=errorMessageUnit) extended to the case myThid=1
  - CHECK_THREADS: specific code if using OpenMP threading: improve checking of
    # of threads across processors (e.g., different env OMP_NUM_THREADS setting)
  - improve special preliminary call to EESET_PARMS (if eedata is read 2 times).
  - when using MPI, always set usingMPI=T ; set default accordingly and stop
    if not consistent.
  - ALL_PROC_DIE: add a BARRIER after MPI_FINALIZE call ; skip this when thread
    argument is zero (in case called within single-thread section).
o pkg/fizhi:
    clean-up turbulence cold-start switch: decided in fizhi_init_vars.F, stored
    in common bloc (fizhi_coms.h) and then passed as argument up to S/R TURBIO.
o pkg/exch2:
  - add argument "updateCorners" to S/R exch2_get_uv_bounds (enable to
    activate EXCH_IGNORE_CORNERS in vector EXCH S/R).
  - switch 1rst EXCH call to IGNORE_CORNERS (instead of UPDATE_CORNERS)
    but keep the 2nd with UPDATE_CORNERS: this prevents overwriting good data
    with bad ones coming from a not-yet-updated halo.
    This should fix the problem when sNx <> sNy and GCD(sNx,sNy) < 2*Olx.
o pkg/frazil:
    move FrzForcT diag from frazil_diagnostics_state.F to frazil_calc_rhs.F
    http://mitgcm.org/pipermail/mitgcm-devel/2012-March/005384.html
o model/src/config_check.F: add a check for OLx>sNx/OLy>sNy
o verification/lab_sea
  * #undef SEAICE_EXCLUDE_FOR_EXACT_AD_TESTING
  * #define ALLOW_SST_CONTROL & ALLOW_SST_CONTROL
  * nTimeSteps 3 -> 4
  * changed reference output accordingly
o pkg/ctrl:
  * fix ctrl_get_gen for xx_sst, xx_sss
o pkg/fizhi:
  - fix 2 calls to S/R GRD2MSC (argument igrd) in update_earth_exports.F
    update results of exp. fizhi-cs-32x32x40 (fail with only 6 digits for cg2d)
  - by default, use new version of S/R GETPWHERE (#define TRY_NEW_GETPWHERE);
    fix few out-of-bounds indices in referencing vars (initialise igrd to 1);
    clean-up fizhi_turb.F (remove unused & uninitialised qdiaglsm array).
o pkg/gmredi:
  - add diagnostic of Redi (main diagnonal) vertical diffusive flux of Temp
o pkg/fizhi:
  - fix few initialisation and multi-tile Pb: aqualev & gridalt now pass the
    (old)aces open64 tuv test.
o pkg/icefront: fix bug and reorder loop in icefront_init_varia.F
o pkg/mom_vecinv:
  - fix 1 loop range in mom_vecinv.F to be like all the other loops which
    set/update gu,gv/Diss (fix Pb of uninitialised fVerUkp in admom_vecinv
    with non-lin free-surf).
o model/src: move k-loop outside of i/j-loops when (re-)computing R_low
  in ini/update_masks_etc.F in order to avoid -O3 optimization problems with
  some compilers (gfortran 4.6.0 on MacOS)
o momentum:
  - separate fVer?(:,:,kUp) & fVer?(:,:,kDown) in argument list of MOM_FLUXFORM
    & MOM_VECINV subroutines (to help TAF). This fixes Pb of uninitialised
    fVer?(kUp) in admom_fluxform with non-lin free-surf or bottom control.

checkpoint63k (2012/03/17)
o model/src:
   - selectAddFluid (ALLOW_ADDFLUID): add missing term in horizontal momentum
     flux-form (mom_fluxform.F) and vertical momentum (calc_gw.F) equations.
   - SOLVE_DIAGONAL: switch default to use adjoinable & vectorized version
     (#undef SOLVE_DIAGONAL_LOWMEMORY); update output of exp. front_relax.bvp.
o model/src: solve_*diagonal.F
   - replace division with multiplication by inverse (similar to original version)
     update output of AD exp. global_ocean.90x40x15.
   - fix pkg/gmredi/gmredi_calc_psi_bvp.F & pkg/ggl90/ggl90_calc.F
     to enable the use of the vectorized & differentiable solve_tridiagonal.F
   - test exp. global_ocean.90x40x15/input_ad: switch to advection scheme 20 for
     vertical advection (to get solve_tridiagonal tested in AD mode).
o pkg/seaice: ECCO-CLIVAR merge:
  1. seaice AREA relaxation
     * CPP option: SEAICE_ALLOW_AREA_RELAXATION
     * runtime flag: SEAICE_tauAreaObsRelax
  2. modified global mean cost imbalance code: CPP option
      ALLOW_SSH_GLOBMEAN_COST_CONTRIBUTION
o another iteration on solve_*diagonal.F
   Make choices independent of AUTODIFF
   Default will be the adjoinable vectorized version.
   Alternative choices are:
   * non-adjoinable original version with low memory footprint:
     #define SOLVE_DIAGONAL_LOWMEMORY
   * still adjoinable but does not vectorize (k as inner-most loop):
     #define SOLVE_DIAGONAL_KINNER (keeping SOLVE_DIAGONAL_LOWMEMORY undef)
o testreport
 - add option to use a home made wrapper around "make"
 - remove MITGCM_IEEE env. variable (no longer active)
o pkg/shelfice
 - improve computation of friction velocity for velocity dependent
   exchange coefficients: include velocities into SHELFICEBoundaryLayer
   block to average velocities vertically
 - add TAF store directives for SHI_ALLOW_GAMMAFRICT
o Modify diagonal solvers, now three versions (upon request):
  #ifndef SOLVE_DIAGONAL_AUTODIFF
    1. default version (dating back a while ago)
  #else /* def SOLVE_DIAGONAL_AUTODIFF */
  # ifdef SOLVE_DIAGONAL_KINNER
    2. adjoinable version with k-innermost loop (G. Forget)
  # else
    3. adjoinable vectorized version of 2.
  # endif
  #endif /* SOLVE_DIAGONAL_AUTODIFF */
  All flags are currently set within routines, but could/should be moved to CPP-options.
  Array bounds for 1. are as before, for 2.,3. cover the entire domain
  (could be changed for 1. too).
o verification/lab_sea (fwd):
  - update the 4 fwd lab_sea test experiment: no longer SEAICE_GROWTH_LEGACY,
    use 7 categories (except hb87), new solve4temp params (except salt_plume),
    constant salinity (=4) or variable salinity (salt_plume) done through
    SItracer.
o pkg/seaice:
  - rename parameters: SIsalFrac to SEAICE_saltFrac & SIsal0 to SEAICE_salt0;
  - remove old parameters ( SEAICE_freeze, SEAICEturbFluxFormula, SEAICE_gamma_t,
     SEAICE_gamma_t_frz, SEAICE_availHeatTaper & SEAICE_availHeatFracFrz)
    from SEAICE_PARMS.h ; still need to fix seaice_cost_sst.F (broken when
    SEAICE_freeze got retired) but already better than previously with
    SEAICE_freeze=123456.7 deg.C;
  - move setting of facOpenGrow/Melt from SEAICE_INIT_FIXED to SEAICE_READPARMS
    (safer multi-threaded setting); always set SEAICEuseEVP;
  - setting of ocean-ice turb. flux coeff: moved from SEAICE_CHECK to
    SEAICE_READPARMS & SEAICE_INIT_FIXED (this fixes wrong summary report);
    stop if multiple specifications for the same coeff; make sure default
    SEAICE_mcPheePiston is compatible with drF(1) & deltaT.
o pkg/obcs:
  - allow to switch to upwind 1rst order advection scheme for the advective
    flux computation at the open-boundary; disabled for adjoint built.
o pkg/ptracers:
  - rename PTRACERS_RESTART.h -> PTRACERS_START.h
  - rename ptracers_fields_blocking_exchanges.F -> ptracers_fields_blocking_exch.F
  - add parameter to decide when to start a tracer; use internal flag to
    know which tracer to step-forward; switch this internal flag at the top
    of forward_step.F (new S/R PTRACERS_SWITCH_ONOFF); for now, not enabled
    for adjoint built.
o pkg/seaice:
  - add SEAICE_SIZE.h anywhere in the code where SEAICE.h is included ;
  - move MULTDIM declaration and setting from SEAICE.h to SEAICE_SIZE.h ;
  - keep experiment offline_exf_seaice truly single category (set MULTDIM=1).
o pkg/ecco:
  - fix writing of output file DiagnosCost_ClimSalt/Theta
    and DiagnosCost_DriftSalt/Theta (if multi-tiles per proc).
o pkg/seaice:
  - add missing initialisation of COR_ICE array in dynsolver.F
  - merging SEAICE_MULTICATEGORY define and undef cases. Now the same code is
    compiled either way, and is tested in all exps (multidim was only tested
    in lab_sea ad before).
  - cosmetic change to prepare for future addition of ITD. no change to results.
    no defaults change.
  - added run time param SEAICE_multDim (7 for SEAICE_MULTICATEGORY, 1 otherwise).
  - by lack of adequate verification experiments, I further used custom versions
    of global_ocean.cs32x15 to test multicat or not, with pickup or not. All
    should be correct.
  - avoid recomputations in ad.
o array initialisation in adjoint mode:
  1) pkg/mom_common/mom_calc_ke.F:
    add full array initialisation of KE inside mom_calc_ke.F (ALLOW_AUTODIFF_TAMC):
    The S/R which calls MOM_CALC_KE initialises KE but in some recomputation
    part this initialisation is gone, resulting in Floating Point Exception
    (caught by open64 compiler with debug option).
  2) model/src/convective_weights.F
    set output convectCount over the full array range (instead of doing
    an update): this fix a similar issue when called within recomputation (adjoint)
    which could by-pass the initialisation (normally done in the caller S/R).
o pkg/seaice:
  - final version of turbulent flux params, as agreed at MIT ice meet:
       SEAICE_mcPheePiston (default is ~ 0.000875)
       SEAICE_mcPheeTaper (default is 0.)
       SEAICE_frazilFrac (defualt is 1.)
       SEAICE_mcPheeStepFunc (default is false)
  - changes results at trunction error level
  - ifdef SEAICE_EXTERNAL_FLUXES, disallow SEAICE_waterAlbedo
o added pkg/frazil:
  - see frazil_description.tex for details
  - verification experiment is global_with_exf/input.yearly; changes output.yearly.txt
o pkg/shelfice/shelfice_thermodynamics.F
  - fix exponents for velocity dependent exchange coefficients: change
    from 2/3(=0) to 0.66666666666666667
  - move computation of velocity dependent exchange coefficients into
    separate loop, so that it applies to both thermodynamics
  - move some divisions by constants out of loops

checkpoint63j (2012/02/16)
o pkg/seaice:
  - overhaul of seaice_summary.F after feb 2012 clean-up of seaice_growth.F etc.
  - SItracer:  added run time params, and allow coupling to ocn salinity.
o pkg/seaice: remove (almost) all divisions by constants within loops
  in seaice_growth.F and seaice_solve4temp.F, this changes (only) the cg2d
  results of global_ocean.cs32x15.seaice from 16 to 11 digits (but only
  those, caused by 1/QI -> recip_QI) -> update output.seaice.txt,
  output_adm.seaice_dynmix.txt and also lab_sea: output_adm.evp.txt
o pkg/seaice :
  - simplify McPhee tapering, and allow to use it with SEAICEturbFluxFormula
    = 1 or 2, using newly added run time parameter SEAICE_availHeatTaper.
  - fix d_AREAbyATM, d_AREAbyOCN, d_AREAbyICE diags I broke in r1.148.
  - add permanent SItflux diag that corresponds to TFLUX but includes
    ice+snow. Hence SItflux-TFLUX should match the ice+snow heat budget.
  - allow activation/testing of a fix for suspected missing term in
    ocn-ice heat budget (to be confirmed). To test this, you want to
    undef SEAICE_DISABLE_HEATCONSFIX, and then set the run time param
    SEAICEheatConsFix to .TRUE. that also allows the 'SIaaflux' diagnostic.
  - no change in results, fwd or ad.
o global_ocean.cs32x15/results: 3 changes following from the pkg/seaice commit below:
  - switch to variable freezing point.
       Results change : cg2d -> 1 digits; ad -> 3-6-6 digits.
  - bug fix : the sublimation term that was missing is now activated.
       Results change : cg2d -> 2 digits; ad -> 8-6-6 digits.
  - bug fix : flooding sign term for SIsal0.NE.0.
       Result change : cg2d -> 8 digits; ad -> 11-12-9 digits.
o pkg/seaice:
  - unified freezing point treatment : the old SEAICE_VARIABLE_FREEZING_POINT
    is now the default, and the old default constant freezing point is recovered
    with SEAICE_tempFrz0    = -1.96,
         SEAICE_dTempFrz_dS = 0.,
  - retire SEAICE_freeze (= the old way of specifycing the constant freezing point)
  - remove ALLOW_SEAICE_FLOODING brackets; run time switch is already there.
  - bug fix (thanks to M. Losch) : the sublimation term that was missing is now
    activated. To reproduce old results with this bug define SEAICE_DISABLE_SUBLIM.
  - bug fix (silly me) : flooding sign term (seaice_growth.F r 1.149line 1211)
    was wrong for SIsal0.NE.0. Changes cs32x15 results (see above item for detail).
  - bug fix (thanks to O. Jahn) : area loss for melting  got messed up in
    seaice_growth r149 for legacy branch (no results change).
  - introduce SEAICE_CAP_SUBLIM : caps sublimation heat flux in solve4temp (code
    from I. Fenty).
  - results did not change except for global_ocean.cs32x15, mostly due to the
    switch to variable freezing point (see above item for detail).
o pkg/thsice:
  - fix and simplify interface to salt_plume pkg ; diagnose directly amount of
    seawater freezing in thsice_calc_thickn (not used).
o pkg/seaice: turbulent flux term specification via run time params.
  - replace CPP switches with run time switches to facilitate testing
  - retired CPPs : MCPHEE_OCEAN_ICE_HEAT_FLUX,
                   GRADIENT_MIXED_LAYER_TURBULENCE_FACTOR
  - added runtime parameter : SEAICEturbFluxFormula
  - move Mcphee constants to SEAICE_PARAMS.h
  - seaice_readparms.F : read turbulent flux term params (SEAICEturbFluxFormula;
             SEAICE_availHeatFrac/Frz, or SEAICE_gamma_t/_frz if apply);
             remove seaice_summary call (moved to seaice_init_fixed)
  - seaice_init_fixed.F : set SEAICE_availHeatFrac/Frz depending on
    SEAICEturbFluxFormula, and seaice_summary call (moved from seaice_readparms)
  - seaice_summary.F : add missing report of read turbulent flux term set up
                       and SITRACER.
  - seaice_check.F : check range; inform and stop if retired CPPs are used
                     (incl. SEAICE_AGE).
  - seaice_growth.F : unified use of SEAICE_availHeatFrac/Frz, without
         CPP switch, same computation as before for the different options.
  - change results at the truncation level.
o pkg/seaice:
  - remove un-used parameters LAD & MAX_TICE ; add new run-time parameters:
    useMaykutSatVapPoly (default=F), postSolvTempIter (default=2) and
    SEAICE_wetAlbTemp (default=-1e-3). Remove option SEAICE_SOLVE4TEMP_LEGACY.
  - update verification/*/input*/data.seaice:
    to reproduce previous results with former #defined SEAICE_SOLVE4TEMP_LEGACY
    code, set useMaykutSatVapPoly=T & postSolvTempIter=0 ;
    and to reproduce previous results with former non-SOLVE4TEMP_LEGACY code,
    set SEAICE_wetAlbTemp=0 & SEAICE_snowThick=0.
o pkg/seaice/seaice_solve4temp.F (SOLVE4TEMP_LEGACY):
  - remove LEGACY code for solving for tsurf (A1,A2,A3) but maintain the same
    algorithm (same choice: useMaykutPolySatVap=T, postSolvTempIter=0);
    difference in results only due to machine truncation.
  - remove MAX_TICE (tsurf is always =< TMELT anyway); keep MIN_TICE if using
    MaykutPolySatVap; keep MIN_LWDOWN.
  - adapt SEAICE_MODIFY_GROWTH_ADJ code (untested) to non-legacy formulation.
  - update output of verification exp. lab_sea (4 fwd: 11 cg2d digits except hb87,
    + 3 AD: 6 digits except evp) and offline_exf_seaice.seaice (12 digits).
o pkg/salt_plume:
  - isolate saltPlumeFlux array exch into a specific S/R called from
    do_oceanic_phys.F
  - add interface to pkg/salt_plume (filling of saltPlumeFlux) in pkg/thsice.
o verification:
  - move untested set-up to MITgcm_contrib/verification_other.
o pkg/seaice:
  - retire old way of SEAICE_AGE. Now replaced with ALLOW_SITRACER.
o pkg/seaice:
  - seaice_solve4temp.F (keeping results unchanged):
    * add 2 future run-time params to select which saturation vapor pressure
      formula is used and how post-iteration fluxes are set.
      Temporary set these 2 params according to option SOLVE4TEMP_LEGACY;
    * New piece of code (not used) to update surf. atmos. heat flux F_ia using
      the linearized expression to stay consistent with tsurf finding.
  - seaice_freedrift.F avoid floating exception in sqrt(y) since y=sqrt(x*x)-x
    can be < 0.
o pkg/seaice/seaice_solve4temp.F (SOLVE4TEMP_LEGACY undef):
  - remove from F_ia (and from it's derivative dFiDTs1) the contribution of
    conductive heat flux F_c , and add it explicitly when updating tsurf as
    solution of: Fc = Fia + d/dT(Fia - Fc) *delta.tsurf
    so that now F_ia has a consistent meaning through the entire routine.
    This causes differences at truncation level: update output of fwd exp.
    global_ocean.cs32x15.seaice.
o pkg/seaice:
  - lots of editing/cleaning in seaice_solve4temp.F + better documentation
    of arrays, sign/direction of fluxes; no effect on results.
  - replace hard coded 273.16 (=previous value of celsius2K) by celsius2K
    in seaice_budget_ocean.F & seaice_solve4temp.F (SOLVE4TEMP_LEGACY part);
    note: this should have been done before changing celsius2K default.
  - to keep results unchanged, add back old value of celsius2K in verification
    exp. input*/data : lab_sea (AD), offline_exf_seaice (fwd+AD) & seaice_obcs
  - replace hard coded seawater freezing temp in seaice_solve4temp.F (part
    SOLVE4TEMP_LEGACY) of 271.20 (=previous value of celsius2K + default
    value of SEAICE_freeze) by celsius2K+SEAICE_freeze so that seawater
    freezing temp is consistent with value in seaice_growth.F ; this causes
    differences at machine truncation level: update lab_sea AD output (3/4).
o pkg/seaice:
  - mask (in exf_init_fixed.F) atemp,aqh,evap,precip,runoff,lwflx,areamask
    and climsst/sss even when using seaice (to prevent calculation that might
    use SST on land); does not affect any verification exp.
  - apply mask to taux,tauy (in seaice_get_dynforcing.F); update output
    of lab_sea.fd & lab_sea.hb87 and global_ocean.cs32x15.seaice_dynmix.
o pkg/seaice/seaice_growth.F: add mask to avoid non-zero ice thickness
  over land (non-legacy code)
o vectorize salt_plume package:
  - add extra code to salt_plume_frac and salt_plume_tendency_apply_s
  - this code computes plumebk everywhere (also over land), thus requires
    code to avoid divisions by zero and catch the case of kLev=Nr.
  - efficiency of salt_plume_frac is still sub-optimal
o tools (genmake2):
  - fix makefile NAME specification (option: -makefile NAME) by adding
    "-f $MAKEFILE" in few places where it was missing including makedepend
    command (contribution from Paul).

checkpoint63i (2012/01/24)
o model/src:
  - add factorized versions of some EOS code to find_rho.F,
    define USE_FACTORIZED_EOS to turn it on (default for TARGET_NEC_SX)
o model/src:
  - add celsius2K to namelist PARM01; remove unused recip_rhoNil from PARAMS.h;
  - change default celsius2K from 273.16 to 273.15
  - to keep results unchanged, add back old value of celsius2K in verification
    exp. input*/data : aim.5l_cs, 1D_ocean_ice_column, lab_sea (fwd),
     global_ocean.cs32x15(seaice) & cpl_aim+ocn(input_atm).
o model/src: add a little initialisation trick to find_rho.F and find_alpha.F
  to make TAF generate vectorizable code
o pkg/seaice/seaice_evp.F: add code (copied from CICE) that avoids underflows.
   Turn on by defining SEAICE_EVP_ELIMINATE_UNDERFLOWS. Most compilers
   have flags that do this more efficiently.
o pkg/diagnostics/diagstats_calc.F
  - for TARGET_NEC_SX fix the treatment of the scaling factor tmpFac=scaleFact
o pkg/obcs (with exch2):
  - derive OB indices in overlap region from OB-InsideMask (in obcs_init_fixed.F)
    and remove code (in obcs_readparms.F) which was based on EXCH of indices
    (through buffer) and did not account for exch2 (e.g., CS-grid) topology.
o pkg/exf and seaice exp:
  - change offline_exf_seaice.seaicetd test exp. to use default DIFF1 value (=0)
    so that switching off area & heff advection flags does not affect results.
  - change default EXF_LWDOWN_WITH_EMISSIVITY to #define in EXF_OPTIONS.h
  - keep exp. seaice_obcs & 1D_ocean_ice_column(ad) unchanged (using #undef
    EXF_LWDOWN_WITH_EMISSIVITY) and, using pkg/exf default emissivities, update
    results of verification experiments: 1D_ocean_ice_column(fwd),
    global_ocean.cs32x15.seaice(fwd+ad) & seaice_dynmix(ad), lab_sea (all 8)
    and offline_exf_seaice (all 4).
o pkg/seaice:
  - remove array YNEG, RIVER, TMIX (replaced by local var) from common block;
    remove also areaNm1 & hEffNm1 when SEAICE_GROWTH_LEGACY is undef.
  - fix bug: areaNm1 & hEffNm1 are needed in seaice_growth (SEAICE_GROWTH_LEGACY)
    but were not filled when resp. SEAICEadvArea=F & SEAICEadvHeff=F and
    not multi-dim advection;
  - fix seaice_growth.F to compile with both SEAICE_GROWTH_LEGACY and
    SHORTWAVE_HEATING #undef.
o optim: make Makefile more robust (?)
o pkg/obcs:
  * fix treatment of obcs_read_pickup for TAF
o pkg/shelfice:
  * add missing initialisation of num_shifwflx
  * new adjoint verification exp. for isomip
  * change Prandtl and Schmidt numbers from generic formulations
    (in terms of model diffus. and visc.) to separate runtime
    parameters, with Holland and Jenkins (1999) default values.
o pkg/exf (interpolation):
  - extended input field (2 rows) near the N & S poles:
    * fill in with the symetric value (when even Nb of data in longitude)
    * add average value at the poles only for scalar quantities ; for vector
      component interpolation, skip the averaging and keep duplicated values,
      unless the 2 components have same location (uvInterp=T) in which case
      interpolate the 2 components together using S/R EXF_INTERP_UV.
  - new S/R EXF_INTERP_UV to interpolate the 2 components of a vector field
    together: this allows to account properly for local orientation when
    averaging at N & S pole.
  - add CPP option EXF_USE_OLD_INTERP_POLE to recover old results regarding
    exf-interpolation near N & S poles. Undef by default.
  - add debug check/print on 1rst iter if debugLevel >=2.
o pkg/exf:
  - change masking flags definition (no longer "parameter"), put them in
    common block and set them in S/R EXF_INIT_FIXED.
  - change recognized masking flag from s,u,v to c,w,s since the mask
    to use (maskC,W,S) depends on position on model grid and has little to
    do with scalar/vector difference; fix masking if using P-coordinates.
  - fix masking of wind-stress (was wrong if interpolated or read on A-grid)
    and update results of exp. global_with_exf (x2).
  - fix setting of zenith-angle table when SHORTWAVE_HEATING is undef.
o pkg/obcs
  - S/R obcs_calc_stevens: fix a small bug (gammat -> gammas where appropriate)
o pkg/exf (interpolation):
  - assume periodicity in X only if input field cover full longitude range.
  - improve search for lat. index (supposed to be faster, in ~log2(ny) steps,
    and should vectorise).
  - fix input lat of the 2 added row (in case we provide N.pole data).

checkpoint63h (2011/12/30)
o pkg/seaice:
  - change declaration of UVM from _RL to _RS in order to get B-grid
    uIce,vIce monitor when _RS = real*4
o pkg/offline:
  - new S/R OFFLINE_RESET_PARMS for resetting main-model params (switch off flags);
  - compute vertical velocity if not read from file (switch on exactConserv
    & staggerTimeStep);
  - fix output of ptracer monitor iter & time for default PTRACERS_monitorFreq.
o verification:
  - update grid-files (in tutorial_held_suarez_cs/input and fizhi-cs-32x32x40/input)
    with grid-angle generated using "utils/matlab/cs_grid/cubeCalcAngle.m":
    fix Pb in yG definition @ 2 missing corners (previously yG was averaged);
  - update output of exp. global_ocean.cs32x15.viscA4 after changing
    grid-file angles (used here for coriolis-3d);
  - remove (or gzip) few files not needed to run fizhi-cs experiments.
o pkg/exf (vector interpolation):
  - rotate vector component toward local grid-axis orientation using grid-angles
    (stored in GRID.h) instead of locally computed rotation angle; keep old code
    available with exf option EXF_USE_OLD_VEC_ROTATION (undef by default).
o pkg/seaice:
  - allow to compile with exf options ALLOW_ATM_TEMP or ALLOW_DOWNWARD_RADIATION
    undefined. Fix and remove the stop when ALLOW_RUNOFF is undefined.
o pkg/PKG_OPTIONS.h files:
  - move #include "CPP_OPTIONS.h" just after #include "PACKAGES_CONFIG.h",
    outside of the #ifdef ALLOW_THISPKG / #endif block.
  - update verification/*/code/PKG_OPTIONS.h files.
o add a verification experiment (offline_exf_seaice/input.seaice) that test
  the B-grid LSOR solver
o pkg/seaice: sort out emissivity and long wave radiation step 2:
  - add emissivity for snow and ice as new run-time parameters
    (unfortunately) that default to the corresponding exf values; this
    changes results in most verification experiments so that for backward
    compatibility these parameter have to be set explicitly to inconsistent
    values (ugly);
  - the exf-flag EXF_LWDOWN_WITH_EMISSIVITY then gets rid off the hard-wired
    emissivities of 0.97 associated with lwdownloc in S/R seaice_solve4temp
    until we agree how to handle this bug properly
o pkg/exf (interpolation):
  - add a set of run-time param ({inputfield}_interpMethod), one for
    each interpolated input field, to select the interpolation method
    with a value of zero switching off the interpolation;
  - print interpolation parameters to standard output;
  - refine exf_check.F accordingly ; stop if USE_NO_INTERP_RUNOFF is defined
    (to use instead runoff_interpMethod=0 in data.exf).
  - simplify default setting of interpolation parameters (for all fields,
    set position to match model grid cell-center position, leading to trivial
    interpolation in case of regular Lat-Lon grid) and fix for the case of
    non-uniform delY.
o pkg/exf/exf_radiation.F: add the factor ocean_emissivity to lwdown, for
   within #ifdef EXF_LWDOWN_WITH_EMISSIVITY/#endif. Unless ocean_emissivity=1.
   this factor is absolutely required, because the lw exitance (= out-going
   long wave radiation) is emissivity*stefanBoltzmann*T^4 + rho*lwdown,
   where the reflectivity rho = 1-emissivity for conservation reasons. Once
   this is established, we can remove the CPP-Flag (if we want to).
o pkg/seaice:
  - qualify a stop statement in S/R seaice_check: EXF_READ_EVAP and
    ALLOW_BULKFORMULAE are only required if SEAICE_EXTERNAL_FLUXES is defined
  - sort out emissivity and long wave radiation, step 1: make SEAICE_emissivity
    what the name implies (and not emissivity*BoltzmannConstant), this means
    the old default value of 5.5e-8 now means
    5.5e-8/5.670e-8 = 0.97001763668430343479 as ocean_emissivity in
    S/R exf_readparms
  - FV-discretization of the B-grid LSOR solver, turn on with
    SEAICE_LSRBNEW. This new solver also involves a slight re-organization
    of the calling routine dynsolver, so that B and C-grid code look a
    little more alike.
  - fix index bugs in ostres.F (B-grid code)
o pkg/seaice/seaice_ocean_budget.F: change (unused) code to make it look better
o pkg/seaice/seaice_readparms.F: make ocean_emissivity*stefanBoltzmann the
  default for SEAICE_emissivity, if useEXF; requires setting a wrong
  parameter value in global_ocean.cs32x15/input.seaice/data.seaice for
  backward compatiblity
o model/src: use sigmaR in calc_ivdc

checkpoint63g (2011/12/16)
o pkg/seaice/seaice_growth.F:
  fix heat conservation of the coupled ocean-seaice system.
  when SEAICE_HEAT_CONSERV_FIX is defined, the mismatch of
  solid vs liquid water treatment is resolved via QNET.
o pkg/seaice/seaice_growth.F:
  add missing term for sublimation in saltFlux, which was breaking conservation.
o pkg/seaice/seaice_model.F:
  Remove this patholigical case treatment in evolution branch,
  where it is un-necessary and breaks conservation.
  Update global_ocean.cs32x15/results accordingly for
  output.seaice.txt output_adm.seaice.txt and output_adm.seaice_dynmix.txt
o model/src:
  useRealFreshWaterFlux: remove masking of EmPmP (using maskInC) in
  external_forcing_surf.F and apply mask directly in S/R SOLVE_FOR_PRESSURE.
o pkg/obcs:
  modify Stevens boundary conditions so that S/R obcs_calc_stevens computes
  tendency for temperature and salinity that is then applied to update
  theta and salt in S/R obcs_apply_ts; this requires proper masking of all
  horizontal advection and diffusion contributions on the boundary (in
  S/Rs gad_advection, gad_calc_rhs, gmredi_rtransport, gmredi_calc_diff), and
  removing the mask in S/R timestep_tracer. The advantage of this approach is
  that the updated tracer values include contributions from the surface
  forcing and vertical diffusion.
  This modification changes exp4.stevens because of vertical diffusion.
o model/src:
  change non-curvilinear grid setting to also work with exch2 + blank tiles:
  - move delX,delY to new header file (SET_GRID.h) and adjust length to 1rst
    face dimensions.
  - new S/R INI_LOCAL_GRID to define model tile-local grid (using same units
    as delX,delY) and called from S/R INI_CARTESIAN_GRID, INI_CYLINDER_GRID
    and INI_SPHERICAL_POLAR_GRID.
  change test-experiment global_ocean.90x40x15:
  - split the domain in many more tiles (9x4 tiles of 10x10 each);
  - switch to exch2 and remove 1 blank-tile (but only for MPI test).
  - update results of both test (std & dwnslp).
o pkg/diagnostics/diagstat_calc.F: fix problem with non-initialised halos in
   tmp-fields for TARGET_NEC_SX at the cost of extra loops and less vectorisation
o model/src:
  - take sigma-coords related code out of update_etah.F into new S/R UPDATE_ETAWS
    and fix initialisation when using sigma-coords.
o model/src:
 - improve Gael's changes from Jan 14, 2011 "addition of an 'update' of hfacc etc.
   to their current value at the beginning of forward_step.F": add a new run-time
   switch "doResetHFactors" (default=false) and use it to do (or not) the resetting.
 - set doResetHFactors=T in the following test exp:
    global_ocean.90x40x15/input (rStar) & input.dwnslp (linFS),
    global_ocean.cs32x15/input.seaice (rStar), hs94.cs-32x32x5/input.impIGW (linFS)
    and tutorial_global_oce_in_p (nonLinFS in p)
o pkg/ecco
  - added IES cost term
o verification/advect_xz
  - scale down the depth by 1/100 (from 200 km to just 2.km)
  - add secondary test using divergent flow, r-star and implicit vertical advection.
  - add note (check_conserve_TS.txt) and matlab script to check global
    conservation of T & S with NonLin-FreeSurf and Adams-Bashforth.
o pkg/rbcs:
  - add missing relaxUFile & relaxVFile in namelist (in rbcs_readparms.F).
o pkg/obcs (Stevens BCs):
  - fix various problems in the phase speed computations of the Stevens
    boundary conditions:
    - sign error for western and southern boundaries,
    - time tendencies were underestimated by factor of dTracerLev and some just
      zero (for multidim advection schemes) -> now estimate time tendencies
      from difference between previous (n) time level and the one before (n-1);
      this requires storing a field per tracer per boundary, also in the pickup
      files.
    - replace deltaTmom in cflMer/Zon computation with dTracerLev
    - set default phase velocity to cflMer/Zon
  - update verification experiment exp4.stevens
o pkg/generic_advdiff (implicit_r):
  - fix implicit vertical advection conservation with AB and/or NonLin-FreeSurf
    (remove Tr*d/dz(w) in gad_implicit_r.F and add it in gad_calc_rhs.F);
  - fix implicit vertical diffusion or advection with NonLin FreeSurf
    (was using current recip_hFacC instead of future recip_hFacC): set future
    recip_hFac in thermodynamics.F and pass & use it in all vertical implicit
    solver S/R ;
  - fill diagnostics of vertical advective fluxes (computed from tendency)
    when using implicit vert. advection;
  - update output of exp that uses NonLin-FreeSurf & implicit vertical diffusion:
     global_ocean.90x40x15 (fwd+AD), global_ocean.cs32x15 (4 fwd +4 AD),
     tutorial_global_oce_in_p (fwd), tutorial_tracer_adjsens (AD)
     and cpl_aim+ocn (used in ocean); to be fixed: bottom_ctrl_5x5.
o pkg/diagnostics:
  - add diags for T & S tendency which goes through Adams-Bashforth.

checkpoint63f (2011/11/30)
o pkg/obcs/obcs_calc_stevens.F:
  - join some loops to reduce number of if-statements
  - fix a bug in code for northern and southern boundaries.
o pkg/seaice/seaice_init_varia.F
  - undo resetting UVM=0 that has slipped in unnoticed in r1.49 and
    caused zero ice-velocities for the B-grid code
o pkg/seaice/seaice_init_fixed.F
  - fix a bug in the initialisation of the second metric terms
    k2AtC and k2AtZ: k2AtC was set to the value of k2AtZ and k2AtZ was 0.
  - this affects all seaice configurations with useCurviLinearGrid = .true.
    and SEAICEuseDynamics = .true. (default) and SEAICEuseMetricTerms
    = .true. (default)
  - the only verification experiment affected is global_ocean.cs32x15:
    icedyn, seaice, and seaice_dynmix (AD)
o pkg/thsice/thsice_diagnostics_state.F
  - only for TARGET_NEC_SX: initialise all of tmpFld, so that overlap does
    not contain garbage that can lead to surprises in diagstats_calc.F
o model/src:
  - move bi,bj loops inside INTEGR_CONTINUITY ;
  - call INTEGR_CONTINUITY directly from forward_step.F
    (previously called from momentum_correction_step.F)
  - call UPDATE_ETAH from integr_continuity.F and update initialise_varia.F,
    forward_step.F and pkg/ecco/the_main_loop.F
o model/src/do_oceanic_phys.F:
  - reset addMass to zero only if useICEFRONT ;
  - separated k-loop for rhoInSitu calculation ;
  - add 2 diagnostics for wVel*delta^k(Rho) at constant pressure (= WdRHO_P)
    and at constant T,S (= WdRHOdP);
  NOTE: change diagnostics WRHOMASS : this is now simply the Vertical transport
    of In-Situ Density (Anomaly) (=wVel*rho^bar-k) (previously was Vertical
    transport of locally-referenced potential density);
    to recover old diag: (WRHOMASS)_old = (WRHOMASS)_new -1/2 * (WdRHOdP)
o gluemnc:
  - replace ncrcat with ncks when adding variables to *.glob.nc
  - change the way variables without record dimensions are handled so that
    files that have variables with and without record variables can be glued:
    add a record dimension with a new unique name to be able to differentiate
    between variable with and without a-prior record dimensions. Remove
    this record dimension before adding the variable to the *.glob.nc file.
    This procedure automatically works also for grid.*.nc files that do not
    have any record dimension.
o verification/cpl_aim+ocn:
  - generate new reference output on baudelaire (gfortran, mpich2) (previously
    from old aces-grid cluster, ao + ifort) and update 'run_cpl_test' script.
o pkg/obcs/obcs_calc_stevens.F:
  - add code for northern and southern boundaries.
  - reorder some loops to save some operations and so that drFBar can be scalar
o model/src:
  - re-arrange extrapolation calculation in Adams-Bashforth S/R (affects machine
    truncation) and add diagnostics for Adams-Bashforth tendency increment.
  - update test-exp. AD output:
    1D_ocean_ice_column, bottom_ctrl_5x5, lab_sea.noseaicedyn, obcs_ctrl;
  and FWD output: exp4 (x3), fizhi-cs-32x32x40, fizhi-cs-aqualev20,
    front_relax (x3), global_ocean.90x40x15 (x2), global_ocean.cs32x15 (x5),
    global_ocean_ebm, ideal_2D_oce, internal_wave, isomip (x3), lab_sea (x4),
    matrix_example, MLAdjust (x5), natl_box (x2), tutorial_advection_in_gyre,
    tutorial_global_oce_in_p, tutorial_global_oce_latlon and
    tutorial_plume_on_slope.
o pkg/diagnostics/diagstats_calc.F: add special code for TARGET_NEC_SX
  that vectorises. This code uses 3 extra 2D fields, F90 array assignments
  and F90 intrinsic routines SUM, MINVAL, MAXVAL, but since TARGET_NEC_SX
  does not even come with an F77 compiler anymore, this should not be
  a limitation

checkpoint63e (2011/11/06)
o pkg/seaice adjoint of LSR:
  - substantially rework STORE dirs.
  - add new flag SEAICE_LSR_ADJOINT_ITER and parameter SOLV_MAX_FIXED
    this flag will do SOLV_MAX_ITERS but only store SOLV_MAX_FIXED fields
    and only perform SOLV_MAX_FIXED adjoint iters.
    If flag SEAICE_LSR_ADJOINT_ITER is undef-ined, the store in the iteration
    always goes to same record, meaning that the last forward field will be
    the one used in the adjoint - an approximation.
  - now produces non-zero LSR-related gradients, and acceptable gradients for
    An's zonal (x-z) test case (to be checked in)
  - lab_sea: produces acceptable gradients for lab_sea with forward/backward LSR
    (but these are screwed up by the thermodynamics in the first place);
    reduce from 4 to 3 timesteps to avoid t.d. issue as temporary solution;
    output_adm.txt also reflects changes to seaice_lsr
  - global_ocean.cs32x15:
    * the "default" input_ad.seaice has been re-defined to always exclude dynamics
      (output_adm.seaice.txt was updated)
    * new input_ad.seaice_dynmix tests a forward LSR / backward free-drift
      (output_adm.seaice_dynmix.txt)
o test-exp. exp4+stevens:
  - switch off pTracers and nonHydrostatic (restart problems with NH); update output
o pkg/seaice (lsr solver):
  - put coriolis term into FORCEX,Y (as in seaice_evp.F; previously in rhsU,V only);
    update output (change truncation) of FWD test exp lab_sea & global_ocean.cs32x15
  - fix SEAICEuseFREEDRIFT for new OBCS version (ndef OBCS_UVICE_OLD)
  - new parameter "LSR_mixIniGuess" allows (if=2,4) to mix free-drift solution
    into initial guess for linearised solver; use weight ~ (1/err)^2,4.
  - compute (with new S/R) and print initial (+ free-driff sol. if available)
    and final residual of linearised system.
o pkg/pp81: add diagnostics for vertical eddy viscosity and diffusivity
  (requires new subroutines pp81_init_fixed.F/pp81_diagnostics_init.F)
o pkg/obcs: Stevens BCs (still only for east and west)
  - fix Stevens BCs by using intermediate velocities of previous
    time step as "baroclinic" contribution rather velocity of one grid cell
    inside the boundaries; more consistent but makes the entire treatment
    more complicated, requires new pickup files and two new S/Rs:
    obcs_copy_uv_n and obcs_save_uv_n
    keep old version with flag OBCS_STEVENS_USE_INTERIOR_VELOCITY
    (undefined by default)
  - silently move computation of some grid factors into separate loops to
    save some recomputations
  - add a hack for non-linear free surface
  - add a verification experiment to exp4 that tests this code
o make gluemnc/xplodemnc work with (moron) non-GNU shell tools

checkpoint63d (2011/10/25)
o pkg/obcs + seaice-dynamics:
  - new implementation calls OBCS_APPLY_UVICE (in seaice_dynsolver.F) before
    solving for uIce,vIce and prevent SEAICE_LSR or SEAICE_EVP to modify OB
    values (consistent with an implicit method).
  - add option OBCS_UVICE_OLD (in OBCS_OPTIONS.h, defined by default) to
    return to older implementation (same results as before); note that none of
    the "experimental" OBCS_SEAICE options are implemented in the new version.
  - switch test exp. seaice_obcs to use new version (update output).
o pkg/seaice:
  - add few stop (B-grid & CS-exch, B-grid & obcs, AUTODIFF & SEAICE_maskRHS)
  - add parenthesis in Water-Ice drag calculations (evp & lsr);
  - in seaice_lsr.F, simplify and fix AA3 setting in case sNx or sNy=1;
    and fix case SEAICE_waterDrag=0 (but unstable if no or little seaice)
  - update output of test exp lab_sea that uses evp or lsr (fwd+ad)
    and global_ocean.cs32x15 (icedyn & seaice fwd+ad).
o pkg/layers:
  - Include potential density as new coordinate (Thanks to David Munday)
o pkg/dic:
  - Remove subroutine CALC_PCO2_APPROX_CO3 from carbon_chem.F and add
    carbonate computation/output to CALC_PCO2_APPROX
o pkg/generic_advdiff
  - make TAF generate code that vectorizes:
    gad_dst3fl_adv_*.F, gad_u3c4_impl_r.F
o model/src:
  - improve vectorization also for adjoint code of
    solve_tridiagonal and solve_pentadiagonal. As this requires up to
    5 new 3D-fields, this code is only turned on for the combination of
    ALLOW_AUTODIFF_TAMC and TARGET_NEC_SX. Also remove error message
    for singular matrix check (only for TARGET_NEC_SX).
  - remove hard-wiring of CPP-flag ALLOW_SOLVERS_KLOOPINSIDE to
    ALLOW_AUTODIFF. This flag now needs to be set outside of
    solve_tri/pentadiagonal.F
o pkg/exf:
  - fix previous modif in exf_readparms.F (revision 1.66: treatment of
    optional namelist EXF_NML_OBCS).
  - add many debug-print (to trace down where pkg/cal error msg comes from)
o pkg/mom_vecinv/mom_vi_hdissip.F
  - rearrange loops so that vectorization is improved and in particular
    the adjoint routine vectorizes. The code is a little longer now, but I
    think easier to read.
    Note: CPP-flag MOM_VI_ORIGINAL_VISCA4 is not tested.
o pkg/seaice:
  - allow to specify initial seaice velocity from files (uIceFile,vIceFile)
o pkg/exch2:
  - alternative code (without tile x tile matrix) for cumulated (global) sum;
    used as default; keep using matrix version in adjustment.cs-32x32x1.
o tools/build_options:
  - after merging some MPI and/or multi-threads specific optfiles so that
    the modified default optfile support both built (using genmake2 -mpi
    for the MPI built, using genmake2 -omp for OpenMP built),
    move now obsolete optfiles to tools/build_options/unsupported/
   (add copy of email sent to support list in doc/optfiles_changes.txt)

checkpoint63c (2011/09/28)
o pkg/ebm:
  - fix ebm_zonalmean.F for several procs in Ydir (nPy > 1); update output of
    test exp. global_ocean_ebm (affects machine truncation, 12 digits for cg2d)
o pkg/seaice (SItracer pickup)
* Simple code for pickup of SItracer fields (#define ALLOW_SITRACER)
  To be done:
  - thorough testing of missing fields in S/R seaice_read_pickup
  - thorough matching between generic tracers and specific fields used
    (e.g. volume-weighted age, area-weighted age, salinity, ...)
o pkg/grdchk:
  - all procs calculate and print finite-difference gradient (for testreport)
  - change description output used by testreport;
  - AD testing: also compare and report Finite-difference gradient;
    => update all output_adm*.txt
o test exp. global_ocean_ebm:
  - switch back useRealFreshWaterFlux (no problem anymore with run-off);
    and turn on exactConserve; update (fwd) output.
o pkg/seaice (LSR):
  - print to STDOUT number of solver iterations at SEAICE_monFreq interval.
  - modify solver to deal cleanly with u/v switch at face edges (CS-grid):
    * identical results with non-CS topology (but save up to half of EXCH calls)
    * no much changes in cs-32 verification tests since no ice at face edges
     (differences due to convergence criteria, since nb of iterations changed)
    * expect some differences on lat-lon-cap grid.
    update FWD results of global_ocean.cs32x15 test exp. (icedyn & seaice)
o pkg/exch2:
  - add new CPP option to disable Cumul-Sum matrix (to save storage when using
    many tiles); until alternative coding is added, just add a stop.
o pkg/kpp:
  - move ptracer/salt correction to KPP diffusivity from calc_3d_diffusivity.F
    to S/R KPP_CALC_DIFF_PTR (+ add tracer-index to argument list).
o optfiles:
  - merged few MPI specific (*+mpi*) and multi-threads specific (*+mth) optfiles
    into corresponding standard one, which now support different build:
    (when using "genmake2 -mpi" for MPI built, "genmake2 -omp" for OpenMP built)
  - add "darwin_amd64_gfortran" optfile (initially from Constantinos, tested by Gael)
o pkg/obcs (seaice):
  - add missing EXCH for uIce,vIce after applying OBCS;
  - remove S/R EXF_SWAPFFIELDS_X/Y , disable S/R EXF_SET_OBCS_X/Y by adding
    argument = number of levels to S/R EXF_SWAPFFIELDS_XZ/YZ and S/R
    EXF_SET_OBCS_XZ/YZ ; update obcs_exf_load.F;
  - fix EXF_SET_OBCS_XZ/YZ for multi-threaded (assuming loaded arrays are shared)
  - verification exp. seaice_obcs: split domain in 2 tiles ; add SIZE.h_mpi
    and eedata.mth for MPI and mutlti-threaded testing.
o pkg/flt:
  - make FLT EXCH working with multi-threads (and MPI + multi-threads);
  - use buffer for floats IO (trajectories & profiles); size set in FLT_SIZE.h;
  - fix pickup and trajectories + profiles output with multi-threads;
  - add parameter to select group of fields to write along trajectory and
    profile (default unchanged);
  - only call PORT_RAND* function when flt_noise <> 0;
  - add multi-threaded test for verification exp. flt_example.
o eesupp/src:
  - fix S/R ALL_PROC_DIE for MPI+multi-threads.
  - USE_OMP_THREADING: check that number of threads (from eedata) matches
    actual number (from env.var. setting).
o pkg/ebm:
  - fix multi-threading in ebm_area_t.F ; clean-up EBM.h header file.
  - add multi-threaded test for verification exp. global_ocean_ebm

checkpoint63b (2011/08/29)
o pkg/ebm:
  - fix sign of runoff;
  - update directly forcing fields (Qnet,EmPmR) to use standard
    external_forcing_surf.F (remove ebm_forcing_surf.F);
  - avoid loading forcing fields a 2nd time (1rst time from ini_forcing.F);
  - set either tauThetaClimRelax (in data) or tauThetaZonRelax (in data.ebm)
    and apply relaxation towards corresponding SST field (2-D map or ZonAver).
  - update global_ocean_ebm parameters file data and update output (fwd+ad).
o verification/matrix_example:
  - split domain in 8 tiles (2x4); add SIZE.h_mpi and eedata.mth for
    MPI and mutlti-threaded testing.
o pkg/matrix:
  - change name of S/R MATRIX_INIT to S/R MATRIX_INIT_VARIA ;
  - fix for multi-tiles (add bi,bj indices to exp/impMatrixCounter);
  - fix for multi-threaded (remove DATA statement);
  - use standard DIFFERENT_MULTIPLE function;
  - add MATRIX_OPTIONS.h
o verification/matrix_example:
   To allow to split the domain in several tiles, change the domain size
    from 31x31 to 32x32 by adding 1 row (on Southern side) + 1 column (on
    Western side) of land points.
o (*_)write_pickup:
  - fix few bugs in mypackage_read/write_pickup.F
  - in MDS_WR_METAFILES calls, replace "myTime" by a local copy into
    array of length 1 (was caught by compiler syntax-check).
o pkg/diagnostics (velocity potential solver):
  - fix initialisation of main diagonal matrix (for overlap values)
o tools/build_options:
  - towards single optfile for MPI and non-MPI built: merge few +mpi optfile
    into previously non MPI one (linux_am64 pgf77,open64,pathf90,ifort11)
  - linux_amd64_gfortran: merge +mpi_generic version into standard optfile:
    * move IEEE flags to DEVEL section; take IEEE flags from +mpi_generic ;
    * FAST case: for now, keep -O3 with ini_masks_etc.F in NOOPTFILES list;
    and use "-devel" testreport option for standard testing on baudelaire.
o pkg/grdchk:
  - Assume that all gradient-check position are within the same tile
    corresponding to global indices (iGloTile,jGloTile) and that
    positions (i,j indices or nbeg) are local to this tile;
  - set tile local-indices and proc. number according to tile global-indices;
  - remove grdchkwhichproc from namelist (retired param);
  - send adjoint gradient to all procs so that all procs print it to STDOUT;
  - switch on MPI test for global_ocean.90x40x15 AD test experiment.
o adding package bbl (Bottom Boundary Layer)
  description in MITgcm/pkg/bbl/bbl_description.tex
  example/test experiment in MITgcm_contrib/bbl
o adjoint verifications
  - changed 5 experiments to multi-tiles
    * global_ocean.90x40x15
    * obcs_ctrl
    * offline_exf_seaice
    * tutorial_dic_adjoffline
    * tutorial_tracer_adjsens
    changed reference output for those that crossed tile boundaries
    (changed choices of gradient check positions)
  - with same tiling, switch on MPI test for the last 4 (add SIZE.h_mpi)
  - temporary bug fix in grdchk_loc.F for obcs
o genmake2 & testreport
  - add target "obj" (just for OBJFILES files) to Makefile;
  - add option to specify FEXTRAFLAGS on command line.
o pkg/mypackage:
  - remove bi,bj arguments from argument list of S/R MYPACKAGE_CALC_RHS

checkpoint63a (2011/08/02)
o pkg/diagnostics (velocity potential):
  - fix velocity-potential calculation when using OBCS: balance net inflow
    at each level (new S/R OBCS_DIAG_BALANCE).
  - fix some of the problems with OBCS in stream-function calculation.
o pkg/exf/exf_readparms.F
  - make treatment of optional namelists (EXF_NML_04, EXF_NML_SGRUNOFF,
    EXF_NML_OBCS) more consistent, so that you need not have these lists
    in data.exf when they are not used.
o optim/optim_readdata.F:
  - add some output about obcs variables that might help debugging
  - add a check about nvarlength
o pkg/ctrl: once again, fix computation of endrec in s/r ctrl_init_rec
o pkg/diagnostics (velocity potential):
  - fix mask for OBCS (still problems in stream-function with OBCS);
  - add specific parameter (default = main code CG2D params) for solver;
  - in case of poor convergence, use solution corresponding to lowest residual.
o pkg/seaice/seaice_growth.F: small changes that permit vectorizable
  adjoint code. In general statements like tmpscal=fld(i,j) are problematic
  and should be avoided where possible.
o model/src (rStar):
  - include r* effect on reference-state (PhiRef) in totPhiHyd
    (so that it's really the potential anomaly at the cell center);
    affect solution only if z* with full pressure in EOS.
  - test-exp global_ocean.90x40x15: reduce viscA4 (was not stable) and
    update output (because of z* in totPhiHyd and viscA4 changes);
  - keep the previous diagnostics as "PHIHYDcR" (closer to potential anomaly
    @ constant r) until interpolation at constant r is implemented.
o pkg/diagnostics
  - fix RCENTER diagnostics in case cell center is not at interface middle
o add code for TEOS-10 (www.teos-10.org, McDougall et al. 2011). Use
  this eos with eosType = 'TEOS10', in data (PARM01). This eos implies
  that THETA and SALT are "conservative temperature" and "absolute
  salinity"
o pkg/ctrl
  - fix computation of endrec in s/r ctrl_init_rec
  - ctrl_pack/unpack_*: remove unused variables and some obsolete code
o pkg/seaice/seaice_growth.F
  - fix recomputation with FENTY_AREA_EXPANSION_CONTRACTION code,
    remove then obsolete STORE directives
  - fix STORE directives for tice and tices, so that only the
    appropriate part of the fields are stored (and not the entire
    field); update global_ocean.cs32x15.seaice AD output.
  - cosmetic changes: adjust CPP flags and indentation for better
    legibilty
o pkg/autodiff: add mnc-output of adBottomDragFld (code contributed by
  Chris Wilson)
o pkg/gmredi:
   Add Sub-Meso Eddies parameterisation from Baylor (for now, disabled with TAF),
   and test it in verification exp. "front_relax.bvp" (update output.bvp.txt)

checkpoint63  (2011/07/11)
o pkg/exch2:
 - rename+move: nTiles in W2_EXCH2_PARAMS.h --> exch2_nTiles in W2_EXCH2_TOPOLOGY.h
 - exch2 version of Cumul-Sum routine: S/R W2_SET_MAP_CUMSUM set up the
   (2*nTiles)x(nTiles) Cumul-Sum matrix and Master Proc collects all tiles X,Y
   increments, calculates Cumul-Sum @ tile origin and sends results to each tile.
o pkg/diagnostics:
 - deal with pairs of post-processed diags which are computed together; in
   particular, re-order list of diags within 1 file to save 2nd computation.
 - add S/R to compute velocity stream-function (called after velocity-potential
   calculation) from divergence free transport -> new diagnostics "PsiVEL".
 - add parameter to select grid-point location where PsiVEL == 0.
o eesupp/src:
   new S/R to calculate cumulated sum on tiled array, corner grid-cell location
   (specific S/R needed with exch2 topology - for now, just print an error msg)
o pkg/shelfice
 - Implement friction velocity-dependent transfer coefficients following
   Holland and Jenkins, JPO, 1999
   Original code by M. Losch with small modifs.
   Enable with CPP option SHI_ALLOW_GAMMAFRICT
   and runtime flag SHELFICEuseGammaFrict
o verification lab_sea & global_ocean.cs32x15:
 - use tools/xmakedepend (instead of cyrus_makedepend, in genmake_local):
   does not miss some dependencies (but is slower) and also works with many files
   (default makedepend limitation for AD built).
 - use cyrus_makedepend in adjustment.128x64x1 (so that it still tested).
o pkg/diagnostics:
 - add run-time parameter "useMissingValue" (def=False) to fill land-point
    (i.e., where mask=0) with MissingValue ; used only in MNC output file.
   This replaces CPP-option DIAGNOSTICS_MISSING_VALUE.
 - Extend the use of "missing_value" setting from data.diagnostics for the case
   of counter-diagnostics (where fraction-weight is zero). This applies both to
   MNC and MDS output files.
o pkg/seaice/seaice_growth.F:
  - add 'a priori' cap of latent heat flux based on actual mass considerations
    when SEAICE_ADD_SUBLIMATION_TO_FWBUDGET is used in conjunction with the
    non-legacy seaice_solve4temp.
  - add diagnostic of the residual sublimation freshwater flux (the freshwater
    flux taken from the ocean if the total actual latent heat fluxes exceed
    the maximum)
  - remove the CPP switch around the *_FWbySublim unit change and move diagnostic
   fill for SIatmQnt, SIfwSubl, SIatmFW to the end of seaice_growth.F.
  - add diagnostic of the actual sublimation freshwater flux (that is 0. ifndef
   SEAICE_ADD_SUBLIMATION_TO_FWBUDGET) and of the latent heat flux (evap+sublim).
  - bug fix : frWtrAtm needs a_FWbySublim ifdef SEAICE_ADD_SUBLIMATION_TO_FWBUDGET.
  - bug fix : missing part to Martin's r_FWbySublim pathological case fix.
o verification 1D_ocean_ice_column:
   made model domain truly 1x1x23 instead of 5x5x23 with only center cell (3,3,:) wet
   update results
o pkg/diagnostics:
 - Implement setting of "Post-Processed" diagnostics (corresponding to gdiag(5)='P')
   which are not filled-up but computed from other diags ; In this case, the mate
   diag points to the primary (filled-up) diag to used for post processing.
 - Update Velocity-potential computation using post-processed diag framework.
 ==> Change the ordering of fields and time-periods in MDS output file
   when using periodic averaging: now writes one time record with the full set
   of fields for this time period, then the next time reccord (it used to be
   one field with the full set of time records then the next field).
     Note: this is now similar to NetCDF (MNC) output file. <==

checkpoint62z (2011/06/21)
o adjoint monitor:
 - Add adjoint monitor output for packages exf, seaice
   and update relevant testreport output
o pkg/seaice:
 - re-order diags inits so that they appear in order in available_diagnostics.log
 - added diags: hsnow thermo. rates of change, area preceeding ridiging process,
   area/heff/hsnow preceeding thermodynamic growth/melt.
 - modified diag: SIdA; output actual effect, as the description states.
 - modified description: SIqneti, SIqneto, SIuheff, SIvheff, SIdAb*, HSNOW.
 - retired redundant diags: SIyneg, SIfice, SIsnwice, SIthdgrh.
   (SIyneg->SIdHbOCN; SIfice->SIdHbATC; SIsnwice->SIdHbFLO;
    and SIthdgrh->SIdHbOCN+SIdHbATC+SIdHbATO)
 - modified diags (2) : switch all SIdA*, SIdH*, SIdS* from delta to rates.
 - added diagnostics for seaice generic tracers (SItr*).
 - added SItrUnit and SItrNameLong run time param (for SItr* diags).
 - in diag names, replaced 'PrTh' abbrev. of 'preceeding thermo' with 'PT'.
 I. Fenty: 18-Jun-2011:
 Minor changes to seaice package:
 1) Retired old variables (A22, SEAICE_lhsublim, areaMax, areaMin, hiceMin) and
    added some new ones (SEAICE_area_reg, SEAICE_hice_reg, SEAICE_area_floor)
   - Differentiated "regularization variables" from "floor variables"
    * areaMin became SEAICE_area_reg (old A22) and SEAICE_area_floor
    * hiceMin became SEAICE_hice_reg (old hiceMin)
      (with _reg meaning regularization variable)
   - SEAICE_lhSublim becomes lhSublim, the sum of SEAICE_lhEvap and SEAICE_lhFusion
    so as to ensure energy conservation when going between phases
  - A22 was not used anywhere
 2) Changed regularization procedure for heffActual and hsnowActual to ensure
    well-boundedness and smooth adjoint in seaice_growth.F
 3) Fixed a bug where seaice_solve4temp would not recognize ice-free grid cells
    because the old regularization always set heffActual >= 0.05 cm
 4) Changed the model so that the default behavior is to put a small (10^-5) "floor"
    on AREA when HEFF > 0.
  - went from requiring ALLOW_PRECLUDE_INFINITESIMAL_AREA to be defined to
    requiring that DISABLE_AREA_FLOOR *not* be defined
 Affected verifications:
  - 1D_ocean_ice_column (output.txt output_adm.txt)
  - global_ocean.cs32x15 (output.seaice.txt output_adm.seaice.txt)
o pkg/diagnostics:
  - move MNC code from diagnostics_out.F into new diagnostics_mnc_out.F (2 S/R).
  - rename S/R GETDIAG to DIAGNOSTICS_GET_DIAG and change type of 1rst argument
    (was _RL, now integer) with option = 0 to retrieve all levels.
  - add pieces of code to compute velocity potential at each level (new diagnostics
    PhiVEL, works only when UVELMASS & VVELMASS are also turned on);
    for now, using same params as CG2D (target-resisual, max Nb of iter ...).
  - fix few issues with counter diagnostics in diagnostics_setdiag.F &
    diagstats_setdiag.F (if diagnostic counter is itself a counter diag)
    and in diagnostics_fract_fill.F (do not need a valid pointer for the
    diagnostics counter-mate); check that definition of counter-diagnostic
    includes a valid counter-mate (in diagnostics_set_levels.F).
o model/src (rStar):
  - add rStar scaling factor in diags_phi_hyd.F (similar to calc_grad_phi_hyd.F);
    affect solution only if z* with full pressure in EOS;
    update output of test-exp global_ocean.90x40x15.
o pkg/seaice:
  - introduce siEps=1e-5 parameter
  - use areaMax in AREA update (part 4), consistent with ridging step (part 2.5).
  - re-organize SEAICE_ADD_SUBLIMATION_TO_FWBUDGET code.
  - introduce ALLOW_SITRACER and seaice_tracer_phys.F to handle generic seaice tracer.
    For now it covers, and was tested for, ice salinity and age (attached to HEFF),
    as well as ice cover age and ridging index (attached to AREA).
    For now the run time parameters (in data.seaice/SEAICE_PARM03) are
    SItrName (e.g. 'age') and SItrMate ('HEFF', which is the default, or 'AREA').
    Up to SItrMaxNum=3 tracers can be used simultaneously.
o pkg/salt_plume:
  -introduce SPsalFRAC run time parameter that sets the fraction of the
   salt by-product of ice growth (SPsalFRAC*(1-SIsalFRAC)*salt typically)
   that gets vertically redistributed (fluxed down) by pkg/salt_plume.
o model debug options:
  - Switch reading of debugMode from S/R INI_PARMS (parameter file "data", stored
    in PARAMS.h) to S/R EESET_PARMS (parameter file "eedata", stored in EEPARAMS.h).
  - Refine debug-msg printing selection (3 new levels):
    debugMode  : controls printing of debug messages (sequence of S/R calls).
    debugLevel : controls printing of algorithm-relevant auxiliary/debug messages
     debLevZero =  0 ; /* level of disabled aux. msg printing */
     debLevA =  1 ; /* level of minimum  aux. msg printing */
     debLevB =  2 ; /* level of low aux. print (report read-file opening)*/
     debLevC =  3 ; /* level of moderate debug prt (most pkgs debug msg) */
     debLevD =  4 ; /* level of enhanced debug prt (add DEBUG_STATS prt) */
     debLevE =  5 ; /* level of extensive debug printing */
    New debugLevel default: with default debugMode value (=F),
      = 2 (debLevB) or = 1 (debLevA) in case ALLOW_AUTODIFF is defined.;
      and if debugMode=T, default debugLevel = 4 (debLevD).
    Relation with previous settings:
     debLevB (=2) corresponds to former debLevA (=1)
     debLevD (=4) corresponds to former debLevB (=2)
    Note:
     a) if debugLevel=0, skip WRITE_GRID call when nIter0 > 0 (same as before);
     b) default debugLevel=1 is convenient in AD runs (avoid many file opening msgs);
        to recover previous default, set debugLevel=2 (e.g. AD-test hs94.1x64x5)
  - Add new parameter (printResidualFreq, read from PARM02 namelist) to print
    detailed CG solvers convergence; off (=0) by default, except if debugLevel=5.
o pkg/obcs:
  - change OBCSfixTopo default from True to False (should not change the results);
    keep OBCSfixTopo=T in verification-exp. seaice_obcs.
o pkg/thsice:
  - fix bug in thsice_calc_thickn.F (was introduced in version 1.18) in
    2nd layer seaice sublimation (unlikely to happen)
  - use Interior mask for OBCS in thsice_advection.F (similar to what is
    done in gad_advection & seaice_advection).
o adjoint:
  bug fix spotted by Gael Forget:
  seaice_advection and thsice_advection still had
  legacy CPP options to avoid CS corner updates for adjoint
o pkg/seaice:
  => Change some of the defaults (2011/05/29):
     - change SEAICEuseFluxForm default (from False to True)
     - change DIFF1 default (from 0.004 m/s to 0. m/s)
     And print warnings if DIFF1 is not set in data.seaice and centered
      avection scheme is used without any diffusion.
  also:
  - fix seaice_diffusion calls in default AdvScheme part of seaice_advdiff.F;
  - set SEAICEdiffKh[] default in the same way as SEAICEadvSch[]
  - stop if DIFF1<>0 with SEAICEadvScheme <> 2, if DIFF1<>0 with any
    other non-zero SEAICEdiffKh[] diffusivity, if SEAICEadvSalt=T with
    #undef SEAICE_VARIABLE_SALINITY, if SEAICEadvAge=T with #undef SEAICE_AGE.
  update results of test exp.:
     lab_sea: output.fd (switch to AdvScheme=33 with diffKh=20)
         output.hb87, output_adm.evp (SEAICEuseFluxForm=T and diffKh=200)
         output_adm.noseaicedyn (SEAICEuseFluxForm=T)
     offline_exf_seaice: output.seaicetd, output_adm (SEAICEuseFluxForm=T)
     seaice_obcs: output (SEAICEuseFluxForm=T)
  and prescribe old default for SEAICEuseFluxForm (=F) and DIFF1 (=0.004)
      for standard fwd & AD lab_sea tests (to keep the same output).
o pkg/seaice/seaice_growth.F:
  - use Ian Fenty's capping formulas for actual ice
  thickness thoughout EVOLUTION branch.
  - put treatment pathological case #2) in CPP brackets
  (ALLOW_AVOID_INFINITESIMAL_AREA, undef by default).
  - update global_ocean.cs32x15 and 1D_ocean_ice_colum results accordingly.
o pkg/seaice:
  - seaice_diffusion.F : remove the min(DX,DY) factor permanently;
  pass the Laplacian diffusivity (in m^2/s) diffKh as a parameter;
  also pass fac as a param, which can be 1. (to update the tendency
  field) or the time step (to update the field itself).
  - seaice_advdiff.F: for multidim, call seaice_diffusion with
  e.g. SEAICEdiffKhHeff and with fac=1; for single-dim, call
  seaice_diffusion with e.g. SEAICEdiffKhHeff and with fac=time step.
  - SEAICE_PARAMS.h, seaice_readparms.F, seaice_check.F :
  hooks to handle SEAICEdiffKhHeff, SEAICEdiffKhArea, etc.
o pkg/seaice:
  diffusion with centered advection scheme (diffus.F & advect.F):
  - simplify S/R DIFFUS (put deltaT & DIFF1 factor outside, move EXCH outside)
    to just compute the laplacian of input-field.
  - unroll k loop (harmonic,biharmonic diff) in advect.F to save 1 exch call.
  - fix flux-form version in diffus.F to conserve tracer.
  update output of lab_sea.fd & lab_sea.hb87 (1rst set of modif affects
   machine truncation) and lab_sea.salt_plume (conservative flux-form modif)

checkpoint62y (2011/05/26)
o pkg/seaice:
 - seaice_growth.F : in EVOLUTION branch, always include
   a_QSWbyATM_cover in qnet (as it should be).
 - verification/global_ocean.cs32x15 : update results accordingly
   (output.seaice.txt output_adm.seaice.txt).
o pkg/seaice + obcs:
 - use maskInW & maskInS in multi-dim advection and biharmonic diffusion:
   equivalent of assuming no tracer gradient outside the OB region.
   update output of seaice_obcs (uses DIFF1 <>0 => biharmonic diffusion)
 - remove calls to OBCS_COPY_TRACER after EXCH calls (no longer needed
   after changes above);
 - obcs+seaice cleaning: apply seaice-tracer OB values to tracer field
   only at OB location (instead of over a band of OLx width).
o pkg/seaice:
 - fix wrong indices in old (non Flux-Form) diffusion default S/R diffus.F
   (dxG(I+1, ...) changed to dxG(I, ...), no impact on Lat-Lon grid)
o pkg/obcs:
  - split header file "OBCS.h" into 4 separated files:
    OBCS_PARAMS.h, OBCS_GRID.h, OBCS_FIELDS.h & OBCS_SEAICE.h
   Note: OBCS_PARAMS.h & OBCS_GRID.h can be included without OBCS_OPTIONS.h
     (contain no conditional statement which depends on OBCS options).
  - move "useOBCSYearlyFields" from "data.obcs" (hold in OBCS_PARAMS.h)
    to parameter file "data.exf", namelist EXF_NML_OBCS (in EXF_PARAM.h).
o ctrl, cost, grdchk & autodiff pkgs:
  - make options file more standard (like other {PKG}_OPTIONS.h file but
    with AD_CONFIG.h); clean-up some of the included header files.
o pkg/obcs:
  - do not mask tracer when applying OB (tracer == 0 could generate problems)
  - apply tracer OB values to tracer field only at OB location (instead of
    over a band of OLx width)
  - clean-up obcs_apply_w.F & obcs_apply_eta.F (since less calls to these S/R)
  - remove OBCS_MULTIDIM_OLD_VERSION code in gad_advection.F and remove
    obcs_apply_tloc.F & obcs_apply_sloc.F
o obcs in model/src:
  - call OBCS_APPLY_W only if NonHydrostatic.
  - call OBCS_APPLY_ETA only if NonLinFreeSurf.
  - reset dEtaHdt and wVel to zero outside OB interior region ;
  - leave tracer unchanged outside OB interior region: This has no effect
    on the solution but just to prevent unrealistic tracer value outside OB.
  - zero out velocity outside OB interior region: This has no effect on
    the solution but just to prevent unrealistic velocity outside OB.
o obcs and non-lin free-surf:
   move call to OBCS_APPLY_R_STAR from update_r_star.F to calc_r_star.F
   and call to OBCS_APPLY_SURF_DR from update_surf_dr.F to calc_surf_dr.F
   + add argument "etaFld" to OBCS_APPLY_R_STAR & OBCS_APPLY_SURF_DR:
   this fixes missing EXCH + get consistent eta OB value (+ fix restart).
   update results of test-exp. exp4(nlfs).
o exp4 (nlfs) test-exp:
   use OBC for Eta at Western & Eastern OB (to test prescribing Eta
   with NonLin-FreeSurf); update output.nlfs.txt
o obcs and 2d/3d solver norm:
   use interior masks (maskInC) to cancel out cg2d & cg3d matrix coeff at OB
   and outside OB interior region (will allow to place OB further inside the
   domain). Depending on the domain, can affects cg2d-Norm (previous
   cancellation outside OB was only partial), e.g. in exp4 & obcs_ctrl,
   and cg3d-Norm (previous Norm was computed before canceling OB terms),
   e.g. in tutorial_plume_on_slope.
  - update output of exp.: exp4 (x2), obcs_ctrl and tutorial_plume_on_slope.
o pkg rbcs:
  - split RBCS.h into 3 files: RBCS_SIZE.h, RBCS_PARAMS.h & RBCS_FIELDS.h
  - add capability to apply relaxation to horizontal velocity uVel & vVel.
o pkg/grdchk: add gradient check for control variable xx_shifwflx
o pkg/shelfice/shelfice_init_fixed.F
  fix CPP-flag combinations
o pkg/seaice: Merge iceage code of Pierre Rampal
  * update/change/correct ice age calculations
  * add age updates for pathological cases
  Probably needs more testing...

checkpoint62x (2011/05/13)
o pkg/mom_vecinv:
   high-order vorticity scheme: use interior masks (maskInW & S)
   to zero-out (outside OB) gradient of vorticity.
o verification exp.:
   turn on "useEnergyConservingCoriolis" (better discretisation) in exp.
   hs94.128x64x5 and seaice_obcs ; update results.
o pkg/obcs:
  fix bug in OBeta for YZ sections in obcs_exf_load.F
o pkg/ctrl, pkg/shelfice, and optim:
  - add new control variable xx_shifwflx (fresh water flux underneath ice
    shelves). This is almost as tedious as obcs-ctrl, because the
    variables needs its own mask.
  - add a cost function term that penalizes the deviation of xx_shifwflx
    from the first guess (zero) in analogy to other control variables
o pkg/shelfice:
  - start basic adjoint
o pkg/ctrl:
  - remove extra 2D field "for good measure" when initializing in
    ctrl_set_globfld_[xy/xz/yz].F
  - replace hard coded precision 32 (a bug) in ctrl_map_ini_gen by ctrlprec
  - improve error messages in ctrl_set_unpack_*
o OBC implementation in momentum:
   use interior masks (maskInC,W & S) in momentum S/R:
   - multiply divergence, tension and some del^i.u or del^j.v by maskInC
   - multiply del2u,del2v by maskInW/S (biharmonic viscosity)
   - multiply horiz. grad of vorticity by maskInW/S (in Leith scheme)
   - multiply gradient of wVel by maskInW/S in del2w calculation (NonHyd)
   Motivation: fix/clean implementation of OBC with biharmonic-viscosity
    (and also with Leith/Smagorinsky harmonic-viscosity).
   Update output of experiment dome and exp4 (+nlfs).
o exp4 test-exp:
  - turn on: nonHydrostatic, exactConserv, viscA4 (with momDissip_In_AB=F)
    and prescribe time-varying OB (without pkg/exf) for zonal-velocity
    at Western & Eastern Boundaries (+/- 1 per-cent); Also prescribe
    time-varying OB at Western-side for wVel (NonHyd); update output.
  - add secondary set-up (.nlfs) using NonLin FreeSurf (z*) + mom_vecinv
    and biharmonic-viscosity ; also use prescribed time varying OB.
o pkg/obcs:
  fix bug in OBWeta,OBWeta indices in obcs_apply_r_star.F
o model/src:
  - fix startTime setting when baseTime<>0 & nIter0=0 are specified ;
  - initialise startTime & nIter0 with unlikely values: allows to set one
    from the other without ambiguity.
o seaice_obcs test-exp.:
  add small diffK4T,S to test biharmonic diffusivity with OBCS ; update output.
o pkg/obcs:
  - remove calls to OBCS_COPY_TRACER after EXCH for T,S & pTracer:
    no longer needed with maskInC,W,S in pkg/generic_advdiff.
o pkg/seaice:
  - retired SEAICE_SALINITY and SEAICE_salinity in favor of
    SEAICE_VARIABLE_SALINITY and SIsalFRAC, respectively.
  - fixed bug in the initialization of sea ice salinity variable HSALT
    in seaice_init_varia.F  (removed dependence on ICE2WATR)
o fizhi-cs test exp.:
   switch reference output convention for these 2 non-standard test-exp,
    from: pgi  6.1-5 on faulks (FC.6, -of linux_ia32_pgf77+authors_fc5)
      to: ifort 11.1 on baudelaire (FC.13, -of linux_amd64_ifort11)
   reason: faulks might get retired soon and pkg/fizhi has still Pb with gfortran
o model/inc:
  - change type of PmEpR array (from _RS to _RL) to fix restart (with "-use_r4")
    of exp. global_ocean.90x40x15 (Suncronous time-stepping + Real-FW + NonLin-FS)
o pkg/seaice:
  - fix calculation of saltFlux and saltPlumeFlux when using SEAICE_SALINITY
o verification/lab_sea, 1D_ocean_ice_column, seaice_obcs, global_ocean.cs32x15
  - updated output*.txt files due to bug fixes in salt, saltPlumeFlux,
    and initial HSALT

checkpoint62w (2011/04/26)
o pkg/mom_fluxform:
  - fix calculation of del2u & del2v (no-slip BC) when using Non-Lin Free-Surf.
  - use parameter "sideDragFactor" in no-slip BC side-drag part.
  - update output of exp. global_ocean.90x40x15
o pkg/mom_vecinv:
  mask del2u & del2v (no effect on results, but cleaner & closer to mom_fluxform)
o update seaice exp.:
  use more consistent parameter values (remove "backward compatability only":
   ICE2WATR, SEAICE_lhSublim, SEAICE_cpAir, SEAICE_rhoAir + set rhoConstFresh)
  related to thermodynamics seaice. Update output (fwd+AD) of exp.:
   1D_ocean_ice_column (x2), lab_sea (x8), ioffline_exf_seaice (x2) & seaice_obcs
o update test-exp global_ocean.90x40x15:
  o use default CD_CODE_OPTIONS file (Adams-Bashforth on CD Mom & Coriolis).
  o increase Overlap size from 2 to 3 (to allow to test bi-harmonic Visc.)
  o new pickup-files from a 100.yr run with pkg/down_slope (input.dwnslp params)
  o turn on zStar & viscA4 in standard set-up (dir input/)
    and update output files: output.txt & output.dwnslp.txt
o new AD-test experiment: obcs_ctrl
  (From Matt MITgcm_Contrib/SOSE/BoxAdj) to test OBCS as control vector.
o pkg/dic:
  fix two bugs in handling water vapour pressure in carbonate chemistry
  and air-sea fluxes. Found by Val Bennington and Galen McKinley
  (add DIC Option = WATERVAP_BUG to recover old results)
  update output of tutorial_global_oce_biogeo (fwd+AD) & tutorial_dic_adjoffline
o adding allowInteriorFreezing option to check for water below freezing point
  at depth and bring the negative heat anomaly to the surface level
o pkgs _fields_load:
  - extend GET_PERIODIC_INTERVAL to deal with non-periodic case (from pkg/rbcs)
  - use new S/R GET_PERIODIC_INTERVAL in pkgs:
    bulk_force, cheapaml, cfc, dic, obcs (+ ctrl/ctrl_get_gen_rec), offline and
    rbcs to get interpolation weights and time reccord number.
  - fix multi-threading in aim_fields_load.F
  - apply EXCH to temp arrays [0,1] after reading in dic_fields_load.F
o external_fields_load:
  new S/R GET_PERIODIC_INTERVAL to calculate which time-record (and linear
   interpolation weights) to use in a periodic time-series ; do not divide by
   time-step to convert to integer:
   - this fixes case where externForcingPeriod is not multiple of time-step
      (Thanks to Christopher L. Wolfe)
   - this fixes case where externForcingPeriod is an odd multiple of time-step
     (was wrong by half of time-step); update results of tutorial_global_oce_in_p.
  store index of time-record which is currently loaded:
   - works without any assumption on sequence of calls to EXTERNAL_FIELDS_LOAD ;
   - needed for the adjoint but not yet used because of extensive recomputations;
     (to be fixed soon)

checkpoint62v (2011/04/02)
o verification/1D_ocean_ice_column added to test Ian Fenty's
  pkg/seaice_growth.F modifications for improving sea ice code differentiability
o update output of exp4, internal_wave, seaice_obcs, tutorial_plume_on_slope
  (new velocity statistics after changing maskInW & maskInS definition)
o pkg/generic_advdiff with OBCS:
  use maksInW & maskInS in advective flux and in biharmonic diffusion calculation:
  equivalent to assumption of no tracer gradient outside the OB region.
  This will affect the results if using obcs+biharmonic diffusion.
  update output_adm.txt of experiment bottom_ctrl_5x5 (not expected since no obc)
o pkg/obcs:
  change definition of maskInW & maskInS: leave OB edges inside (maskIn=1)
  (e.g., maskInW(OB_Ie)=1 ) so that velocity normal-component at OB is still
  in Interior region. No impact on solution but affects Velocity monitor stats.
o pkg/ptracers (adjoint)
  New option AUTODIFF_PTRACERS_SPLIT_FILES for writing separate
  tape file for each tracer
o model/inc/src and pkg/autodiff: add parameters that allow to turn
  of parts of the adjoint code at run time. For now, there are only
  useKPPinAdMode, useGMrediInAdMode, and useSEAICEinAdMode. These
  parameters are set in data.pkg.
  This is the lazy coward's version of doing this, but still useful for
  debugging. In order to do it right, everything needs to be moved to
  pkg/autodiff.
o pkg/autodiff: fix global_sum_tile_ad.F by resetting adsumPhi at
  the end; this fixes the adjoint balancing code for open boundaries.
o pkg/ctrl:
  - change behavior of xx_${varname}period to be analogous to exf-conventions:
    xx_${varname}period =   0.,  means time-independent control part
    xx_${varname}period = -12., means one-year-periodic monthly control part
  - introduce helper routine ctrl_init_rec (part of ctrl_init.F) to
    clean up ctrl_init a little, remove unused variables
  - ctrl_init: fixed the handling of the start/endrec for obcs-variables
  - move "call cal_GetMonthsRec" from s/r ctrl_get_gen to s/r ctrl_get_gen_rec

checkpoint62u (2011/03/15)
o model/src:
  - for the adjoint, change NonLin-FreeSurf initialisation sequence: fill-in
    h0Fac from INITIALISE_FIXED and reset hFac to h0Fac in INITIALISE_VARIA ;
  - in initialise_varia.F (except for ALLOW_DEPTH_CONTROL) remove 2nd call to
    INI_DEPTHS, INI_MASKS_ETC & INI_LINEAR_PHISURF.
o pkg/ctrl/obcs/ecco:
  - remove obsolete, unused, and partially broken code:
    ctrl_obcsvol/ctrl_obcsbal/ctrl_volflux and code within
    ALLOW_CTRL_OBCS_BALANCE
  - put a stop statement into ecco/cost_obcsvol.F, but also add
    cost_obcsvol to ecco_ad_diff.list
o pkg/ecco: fix counting cost function contributions for obcs (code
  by Matt M.) and diffkr for diagnostics
o pkg/ecco, pkg/ctrl, pkg/grdchk:
  add cost penalty terms for initial uvel, vvel, eta controls
  and I/O for prior error files
o pkg/mdsio:
   move mds_check4file.F from eesupp/src to mdsio_check4file.F ; add option
   (new argument) to check for tiled file in mdsioLocalDir : this fix the
   restart from pickup_som , pickup_dic (& dic_co2atm) with mdsioLocalDir.
o pkg/ctrl:
 - ctrl_obcsbal.F, ctrl_obcsvol.F: replace last calls of ctrl_getrec by
   ctrl_get_gen_rec, put a stop statement into ctrl_getrec. Remove
   unused and superfluous variables
 - ctrl_get_gen_rec.F: catch the case of xx_genperiod=0.
o pkg/ecco
 - enable adjoint of Stevens OB
o pkg/ctrl/ecco/grdchk:
  - remove global declaration of tmpfldx/yz and tmpfldx/yz2.
    Fortunately, we do not have any tests for the numerous cpp-flagged
    option of "obcs as control parameters" so we will never know
    if this is an improvement (but at least now things compile).
  - remove an obsolete initialization from ecco_cost_init_barfiles.F
  - fix some problems within never used ifdefs to make the code compile
o pkg/obcs:
 - Refine Interior mask definition to work with more complex OB (e.g.
   if OB_Ie < OB_Iw); In case default setting is not sufficient, allows to
   read in Interior mask from file. Check if Interior mask is consistent
   with OB list of indices.
o pkg/seaice
 - beginning code for a seaice tracer package,
   but currently only used for seaice age: SEAICE_AGE
   SEAICE_num = 4
   iTracer = 1: area-weighted ice age
           = 2: volume-weighted ice age
           = 3, 4: template for one-year vs. multi-year ice
   data.seaice has new namelist SEAICE_PARM03 for arrays related to
   SEAICE_num

checkpoint62t (2011/03/05)
o pkg/obcs:
 - obcs_apply_uv.F: change to a 2 steps method, first tangential component;
   then normal component. This ensures that the normal component is set
   correctly even when it conficts with tangential setting from an other OB.
   Affects results of test-experiment seaice_obcs: update the output.txt
o pkg/obcs:
 - add code to monitor statistics of dynamical fields at OB.
 - take OBCS_BALANCE code out of obcs_calc.F into new S/R OBCS_BALANCE_FLOW :
   - fix to OBCS_BALANCE code (right hFac ; deal with simple OB intersection).
   - change default: balance the Net inflow through all OB (instead of balancing
     each OB separately); keep the old method if setting OBC_balanceFacX < 0.
 - switch on useOBCSbalance in dome experiment: only correct Western OB outflow
   to match Nortern OB inflow (OBCS_balanceFacN=0).
o pkg/seaice:
 - redefined actual sea ice age to be ICEAGE/HEFF ifdef SEAICE_AGE_VOL
o pkg/seaice (seaice_growth v 1.113):
 - reverting seaice_growth to v 1.111 in order to have code with exact bit
   compatibility with MITgcm_contrib/ifenty/Fenty_seaice_thermo_code_merge
   CPP option SEAICE_OCN_MELT_ACT_ON_AREA removed in v 1.112 is reintroduced
   runtime flag SEAICEareaFormula is kept but is inactive
o model/src:
 - add new param to scale curvilinear grid distance and area when using
   a different sphere radius from the grid-files.
 - test/check multi-threads EXCH applied to local variable (cg2d_x)
o adjoint:
 - enable adjoint of Stevens OB
 - add dummy_in_dynamics to enable extraction of ADJrhoinsitu
   (a bit delicate because of potentially modified adj. common block structure;
   current switch is ALLOW_AUTODIFF_MONITOR_DIAG, could be changed later)

checkpoint62s (2011/02/15)
o pkg/seaice (seaice_growth v 1.112):
 - introduce SEAICEareaFormula run time parameter, which selects the recipe for
   computing the ice cover tendency from effective thickness tendencies. Include
   Ian Fenty's formula.
 - remove 'undef SEAICE_OCN_MELT_ACT_ON_AREA' which may now be achieved using
   SEAICEareaFormula.
 - simplify notations for the various d_HEFF/d_AREA terms.
o pkg/gmredi:
 - add Boundary-Value-Problem bolus transport (Ferrari etal, OM 2010) code
   from Christopher Wolfe (UCSD); add partial cell factor in vertical derivative;
   add a verification test-run (front_relax.bvp) to test GM_useBVP.
o pkg/seaice (seaice_growth v 1.111):
 - for SEAICE_DO_OPEN_WATER_GROWTH, replace Gael's implementation with Ian's.
 - the new SEAICE_DO_OPEN_WATER_MELT allows open-water air-sea heat fluxes to
   also melt ice.
o pkg/seaice:
 - McPhee formula for Ice-Ocean fluxes (provided by Ian Fenty).
 - can be used by #define MCPHEE_OCEAN_ICE_HEAT_FLUX in SEAICE_OPTIONS.h
o pkg/cheapaml:
 - from Nico Wienders: New version of this package.
o pkg/flt:
 - add CPP options to prevent floats to re-enter the opposite side of
   a periodic domain (default: keep periodicity)
o pkg/gmredi:
 - apply exchange to GM_PsiX,GM_PsiY to get valid values near CS-corners
   (needed for multi-dim advection).
 - switch on GM Advective form in global_ocean.cs32x15 and update output.txt
o model/src:
 - fix wrong re-setting of addMass array (ALLOW_ADDFLUID) for atmospheric run.
o tutorial_tracer_adjsens
 - extend to NLFS and replace maskC by hFacC
   (change reference output accordingly)

checkpoint62r (2011/01/24)
o testreport:
 - add option -deloutp (-do) to remove output file after successful run
 - add option -mfile (-mf) for MPI machile-file and for each test-exp,
   extract exact list of procs from this file ; adjust COMMAND by
   replacing TR_MFILE & TR_NPROC with local machile-file & Nb of MPI procs.
o pkg/ecco: replace old ineffective way of penalizing deviations from
  first guess (of obcs) with code by Matt Mazloff
o pkg/ctrl: add code that allows the use of ALLOW_OBCS?_CONTROL without
  exf/cal
  - ctrl_init: fix initialisation (computation of diffrec) for obcs-ctrl
    and handle case of obcs?period == 0
    Not affected by these changes: There is still an inconsistency in
    the computation of start/endrec for the obcs variables for ALLOW_CAL
    defined (see comment by Menemenlis, 7-Mar-2003)
  - make S/R ctrl_get_gen_rec return something meaningful even if
    ALLOW_CAL is not defined
  - ctrl_getobcs?: simplify code so that it does not need to use
                   S/R exf_swapfields
o testreport:
   allow to test MPI with different number of processors for each experiment:
   create file "SIZE.h.mpi" in each build dir.
   Note: update of "-command" argument not yet implemented.
o model/src, pkg/autodiff, pkg/ecco, pkg/seaice:
  alleviate the need for additional 3D tapes when using
  the non-inear free surface in the adjoint. This is done
  by adding an 'update' of hfacc etc. to their current
  value at the beginning of forward_step.F.
o pkg/seaice
  seaice_lsr: move stress-divergence computations out of outer pseudo-
  timestepping loop
o pkg/obcs/obcs_prescribe_read.F: move 'CALL OBCS_EXTERNAL_FIELDS_LOAD'
  up, so that the calls of the ctrl_* subroutines are really at the end
  of the routine.
o pkg/gmredi:
  allow to specify a 2-D horizontal map and a 1-D vertical profil
  as scaling factor for Isopycnal diffusivity (Redi) and GM diffusivity.
o pkg/seaice:
  move lsr iterations from seaice_dynsolver to seaice_lsr.
o pkg/seaice:
  reduce memory footprint of seaice mutldim advection tapes,
  by using a 2D tape independent of the generic_advdiff ones,
  and setting GAD_AREA=1 etc. rather than GAD_AREA=101 etc.

checkpoint62q (2010/12/29)
o model/src:
  - check horizontal grid-spacing for unset or zero/negative values.
  - change AD test hs94.1x64x5 to be truly a 2-D set-up.
o pkg/flt:
  - use (recent) mdsio S/R MDS_READVEC_LOC instead of local FLT_MDSREADVECTOR
  - precision of input and output files set according to readBinaryPrec
    and writeBinaryPrec (previously always 64.b), pickup remains at 64 bits.
  - initial float position from tiled file was not converted to index space
    (looks like a bug): fixed to make it similar to initial pos. global file.
o global_ocean.cs32x15:
   change SIZE.h of AD set-up to get same tiling as with MPI.
   Update output_adm, output_adm.thsice (pass@14) & output_adm.seaice (fail@11)
o model/src:
   add flag to control printing of domain fields (bathymetry, hFac ...) in
   ini_mask_etc (call to plot_fieds_xy*).
o pkg/thsice:
   if useEXF, some forcing fields are not valid in overlap: fixed by computing
   over the interior only + apply EXCH at the end (like with SEAICE advection).
o pkg/mdsio:
  - add 2 arguments to S/R MDS_PASS_R4/8toRL/S for overlap size of buffer
    to copy to/from, so that it can be used to replace MDS_PASS_WH_R8toRL/RS.
  - change barrier call for safe multi-threads access to 3-D shared buffer.
  - MDS_READ/WRITEVEC_LOC use buffers from MDSIO_BUFF_3D.h (instead of local ones)
  - replace call to MDS_PASS_WH_R4/8toRL with call to MDS_PASS_R4/8toRL and
    remove the 4 S/R MDS_PASS_WH_R4/8toRL/S.
o pkg/flt:
  - add fourth-order Runge-Kutta integration
  - add basic exch2 support (only 1 facet supported so far!)
o pkg/mdsio+rw:
  new S/R to read local (or tile independent) vector (read counterpart of
   mds_writevec_loc, and front-end write_glvec_rl/rs).
o global_ocean.cs32x15: additional input_ad.seaice experiment
    that uses pkg/seaice rather than pkg/thsice.
    (using multidim advection for seaice)
o towards more F95 syntax for array specification in namelist:
  - change "data.diagnostics" (data.ptracers was changed before checkpoint62p)
    of all verification experiments.
       e.g.:    line: fields(1,3)='ETAN    ','ETANSQ  ',
      was changed to: fields(1:2,3)='ETAN    ','ETANSQ  ',
  - finish adding "-DNML_EXTENDED_F77" to DEFINES list in pgf77 and g77 optfiles
o global_ocean.cs32x15: additional input.seaice experiment
    that uses pkg/seaice rather than pkg/thsice.

checkpoint62p (2010/12/17)
o pkg/thsice: rename (ad tape index) iicekey as ticekey, and move it
    to THSICE_SIZE.h to avoid conflict with pkg/seaice.
o pkg/seaice: add seaice_diffusion.f seaice_map_thsice.f to adjoint.
    allow for use of multim. advection in seaice adjoint.
o pkg/seaice: add diagnostics for snow precipitation and sublimation flux
  - first attempt to close budgets by taking into account the freshwater
    flux implied by the sublimation of snow and ice. So far only the
    volume budget is closed, turn on with soon-to-be-retired-again CPP-Flag
    SEAICE_ADD_SUBLIMATION_TO_FWBUDGET
o eesupp/src:
  new S/R with new option (NML_EXTENDED_F77) to change array specification
  from F95 standard to commonly accepted extended F77 form.
  This would allow to use F95 syntax in namelist (needed with gfortran 4.4.5)
  and to revert back to the original syntax (with -DNML_EXTENDED_F77)
  for less tolerant f77 compiler (e.g., pgf77, g77).
o globalFiles:
  commented out in parameter file "data" since it's not safe with MPI
  (e.g., wrong on aces); keep it if useSingleCpuIO=T (but not doing much
  in this case); no longer commented out in restart test (tst_2+2).
o add adTapeDir to specify a special directory where adjoint tapes are
  written/read (adread_adwrite.F). adTapeDir is specified in data/PARM05
  and cannot be used together with mdsioLocalDir.
o nesting pkgs:
  - packages_init_variables : put call to OBCS_INIT_VARIABLES in last position
  - update Gianmaria's Nesting pkgs (from Contrib/nesting_sannino)
  - add parameter files + utils dir + output from short run on beagle.
o pkg/seaice:
    fix seaice_growth.F store directives; update results of exp. lab_sea.ad
o pkg/seaice: explicitly store tsurfloc in seaice_solve4temp.F to avoid
  unnecessary copying in adjoint code, requires new parameter NMAX_ITER

checkpoint62o (2010/11/25)
o pkg/exf:
  - change CPP option EXF_VERBOSE to run-time logical param exf_verbose.
o pkg/seaice:
  - seaice_ocean_stress: split a loop for better vectorization of the
    adjoint code
  - seaice_growth.F: fix bug in conservation of freshwater connected to
    capping of heff, put contribution into d_HEFFbyNEG
  - replace irritating parameters SEAICE_latentWater/Ice and SEAICE_sensHeat
    by something more sensible (parameters that are what their name implies)
  - change some defaults, so that by default exf-parameters are used for
    things like rhoAir, cpAir,latent/sensible heat parameters, in order
    to reproduce the old results, many data.seaice now contain funny values
    for cpAir and latent heat of sublimation
o packages_readparms.F: move exf_readparms up in line so that
    exf-parameters are visible for other packages (e.g. seaice)
o debugMode & debugLevel=2:
  - differentiate between debugMode & debugLevel=2:
    debugMode: controls printing of debug messages (sequence of S/R calls).
    debugLevel: controls printing of algorithm intermediate results and stats.
  - remove "if debugLevel=2 => debugMode" but keep "debugMode =>  debugLevel=2";
    => allows to print debug-stats without all sequence of call messages.
  - switch control of debug print from debugLevel to debugMode in many S/R.
o pkg/obcs (obcs-sponge):
    fix bug that was introduced on Oct 25 (in dynamics.F v1.151): put back the
    call to OBCS_PRESCRIBE_EXCHANGES (need to exch gU,gV when using obcs-sponge)
o pkg/generic_advdiff:
  - record overlap minimum size for each advection scheme;
  - refine criteria on overlap minimum size;
  - check and stop (in gad_check) if overlap size is too small.
o pkg/obcs:
  - with ptracers: remove multiple calls to obcs_apply_ptracer (only done
    once, in ptracers_implicit.F)
  - with seaice: remove test on empty file name in obcs_apply_seaice (always
    apply OB values when tile has OB)
o model/src, coriolis setting:
  - integer parameter "selectCoriMap" (=0,1,2) replaces 3 logical
    useConstantF, useBetaPlaneF, useSphereF ; can now read coriolis from
    files (selectCoriMap=3) with any grid.
  - add parameter "fPrime" for constant second Coriolis coeff (default=0).
o pkg/seaice/seaice_growth.F:
    a few cosmetic changes that reduce the number of lines of code
o pkg/obcs: add boundary conditions following Stevens (1990)
  - the code follows old MOM/NAOSIM code
  - so far it is only implemented for the eastern and western boundaries
    and NOT for pTracers
o pkg/rbcs:
  - replace rbcsInIter by rbcsForcingOffset, the time in seconds at the
    beginning of the first rbcs forcing period.
  - add option rbcsSingleTimeFiles that makes rbcs read forcing data like the
    offline package, i.e., one file per time, labeled by iteration number;
    deltaTrbcs sets the timestep with which the data was generated;
    rbcsIter0 is the forcing iteration corresponding to rbcsForcingOffset.
  - rbcsForcingCycle=0 makes forcing non-cyclic.
  - make arithmetic safe for negative times and odd forcing periods.

checkpoint62n (2010/11/09)
o pkg/seaice:
    fix masking in free-drift S/R ; update results of exp. lab_sea.fd
o pkg/obcs:
   New S/R to copy tracer value from the OB location to narrow band region
    (width = same as overlap) beyond the OB: preserve OB value (needed for
    high-order scheme) which were overwritten by EXCH call if in overlap
    region. Applied to theta, salt, ptracer and advected seaice variables.
   With seaice: use maskInC in similar way as in gad_advection.F,
    in seaice_advection.F and advect.F.
   Update output of experiment seaice_obcs and change exp4 to test OBCS with
    4th order Adv.Scheme. for pasive salt and ptracer.
o tools/genmake2:
  - when looking for an optfile (not specified), only search for Fortran compiler
    (remove sym-link test + setting of CPP + makedepend check + C-compiler check)
  - in get_fortran_c_namemangling: use "$CC $CFLAG" to compile C test programm
    (instead of "$MAKE genmake_test.o" since an existing Makefile can be wrong)
  - set default for CPP to "cpp -traditional -P" (was the case without specifying
    an optfile, but otherwise default was just "cpp".
  - comment out PLATFORM=$p_PLATFORM (no idea where p_PLATFORM comes from)
  - when "CC" is not set in the optfile, look for possible C compiler
    (instead of just setting CC=cc)
  - put back version v.169 modif (from 2008/02/15), was dropped in v.173 changes:
    => add a ".F" to ".o" rule for source files with no "#include" (such as
       port_rand.F); otherwise, default ignores FOPTIM and just uses FFLAGS.
  - move gfortran before g77 in list of possible Fortran compiler (consistent
    with reference compiler switch from g77 to gfortran)
o pkg/seaice:
  o remove SEAICE_OLD_AND_BAD_DISCRETIZATION-code, add a test to
    seaice_check that stops the model, when the CPP flag is used.
  o seaice_growth.F: make capping of ice volume conserving by returning the
    capped ice as freshwater to EmPmR. This does not change the verification
    experiments but will change runs where the capping is acutally active
o change reference platform+compiler from faulks+g77 to baudelaire+gfortran
  (except the 2 fizhi test exp.); update output of exp.: bottom_ctrl_5x5,
     global_ocean.cs32x15 (icedyn, thsice, AD thsice), global_ocean_ebm (AD),
     lab_sea (fd, hb87, salt_plume), MLAdjust (3/5) and vermix (dd)
o tools/genmake2:
  - merge genmake_warnings & genmake_errors into 1 log file: "genmake.log")
  - change DUMPSTATE default to false (can use "-ds" option to switch it to T)
  - clean previous genmake log files before anything else.
  - change Makefile to remove testreport log files (*.tr_log) and genmake log
    files only with "CLEAN" target (instead of "Clean");
o pkg/generic_advdiff:
  Change OBCS in multiDim advection (gad_advection.F):
   Use maskInC to prevent intermediate update of tracer-field in OB regions,
   thus keeping current-time-step OB values; and remove the call to OBCS_APPLY
   which were applying future time-step OB values.
  This way, all explicit calculations use current-time-step OB values
   (simpler and more consistent).
  Affects results when set-up uses time-varying OBC and multi-dim advection;
   update output of experiment seaice_obcs.
o pkg/seaice:
  move OPTIONS (formerly locally defined) to SEAICE_OPTIONS.h:
   this includes SEAICE_GROWTH_LEGACY (+ SEAICE_DO_OPEN_WATER_GROWTH &
     SEAICE_OCN_MELT_ACT_ON_AREA ) and SEAICE_SOLVE4TEMP_LEGACY.
  Default (pkg/seaice/SEAICE_OPTIONS.h) is to define SEAICE_SOLVE4TEMP_LEGACY
   but leave SEAICE_GROWTH_LEGACY undef ; For now, keep verification exp
   unchanged (SEAICE_GROWTH_LEGACY defined in */code*/SEAICE_OPTIONS.h)
o pkg aim (2010/10/26):
  - Introduce ALLOW_INSOLATION, moving toward a more general incoming solar radiation
    formulation with obliquity, eccentricity, ... as run-time parameters,
  - Introduce diagnostics for top-of-the-atmaophere incoming solar radiation and
    upward shortwave radition at the surface (all-sky and clear-sky).
o pkg/obcs:
  - writing sections with globalFiles=T does not work: switch to tiled-files
    when writing sections for OBCS (change pkg/rw/write_rec.F accordingly).
  - fix index bug (OB_Ie -> OB_Iw_) in obcs_apply_uvice.F
  - apply OBCS_SEAICE_COMPUTE_UVICE to both uice and vice at all obcs

checkpoint62m (2010/10/21)
o pkg/seaice: vectorize seaice_solve4temp.F
  - move iterations loops outside of i/j-loops
  - requires 2D arrays for TB and effConduct
  - add 2D iceOrNot to replace HICE_ACTUAL.GT.0, as HICE_ACTUAL is
    modified in this routine
  - a little bit of clean up, adjusting indentation, etc.
  - replaced a few TEN**a by exp(a*log(10.)) in new code for better
    performance and '**TWO' by '**2' (because TWO is a float),
    replaced ONE, ZERO
o eesupp/src:
   fix flow dir for exch1_z_RX_cube, exch1_uv_RX_cube & exch1_bg_RX_cube
o pkg/seaice/seaice_growth.F
  Revision 1.89 of seaice_growth.F completes the overall october 2010 revision and
  merging process. The merged routine has two branches, and one activates the 'evolution'
  branch by setting SEAICE_GROWTH_LEGACY to undef (at the top of the routine for now).
  In summary, here is what the '10/10 revision' did consist of
    part 1: seaice_growth.F revisions 1.71 to 1.75
      - Preliminary seaice_growth.F clean-up, keeping test results strictly unchanged.
        The emphasis here was on improving readability (e.g. by trying to use meaningful
        variable names) and modularity (e.g. by adding arrays to store heff etc. updates).
    part 1.5:
      - revising the lab_sea experiment to make it a more useful (i.e. stable
        and representative of an actual model run). This was done by generating a
        (winter) pickup to start from, switching back the main experiment dynamic
        solver from evp to lsr, having one of the experiments use the free drift solution.
    part 2: seaice_growth.F revisions 1.76 to 1.85
      - Sorting out hard-coded constants that prevented heat and fresh water conservation.
      - Sorting out the various fields units and sign (set early on and reset at the end)
        to avoid numerous scalings/re-scalings. By v1.85 the basic unit for ice, heat and
        fresh water stock is 'effective ice meters', and >0 implies more ice/snow.
      - Using tendency terms arrays (d_HEFF* etc.) to alleviate remaining code locks,
        and simplifying logical expressions to further improve readibility.
    part 3: seaice_growth.F revisions 1.86 to 1.89
      - Re-organize the blocks of code more logically.
      - Merging the '_if.F' pieces that add something new.
o pkg/thsice:
  - vectorize thsice_solve4temp and thsice_get_exf.
    Problem: thsice_solve4temp has an unvectorizable statement that
    might also be problematic for TAF
  - thsice_get_exf: add the ALLOW_BULK_LARGEYEAGER04 CPP-flag. This
    does not change the verifcation experiment, but will change all
    experiments that have this flag undefined (not tested in verification);
    a little reorganization to save a few 2D fields and recomputations
  - 1st step of revisiting thsice adjoint (major recomp. sorted out)
  - 2nd step:  fix some store dirs
    o seems to work somewhat, i.e. using ifort but not g77
    o likely cause are incomplete init. or recomputation
    o start verification/global_ocean.cs32x15/input_ad.thsice
o pkg/obcs: add support for exch2
  - the position of the boundary and prescribed values are specified using
    a global domain with exch2 facets stacked
    - in x for N,S boundaries (like W2_mapIO=-1)
    - in y for E,W boundaries (so E,W boundaries do not overlap)
o pkg/mdsio: add support for writing global sections with exch2
    file layout is as for obcs described above:
    - for x-z sections, facets are stacked in x (like W2_mapIO=-1)
    - for y-z sections, facets are stacked in y
o pkg/thsice:
   - change a few routines for better vectorization: thsice_albedo.F,
     thsice_step_temp.F, and in thsice_calc_thickn.F. Results are
     not affected, but in particular the latter routine has changed
     dramatically (not necessarily easier to read now).
   - re-arrange calculation in THSICE_SOLVE4TEMP: move outside of i,j loops
   iteration loop and call to S/R THSICE_GET_BULKF & THSICE_GET_EXF.
o verification/lab_sea:
  - overhaul of the forward model experiments. The main motivation
    for this revision is that lab_sea has proven quite fragile (when
    changing the sea-ice code, and switching platforms) to a point
    when failures were very hard to attribute to specific code problems.
  - the suspected reason for this fragility is noise amplification by evp so,
    to start with, we decided to replace evp with lsr in the main experiment.
  - the input.lsr experiment thus became obsolete and was removed.
  - it was replaced with the input.fd experiment that uses an
    analytical "free drift" solution as the ice velocity field.
  - Taken together, input (lsr), input.fd (free drift) and input.hb87 (evp)
    will hopefully allow us to discriminate problems due to dynamic solvers
    from problems due to the thermodynamic code. input.salt_plume (lsr) allows
    us to test additional options, along with the salt plume package.
  - Finally a pickup was generated (at the end of a one year run) to
    make the tests more representative of an actual model run. Previously
    the tests starting point was a 1m thickness of ice everywhere.
o pkg/seaice:
  - introducing S\R seaice_freedrift.F that compute the
    analytical solution to an approximate ice momentum
    equation (i.e. the simple stress/coriolis balance).
  - define SEAICE_ALLOW_FREEDRIFT to trigger the computation
    of the free drift velocity field, and enable its use.
    To actually use the free drift solution as the model ice
    velocity field set SEAICEuseFREEDRIFT to .TRUE. in data.seaice.
o move "useOASIS" from PARAMS.h to EEPARAMS.h and read it from "eedata"

checkpoint62l (2010/10/04)
o pkg/seaice:
  -fix the USE_ORIGINAL_SBI version (for variable freezing point);
  -use "celsius2K" in SEAICE_VARIABLE_FREEZING_POINT and in new
   version (with USE_ORIGINAL_SBI undef);
o add hooks for new packages OASIS, the package will follow
  (hooks exclude the seaice pkg for now)
o pkg/autodiff: ALLOW_AUTODIFF_WHTAPEIO
  Option to use mdsio_read_whalos.F/mdsio_write_whalos.F,
  rather than mdsio_readvector.F/mdsio_writevector.F, within
  adread_adwrite.F to read/write adjoint-related tapes to disk.
o eesupp and pkg/mdsio: ALLOW_WHIO
  Option to write/read 2D fields to files including tiles halos.
  The main purpose is for adjoint related "tape I/O".
  The secondary purpose is for debugging phases.
  A word on those rather specifically intended purposes.
  The code was meant to be stripped down to the bare minimum.
  Typically, there is a unique and basic mapping to the global
  buffer (tile by tile, then proc by proc, then level by level), and
  byteswaps and meta-files are omitted. Indeed the (*_WH*) code is not
  meant to generate user friendly outputs of various shapes and forms.
  Rather it is intended, for the knowledgeabale developers,
  to be largely independent of the many mdsio options, to allow
  outputs of tiles+halos in debugging phases and in adjoint runs,
  and to allow some flexibility in tuning (adoint) I/O depending on each
  file system behavior. With regard to tuning, most of the potential knobs
  (to leave files open, to allocate the I/O indep. of usesinglecpuio,
  to specify directories, to specify the typical size of I/O calls, etc.)
  are not yet included, and will be added if they prove useful.
o pkg/seaice:
   fix uninitialised arrays in USE_ORIGINAL_SBI version of seaice_solve4temp.F
o pkg/seaice:
   new S/R seaice_solve4temp.F: this is the merged version of Ian Fenty
   code (seaice_budget_ice_if.F) which enable to recover old standard
   code (seaice_budget_ice.F) when option USE_ORIGINAL_SBI is defined.
   temporary: add "#define USE_ORIGINAL_SBI" at the top of seaice_solve4temp.F.
o model/src (rStar):
   use simple average (not area weighted) of rStarFac at U,V point when using
   vectorInvariant and selectKEscheme=1,3 (consistent with mom. vertical advection)
   update output of exp. fizhi-cs-32x32x40 and fizhi-cs-aqualev20.

checkpoint62k (2010/09/17)
o adjoint
   * changed verification/global_ocean.cs32x15 ; adjoint now tests
     Adams-Bashforth 3 + NLFS + RSTAR
   * some more modifs required for ECCO-GODAE v4
o pkg/seaice
   add SEAICE_AGE_VOL option to use volume instead of area for
   integrating SEAICE_AGE
o model/src:
   first check-in of sigma & hybrid-sigma coordinate code ; also includes
   non-linear free-surface parts ; but pressure-gradient not yet coded.
o pkg/ptracers:
   option for ptracer to convert Salt Relax into additional EmP.
    tested in exp. global_ocean.90x40x15.dwnslp (update output)

checkpoint62j (2010/08/25)
o pkg/ggl90:
   other minor changes: remove 3-D temp array gTKE (+ add argument myIter)
o pkg/dic: car_flux.F, phos_flux.F
  - reduce number of exp-calls in order to improve performance
  - clean up a little (replace fields by their macros, etc., fix
    typo in CPP-flag)
o pkg/ggl90: minor changes
  - GGL90diffKrS was removed --> always use GGL90diffKr
  - GGL90viscAr was removed --> replaced with GGL90viscArU, GGL90viscArV
  - hack of mxlMaxFlag=2 --> ensure mixing between first and second level
    (commented out for now)
  - change in max/min operations to ensure that smoothing is ok
  - smoothing of GGL90viscAr was moved to ggl90_calc.F (as done for GGL90diffKr)
  - always use diffKrNrT as background profile (i.e. never use diffKr field)
o pkg/cfc: bug fix, AREA(i,j,1,bi,bj) -> AREA(i,j,bi,bj)
o pkg/dic:
  - model/src/impldiff.F: if TARGET_NEC_SX, extend loop ranges for better
    vectorization
  - small bug fix in insol for the unlikely case of a cartesian grid
  - towards vectorizing the dic package: bio_export.F, car_flux.F, phos_flux.F
    + now vectorize, which also removes adjoint recomputations;
    + replace integer maksp1 by _RL maskp1
    + replace a**x by exp(x*log(a)) in phos_flux.F for speed

checkpoint62i (2010/07/21)
o pkg/flt:
  - with OBCS: stop floats which enter the OB region
o model/src:
  - use tempVertAdvScheme & saltVertAdvScheme (instead of horizontal ones)
    for implicit vertical advection.
o pkg/seaice:
 - account for melting in seaice age evolution.
 - remove double counting of seaice ridging effect on seaice age.

checkpoint62h (2010/06/18)
o pkg/exch2:
 - remove exch2_*xy_rx files: call was replaced with exch2_*3d_rx(myNz=1).
o tools/genmake2
  - remove "-pdefault" option: redundant with the use of "packages.conf";
  - remove file pkg/pkg_default : set the default as a pkg group
    ("default_pkg_list") defined in pkg/pkg_groups;
  - fix for case pkg/pkg_depend is missing (was hanging before);
  - add option "-pgroups" to specify a different pkg_groups than the default.
o verification/adjustment.cs-32x32x1:
   add a "minimal" set-up test (code_min & input_min) which only compiles
   eesupp/src and the 2 pkgs (exch2 & debug) which don't need model/src & inc.
o tools/genmake2
  - extend pkg_depend rules to model & eesupp (e.g., if model depend on [pkg]))
  - fix details of checking for mnc & profile pkg when NetCDF is unavailable.
o pkg/exf: merge exf_bulk_largeyeager04 into exf_bulkformulae because these
  files are nearly the same anyway.
  Step 1: make exf_bulkformulae look like exf_bulk_largeyeager04:
   - redefinition of tau(i,i) (by a factor of ustar)
   - 1./exf(Const/T) -> exf(-Const/T) (big change in the results)
   - replace rhonil by rhoConstFresh in computation of evap (bug fix)
   - replace u/vstress=tau*rd*ws*cw by tau*rd*u/vwind (changes results)
   - replace
     rd(i,j)= rdn(i,j)/(exf_one - rdn(i,j)/karman*psimh )
     shn    = sh(i,j,bi,bj)*rd(i,j)/rdn(i,j)
     by
     shn    = sh(i,j,bi,bj)/(exf_one - rdn(i,j)/karman*psimh )
     (changes results)
   -> exf_bulkformulae v1.22,
      update verification experiments lab_sea, offline_exf_seaice, seaice_obcs
      (lab_sea: output.hb87.txt 1.11, output.lsr.txt 1.25, output.salt_plume.txt 1.13,
                output.txt 1.63
       offline_exf_seaice: output.seaicetd.txt 1.7
       seaice_obcs: output.txt 1.10)
  Step 2: do the actual merge and remove exf_bulk_largeyeager04.F
   -> exf_bulkformulae v1.23,
      unfortunately requires updating lab_sea.salt_plume (6 matching digits),
      and global_ocean.cs32x15.icedyn (only 11 matching digits)
  Also update output_adm of exp. lab_sea (all 4) and offline_exf_seaice.
o adjoint of exch-1:
 - pass high-level EXCH S/R through TAF (eesupp/src/exch_ad_diff.list)
   (note: was already like this when using EXCH-2) and remove flow dir
   and hand-written AD version of high-level EXCH S/R (pkg/autodiff);
 - provide flow-dir for low-level exch1 S/R (eesupp/src/exch1_ad.flow);
 - update pkg/exch2 diff list.

checkpoint62g (2010/05/19)
o eesupp/src (exch-1):
 - split exch_rx.F into Forward S/R (exch1_rx.F) and Adjoint S/R (exch1_rx_ad.F)
   and remove argument "simulationMode"; same thing for all exch_*rx_cube.F
   (renamed to exch1_*rx_cube.F).
 - change accordingly exch_*_rx.template and AD version in pkg/autodiff
   to call new exch1 S/R ; update Makefile and .cvsignore.
 - replace call to exch2_xy_rx S/R with exch2_*3d_rx(myNz=1) (will remove
   exch2_xy_rx later)
  Note: after updating your code, need to run "make clean" in eesupp/src
o test experiment bottom_ctrl_5x5:
   new output_adm.txt with fewer grdchk & less monitor output.
o model/src:
  remove the call to ini_cori in initialise_varia.F (just keep the usual one
   in initialise_fixed.F). More consistent with coriolis & horizontal grid
   beeing treated in the same way (ini_grid is not called a 2nd time).
o pkg/exf:
  - rewrite exf_bulk_largeyeager04.F for better vectorization, changes
  global_ocean.cs32x15/input.icedyn (11 digits of agreement), updated
  - fix adjoint (used worked for ALLOW_ATM_WIND defined, works for this now)
  - cosmetic changes to exf_bulkformulae.F to make it look more like
    exf_bulk_largeyeager04.F
o eesupp/src (exch-1):
  - Fix AD EXCH code for 2-D domain special cases (Nx=1 or Ny=1).
  - Separate buffer filling and MPI sending: allow EXCH-1 to work for local
    array (non-shared) when using MPI+MTH. Also reduces number of BARRIER
    (even without using MPI).
  - Message mode: move RecvAck setting (indicator of buffer being ready)
    from send_put to recv_get S/R (was useless before, but not sure if
    it's much more useful now);
  - Switch the order of sync: MPI-proc 1rst and then threads;
  - take out spin-waiting code (#undef EXCH_USE_SPINNING), use BARRIER instead.
  - fix AD code for communication mode ='get' (but not used).
o model/src:
  initialise dPhiHydX,dPhiHydY inside calc_grad_phi_hyd.F (so that TAF does
  not drop it in S/R mddynamics, producing NaN in hs94.1x64x5 AD-test exp).
o utils/matlab/rdmnc.m: adapt to be able to use the generic matlab netcdf API
o pkg/ctrl: require a specific set of control variables and exf-flags for
  adjoint of seaice (stop in ctrl_check.F if conditions are not satisfied)
o model/src:
 a) 1rst version of a new driver S/R to turn-off output freq and flags after the
   1rst forward sweep, to avoid over-writing output files during recomputations
   recomputations (& grdchk); called from cost_final.F (& ctrl_init_ctrlvar.F ?)
 b) 2nd version:
  - add specific pkg S/R for seaice & ptracers (called from S/R TURNOFF_MODEL_IO);
  - switch-off more output flags (exf_monFreq, chkPtFreq, dumpInitAndLast,
     writePickupAtEnd) + seaice & ptracers output;
  - do not switch off MNC flags (otherwise, won't get admonitor netcdf file)
o model/src:
  - new S/R rotate_uv2en_rl (..._rs) that rotates vector fields.
o pkg/exch2:
  - remove "simulationMode" from arg. list of S/R EXCH2_RX1,2_CUBE ;
  - add argument "signOption" to EXCH2_RX1_CUBE (will be needed for SM exch).
o pkg/autodiff & exch2:
  process exch_uv_agrid_3d_rx.f & exch2_uv_agrid_3d_rx.f through TAF
  (for now, only if ALLOW_EXCH2 is defined).
o pkg/autodiff:
  - include PACKAGES_CONFIG.h in exch*ad.flow & exch*ad.F
    (not supposed to be in CPP_OPTIONS.h) to get ALLOW_EXCH2 defined correctly.
   + clean-up comments (_RS is not always real*4)
  - fix bug in ADEXCH_UV_3D_RX (without EXCH2, was calling the forward exch S/R)
  - add a stop in ADEXCH_UV_AGRID_3D_RX if trying to use it with EXCH2:
    was calling a forward exch2, which is wrong ; used in SEAICE & EXF pkgs.
o testreport (AD-tests):
  no longer link files from dir "../input" (1rst link files from
  "../input_ad.[xx]" if secondary test "xx" and then from "../input_ad")

checkpoint62f (2010/04/29)
o model/src/the_main_loop.F:
  adjust store directives for seaice evp and multicategory according to
  pkg/ecco/the_main_loop.F
o adjoint:
  global_sum_ad was incomplete (noted many times by many people ;)
  nice description by Jean U. as follows:
  * allreduce(var) in global_sum.F can be interpreted as
    reduce(sum) followed by broadcast of sum.
  * The adjoint of that is
    sum(adjoint) followed by broadcast(summed adjoint value)
    or in other words, allreduce(sum, adjoint vars)
  We were missing the sum(adjoint)!
  Benign, except(!) for "global" scalars appearing in tile loops (bi,bj)
  (noted by J.M. Campin, e.g., in cost_ssh_mean, variable offset).
  The fix should produce 16-digit accuracy between
  single-CPU multi-tile (e.g. nSx=2, nPx=1) and
  multi-CPU single-tile (e.g. nSx=1, nPx-2)
  We'll probably change this yet again shortly
o eesupp/src:
  - fix global_sum_r4 (wrong from previous modif in Jun 2009; ever used ?)
o pkg/icefront
  - ALLOW_SUBGLACIAL_RUNOFF option adds capability for time-evolving
    specification of addmass array based on a 2D field, which is added
    at bottommost wet level at each horizontal location.
o model/src:
 horizontal grid initialisation (other than curvilinear): add code for Exch2 IO
 layout; (not always compatible with delX,delY setting; commented out for now).
o pkg/exch2:
 change tile to processor setting (case nSy*nPy > 1): allows default model mapping
 (myX and myYGlobalLow) to be used for simple (1 facet, no blank tile) config.

checkpoint62e (2010/04/15)
o pkg/obcs:
  - fix wrong index in OBCS_SPONGE_V for Eastern-OB (reported by David Hebert).
o pkg/dic:
  -fix bug in fe_chem.F for multi-tile (nSx*nSy > 1) set-up;
    (note: not presently tested in any forward verification exp.)
   update tutorial_global_oce_biogeo AD output file.
o pkg/exf:
  - account for the variation of albedo as a function of zenith angle
    by defining ALLOW_ZENITHANGLE in EXF_OPTIONS.h
o build_options:
 - rename "linux_ia64_ifort+mpi_ice_nas" to "linux_amd64_ifort+mpi_ice_nas"
o pkg/dic:
  change DIC atmos-CO2 box (method 3, dic_int1=3) initialisation & restart:
  - use binary pickup file for restart;
  - initialise atmos-CO2 box from dic_pCO2 parameter;
  - fix multi-threaded.
o pkg/rbcs:
 - clean-up RBCS code: add RBCS_OPTIONS.h file ; fix multi-threaded ;
   change (+ fix IO calls) type of array RBC_mask from _RL to _RS.
 - add RBCS to exp4 passive tracer 01 (rbcs was previously untested)
   and update output.txt
o pkg/kpp:
 - add diagnostics for KPP non-local flux of Temp, Salinity and pTracers;
 - change diagnostic of KPP non-local term: output average of KPPghat*KPPdiffKzS
   (= ratio of KPP non-local (salt) flux relative to surface-flux) when
   using pkg/timeave & pkg/diagnostics (diag 'KPPghatK' replaces 'KPPghat ');
 - change pkg/offline to read-in average KPPghat*KPPdiffKzS from file
   KPP_ghatKFile (instead of the average of KPPghat from file KPP_ghatFile).
o pkg/offline:
  fix bug in S/R OFFLINE_FIELDS_LOAD regarding surfaceForcing conversion factor
  (bug was added in version 1.10 on 2007-08-23).
o pkg/offline:
  - no need to specify periodicExternalForcing, etc ... to use offline pack
  - offline input files no longer just single prec --> parameter offlineLoadPrec
o verification/lab_sea:
  change AD test to multi-tile setup and update all 4 AD output.
  NOTE: while cost function values remain very similar,
  gradients are very different, although gradient checks are self-consistent
  Should try to get to the bottom of this (cost function summation order?)
o pkg/dic:
  in carbon_chem.F, replace log10 (AUTODIFF) with explicit form to avoid
  a weakness of TAF that drops part of double precision in log10 derivative.
  <= changes removed since problem has been fixed in current TAF version 1.9.71
  update AD output of exp. tutorial_dic_adjoffline & tutorial_global_oce_biogeo.
o pkg/ecco:
  add missing "_d 0" in cost_readers.F, cost_readtopex.F & cost_readtopexmean.F
  update all 4 lab_sea AD output.

checkpoint62d (2010/03/22)
o build_options:
  remove '-r8' (and '-i4') from linux_*pgf and linux_*ifort optfiles.
o remove unbalanced quote (single or double) in commented line of source code
  (may cause some warning with some preprocessor/makedepend versions).
o pkg/seaice:
  fix seaice_model.F for adjoint (gael) and update AD results of experiments
   lab_sea (std + evp + noseaicedyn) and offline_exf_seaice.
o testreport:
  add option '-runonly' (short: '-ro') to just do the run part (without make).
o eesupp: remove JAM communication code (obsolete).
o add option to genmake2 & testreport to switch "_RS" type to "real*4"
  (if allowed in CPP_EEOPTIONS.h); update default CPP_EEOPTIONS.h and return
  to default CPP_EEOPTIONS.h for exp. inverted_barometer & solid-body.cs-32x32x1
  (update also the output).

checkpoint62c (2010/03/02)
o tools/build_options :
   move (some) old optfiles from build_options/ to build_options/unsupported/
o model/src and pkg/exf
   surface relaxation -- separating data and data.exf options
   The point is to ensure that we specify the surface relaxation
   either in data or in data.exf (but not half and half) and to
   avoid an accidental relaxation to 0 (which happened if a time
   scale was specified but the file name was left empty)
o model/src model/inc and pkg/mom_common
   ALLOW_3D_VISCAH/ALLOW_3D_VISCA4 => 3D specification of Viscosity
   => addition to the viscosity field as computed by others schemes
o tools/build_options:
  - rename "_generic_mpi" -> "+mpi_generic" (like other "+mpi" optfile)
    but keep the former optfile for few weeks for smooth transition
o pkg/ecco
  - allow user defined cost function contributions
     CPP: ALLOW_USERCOST_CONTRIBUTION
     USAGE: compute contributions in cost_usercost_all.F
  - note: this is identical to what ALLOW_GENCOST_CONTRIBUTION once was.
      the two options are complementary.
o pkg/smooth
  - migration from contrib to the main repository

checkpoint62b (2010/01/26)
o pkg/monitor:
  - change back mon_printstats_rl.F & mon_stats_rl.F and add a stop
    (in case someone forgot to update customized pieces of code)
o nonHydrostatic:
  - add Non-hydrostatic free-surface form (selectNHfreeSurf=1)(not fully tested);
  - add a simple 2-D experiment (short_surf_wave) to test it.
o pkg/icefront:
   adding the shell of, and the hooks to, a new package that
   will model melting and freezing of vertical glacier ice fronts
o momentum:
  add diagnostics of momentum tendency from Hydrostatic pressure gradient
   (without surf.pressure term: would need a 2nd filling since implicit term).
o add 3 "_d 0"s so that fizhi compiles with xlf on iblade, and replace
  two " &end" by " &" (in fizhi-cs-*) because S/R NML_SET_TERMINATOR
  cannot deal with the former
o cleaning:
  - remove all (except OpenAD) old TLM output from results_ad dirs.
  - remove unused S/R (MDSWRITEMETA, DIAGNOSTICS_ADD2LIST, old DFILE IO S/R)
  - comment out maskH definition (replaced by maskInC)
o pkg/monitor:
  - change mon_printstats_rl.F & mon_stats_rl.F (were similar to mon_writestats_rl
    & mon_calc_stats_rl) to be the RL equivalent of mon_printstats_rs & mon_stats_rs.

checkpoint62a (2010/01/15)
o model/src:
  - bottom pressure diagnostic: correct for r* (when nonlinFreeSurf >= 4)
o pkg/diagnostics:
  - add optional level number diagnostics (i.e., level number to be define
    explictly with S/R DIAGNOSTICS_SETKLEV) with parser-code(10)="X".
  - strictly check for valid parser-code(10) ;
  - check if adding diag to the list from the right place.
o pkg/longstep:
  - change parameters and fix tracer conservation with rstar/nonlinear free surface
o diagnostics:
 - in all pkgs, replace remaining calls to old S/R DIAGNOSTICS_ADD2LIST with newer
   S/R DIAGNOSTICS_ADDTOLIST ; fix seaice VICE diagnostics.
o pkg/diagnostics:
 - Add option for writing vertical integral (sum of selected levels) of an output
    field instead of writing output field levels. Activate this option on a per
    output-file basis, by setting the 2nd character of fileflag to 'I'.
 - Add field-specific information relative to level integral in 3rd postion
    of parser diagnostics code (gdiag): " "=cumulate levels, "R"=integrate
    vertically (x level-thickness x hFac), "r"=same but without hFac.
o do_the_model_io:
  - pass end-of-model-run flag as argument, from forward_step to diagnostics_write:
    in case useSIGREG, will write (averaged) diagnostics (if dumpAtLast) before
    writing pickups and stopping.
o pkg/diagnostics (for now, only with mdsio):
  - write time information to meta file (and modify accordingly rdmds.m) :
    time-averaged diagnostics output: write starting and ending time of the
    time-averaging interval ; snap-shot diagnostics output remains unchanged;
o pkg/timeave:
  - S/R TIMEAVE_NORMALIZ: change size of cumulated-time array (was previously
    always Nr), now assumed to be equal to number of levels of averaged field;
    only used for DIC_COST monthly mean arrays: this fixes dic_aver_final.F
o pkg/sbo:
  - fix ocean bottom pressure global-average & 2-D time-ave output (was
    neither initialised nor filled).
  - add starting iteration in suffix of global-average output file
    (to avoid over-writing the file after a restart)
  - use standard MDSIO pkg S/R instead of SBO_WRITEVECTOR (fix byte-swap Pb).
o time-average:
  - use simple cumulative-time array (no k index) in all pkgs: {PKG}_timeAve(bi,bj)
    (pkgs: aim_v23, bulk_force, dic, gmredi, kpp, land, ocn_compon_interf,
     ggl90, my82, opps, pp81, ptracers, sbo, seaice, shelfice, thsice)
    this fix DIC_COST cumulative-time array (previously: bi,bj,k)
  - fix 1rst call (nIter0) snap-shot output and accumulation (pkg/shelfice)
  - fix missing accumulation for pkg/opps.
  - cumulate fields only if doing time-ave output ({PKG}_taveFreq > 0)
     (pkgs: ptracers, kpp, ocn_compon_interf, ggl90, my82, pp81);
  - fix initialisation of time-ave vars and do only full time-step increment
    (i.e.: no first & last "half time-step") (pkgs: ggl90, my82, opps, pp81);
o pkg/layers:
  - use standard RW pkg S/R to write the output
    and remove local write_fld version (which had a problem).
  - use simple cumulative-time array (no level index) to fix time-ave S/R calls.
  - fix LAYERS_CALC argument list.
o pkg/timeave:
  - store cumulative-time in a simple tiled array (drop the level index)
  - add new S/R (TIMEAVE_NORMALIZE) which uses simple cumulative-time array.
o pkg/ocn,aim_compon_interf
  - changes for multi-threaded coupled run. (tested with ifort-11 on danton)

checkpoint62  (2009/12/23)
o switch on useOBCSbalance in tutorial_plume_on_slope exp. and update output.
    (was not previously tested in any other exp.)
o pkg/monitor:
  - clean-up _RL/_RS version: add specific S/R for statistics with mask & volume:
    mon_writestats_rl/s,F mon_calc_stats_rl/s.F ; will keep the old one
    (mon_printstats_rl/s,F mon_stats_rl/s.F) just for bare statistics.
  - use hFac & 2-D mask (instead of 3-D mask + hFac in previous mon_stats_rl.F).
  - change del2 calculation.
  - use interior masks (instead of maskH, <- to be remove).
  - shorter monitor suffix for forcing stats ("forcing" instead of "extforcing").
o mask & obcs:
  - define 2-D "interior" masks (i.e., zero beyond OB) at 3 locations (C, W & S).
  - move global area computation from ini_masks_etc.F to ini_linear_phisurf.F
    (called after packages_init_fixed)
o pkg/obcs:
  - move bi,bj loops into obcs_calc, so obcs_prescribe_read is called only once.
    Fixes bug in obcs+exf with nSx*nSy.GT.1
  - fix multi-tile handling in obcs balance code
o nonHydrostatic:
  - Implement AB-3 for non-hydrostatic vertical momentum ;
    (change ordering of var. stored in pickup file when using NH)
  - move NH code from solve_for_pressure.F to 2 new S/R: PRE_CG3D & POST_CG3D.
  - add 2-D field to store Hydrostatic Surface Pressure adjusment from cg3d_x
    (in prep. for new NH free surface form).
o pkg/obcs:
  add files & OB-variables for wVel (Non-Hydrostatic) with useOBCSprescribe
o model/src:
  fix 2-D solver initialisation for deep-atmosphere (p-coord) with topography

checkpoint61z (2009/12/01)
o nonHydrostatic:
  Fix missing vertical flux of vert. momentum near surface (k=1). This fixes
    a spurious source of energy in simple baroclinic adjusment test case.
  Update all non-hydrostatic exp output.
o model/src (3-d solver):
  Change again 3-D solver free-surface RHS term when exactConserv=T:
    simpler, consistent with exactConserv, and works with implicDiv2Dflow < 1
    (which was not the case with previous formulation).
  To recover previous version, just reset "oldFreeSurfTerm" to previous value.
  Affects results of exp. global_ocean.cs32x15.viscA4 & hs94.cs-32x32x5.impIGW.
o nonHydrostatic:
  - compatible with implicDiv2Dflow < 1 ; + implement implicit factor
    for Non-Hydrostatic pressure gradient (similar to implicSurfPress).
  - change 3-D solver to work with r* (for now, only with linear free-surf.)
  - add few debug diagnostics (cg3d_x, residual)
o model/src:
  fix missing EmPmR in 3-D solver RHS (was in cg2d_b but missing in cg3d_b).
    update output of exp. global_ocean.cs32x15.viscA4
o update output of exp. global_ocean.cs32x15.icedyn after removing
  #define SEAICE_OLD_AND_BAD_DISCRETIZATION from SEAICE_OPTIONS.h
o add entry points for Gianmaria's Nesting pkgs (from Contrib/nesting_sannino)
o mnc: add horizontal grid coordinates (XC,YC) and (XG,YG) to netcdf output
  for complex grids, for now only to "state", "adstate", "adexf", "adseaice"
o model: add Christopher Wolfe's implemetation of the single reduction cg2d
  (d'Azevedo, Eijkhout, and Romine, 1999) with CPP-flag ALLOW_SRCG and
  runtime flag useSRCGSolver. Modify verification experiment global_with_exf
  to test this code
o pkg/cd_code:
  Change defaut D-grid time-stepping to get the same for D-grid momentum as for
   C-grid momentum. D-grid velocity used to be stepped forward in time with
   Adams-Bashforth only on surface pressure term. Tests show that using AB on
   D-grid coriolis term improves stability (as expected from CD-scheme paper).
  To reproduce old results, add 2 options (in CD_CODE_OPTIONS.h).
  Update results of exp: global_with_exf (x2), ideal_2D_oce, isomip (x2),
   lab_sea (3 Fwd +3 AD), natl_box (x2), tutorial_global_oce_biogeo (Fwd+AD),
   tutorial_global_oce_latlon, tutorial_global_oce_optim & tutorial_tracer_adjsens.
  Keep old results by adding CD_CODE_OPTIONS.h in exp: cfc_example, exp2,
       global_ocean.90x40x15(+AD), global_ocean_ebm(+AD) and OpenAD.
o pkg/obcs:
 - fix bug in initialisation (broken since Oct 1rst modification)
   for useOBCSprescribe without useEXF.

checkpoint61y (2009/11/15)
o pkg/seaice
 - change (once again) the discretization for the evp solver: rather than
   squaring the averages of strain rates, average the squares to give
   a better approximation to VP behavior (in simple test); this breaks
   verification experiments that use EVP (lab_sea and lab_sea.hb87)
    --> update outputs
o add CPP-flag (in mom_calc_visc.F) and TAF directive (in gmredi_slope_limit)
  to improve vectorization of adjoint code on TARGET_NEC_SX
o verification/vermix:
  - change vermix to a more "classical" 1d column with high vertical
    resolution, seasonal heat flux forcing and constant wind forcing
    --> update outputs
o pkg/seaice
 - fix diagnostics of principal stress components for EVP
 - add optional diagnostics of non-linear convergence for LSOR solver
 - make maximum zeta a runtime parameter
o model/src (3-d solver):
  Undo modif from Dec 12, 2005 (solve_for_pressure.F cvs version v.49),
   which consisted in removing the Surf. Non-Hydrostatic pressure from the
   whole column and adding it to Eta (inspired from Casualli, 1999):
   Only affects 3-D solver initial guess and only if using ExactConserv,
   but tests did show a degradation of solver convergence. For this reason,
   decide to disable this piece of code.
   to recover previous version, just set zeroPsNH = exactConserv (line 78).
  Update output of exp. global_ocean.cs32x15.viscA4 & hs94.cs-32x32x5.impIGW
o pkg/ggl90:
 - fix previous modif (unfortunatly has not been documented here).
o pkg/seaice/autodiff:
 - add CPP flag to include clipping of zeta in EVP code;
   although clipping of zeta is not necessary for EVP and not recommended
   it was done by default, now clipping is disabled by default
 - modify computation and store zetaC/Z in seaice_evp for TAF
 - add CPP-flag SEAICE_ALLOW_CLIPVELS (undefined by default)
 - change seaice_calc_viscosities/strainrates for better
   vectorization after AD by TAF
 - rearrange common blocks in SEAICE.h once again for easier dumps of
   adjoint output, adjust adcommon.h and g_common.h
 - change flux form of default advection scheme for better vectorization
   of adjoint code
 - modify lab_sea/input.lsr to test the flux form of default advection
   scheme
o autodiff: fix seaice fields in g_common.h (left over from 3 to 1 level
  transition in checkpoint61r)

checkpoint61x (2009/10/19)
o adjoint: adding two new verification experiments
  * tutorial_global_biogeo: an online dic sensitivity experiment
    (work with G. Forget)
  * tutorial_dic_adjoffline: an offline dic sensitivity experiment
    (an update of the Dutkiewicz et al., 2006 paper)
  Both use the same CO2FLUX cost function, but different controls
  Gradient checks look good, but some recomp. could still be traightened out
  Should add xx_dic control variable to test at some point
o model/src:
  add run-time parameters to check and/or mask initial Temp & Salt
o pkg/ptracers:
  apply zonal filter (if used) to all passive tracers

checkpoint61w (2009/10/12)
o adjoint:
  * update and finish work on adjoint of dic package (G. Forget)
  * start adjoint of offline package
  * bug fix for cube-sphere TLM code (active_file_g.F)
o tutorial_global_oce_optim:
  now tested with 4 tiles (change data.grdchk and update output_adm.txt)
  and add SIZE.h_mpi for MPI testing
o pkg autodiff
 - fix bug in autodiff_restore
 - make genmake2 remove comments and empty lines from ad_input_code.f in
   order to reduce file size (new script file remove_comments_sed)
o allows to specify vertical profile of vertical viscosity (viscArNr)
o pkg autodiff
  autodiff_ini_model_io: comment out writing of grid information to netcdf
  files, because at this time the grid fields are a bunch of zeros
  (this is analogous to ini_mnc_vars.F)
o pkg seaice/autodiff:
 left-over from removing the 3-time-level fields:
 - small rearrangement of common blocks (SEAICE.h)
 - fix field declaration in order to get meaningful output in
   adseaice.*.nc (adcommon.h)
o pkg obcs:
 - go through NH code only if nonHydrostatic=T
 - fix restart for Orlanski (Hydrostatic; still to fix NH+Orlanski restart)
 - move call to OBCS_CALC before SEAICE_MODEL which needs seaice-obc fields
   => Update output of experiment seaice_obcs
 - useOBCSbalance: code is wrong with multi-tile / proc: add a stop.
 - fix NH+Orlanski restart (add wvel OBC value in pickup file)
 - fix restart for useOBCSprescribe + useEXF
o pkg ctrl
 - make obcs as control parameter work also with useSingleCPUio
 - replace a few sny and snx by Ny and Nx to be consistent with
   ctrl_set_globfld_x/yz.F
o pkg seaice
 - re-introduce global field frWtrAtm for the case of
   ALLOW_MEAN_SFLUX_COST_CONTRIBUTION defined (SEAICE.h, seaice_growth.F)
 - catch the case of an empty filename in seaice_cost_init_fixed.F
o pkg ecco:
 - small bug fixes in the_main_loop
  . fix order of monitor arguments
  . change SEAICE_MULTILEVEL to SEAICE_MULTICATEGORY
  . move include DYNVARS.h up outside the ALLOW_AUTODIFF_TAMC block so
    that ALLOW_ECCO_FORWARD_RUN works with NONLIN_FRSURF
 - replace cos(yc*deg2rad) by _rA in cost_mean_heat/saltflux.F, fix the
   imbalance diagnostics for wmean_h/sflux = 0
 - add actual values to f_obcsn/s/w/e in ecco_cost_final.F
 - catch the case of empty filenames in ecco_cost_init_fixed.F
   and ecco_readparms.F
 - fix the logic of wsalt=0.and.wsalt2=0 to wsalt=0.or.wsalt2=0 (and theta)
   to make this statement meaningfull in ecco_cost_weights.F
o pkg zonal_filt:
  - change ZONAL_FILTER S/R interface (allows to filter 2-D fields)
  - when using rStar, filter uVel*hFacW instead of uVel
   (tested without topography: fix a Pb of growing instability with NLFS)
o pkg/aim/thsice:
 -Add capacity to read a Q-Flux to be applied in slab-mixed layer thsice_slab_ocean.F
  (works as SST restoring)
o pkg/thsice:
 -add specific parameter for salt restoring in slab mixed-layer
   (by default equal to the temperature restoring)

checkpoint61v (2009/09/21)
o pkg/kpp:
 -add double diffusive contributions as a hack, turned off by default
  for now, and the code can be excluded with a CPP-flag
  EXCLUDE_KPP_DOUBLEDIFF just as EXCLUDE_KPP_SHEAR_MIX
 -add a verification experiments to "vermix" to test this code
o pkg/mom_common:
  Move computation of length scales to mom_init_fixed.F (avoid recomputation
  at each time-steps*levels).
o pkg/layers:
  Created a new package for computing volume fluxes in temperature or
  [not yet implemented] density layers, e.g. for calculating residual
  overturning circulations.
o pkg/diagnostics:
  implement a RS type version for the set of DIAGNOSTICS-FILL subroutines
o fix few RS/RL type mismatch (check with ifort 11.1 "-warn all" option)
o pkg/mdsio (& pkg/rw): rework high level S/R interface:
  To avoid mixing type (RS/RL) of input/output array argument,
  replace single mixed-type array with a pair from each type (RS/RL).
o setting pickupSuff force to start from a pickup (even if nIter0=0): this
  is now implemented for all pkgs (previously only done for the main pickup)

checkpoint61u (2009/08/25)
o pkg/obcs:
  - change OB?eta from _RS to _RL and put them into a separate commen block
  - add code to read OB?eta from a file via obcs_prescribe_read: the code
    compiles and does not destroy any other experiments, the data is read
    properly, but the code is not tested in actual applications
o ini_mnc_vars.F: if available (ALLOW_CAL), use startTime_1 and 2 to
  create a meaningful unit attribute for the time coordinate variable
o pkg/ebm: add plenty of missing "_d 0" ;
   update results of experiment global_ocean_ebm (fwd + adjoint tests)
  Notes: several pieces of code only works for (very) specific set up
   (domain size, lat range, etc ...); should be documented & stop if one
   of those assumptions is not meet.
o pkg/seaice: add missing "_d 0" in HSNOW initialisation
   update results of experiments: lab_sea (3 fwd tests + 2 adjoint tests)
      and offline_exf_seaice (seaicetd + adjoint).
o add missing "_d 0" in ShortWave flux penetration (S/R SWFRAC):
   update results of experiments: lab_sea (4 fwd tests + 3 adjoint),
    seaice_obcs, global_ocean.cs32x15 (icedyn & thsice) and natl_box (x2).
o few changes to pass when compiling with strick checking of arguments
   across S/R (allow to find few bugs in S/R calls).
o pkg/seaice:
 - seaice_evp: move if-statement out of loop (TEM) at the cost of 11 new
   2d-fields, for slightly better performance

checkpoint61t (2009/07/22)
o pkg/seaice:
 - remove unused variables in seaice_evp
 - reduce number of SQRT in seaice_evp and seaice_calc_viscosities
o eeset_parms.F, open_copy_data_file.F & ini_parms.F:
   named file replacing SCRATCH files (for TARGET_BGL & TARGET_CRAYXT):
   each processor opens a different file (a fix from Matt).
o cg2d:
   use simple EXCH (overlap size = 1 and ignore corners), like in cg3d.F :
   this reduces number of EXCH calls by 2 when using exch2.
   For now, keep previous size array for gc2d_nsa.F to avoid Pb with store
   directives and missing simple EXCH (exch_s3d_rx) adjoint code.
o pkg/thsice:
   add code for Near Infra-Red albedo (from Jeff)
   (turned on with run-time flag: thSIce_calc_albNIR, in data.ice).
o ini_model_io:
   move (from packages_readparms.F & initialise_fixed.F) to ini_model_io.F
   MNC & MONITOR initialisation calls; move MNC calls from {pkg}_readparms.F
   to {pkg}_init_fixed.F for {pkg}= kpp, seaice & shelfice.

checkpoint61s (2009/06/30)
o pkg/exch2 (exch2_rxN_cube*):
   remove last BARRIER (no need to synchronise after getting data from shared
   buffer (get) as long as any change to buffer (put,recv) is between BARRIER)
o change tiling of natl_box (from 2 to 4 tiles) to get it tested with MPI+MTH
  and generate new output (for the 2 tests) using default rotationPeriod.
o pkg/exch2:
  - always call exch2_*_cube, not exch-1 anymore, if useCubedSphereExchange=F
    (was already the case with AUTODIFF_EXCH2 defined)
  - add bj in exch2 arrays and S/R.
  - can now use pkg/exch2 for regular (non CS) set-up; switch test experiment
    MLAdjust to exch2 (identical results except with MPI -> truncation diff);
o add pkg/longstep for ptracer timestep a multiple of U/V/T/S timestep
  - adds deltaT argument to the subroutines TIMESTEP_TRACER DWNSLP_APPLY
    GAD_ADVECTION GAD_CALC_RHS GAD_IMPLICIT_R GAD_SOM_ADVECT
  - verification experiment natl_box.longstep
o build_options: ifort+mpi_aces optfile (following Constantinos advise):
  allow different versions of ifort (8 or 9) and different versions
   of mpi (mpich or mpich2) to be used with the same optfile.
  requires to load a netcdf module and set MPI_INC_DIR (see comments inside
   optfile). Change testing scripts (example_scripts/ACESgrid) accordingly.
o pkg/seaice:
  fix previous modif (3-level field removed) for old-pickup reading

checkpoint61r (2009/06/25)
o pkg/seaice:
 - clean up the 3-time levels of UICE,VICE,HEFF,AREA in three steps:
  1. introduce fields for time step (N-1)
  2. do not use levels 2 and 3 anymore (but keep them)
  3. replace 3D versions of UICE,VICE,HEFF,AREA by 2D versions. This
     includes changes to pkg/thsice/thsice_get_velocity.F,
     model/src/external_forcing_surf.F, pkg/obcs/obcs_apply_seaice.F, and
     pkg/obcs/obcs_apply_uvice.F.
 - completely remove code for leap-frog time stepping for second order
   advection
 - adjusted adjoint accordingly;
   gradient checks have improved by an order of magnitude!

checkpoint61q (2009/06/22)
o pkg/seaice: fix bug in free slip boundary conditons for LSOR solver
 - the boundary conditions along open boundaries are unclear, because the
   associated masks are set to zero and are thus treated as closed when
   applying the slip-boundary conditions.
 - move initialisation of grid variables from seaice_init_varia to _fixed
o adding doc/diags_changes.txt
o model/src:
  do_the_model_io: rename few pkg S/R which are called from do_the_model_io,
   to avoid "_diags" naming if no relation to pkg/diagnostics.
  ini_theta,ini_salt: fix (at least compile the code) reading from NetCDF
   file and only call PLOT_FIELD_XYZ if debugMode=T.
  remove few PLOT_FIELD_XY calls outside initialisation.
  remove few unnecessary BARRIER.
o pkg/salt_plume: add SaltPlumeSouthernOcean to allow disabling
  of salt_plume package in Southern Ocean
o pkg/thsice:
 - fix hOceMxL in overlap (needed for sea-ice advection);
   update output of experiment global_ocean.cs32x15.icedyn.
o pkg/seaice:
 - make the (placeholder-)tracer IceAge a little more meaningful
  by avoiding ridging of age due to convergent ice flow
 - add diagnostics for surface temperature, atmospheric and oceanic
   heat flux, and atmospheric and oceanic ice growth

checkpoint61p (2009/06/10)
o eesupp (global_max & global_sum):
 - add one more element to buffer (start at index 0) for GL_MAX/SUM output;
 - remove starting & endding barrier (no longer needed)
o pkg/mdsio, writelocal:
   works also in multi-threaded when LOCBIN_IO_THREAD_SAFE is undefined
   (remove the STOP): uses shared buffer IO to store data from all threads
   and then let master-thread write nThreads tiles.
o pkg/mdsio (read/write field):
 - tiled IO done in 1 piece (all levels at a time);
 - new header file "MDSIO_BUFF_3D.h" with 3-D buffers.
 - multi-threaded: allow to read/write local (non-shared) array
   (was already working with singleCpuIO ; now works also without);
   => no longer needs barrier call after reading a file (added inside
   mds_read/write field).
 - move barrier calls outside gather/scatter_2d to mds_read/write_field
o pkg/obcs/exf
  - exf_getffieldrec.F: add a few ". _d 0" and
                        add code to catch the case fldperiod = 0.
  - obcs_precribe_read.F: change if statements so that they match
                          the variable type (_RL)
  - add a separate exf_iprec_obcs to exf_set_obcs (by default equal to
    exf_iprec) as part of namelist EXF_NML_01
o pkg/mdsio:
  - read/write tiled (local) files: read/write 1-level tile chunk at a time
    (instead of segment of length sNx); expected to speed up tiled IO.
o pkg/exch2:
  - take buffer copy from/to array out of S/R exch2_send/recv into new
    S/R exch2_put/get ; Exch of local variable now works with MPI+MTH
    (tested by removing commom block statement in SOLVE_FOR_PRESSURE.h).
  - ad version of send/recv no longer needed (but needs exch2_ad_put/ad_get)
  - simplify argument list of S/R exch2_get_uv_bounds and exch2_get_scal_bounds
    (which replaces exch2_get_recv_bounds & exch2_get_send_bounds) by
    including Topology header file (and common blocks).
  - implement EXCH_IGNORE_CORNERS in scalar exchange (rx1);
    remove 2nd exch call in exch2_s3d_rx (no longer needed).
  - document S/R arg. list (+ update some comments)
o pkg/seaice:
  - added SEAICE_CLIM_AIR code, which permits modulation of surface air
    temperature and humidity over sea ice based on climatological values.
  - clean up computation of Hibler+Bryan (1987) stress coupling for the case
    of LSR (this change is expected to change the results slightly because now
    it uses slightly difference moduli from the second last LSR solution, but
    that is more consistent with the stress computations; this part of the code
    is not tested in the verification experiments)
  - fix diagnostics for flux of ice in case of B-grid
  - turn strain rates eij and press into global fields within global
    common block in SEAICE.h for more straighforward diagnostics
  - fix diagnostics for principal stress components, press, zeta, eta
    to give something meaning full
o change tiling of global_ocean.cs32x15 (12 tiles, 32x16) and generate
  new output (all 4 tests) using default rotationPeriod.
o pkg KPP:
  - add flag (LimitHblStable) to avoid limiting BL depth under stable conditions
  - fix vertical indices in RI_IWMIX (match between KPP grid from 0 to Nr+1
    and normal grid from 1 to Nr)
o Fix computations of L4rdt in mom_calc_visc.F
o eesupp:
  new S/R ALL_PROC_DIE (like EEDIE, without irrelevant threads err msg):
  should be called before a "stop" if we know that all process are going
  to stop; if one Proc does call this S/R, will hang in MPI_FINALISE.

checkpoint61o (2009/05/26)
o pkg/exch2: change check_depths to issue just a warning (instead of error+stop)
o model/src/ini_curvilinear_grid.F:
   compute angleSin/CosC when they are not read from a file
o pkg/seaice:
   add pseudo time stepping for LSOR
o pkg/exch2:
   temporary fix for exch2_s3d_rx; update results of exp. hs94.cs-32x32x5.impIGW
o pkg/seaice:
   Adding separate sea ice albedo, drag coefficients, and HO in Southern
   Ocean from those in Arctic Ocean.  See *_south in SEAICE_PARAMS.h
o SingleCpuIO:
   fix bug put before chkp61n (May 11), when more than 2 MPI cpu are used.
o pkg/seaice:
   put exchanged variable in (local) common block for MPI+Multi-Threads
   to work (necessary with exch1, and for now with exch2 too).
o verification: to get more experiments tested with mpi, mth and mpi+mth,
  change tiling of:
   aim.5l_Equatorial_Channel, aim.5l_LatLon, dome, exp4, global_ocean.90x40x15,
   hs94.cs-32x32x5, MLAdjust, offline_exf_seaice & tutorial_plume_on_slope
  update output of exp:
   exp4, global_ocean.90x40x15(+.dwslp), MLAdjust(all 5),
   tutorial_plume_on_slope and hs94.cs-32x32x5 (use default rotationPeriod)
  + ideal_2D_ocean: use default rotation period + test Global_Sum_SINGLECPU
                   (note: output.txt generated on faulks using only 1 tile)
o eesupp & mdsio (SingleCpuIO):
 - remove MISSING_TILE_IO (from MDSIO_OPTIONS.h), replaced by run-time
   parameter "W2_useE2ioLayOut" (read from file "data.exch2").
   Note: was not effective for globalFile & useSingleCpuIO=F; now fixed.
 - move MDSIO_SCPU.h (pkg/mdsio) to EEBUFF_SCPU.h (eesupp/inc).
 - fix GLOBAL_SUM_SINGLECPU when using Exch2; re-use same buffers and same
   gather/scatter S/R as with SingleCpuIO (=> 1 less 2D global RL array).
o pkg/exch2:
 - new code to set-up W2-Exch2 topology (replace matlab-topology-generator):
   read parameter file "data.exch2" if it exists; otherwise try default regular
   cube without blank-tile; new header file "W2_EXCH2_SIZE.h";
 - update matlab-topology-generator (exch2_setup_cs6_print.m) to be compatible
   with new code (not to be used, just as a backup solution).
 - add examples (e.g., for lat-lon-cap_120) of parameter file "data.exch2"
   in utils/exch2/input.

checkpoint61n (2009/05/12)
o eesupp & mdsio (SingleCpuIO):
  - move mapping to global io-buffer inside gather_2d/scater_2d: this save
    memory (1 less 2D global RL array); skip 1 buffer copy; and only send/
    receive real*4 array (instead of real*8) to read/write 32.bit files.
    (new template for gather_2d/scater_2d, new set of S/R MDS_PASS_R4,8toRL,S
     and remove new mapping S/R)
o pkg/mdsio: in preparation for topology-generator within pkg/exch2:
  - Change declaration of SingleCpuIO buffer, reduced to only 1 dim.:
    xyBuffer_size, which is set to W2_ioBufferSize from W2_EXCH2_PARAMS.h
    when using exch2. Add S/R to map global io-buffer to global model array.
  - uses exch2_global_Nx,y instead of exch2_domain_nxt,nyt.

checkpoint61m (2009/04/29)
o write_utils : change WRITE_1D_R8 to WRITE_1D_RL
  and add 3 other S/R for other types (R4,R8,RS).
  Change calls to WRITE_0D/1D_R[4,8,S,L] to match the type of argument.
o eesupp/inc/CPP_EEMACROS.h (EXCH & GLOBAL_SUM/MAX macros):
 - ensure suffix (_R4,_R8,_RS,_RL) correspondance between macro and S/R ;
 - reduce number of macro definitions (keep only those which are used);
   can always call directly the corrresponding S/R if needed.
 - everywhere in the code: change macros (EXCH & GLOBAL_SUM/MAX) suffix
   _R4/_R8 to _RS/_RL when applied to _RS/_RL variable.
 Fixed wrong type of arg in:
   atm2d/put_ocnvars.F cheapaml/cheapaml.F ocn_compon_interf/ocn_apply_import.F
   ctrl/ctrl_map_ini_ecco.F seaice/seaice_do_diags.F seaice/seaice_model.F
 To fix: global_sum of var in common block is wrong (multi-threaded) in:
   dic/dic_atmos.F ebm/ebm_area_t.F ebm/ebm_zonalmean.F sbo/sbo_calc.F
 To fix: aim_v23/aim_do_co2.F (BARRIER & GLOBAL_SUM within bi,bj loops)
o adjustment.cs-32x32x1: test "blank tiles" when compiling with mpi; 2nd
  "nlfs" mpi test is going to stop when checking for unconnected tile egdes.
o eesupp/src: new S/R to stop everyone when 1 (or more) Proc. find an error
o pkg/exch2: new S/R EXCH2_CHECK_DEPTHS to check that unconnected tile
  edges are closed (zero depth); might happen with "blank tiles";
  for now, disabled if using OBCS.
o tools/gemake2: delete modifs from March 27-29 2009 (with option "-mpi":
  link *_mpi files from "MODS" dir) to return to a strait-forward behavior.
o move read_write.F to write_utils.F ; new parameter (maxLengthPrt1D)
  to reduce length of 1.D array print in STDOUT.
o adjustment.cs-32x32x1: changed to oceanic test with 1 continent
  + use 48 tiles (16x8): this will allow to test "blank tiles".
o start to test MPI + multi-threaded (change testreport to skip tests
  where number of tiles do not match).
o genmake2: add option "-omp" to turn on Open-MP ;
  passed to testreport (if using -mth) ; merge few (*+mth) optfiles.
o pkg/exch2 (+ utils/exch2): ignore blank tiles (instead of removing them)
  and keep the original tile numbering. Note: compatible with old
  W2_EXCH2_TOPOLOGY.h & w2_e2setup.F topology files.

checkpoint61l (2009/04/07)
o Overlaps had been forgotten in calculating ijk keys : fixed
o fix cyrus makedepend for gcc 4.4
o experiment fizhi-cs-aqualev20:
  switching to new version of S/R GETPWHERE (#define TRY_NEW_GETPWHERE)
  and generate new output. Note: new output is much closer to the old
  one (v1.8) generated with pgf77 -O2 on Mar 14 2007 than it is from
  the previous one (v1.9) generated with pgf77 -O0 on Jun 13 2007.
o pkg/fizhi:
 - change to avoid indices going deliberately over array-bounds
 - remove unnecessary MPI stuff
 - perpetual spring equinox with "#define FIZHI_USE_FIXED_DAY"
 - new version of S/R GETPWHERE available with #define TRY_NEW_GETPWHERE:
   does not go over array-bounds and therefore returns reliable output.
 - in fizhi_driver.F & fizhi_turb.F, fix "get_alarm" calls:
   this S/R has 4 output arguments, which are used inside "get_alarm";
   when it is called with the same variable "ndum" in place of several
   output arguments, this produces weird side effect inside "get_alarm"
  (e.g., datein=dates(n) is overwritten by timein=times(n) since both
   datein & timein, resp. 2nd and 3rd arg., are pointed to the same "ndum"
   address) and produces error.
o tools/gemake2: (March 27-29 2009)
  with option "-mpi": link *_mpi files from "MODS" dir (this is what
  testreport does).
o lab_sea experiment: change from 2x1 tiles to 2x2 tiles and regenerate output
o pkg/seaice: fix bug in new version of S/R SEAICE_LSR.F:
   update lab_sea.lsr & lab_sea.salt_plume results
o pkg/seaice:
  Major overhaul of the LSOR solver: change discretization from original
  finite differences to finite volume. The old routine is still in the
  file seaice_lsr.F and can be turned on with the CPP-flag
  SEAICE_OLD_AND_BAD_DISCRETIZATION
  Along with this change, the discretization of the strain rates is changed.
  The same flag turns on the old discretization in seaice_calc_strainrates.F
  All verification experiments with seaice are affected (except for
  seaice_exf_offline); global_ocean.cs32x15/input.icedyn recovers the old
  results by setting the above flag.
  Further changes involve changes in defaults:
  - ALLOW_FLOODING is defined and turned on by default
  - SEAICEadvSnow = .true. is now the default
  - SEAICEadvSalt = .true. is now the default
  - SEAICEadvAge  = .true. is now the default
  - SEAICE_clipVelocities  = .false. is now the default
                                     (as per J. Zhang's recommendation)
  - B-grid, and thus not tested: SEAICE_TEST_ICE_STRESS_1/EXPLICIT_SSH_SLOPE
    is defined, SEAICE_TEST_ICE_STRESS_1 is renamed into SEAICE_BICE_STRESS
  - seaice_growth: replace computation of UG by a simple copy from wspeed

checkpoint61k (2009/03/18)
o pkg/seaice: a few bug fixes mostly concerning the metric terms:
  seaice_lsr: fixed a few metric terms,
              affects lab_sea.lsr, lab_sea.salt_plume, seaice_obcs
              add more debugging diagnostics
  seaice_evp: removed superfluous many metric terms of FV discretization
              of stress divergence
              affects lab_sea, lab_sea.hb87
  seaice_ocean_stress: removed superfluous many metric terms of FV discretization
              of stress divergence for non-evp solver
              (this part is not tested anywhere)
  seaice_calc_strainrates: fixed a bug in no-slip boundary conditions,
              they were effectively only half slip
              affects lab_sea.hb87
  updated all relevant verification experiments (except lab_sea//output_adm.txt
    which was left over, but fails at level 7 & 6)

checkpoint61j (2009/03/17)
o pkg/seaice: turn a few hard wired parameters into run time parameters
o pkg/seaice/exf/monitor: turn netcdf coordinate variable T into model
  time in seconds as promised by the usints in seaice_monitor and exf_monitor
o pkg/mnc: fix the coordinate variables for multi-tile curvi-linear grids
  that are not cubed-sphere grids
o pkg/seaice: fix a bug for the rare case of SEAICE_VECTORIZE_LSR
o pkg/ctrl:
  fix bug in ctrl_depth_ini.F (EXCH_XYZ was applied to 2-D field xx_r_low)
o non-hydrostatic (calc_gw.F):
  fix viscA4 on CS-grid + fix diagnostics: Wm_Diss & Wm_Advec
  update output of exp. global_ocean.cs32x15.viscA4
o remove backward compatibility for thetaMin,phiMin
  (replaced by xgOrigin,ygOrigin on Jan 27, 2009)
o pkg/exf: fix a serious bug in exf_set_uv.F: do a rotation of the
  interpolated wind field not only for curvilineargrid=.true., but also
  for a rotated grid (rotateGrid=.true.)
o pkg/exf: add capability to bypass interpolation for runoff
  by setting yet another CPP-flag
o eesupp/src, B-grid exchange:
  add simple (6 tiles, non MPI) CS exch + standard interface S/R.
o autodiff
  new CPP option ALLOW_TAMC_SINGLEPREC_COMLEV
  allows to switch to single-prec common blocks;
  corresponding switch occurs in tamc.h, integer isbyte
  TAF store directivs "byte" and "kind" seem equivalent;
  Most tamc.h have been updated correspondingly.

checkpoint61i (2009/02/13)
o autodiff:
  fix autodiff_sore/_restore indices for obcs
  (spotted by I. Hoteit, M. Mazloff)
o pkg/autodiff, pkg/ctrl:
  Add flag to reduce all tapelev I/O to single-prec.
  In data.ctrl set
    doSinglePrecTapelev = .TRUE.
o model/src/ini_curvilinear_grid.F, new grid-file format without EXCH2:
  check in hack for SX8 compiler (for dxV, dyU); remove it afterwards.
o pkg/shelfice: fix bug with SHELFICEconserve flag, prepare for
  real fresh water flux (not yet)
o pkg/mdsio & rw:
 - add argument & option to S/R MDS_WRITEVEC_LOC (avoid Open/Close & write-meta)
 - add simple interface S/R to MDS_WRITEVEC_LOC in pkg/rw: WRITE_GLVEC_RX.
o pkg/flt:
 - replace FLT_INIT by 3-steps standard initialization S/R: readparms,
   init_fixed & ini_varia.
 - clean-up & simplify linear interpolation S/R:
   move flt_bilinear.F -> flt_interp_linear.F ; add arg. myThid.
 - fix some indices (mainly vertical index) ; add IMPLICIT NONE.
 - more efficient I/O, using new options of MDS_WRITEVEC_LOC S/R.
 - add vert. coordinate & horiz. indices to output files.
 - change vertical position in initial condition, from index to depth [m].
 - store horizontal (decimal) indices i,j in common block (instead of coord. x,y)
   (easier to get to a curvilinear grid) ; delX,delY no longer used.
o pkg/ggl90: a few modifications:
 - fix bottom boundary condition, and interpolation of KappaE
   near top and bottom
 - use same set of viscosity/diffusivity for TKE/momnetum/tracer
 - add smoothing option as in Blanke and Delecluse (1993) (--> ALLOW_GGL90_SMOOTH)
 - add a few options for mixing-length upper limit (--> mxlMaxFlag)
o rename thetaMin,phiMin -> xgOrigin,ygOrigin
  (maintain temporary backward compatibility, until next checkpoint)

checkpoint61h (2009/01/27)
o pkg/diagnostics with "periodic averaging diagnostics":
  fix S/R DIAGNOSTICS_COUNT ; hack diagnostics_out.F to get NetCDF output.
o pkg/my82: add missing "_d 0" ; update output of exp. vermix.my82
o pkg/obcs: fix loop ranges for balancing code
o pkg/flt:
 - improve criteria for finding which tile owns a float.
 - fix FLT_EXCH for case without MPI ; apply cyclic BC + fix also the MPI case.
o Add well-mixed CO2 box in aim_v23 (which includes changes in pkg
  aim_compon_interf, ocn_compon_interf, gchem, and dic to get coupling
  with ocean biogeo)
o pkg/flt:
 - do some cleaning and fix the restart ;
 - add output.txt in flt_example/results to get this pkg tested.
o genmake2: add an EXTENDED_SRC option and flag.
   for now, cannot be turned on on command line (only through genmake_local)
o pkg/mdsio: read/write vector:
 - singleCpuIO: fix RL/RS in MDSWRITEVECTOR by calling new S/R MDS_BUFFERtoRL/RS
 - singleCpuIO=F: fix arrType & filePrec & _BYTESWAPIO in both MDSREADVECTOR
   & MDSWRITEVECTOR by calling new S/R MDS_RD/WR_VEC_RL/RS.
 - affects gradient of test-exp "bottom_ctrl_5x5" (not due to _BYTESWAPIO)
  (drop to 4 digits matching for grad). But this test does not look very
  reliable (was already failling on eddy, fc5, at 6.digits). Update output.

checkpoint61g (2008/12/29)
o pkg/flt:
  - move FLT_CPPOPTIONS.h to FLT_OPTIONS.h (standard name)
   + make OPTIONS file more standard.
  - rename S/R MDSREADVECTOR_FLT to FLT_MDSREADVECTOR (to mach src file name)
  - fix _BYTESWAPIO CPP-Flag
  - standard reading of file-parameter "data.flt"
  - fix argument list of S/R FLT_RESTART
  still need to fix _BYTESWAPIO in pkg/mdsio/mdsio_writevector.F
o pkg/obcs: fix a CPP-flag, bug reported by Jeff Blundell
o gather_2d.F/scatter_2d.F: suppress vectorisation on NEC SX in respond to
  a still unfixed compiler/optimization bug

checkpoint61f (2008/11/21)
o pkg/seaice, LSR solver: fix bug in GLOBAL_MAX calls ;
  update results of global_ocean.cs32x15.icedyn test.
o move getcon.F from model/src to pkg/fizhi.
o pkg/exf: add parameter for extrapolation of temp up to the surface
   and option to prevent negative evap (in bulk_largeyeager04 only).
o Prather Advection scheme: fix tracer conservation for divergent flow
  (e.g., when using NonLin Free-Surface).
o kpp: retire KPPmld diagnostics --> use MXLDEPTH instead
o gmredi (Visbeck-variable-K):
 - add more parameters to Visbeck-variable-K.
 - use a 5 points average for dSigmaR in Visbeck-K calculation
   (more "homogenous": same stencil and same weights as in dSigmaH)
 - update output of ideal_2D_oce experiment.
o fix CPP-flag REAL4_IS_SLOW, when _RS expands into real*4
  (#undef REAL4_IS_SLOW)
 - pkg/mnc/mnc_cw_cvars.F: write _RS-grid variable as netcdf-real*4
   coordinate variable
 - pkg/monitor/monitor.F: call mon_printstats_rs for _RS variables
   (surface forcing fields), removes some of the functionality
 - model/src/write_grid.F: write _RS variables as RS-netcdf variables
 - model/src/diags_oceanic_surf_flux.F: fix a few diagnostics, but
   probably not all: copy _RS surface flux fields to RL field before
   calling DIAGNOSTICS_FILL
 - model/inc/CPP_EEMACROS.h: make the _EXCH_*_RS macros expand into
   real*4 (CALL EXCH_*_RS) versions.
 - tested in 2 experiments: inverted_barometer & solid-body.cs-32x32x1
   (generate new output).

checkpoint61e (2008/10/23)
o gmredi (Visbeck-variable-K):
  - fix the "OLD_VISBECK_CALC" option + move the #undef to GMREDI_OPTIONS.h
  - change computation of Visbeck-K where Slope > Smax :
    now: N*min(Slope,Smax) (similar to OLD_VISBECK_CALC with gkw91 taperFct)
    previously was: M*sqrt(min(Slope,Smax)) ; update ideal_2D_oce output.
o bottom-drag in P-coord.: change units of bottomDragLinear & bottomDragQuadratic
  to be the same as with Z-coord. (i.e., m/s & no-units respectively).
o calc_viscosity: fix index range (was wrong for CD-Scheme & explicit Visc)
o pkg gmredi, linear & fm07 tapering: put an upper limit on Slope^2 so that Kwz
  does not become too large (to avoid precision problems in implicit-diffusion
  solver); update ideal_2D_oce output.
o pkg ggl90:
  - in ggl90_cal.F: compute only one set of visc/diff, used to
    step forward TKE/T/S/momentum
  - default value of GGL90viscMax/GGL90diffMax larger and equal (to
    have Prandlt =1)
o gmredi (fm07):
  - add lower limit on Transition layer thickness + lower limit on 1/lambda
  - allow to set few more params from data.gmredi
o pkg ggl90:
      - add missing sqrt(2) factor in computation of mixing length
        scale in ggl90_calc.F
        (see Eq. (2.35) in Blanke and Delecluse, JPO, 1993)

checkpoint61d (2008/09/25)
o adjoint modifs
  - adapt to new field rhoInSitu
  - allow to revert from StoreDynVars2D, StoreDynVars3D
    to individual fields
    (switches AUTODIFF_USE_OLDSTORE_2D, AUTODIFF_USE_OLDSTORE_3D)
o store 3-D (in-situ) density in commom block (DYNVARS.h)
 - save 1 rho computation.
 - no longer modify T & S inland when using down_slope pkg.
o gad_som : allow to switch to SOM advection for T & S without corresponding
  pickup files (using new S/R: MDS_CHECK4FILE).
o keep removing _BEGIN/_END_MASTER between MDSIO S/R call
  (for useSingleCpuIO to work in multi-threaded)
o pkg/shelfice:
 - disentangle parameters: retire shelfIceFile in data/PARM05 and substitute
   with SHELFICEtopoFile in data.shelfice
 - move code for reading ice shelf topography and modifying hFacC into separate
   subroutines of the shelfice package
 - separate initialisation of "fixed" and "variable" variables
 - kTopC is not (yet) replaced by kSurfC, although this is possible
o fix broken diagnostic SIatmFW and changed the units from m/s to kg/m^2/s
o add initialisation of deepFac if using Pcoords (new S/R set_grid_factors)
  and rename:
  ini_phiref.F          --> set_ref_state.F  (+ set anelastic factors)
  ini_reference_state.F --> load_ref_files.F (- set anelastic factors)
o change FIND_RHO_SCALAR : return rho (instead of rho - rhoConst)

checkpoint61c (2008/08/30)
o add option ALLOW_ADDFLUID and run-time selector "selectAddFluid"
  to add mass source/sink of fluid in the interior (3-D generalisation
  of oceanic real-fresh water flux).
o pkg/monitor: fix recip_dr argument in mon_advcflw2 call (-> advcfl_W_hf_max)
o vermix test experiment: switch from LINEAR EOS to MDJWF (not tested before)
o new pkg: down_slope
  density-driven downsloping flow parameterisation (Tellus, 1999, 412-430).
  - presently, modify T & S inland (dwnslp_calc_rho.F).
    can be avoided if rho was stored in common bloc and used in calc_phi_hyd.
  - implementation for ocean in P-coords not tested.
  - add secondary test to global_ocean.90x40x15 (input.dwnslp) to check this pkg.
o move kSurfC,kSurfW & kSurfS from SURFACE.h to GRID.h (next to kLowC)
  (to facilitate conversion of oceanic pkg to p-coordinate).
o change FIND_RHO to FIND_RHO_2D :
  pass arguments tFld & sFld as local (tile) 2D-arrays ; +fix EOS_CHECK.
o new pkg: cheapaml

checkpoint61b (2008/08/05)
o exch2:
  change index bounds in rx2_cube exchanges (new S/R: EXCH2_GET_UV_BOUNDS)
  - no longer depend on the order sequence (N,S,E,W).
  - 3rd exchange no longer needed (tested with 24 tiles).
  - same modif to hand-written adjoint S/R (global_ocean.cs32x15: zero diff)
  - exch_UV_A-grid readily available (but not yet tested).
  comment out 3rd exch call and remove copy of V to U at SE & NE face-corners
  (both are no longer needed) in exch_uv: no effect in forward run; but
   get truncation error differences with adjoint exch.
o exch2:
 - change index-bounds storage (moved from target to local tile,
   more intuitive this way) ; rename/remove some variables.
 - change utils/exch2/matlab-topology-generator & code_mods accordingly.

checkpoint61a (2008/07/29)
o exch2/matlab-topology-generator:
  fix bug in index bounds for N-S internal exchange (hard to tell if this
  had any effect on the solution).
o pkg/mnc: small fix in mnc_handle_err: make sure that length of msgbuf
  is exceeded
o testreport: modify syntax of awk, so that it works also with
  awk, and not only with nawk and gawk

checkpoint61 (2008/06/24)
o autodiff
  Change default for TAF usage by removing argument '-nonew_arg'
  This changes TAF subroutine argument list (ordering of active var.)
  Omission of this flag leads to incompatibility w.r.t. TAMC
  To restore TAMC-compatibility, need following modifs:
  * use adoptfile tools/adjoint_options/adjoint_tamc_compatibility
  * use CPP option #define AUTODIFF_TAMC_COMPATIBILITY
  Tested TAF version is 1.9.22
  N.B.: exch2 hand-written adjoint code currently not TAMC compatible

checkpoint60 (2008/06/19)
--->>> This is the last checkpoint for which generating the adjoint
--->>> is done via the TAMC-compatibility TAF-flag "-nonewarg"
--->>> by default.
--->>> Future checkpoints will ommit this flag by default.
o pkg/generic_advdiff, os7mp: simplify and avoid division by zero.
o pkg/grdchk: Add gradient check to etan0 perturbations.
o pkg/exf: read ice area from file (#ifdef ALLOW_ICE_AREAMASK).
o pkg/autodiff: more flexibility in zeroadj.
  model/src: modifying do_oceanic_phys.F accordingly.
o pkg/ctrl: Bounds for (kapgm,kapredi,eddypsi) parameter estimation.
o model/src and pkg/gmredi: GMREDI_WITH_STABLE_ADJOINT CPP option
  special setup of gmredi for which the adjoint is stable
  enough for parameter optimization.
o bridging the gap between eddy stress and GM.
  -> eddyTau is replaced with eddyPsi (eddyTau = f x rho0 x eddyPsi)
      along with a change in CPP option (now ALLOW_EDDYPSI).
  -> when using GM w/ GM_AdvForm:
      The total eddy streamfunction (Psi = eddyPsi + K x Slope)
      is applied either in the tracer Eq. or in momentum Eq.
      depending on data.gmredi (intro. GM_InMomAsStress).
  -> ALLOW_EDDYPSI_CONTROL for estimation purpose.
  The key modifications are in model/src/taueddy_external_forcing.F
  pkg/gmredi/gmredi_calc_*F pkg/gmredi/gmredi_*transport.F

checkpoint59r (2008/05/29)
o new S/R (pkg/mdsio/mdsio_facef_read.F) reading of sNx+1 x sNy+1 array
  from per-face file (take S/R READSYMTILE_RS out of ini_curvilinear_grid.F);
  fix option to read coriolis(@ cell-corner) from files with CS-grid.
o pkg/mnc: add some attributes to standard 1D-coordinate variables
o pkg/diagnostics: enforce missing_value attribute for scalar variables at
  mass points, when using mnc for output
  - add runtime parameter (missing_value, missing_value_int) to override
    default (which is the value of getcon('UNDEF'))
o pkg/mnc: prepare mnc for the actual use of missing values with the
  diagnostics package: small fix in mnc_cw_readwrite.template and more
  initialisation of never used fields
  - replace mnc_common.h and mnc_id_header.h with corresponding upper case
  versions
o pkg/thsice/thsice_ini_vars.F added default initial values so that
  thermodynamics sea ice solver does not blow up when some initial fields
  are missing.
o move from external_forcing_surf.F to ini_forcing.F
  the p-coord. hack consisting in using pLoad to set phi0surf ;
  update output of tutorial_global_oce_in_p (affected @ truncation level).
o Freshen up a bit hs94.1x64x5, notably:
  remove rotationPeriod and tRef=5*0. (adjoint only), and add
  exactConserv=.TRUE.
o pkg/generic_advdiff:
  change option GAD_ALLOW_SOM_ADVECT to GAD_ALLOW_TS_SOM_ADV which only
  applies to files where Temperature & Salinity 2nd Order moments are used.
o pkg/ptracers: add second-order moment advection schemes (80 and 81);
  this uses a dynamically allocated internal state data structure
  (#define PTRACERS_ALLOW_DYN_STATE in PTRACERS_OPTIONS.h)
  and requires a fortran 90 compiler

checkpoint59q (2008/05/06)
o pkg/mom_vecinv: Add energy & enstrophy conserving scheme (selectVortScheme=3)
   (from Sadourny, described by Burridge & Haseler, ECMWF Rep.4, 1977)
o Refresh tutorial_global_oce_biogeo, notably:
  - change bathymetry (put back seamounts in ACC, use hFacs)
  - change EOS (POLY3 --> JMD95Z)
  - use Bryan-Lewis vertical diffusivity
  - use multidimensional advection
  - remove old virtual virtual in dic pkg, now done through ptracer pkg
  - change a couple of parameters in dic pkg
o pkg/ctrl: change formula in adctrl_bound.F and add a parameter to ctrl_map_ini_gen.F
o pkg/obcs: change default to OBCSfixTopo = .true.,
  - set OBCSfixTopo=.false. in exp4/input/data.obcs to reproduce old result
  - replace "debugMode" with "debugLevel .GE. debLevB"
o implementation of TAF directives for gchem,cfc,dic
o remove "exp5" (replaced by tutorial_deep_convection).
o pkg/obcs: add code to fix topography gradients normal to open boundaries;
  this requires computing the index fields OB_Jn/Js/Ie/Iw in obcs_readparms;
  the code can be turned on by setting OBCSfixTopo = .true. in data.obcs
  --> changes results in exp4, seaice_obcs
o tutorial_deep_convection :
  update the set-up and increase resolution and domain size ; start
  from pseudo initial conditions = output at t=120mn in order to see
  something happening when running testreport.
o pkg/seaice: add os7mp as an advection scheme
              add check for advection schemes
              add a flag for restoring T and S underneath sea ice
o pkg/my82: add netcdf-support and diagnostics
o thsice pkg:
  - Now hsMax limits snow height by turning it into ice following
    flooding scheme (and now conserving energy)
  - Slight rewriting of the formula in thsice_calc_thick.F
  - Parameter rhowi eliminated to be replaced by floodFac = (rhosw-rhoi)/rhos
  --> changes results of global_ocean.cs32x15.icedyn and global_ocean.cs32x15.thsice

checkpoint59p (2008/04/10)
o gchem / dic / cfc :
  - add useDIC, useCFC , read from "data.gchem" (& hold in GCHEM.h);
  - add new parameter files: "data.dic" & "data.cfc" ;
  - various re-arrangement in initialisation & header file ;
  - fix tutorial_global_oce_biogeo for multi-threaded test.
o pkg/dic: test for "pickup_dic" file when restarting ;
  if no pickup-file, can restart with a re-initialised pH (same as it did
  before) providing pickupStrictlyMatch is set to False.
o change argument list of S/R PTRACERS_WRITE_PICKUP & MYPACKAGE_WRITE_PICKUP
  + fix call to S/R GGL90_WRITE_PICKUP & DIC_WRITE_PICKUP
o add a "warning" (to Error msg file) when an Active Tracer is not using AB-2
  and staggerTimeStep is off (needed for stability of Internal-wave dynamics).
o move out of PARAMS.h & data the last pieces of old-ptracer code: tauTr1ClimRelax,
 & lambdaTr1ClimRelax ; put those 2 params in PTRACERS_PARAMS.h & data.ptracers
   (note: not clear to me what lambdaTr1ClimRelax is still used for ...)
o pkg/mom_vecinv: - new parameter "selectVortScheme" to select which
   scheme to use for vorticty-term ;
 - compute upwindVorticity=T case within mom_vi_u/v_coriolis_c4.F
   (with default selectVortScheme, return to original discretisation)
 - remove weird combination (e.g.: upwindVorticity & highOrderVorticity)
o pkg/seaice: add a line to the summary to indicate grid type (B/C)
o in mom_calc_visc, fix average value of viscAh_W & viscA4_W next to the
  bottom ; only used with variable horizontal viscosity and non-hydrostatic.
  also fix diagnostics VISCAHW & VISCA4W.

checkpoint59o (2008/03/07)
o dome/code/obcs_calc.F: avoid division by zero (detected using gfortran).
o change the loop ordering in most gad_*_adv_x.F to improve vectorization:
  move a few statemens out the main loop into separate loops
o pkg/shelfice:
  - sort out freshwater flux; convert freshwater fluxes to mass fluxes
    (kg/m^2/s), does not break tests, because in verification/isomip,
    rhoConstFresh=rhoConst (by accident)
  - rearrange computation of tLoc, sLoc, pLoc to make code more efficient
  - move S/R find_rho_scalar, pkg/ecco/sw_ptmp.F, pkg/ecco/sw_adtg.F into
    new file model/src/seawater.F, so that they are available for all pkgs.
  - convert potential temperature into in-situ temperature. This changes the
    isomip tests => update tests
o add a flag writePickupAtEnd (default=true) to be able to suppress
  writing a pickup at the last timestep
o tools/mpack-1.6 :
  - disable automake (not working) and autoconf (not needed).
  - update to version 1.6.4 which fix MD5 code on some 64 bits platforms
    also cleaner with much less compilation warnings.
o pkg/profiles:
  rename profiles_interp_mean_genericgrid as profiles_interp_mean_gg
  (for "less than 32 characters name" compiler requirement)
o pkg/obcs and pkg/exf: added capability to specify seaice open boundary
  conditions that have a different sampling frequency than S/T/U/V obcs
o pkg/diagnostics (stats-diags):
  - fix global Min/Max in case 1 processor get only empty tiles
o genmake2: replace (4 times)
     make genmake_tc_1.o >> genmake_warnings 2>&1
  with
     COMM="$CC $CFLAGS -c genmake_tc_1.c"
     echo $COMM >> genmake_warnings
     $COMM >> genmake_warnings 2>&1
  to make genmake2 always see the value of CC as specified in the optfile.
o generic_advdiff: - prather advection scheme (SOM) coded for CS-grid.
  - add diagnostics for 1srt & 2nd Order moments and sub-grid variance.
  - modify verification advect_cs test to test SOM-advection on CS-grid.
o pkg/ctrl:
  - Rewrite of ctrl_map_ini_ecco.F,
    introducing a generic routine (ctrl_map_ini_gen.F).
  - Modification of ctrl_bound/adctrl_bound handling control vector bounds.

checkpoint59n (2008/02/09)
o pkg/diagnostics: for large number of diagnostics, store diagnostic mate
  number in dedicate array "hdiag":
  - new version of S/R DIAGNOSTICS_ADD2LIST : DIAGNOSTICS_ADDTOLIST
    with 1 more argument (mate number); modify old version DIAGNOSTICS_ADD2LIST.
  - many small changes (integer format) for large number of diagnostics
  - start to use DIAGNOSTICS_ADDTOLIST (necessary for diagnostics with
    a counter mate) in pkg diagnostics, ptracers, thsice & aim_v23.
o add parameter rotateGrid and Euler angles EulerPhi/Theta/Psi. For
  usingSphericalGrid, this allows to define the rotated grid coordinates
  via phiMin/thetaMin/dxSpacing/dySpacing, etc., but then re-compute the
  geographical coordinates according to the inverse of the rotation defined
  by the Euler angles, so that Coriolis parameter and online-interpolation by
  exf works with the geographical coordinates on XC/YC/XG/YG.
  Naturally, this feature does not work with all packages, so some
  combinations are prohibited in config_summary (flt, flt_zonal, ecco,
  profiles), because there the coordinates are assumed to be regular
  spherical grid coordinates.
o pkg/gmredi,ctrl,ecco,autodiff,grdchk and model/src,inc:
  - introduce isopycnal diffusion coefficient control.
o tools/adjoint_options:
  - additional control vector components.
o pkg/mnc: have mnc create marginally meaning full coordinate variables
  (that is the grid indices) if usingCurvilinearGrid and NOT EXCH2
o pkg/mypackage:
  - add example of read/write pickup for state-var ;
  - add entry points to the main code for state-vars diags & write-pickup.
o pkg/exf: rewrite of exf_getffieldrec.F to properly deal with year
  transitions for useExfYearlyFields
  - add new subroutine that determines the file to read from for
    use*YearlyFields = .TRUE. and .FALSE.
  - add a verification experiment to global_with_exf that tests
    useExfYearlyFields with USE_EXF_INTERPOLATION defined
o pkg/obcs/exf: add useOBCSYearlyFields (=.FALSE.) to obcs with exf in
  analogy to useExfYearlyFields; rearrange obcs_prescribe_read: two new
  subroutines (which could be generated from a template, because they are
  almost identical), for now they are included in obcs_prescribe_read.F for
  simplicity
o pkg/exf:
  - add a little more diagnostic to exf_interp_read (in analogy to
    mds_read_field, can be turned off with debugLevel < debugLevA=1)
  - improve vectorizability of exf_interp for TARGET_NEC_SX, makes code
    ugly but fast by unrolling short inner loops, inserting a unroll=8
    directive in routine lagran, and splitting a loop and making do while the
    outermost loop (the latter requires the intoduction of index arrays)
o pkg/obcs: replace obcs_apply_area/heff/hsalt/hsnow with obcs_apply_seaice
o pkg/seaice: moved DIFFERENT_MULTIPLE from seaice_model to seaice_dynsolver
  http://forge.csail.mit.edu/pipermail/mitgcm-devel/2008-January/003173.html
o verification/seaice_obcs: updated for restart test and latest options
o pkg/seaice: add a new flag SEAICEuseTEM to use a slightly different
  ice rheology (so-called truncated ellipse, that gets rid of tensile stress);
  for now this is only available for the C-grid code and also within
  #ifdef SEAICE_ALLOW_TEM, because this option may slow down the EVP code

checkpoint59m (2008/01/14)
o pkg/seaice: use different time constant for melting (SEAICE_gamma_t)
  and freezing (SEAICE_gamma_t_frz) ice due to mixed layer temperature
o gad_som : fix flux output (& diagnostics) to have same units as other
  advection scheme fluxes (was previously multiplied by deltaT).
o added verification/seaice_obcs both to test seaice open boundaries
  and to provide an example matlab scrpt for generating them
o added verification/lab_sea/input.salt_plume for testing pkg/salt_plume
o pkg/salt_plume: clean up salt_plume_frac.F to
  remove redundancy in PlumeMethod 1 and 4
o pkg/kpp: added saltplume diagnostics
o pkg/obcs and pkg/seaice:
  - do not set uice and vice to zero when OB*icefile are unspecified
  - OBCS_SEAICE_AVOID_CONVERGENCE is undefined by default
  - moved seaice tracer obcs after call to seaice_growth
o pkg/salt_plume: added various options for salt plume depth
  criterion and for vertical distribution of the salt

checkpoint59l (2007/12/18)
o pkg/ptracers: new version of ptracers pickup:
  read meta file and write only fields which are needed to restart.
  ( same logic as main pickup file ; also using pickupStrictlyMatch )
o pkg/seaice:
  - add timescale for melting due to warm mixed layer as a means of
    setting SEAICE_availHeatFrac more conveniently
  - add a CPP-flag/runtime parameter check for flooding algorithm
  - reformulated availHeat in seaice_growth.F to be independent of AREA
o change units attribute of EmPmR netcdf variables to kg/m^2/s to reflect recent
  unit changes
o pkg/obcs: added OBCS_SEAICE_AVOID_CONVERGENCE constraint
o cg2d.F: add 3 compiler directives that speed up this routine by 30% on a NEC
  SX vector computer.
o pkg/seaice:
  - removed SEAICE_FFIELDS.h and seaice_get_forcing.F
    seaice forcing fields can now be read only through pkg/exf
  - removed some unused halos
o no longer write pickup from THE_MODEL_MAIN but always from FORWARD_STEP
o pkg/exf: added useRelativeWind EXF_PARAM.h option for subtracting U/VVEL
  or U/VICE from U/VWIND before computing U/VSTRESS

checkpoint59k (2007/11/30)
o pkg/seaice: ICE2WATR=SEAICE_rhoIce/rhoConst for consistency between
  dynamics and thermodynamics. Set ICE2WATR=0.92 to reproduce older results.
o fix un-initialised variable problem (in mom_vecinv & shap_filt):
  all experiments pass when compile with un-initialised var. checking option.
o added pkg/salt_plume
o script to test restart (for now, in MITgcm_contrib/jmc_script)
o pkg/seaice: new read/write pickup version.
  read meta file and write only fields which are needed to restart.
  ( same logic as main pickup file ; also using pickupStrictlyMatch )
o pkg/seaice: fix bug in seaice_ocean_stress (call of seaice_calc_strainrates)
o lab_sea.hb87: modify the domain & update output.hb87.txt :
  lat-long grid & no-slip BC in seaice-dynamics produce different sigma12
  at j=1 & j=Ny+1 : this case is not treated correctly in the restart
  process. Fixed here by closing the domain at the Northern boundary.
o pkg/rw: cleaning-up: call directly new MDSIO S/R MDS_READ/WRITE_FIELD.
o pkg/mdsio: add new arguments to MDS_READ/WRITE_FIELD for reading/writing
  a set of consecutive levels in/from a 3-D array.
o pkg/ptracers:
  use a 2 characters string ioLabel to identify tracer (if more than 99 tracers).
  to-do: fix pkg/diagnostics when large number of diagnostics are defined.

checkpoint59j (2007/11/09)
o in pkgs: dic, obcs, offline, rbcs:
  standard way to compute coeff. for time interpolation between 2 time reccords
  which retains full precision (& make results less dependent on compiler).
  update output of exp: tutorial_cfc_offline & tutorial_global_oce_biogeo.
o pkg/cfc: if compiled with exf and seaice, cfc now can use fields from those
  packages instead of reading ice cover and wind speed separately
o split PTRACERS.h in 2 header files: PTRACERS_FIELDS.h & PTRACERS_PARAMS.h
 (keep a temporary version of PTRACERS.h in verification/OpenAD/code_ad_openad
  to allow to compile customized code before the update)
o cleaning-up:
  - fix CPP instruction syntax in pkg/obcs
  - replace (some) call to MDSIO S/R with call to RW interface S/R ; and
    add #ifdef ALLOW_MDSIO elsewhere (allows to compile without pkg/mdsio)
  - fix some threads issue in IO parts.
o pkg/dic:
  - add tons of "_d 0" (--> much better testreports !)
   and then update outputs of tutorial_global_oce_biogeo
o pkg/mom_fluxform:
  add a special version of momentum advection intended to conserve momentum
  next to a bathymetry step or a coastline edge. (default = off = #undef)
o new read/write pickup version:
  - for now, only implemented for main (mdsio) pickup file.
  - write out only what is needed to restart; merge pickup_nh , pickup_ph
    and main pickup together.
  - read meta file; read only what is needed to restart; stop if a field
    is missing (if pickupStrictlyMatch=T, = the default) or try to restart
    if it make sense (even if the restart is not perfect).
  - if no meta file, assume that pickup to read corresponds exactly to
    a pickup that would currently be written.
  - read pickup written in the old format (until checkpoint59i) if it
    recognizes an old meta file (no field-list).
  - add a meta file in exp. which starts from a pickup: 2 cases:
    a) minimal meta file (with just file precision) + pickupStrictlyMatch=F
     e.g.: global_ocean.90x40x15/input/pickup.0000036000.meta
    b) a meta file describing the content of the associated pickup file
     e.g.: tutorial_global_oce_biogeo/input/pickup.0004248000.meta
o pkg/mdsio & pkg/rw:
  - new routine to read a meta file ; new set of routine to read
    Multiple-fields file (with meta file).
o added open boundary conditions capability for seaice
    HSNOW, HSALT, UICE, and VICE

checkpoint59i (2007/10/21)
o adjoint:
  * fix multiDimAdvection adjoint
    (partial recomputation problem by TAF for fVerT(:,:,kDown)
    and comlev1 size definition (maxpass vs. max. number of tracers)
  * verification/global_ocean.90x45x15 adjoint now tests
    NLFS and multiDimAdvection using DST3 (=30)
  * verification/lab_sea now tests multiDimAdvection using DST3 (=30)
o pkg/kpp: add "_d 0" to real constant (if missing);
  update output of exp: natl_box (10.digits); vermix (std, 7.digits)
  and lab_sea, 3.FW (only 6,4,6 digits match) & AD (8.digits).
o prepare for "clever pickup" implementation: add new header file "RESTART.h"
  for internal parameters related to restart process (formerly from PARAMS.h)
  and add startAB parameter to argument list of S/R ADAMS_BASHFORTH2.
o more standard interface to {PKG}_WRITE_PICKUP with pickup suffix passed
  as argument. (only atm2d & obcs write_pickup have not yet been updated)
o pkg/monitor:
  - use GLOBAL_SUM_TILE instead of _GLOBAL_SUM
  - fix mon_stats_rs (statistics over the full domain, even where field is zero)
  - account for deep Atmosphere factor and density factor (anelastic)
o added open boundary conditions capability for seaice HEFF and AREA
o pkg/shelfice: add option for convservative form of Hellmer&Olbers (1989)
  thermodynamics
  - requires a little reorganization, which affects the testreport results
    of isomip.htd (only 7 digits of cg2d agree) => update/modify experiment,
    so that now the conservative form is tested
  - add a few comments
o add missing cvs Header: or Name: in eesupp/*, pkg/* & verification/code*
o add a little bit of code to gad_os7mp_adv_?.F to help vectorization
o add new diagnostics to seaice: advective, diffusive fluxes (only for
  multidim-advection, for scheme 2 they are not filled) and transports,
  thermodynamic growth rates
o change units of EmPmR (inside the code, + within coupling interface)
  from m/s to kg/m2/s (mass flux) but leave input file unchanged.
  Affects results @ truncation level (cg2d match) and update output of
   experiments: lab_sea(6), global_ocean.90x40x15(10),
  global_ocean.cs32x15(11x3,10), natl_box(11), tutorial_global_oce_latlon(11)
  + adjoint results: global_ocean_ebm(11) and lab_sea (12).
  Coupled set-up: allow to restart from previous pickups (cpl_oldPickup=T).
  Next: will retire convertEmP2rUnit (simply using mass2rUnit instead).

checkpoint59h (2007/09/29)
o pkg/exf:
  - improve vectorization by moving if-statement out of loops in
    exf_mapfields, exf_radiation
  - exf_bulkformulae.F: introduce 2D fields and vectorize code
o pkg/kpp: added the salt plume scheme (ALLOW_SALT_PLUME) to KPP package
o testreport:
  - allow to test for Qnet & SeaIce monitor output; clean-up ALLOW_BULK_OFFLINE
    monitor & update offline_exf_seaice exp. output.
  - AD testing: pass/FAIL according to Grad. output accuracy (instead of Cost)
o pkg/seaice:
  - bug fix in the evp solver: boundary conditions were affected be
    masking of zMax/zMin (changes results)
  - minor bug fix in boundary conditions in seaice_calc_strainrates
    (changes results for no_slip)
  - seaice_lsr.F: make interpolation of eta dependent on boundaries
  - replace hardcoded lower limit for zeta (zMin) by runtime parameter
  - add a test to lab_sea, that tests the Hibler and Bryan (1987) ocean
    stress formulation and no-slip boundary conditions
o pkg/ptracers: Temporary fix for PTRACERS_useGMRedi & PTRACERS_useKPP
  in gad_calc_rhs.F ; add few safety stops in initialisation phase.
o pkg/seaice: a first HSALT time stepping equation has been checked in
o pkg/seaice: replaced maskW with seaiceMaskU and maskS with seaiceMaskV
  in seaice_lsr.F; this solves the pkg/seaice-pkg/obcs problem
  without requiring DO-IF statements
o pkg/thsice:
  use continuous power-law function for partition of energy between lateral
  melting/freezing and thinning/thickening ; old code using step function
  still available with #undef THSICE_FRACEN_POWERLAW
  update output of exp: aim.5l_cs.thSI, global_ocean.cs32x15.icedyn & .thsice
o testreport: change AD testing : check against results/output_adm.txt
  using same scripts as for forward test.

checkpoint59g (2007/09/17)
o adjoint testing: in preparation for changing testreport:
  - output format: cost and grad written on separated lines
  - ad output results in directory "results" (instead of "results_ad")
o pkg/seaice: adding ice salinity HSALT as a prognostic variable
o pkg/seaice: changes for using pkg/seaice with pkg/obcs
o pkg/ecco: allow user defined cost function contributions
o testreport:
  Allow to choose (per experiment) the list of tested output variables
   and the main variable (used to issue a pass/FAIL ) ;
  - for now, done by adding the specific list in file: [exp]/input/tr_checklist
  - default is unchanged: >cg2d< , (T,S,U,V,5 tracers)_[min,max,mean,StD] ;
  Also modify printing of summary:
   a) ">" NN "<" indicates the "main" variable (used for pass/FAIL)
   b) echo the list of tested variables in the individual summary.txt of
      each experiment.
o new S/R GLOBAL_SUM_TILE to compute global sum independently of number of
  threads and number of processes (with #define GLOBAL_SUM_SEND_RECV)
  (but still depend on the tile decompostion of the domain).
o pkg/seaice: change a discretization detail to make the B-grid code
  "more symmetric". This change is likely to remove all "ridges/leads" that
  where quasi-aligned with the grid in B-grid solutions. It may also be
  the solution to the stress coupling issues with the B-grid.
o each tested exp: add a "run" directory with a standard ".cvsignore" file ;
  remove .cvsignore from input dir. (since testreport no longer run here).
o pkg/thsice:
 - cleaning: move common block out of "THSICE_2DYN.h" (removed) to "THSICE_VARS.h"
 - fix reshaping of sea-ice just after advection:
   melt all the ice only if ice-volume is too small.
 - re-visit lateral/thinning repartition of melting (modifs from May 04, 2007):
   prevent lateral melting if sea-ice fraction is too close to iceMaskMin ;
 and update experiment global_ocean.cs32x15.icedyn (+start from pickup files).
o external_forcing_surf : extend the use of salt_EvPrRn & temp_EvPrRn (fresh-water
  tracer content) to linFS or no RealFreshWaterFlux ; default remains unchanged.
o define mass2rUnit & rUnit2mass as units conversion factor, used for surface
  forcing. mass2rUnit: from mass per unit area [kg/m2] to r-coordinate unit
  (z-coord: =1/rhoConst ; p-coord: =gravity) ; rUnit2mass is just the reverse;
  and remove horiVertRatio (& recip_horiVertRatio). Affects truncation error
  of exp. global_oce_in_p: 10 16 16 14 16 13 16 16 16 13 13 13 16 13 13 12 16
  -> update output.txt
o pkg/cd_code: add brackets in multiple terms sum (S/R CD_CODE_SCHEME):
 this affects truncation error: -> update output.txt of exp:
  global_ocean.90x40x15 (fw&adm), lab_sea (fw&adm) & lab_sea.lsr,
  ideal_2D_oce, isomip.htd, natl_box, tutorial_global_oce_latlon.

checkpoint59f (2007/08/21)
o pkg/autodiff: zero_adj resets an ajoint variable to zero (in adjoint mode)
o pkg/ctrl: ctrl_bound  forces parameter corrections to stay in
  a bounded range (in forward mode)
o pkg/ecco, ctrl, autodiff and mom_common:
 internal parameter controls, completements of implementations
o add few EXCH S/R (UV_BGRID, UV_DGRID, SM) for B & D-Grid velocity & 2nd Moment Sxy.
o use UV_BGRID exch for dxV,dyU: for now, only with pkg/exch2 & forward ;
  (not seem any difference in testing results).
o pkg/cd_code: use the right EXCH calls (for CS-grid); but problem remains
   at face corners.
o pkg/generic_advdiff:
 - in GAD.h, define as parameters (iMinAdvR,iMaxAdvR,jMinAdvR,jMaxAdvR)
  loop range indices for computing vertical advection tendency
  and do the calculation in the interior only (no overlap) ;
  for now, only implemented for SOM advection (to save CPU time).
 - add argument "withSigns" to S/R FILL_CS_CORNER_TR_RL (needed for SOM_xy moment)
o exch2 adjoint
  First set of changes:
  - add exch2 hand-written adjoint templates
  - exch2 hand-written no longer use TAF-flag 'nownew_arg'
    This will require cleanup in pkg/autodiff/*.F
    (changed routines currently kept separate in verif. code/)
  - Comment all relevant #ifndef ALLOW_AUTODIFF_TAMC
    that used to hide exch2 or cubed-sphere specific code
    (commented via 'cph-exch2')
o pkg/seaice
  - Close southern and western boundaries for UICE/VICE when useOBCS=.TRUE.
o pkg/bulk_force: fix loading into Qsw of Short-Wave flux; and update
   output of global_ocean.cs32x15.thsice .

checkpoint59e (2007/07/26)
o exch2: new S/R that only use the cube-tracer (center-position) exchange:
  for B-grid vector (not yet tested) and C-grid vector (<- only used
  when option W2_USE_R1_ONLY in W2_OPTIONS.h is defined).
o starting implementation of Duffy et al. (GRL 1999) salt plume scheme
  (#ifdef ALLOW_SALT_PLUME)
o gather_2d/scatter_2d: removed halo regions
o gmredi: add option (GM_taper_scheme='fm07') for Ferrari & McWilliams 2007
  scheme and the corresponding test case (under front_relax dir). For now,
  only available with Skew-flux form and not yet tested in realistic set-up.
  adjoint: store directives updated, but gradient checks deteriorated,
  so maybe GM/Redi adjoint is now broken.
o seaice adjoint
  * add AREA, HEFF, HSNOW as control variable
    (should not change lab_sea results)
  * CTRL_OPTIONS.h needs new flag: CTRL_SET_OLD_MAXCVARS_40
o pkg/seaice:
  * added computation of saltFlux in seaice_growth;
    For time being, sea ice salinity is assumed constant
    contribution of snow flooding to freshening of sea ice is neglected.
    SEAICE_salinity is set in SEAICE_PARM01 of data.seaice and it
    defaults to 0.0 in order to maintain backward compatibility.
    Typical values for SEAICE_salinity are 4 to 10 g/kg.
  * replaced dRf(1) with dRf(kSurface)*hFacC(kSurface) in seaice_growth.F
  * added SEAICE_availHeatFrac, which specifies fraction of surface level
    heat content used to melt or grow ice
  * commented out cap of HICE: it helps keep ice thinner
  * reintroduced cap of HEFF via MAX_HEFF and SEAICE_CAP_HEFF option
  * applied OBCS T/S mask to HEFFM sea ice mask

checkpoint59d (2007/06/21)
o standard name: {PKG}_DIAGNOSTICS_STATE to fill diagnostics array
 for {PKG} state variables, and called from DO_STATEVARS_DIAGS.
 (keep {PKG}_DIAGNOSTICS_FILL for non-state variables diagnostics)
o pkg/gmredi (gmredi_readparms.F): add some missing "_d 0"
 and change default value of parameter "GM_Small_Number";
 update output of exp: lab_sea (x2), cfc_example, global_ocean.90x40x15,
   global_ocean.cs32x15 (x4), global_ocean_ebm, global_with_exf,
   tutorial_global_oce_biogeo, tutorial_global_oce_latlon
o pkg/ecco: cost function when applying pkg/smooth to controls
o pkg/ctrl: add forcingPrecond run time parameter
o pkg/seaice:
 - replace ZMIN=4.e8 with ZMIN=0. in dynsolver.F as in C-grid code
 - fix bug in metric terms of u-equation in LSR solver (implicit part),
   changes verification/lab_sea
 - rearrange implicit part of u-equation in LSR solver to make it easier to
   read, understand, and debug. This causes changes at the truncation level.
 - fix (serious) bug in the boundary conditions (sign error in the implicit
   part) of the LSR solver. Changes all LSR results.
 - fixed problem with HSNOW initialization to avoid thick snow when AREA
   is initilized with small values - does not change lab_sea results.
 - added HsnowFile initialization capability
o pkg/smooth: addition to model/src and pkg/ctrl so allow
 initialization of pkg/smooth and application to control vector
o pkg/seaice: fix another bug in the LSR no-slip boundary conditons
o dependencies: pkg/profiles requires pkg/cal
o pkg/profiles:
 - added option ALLOW_PROFILES_GENERICGRID
     -> pkg/profiles can thus be used with any grid (e.g. cs32x15) assuming
     that interpolation information (grid points and coefficients) is provided
     within the netcdf input files.
     -> sample matlab scripts can be found in MITgcm_contrib/gael
     that allow you to prepare netcdf input files.
 - also modified: cleaner include statements, cleaner error print statements,
   cleaner stops when error, and more tests of the netcdf input files consistency.
o additional test (in global_ocean.cs32x15) using seaice+thsice pkgs.
o pkg/seaice:
 - move seaice-diagnostics from seaice_do_diags to do_statevars_diags; this
   requires a new routine: seaice_diagnostics_fill.F
 - make sure that seaice does not move if not forced (pressure replacement
   method, Hibler and Ip, 1995), changes results
 - and new damping criterion for EVP solver according to Hunke, JCP, 2001
 - SEAICE_evpDampC = > 0. turns it on (615. is the recommended value).
   It is turned off by default (=-1.), because it changes the results.
 - make it possible to read AREA from a file, too.

checkpoint59c (2007/06/04)
o add S/R and diagnostics for oceanic mixed-layer depth
o move GMRedi call after all vertical mixing schemes (including KPP)
o pkg/thsice:
 - ensure iceMask > iceMaskMin : this problem appeared after May-04 modifs
  (melt only laterally if thin ice): update output of global_ocean.cs32x15.thsice
o pkg/obcs:
 - bug fix for balance code
o pkg/seaice:
  - allow values of SEAICE_elasticParm > 1
  - add new parameter SEAICE_evpTauRelax as an alternative
    to SEAICE_elasticParm
  - make lsr boundary conditions free slip (by default), changes result
  - add code for no slip boundary conditions for lsr
  - set minimum of zeta to zero (and not 4e8) (changes results)
  - add a cap on AREA after advecting AREA if seaice_growth is not called
o change calculation of Visbeck K:
  - no longer depend on tapering scheme; instead, compute slope (limited
    by GM_maxSlope). this is equivalent to what was comuted before with
    clipping or linear tappering.
  - fix vertical averaging (wrong by 1/2 level)
  - leave the old version (but will not be maintained) within
    #ifdef OLD_VISBECK_CALC / #endif
  - update output of exp. ideal_2D_oce
o change error catch in calc_r_star to improve vectorization
o exf runoff and seaice: remove ALLOW_SEAICE from exf pkg files and
  add #define ALLOW_RUNOFF in SEAICE_OPTIONS.h (when not using exf).
o adjoint:
  Re-organized adjoint checkpointing according to Matt Mazloff
  (but with modifs/completions/cleanups)
  Storing is now bundled into large arrays to optimized I/O
  (and second step in cleanup of the_main_loop)

checkpoint59b (2007/05/16)
o coupler (pkg/atm_ocn_coupler, pkg/ocn_compon_interf, pkg/atm2d):
  - export/import (between ocean & coupler) fields needed for ocean DIC.
o pkg/seaice:
  - get rid of three more exchanges seaice_calc_viscosities (required
    different loop boundaries in seaice_lsr and seaice_ocean_stress)
  - bug fix in seaice_ocean_stress (update of lab_sea required)
  - reduce loop boundaries to necessary minimum also in seaice_evp
  - go back to the old way of computing deltaC/Z as the adjoint likes that
    better
o Refresh of tutorial_global_oce_latlon (includes changing salinity-like
  passive tracer to an Age Tracer) + update output.txt
o pkg/exf:
  - implement A-grid / C-grid selection for wind-stress input files.
  - clean-up exf_wind.F (remove us, use wspeed instead ; add wStress)
  for now, in exf_bulk_largeyeager04.F only :
  - change implementation for case where windspeed + 2. components wind-stress
    are read-in. AND use rhoConstFresh to convert evap.
o pkg/seaice:
  - use correct EXCH_UV for wind-forcing (on A-grid).
  - change SEAICE_OPTIONS.h to limit the number of option combinations (regarding
    SEAICE_EXTERNAL_FORCING & SEAICE_EXTERNAL_FLUXES); add corresponding stops.
o pkg/exf:
  - default EXF options are now set in EXF_OPTIONS.h (ifndef ALLOW_AUTODIFF_TAMC)
  EXF_INTERPOLATION:
  - merge global_with_exf/code version of exf_interp_read.F
    to the main code ;
  - Add new option: EXF_INTERP_USE_DYNALLOC to use Dynamical Allocation when
    reading the file ; Important: This options needs to be defined to recover
    previous code.
    otherwise, use fixed size array to read in (size=exf_interp_bufferSize).
  - no longer loose real*8 precision along the way when using exf_iprec=64.
o pkg/seaice: rearrangement of common blocks (really needs more cleaning up)
  - change discretisation of evp-solver in order to avoid another exchange
    (changes lab_sea) and clean up a little
  - replace SQRT(MAX(deltaC,SEAICE_EPS)) by MAX(SQRT(deltaC),SEAICE_EPS)
    help the adjoint (this also changes the results slightly)
  - add a few "_d 0" where they had been missing in seaice_evp.F
  - cleaning up: remove unused seaice_calc_rhs.F
o pkg/exf: some cleaning-up:
  - change various "constants" into runtime parameters
  - cleaned-up Large&Yeager04 routine which should eventually
    replace exf_bulkformulae.F (changed names of S/R and CPP)
    and merged various ALLOW_ATM_WIND options
 only used with thsice pkg (in thsice_get_exf.F):
  - implement fixed turbulent transfert Coeff over ice (as in Large&Yeager04)
    which are used when useStabilityFct_overIce=TRUE (= the default)
  - change default values of ice & snow emissivity and scale downward LW
    by ice & snow emissivity.
o pkg/thsice:
 fix few little problems, in thsice_calc_thickn.F:
  - growth vertically (and not laterally) if iceFrac == iceMaskMax
  - melt only laterally if hIce < hThinIce (as the comments say)
  and in thsice_extend.F:
  - allow to form ice even when iceFrac == iceMaskMax (by increasing thickness)
  - start to form ice as soon as the minimum ice-volume is reachable.
 update output of test-exp: aim.5l_cs(thSI), global_ocean.cs32x15(thsice),
  and cpl_aim+ocn
o pkg/kpp
 - move computation of surface related input fields to KPP into a new
   subroutine kpp_forcing_surf.F
 - remove wrong (within bi,bj loops) EXCH calls.
 - little cleaning (add argument myThid in last position, cvs header ...)
 - for now, fix conservation problem by exchanging KPPviscAz (may not
   be the best fix)
o pkg/seaice
 - check for inconsistent evp parameter/cpp-flag combination
 - remove leftover errIO flat for obsolete name list error handling
o OpenAD
 - changed verification/OpenAD to full baroclinic setup (including GM/Redi)

checkpoint59a (2007/05/01)
o pkg/seaice: some parameter clarifications and a little bit of clean up
o pkg/thsice: rename run-time parameters:
   himin       -> hIceMin
   himin0      -> hThinIce
   hihig       -> hThickIce
   i0          -> i0swFrac
   transCoef   -> bMeltCoef
   frac_energy -> fracMelting
  add new parameters: hNewIceMax, fracFreezing, dhSnowLin
   with default values (for now) that do not change the results.
  remove old version of thsice vars advection in pkg/seaice.
o in FFIELDS.h:
  - replace #ifndef ALLOW_EXF  by #ifndef EXCLUDE_FFIELDS_LOAD
  - make pLoad & sIceLoad always available (but still only used if
     ATMOSPHERIC_LOADING is #define).
o pkg/kpp: replaced _KPP_RL with _RL
o bug fixes for vertical diffusivity computations when both KPP and
    3D diffusivity arrays are used; pkg/kpp/kpp_calc_diff_s & _t.F
    are no longer updating the vertical diffusivity array
    (passed as argument) but are (re-) setting those arrays.
o pkg/seaice: fix bug in evp solver, while doing that
  - change (improve?) discretization of stress computations for both
    cgrid-lsr and evp solver
  - add a new routine to compute strain rates
  - the above changes lab_sea results
  - add no slip conditions for evp solver (off by default), lsr-version
    may follow
  - fix exchange for shear at Z-points (does not change lab_sea)
  - retire SEAICEuseEVP, instead turn on EVP by setting SEAICE_deltaTevp
    (to force the user to pick a time step since there is not "safe" way
    of choosing it)
  - add principal stress diagnostics
  - rearrange fields for evp a little to avoid having to call a: too many
    exchanges and b: exchanges for stress trensor components which we do
    not have.
  - modify Hibler+Bryan (1987) stress coupling so that it reuses information
    of evp, complete rewrite for lsr case (latter is does not yet work
    in all cases)
o pkg/kpp: add code to have mixing in shelf ice caverns
  - add myThid to all kpp routines (long overdue)

checkpoint59 (2007/04/19)
o pkg/exf:
  - fix wind-stress location: defined on A-grid (if ALLOW_ATM_WIND &
    ALLOW_BULKFORMULAE or USE_EXF_INTERPOLATION), otherwise, defined on C-grid
  - move exf header files from lower_case.h to UPPER_CASE.h ;
    add missing cvs Header & Name
  - add adjoint routines and flow dirs for newly used exch_uv_agrid routines
  - add namelist param. selectStressGridPosition, exf_monFreq
  - retire many _CLIM routines, and remove data.exf_clim
    + params moved to data.exf
    + climsst, climsss now handled by exf_set_gen, i.e.
      climss?period=0 refers to constant field,
      climss?period=-12 to monthly forcing
  - split up namelists in data.exf
o pkg/seaice:
  - remove seaice_exch and seaice_exch_uv
  - remove superfluous exchange of theta
  - add myThid to seaice_budget_ocean/ice
  - add new interface for atmospheric wind forcing (C-grid only)
    + new routine
    + two new field (taux, tauy for stress over ice)
    + removed one global field (DAIRN) for C-grid case only
o pkg/thsise
  - 2nd set of modifs for thsice adjoint in conjunction with exf
o enable runtime flag useEXF (useCAL is set to .T. if useEXF=.T.)

checkpoint58y_post (2007/04/15)
o Added capability for latitudinal dependence of Bryan and Lewis, 1979
  vertical diffusivity, similar to that in MOM4; turned on using
  #define ALLOW_BL79_LAT_VARY in CPP_OPTIONS.h and specified using
  diffKrBL79*, diffKrBLEQ*, and BL79LatVary in runtime data file.
o Added capability for 3D specification of background vertical diffusion
  coefficient.  This is done by (i) #define ALLOW_3D_DIFFKR
  in CPP_OPTIONS.h and (ii) specifying file diffKrFile in runtime
  "data" file that contains the 3D vertical diffusivity coefficients.
o ice dynamics (pkg/seaice) with thsice thermodynamics:
  - add code within pkg thsice to advect & diffuse sea-ice fields
  similar to (and will replace) what has been added in  seaice_advdiff.F,
  but: - conserving Mass, Heat & Salt.
       - better when using non-linear advection scheme (not yet fully tested)
       - can also be used in atmospheric set-up (for now, only the diffusion).

checkpoint58x_post (2007/04/04)
o IO option for global-file compact format:
  - add options when generating topology (utils/exch2/matlab-topology-generator)
  - add I/O capability (pkg/mdsio).
  - adapt utils/matlab/rdmds.m to read this format.
  for now long-line format not yet supported by pkg/mdsio (& exch2).
o shelfice: add a few diagnostics

checkpoint58w_post (2007/03/13)
o p-coord. non-hydrostatic using reference profile for w <-> omega conversion:
  rVel2wUnit & wUnit2rVel are computed from reference profile Tref,Sref
  (and replace horiVertRatio in NH code).
  Update output of exp.: tutorial_global_oce_in_p (useNHMTerms !)
                     and tutorial_plume_on_slope (sensitive to truncation)
o seaice: if ALLOW_ATM_WIND is undefined use wind stress
  directly to drive seaice model (C-grid only)
o exf: when input wind-stress (#undef ALLOW_ATM_WIND):
 - reintroduce computation of wind from stress,
 - compute tau (in exf_bulkformulae.F) from windstress averaged to
   mass points to avoid tau = 0
 - fix serious bug: (1/3) in Fortran is not the same as (1./3.)
o rdmnc.m: make it work with "global" files created with gluemnc
o rdmnc.m : some improvements in dealing with singleton dimension
  (tested on all testreport mnc output files).
o genmake2: disable pkg/profiles if netcdf test fails.
o cpl_aim+ocn exp.: use consistent rhoConstFresh in Atm & Ocn; update output.
o move call to cal_readparms up to make calendar parameters/variable available
  to all packages

checkpoint58v_post (2007/02/08)
o change EOS (from POLY3 to JMD95P) in global_ocean.90x45x15 to get
  useDynP_inEos_Zc tested.
o pkg/exf: changes to properly interpolate/mask/scale initial fields
o utils/matlab/cs_grid/read_cs: routines to speed up reading of CS510 fields
  and portions thereof.  See read_cs.txt for description and examples.
o utils/matlab/cs_grid/bk_line: to compute transport through passages,
  add a script (grt_circ_bkl.m) to generate broken-line between 2 points,
  following the great-circle arc between those 2 points.
o trap un-initialized variable with pathscale compiler on weddell.mit.edu
  (thanks to Constantinos): fix few problems and get (almost) all exp to pass.
o 2nd-Order Moment Advection Scheme (Prather, 1986): first check-in
 - enable by setting #define GAD_ALLOW_SOM_ADVECT (in GAD_OPTIONS.h)
 - used without limiter (AdvScheme=80) or with Prather limiter (AdvScheme=81)
 - still needs work (not working with some options ; efficiency to improve)
   and serious testing.
 - use this scheme for temperature & salinity in 2 advection test exp.:
   advect_xy & advect_xz, respectively.

checkpoint58u_post (2007/01/12)
o new test-exp: fizhi-cs-32x32x40 (40 levels) to replace the 10 levels.
o move call to INI_FORCING from PACKAGES_INIT_VARIABLES to INITIALISE_VARIA.
o testreport: add option "-skipdir" to skip some test.
o exf: when input wind-stress (#undef ALLOW_ATM_WIND), by-pass turbulent
  momentum calculation.
o gad_advection: fix vertAdvecScheme (if different from advectionScheme)
o some cleaning: usePickupBeforeC35 no longer supported ; remove this option.
  remove checkpoint.F and the_correction_step.F (no longer used);
  do the k loop inside CYCLE_TRACER (supposed to be more efficient).
o add option (linFSConserveTr) to correct for tracer source/sink due to
  Linear Free surface
o pkg/seaice: fix a bug in the flooding algorithm: turn off the snow machine
o pkg/thsice: fix reading mnc-pickups

checkpoint58t_post (2006/12/30)
o pkg/diagnostics: fix multi-threaded output (when singleCpuIO=F)
o pkg/mdsio:
 - clean-up mdsio_readfield.F & mdsio_writefield_new.F and
   move to new files: mdsio_read_field.F (S/R MDS_READ_FIELD) &
   mdsio_write_field.F (S/R MDS_WRITE_FIELD);
 - fix multi-threaded singleCpuIO option in MDS_WRITE_FIELD
 - collect old S/R  in one file: mdsio_rw_field.F (now just a call to
   either MDS_READ_FIELD or MDS_WRITE_FIELD )
 - new S/R (to replace MDSWRITEMETA), which allows to write more
   informations (variable names, time ...) to meta files.
 - modify rdmds.m to give back the meta file content.
o pkg/diagnostics: change vertical interpolation to be safer, and more
   flexible (define p-levels to interpolate to in data.diagnostics);
  add argument to S/R DIAGNOSTICS_GET_POINTERS to catch the right
   diagnostic pointer.
o pkg/seaice: more cleaning up of seaice_growth, added many comments
o pkg/exf: put runoff0 and runoff1 into the appropriate common block
o fix multi-category seaice:
 - change cpp flag SEAICE_MULTILEVEL to more meaningful name:
   SEAICE_MULTICATEGORY
 - fix short wave heat flux
o pkg/seaice: change default (SEAICE_OPTIONS.h): use C-grid dynamics
   and allow to use EVP solver. Change forward lab_sea: test both EVP
   solver and LSR solver, and use C-grid dynamics (like lab_sea adjoint)
o Initial check-in of lab_sea adjoint
  (very similar to natl_box_adjoint/code_seaice)
  * used C-grid and EVP solver
  * used KPP, GM/Redi
  * uses inAdExact=.TRUE.
  * gradient checks fail for both ADM and TLM
    due to sensitive snow melt code in seaice_grwoth (look for "JZ")
    f.d. gradients actually seem more problematic than ADM, TLM gradients;
    issue is related to forward mismatch between g77 an ifort
o pkg/seaice: overhaul of thermodynamics
 - growth.F and groatb.F are replaced by new routine seaice_growth.F
 - budget.F is replaced by two new routines seaice_budget_ocean/ice.F
 - move a few global fields out of SEAICE.h into seaice_growth.F and
   make them 2D (FICE/QNETO/ ...)
 - remove FO (it is the same as QNETO)
 - introduce a few local fields to avoid modifying external fields such
   as atemp, etc.

checkpoint58s_post (2006/12/11)
o pkg/exf: moved exf_init_runoff.F to exf_init.F and exf_set_gen.F
  changed exf_set_gen.F so that
    genperiod=0 means input file is one time-constant field and
    genperiod=-12 means input file contains 12 monthly means
o CG2D: use pre-computed solver main-diagonal (stored in common block);
  this affects truncation error ; generate new output file for exp. which
  fails: exp4(12d), fizhi-cs-aqualev20(12d), front_relax(10d),
    global_ocean.90x40x15(10d), global_ocean.cs32x15(10d).thsice(11d).viscA4(10d),
    ideal_2D_oce(10d), internal_wave(09d), isomip.htd(11d), matrix_example(07d),
    MLAdjust(4x11d,12d), natl_box(11d), rotating_tank(12d),
    tutorial_global_oce_in_p(10d), tutorial_plume_on_slope(11d),
    vermix(12d).ggl90(12d).my82(11d).opps(12d).pp81(11d)
o start implementation of deep-atmosphere and anelastic formulation
o verification: remove 2nd copy of input files and use script "prepare_run"
  to make a symbolic link to the 1rst copy (reduce downloaded size by ~81.M)
o mom_common/vecinv/fluxform: fix a few initialisation isssues
o profiles: fix for multithreaded case

o diagnostics: rename few diags:
  s/'PRESSURE'/'RCENTER '/g
  s/'TICE    '/'oceFreez'/g
  s/'TAUX    '/'oceTAUX '/g
  s/'TAUY    '/'oceTAUY '/g
  s/'SWFLUX  '/'oceQsw  '/g
  s/DIFx/DFxE/g
  s/DIFy/DFyE/g
  and add few ocean-forcing diagnostics:
  atmPload, sIceLoad, oceQnet, oceFWflx, oceSflux, surForcT & surForcS
o modifications to pkg/seaice/growth.F and budget.F, which change results of
  lab_sea experiment: HSNOW was sometimes treated as effective and sometimes
  as actual snow thickness.  It now refers everywhere to effective snow
  thickness, meaning that for non-zero AREA, actual thickness is HEFF/AREA.

checkpoint58r_post (2006/11/17)
o modifications to pkg/seaice/growth.F, which change results of
  lab_sea experiment: fixes pertain to melting snow over open water, to
  masking EVAP under sea ice, and to using the correct AREA variable for
  computations of EVAP, PRECIP, HSNOW, and GHEFF
o add ability to read bathy, salt, and theta using MNC (off by def)
o add flooding algorithm and advection of HSNOW for pkg/seaice;
  both are turned off by default and do no change any results
o seaice advection with pkg/thsice: a step toward the use of non-linear
  advection scheme, but #ifdef or commented out for now (requires more EXCH).
o use standard version of PTRACERS_INI_VARIA in tutorial_tracer_adjsens
  (identical results) and the standard version of EXTERNAL_FIELDS_LOAD
  in natl_box (affects results @ truncation level: update output.txt)
o multi-threading and IO:
  - replace some call to MDSIO S/R by the corresponding READ/WRITE_FLD S/R.
  - remove most of BEGIN_MASTER/ END_MASTER around READ/WRITE_FLD S/R calls
    (needed to work with SingleCpuIO): tested in all verif. exp.
o GAD: use simpler DST3 formulation as default (old version left within #ifdef)
  affects the results (but none of the verification test uses this scheme).
o Adding some pkg/diagnostics capability to pkg/seaice
  (will certainly be subject to changes)
o ctrl: adding new control variables:
  lwflux, lwdown, evap, snowprecip, apressure, runoff

checkpoint58q_post (2006/10/20)
o added CPP_EEOPTIONS.h flag DISABLE_MPI_READY_TO_RECEIVE.  Speeds up
  1/6-deg Southern Ocean configuration by 8% on IBM Datastar and
  high_res_cube configuration by 4% on Columbia.
o clean-up multi-threaded problems (reported by debugger tcheck on ACES);
  add (in global_with_exf/code) a version of EXF_INTERP_READ without
  dynamical allocation (seems to work in multi-threaded).
o new function "MASTER_CPU_IO" (=T if master thread & master CPU, if using
  single CPU io) so that TAF does not have to see EESUPPORT.h
o pkg/seaice: implement sea-ice loading (when using RealFreshWaterFlux)

checkpoint58p_post (2006/09/08)
o obcs: stop if obcs is used with useCDscheme = .true.
o shelfice:
 - fix a sign error so that no slip at shelfice interface works
 - remove stop for combination non-hydrostatic code and shelfice. That does
   not mean, that the results are correct, but at least they are numerically
   stable
o diagnoctics: modify UVELPHI and VVELPHI to include hfac (i.e. mass-weighted)
o added adjoint exch routined for all exch*3d* routines
  and updated flow directives

checkpoint58o_post (2006/08/28)
o replace calls to EXCH_Z & EXCH_UV_AGRID: use the new _3D_ version ;
  remove old subroutines (_XY_ & _XYZ_); update the adjoint version.
o change controling S/R for writing pickup file (new S/R do_write_pickup)
  and clean-up reading/writing of pickup files.
o fix local version of read/write pickup (NH part) in rotating_tank/code
o simplify EXCH interface:
 - change _XYZ_ interface to _3D_ subroutine (with 3rd dim in argument list)
 - not often used EXCH S/R (exch_z, exch_uv_agrid): keep only the _3D_ version
o added the regrid package
o shelfice:
 - add a simple boundary layer scheme to reduce noise
 - fix the indexing in shelfice_u/v_drag so that there will be actually drag

checkpoint58n_post (2006/08/14)
o fix globalArea multi-threaded calculation: need to apply GLOBAL_SUM to
   local variable (not in common block).
o lot of small changes for multi-threaded. Most tests (using OMP & ifort) pass.
  - still problems with pkgs: mnc, exp2, dic, cal, exf (and probably more);
  - still BEGIN_MASTER/END_MASTER to remove around READ/WRITE_FLD S/R calls
    to work with SingleCpuIO.
o add "_d 0" to real constant of pkg/cfc subroutines ;
   update exp. cfc_exemple & tutorial_cfc_offline output files.
o multi-threading and IO:
  - all threads call READ_FLD S/R (needed if using SingleCpuIO):
    (no BEGIN_MASTER/ END_MASTER around the call, but inside MDSIO S/R.
  - barrier before and after reading.
  - stop if other than master is calling MDS_WRITELOCAL (if #undef IO_THREAD_SAFE)
  - avoid using MDS_WRITELOCAL for LAND pkg output.
  - new S/R AIM_WRITE_PHYS (replaces AIM_WRITE_LOCAL) to write AIM physics
    common-block variables ; Allows multi-threading with master-thread IO.
o change default MAX_NO_THREADS from 32 to 4 ;
  and stop cleanly when MAX_NO_THREADS is too small.
o add S/R BAR_CHECK to check multi-threaded barrier synchronization

checkpoint58m_post (2006/07/17)
o add a Non-Hydroatatic test (with 3-D Coriolis, NHMTerms, biharmonic Visc.
   and side-drag) on CS-grid : global_ocean.cs32x15.viscA4
o make "tutorial_global_oce_latlon" from standard "global_ocean.90x40x15" exp.
   keep global_ocean.90x40x15 (for AD testing) with former secondary test
   (".qshyd") as the main test (mv output.qshyd.txt to output.txt)
o CVS modules: update MITgcm_verif_basic; remove MITgcm_verif_ocean & _verif_atmos;
    add MITgcm_tutorials (= code + all the tutorials)
o ecco, option to compute cost for total ssh (mean+anom)
o consistent with addition of ptracer and ssh in pkg/profiles
o profiles: adding ptracer and ssh
o testreport: change multi-test output-file name
  (from output.txt.{name} to output.{name}.txt)
o profiles: now ok for mutli-tiles case
o seaice: add 4 parameters for different advection schemes for area,
  (effective) seaice thickness, enthalphy, and snow height. Their default
  is the standard parameter SEAICEadvScheme
o calc_gw:
 - add cosFacU in zonal viscous flux (harmonic.visc.).
 - put back side-drag (call new S/R MOM_W_SIDEDRAG) and output.txt.
   of tutorial_plume_on_slope.
o obcs_calc.F : fix index Pb in OBSeta & OBNeta (Thanks to Gianmaria).
o calc_gw: true flux-form, account for horizontal grid spacing.
  update rotating_tank results, but not plume_on_slope (affected at
  truncation level, 11 digits).

checkpoint58l_post (2006/07/12)
o calc_gw:
 - take bi,bj loops outside calc_gw to fix Pb with local array KappaRU,V
 - remove side-drag for now (need to fix it); update plume_on_slope results.
 - fix for partial-cell & non-uniform dz; update plume_on_slope results.
o commit code to make SST/SSS weights spatially variable
  (based on either variable in-situ or variable initial T/S weights)
o pkg/ecco:
  * commit code to relax deviations of xx_theta, xx_salt to 5*sigma,
    now based on horizontally varying weights wthetaLev, wsaltLev
  * cost_averagesflags now returns year indices in addition to day, month
  * sflux balance is performed on annual basis
    (sflxumm, sfluxmm2, bal_sfluxmm)
  * for SSH anomaly, separate more cleanly contrib from T/P, ERS, GFO,
    including separate counting and multipliers
o pkg/rbcs
  * add all necessary infrastructure for pkg/rbcs levN adjoint checkpointing

checkpoint58k_post (2006/07/06)
o testreport:
 - always build in dir. "build" (if not there, mkdir build instead of building
   & running in input)
 - run in dir run (if it exists), in build otherwise.
 - call prepare_run (if input/prepare_run exists)
 - run multi-threaded test (with new option: "-mth") if file input/eedata.mth exists.
o pkg/exf modifications to interpolation and rotation routines for more
   reasonable treatment of North Pole singularity: for tracers North Pole
   value is set to northernmost zonal-mean value, for zonal velocity it is
   set to zero, and for meridional velocity it is set to northernmost value.
o pkg/exf/exf_check_range.F
 - add tile index to diagnostics and move stop statement to the very
   end of the routine.
o pkg/diagnostics: (diagnostics_main_init.F)
  define title of isomorphic variables according to the current config.
o pkg/thsice with pkg/seaice dynamics:
- fix domain of computation (interior only, required for exf) and do exchanges
- seaice-dynamics forcing: add atmospheric and seaice loading to SSH gradient
o towards a standard way of dealing with multi-threading in MONITOR
  and ${PKG}_MONITOR (all except ptracers_monitor) subroutines.
o Pass variable viscosities (vertical and horizontal, e.g., KPP or Leith)
   to W momentum equation in nonhydrostatic and quasihydrostatic runs.
o make exf_monitor & seaice_monitor independant of the main (dynamics) monitor.
o pkg/seaice: fix SEAICEuseEVPpickup parameter (put it in a commom block)
o generic_advdiff: DST advection S/R : use local copy of velocity to compute CFL
   (problems ? with gradient check in bottom_ctrl_5x5 adjoint test)
o tracer advection:
 - clean-up and simplify calc_common_factors.F
 - make a local copy of velocity and pass it (as u,v,r_Trans) to DST tracer
   advection subroutine (but still not used within DST advection S/R)
o rename pkg aim_ocn_coupler to atm_ocn_coupler (later on, will be used without aim)

checkpoint58j_post (2006/06/15)
o new driver S/R: LOAD_FIELDS_DRIVER to load external forcing fields
  from file (collects calls previously in FORWARD_STEP)
o move call to SEAICE_MODEL from FORWARD_STEP to DO_OCEANIC_PHYS
o adjoint store dir. adjusted accordingly
o genmake2
  replace target "ad_taf" by $(EXE_AD) ; add $(EXE_AD) to the make CLEAN list.

checkpoint58i_post (2006/06/14)
o pkg/seaice: add parameter that allows to scale/turn off effect of seaice
  on wind stress (SEAICEstressFactor defaults to 1.)
o Total number of Timers is finite (<=40): comment out 2 non-essential one
  in the_main_loop.F to avoid Pb (e.g., when running fizhi test)
o vector_invariant: fix highOrderVorticity(=4.th.Order) advection
  on CS-grid: no longer loosing mass.
o exf & curvilinear-grid: no longer modify longitude xC & xG.
o pkg/ggl90: fix sloppy output and fix a bug
o pkg/seaice: added SEAICEuseEVPpickup parameter
  - Set to false in order to start EVP solver with
    non-EVP pickup files when using SEAICEuseEVP
  - fix sign error in diffusion in seaice_calc_rhs

checkpoint58h_post (2006/06/07)
* Modifications for bottom topography control
  o replace hFacC by _hFacC at various places
  o replace ALLOW_HFACC_CONTROL by ALLOW_DEPTH_CONTROL
  o add non-self-adjoint cg2d_nsa
  o update autodiff support routines
  o re-initialise hfac after ctrl_depth_ini
  o works for 5x5 box, doesnt work for global_ocean.90x40x15
* Adding verification for 5x5 box (4-layer) bottom topography control

checkpoint58g_post (2006/06/07)
o pkg/diagnostics: implement "periodic averaging diagnostics" (e.g.,
   used for mean seasonal cycle, mean diurnal cycle); add an example
   in verification/global_ocean.cs32x15/input.thsice/data.diagnostics
o pkg/ggl90:
  - add parameter (minimum surface kinetic energy)
  - fix bug (avoiding division by zero)
o couple pkg/thsice to pkg/seaice:
  - modify advection in seaice to accomodate new scalar fields to be advected
  - only muliDimAdection scheme work with seaice/thsice
  - mapping of thsice-variables to seaice-variables, back and forth
  - does not break the verification experiments, but does not give the
    desired results either
o pkg/seaice
  - make (default) second order advection a bit less confusing?

checkpoint58f_post (2006/06/05)
o couple pkg/thsice and pkg/exf (as a preparation for coupling pkg/thsice
  to pkg/seaice):
  - new routines thsice_map_exf and thsice_get_exf provide the interface
  - add an additional formal parameter to thsice_solve4temp
o pkg/exf:
  - add new fields wspeed, snowprecip (to be able to couple to thsice)
  - correct Stefan-Boltzmann constant
  - new parameter for longwave surface emittance
  - separate some stuff from exf_bulkformulae into new routines
    exf_radiation, exf_wind
  - add new parameters and constants: longwave emissivity for ocean, ice
    and snow, evaporation parameters over ice
  - decouple wind/stress computation from ALLOW_BULKFORMULA: always compute
    either wind from stress or stress from wind
o pkg/thSIce:
- split thsice_step_fwd.F in 2 S/R: thsice_step_temp.F & thsice_step_fwd.F
- put i,j loops inside S/R: THSICE_ALBEDO, THSICE_SOLVE4TEMP, THSICE_EXTEND
   and THSICE_CALC_THICKN
- for now, call to THSICE_GET_BULKF remains inside i,j loops.
- add CPP option: ALLOW_DBUG_THSICE and header file THSICE_DEBUG.h
  to make debugging easier.
- affects results (@ truncation level) of global_ocean.cs32x15.thsice: update output
o pkg/bulk_force:
  - clean-up comments and parameters ;
  - add new Bulk-Formulae from Large and Yeager, 2004, NCAR/TN-460+STR ;
o fix bug in aim+thsice albedo: snow & ice thickness arguments were switched;
  generate new output for test-experiment: aim.5l_cs.thSI
o results_ad : rename "output.txt_adm" to "output_adm.txt" and change
  testreport accordingly

checkpoint58e_post (2006/05/17)
o SEAICE_CGRID adjoint done
o R_STAR adjoint implemented.
  * Seems to just work (based on global_ocean.90x40x15/code_ad_nlfs/ )
  * need to sort out init. of h0facc, etc.
o Make pkg/profile fully independent of ecco,cost, etc. stuff
  to be able to use it in pure forward.

checkpoint58d_post (2006/04/21)
o upgrade simple test-experiment to tutorial example:
 step.1: duplicate the experiment and (step.2) will remove the old copy.
  tutorial_barotropic_gyre      <- copy of exp0     (R1:barotropic_gyre_in_a_box)
  tutorial_baroclinic_gyre      <- copy of exp1     (R1:baroclinic_gyre_on_a_sphere)
  tutorial_global_oce_latlon    <- empty for now    (R1:global_ocean_circulation)
  tutorial_global_oce_biogeo    <- copy of dic_example
  tutorial_deep_convection      <- almost like exp5 (R1:nonhydrostatic_deep_convection)
  tutorial_plume_on_slope       <- copy of plume_on_slope
  tutorial_tracer_adjsens       <- copy of carbon   (R1:tracer_adjoint_sensitivity)
  tutorial_global_oce_optim     <- empty for now (David ?)
  tutorial_global_oce_in_p      <- copy of global_ocean_pressure
 some tutorials (R1) were already checked-in under tutorial_examples in release1_branch
o correct a sign problem in cost_scat.F
o obcs and ptracers: fix boundary conditions for advections schemes
  with larger stencil
o thsice adjoint: start
o mom_vecinv: add ISOTROPIC_COS_SCALING flags to mom_vi_hdissip for
  completeness
o mom_fluxform: fixing the mutual use of ISOTROPIC_COS_SCALING
  and COSINEMETH_III, add comments in default CPP_OPTIONS.h
o ptracers adjoint:
  * avoid extensive recomputatations
  * fix missing re-init. of gptr (missed by TAF)
o obcs: add a flag (OBCSprintDiags, defaults is true) that allows
  me to turn off the excessive output to STDOUT that this package produces
o move NH metric terms & 3.D Coriolis S/R to pkg/mom_common
  and add those terms in Vector-Invariant formulation.
o in ctrl pkg, if ALLOW_CAL, use monthly mean controls
  if the control period (xx_hfluxperiod etc) is 0
o in profiles pkg, clean routines and fix details
o in ecco pkg, reading ssh data:
  fix problem in case the model does not start at iter0=0
o fix mnc-pickup/restart for ptracers
o new package prifiles:
  code to compute profile-based cost by Gael Forget
  (modifs in ecco, ctrl, autodiff)
o Benign bug fix in initialization (spotted by M. Mazloff) of
  ctrl_set_globfld_xz.F ctrl_set_globfld_yz.F

checkpoint58c_post (2006/03/23)
o adjoint: finish NLFS adjoint and provide reference output in
  verification/global_ocean.90x40x15/results_ad_nlfs
o seaice: add an EVP solver following Hunke and Dukowicz (1997) and the
  documentation of CICE. Turn on by defining SEAICE_ALLOW_EVP in
  SEAICE_OPTIONS.h and SEAICEuseEVP=.true. in data.seaice. Works only
  with SEAICE_CGRID defined.
o move calendarDumps from "data" to "data.cal" and clean-up the code
  with a simple call to pkg/cal S/R: CAL_TIME2WRITE
o add useEXF & useCAL flags (for now, set in hard-coded way)
o add S/R to compute NH-metrics terms & Coriolis f' in vertical momentum
  (were missing in NH mode, and wrong in quasihydrostatic mode).
  waiting for Chris updated version of calc_gw to add those CALLs.
o fix bug in quasihydrostatic S/R ;
  add a test for this option: global_ocean.90x40x15.qshyd
o new S/R "SET_PARMS": set parameters that might depend on the use of some pkgs.
  (called from INITIALISE_FIXED, after INI_PARMS & PACKAGES_READPARAMS)
o add on/off flag useOffLine for package OFFLINE
o seaice:
  - modify advection so that it works also on the C-grid
  - extend loop ranges in seaice_lsr and seaice_dynsolver; fixes
    problem in multi-tile runs with C-grid
  - add flags for clipping ice velocities and/or masking solver forcing
  - fix drag (ocean on ice) formulation and a bug that caused noise in the
    C-grid solver
  - added a few comments to seaice_diffusion.F
  - separate C-grid and B-grid versions more cleanly (UVM and seaiceMaskU/V
    are now exclusive)
  - add a new ocean-ice stress coupling method (Hibler and Bryan, 1987) which
    required re-ordering the code a little:
   + make DAIRN global variable (defined in SEAICE)
   + move computation of the viscosities eta and zeta into a new separate
     routine (because I need to recompute them in seaice_ocean_stress.F)

checkpoint58b_post (2006/03/13)
o AIM+thSIce: fix sign of Short-Wave through the Ice ;
  update output.txt of exp. aim.5l_cs.thSI
o various mnc cleanups and improvements:
  + shrink lookup tables by factor of ~4
  + better error reporting when running out of lookup space
  + able to handle longer path/file names (up to 500 chars)
o adjoint:
  - Another overhaul of store dirs. for NLFS to eliminate  "hidden" recomputations.
  - TBD: "hidden" mom_vecinv recomp. in dynamics
o change forcing_In_AB to affects both T,S forcing and Momentum forcing
 (allow to differentiate between forcing components using new integer flags:
  momForcingOutAB=1/0 & tracForcingOutAB=1/0)
 and add new flag to put Dissipation tendency out of Adams-Bashforth.
o ecco
  - enable trend removal from SSH anomaly obs.
o adjoint
  - a fix for PmEpR when #undef EXACT_CONSERV
  - fix of "hidden" recomp. in thermodynamics (no TAF warnings)
  - try to fix "hidden" recomp. in forward_step for NLFS
    (NLFS seems broken sometimes after I checked it in)
o seaice:
 - add c-grid version of the dynamic solver:
   + three new routines that are the c-grid substitute lsr, dynsolver
     and ostres
   + put a few fields that were local to dynsolver into global common
     blocks, so that I can move the computation of stresses etc into
     seaice_lsr (saves coding but may break the adjoint).
 - replace more hardwired parameters by runtime parameters
 - add ice masks that mask the rhs of the implicit solvers where there
   is no ice (commented out in seaice_dynsolver, because i am not sure
   if this works properly), eventually this should replace the clipping
   of ice velocities in seaice_dynsolver to +/-40cm/s.
o remove the BUILD_INFO.h include from CPP_EEOPTIONS.h and explicitly
  include it only where its needed
o move balancing of fluxes before the call of external_forcing_surf
o seaice:
  - correct units of turning angles (now they are really in degrees)
  - move computation of GWATX/Y out of main routine into dynsolver
  - initialize GWATX/Y in seaice_init
o Apply mask on Fresh-Water flux (needed for SSH forcing).
  update output.txt of exp. global_ocean_ebm & cpl_aim+ocn (affects cg2d residual)
o seaice: add runtime flags for turning angles (default to zero)
o Adding runtime parameter to exf/, ctrl/, to remove on-the-fly global mean
  and trend from exf forcing and ctrl control adjustments
o fix variable aliasing in gad_calc_rhs that cannot be handled by TAF
  (since checkpoint57x_post)
o change the default rotation period to 86164.s = the Earth rotation
o 1rst implementation of Implicit IGW using the 3-D solver (use3Dsolver=T)
  and based on a reference stratification. Tested within hs94.cs-32x32x5.
o seaice advection: add code for choosing between the default (2nd order
  central differences) and multiDim advection schemes provided by
  pkg/generic_advdiff
o seaice:
  - removed all references to SEAICE_GRID.h fields from
    dynsolver, advect, diffus, lsr, without changing the results of lab_sea
    (cubed-sphere configuration will change a little)
  - grid computations in seaice_init are obsolete now.
  - cleaned up code a little so that is easier to read (hopefully).
  - added new (better?) discretizations of default advection and diffusion
    (turn on with SEAICEuseFluxForm)
  - replace 1 in 3d global fields by kSurface in growth.F

checkpoint58a_post (2006/02/13)
o seaice:
  - bug fix in advect.F
o shelfice:
  - separate shelfice load anomaly from pload (breaks with time
    dependent forcing), => introduce constant field shelficeLoadAnomaly.
    Its default is 0., but it may be computed more cleverly from (unknown)
    t- and s-profiles (tRef, sRef) and actual EOS. For now this has to be
    done offline. A good approximation of the pressure load anomaly is
    necessary to avoid large initial adjustment processes underneath
    deep-reaching shelfice.
  - small fix in ISOMIP shelfice_thermodynamics
  - add more sophisticated thermodynamics of Hellmer (1989), this is
    now the default
  - give a few constants more intuitive names
o add code to balance EmPmP and Qnet at the end of do_ocean_physics. Useful
  if bulk formulae are used in long integration (especially EmPmR). Turn
  on with balanceEmPmR = .true. or balanceQnet = .true. in data, PARM01
  if balancePrintMean, the imbalance that is substracted is printed to
  STDOUT.
o fix bug (typo) in obcs_apply_eta.F
o add a new package shelfice which enables us to model the circulation
  underneath shelf-ice with draughts of hundreds of meters.
 - works
 - to do: + include improved thermodynamics
          + check whether kSurfC (from model/inc/SURFACE.h) can be used
            instead of new field kTopC
          + can we use topoFile, Ro_surf and existing code in ini_depth.F
            instead of new field R_shelfIce and new code in ini_depth.F
            and ini_mask_etc.F?
          + adjust vertical mixing schemes?
o seaice pkg:
 - add a cpp-flag to include a simple formula for a salinity dependent
   freezing point of sea water at the surface
 - change the contents of SEAICE_TEST_ICE_STRESS_1 so that zonal and
   meridional stresses are now different (and hopefully correct)
o AIM pkg: change threshold on large-scale condensation to conserve Heat.
   update results of aim.5l_LatLon test ; fix title & units of AIM diagnostics
   and  change 3 diagnostics names (OSR,OSRCLR,KM -> TSR,TSRCLR,DRAG)
o pkg/diagnostics: add options and parameters for regional-statistics
   diagnostics ; define regions by reading a region-mask from a file
   (might add other options later)
o pkg/bulk_force:
 - add option and parameters to use AIM surface-flux formulae.
 - Change loading part: S/R BULKF_FIELDS_LOAD only take care of bulkf_fields ;
   others forcing fields (defined in PARM05, parameter file "data") are loaded
   from S/R EXTERNAL_FIELDS_LOAD, as usually (with useBulkforce = T or F).
 - initialise all bulkf_fields in bulkf_init.F ; do in-lining of exf_bulkcdn.F
 - use the right EXCH call for uwind,vwind (to work on CS-grid).
 - re-arrange header files (move parameters from BULKF.h to BULKF_PARAMS.h)
   and parameters (note: calcWindStress replaces .NOT.readwindstress).
 - cleaner interface with pkg/thSIce (new S/R THSICE_GET_PRECIP).

checkpoint58 (2006/01/12)
o add "--embed-source" option to genmake2 which, when the supporting
  tools can be compiled (as determined by genmake2) will turn on the
  embed_files package which then embeds the entire MITgcm source code
  (*.[fFhc] + Makefile) used for the build within the executable
  - requested by CNH but off by default
  - adds a paltry <9MB to the mitgcmuv executable in most cases
  - only writes the output when useEMBEDSRC in eedata is true
o clean up 3-dim. relaxation codes:
  * Fix I/O inconsistency in pkg/rbcs: replace precFloat32 by readBinaryPrec
  * Remove 3-dim. relaxation code from pkg/exf (now use only pkg/rbcs)
  * Thanks to Tom Haine for testing!

checkpoint57z_post (2005/12/31)
o make CG3D solver compatible with Free-surface at k > 1 (p-coordinate):
  affects output (@ truncation level) of exp. plume_on_slope ; updated.
o fix the pickup behavior for obcs in combination with ptracers
o fix a bug in ptracers_external_fields_load
o no AB-2 at the first iteration for Gw (consistent with Gu,Gv,Gt,Gs ...)
  affects results of NH experiments (but all our NH tests have Gw[it=1]==0 !!)
o transfered surface NH pressure to eta field (if exactConserv).
o gmredi: fix bugs in slope tapering ldd97 (depthZ had the wrong sign)
     and update lab_sea output.txt file.
o completing 3-dim. relaxation code: additional term
     1/tau*( theta(i,j,k) - thetaStar(i,j,k) )
  in S/R EXTERNAL_FORCING_T (file external_forcing.F)
  * At compile time, in "EXF_OPTIONS.h" set
      #define  ALLOW_CLIMTEMP_RELAXATION
      #define  ALLOW_CLIMSALT_RELAXATION
  * At runtime in "data", under &PARM03 set (e.g., units in seconds)
      tauThetaClimRelax3Dim = 15552000.0,
      tauSaltClimRelax3Dim  = 15552000.0,
  * 3 cases:
      1) Use a constant-in-time 3-dim. field
      2) Provide 12 3-dim. fields corresponding to Jan., ... , Dec.
      3) Real-time relax. to time-evolving prescribed field
o Adding Laplacian-type smoothness constraint on
  initial and boundary (forcing) controls (ic, bc)
  * enable at compile-time via
    ALLOW_SMOOTH_IC_COST_CONTRIBUTION, ALLOW_SMOOTH_BC_COST_CONTRIBUTION
  * enable at run-time via mult_smooth_ic = 1, mult_smooth_bc = 1
  * Absolute scale somewhat unclear so far
  * no area weighting was included since no other cost term does so far

checkpoint57y_post (2005/12/08)
First step for a NLFS adjoint
o initially suppress rStar (new flag DISABLE_RSTAR_CODE)
o new init. routines for calc_r_star, calc_surf_dr
o still need to deal with ini_masks_etc
o testreport seemed happy
checkpoint57y_pre (2005/12/08)

o obcs: always reset wVel & eta (to zero or prescribe it) at the OBs.
o add new package rbcs (for relaxing ptracers at boundaries/depth/surface etc)
o add new offset feature to offline pkg (plus minor cleanup)
o cfc fixes for final year of integration
o clean up GCHEM_OPTIONS.h/DIC_OPTIONS.h (all options should
  be in GCHEM_OPTIONS).

checkpoint57x_post (2005/12/04)
o fix testreport Pb in multiple test experiment.
o cleanup our namelist syntax in verification:
  - make it more F95 standards compliant (some work still needed)
  - allows the vast majority of our tests to work with gfortran
o Non-Hydrostatic:
 - put all NH variables (formerly in DYNVARS.h & GW.h) in NH_VARS.h
 - fix exchange calls for CS-grid using the new EXCH_S3D_RL.
o Allow to apply AB on T,S rather than on AB(gT,gS):
 - implemented within #ifdef ALLOW_ADAMSBASHFORTH_3
 - use the same arrays (gtNm,gsNm) to hold tracer field at previous
   time-steps (if AB(T,S)) and tendencies (if AB(gT,gS)).
 - need a "clever" read_pickup to restart from the other AB formulation
o move local commom bloc /GlobalLo/ (used for singleCpuIO) in EESUPPORT.h
o remove some unused variables (reduces number of compiler warnings)
o adjoint
  * Disable useVariableViscosity for adjoint for time being
    (there are a number of extensive recomputations)
  * Initialize certain variables needed for adjoint

checkpoint57w_post (2005/11/03)
o pkg/mdsio: use MAX_LEN_FNAM (instead of hard coded 80) for file-names
             fix the singleCpuIO RS version of MDSWRITEFIELD
   and add a WARNING if using globalFiles=T with multi-processors.
o write grid-file(s) in only one format (MDS or MNC): default=MNC (if
  using MNC); can force MDS output by setting writegrid_mnc=F in data.mnc
o tracer advection scheme:
  add DST-2 (=Lax-Wendroff) & 1rst order upwind schemes (the way to get
   those 2 schemes before, changing GAD_FLUX_LIMITER.h + to recompile,
   was not very convenient).
  add implicit version for DST-3 & DST3_Flux_Limit vertical advection;
   (further tests needed for the implicit DST & Flux-Limiter schemes).
o PTRACERS: added namelist parameter PTRACERS_ref in analogy to tRef
  and sRef for convenience, handy, when you want to initialize
  ptracers in a large domain with a constant non-zero value. Also,
  untangle ptracers_init.F a little.

checkpoint57v_post (2005/10/13)
o change dome exp. to use variable viscosity in side-drag terms.
o remove all the files from the cfc_offline test since they are now
  incorporated into tutorial_cfc_offline which has been producing
  identical results for a few days of testing
o add new parameter: sideDragFactor to enable half-slip-side BC
  and change side-drag S/R to use viscosity from mom_calc_visc
  (can switch back by setting sideDragFactor=0.); affects results at
  truncation level; regenerate output for exp.: global_ocean.cs32x10(x3),
   global_ocean_ebm, global_ocean_pressure, matrix_example & MLAdjust(x5).
o vorticity & strain are now computed without masking, to account for
  no-slip-side BC in variable viscosity calculation ; mask is applied
  anyway later on, before computing advection/coriolis terms.
o modify exp4 to test new obcs support for reading from external files
  and for passive tracers
o fix behavior of ptracers_monitor when monitor output is written to a
  netcdf-file; still not independent of monitor.F (writes in the same
  file).
o change default value of tRef (put a uniform, meaningful value for ocean
  & atmos) and initialize sRef (was missing, as Martin mentioned).
o Redefine viscC?Leith*.  Change the coefficients of Leith viscosity
  to be proportional to enstrophy dissipation length.  Thus,
   viscC?leith?_new=pi*(viscC?leith?_old)^(1/3)
  This is now consistent with Smagorinsky and with the manual.

checkpoint57u_post
o OBCS and PTRACERS: add open boundary support for passive tracers
  - either use homogenous (pseudo) v.Neumann conditions or prescribe
    OB-values from file; this is not different from the way theta and salinity
    are treated
  - however, Orlanski-radiation conditions are not supported, and the model
    will stop if you use pTracers and Orlanski at the same time.
  - beefed up the rountine obcs_external_fields_load: now only those open
    boundary values are overwritten with values from files for which there
    are really files, otherwise the OB-fields remain untouched. This makes
    it possible to use different OBs at different ends of the domain (as
    with EXF)
o reduce number of exch calls in shap_filt (s2).
o CS-grid: fix divergence contribution to Leith viscosity. Affects (@
  truncation level) 4/5 MLAdjust test results (11&12 digits match).

checkpoint57t_post (2005/10/03)
o test biharmonic viscosity + no-slip with exp: global_ocean.cs32x15.viscA4
o finish adding brackets (coriolis S/R, vecinv) in multi-terms sum to get
  same truncation, independent of the face number: affects affects several
  test. exp.: Update global_ocean.cs32x15 (+.thsice) & MLAdjust (all 5).
o fix bug in mom_v_sidedrag (biharmonic viscosity was counted 2 times);
  note that biharmonic viscosity + no-slip was not tested in any experiment.
o fix bug in non-linear free-surf side-drag ; generate new output for
  global_ocean.cs32x15(+.thsice) & global_ocean_pressure.
o make mnc honor the writeBinaryPrec flag for most kinds of output
o eesupp: split EEPARAMS into EESIZE/EEPARAMS and add a vector global sum
o minor change in averaging W (mom_vi_?_vertshear.F) that affects truncation
  error; update output from global_ocean.cs32x15(+.thsice) & MLAdjust (all 5).
o add brackets in multi-terms sum to get same truncation, independent of
  the face number (manage to get exactly same value of gU,gV at the cs-edge)
  affects several test. exp. Update global_ocean.cs32x15 (+.thsice).
o Clean, new version of mom_calc_visc.  Adds a new feature, viscAhRemax
  and viscA4Remax, which allow one to limit the minimum viscosity by specifying
  a maximum grid-scale Reynolds number.  Also, changes all length calculations
  in the case of grid anisotropy to geometric mean of dx**2 and dy**2.
  Suggested values of viscosity parameters found in mom_calc_visc.
  Many new viscosity diagnostics available.

checkpoint57s_post (2005/09/20)
o Add clearing-house for viscosity calculations, mom_calc_visc and
  correct numerous bugs in LeithD and Smagorinsky discretizations.
  mom_calc_visc now allows for Smagorinsky, Leith and LeithD to be
  used simultaneously, and to be used in mom_vecinv and mom_fluxform.
  Mom_vecinv can be used with standard viscous calculation (mom_vi_hdissip.F)
  and with Strain-Tension viscous term calculation (mom_hdissip.F).
  The Strain-Tension form is now called with useStrainTensonVisc=.true.
  ViscAhStrain and viscAhTension are now retired.
o diagnostics "VISCAHD" & "VISCA4D" replace "VISCAH" & "VISCA4".
o In response to JMC's bug report, genmake2 now ignores any soft-links
  that it finds in the *current* directory when searching for files.
  Soft-links found in any other source directories will still work as
  they did before.
o add HAVE_SETRLSTK define and useSETRLSTK flag (eedata) which calls
  a C routine to unlimit the stack size
o mnc-ify pkg/aim snapshot vars
o mnc-ify pkg/land as requested by Daniel
o various changes to mnc including:
  - all files use the new "BASENAME[[.ITER].{t|f}NUM].nc" format
  - output can now be grouped so that all files within a group
      change the ITER portion of their names in lock-step together
  - can now read ("global") PER-FACE (in addition to PER-TILE) files
      and works with both EXCH1 and EXCH2 (but needs more testing)
  - writing works for all verification test cases w/ g77 on Linux

checkpoint57r_post (2005/09/07)
o make MNC variable initialization happen earlier
o add diagnostics for (almost) each term of the momentum Eq.
o remove SST,SSS,UVEL_k2,VVEL_k2 diagnostics.
o move pkg timeave out of pkg-groups "oceanic" & "atmospheric" (pkg/pkg_groups)
o remove MINIMAL_TAVE_OUTPUT option ;
  add "dumpInitAndLast" to replace "nodumps" (and MINIMAL_TAVE_OUTPUT).
o move some basic S/R (used elsewhere in the code) from pkg/mdsio to eesupp/src
  allows to compile without pkg/mdsio (& test successfully hs94.1x64x5)
o add MNC output for adjoint of EXF (adexf), SEAICE (adseaice)
o add time-dependent SST, SSS control
o cost terms in ecco/ modularized (new cost_generic.F)
o cost_averages routines are modularized (new cost_averagesgeneric.F)
o new infrastructure for seaice model vs. obs misfits in seaice/
  * driver from the_main_loop.F is seaice_cost_driver.F
  * first term is AREA vs. SMR observation misfit (ALLOW_SEAICE_COST_SMR_AREA)
  * gradient check in Exp. 6a of natl_box_adjoint/
o natl_box_adjoint input_seaice for Lab. Sea now available online via wget
  (see README file)

checkpoint57q_post (2005/08/19)
o fix initialisation Pb in calc_gw (get NANs in exp5 with g77)
o fix annoying months-old bug in mnc/mdsio output for seaice pkg
  - bug was reported by Jean-Michel and Ian Fenty
o fix initialization Pb in AIM-Ocean coupled model (aim_sice2aim.F)
  update exp. cpl_aim+ocn output.
o Implement 4-level checkpointing: AUTODIFF_4_LEVEL_CHECKPOINT
  Needed for high-res. runs with large global files
  to be able to limit tapelev size
o Changed some tests for adjoint:
  * carbon/ now tests AUTODIFF_2_LEVEL_CHECKPOINT
  * natl_box_adjoint/code_bulk/ tests AUTODIFF_4_LEVEL_CHECKPOINT
  * global_ocean.90x40x15/ back to default 3-level checkpointing
o Modifications to enable scripted COMMON to MODULE conversion
  * verification/OpenAD/code/ has necessary scripts and description;
  * converts, compiles and runs successfully;

checkpoint57p_post (2005/08/01)
o reading of delXfile & delYfile moved from ini_parms.F to ini_grid.F
o move ${PKG}_MNC_INIT from ${PKG}_READ_PARAMS to ${PKG}_INIT_FIXED
  (already the case for some pkgs, including recent MNC_init, e.g. thsice)
o call CALC_GW from DYNAMICS (instead of from FORWARD_STEP)
o Dissipation & phiHyd gradient are always added to gU,gV in timestep.F
  (was already the case for dissipation with mom_vecinv,
   and also the case for grad.PhiHyd when staggered-timeStep)
  This will allow to put dissipation out-off the AB time-stepping.
 Unfortunately, affects truncation error. Update output of exp. that "fails"
  (cg2d matching number) and leave the others for later: front_relax(10),
  global_ocean_pressure(10),ideal_2D_oce(10),internal_wave(9),lab_sea(12),
  matrix_example(7!),natl_box(12),plume_on_slope(11),vermix(12x3,11x2).

checkpoint57o_post (2005/07/30)
o fix MNC/MDSIO flags in PTRACERS so that (1) it works, and
  (2) its ready to be documented during the 20050801 DocFest
o MNC-ify the gmredi package -- tested and works w/ and w/o mnc
  for ideal_2D_oce and lab_sea on linux_ia32_g77
o set to #undef CTRL_SET_OLD_MAXCVARS_30
  in global1x1_tot/code_seaice_adj to access indices 32, 33
  (worth another tag)

checkpoint57n_post (2005/07/29)
o adding precip control xx_precip 32
o adding swflux control xx_swflux 33
o Replacing 10 forcing penalty cost routines by 1 generic.
o Implementing partitioning in time-mean and variable adjustment
  for atmos. state.
o Time-mean constant error is now read in data.ecco (instead of hard-coded)
o in natl_box_adjoint:
  * updated exp 1 to 10
    (but does not have time-mean vs. variable split results yet)
o updated global1x1/*_seaice_adj/
  to incorporate latest changes
o enable useSingleCpuIO for mdsio vector routines
  (applies in particular to tapelev I/O)
o removed inefficient K-loop in all active_file*control*.F

checkpoint57m_post (2005/07/28)
o re-arrange exp. adjustment.cs-32x32x1 (adjust_nlfs.cs-32x32x1 merge into)
  and advect_cs (use EXCH-2 and standard cs-32 grid files).
o pkg/exch2: filling of face-corner halo regions is optional
  (ifdef W2_FILL_NULL_REGIONS) and is turned off by default.

checkpoint57l_post (2005/07/14)
 tag before updating tutorials (pre-release-2)
o add cos & sin of grid-direction orientation angle (curvilinear grid only,
   for output and interpolation of input fields onto model grid)
o fix radius in mom_v_metric_cylinder.F (wrong by dy/2).
   Affects results of exp. rotating_tank ; update output.txt.
o pkg/diagnostics: 2 new S/R to fill a diagnostics using a scaling factor
      and taking the square quantity and/or using a fraction-weight field.
o fix aim_diagnostics_init.F mate numbers.
o add mnc output capability to diagnostics/diagstat and update
  our cvsignore files for the ACSII output generated

checkpoint57k_post (2005/07/02)
o lab_sea now uses diagnostics package and provides a suite of
  new EXF diagnostics output.

checkpoint57j_post (2005/06/30)
o exf
  * bug fix in exf_bulkformulae for psimh (spotted by Eliyahu Biton):
    Bracket missing in eqn. for psimh (eqn. 7 of Large & Pond, 1982);
    terms -2*ATAN(x) + pi/2 were added to both stable and unstable case.
  * extended diagnostics output
    - now includes all EXF variables
    - hs, hl moved to common block
    - separate S/R for diagnostics, called after ctrl vector is added
    - name changed for EXFsw -> EXFswnet, EXFlw -> EXFlwnet
    - EXFqnet contains true Qnet (i.e. includes qsw)
  * updated verif. lab_sea, global_with_exf
  * Rearranging hflux (exf_mapfields -> exf_getforcing)
    to ensure that diagnostics sees a true EXFqnet
o add matlab scripts for CS-grid vectors (in utils/cs_grid)
o diagnostics pkg: change pointers so that 1 diagnostic can be used
  several times with different frequencies.
o mnc-ify the thsice package as requested by Daniel Enderton
  - the monitor--MNC output needs work
  - many attributes need to be added (most are currently blank)
o mnc-ify theaim_v23 package as requested by Daniel Enderton
  - many attributes need to be added (most are currently blank)
o remove "groundAtK1" & "rkFac" (replaced by usingPCoords & -rkSign)
o add Sadourny like discretization to the 4th.O vorticity advection scheme
o fix bug in rStar code (calc_r_star.F) when used with topo/bathy.
  update output.txt from: aim.5l_cs (& .thSI), cpl_aim+ocn,
     fizhi-gridalt-hs and global_ocean.cs32x15 (& .thsice).
o fix few little things to avoid floating error with -ftrapuv (ifort v9)
 (ini_spherical_polar_grid.F, calc_r_star.F, monitor/mon_surfcor.F)

checkpoint57i_post (2005/06/19)
o Diagnostics package was changed: diagnostic allocation is now deactivated
  by setting an empty file name in the namelist (used to be by setting 0 frequency)
o momentum advection (VI form) options: activate 4th.O vorticity Coriolis ;
  add 1rst Order upwind vertical Shear.
o add a quick fix for A/B checkpointing in OFFLINE mode
o add IGNORE_TIME define and -ignore_time option to genmake2 as an
  end-run around the C/Fortran linking horror in eesup/src/timers.F
o added pkg/runclock: allows user to terminate run based on wall clock
o added non-hydrostatic scaling parameter: nh_am2
o pkg/my82: futile attempt to make results compiler-independent by adding
  some "_d 0", etc. no effect.
o for mnc output, fill the 'T' coordinate var with myTime and create a
  separate 'iter' variable for iteration count
o pkg/diagnostics:
  add new capability: output of Global/Regional & per-level statistics ;
  tested against monitor output (including land & thSIce) on various exp.
o make seaice-pkg I/O type flags (MNC/MDS) more standard.

checkpoint57h_done (2005/05/19)
  tag after changing user customized files (DIAGNOSTICS_SIZE.h,
  data.diagnostics, data.gchem, data.ptracers) is done.

o pkg/diagnostics: prepare for Global/Regional statistics.
  add 2nd namelist in data.diagnostics and update DIAGNOSTICS_SIZE.h
o remove "baseTime" (no used) from arg. list of DIFF_BASE_MULTIPLE
  and rename it: DIFFERENT_MULTIPLE

checkpoint57h_post (2005/05/14)
o move tIter0 from data.gchem to PTRACERS_Iter0 in data.ptracers
o pkg/diagnostics: change output frequency, now in seconds (instead
  of Nb of iterations). This requires to change data.diagnostics.
checkpoint57h_pre (2005/05/12)

o in mnc, let the user create the output dir if both mnc_outdir_date
  and mnc_outdir_num are false
o add fflags() to pkg/diagnostics which allows one to specify, on a
  per-file basis, the file precision [default behavior is unchanged]
o added diagnostics to pkg/kpp, including computation of mixed layer
  depth based on a temperature/density criterion
o updated verification/natl_box to test the new pkg/kpp diagnostics
o bugs fixed (with useAbsVorticity=T & with useJamartMomAdv=T)
o test AB-3 code with 4th.Order advection scheme (advect_xy/input.ab3_c4)
o fix mnc flags in pkg/seaice so that they are "owned" by seaice,
  not mnc -- this mistake was found by JMC and is now corrected

checkpoint57g_post (2005/04/15)
o add Adams-Bashforth 3rd Order time stepping:
  - default remains AB-2 (#undef ALLOW_ADAMSBASHFORTH_3)
  - not yet implemented with NH, CD_Scheme, pTracers, MNC_pickup ...
checkpoint57g_pre (2005/04/15)

o make lambda[Theta,Salt]ClimRelax spatially varying
  (default remains spatially uniform constant based on tau)
o added new control variables
  * init. uVel, vVel, etanN
  * lambda[Theta,Salt]ClimRelax
o separate masks used for ctrl_pack/unpack 'from write_grid' output
  (suggested by G. Forget)

checkpoint57f_post (2005/04/06)
o add parameter "baseTime" = model base time = time at iteration zero
  new function DIFF_BASE_MULTIPLE (replace DIFFERENT_MULTIPLE) to
  account for baseTime shift
o move Coriolis arrays from PARAMS.h to GRID.h
checkpoint57f_pre (2005/04/06)

o mnc-ifying the seaice package
o introduced an alternative length scale calculation for use in the limiting
  maximum viscosity (off by default, see mom_vi_hdissip.F for details)
o S/R ptracers_calc_diff: argument list bug for CALL KPP_CALC_DIFF_S
o added modified Leith scheme with viscosity proportional to grad(Hdiv)
  as well as grad(vort3).  Made it compatible with both approximate form
  for the cubed sphere and full form of these gradients.  Added flag
  useFullLeith to select between approximate and full form.
o add "d0" in getcon.F to reduce differences between compilers/platforms
  update output.txt of exp. fizhi-gridalt-hs
o change port_rand funtion to allow to set the seed.
o fix obscure MNC bug involving conversion between reals and integers
  - it caused no problems with certain (eg. gcc, ifc) compilers but the
    new version is now more standards-compliant
o adjoint-related modifications
  * gad_dst3_adv_?: to be able to use advscheme=30 in adjoint
  * gad_calc_rhs: fool adjoint, revert to advscheme=30 in reverse when using 33
  * mom_vi_hdissip: to be able to use Leith scheme in adjoint

checkpoint57e_post (2005/02/28)
o Adding eddy stress controls a la Ferreira et al.
checkpoint57e_pre (actually was tagged: eckpoint57e_pre)

o fizhi pkg: fix AtoC and CtoA when called with same input & output array
  update output.txt of exp. fizhi-gridalt-hs
o add more "Z" dimensions and associated coordinate vars to MNC
o pkg/exf: added twoDigitYear capability for option useExfYearlyFields
o parameter calendarDumps: when set, approximate months (30-31 days) and years
  (360-372 days) for parameters chkPtFreq, pChkPtFreq, taveFreq, SEAICE_taveFreq,
  KPP_taveFreq, and freq in pkg/diagnostics are converted to exact calendar
  months and years.  Requires pkg/cal.
o diagnostics: add pickup functionality
  - off by default for backwards compatibility
  - current version only uses MDSIO -- MNC will be added
o allow to use pkg diagnostics for LAND pkg output & Shapiro Tendencies.
o pkg/shap_filt: fix for multi-tiles per face (CS-grid with EXCH2)

checkpoint57d_post (2005/02/11)
o pkg/thsice used in the ocean: fix tile Pb related to sIceLoad forcing
o modify verification/ideal_2D_oce so that it tests the creation of mnc
  output from the diagnostics package
o temporary fix in EXCH2_UV: add a 3rd call to fix the 24.tiles CS-grid set-up
o make genmake2 more portable by using ".$FS" instead of ".f" for more
  of the test compilations (eg. IBM xlf on Mac OSX w/HFS filesys)
o add coordinate variables to the MNC output from the diagnostics package
o change MNC-flags default value: true when useMNC=TRUE
o add a "readgrid_mnc" flag to MNC and give model/src/ini_curvilinear_grid.F
  the ability (off by default) to read the grid information using MNC
o lab_sea: use LSR_ERROR=1.E-12 for testing ; update output.txt
o diagnostics: fix a bug (sub-set of levels); keep full precision when averaging
o do snap-shot diagnostics at the middle of the time-interval (instead of
  at the end).
o update exp. aim.5l_cs (use default LAND_OPTIONS.h file) and add
  new test for AIM with thSIce + slab-ocean
o cpl_aim+ocn test: update output (optfile & default GMREDI_OPTIONS.h)
o move state variable diagnostics to the beginning of the time step ;
  (note: still needs some work specially for snap-shot diagnostics)
  duplicate & replace UVELVVEL diagnostics with UV_VEL_C & UV_VEL_Z

checkpoint57c_post (2005/01/27)
o Change testing option (-ieee) to get closer agreement between g77 & ifort
o generate new output.txt files on faulks with g77 & the new -ieee option
checkpoint57c_pre (2005/01/27)

o add "_d 0" in freeze ; change some "FLOAT" to "DFLOAT" and went back (TAF);
  update output.txt of exp. global_ocean.90x40x15
o fix in ini_eos.F (one "_d 0" was missing): now g77 & ifc give much closer
  results; update global_ocean_pressure & global_ocean.cs32x15 output.txt
o add saltFlux(+File) forcing capability with periodicExternalForcing
o allow to use pkg diagnostics for GM-Redi & ThSIce output
o diagnostics_fill: fill in up to sNx+1 or sNy+1 (if U,V or Z pt) for mnc.
o improvements for the MNC output from DIAGNOSTICS:
  - correct handling of the unlimitied dimension
  - all dims now have associated coordinate variables
  - variables located at U, V, and Corner ("Z") points are now written
    with the correct horzontal dimensions (eg. 'Xp1', 'Yp1') so that
    *all* data points are output
o added seaice_summary.F and removed obsolete ALLOW_SEAICE's from pkg/seaice
o added pkg/seaice/seaice_monitor.F
o mdsio_readfield.F can now read files visible only to master MPI process.
o pkg/seaice: some test code for ice-modified ocean stress
o exf_getffields interpolation defaults to bilinear for all scalar forcing
  fields (remains bicubic for wind velocity and stress).  This avoids, e.g.,
  spurious negative numbers for precipitation and humidity.  Will cause
  some small numerical differences for integrations using pkg/exf/exf_interp.F.
o pkg/ctrl/
  * Add ctrlvec diagnostics in pack/unpack for nondimensional I/O
    May be enabled via doPackDiag
  *  introduce z-scaling of
     + gradient (doZscalePack) and
     + control (doZscaleUnpack)
o pkg/mdsio/
  * enable useSingleCpuIO for state estimation (ctrl_pack/unpack) mdsio_gl.F
  * N.B.: leave tiled I/O for tapelev (i.e. mds...vector)

checkpoint57b_post (2004/12/20)
o simplify options in diagnostics_fill arguments (remove weird combinations)
o fix MNC coordinate variables so that they now contain per-face index
  values (instead of xC,xG,yC,yG values) when run with EXCH2 since, in
  general, EXCH2 grids are only aligned to a "local" coordinate system
o test diagnostics pkg in dic_example (no output) and ideal_2D_oce (with ouput)
o Implement instantaneous output within pkg diagnostics:
  setting a negative frequency in data.diagnostics produces
 "snap-shot" output (as opposed to time-average if freq > 0)
o move out off EQUIVALENCE all diagnostics that fizhi does not use ;
  NOTE: change ptracer diagnostics name: use 2 characters to work with
        more than 9 tracers. Add also diagnostics of advect & diffus flux.
o more CF compliance: convert all MNC 'iter' variables to 'T' so that it
  becomes the coordinate variable for the 'T' dimension
o add CF-style coordinate variables to MNC
  - just a first cut:  numbers are meaningless on the cubesphere and
    missing along the T axis but otherwise it works!
o add surface flux diagnostics: TAUX, TAUY, TFLUX, TRELAX, TICE, SFLUX, SRELAX
o pkg/thSIce: read initial state from 6 files ; allow monitor to use MNC.
o add diagnostics of advective & diffusive flux for T & S (pTracers coming soon)
  this is based directly on what the model compute, so that the content of
  each diagnostics might be affected by switching options (e.g., implicitDiffusion)
o small changes for diagnostics (gad_biharm_?.F, arguments of S/R impldiff.F)
o clean up build options files for SunOS, in particular
  - remove -traditional from xmakedepend
  - change -xarch=v9 to -xarch=native for f77
  - restore use of make (not gmake)
  - add CC=gcc if using g77
o changes per discussion of AM, JMC, & EH3 today:
  - move redundant "grid" variables out of "state" -- in preparation of
    creating proper CF-style coordinate variables and in recognition
    that any/all grid variables can be easily copied (eg. w/NCO) from
    the grid files into any of the other NetCDF files
  - *always* output grid variables with MDSIO (this will eventually be
    changed)
  - output MNC grid file if useMNC is true
o every instance of _END_MASTER() has been found and replaced with
  _END_MASTER( myThid ) in order to satisfy certain picky Sun
  preprocessors
o re-arrange diagnostics pkg initialisation:
 - allow each package to extend the available diagnostics list
 - add some checking and fix small problems (multi-threaded, ...)
 - new S/R diagnostics_fill (replace fill_diagnostics):
   look through the short list of active diag. (instead of the long list)
   create function DIAGNOSTICS_IS_ON to tell if a diagnostics is active

checkpoint57a_post (2004/12/10)
o this set of changes restores TAMC compatibility
  tested for global_ocean.90x40x15 adjoint on trough
  (what a pain)

checkpoint57a_pre (2004/12/10)
o some modifs in tools/build_options for sunos
o call ctrl_pack for ctrl at end for optimcycle=0

checkpoint57 (2004/12/09)
o add horizontal bi-harmonic viscosity for vertical velocity
  - new parameter viscA4W (defaults to viscA4)
  - affects only non-hydrostatic code
  - to be done: no-slip lateral boundary conditions
o switch back to "sflux = sflux - runoff" in exf_getforcing.F
o implement Implicit Vertical advection for pTracers
o depth convergence accelerator: replace deltaTtracer by dTtracerLev(k)
  (implemented also for implicit vertical diffusion & advection)
o OBCS: extend application of tracer open boundary conditions
  to a strip beyond the boundary of width Olx/Oly
o add call monitor to TAF set of required calls (flow directives)
  and include in natl_box_adjoint
o untangle a few ifdefs related to cost, ctrl, autodiff
  untangel a few ALLOW_ECCO_OPTIMIZATION
o Apply Cooper & Haines representative estimates also at sub-surface (k=Nr)
  (theta2, salt2 in ecco_cost_weights)

checkpoint56c_post (2004/12/03)
o OBCS as control variables
  - update ctrl_ad_diff.list, obcs_ad_diff.list
  - remove balance of obcs controls from default
  - fix index bug nobcs in ctrl_init
  - fix dummy fields filen in ctrl_pack
  - add dummy weights for obcs
o lsopt: comment out fort.94 output
o optim:
  - remove unnecessary header files
  - adjusted namelists
  - add xerbla.F to Makefile
o exf:
  - multiple modifications of exf_check_range
  - unit change in exf_init_runoff from [m/year] to [m/s]
o mdsio:
  - i/o-vector change debugLevel from debLevA to debLevB

checkpoint56b_post (2004/12/01)
o collect all ptracers output in an new routine (PTRACERS_OUTPUT) that
  is called from DO_THE_MODEL_IO
  - rename PTRACERS_STATV_WRITE to PTRACERS_WRITE_TIMEAVE
  - introduce new parameter PTRACERS_dumpFreq (defaults to dumpFreq)
  - clean up PTRACERS_WRITE_TIMEAVE a little
o add another verification experiment that tests both the cfc-pkg and
  the gchem-pkg with GCHEM_SEPARATE_FORCING undefined, that is with
  reactive tendencies treated inline with regular timestepping
o testreport previously did a lousy job of comparing small numbers, so
  we (Ed and Martin) changed the  way the cut-off of 1.e-12 is
  implemented in the little c-progam tmp_cmpnum.c which is embedded in
  testreport.
o ptracers_monitor: bug fix for MPI

checkpoint56a_post (2004/11/28)
o GCHEM: finish reorganizating the package
  - forward_step calls GCHEM_CALC_TENDENDY, which computes gchemTendency
    (introduces another 3D-array for each passive tracer, but only if
    GCHEM_SEPARATE_FORCING is undefined. For GCHEM_SEPARATE_FORCING
    gchemTendency is not needed because the timestep is done separately)
  - gchemTendency is added to gPtr in GCHEM_ADD_TENDENCY
  - GCHEM is now---more or less cleanly---separate from PTRACERS
  - to bo done: handling of surfaceForcingPtr that is needed for KPP not
    so clear to me how that should be done in a general way.
o CFC: improve formatting of output in CFC_ATMOS
o PTRACERS:
  - rename GCHEM_MONITOR to PTRACERS_MONITOR and call it from MONITOR, so
    that ALL experiments with ptracers enable can be checked. This makes
    GCHEM_MONITOR obsolete.
  - include a runtime parameter PTRACERS_monitorFreq that defaults to
    monitorFreq
  - set default PTRACERS_write_mdsio to false if PTRACERS_write_mnc is true
o add PTRACERS (PTR0[1-5]) to testreport output
o exf_check_range:
  * default changed to .TRUE.
  * will check values for niter0 if debLevA, every timestep if debLevB
  * STOP in exf_check_range if 'out of range'
  * range chosen generous to allow for potential extema
  TBD: a version with stricter range
       permitted range would be runtime parameters
o GMredi:
  - fix ldd97 slope limit ; extend valid domain of Psi-Bolus ;
  - change S/R GRAD_SIGMA to be valid in the overlap on CS-grid.
  - change the default GMREDI_OPTIONS.h: compile everything except Visbeck
o GCHEM:
  - move call to GCHEM_FORCING_SEP, so that it is now called before
    the blocking exchanges to avoid computing halos in GCHEM_FORCING_SEP
  - introduced a useGCHEM runtime flag and applied it everywhere.
  - renamed PTRACERS_SEPARATE_FORCING to GCHEM_SEPARATE_FORCING;
    this flag is now only visible within GCHEM-pkg routines.
  - moved gchem_forcing_int temporarily into ptracers_forcing, this will
    be replaced by a 3D array that is computed before thermodynamics; for
    this, the tracer ID iTracer had to be included into the parameter list
    of ptracers_forcing
  - set up forward_step to call gchem_forcing, that will replace
    gchem_forcing_int in ptracers_forcing
  - cleaning up
o small cleaning of exch2: remove files that are also in eesupp/src

checkpoint56 (2004/11/17)
o AIM: read land-Fraction earlier (from ini-fixed) and monitor land at nIter0
o mnc: cleanup "full" files--fixes out-of-memory problem
o ECCO-GODAE
  * model/, pkg/, code/, input/ now complete w.r.t. ECCO-GODAE production setup
  * fully merged and updated from SIO code
    windstress sign change affects
    - exf_inscal_[u/v]stress
    - sign of xx_tau[u/v] adjustments
    - signs in cost_scat
  * ctrl_get_gen: avoid update of tau[u/v] for first few days
  * natl_box_adjoint updated and compressed
  * 2-level checkpoint switch added
    (tested in EXP. 1 of natl_box_adjoint)
  * new switch doInitXX to avoid init. of xx_... in optimcycle=0
o SVD
  * first complete, non-hacked version for SVD calculations
  * all interfaces clean w.r.t to handling of xx_..., adxx_..., g_xx_...
    performed via direct access files admtlm_vector.it????
    (via ctrl_[un]pack)
  * optimcycle is used for ARPACK iteration counter
    (note: adxx_... is iterated, rather than xx_...; latter is constant!)
  * EV problem ok w.r.t. L2-norm in tangent space; need to check other norms
    and add linear transforms where necessary
  * controls are initial/final SST, SSS (can be extended; need to check
    ctrl_set_[un]pack_xyz.F according to ctrl_set_[un]pack_xy.F
o mdsio: filename info to both stderr, stdout
o exf: exf_inscal_runoff: separated default conversion [m/year] -> [m/sec]
  from sign change

checkpoint55j_post (2004/11/10)
o isolate dissipation tendency (allow to keep it out off AB) in V.I form.
  affects (truncation level) output.txt of global_ocean.cs32x15(&.thsice)
o add consistent build directories and .cvsignore files to verification
o added viscA4GridMin and viscA4GridMax for more control on biharmonic viscosity
o make all subroutines 30 or less characters in length for certain older
  compilers to work (a thorough search only turns up two routines in
  pkg/ptracers)
o allow (vecinv only) a different horiz. viscosity for Divergence and Vorticity;
  affects (truncation level) output.txt of global_ocean.cs32x15(&.thsice)

checkpoint55i_post (2004/10/28)
o change arrays for total vertical diffusivity (2.D if explicit,
  3.D if implicit) ; each ptracer uses its own background value.
o added mnc/NetCDF output capability to ocn_compon_interf
  - added bits to verification/cpl_aim+ocn so that it can run on
    ITRDA and other clusters without the mpirun "-wd" option
o fixed wayward endif in mom_fluxform.F that messed up cyclindrical
  configuration
o give MNC the ability to create additional files rather than
  exceeding a specified file size limit "MNC_MAX_FILESIZE"
  - the default is just less than 2GB which is a practical limit
    on many systems
o Compute the non-local term using either KPP vertical diffusivity (=default)
   or the total vertical diffusivity (when KPP_ghatUseTotalDiffus=T)

checkpoint55h_post (2004/10/20)
o add verification test "vermix"
o remove all the *_ioinc flags and replace with the single global
  outputTypesInclusive flag
o allow to set a vertical profile of vertical diffusivity for T & S
o call PACKAGE_BOOT & PACKAGES_READPARMS just after INI_PARMS
o useMNC moved from data.mnc to data.pkg

checkpoint55g_post (2004/10/14)
o Renaming carbon AD experiments to comply with testreport conventions
o Updating adjoint of Held-Suarez hs94.1x64x5
o Fixing directives for non-ECCO forward_step, after ECCO directives
  have been fixed to avoid recomp. of do_oceanic_phys
  Works well for global_ocean.90x40x15,
  but recomp. issue remains for carbon
o Updating adjoint output for natl_box_adjoint after
  pkg/ecco has been modified (see taga c55d_post)

checkpoint55f_post (2004/10/13)
o rename to timeave_init_fixed

checkpoint55e_post (2004/10/13)
o some delicate re-shuffle of store directives to avoid one
  extra call of do_oceanic_physics
  affects ecco_the_main_loop.F, do_oceanic_physics.F
  checkpoint_lev1_directives.h
o NB: this may break global_ocean adjoint temporarily,
  but it is clear how to fix it. Will do later, need this now.

checkpoint55d_post (2004/10/11)
o ECCO specific cost function terms (up-to-date with 1x1 runs)
o ecco_cost_weights is modified to 1x1 runs
o modifs to allow observations to be read in as
  single file or yearly files
o enable to read exf forcing fields as either
  single file or yearly files (flag useExfYearlyFields)
checkpoint55d_pre (2004/10/08)

o switch between 2-level and 3-level checkpointing
o add ability of MNC to write local and "partial" (eg. 2D slices where
  the full 3D field is never actually stored) arrays to NetCDF files
  with the correct (that is, the complete multi-dimensional) set of
  array indicies
  - used in mom_vecinv() to write the diagFreq output
  - tested (demonstrated) in verification/aim.5l_cs
o further mnc-ification
  - add verification/lab_sea to the list with mnc setups
  - fix undefined mnc v-names in cd_code
  - add kpp to mnc output (both snapshot and timeave)
o non-hydrostatic code
  - added horizontal viscosity parameter viscAhW for w, that replaces viscAh
    in calc_gw.F
  - defaults to viscAh
  - this is useful, when I want to use viscAh=0 (e.g., only biharmonic
    friction or Leith) in non-hydrostatic mode, as long as there is
    no biharmonic friction and/or Leigth or equivalent for vertical velocity.
o pkg/cost
  extend simple cost functions to treat time mean quantities
  (T,U,V) via cost_accumulate_state from cost_tile
o multidimAdvection on CS-grid: implement the full 3 pass ; overlap needs to
    be 2 times larger than the minimum size the advection scheme requires.
    now get a perfect conservation of salt in advect_cs test-exp (updated)
o GGL90 (Gaspar's TKE mixed layer)
  - add horizontal diffusion of TKE, requires exchanges in
    do_fields_blocking_exchanges, horizontal diffusivity is zero by
    default. In OPA there is no horizontal diffusion of TKE but the
    mixing coefficients are computed from a horizontal average of TKE of
    6 points or so. I think that diffusion has a little more physical
    justification.
  - clean up ggl90_calc in the hope of reducing memory usage (this hope
    was in vain)
  - mask tke-variable in ggl90_init
o fix mask Pb in multidimAdvection on CS-grid (still a small Pb with ipass)
o fix biharmonic diffusion on CS-grid.
o more obcs stuff
  - added obcs_external_fields_load as an alternative to the EXF-pkg option
    for reading boundary values. This routine is called from
    obcs_prescribe_read
  - updated obcs_check
  - changed sponge layer relaxation parameter units for days to seconds
  - turned off sponge layer by default
  - changed argument list of OBCS_CALC to myTime+deltaTclock
  - fixed about 35 bugs in obcs_external_fields_load

checkpoint55c_post (2004/09/23)
o obcs stuff
  - new runtime flags useOBCSprescribe, useOBCSbalance
  - re-arranged obcs_calc
  - moved exf_getobcs to obcs_prescibe_read
    obcs_prescibe_read is called after ORLANSKI stuff
    and independent of it (executable can contain all).
  - updated obcs_check
  - added exchanges for U,V,gU,gV for useOBCSprescribe=.TRUE.
    These may be necessary only if tangential velocities are
    prescribed at OB, not sure, needs testing.
o make the MNC_CW_ADD_VATTR_* subroutines all take scalar arguments
  which simplifies the calls and passes the ifc check-bounds test

checkpoint55b_post (2004/09/22)
o add a 2D scalar, Z location, exchange_2 routine.
o EXCH_UV for CS-grid: add one u,v in the corner-halo region, allows
  to compute vorticity on a wider stencil [e.g., vort3(0,1)&(1,0)]
  affects advect_cs results (for the wrong reason): update output.txt
o use a more standard discretization for biharmonic viscosity ;
 (original version still available with #define MOM_VI_ORIGINAL_VISCA4 )
  affects results of dome set-up: update output.txt
o fix gad_advection.F (CubedSphere part), back to version 1.23
o fix bug in mom_vi_del2uv.F (CubedSphere part).

checkpoint55a_post (2004/09/20)
o merged code to
  * prescribe/read time-dependent open boundaries
    (works in conjunction with exf, cal)
  * sponge layer code for open boundaries
  * each boundary N/S/E/W now has its own CPP option
    (healthy for the adjoint)

checkpoint55 (2004/09/17)
o up-to-date adjoint of previous breaks
  - natl_box_adjoint: problem for exp 12, 13: cost = 0. needs fix
  - global_ocean_ebm: adjoint still needs fix (TLM ok)
  - global_ocean.90x40x15: extended GMREDI_OPTIONS.h
  - carbon: * remove tr1-related adjoint verification
            * add ptracer as control variable
o remove all tr1-related code (ALLOW_PASSIVE_TRACER)
  (adjoint stuff still has some tr1 'names', but all use ptracer arrays)

checkpoint54f_post (2004/09/16)
o in verification/carbin/ remove experiment related to
  ALLOW_PASSIVE_TRACER (array tr1 etc)
  code_ad/ input_ad/ results_ad

o add two new packages
  - ggl90, TKE-model of Gaspar et al. (1990), Blanke+Delecluse (1993)
    + subject to optimization (memory)
  - opps, OPPS (ocean penetrative plume scheme) of Paluszkiewicz+Romea (1997)
    + subject to reordering (many GOTOs in the original code)
    + so far opps is called for every (i,j) point, and then operates in
      the vertical; one may want to reorder the scheme in order operate in
      horizontal slabs at the cost of (a lot of) memory, at least ten new 3D
      fields)
o overhaul of IO so that we now have flags for MDSIO and/or MNC
  - all verification tests compile and run with linux_ia32_g77
  - defaults are compatible with current input files--nothing
    should change if you were not previously using MNC
  - MNC output has been added in numerous places (eg. timeave)
    but there are still a few writes not yet do-able with MNC
    (this is in progress)
  - flags now allow for either/or/both use of MDSIO and MNC and
    documentation will soon follow
  - numerous small formatting cleanups for ProTeX
o add version info (via BUILD_INFO.h) to MNC and stdout

checkpoint54e_post (2004/09/02)
o add two new packages
  - pp81 (Packanowski and Philander, 1981), Richardson number and
    stratification dependent mixing
  - my82 (Mellor and Yamada, 1982) level 2 turbulence closure scheme
  - these scheme operate in a similar manner as KPP (without ghat, of
    course), however there is only one diffusivity that is used for both
    temperature and salinity (and passive tracers)
o add offline package
o add "verification/dic_example" which contains a dic-gchem-ptracer setup
  provided by Stephanie Dutkiewicz
o genmake2: add ability to search for C compilers and cleanup test output
  - fixes recent SX-6 problems and should help with others (eg. HP-UX)

checkpoint54d_post (2004/07/27)
o data.diagnostics: if levels() is unspecified then ALL levels are diagnosed
o bug fix in pkg/cal/cal_addtime.F for TheCalendar='model' day count is wrong,
  leading to additional shift by 5 days each year of integration
   (i.e. leading to considerable offset over the years)
o update global_ocean.cs32x15/thsice: use z* + RealFW + staggerTimeStep
o start with no AB and no initial filtering (staggerTimeStep):
  change the results of test-exp: hs94.128x64x5, hs94.1x64x5 & hs94.cs-32x32x5
o move ocean specific S/R calls from forward_step.F to do_oceanic_phys.F
  (external loading & cpl import/export stay in forward_step.F)
o update coupling interface to work with new staggerTimeStep
o change MDSIO ptracers_pickup.
o fix a bug in Flux deriv. vs Ts (pkg/aim_v23/phy_suflux_sice.F);
o genmake2 fixes so netcdf now works on halem ("osf1_alpha_*")
o bugs fixed in kpp_calc.F (ustarY) and external_forcing.F (Qsw & Partial-cell)

checkpoint54c_post (2004/07/18)
o replace surfaceTendency U,V,S,T,Tice,Ptr by surfaceForcing U,V,S,T,Tice,Ptr
  this affects (truncation error) output.txt of test-exp:
   global_ocean_ebm,_pressure,.cs32x15(&.thsice), lab_sea & natl_box
o pkg/kpp: replace pMask by maskC to reduce memory size (one 3.D array)
o change Qnet to always be the net heat flux, (+upward).
  affects (truncation error) output of natl_box exp.: updated
o define the max number of passive tracers in PTRACERS_SIZE.h
o start to test mnc routinely in exp0
o add sea-ice loading (sIceLoad) as a new forcing field.

checkpoint54b_post (2004/07/08)
o add testreport "-j JOBS" option for parallel builds (tested and pretty
   impressive on Altix and Opteron systems)
o diagnostics can now write NetCDF files through the mnc package
o staggerTimeStep & NLFS: update pkg aim_v23 & thsice; update aim.5l_cs output
o staggerTimeStep & multi-Dim-Advec: Exch(U,V) added
o staggerTimeStep & NLFS: rescale T & S surface tendencies.
  affects (truncation error) output of lab_sea & natl_box exp.: updated
o change pickup _cd & _ptracers (old pickup restart: usePickupBeforeC54=.T.)

checkpoint54a_post (2004/07/06)
o re-write staggerTimeStep: step fwd U,V and then T,S (reverse the order).
o change pickup file (to restart from old pickup, set usePickupBeforeC54=.T.)
o get a perfect restart when using RealFreshWaterFlux + NLFS (not finished)
o update output of all exp. that use staggerTimeStep (except hs94.cs & 2D)
  + internal_wave (shift in writing cg2d_ini_res)
checkpoint54a_pre (2004/07/05)

o require forcing_In_AB=.FALSE. and remove surfaceTendencyTice from pkg/seaice
  - modified verification/lab_sea and natl_box_adjoint accordingly

checkpoint54 (2004/07/02)
checkpoint53g_post (2004/07/02)
o prepare splitting of thermodynamics: store convect.counter in common block
o store d.etaH/dt (instead of Div.hV) in common ; affects (truncation error)
  output of: global_ocean.cs32x15, global_ocean_pressure & internal_wave
o cnh's modifs to gad_advection.F for cube-sphere multi-dim advection
o new parameter "nShapS": allow to treat differently S from T (nShapT)
o separate Vert.Advec.Scheme from horizontal Advec.Scheme (T & S)
o restore adjointability

checkpoint53f_post (2004/06/25)
o modifications that affect AIM experiment results (update output.txt):
  - no advection of S at top interface Nr (pkg/generic_advdiff)
  - air surf. temp: use lower value between T0 & T1 (phy_suflux_prep.F)
o AIM pkg:
  - include stability function into surf.Flux derivative relative to Tsurf
  - calculate clear-sky radiation & surface temp. change (for diagnostics)

checkpoint53e_post
o merged cylindrical coord configuration
o added rotating_tank experiment
checkpoint53e_pre

checkpoint53d_post (2004/06/14)
o faulks upgraded: re-generate output.txt that have changed:
   global_ocean.cs32x15(.thsice), global_ocean_ebm, lab_sea, natl_box
o Added Bryan and Lewis, 1979, vertical diffusivity profile
o pkg/land: fix problem in land_impl_temp.F when Ts arround freezing.
o added Sadourny discretization of Coriolis
  - moved some PARAMETERS from mom_*_coriolis.F to PARAMS.h
  - re-enabled use of omega3 (useAbsVorticity)
o added Leith (Phys. Fluids, 1968, 10, 1409-1416) variable viscosity for
  vector-invariant equations
  - note: does *NOT* yet use same variable visc. for no-slip BC's.
o recoded the lateral boundary conditions for non-hydrostatic w, this time
  hopefully without new bugs
  - still to do: biharmonic friction for non-hydrostatic w
o bug fix for mom_*_sidedrag: rA -> rAs,rAw
o regenerated output for global_ocean_ebm (using -ieee)
o fix mom_common/mom_*_sidedrag.F to recover numeric output prior to creation
  of mom_common/
  - simple re-arrangement of instructions within computing loop
checkpoint53d_pre (2004/05/21)

checkpoint53c_post (2004/05/21)
o new version of coupler for AIM+thSIce and Ocean models
 - new fields (SSS,h_MixLayer ...) are exchanged through the coupler
 - land: change Evaporation of snow
 - aim with thSIce: fix bug in snow-precip.
o changes to calc_gw.F
 - bug fix for w^2 term near the bottom boundary
 - (hopefully) improve the lateral slip boundary condtions for use with
    partial/looped cells
  - because the bug fix changes two verification experiments anyway (exp5
    and plume on slope), change the lateral boundary condition from half slip
    to the value of no_slip_sides
o ebm package wasnt quite up to the parallel task. Fixed that.
o Adjoint of EBM package + verification
  * TLM OK
  * ADM not sufficient accuracy yet (needs further testing)

checkpoint53b_post (2004/05/14)
o Commiting new energy balance model to repository
  * package is pkg/ebm
  * verif. is verification/global_ocean_ebm
  * references are in ebm_driver.F
C      * X. Wang, P. Stone and J. Marotzke, 1999:
C        Global thermohaline circulation. Part I:
C        Sensitivity to atmospheric moisture transport.
C        J. Climate 12(1), 71-82
C      * X. Wang, P. Stone and J. Marotzke, 1999:
C        Global thermohaline circulation. Part II:
C        Sensitivity with interactive transport.
C        J. Climate 12(1), 83-91
C      * M. Nakamura, P. Stone and J. Marotzke, 1994:
C        Destabilization of the thermohaline circulation
C        by atmospheric eddy transports.
C        J. Climate 7(12), 1870-1882
o Will need long integration testing.
checkpoint53b_pre (2004/05/14)

o created pkg/mom_common in preparation for variable viscosity code
o renamed and split ini_mnc_io
o pkg/land: only liquid water can diffuse or run-off
o AIM using land: soil wetness availability account for snow
o added printMapIncludesZeros to EEPARMS namelist

checkpoint53a_post (2004/05/11)
o restore TAMC compatiility for exf_constants.h
  (no usage of _d in .h)
o Additional storing in KPP in an attempt to fix
  TAMC problem with adjoint of KPP code.
  (no success...)
  Identical code works fine with TAF.
o Fixed verification/natl_box_adjoint experiments.
  Initial conditions for Experiments 4 and 5 are now
  set to "SEAICE_initialHEFF=0", which is more reasonable,
  and hence gives results closer to that of Experiment 2.
  Experiment 6 requires "SEAICE_initialHEFF=1" and is working once again.

checkpoint53 (2004/05/06)
o stable checkpoint with up to date adjoint
  TLM tests only run for 1st grdchk at the moment. Its unclear if
  this is a code problem or a problem with resetting code for g_
  variables that is being autogenerated wrong.
  Otherwise:
   o code is testing well on Linux (P4 and AMD), SGI Alitix and Irix.
   o IBM and HPQ tests could not be run because NCAR (IBM) and NCCS (HPQ)
     are both still in chaos following their security messes.

checkpoint52n_post (2004/05/06)
o various build (mostly genmake2) changes including:
  - ability to build/run more easily within Cygwin and MacOS X
  - more complicated Makefiles with a stronger dependence on Gnu Make
o pkg/seaice modifications
  - added SEAICE_deltaTtherm and SEAICE_deltaTdyn in order to reduce cost
    of pkg/seaice.  For time being, SEAICE_deltaTtherm = deltaTtracer
    and SEAICE_deltaTdyn must be integer multiple of SEAICE_deltaTtherm
  - changed proxy for geostrophic velocity and updated
    verification/lab_sea/results/* accordingly
  - removed ADI dynamic solver from pkg/seaice
  - replaced all occurrences of 1/CSTICE or 1/CSUICE
    they caused a segmentation fault under certain circumstances
  - removed unused field WATR
o bug fix in exf-package:
  -  u/vwind are defined at tracer/pressure points. The values of u/vwindmask
     now reflect that.
o small fixes in the cal-package:
  - set reference date to first of January for the 'model'-calendar
  - failing of cal_CheckDate in cal_FullDate now actually results in a
    warning
o small modifications in exf-package to increase flexibility:
  - change climtempfreeze from a constant to a runtime parameter that
    is specified in data.exf_clim (default = -1.9)
  - introduce runtime parameter windstressmax (default = 2.0) that is
    specified in data.exf
o fix in pkg/thsice:
  - update Evap (Tsf changes) to be consistent with Latent heat flux
  - maintain snow precipitation unchanged (even if Tsf >=0).
 both affect global_ocean.cs32x15/(.thsice) results ; update output.txt.thsice

checkpoint52m_post (2004/04/18)
o commented out call to cal_GetMonthsRec in swfrac.F and added some comments;
  this does not change any of the results, because myIter=0 in swfrac always
  lead to jwtype=2 (the default anyway), but the call makes little sense
  as a default
o no SHORTWAVE HEATING lost at the bottom; affects lab_sea output; updated
o re-work pkg/thsice interface with ocean & bulk_force pkg to allow
  atmospheric model (AIM) to use it ; add a "slab ocean" component.
o pkg/aim_v23 : add interface to call thermodynamic sea-ice (thsice)
o update global_ocean.cs32x15/output (.thsice) after changes in pkg/thsice
o extending useSingleCpuIO option to work with new exch2 I/O format
  - old-style, missing-tile I/O is still accessible by defining CPP
    option MISSING_TILE_IO in pkg/mdsio/MDSIO_OPTIONS.h
o monitor package can write to NetCDF files and/or STDOUT
o fix re-definition bug in MNC_GRID_INIT_ALL()
o doc/api_reference added
  - a framework for building an API Reference Manual using all
    the "protex" comments embedded in the code
  - see pkg/generic_advdiff, pkg/mnc for examples
o MNC:
  - make myThid the last argument for all subroutines
  - new default for the grid files: NO halos
  - add useMNC and other run-time flags
  - separate per-file-group handling of the unlimited dimension
  - early initialization of MNC w/ flags read at the eeboot stage
    and lookup tables set in initialize_fixed
  - write all MNC output to a freshly-created directory
o thermodynamics sea-ice (thsice) is now tested with testreport.
o test exp. advect_cs: use the standard cs32 grid ; update output.
o Added functionality to grdchk:
  pick global i,j,k position (or nearest wet) where to perform check.

checkpoint52l_post (2004/03/11)
o new land formulation:
  a) use ground enthalpy as prognostic variable to ensure exact
     energy conservation.
  b) account for water temperature and for latent heat of freezing
     in all processes (rain, run-off, ground storage)
  c) compute surface and ground temperature implicitly.
o aim_v23 modification for new land model:
  a) Treat separately land / ocean / sea-ice surface fluxes
     to allow implicit computation of land & sea-ice surface temp.
  b) add snow precipitation.
checkpoint52l_pre (2004/03/11)

o fix problem (when 1 tile is empty) in min/max monitor.
o fix bug in timeAve (u,vZetatave in common block)
o no restoring terms under ice for pkg/seaice
o moved SEAICE_DO_DIAGS to S/R do_the_model_io
o bug fix for pkg/seaice pickups
o change MNC call locations and add coordinate attributes
o mask vorticity at the corner ; affects global_ocean.cs output
o fix ini_curvilinear_grid ; test CS experiments with mpi
o aim.5l_cs: modify sea-ice fraction input file ; update output
o exf: Adding simple range check routine for exf fields after read

checkpoint52k_post (2004/02/23)
o removed top-level directory "diags"
  - we migrated these functions to pkg/timeave a long time ago
o fixed bug introduced in pkg/monitor
o accuracy ctrlprec = 32 insuffient for gradient checks using
  averaged fields (I/O via cost_averages)
  -> use ctrl.h in active_file*.F to control I/O precision.
o paramter list of CALL ADTHE_MAIN_LOOP
o added initial do_the_model_io to ecco
o set all ...Freq to zero after cost_final
  taveFreq, dumpFreq, pChkptFreq
o MAIN and ECCO differentiability restored

checkpoint52j_post (2004/02/18)
o fix nchklev in tamc.h for global_ocean...
o Bringing flow and store directives up-to-date
o Really weird thing!
  call do_the_model_io from the_main_loop with parameters
  starttime, niter0, instead of mytime, myiter, screws up the adjoint:
  TAF places a faulty re-call of initialise_varia
  after cost_final call which should not be there!
checkpoint52j_pre (2004/02/03)

o tweaked pkg/mdsio/mdsio_readfield.F to have more useful logic and
  error messages
o fix errorMessageUnit problem. remove old version of mdsio from eesup/src
o modified pkg/mdsio/mdsio_readfield.F -- commented out diskspace-eating
  debug output
o modfied mdsio_writefield.F to handle non-global files under exch2
o update AIM Cubed-Sphere exp (aim.5l_cs):
  use land, p*, and Franco.M forcing fields with fractional land-sea mask.
o update AIM Equatorial Channel exp:
  use standard aim_v23 pkg and change the SST fields to be more realistic.
o globalFile now works with exch2
o merged mom_vi_calc_relvort3.F, mom_vi_del2uv.F and
  mon_vort3.F to make exch2 friendly with >1 tile per cube face
o limit timeave output for hi-res integrations

checkpoint52i_post (2004/01/21)
o removed CPP_EEOPTIONS.h from verification/*/code
o updated the tiling for global_ocean_pressure
checkpoint52i_pre (2004/01/20)

o update aim.5l_LatLon using the standard aim_v23 pkg (instead of
  the old pkg/aim).

checkpoint52h_pre (2004/01/20)
o shortened offending lines in exch2_send_rx?.template
o modified W2_EXCH2_TOPOLOGY.h to reflect current topology generator
o genmake2: add build & execute test for NetCDF code
o modded aim.5l_cs and global_ocean.cs32x15 to use exch2, removed
  old grid files, moved CPP_EEMACROS.h to pkg/exch2
o added useSingleCPUIO flag to monitor.F and mon_out.F
o added temporary hack for sea-ice dynamics on the cube:
  metric terms are ignored and it is assumed that
  there is no sea-ice on cube faces 1, 2, 4, and 5.

checkpoint52f_post (2004/01/09)
o added exch2 cube routines to pkg/exch2
o modified hs94.cs-32x32x5 to use it
o added new grid files to hs94.cs-32x32x5
checkpoint52f_pre (2004/01/07)

checkpoint52e_post (2004/01/07)
o first attempt to solve vertical advection (momemtum & T,S) Implicitly
  for now, only implemented with Lax-Wendroff (tracer) and VectInv (mom)
o step.1 : rewrite (as in MultiDimAdvec) explicit tracer stepping (gad_calc_rhs.F)
  to work with implicit vertical advection and AB ;
o Implic. vert. advect. implemented with flux-limiter, c2, u3 and c4 scheme.
o update output (gad_calc_rhs.F changes affect truncation error) of exp:
 front_relax, global_ocean .cs32x15 & _pressure, internal_wave, lab_sea, natl_box
checkpoint52e_pre (2004/01/02)

o fix bug in impldiff when Nr=1 or Nr=2.
o change the albedo in pkg/thsice (as GISS model); update output_thsice.txt
o little changes (fftpack, aim/phy_suflux ...) to pass the "checkbounds" test.
o fix deltaTfreesurf in update_cg2d.F (left from c45d_post): affects 2
  ocean exp. that use NLFS: global_ocean.cs32x15 & global_ocean_pressure
o added exf_offset_atemp for Celsius to Kelvin conversion of atemp
o eesupp/inc/EEPARAMS.h: MAX_NO_PROCS=1024
o pkg/cal/cal_toseconds.F fix for long (>60 years) integrations

checkpoint52d_post (2003/12/16)
o re-tiled many expts to allow comparison in multi-processor mode
  - updated output accordingly
  - changed hs94.128x64x5 to use intial T from file rather than use the
    random number generator
o add infrastructure in model routines for fizhi and gridalt packages
o change global_ocean.cs32x15 because of Pb with GM on CS-grid.
o changes to permit hi-res, cubed-sphere, configuration
  - added useSingleCpuIO capability to mdsio_readfield.F and exf_interp.F
  - added "#undef ALLOW_USE_MPI" support to eesupp/src/scatter_2d.F
  - added pkg/exf/exf_set_uv.F for on-the-fly interpolation and rotation
    of surface winds for the cube
  (A verification experiment, based on global_ocean.cs32x15, but with
   pkg/seaice turned on and with on-the-fly interpolation from the NCEP
   Gaussian grid is described in MITgcm_contrib/high_res_cube/README_ice,
   complete with example surface forcing files and matlab scripts to look
   at the output and compare it with that of global_ocean.cs32x15.)
o packages pickup: $PKG_write_pickup called from packages_write_pickup ;
   but call to $PKG_read_pickup remains in $PKG_ini_vars: change CD_code
   to conform to the common rule.
o check-in the first version of the coupler + interfaces for multi-components
   set-up (Chris's version, adapted to work on cubed-sphere grid); use MPI.
   - imply modification in eesupp (MPI_COMM_MODEL < MPI_COMM_WORLD).
   - atmosphere: use pkg aim_v23 ; no sea-ice for now.
   - ocean and atmos. share the same horizontal grid (no interpolation).
   - exchanges between component and coupler is done in forward_step
o new verification experiment, cpl_aim+ocn:
   coupled ocean - AIM atmosphere on cs32 grid.

checkpoint52d_pre (2003/12/06)
o surface flux time-av diagnostic modified for NLFS & RealFreshWater
o add call to AIM pendant S/R in external_forcing & external_fields_load.F

checkpoint52c_post (2003/11/25)
o Fixing OPTIONS files for use of exf:
  - ALLOW_ECCO not needed
  - ECCO_CPPOPTIONS.h should not be included from
    EXF_OPTIONS.h/CAL_OPTIONS.h, but from CPP_OPTIONS.h
    as has been the case in the past
  - All cal/exf related options are currently set in
    single header file. Should remain so until we
    agree on a consistent new policy.
o Removed all CPP options for cal package.
  cal has no more CPP options.
o modified STOREs in GAD_ADVECTION
o corrected key comp. for passkey

checkpoint52b_post (2003/11/23)
o new version: "thsice" of thermodynamic sea-ice pkg:
 - only 1 call from "forward_step"; conserve energy, fresh-water & salt.
 - modify fluxes but do not change theta directly;
 - light cleaning of bulk_force pkg (still needed with thsice).
 - add forcing fields + data files in global_ocean.cs32x15/inp_thsice
   + output_thsice.txt to test thsice & bulk_force pkgs.
o put back grid & coriolis monitor output.
checkpoint52b_pre (2003/11/23)

o call "do_the_model_io" at the beginning (=> dump initial state)
o use rhoConstFresh to define convertEmP2rUnit (was done only in ocean-P)
o sort out interplay between tamc.h and PTRACERS_OPTIONS.h
  (need info on NUMBER_OF_PTRACERS)
o missing PTRACERS headers in some routines
o default tamc.h in pkg/autodiff supposed to crash
  to ensure proper customization

checkpoint52a_post (2003/11/17)
o modifications to make FREEZE (_SURFACE) flux visible to pkg/kpp
  - moved surfaceTendencyTice from pkg/seaice to main code
  - subroutine FREEZE_SURFACE now limits only surface temperature
    and is called in FORWARD_STEP (if allowFreezing=.TRUE.)
    => new output.txt for global_ocean.cs32x15 & global_with_exf
  - keep the old version of FREEZE for backward compatibility;
    global_ocean.90x40x15 left unchanged using useOldFreezing=.TRUE.
  - corresponding modifs for TAF directives
o added surface flux output variables to TIMEAVE_STATVARS
o time-averaged output for pkg/ptracers
o fix problem with ECCO-related divided adjoint
  snapshot file was missing some ad-variables,
  but no warning issued by TAF

checkpoint52a_pre (2003/11/12)
o some bug fixes for #undef REAL4_IS_SLOW

checkpoint52 = ecco_c52_e35
o after testing adjoints of checkpoint51u_post

checkpoint51u_post (2003/11/06)
o this is the post-merge tag of the ecco-branch
  (needs another clean checkout and re-testing)
o various natl_box_adjoint configs and results
  but no input fields
o obcs adjoint not yet merged!
o adding ECCO global 1x1 and 2x2 degree configs
o updated/extended some store directives for seaice
o pkg/ecco now containes ecco-specific part of cost function
o top level routines the_main_loop, forward_step
  supersede those in model/src/
  previous input data.cost now in data.ecco
  (new namelist ecco_cost_nml)
o in ctrl/ cleaned some cross-dependencies and updated CPP options

checkpoint51t_post (2003/11/04)
o this is the pre-merge tag of the ecco-branch

checkpoint51s_post (2003/11/04)
o cleanup: removed various obsolete #define-s
o pkg/grdchk
  - renamed 'ph-grd 3' to 'grad-res'
  - merged from ecco-branch
    (remaining bug fixes for obcs gradient checks)
  - additional high-precision output for testreport
    (grep for 'precision_grdchk_result')

checkpoint51r_post (2003/11/03)
o cleaned up or removed CPP_OPTIONS.h files
o updated results for some of the tests to reflect the new
  optfiles (-ieee: -O0 instead of -O3)

checkpoint51q_post (2003/10/30)
o cd_code:
  - moved cd_scheme.F -> cd_code_scheme.F
  - separate read_checkpoint from cd_code_ini_vars.F
  - separated cd_code part from write_checkpoint
  - updated AD_SOURCE, generated .flow
  - added CD_CODE_VARS.h to the_main_loop
  - Moving cd_code specific store dir.s to pkg/cd_code
o ctrl package totally restructured
  - pack/unpack now optional and decoupled from
    xx_/adxx_ I/O
  - ctrl_pack/unpack cleaned
    (new routines ctrl_init_ctrlvar.F, pkg/ctrl/ctrl_init_wet.F)
  - confined inclusion of AD_CONFIG.h to where necessary.
o genmake2: changed AD dependencies from SRCFILES to AD_FILES

checkpoint51p_post (2003/10/30)
o create initial cd_code package
  - WARNING: the initialization of fields within packages
    is broken because INI_FIELDS (where READ_CHECKPOINT is
    called) is called *before* PACKAGES_INIT_VARIABLES.
    This seems to be backwards since
    1) its important to initially zero the entire field including
       the "halo" region
    2) zeroing needs to be done *before* reading pickup info
       and the pickup call might or might not happen in any
       particular run
  - this needs an overhaul for R2
o cleanup verification/*/code/GMREDI_OPTIONS.h
o cleanup testreport

checkpoint51o_post (2003/10/27)
o bringing AD-related verif's up to date with genmake2
  - carbon/
  - global_ocean.90x40x15/
  - hs.94.1x64x5/
  - (front_relax/ )
o (more) consistent directory structure for AD-related verif.'s
o cleaning ALLOW_GRADIENT_CHECK -> ALLOW_GRDCHK
o cleaning some ALLOW_TANGENTLINEAR_RUN -> ALLOW_AUTODIFF
o bug fix in find_alpha.F for MDJWF:
  - modif. to alpha = 1/D*( dN/dT - rho*dD/Dt) to account for
    change rho -> rho-rhoConst
  - replace call find_rho to find_rhonum
o initialisation of rFlx extended to full array (required by TAF)
  and shifted to thermodynamics
o removed PTRACERS.h in ptracers routine
o added surfacetendencyPtr to S/R parameter list pracers_forcing
o Correcting initialisations for fVerU, fVerV.
o helping TAF to recognize dependency on kUp for
  fVerU, fVerV
o Replacing delZ by delR in pkg/ctrl/
checkpoint51o_pre (2003/10/24)

o undid all of cp51 pending some cleanups and discussion
o added the [#include "AD_CONFIG.h"] statement to all files that need
   it for adjoint/tl #defines
 o re-worked the build logic in genmake2 to support AD_CONFIG.h
 o removed tools/genmake since it no longer works

checkpoint51n_post (2003/10/23)
o modifications to make FREEZE flux visible to pkg/kpp
  - moved surfaceTendencyTice from pkg/seaice to main code
  - FREEZE & EXTERNAL_FORCING_SURF moved to FORWARD_STEP
  - subroutine FREEZE now limits only surface temperature
    (this means new output.txt for global_ocean.90x40x15,
     global_ocean.cs32x15, and global_with_exf)
o added surface flux output variables to TIMEAVE_STATVARS

checkpoint51n_pre (2003/10/23)
o added "#undef ALLOW_USE_MPI" support to eesupp/src/gather_2d.F
o added [#include "AD_CONFIG.h"] to all files that use the following
  defines:
  - ALLOW_ADJOINT_RUN
  - ALLOW_TANGENTLINEAR_RUN
  - ALLOW_ECCO_OPTIMIZATION

checkpoint51m_post (2003/10/21)
o incorporating changes to get TAMC/TAF working in genmake2
  - added new TAMC/TAF targets to the Makefile
  - various cleanups related to package handling
  - these changes should have no impact on the forward model

checkpoint51l_post (2003/10/20)
o changes to pkg/cal and pkg/exf that allow and speed-up long integrations
 - faster algorithm for cal_addtime.F
 - higher precision arithmetic, where needed
 - pkg/exf *startdate variables changed from calendar date to
   model integration time

checkpoint51l_pre (2003/10/17)
o add salt flux to forcing fields (used when salty sea-ice forms or melts)
o enable to apply restoring on S & T only in a latitude band.
o update output (external_forcing_surf modif. change truncation errors)
   global_ocean.cs32x15, global_ocean_pressure, lab_sea, natl_box

checkpoint51k_post (2003/10/16)
o change default to: useNHMTerms=.FALSE.
 - new output.txt for atmos. exp (NHMTerms were wrong but now turned off):
   adjustment.128x64x1, aim.5l_Eq_Ch, aim.5l_LatLon, hs94.128x64x5, hs94.1x64x5
 - new output.txt for idealized oceanic exp (NHMTerms are now turned off):
    exp1, ideal_2D_oce
 - change data file of oceanic exp (leave the results unchanged for now)
   exp2, global_ocean[90x40x15,pressure,with_exf], lab_sea, natl_box
o set gravitySign automatically according to the vertical coordinate used
  (and change sign: back to "logical" value: +1 when R increases downward)
o added an include barrier to the default CPP_OPTIONS.h and
  removed the #include "PACKAGES_CONFIG.h" from it
o fix a bug in mom_fluxform (from chk51j_post)

checkpoint51j_post (2003/10/10)
o Added some AD-related initialisations in mom_vecinv/ mom_fluxform/
o adjusted some flow directives (dynamics, thermodynamics)
o added cubed-sphere case to test cost function
o heckpoint_lev?_directives.h now include
  pkg-specific directives, whenever those are enabled.
o Moving pkg-specific flow directives to corresponding pkg
  Moving pkg-specific differentiation list to corresponding pkg
  Moving pkg-specific checkpoint-lev storing to corresponding pkg
  ---> conventions are
       - pkg_ad.flow
       - pkg_ad_diff.list
       - pkg_ad_check_lev?_dir.h

checkpoint51i_post (2003/10/09)
o merge of the branch-genmake2
  - knowingly breaks the older genmake
  - automatic generation of all ALLOW_${PKG_NAME} defines
  - new testreport supersedes older testscript
o large number of package inclusion and header cleanups
checkpoint51i_pre (2003/10/08)

o new output for adjoin of global ocean vector invariant
o fix for checkpoint of thermodynamic seaice and bulk_force
o Steph gchem various cleanups

checkpoint 51h_pre
o fixed some single quotes
o modify gchem pkg to be more versatile
o modifications to clean up dic pkg
o add pkg/cfc

checkpoint51g_post (2003/10/02)
o provide links for ARPACK and ADM*TLM
o start removing verification/vero/
o update AD-related stuff
  (in particular some IF-statements in model/src/ routines)
o adding to verification/global_ocean.90x40x15/ adjoint of
  vector invariant setup

checkpoint51f_post (2003/10/02)
o update advect_xz/output.txt (left from chekpoint50f_pre, ini_vel modif)
o Mods and bug fixes to pkg/cal, pkg/exf, etc., needed for computation
  of tracer Green's fucntions for ocean inversion project.

checkpoint51f_pre (2003/08/07)
o Added on-the-fly spatial interpolation capability
    "USE_EXF_INTERPOLATION" to pkg/exf.
  - This is a temporary Cartesian-grid hack until
    the super-duper ESMF coupler becomes available.
  - See verification/global_with_exf/README for usage example.
  - Removed obsolete EXFwindOnBgrid and SEAICEwindOnCgrid
    flags and modified pkg/seaice accordingly.
o Bug fix to pkg/ptracers, pkg/generic_advdiff/gad_calc_rhs.F,
    and pkg/kpp/kpp_transport_ptr.F for dealing with tracer
    non-local transport term.

checkpoint51e_post (2003/08/03)
o pkg/mom_vecinv:
  - changes related to hFac: use S/R from aim.5l_cs/code (coriolis & vort.advec)
  - add time-ave diagnostic of vorticity advection.
o add diagnostic (instantaneous) of Shapiro Filter effect for T,S & UV.
o atmospheric geopotential: - include water vapor effect;
                            - use p^kappa in p* scaling.
o land pkg: read initial state from files.
o AIM : add stratospheric drag in the upper level

checkpoint51d_post (2003/07/18)
o change function ILNBLNK (=> last non-blank char.) to return zero
  (instead of the string length) when the string. char is empty
o fix bug in dxV,dyU definition of cubed-sphere grid (ini_curvilinear_grid)
o modif's to restore TAMC compatibility
  - avoid "_d" constructs in PARAMETER declarations
  - avoid interrupting lines by comment lines
o Use cluster local disks for purely local I/O
  vs. globally visible disks needed for ctrl stuff
  (merged from ecco-branch)
  - new active_file_loc... and mdsio_..._loc routines
  - affected packages: autodiff, ctrl, grdchk, mdsio

checkpoint51c_post (2003/07/08)
o introducing integer flag debugLevel
  - debLevZero: suppress all output
  - debLevA: standard
  - debLevB: equivalent to current debugMode=.TRUE.
o introducing pathname variable mdsioLocalDir for mdsio
  that can be specified at runtime
  (relevant for cluster I/O to local disk)
`
>>>checkpoint51b_post
adjoint of ptracers
o disentangled ALLOW_PTRACERS using new ALLOW_GCHEM
o extended state in checkpoint_lev?, etc.
o alternative ctrl/cost with tr1 or ptracer
o new comlev1_bibj_ptracers
o new ptracers.flow
o made ptracers_forcing same as external_forcing_s
o added verification for adjoint with ptracers
  - adm. grdchk fail so far
  - tlm. grdchk OK
  - checked tapelev/comlev recomputations: OK
<<<checkpoint51b_pre

checkpoint51a_post (2003/06/25)
o added code for biogeochemistry package
  - new pkgs: dic, gchem
  - new subroutine in ptracers
o modify code for biogeo packages
  - in model/src and pkg/ptracers

checkpoint51 (2003/06/24)
o merged improved packages from ecco-branch (ecco_c51_e34) to MAIN
  - autodiff, ctrl, exf, grdchk, seaice
  kept separate packages
  - cost, ecco, obcs
o updating verification/internal_wave, verification/lab_sea
  (all verif's pass on faulks.lcs.mit.edu RH7.3, g77)

checkpoint50i_post (2003/06/23)
o Preparing next differentiable checkpoint and sync
  of MAIN vs. ecco-branch
  - 1st step: this one is differentiable
  - 2nd step: next(! not this) checkpoint will have updated packages
              from ecco-branch)

checkpoint50h_post (2003/06/20)
o new package "land": provide surface BC for AIM.
o pkg/ptracers: apply exchange to all tracers after reading a pickup.
o AIM: use true log-P extrapolation for near surface temp (= as in
    F.Molteni paper) ; update aim.5l_cs output.
o New variable in PARM03 for more flexible pickups
o somewhat cleaned package initialisation sequence for
  ctrl/ cost/ ecco/ in packages_... routines

checkpoint50g_post (2003/05/23)
o merged with release1_p17 (pkg/seaice and verification/lab_sea)
  - added SEAICE_MULTILEVEL for 8-category sea-ice thermodynamics
  - LSR sea-ice dynamic solver moved to SouthWest B-grid location and
    made the default because of faster convergence than ADI

checkpoint50f_post (2003/05/23)
o exf totally restructured
  - replaced all exf_set_ routines by one generic exf_set_gen.F
    and made sure it's still differentiable
  - split exf_getffields.F into new exf_bulkformulae.F
  - exf_inscal_/exf_outscal_ suffixes consistent with field names
  - updated adjoint/makefile and relevant verif. accordingly

checkpoint50f_pre (2003/05/23)
 o AIM: near surface temp evaluated from Pot.Temp: fixed for Part Cell ;
      + change Evap over land. (update aim.5l_cs output)
 o added missing .cvsignores and made uniform across expts
 o changed configuration of tidal_basin_2d expt
 o added pkg/debug functions for tracing code in fatal crashes
 o tidied pkg/monitor to use MONITOR_OPTIONS.h
 o new fn in pkg/monitor to stop model if solution grows too big
 o removed lots of single quotes from comments

checkpoint50e_post (2003/05/14)
o make KPP work with PTRACERS
 - fix gad_calc_rhs to call new routine kpp_transport_ptr, which is
   nearly a copy of kpp_transport_s
 - there is no analogue to SurfaceTendencyS, so I have to use
   gPtr(of the surface layer) instead
o add a new platform SunFire+mpi (SunFire 15000) to genmake
checkpoint50e_pre (2003/05/13)

checkpoint50d_post (2003/05/13)
o change kpp output from multiple-record state files to single-record state
  files analogous to write_state.F
o reduce the output frequency of cg3d-related stuff to the monitor frequency,
  analogous to the cg2d-related output.
o fix small problem with in ptracers_write_checkpoint.F: len(suff)=512,
  so that writing to internal file fn (with length 512) fails.
checkpoint50d_pre (2003/05/12)

checkpoint50c_post (2003/05/12)
o fix problem in ini_procs.F when using MPI (was there since checkpoint48f)
o add monitor diagnostic of vorticity (mon_vort3.F) and potential energy.
o add time-average diagnostic of U*V and vertical diffusive flux for theta.
o bug fixed in convective adjustment diagnostic (multi-tile set-up).
o 4th Order Adv scheme: return to previous (c40pre7) masking near boundaries.

checkpoint50c_pre (2003/04/30)
Merging from release1_p13:
o bug fix for pkg/seaice dynamic solver
o Added SEAICE_initialHEFF to pkg/seaice

checkpoint50b_post (2003/04/17)
o store u*,v* in gU,V instead of in guNm1,gvNm1
o in order to put the momForcing out of the Adams-Bashforth:
  move forcing & CD-scheme calls from mom_fluxform & mom_vecinv
  to timestep.F
o new flag "useCDscheme" (default=F); replace guCD,gvCD by local arrays
o re-generate output for highly sensitive test-exp:
   global_ocean_pressure, ideal_2D_oce, lab_sea, natl_box

checkpoint50b_pre (2003/04/17)
o restore the use of momAdvection & useCoriolis flags (mom_vecinv)
o corrected CPP option mismatch in exf_Bulk... functions for case
  #define ALLOW_ATM_WIND && #undef ALLOW_ATM_TEMP

checkpoint50a_post (2003/03/21)
o Bug fix for merging between c50 and KPP.
  ikey was passed from thermodynamics to kpp_calc via
  common block rather than being recomputed in kpp_calc,
  in contradiction with new key itdkey.
  New key ikppkey created, and tamc.h headers updated.

checkpoint50 (2003/03/08)
- 2nd step of merge with ecco-branch:
  merge changes in ecco-branch back into main trunk
- bug fix in find_alpha
- more storing in gmredi_calc_tensor.F, kpp_routines.F
- avoid iterative loop in ini_pressure for ALLOW_AUTODIFF_TAMC
- merged some sliced AD support routines

checkpoint49 (2003/03/06)
merged from ecco-branch:
o exf:
  - Enable initialisation of forcing fields to constant
    (runtime) values.
  - in exf_getffields.F
    Reduce i-/j-loop to interior domain, discarding overlaps.
    That also fixes wrong TAF-key computations for key_1, key_2
    with bulf formulae.
  - exf_init.F modify #ifdef for exf_init_evap
  - exf_getffieldrec.F, ctrl_getrec.F
    The following INT-usages are not safe:
      fldsecs  = int(fldsecs/fldperiod)*fldperiod
      fldcount = int(fldsecs/fldperiod) + 1
    and were modified.
o autodiff: checkpoint_lev...
  - updated storing for bulk formulae (some arrays were missing)
  - added state for seaice package
  - synchronized with main branch
o DIVA:
  Modif.s in
  - the_main_loop.F
  - the_model_main.F
  and added cost_final_restore.F cost_final_store.F
  o With these changes, it is possible to fully separate
    the first forward run to compute the cost function (mdthe_main_loop)
    and adjoint runs over individual DIVA intervals (adthe_main_loop)
    into separate model executions.
    This enables better tuning of DIVA to given queue sizes.
  o Loss of cost function value in consecutive DIVA runs is
    fixed by storing to 'costfinal' file.
  o Appropriate call of ctrl_unpack/_pack,grdchk_main at
    beginning/end of adjoint integration is accounted for.
  The current changes apply to TAF-1.4.26.
  TAF has one remaining bug, requiring one manual change
  (see MITgcm manual).
o cal: synchronized between MAIN and ecco-branch

checkpoint48i_post (2003/03/05)
o Changes to restore differentiability of code w.r.t. previous tag
  (mostly adding new routines to make list and replacing
  pressure by totPhiHyd).
o Updated and merged grdchk package
  - has both ADM and TLM checks
  - works for single- and multi-proc.
  - output cleaned
  - worked successfully for parallel DIVA
o genmake:
  - Adding -platform=SP4
  - Modif. for DEC Alpha (many don't have makedepend; use mkdep instead).
o Modif. for DIVA:
  ctrl_unpack should not be called in intermediate DIVA interval.
  (similar thing would apply for active files such as
  tbar, sbar, psbar, which should not be reinitialised;
  only relevant for ecco-branch)

checkpoint48h_post (2003/02/28)
o improve "ini_p_ground" when using finite difference form for calc_phi_hyd
o Added net flux to downward flux conversion to pkg/exf/exf_getffields.F
o Added SEAICE_initialHEFF to pkg/seaice
o ecco_the_model_main.F: SEAICE_WRITE_PICKUP must precede WRITE_CHECKPOINT

checkpoint48g_post (2003/02/18)
--- EOS:
o compute locally the pressure for use in EOS: UNESCO, JMD95P, MDJWF
  store total Potential in totPhyHyd for diagnostics & EOS.
o fix restart and overlap Pb when using Z-coord and EOS funct. of P
--- Pressure/geopotential gradient:
o use Ro_surf & R_low instead of hFac in cal_phi_hyd:
o NLFS + p-coord.: eta*Alpha' is not longer lagging 1.time-step behind
  ( changes results of global_ocean_pressure )
o NLFS + z-coord.: add eta*Rho' contribution.
o accurate phiHyd when using interface-W at the middle between 2 centers
 ( changes results of ideal_2D_oce )
o includes r* 2nd term in potential gradient.

checkpoint48f_post (2003/02/18)
Merging from release1_p12:
o Modifications for using pkg/exf with pkg/seaice
  - improved description of the various forcing configurations
  - added basic radiation bulk formulae to pkg/exf
  - units/sign fix for evap computation in exf_getffields.F
  - updated verification/global_with_exf/results/output.txt
o Added pkg/sbo for computing IERS Special Bureau for the Oceans
  (SBO) core products, including oceanic mass, center-of-mass,
  angular, and bottom pressure (see pkg/sbo/README.sbo).
o Lower bound for viscosity/diffusivity in pkg/kpp/kpp_routines.F
  to avoid negative values in shallow regions.
  - updated verification/natl_box/results/output.txt
  - updated verification/lab_sea/results/output.txt
o MPI gather, scatter: eesupp/src/gather_2d.F and scatter_2d.F
o Added useSingleCpuIO option (see PARAMS.h).
o Updated useSingleCpuIO option in mdsio_writefield.F to
  work with multi-field files, e.g., for single-file pickup.
o pkg/seaice:
  - bug fix in growth.F: QNET for no shortwave case
  - added HeffFile for specifying initial sea-ice thickness
  - changed SEAICE_EXTERNAL_FLUXES wind stress implementation
o Added missing /* */ to CPP comments in pkg/seaice, pkg/exf,
  kpp_transport_t.F, forward_step.F, and the_main_loop.F
o pkg/seaice:
  - adjoint-friendly modifications
  - added a SEAICE_WRITE_PICKUP at end of the_model_main.F

checkpoint48e_post (2003/02/12)
o New S/R for diagnostic of bottom pressure (phi0surf was missing in c48d_post)
o dynamics: change definition of computational domain & adapt mom_fluxform
  accordingly ; when viscA4=0, allows to run the dynamics with Olx=Oly=2.
o following exp works with Olx=Oly=2 (and pass through checkbounds option):
    adjust_nlfs.cs-32x32x1 adjustment.128x64x1 adjustment.cs-32x32x1
    exp0 exp1 exp2 exp4 exp5 hs94.cs-32x32x5 hs94.128x64x5 hs94.1x64x5
    global_ocean.90x40x15 global_with_exf global_ocean_pressure
    inverted_barometer solid-body.cs-32x32x1
  (high order AdvScheme and/or multiDimAd works with Olx=Oly=2 ? not sure)

checkpoint48d_post (2003/02/09)
o in preparation for r*:
 a) use pre-computed gradient of hydrostatic potential:
    changes in timestep.F & mom_cdscheme.F affects results of ideal_2D_oce
 b) move phi0surf from calc_phi_hyd to calc_grad_phi_hyd:
    => affects results of glob_oce_pressure (different truncation error)
  update output.txt of ideal_2D_oce & global_ocean_pressure

checkpoint48d_pre (2003/02/08)
o in preparation for r*:
  new S/R (calc_grad_phi_hyd.F) to compute Hydrostatic potential gradient.
  pass the 2 comp. of the grad. as arguments to momentum S/R.
  but for the moment, only used if it does not change the results.
o add finite volume form of calc_phi_hyd for buoyancyRelation OCEANIC & OCEANICP

checkpoint48c_post (2003/02/06)
Modifications in treatment of initial flux forcing controls
to avoid extra storing of flux fields.

checkpoint48c_pre (2003/01/21)
o Added tidal_basin_2d experiment (currently 1D!)
o can use r* Coordinate with OBC (but Orlanski Rad. BC not yet implemented)

checkpoint48b_post (2003/01/27)
o r* coordinate added in #ifdef NONLIN_FRSURF block.
 (modification to pressure gradient not yet implemented)
o mom_fluxform: new S/R mom_calc_rtrans.F computes vertical transports
  (for U & V) that are used for vertical advection of momentum.

checkpoint48a_post (2003/01/24)
o In preparation for r*, use temp. array to compute vertical transport
   in flux-form momentum pkg. => change results of few test-exp.
  Update output of: exp4, exp5, front_relax, global_ocean_pressure,
                    lab_sea, natl_box & plume_on_slope

checkpoint48 (2003/01/23)
o fix small bug that was causing lot of warning (TIMER_STOP 'UPDATE_CG2D')

checkpoint47j_post (2003/01/21)
o add new exp. (ideal_2D_oce) to test "exotic" parameters and options.
o moved adexch from forward_step to addummy_in_stepping
o added exch in ctrl_map_...
o aveFreq.=0. at end of cost_final to avoid overwrite in
  reverse checkpointing loop
o Yet more changes in gmredi:
  * adgmredi_calc_tensor
    avoiding all recomputation of gmredi_slope_limit
  * adgmredi_x/y/rtransport
    added flag for excessive storing to avoid recomp. of
    u/v/rtans, dTdx/y/z
    -> this is not really necessary and very memory-consuming
  * adgmredi_slope_psi:
    consistency with gmredi_slope_limit in treatment of GM_slopeSqCutoff
  * gmredi_slope_limit
    re-activated full calculation of taperfct for case 'ac02'
o updating verification/ adjoints of carbon, global_ocean.90x40x15

checkpoint47i_post (2003/01/13)
o GM_EXCLUDE_() replace GM_TAPER_(): by default, all the code is compiled.
o add GM_Small_Number & GM_slopeSqCutoff as run-time parameters (data.gmredi)
  default values = 1.D-12 & 1.D+48 (=> give same results as checkpoint47f_post)
o cg2dTargetResWunit: define tolerance using deltaTmom (and not deltaTfreesurf)
o gmredi: fix few bugs.

checkpoint47h_post (duplicate tag for PH's c48 tag, in order to move c48)
This will be a good checkpoint to plug into the ecco-branch.
o few modif.'s to get latest version adjointed
  (mainly kick out code in ini_linear_phisurf)
o modif's to run adjoint with exactConserv
o case GM_BOLUS_ADVEC should be cleaned
  S/R gmredi_slope_psi should be cleaned
o verification/carbon now has exactConserv=.TRUE.

checkpoint47g_post (2003/01/10)
o time-average AIM output: becomes independent from statvars time-average
  (can be used with #undef ALLOW_TIMEAVE) ; add new variables (e.g., RH)
o After TAF bug fix:
  Tested adjoint of gmredi package.
  Tests were done with checkpoint47 rather than with latest
  checkpoint47f_post since the latter is broken for the adjoint
  verification/carbon/ contains both ADM and TLM gradient checks.
Here they are, before they get changed/lost/stolen.
Mostly modif.'s to fix numerical sensitivities.
Gradient checks OK for
- GM_taper_scheme:
  * clipping
  * ac02
  * linear
  * glw91
  * dm95
  * ldd97
- GMREDI_OPTIONS:
  * GM_VISBECK_VARIABLE_K
  * GM_NON_UNITY_DIAGONAL
  * GM_EXTRA_DIAGONAL
  * GM_BOLUS_ADVEC
in conjunction with data.gmredi parameters to be checked in
in a few minutes under verification/carbon/code/

checkpoint47f_post (2002/12/28)
Merging from release1_p10:
o modifications for using pkg/exf with pkg/seaice
  - pkg/seaice CPP options SEAICE_EXTERNAL_FORCING
    and SEAICE_EXTERNAL_FLUXES
  - pkg/exf CPP options EXF_READ_EVAP and
    EXF_NO_BULK_COMPUTATIONS
  - usage examples are Experiments 8 and 9 in
    verification/lab_sea/README
  - verification/lab_sea default experiment now uses
    pkg/gmredi, pkg/kpp, pkg/seaice, and pkg/exf

checkpoint47e_post (2002/12/27)
o created a tag prior to creating a branch

checkpoint47d_post (2002/12/16)
o fixed bug in the oceanic pressure coordinates code: vertical viscosity
  at the bottom boundary had an erroneous half slip boundary condition
o added bottom drag and no slip boundary condition capabilities to
  oceanic pressure coordinates code
o added new verification experiment global_ocean_pressure, this experiment is
  also described in the tutorial section of the manual
checkpoint47d_pre (2002/12/16)

checkpoint47c_post (2002/12/16)
o Added a verification experiment for a global cubed-sphere ocean run
  -  verification/global_ocean.cubed32x32x30
  -  uses pkg/therm_seaice and pkg/bulk_forcing

o allow to run AIM physics with SPEEDY input files (from Franco Molteni)
o allow a more accurate definition of Ro_Surf (selectFindRoSurf=1)
  when using P-coordinate; only implemented for atmospheric config.
o OCEANICP & realFreshWater: include P-E direct effect on wVel ;
  NOTES: requires option NONLIN_FRSURF to be "#define".
o update advect_xz/results/output.txt (left from checkpoint44g_post)

checkpoint47b_post (2002/12/05)
Merging from release1_p9:
o pkg/seaice
  - removed GOTO's and added taf directives
  - double precision constants to reduce the g77 (Linux)
    to F77 (SGI) differences reported in release1_p8
o tools/genmake
  - added SGI options
o verification/testscript
  - updated to that of checkpoint47a_post
o verification/global_ocean.90x40x15/input/eedata
  - modified for SGI f77 compatibility
o verification/lab_sea
  - added description of sea-ice model
  - added missing matlab routines
  - added test of thermodynamics parallelization

checkpoint47a_post (2002/11/23)
o new pkg: aim_v23
 = F. Molteni atmos.physics (SPEEDY, ver23) adapted to MITgcm.
   for now, keep the same surface forcing as before.
 - Part-Cell implemented into AIM; check that Heat & Water are conserved
 - aim.5l_cs: use new aim pkg (run 10yr & get better results than before)
 - aim.5l_LatLon & aim.5l_Equatorial_Channel are still using old aim pkg
o add diagnostic of surface correction term in monitor output

o bulk_force and therm_seaice
- Two packages:  bulk_force (Bulk forcing)
  and therm_seaice (thermodynamic_seaice) - adopted from LANL CICE.v2.0.2
- Earlier integration from Stephaine Dutkiewicz
  and Patrick Heimbach.
- Two ifdef statements for compile time,
   ALLOW_THERM_SEAICE and ALLOW_BULK_FORCE

checkpoint47 (2002/11/15)
differentiable version of checkpoint46n_post
o bug fix in quasihydrostaticterms
o * "clean" adjoint code (in terms of extensive recomputations)
    can now be obtained for all GMREDI options (i.e. for
    - GM_VISBECK_VARIABLE_K
    - GM_NON_UNITY_DIAGONAL
    - GM_EXTRA_DIAGONAL
    - GM_BOLUS_ADVEC )
  * However, wrong gradient check problem remains unsolved.
  * New CPP options have been introduced for different
    tapering schemes
o external_fields_load now part of differentiation list
o pressure needs multiple storing;
  would be nice to have store_pressure at beginning or
  end of forward_step, e.g. by having phiHyd global (5-dim.)
  (NB: pressure is needed for certain cases in find_rho,
  which is also invoked through convective_adjustment).
o recomputations in find_rho for cases
 'JMD95'/'UNESCO' or 'MDJWF' are OK.
o #define ATMOSPHERIC_LOADING should be differentiable
o ini_forcing shifted to begining of initialise_varia
o Incorporating QNVS line search routines into MITgcm
  (this is separate code, and therefore not under pkg)
  lsopt/, optim/
o Updated verification/carbon/
  - #define GM_VISBECK_VARIABLE_K
  - GM_taper_scheme    = 'ldd97'

checkpoint46n_post (2002/11/12)
Merging from release1_p8:
o verification/natl_box:
  updating new external_fields_load routine
o New package: pkg/seaice
  Sea ice model by D. Menemenlis (JPL) and Jinlun Zhang (Seattle).
  The sea-ice code is based on Hibler (1979-1980).
  Two sea-ice dynamic solvers, ADI and LSR, are included.
  In addition to computing prognostic sea-ice variables and diagnosing
  the forcing/external data fields that drive the ocean model,
  SEAICE_MODEL also sets theta to the freezing point under sea-ice.
  The implied surface heat flux is then stored in variable
  surfaceTendencyTice, which is needed by KPP package (kpp_calc.F and
  kpp_transport_t.F) to diagnose surface buoyancy fluxes and for the
  non-local transport term.  Because this call precedes model
  thermodynamics, temperature under sea-ice may not be "exactly" at
  the freezing point by the time theta is dumped or time-averaged.
  N.B.: fairly large differences in accuracy occur across
        different platforms/compilers; comparison between
        g77 (Linux) and F77 (SGI Origin 2000/MIPSpro)
        generated output gives:
   T           S           U           V
  C D M    c        m  s        m  s        m  s        m  s
  n p a R  g  m  m  e  .  m  m  e  .  m  m  e  .  m  m  e  .
  f n k u  2  i  a  a  d  i  a  a  d  i  a  a  d  i  a  a  d
  g d e n  d  n  x  n  .  n  x  n  .  n  x  n  .  n  x  n  .

  Y Y Y Y  5  5  7  7  7  8 10  9  6  6  6  6  7  5  7  5  7 FAIL  lab_sea
o GAD:
  - generated new common blocks to account for call of
    same gad routines with differing traceridentities
    (needed to modify tracerIdentity indices in GAD.h)
  - generated separate common blocks for case useCubedSphereExchange
    (Department of Futurology)
  - parameter lists to gmredi_?transport: added tracerIdentity
  - added new key indices to tamc.h
o external_fields_load:
  - added this routine to TAF list
  - needed to make some common blocks global and additional storing
    along the same lines as exf package (checkpoint_lev?_directives.h)
o exf:
  updated external forcing package
  - bug fixes carried over from ecco-branch
    (missing OBCS_OPTIONS.h in two routines)
  - enable easy to use "no forcing".
  - added exf I/O for atmospheric loading
  - added exf I/O for runoff data
  - transfered scaling between exf <-> MITgcm to exf namelist
o Adding new verification experiment global_with_exf.
  This verification experiment is almost identical to the
  global_ocean.90x40x15 experiment, except that it uses
  the exf (and cal) package instead of the
  external_fields_load routine (cf README file).

checkpoint46m_post (2002/11/07)
o modified testscript to return -- when there are no lines of "%MON" output
o added new flag "quasiHydrostatic" for QH mode
  and new routine quasihydrostaticterms()
o added 2*Omega*Cos(phi)*W to u equations (non-hydrostatic Coriolis term)
  New routine: mom_u_coriolis_nh()
o fixed sign of non-hydrostatic metric terms in u and v equations.
  Depend on correct sign of gravitySign.
o added work.pc* to .cvsignore in aim directories using ifc
o introduced flag for controllin non-hydrostatic metric terms
o removed gravitySign from PARM04
o switched to g77/ifc from pgf77 in aim experiments

checkpoint46l_post (2002/11/01)
o made convective adjustment work with pressure coordinates:
 - changed the direction of k-loop in convective_adjustment.F for the
   case of pressure coordinates (OCEANICP,ATMOSPHERIC buoyancyRelation)
 - adjusted the reference pressure k-index in convective_adjustment.F
 - adjusted the convection condition in convect.F (in analogy to
   calc_ivdc.F)
 - convective_adjustment no longer computes anything on the halos
 - removed the warnings about negative salinity from find_rho.F and
   find_alpha.F; instead the new routine look_for_neg_salinity, called
   at the beginning of find_rho, find_alpha, and find_beta, does a
   check of the entire slice, if CPP-option
   CHECK_SALINITY_FOR_NEGATIVE_VALUES is defined
checkpoint46l_pre (2002/10/23)

checkpoint46k_post (2002/10/23)
o fixed the verification/global_ocean.90x40x15 experiment:
 - new bathymetry (the world according to A., JMC, and M.)
 - new initial fields and forcing fields (*.bin files)
 - new POLY3.COEFFS (for the next release one should switch to a full
   equation of state: JMD95P or MDJWF)
 - fixed several errors and redundancies in the data file
 - experiment uses looped cells
 - added matlab directory with diagnostic scripts for plotting of output

o S/R aim_initialise.F replace S/R aim_init from file aim_do_inphys.F:
 - read AIM physics parameters from a file (data.aimphys)
 - set defaults values = F.Molteni paper (Clim.Dyn., 2002)

checkpoint46j_post (2002/10/07)
o split calc_exact_eta in 2 S/R : integr_continuity & update_etaH
o move wVel computation at the end of the time step, in S/R integr_continuity
o create specific S/R to exchange T,S before DYNAMICS (for stagger time step)
o update timeave pkg for wVel diagnostic.
checkpoint46j_pre (2002/09/27)

checkpoint46i_post (2002/09/25)
o Clean up AIM package (and keep the results unchanged):
  include CPP_OPTION and use IMPLICT NONE in all routines ;
  declare all the variables _RL ; use _d 0 for all numerical constants.
  use ifdef ALLOW_AIM everywhere. And now AIM can be used with g77 !

checkpoint46h_post (2002/09/25)
o cleaned up the use of rhoNil and rhoConst.
  - rhoNil should only appear in the LINEAR equation of state, everywhere
    else rhoNil is replaced by rhoConst, e.g. find_rho computes rho-rhoConst
    and the dynamical equations are all divided by rhoConst
o introduced new parameter rhoConstFresh, a reference density of fresh
  water, to remove the fresh water flux's dependence on rhoNil. The default
  value is 999.8 kg/m^3
o cleanup up external_forcing.F and external_forcing_surf.F
  - can now be used by both OCEANIC and OCEANICP
checkpoint46h_pre (2002/09/18)

 Added code to convert surface volume flux (fresh water) into
 a mass flux when using P coordinates in the ocean (OCEANICP).
 Note: It assumes you have set rho0=rhoConst=density of fresh water.

checkpoint46g_post (2002/09/18)
o Include a new diagnostic variable phiHydLow for the ocean model
  - in z-coordinates, it is the bottom pressure anomaly
  - in p-coordinates, it is the sea surface elevation
  - in both cases, these variable have global drift, reflecting the mass
    drift in z-coordinates and the volume drift in p-coordinates
  - included time averaging for phiHydLow, be aware of the drift!
o depth-dependent computation of Bo_surf for pressure coordinates
  in the ocean (buoyancyRelation='OCEANICP')
  - requires a new routine (FIND_RHO_SCALAR) to compute density with only
    Theta, Salinity, and Pressure in the parameter list. This routine is
    presently contained in find_rho.F. This routine does not give the
    correct density for 'POLY3', which would be a z-dependent reference
    density.
o cleaned up find_rho
  - removed obsolete 'eqn' from the parameter list.
o added two new verification experiments: gop and goz
  (4x4 degree global ocean, 15 layers in pressure and height coordinates)
checkpoint46g_pre (2002/09/16)

checkpoint46f_post (2002/09/16)
o Enable tangent linear (forward mode) gradient checks:
  - extended active file handling to g_... files
  - added TANGENT_SIMULATION to theSimulationMode
  - extended grdchk package accordingly
o added tangent linear setup in verification/carbon/code_ftl
o added adjoint setup in verification/front_relax/code_ad

checkpoint46e_post (2002/09/05)
o Added new equation of state -> MDJWF
  - EOS of McDougall et al., 2002, JAOT, submitted
  - caveat: the equation of state is only valid for a smaller (more
    realistic?) range of values than JMD95P/Z and UNESCO
  - added masks to the calculation of pressure in store_pressure
  - added more check values for density in check_eos (ini_eos.F), some of
    the old check values are out of the range of the MDJWF-eos, so don't
    expect perfect matches for those
checkpoint46e_pre (2002/08/19)

checkpoint46d_post (2002/08/19)
o fixed store_pressure to work with both buoyancy relation = 'OCEANIC' and
  'OCEANICP', also initialised field pressure correctly in ini_eos in the
  case of pressure coordinates. eosType='JMD95Z' in
  combination with buoyancyRelation='OCEANICP' now causes an error.
o Changed p = pressure(i,j,k,bi,bj)  to  p = pressure(i,j,kRef,bi,bj)
  in find_alpha/beta.
checkpoint46d_pre (2002/08/15)

o Changed p = pressure(i,j,k,bi,bj)  to  p = pressure(i,j,kRef,bi,bj)
  so that JMD95Z and JMD95P give approptiate static stability in find_rho.

checkpoint46c_post (2002/08/15)
o Changes necessary for ocean in p-coordinates
 -  Added new buoyancy relation = 'OCEANICP'
 -  Added new parameters = gravitySign (this used to be contained inside
    the factor dRdZ which I added when we first switched to R coordinates).
 X GM/Redi is not compatible (yet)
 X bottom drag and no-slip need to be debugged.
checkpoint46c_pre (2002/08/07)

checkpoint46b_post (2002/08/07)
o Added new equation of state -> JMD95Z and JMD95P
  - EOS of Jackett and McDougall, 1995, JAOT
  - moved all EOS parameters into EOS.h
  - new routines ini_eos.F, store_pressure.F
o Added UNESCO EOS, but not recommended because it requires
  in-situ temperature (see JMD95)
o Modified formatting for knudsen2.f in utils/knudsen2 and added
  unesco.f to be used with POLY3
checkpoint46b_pre (2002/07/31)

checkpoint46a_post (2002/07/31)
o Added (atmospheric) pressure loading
  - new field in FFIELDS.h, etc...
  - new cpp flag ATMOSPHERIC_LOADING
o Changed hFacC to _hFacC in calc_phi_hyd.F
o Added SHORTWAVE_HEATING to some files for consistency
checkpoint46a_pre (2002/07/13)

checkpoint46 (2002/07/13)
further merges from release1_p5
o new ctrl package
  - adopted from ECCO environment to enable optimization
  - added Eliassen Palm fluxes to controls
o added Eliassen Palm flux controls to gradient check package
o cost package
  - Compatible with new ctrl package
  - added Eliassen Palm cost hooks
  - modif's of existing cost functions
o Adjoint-related bug fixes in kpp:
  - kpp_calc: sore of kpphbl avoids recomputation/call to S/R kppmix
  - kpp_routines: store of Rib avoids partial recomputation bug of TAF.
o autodiff package
  - flow directives:
    + new for S/R do_the_model_io
    + enhanced for S/R checkpoint
    + new gmredi.flow
  - Introduced CPP option ALLOW_AUTODIFF_MONITOR to
    disable adcommon.h/g_common.h by default.
  - fixed problem for adjoint of global_max
o modified verification/carbon/
o New setup for adjoint of global_ocean
o added hooks for Eliassen Palm fluxes (dynamics.F, ini_fields.F)
o cleaned TAF keys iikey, idkey (dynamics.F, thermodynamics.F)
o incorporated hooks for sponge layer code (external_forcing.F)

checkpoint45d_post (2002/07/12)
o import 2 fixes from release1_p5 (CG2D.h & packages_readparms.F)
o use recip_dx*,recip_dy* instead of /dx*,/dy* in orlanski_E,W,N,S
  (affects plume_on_slope "cg2d" output)
o add new parameter deltaTfreesurf for free-surface time stepping
o exchange gT,gS when using staggerTimeStep & GM & Oly<4
o NONLIN_FRSURF: rescale gNm1 to get a better conservation with A-B
o change phiMin in exp1 (to agree with documentation)
o add new flags:
 - T,S forcing inside/outside Adams-Bashforth
 - turn off temp,salt advection and/or forcing
 - for each tracer, define internal flag for multiDimAdvection & A-B
o monitor: change definition of KE to check conservation of Energy

checkpoint45c_post (2002/05/30)
o Removed f90 comments ("!")
o Modified initialisations to enable exf package for MITgcm
  (without invoking ECCO_PACKAGE).
o modifications to gradient check package (Martin Losch)
  - enable centered differences
  - modified format of standard output

checkpoint45b_post (2002/05/30)
o cleaned exchange calls in cg2d
o Included CPP option ALLOW_AUTODIFF_MONITOR in forward_step
o included CPP option SINGLE_LAYER_MODE in thermodynamics
  to configure barotropic setup (Martin Losch)
o moved some initialisations within bi,bj loop in dynamics
  (TAF flow dependency)
o in initialise_varia, moved call packages_init_variables
  before convective_adjustment_init
  (corresponding adjustment of TAF tape initialisation).
o in calc_diffusivity/calc_viscosity extended domain to full overlap.

checkpoint45a_post (2002/05/01)
o compute Rho over the whole domain (extend iMin,jMin indices)
o specific exchange for X-slice domain (case Ny=1)
o argument futureIter of S/R obcs_calc missing in exp4 & internal_wave /code
o solve_for_pressure : set cg2d_x to zero where OBCS are applied

checkpoint44h_post = checkpoint45
o Fix to restore differentiability:
  place at which packages_init_variables is called in
  initialise_varia is crucial for reverse control flow.
o modifications in GMRedi to enable stable adjoint
  (corresponding modif's in thermodynamics, dynamics)
o added missing hook for sponge layer code in external_forcing
o modified test cost functions
o storing in gad_advection (plus removal of write(0,*)!
o missing headers TR1.h added in convective_adjustment routines
o errorMessageUnit set non-equal zero in eeboot
  (conflict on some platforms, e.g. IBM SP3)
o modified carbon verif.

checkpoint44h_pre (2002/03/14)
o vertical grid option: allow to put the Interface at the middle between
  2 cell-centers ; replace delZ in pkg/kpp by drF.
o GM Advective form: Tracers are advected using the residual transport (=
  Euler+GM-bolus); set param GM_AdvSeparate=T to return to previous form.

checkpoint44g_post (2002/03/05)
o fix surface correction term in multiDimAdvection (affects plume_on_slope
  results) ; ifdef missing in thermodynamics.F

checkpoint44f_pre,checkpoint44f_post
o added PTRACERS package
  This allows an arbitrary number of passive tracers to be integrated
  forward simultaneously with the dynamicaly model.
  + Implemented so far:
    - basic forward algorithm (time-stepping, advection, diffusion, convection)
    - I/O and checkpointing
    - GM/Redi  *but*  using the GM/Redi coefficient of Salt
  + Not implemented so far:
    - KPP
    - OBCS
  + No specific example supplied (yet) but global_ocean.90x40x15 has the
    necessary data.ptracer file. Simply use -enable=ptracers and uncomment
    line in data.pkg.
  + This package is disabled by default since it increases storage.


o testscript: added -cleanup option
o Shap_filt: a) new shap_filt S/R to use no-slip BC with S2 filter
             b) enable to filter 2D fields.

checkpoint44e_pre,post
o re-wrote convective adjustment to use pre-calculated weights
  Affects: model/src/convective_adjustment.F, convective_adjustment_ini.F
  Adds:    model/src/convective_weights.F, convectively_mixtracer.F
  Original calls to convect() still in place.

chkpt44d_pre,post
o added missing EXCLUDE_MONITOR flags
o changed "e" to "_d" in gmredi_slope_limit, gmredi_slope_psi
  (incompatible typ in MIN/MAX expressions caused problems
  on IBM SP3)
o in genmake added variable MAKEDEPEND
  plus resetting for case SunOS
o added timer_stats.c routine for IBM SP3
o removed variables in dynamics
!!! I forgot to create tag chkpt44d_pre !!!
!!! But chkpt44d_pre = chkpt44c_post    !!!

o real fresh water flux implemented with non-linear free-surface.

chkpt44c_pre,post
o few fix (mask in shap_s2, EmPmR in external_field_load,
  USE_NATURAL_BCS in solve_for_P);
o add arguments myIter & myTime to S/R obcs_calc & solve_for_P

checkpoint44b_pre/_post
o merge of relevant stuff from the ecco-branch:
  - genmake: removed $S64 overwrite for case SunOS
  - pkg/exf: update and corrections for field swapping and obcs
  - pkg/ecco: parameter lists for the_model_main, the_main_loop
              harmonized between ECCO and MITgcm
  - pkg/autodiff: added flow directives for obcs, mdsio_gl_slice
                  updated checkpointing_lev... lists for obcs
  - model/src: minor changes in forward_step, plot_field
               added directive for divided adjoint in the_main_loop
  - pkg/mdsio: added mdsio_gl_slice

o check parameters & config (chkpt44a_pre,post)
o OBC and NonLin_FrSurf.

checkpoint44 (2002/01/18)
o fix bug in mom_vi_del2uv
o select when filters are applied ; add options to zonal_filter (data.zonfilt)
o gmredi: fix Pb in the adiabatic form ; add options (.e.g. Bolus advection)
o update AIM experiments (NCEP input files)
o improve and extend diagnostics (Monitor, TimeAve with NonLin-FrSurf)
o added some stuff for AD

checkpoint43 (2001/09/28)
o added two new advection tests
o added global 4x4 degree ocean test
o added test of H&S94 with free surface on cube
o some final mods for gradient check, adjoint,...

checkpoint42 (2001/09/27)
  Fixed AD-related problems:
o Store directives up-to-date with re-arranged Adams-Bashforth
  (mainly thermodynamics.F)
o New store directives for multi-dim. advection schemes
  * new CPP flag ALLOW_MULTI_DIM_ADVECTION
  * new common block and key passkey
  (mainly gad_advection.F)
o Modified store directives for split of dynamics/thermodynamics
  for the case ALLOW_KPP
o Cleaned argument list for timestep_tracer.F

checkpoint41 (2001/09/27)
o re-formatted/added comments in prologues of key subroutines
  to work with protex

checkpoint40 (2001/09/27)
o moved calc_gs, calc_gt and calc_tr1 back to model/src
o added FLT (floats) package from Arne along with demo. experiment
o re-arranged Adams-Bashforth scheme for tracers to allow easier
  implementation of forward-in-time forcing terms
o more mods for non-linear free-surface including new variable
o modified multi-dim method to work on cube
o bug fix in KPP (from DM)

checkpoint40pre9 (2001/09/27)
o added DST advection schemes
o fix MPI bug on SGI's
o modifications for non-linear free-surface
o fixed conditionals for fixed flow/passive tracer only mode
o added tension/strain form of stress tensor
o changes to commenting of arguments for TAF/TAMC
o added/updated many matlab scripts
o added multi-dimensional advection method for tracers

checkpoint40pre8 (2001/09/05)
o new package rw/
  Added method for dumping intermediate local arrays:
  mdsio_writetile - same as mdsio_writefield except works from inside
                    bi,bj loop
  mdsio_writelocal - same as mdsio_writetile except works for local
                     arrays
  write_local_r? - higher-level wrapper for mdsio_writelocal
  Controlled by diagFreq. Defaults to zero (ie. no dumps)
  Example given at end of mom_vecinv.F that dumps some local arrays.
o replaced calc_mom_rhs.F by mom_fluxform.F/mom_vecinc.F to
  control flux-form versus vector invariant code.
  Switch is runtime flag vectorInvariantMomentum (defaults to false)
  or genmake -DISABLE ...
o TAMC-related update to cope with mom_fluxform.F/mom_vecinc.F
  (additional storing is now needed for case vecinv;
  currently nothing implemented to switch this storing off
  in case fluxform is used since no CPP flag available).

checkpoint40pre7 (2001/08/14)
o bug fix in dynamics.F
  calc_viscosity called before k=1,Nr loop.
o added some #ifdef's ALLOW_PASSIVE_TRACER
o cleaned initialisations in ctrl_map_ini
  related to TAF

checkpoint40pre6 (2001/08/13)
o split dynamics into thermodynamics & dynamics
o corresponding split of calc_diffusivity into
  calc_diffusivity, calc_viscosity
  (kpp_calc_diff, kpp_calc_visc).
o Added diffkr, kapgm to control variables
o bug fix in gmredi_slope_limit for ldd97

checkpoint40pre5 (2001/07/31)
o proper initialization of Adams-Bashforth time stepping
  + uses forward step for very first step of model (iter=0)
o re-generated *all* output since almost all output is modified by this
  change (sorry but we've been putting this one off for about 2 years)
  + natl_box, aim.5l_Equatorial_Channel and aim.5l_zon-ave were
    *not* regenerated since they are already out of date and I don't
    want to create the impression that they are suddenly working.
o removed KAP stuff for DEC's
o modified/added many .cvsignore files in */code and */input
o added new expt "solid-body.cs-32x32x1"
  + this uses an alternative form of ini_curvilinear_grid.F which
    is not necessarily any better than the current one...

checkpoint40pre4 (2001/07/30)
o added re-initialisations of utrans,vtrans,rtrans in
  calc_common_factors which are crucial for TAF.
o extended iMin,jMin range for calc_common_factors,
  calc_diffusivity
o added option ALLOW_PASSIVE_TRACER
o a few minor updates and fixes

checkpoint40pre3 (2001/07/13)
o created calc_gtr1.F for gad package
o split the_main_loop and re-introduced forward_step
o some recomputations of nIter0 for TAMC

checkpoint40pre2 (2001/07/13)
o Updated to latest branch of AJA, JMC
o Added gradient check package
o Added routines for passive tracer handling
o Added carbon sequestration sensitivity experiment

checkpoint39 (2001/05/14)
 o Modifications and fixes to support TAMC
   (mainly missing or wrong directives)
 o Corrected common blocks when fooling TAMC to produce adjoint I/O
   in addummy_in_stepping
 o Updated verification/vero/ (bug fixes in code/, correct pickups in input/)
 o Enabled "sliced" (xz-,yz-) exchanges, needed for obcs.
 o Included following packages:
   cal: calendar
   exf: external forcing
   ecco: essential routines to control use of cal, exf
         (NB: this is not the full ECCO environment)
 o disabled some packages by default in genmake

checkpoint38 (2001/04/10)
 o see notes_c37_adj.txt
 o corrected wrong layer index in external_forcing_t
 o replaced the_main_loop/forward_step by the_main_loop
 o removed forceoutput from write_state
   (replaced criteria for initial/final state)
 o added runtime flag for pre-C35 pickups: usePickupBeforeC35

checkpoint37 (2001/03/13)
 o mdsio.F routine split and packaged in pkg/mdsio
   (mdsio.F and mdsio_gl.F still exist in eesupp/src but are not
    used unless genmake -disable=mdsio)
 o allow a more precise surface-geopotential gradient for the atmosphere
   taking into account the change in space of Alpha (=1/rho) at the surface.
 o variable "etaN" (replace cg2d_x) is the surface R-anomaly [r unit]
   (ocean: sea surface height [m] / atmos: surface pressure anomaly [Pa])
 o Change units: Phi_Hydrostatic (=phiHyd), Phi_Surface(=cg2d_x) and
   Phi_NonHydrostatic (=cg3d_x), all have now the dimension of a potential
   [m2/s2] (pressure/rhoConst in the ocean ; Geo-Potential in the atmosphere).
 o Time-Average diagnostics defined as a pseudo package "timeave".
 o pickup files : old pickup (before c35) did not work with new code (c35
   and after) unless activating 2 commented lines in initialise-varia.
 o Non-Hydrostatic pickup file Pb fixed.
 o bug with Rigid-lid version (since c35) fixed.

checkpoint36 (2001/02/20)
 o implement Crank-Nickelson barotropic time-stepping
 o recover Time-Average diagnostics
 o fix Pb in checkpoint (PR#19)
 o AIM become a standard package ; clean unused CPP_kees

checkpoint35 (2001/02/08)
 o subtantial rewrite of dynamics.f
 o allows staggered time-stepping
 o packaged obcs, aim (Atmospheric Physics), zonal_filt, shap_filt
 o added bottom drag (linear + quadratic)

checkpoint34 (2001/01/30)
 o Modified exchange routines for correct reverse simulation.
 o Added verification output to comply with bug fix in impldiff.F
   as of c33 (exp2, natl_box).
 o Corrected store directives in dynamics.F
 o Corrected array boundaries in impldiff.F
 o Corrected array dimensions in gmredi.
   Added temporary scalars to avoid storage by TAMC (gmredi, kpp).
 o Added routine GLOBAL_SUM_INT to global_sum.F
 o Added mdsio_gl.F for ECCO purposes.

checkpoint33 (2000/11/30)
 o Fixed bug in lower BC in impldiff.F
 o Fixed confusion about units of forcing arrays in FFIELDS.h
   namely Fu,Fv,Qnet,Qsw,EmPmR:
   - Removed verification/natl_box/code/external_fields_scale.F
     (did not differ from that in model/src)
   - Changed units of fu,fv,Qnet,Qsw,EmPmR back to proper units
     (see FFIELDS.h for description)
   - Scale fu,fv,Qnet,Qsw,EmPmR when used in external_forcing_surf.F,
     kpp_calc.F and kpp_transport_t.F
   - Removed model/src/external_fields_scale.F and calls to it
   - verification/natl_box uses flux data with "atmospheric" sign so
     a special version of external_fields_load.F is used to
     change the data as it's read in. This way, the arrays
     have the right units and signs at all times tha a user could
     possibly use them.
 o Corrected genmake to delete a temporary file during configuration

checkpoint32 (2000/11/13)
 o Scaling of forcing fields moved from external_forcing.F to
   external_fields_scale.F, called directly after loading fields.
 o Surface relaxation terms added to surface tendency fields in
   extra subroutine.
 o impldiff.F changed to avoid storing by TAMC of huge intermediate
   fields.
 o Changes in GMRedi to comply with packaging structure.
 o Modifications and bug fixes in KPP package.
 o Verification experiment for KPP added (verification/nat_box/)

checkpoint31 (2000/09/11)
 o Packages interface brought in line with defined standard
   -> new routines packages_...F
   -> changes in initialise_fixed.F, initialise_varia.F
   -> enables initialisation interface for ECCO package
 o Rescaling of external forcing fields immediately after read
   (removed from external_forcing.F)
   -> new: surface_fields_scale.F
   -> affects ini_foorcing.F, external_fields_load.F
 o Computation of surface tendencies before tendency updates.
   -> new: external_forcing_surf.F
 o Change of variable names useGMRedi, useKPP, useECCO
 o Further changes in dynamics.F, impldiff.F for TAMC
 o Tested for experiments 0, 2, 4.
   - not yet tested for GMRedi.
   - not yet tested for KPP.

checkpoint30 (2000/07/13)
 o Updates for OBCs
 o New experiment for test OBCs (internal_wave)
 o New output.txt in verification/exp4/results/
 o Updates for KPP: calculation of viscosity corrected, new variables
   kpp_dumpFreq and kpp_taveFreq
 o CPP'd calls to system routines for TARGET_CRAY_VECTOR (P.H.)
   and entry for T90 in genmake

checkpoint29 (2000/06/21)
 o packaged KPP and GM/Redi

checkpoint28 (2000/06/09)
 o Corrected initialization of hFacMin for difference vertical coordinates
 o Modified calculation of partial cell thickness to more robust algorithm
 o config_summary.F: replaced write_1D_... by write_0D_...
   read_write.F: added subroutines write_0D_...
 o routines calc_common_factors, calc_gs, calc_gt, calc_phi_hyd, find_rho:
   included some initialisations required for TAMC.
 o routine calc_isoslopes: modified sqrt computation to make it
   differentiable for zero argument.
 o routines dynamics, impldiff:
   included store directives and tape key computations required for TAMC.
 o ALL TAMC related changes are between ifdef ALLOW_AUTODIFF_TAMC

checkpoint27 (2000/04/10)
 o fixed calc_isoslopes() to so that cancellation of terms in tensor
   formulation works properly with variable resolution.
 o restructured the calling tree between the_model_main() and dynamics()
 o split initialise() into initialise_fixed() and initialise_varia()
 o introduced initialization file pSurfInitFile for free surface (cg2d_x)
   in new routine ini_psurf()

checkpoint26 (2000/04/05)
 o moved some #ifdef in optional routines to encompass everything
   except the argument declarations. This was using up some memory.
 o fixed macros like _ADT to work with both versions of Linux cpp
 o cleaned up some unused and uninitialized variables
   (helps when debugging with strict compile options)
 o split up CPP_EEOPTIONS.h into options and macros
   (macros are now in eesupp/inc/CPP_EEMACROS.h)
 o patch for 2 processor JAM mode

checkpoint25 (2000/03/15)
 o updates for OBCs and NH
 o dramatically reduced memory usage
 o added "JAM" routines for use on Artic network
 o parameterization of convection by implicit vertical diffusion
 o added a diagnostic of convective index
 o moved call to calc_divg_hat() from dynamics() to solve_for_pressure()
   (this is was partly for OBCs and NH but also in anticipation of
    an explicit free-surface option)
 o initial state input files for U and V

checkpoint24 (1999/08/02)
 o Removed some spurious "REAL"s
 o Updated KPP to latest version from JPL
 o Added a COS(latitude) in horizontal viscosity

checkpoint23 (1999/05/26)
 o Added del^4 diffusion for salt and temperature
 o Multiple minor fixes (implicit none's, arguments to global_sum, etc.)

checkpoint22 (1999/05/18)
 o Made many small changes: implicit none, format(i5), etc...
 o Introduced KPP mixing scheme (compiles and runs but *not* tested)

checkpoint21 (1999/05/18)
 o Introduced new I/O package that supports direct-access records (mdsio.F)
 o Split-up mid-level I/O routines
 o Updated input data for experiments 0,1,2,4 and 5
 o Finally removed the genmake.* scripts (everyone seems happy with genmake)

checkpoint20 (1999/03/22)
 o Tidied up open-boundaries some more
 o Added non-hydrostatic code
 o Fixed some input data
 o Modified MPI start-up to work in "coupled" context.

checkpoint19 (1998/12/15)
 o Tidied up directory structure for verification experiments.
 o Added new code for open boundaries.
 o Corrected advective terms near boundaries.
 o Added CPP flag for "old UV" geometry and corrected spherical geometry.
 o Implemented free-slip/no-slip BCs and del^4 dissipation.
 o Split default parameters out of ini_parms.F into set_defaults.F.

checkpoint18 (1998/11/30)
 o Further changes for optional code generation with
   CPP - ugh!

checkpoint17 (1998/11/03)
 o Beginning to incorporating modularity
   for supporting atmos. and ocean configs.
 o Small changes for TAMC complinace
 o New ultra simple test case. Barotropic box
   configuration "exp0".

checkpoint16 (1998/10/28)
 o Minor changes to exchange routines to support
   accumulation in reverse mode. Adjoint of an
   assignment is an addition.
 o Changes to support compilation by TAMC (LR(1)
   syntax) and by g77 under Linux ( 72 character
   limit ).

checkpoint15 (1998/09/29)
 Rewrote exchange routines to allow
 o General tile <-> tile connectivity.
 o TAMC reverse mode flag ( is this really needed? )
 o Variable width overlap and exchange region widths.
 o Hooks for sharing data via DMA, Arctic, Memory Channel,
   shmput/shmget, VIA, SYSV shmem and every other cool
   communication method.

checkpoint14 (1998/09/09)
 Consistent isomorphism chages made. These allow dynamical core
 to support both pressure and meters as a vertical coordinate.

checkpoint13 (1998/07/17)
 Release which corrects global_max problem and a couple
 of KGM time-averaging diagnostic errors. Also contains
 a double-gyre experiment setup as well as the baseline
 4 degree global template. The double gyre template is
 organised to allow it to be applied automatically to
 the baseline configuration.

branch-point-rdot
 A few tidy-ups have been made bt the real point of this
 check-point (excuse the pun) is to allow a branch to be
 made for the purposes of adding the rDot alterations.
 I don't want to commit the rDot to the main-trunk until
 we've actually tested it...

checkpoint12 (1998/07/08)
 Tidy up and added generic genmake script (formerly
 configure script).
 Released to testers.

checkpoint11 (1998/07/02)
 Re-arranged initialise() and introduced ini_vertical_grid()
 and ini_masks_etc().

checkpoint10 (1998/07/01)
 Introduced the configure script.
 Separated out the diags package.
 Added template for writing time-averages of tile/intermediate quantities.
 Updated SIZE.h in exp2 and made the data big-endian.

checkpoint9 (1998/06/22)
 MPI fix. Filename changes (meta/data). salbin*y stuff.
 General tidy-up.
 SST.bin SSS.bin added to verification/exp2

checkpoint8 (1998/06/22)
 Inludes time-dependant forcing and time-averaging.
 Works at 4x4 and 2.8125x2.8125 global

checkpoint7-4degree-ref
 Branch from checkpoint7. Released for application to
 global modeling and general modeling - process studies, regional
 model etc..
 Configured for verification/exp2 - 4 degree global, two process.

checkpoint7 (1998/06/15)
 Created by cnh
 Simple 4 degree global simulation
 configuration.
 Includes climatological wind,
 hydrography, bathymetry etc
 Does not include Heat Flux and E-P

checkpoint6 (1998/06/08)
 Created by cnh
 merged checkpoint5 with CD and
 spherical polar code.
 Still some problems with GM Redi
 abd full topography.

checkpoint5 (1998/06/08)
 Created by AJA
 contains updates to GM Redi
 and reordered timestepping loop
 for Implicit Diffusion.

checkpoint4 (1998/05/30)
 Created by cnh
 Contains memory saving macros ( _rdxc etc..) for when
 grid variations are limited.
 Contains polynomial coeffs for EOS and knudsen program
 for generation.

checkpoint3 (1998/05/26)
 Created by cnh
 Added extra flags for runtime options
 Added this file
 Added implicit free-surface
 Added pre-conditioner
 Put compare01 into repository ( compare01/... )
 Put data and eedata into repository ( verification/exp1 )

checkpoint2
 Created by AJA
 Added GM/Redi

checkpoint1
 Created by AJA
 Restructured kloop in dynamics.F
 Added non-linear EOS

baseline
 Original checked in code
