forked from altMITgcm/MITgcm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
AUTODIFF_PARAMS.h
76 lines (65 loc) · 3.43 KB
/
AUTODIFF_PARAMS.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
C $Header: /u/gcmpack/MITgcm/pkg/autodiff/AUTODIFF_PARAMS.h,v 1.9 2014/06/28 22:41:00 gforget Exp $
C $Name: $
CBOP
C !ROUTINE: AUTODIFF_PARAMS.h
C !INTERFACE:
C #include AUTODIFF_PARAMS.h
C !DESCRIPTION:
C Header file defining pkg/autodiff "parameters". The values
C from the pkg input file are stored into the variables held
C here. Notes describing the parameters can also be found here.
CEOP
C-- COMMON /AUTODIFF_PARM_L/ Logical valued parameters used by the pkg.
C inAdMode :: enable approximate computation in backward sweep
C inAdTrue :: value of inAdMode flag during backward sweep
C inAdFalse :: value of inAdMode flag during forward sweep
C inAdExact :: get an exact adjoint (no approximation)
LOGICAL inAdMode, inAdTrue, inAdFalse, inAdExact
C- Logical flags for turning off parts of the code in adjoint mode
C SEAICEuseFREEDRIFTswitchInAd :: switch on/off Free-Drift in adjoint mode (def=F)
C SEAICEuseDYNAMICSswitchInAd :: switch on/off seaice Dyn in adjoint mode (def=F)
LOGICAL useKPPinAdMode, useKPPinFwdMode
LOGICAL useGMRediInAdMode, useGMRediInFwdMode
LOGICAL useSEAICEinAdMode, useSEAICEinFwdMode
LOGICAL useGGL90inAdMode, useGGL90inFwdMode
LOGICAL useSALT_PLUMEinAdMode, useSALT_PLUMEInFwdMode
LOGICAL SEAICEuseFREEDRIFTswitchInAd, SEAICEuseFREEDRIFTinFwdMode
LOGICAL SEAICEuseDYNAMICSswitchInAd, SEAICEuseDYNAMICSinFwdMode
LOGICAL useSmoothCorrel2DinAdMode, useSmoothCorrel2DinFwdMode
C- Logical for ad dump format (if true then write all records
C to one file per variable; else write one file per record)
LOGICAL dumpAdByRec
COMMON /AUTODIFF_PARM_L/
& inAdMode, inAdTrue, inAdFalse, inAdExact,
& useKPPinAdMode, useKPPinFwdMode,
& useGMRediInAdMode, useGMRediInFwdMode,
& useSEAICEinAdMode, useSEAICEinFwdMode,
& useGGL90inAdMode, useGGL90inFwdMode,
& useSALT_PLUMEinAdMode, useSALT_PLUMEInFwdMode,
& SEAICEuseFREEDRIFTswitchInAd, SEAICEuseFREEDRIFTinFwdMode,
& SEAICEuseDYNAMICSswitchInAd, SEAICEuseDYNAMICSinFwdMode,
& useSmoothCorrel2DinAdMode, useSmoothCorrel2DinFwdMode,
& dumpAdByRec
C-- COMMON /AUTODIFF_PARM_I/ Integer valued parameters used by the pkg.
C dumpAdVarExch :: control ad-variables exchange before dumping output
C mon_AdVarExch :: control ad-variables exchange before monitor output
C - for both :: =0 : no exch ; =1 : apply adexch ;
C *AdVarExch - :: =2 : do adexch on a local copy.
C SEAICEapproxLevInAd :: level of approximation in seaice adjoint
C -1 (and .NOT.useSEAICEinAdMode) : use seaice_fake adjoint
C 0 (and .NOT.useSEAICEinAdMode) : omit all of seaice thermo adjoint
C 0 (and useSEAICEinAdMode) : use all of seaice thermo adjoint
C >= 1 (and useSEAICEinAdMode) : omit pieces of seaice thermo adjoint
INTEGER dumpAdVarExch
INTEGER mon_AdVarExch
INTEGER SEAICEapproxLevInAd
COMMON /AUTODIFF_PARM_I/
& dumpAdVarExch, mon_AdVarExch, SEAICEapproxLevInAd
C-- COMMON /AUTODIFF_PARM_R/ "Real" valued parameters used by the pkg.
C viscFacInAd :: viscosity factor for adjoint
_RL viscFacInAd
COMMON /AUTODIFF_PARM_R/ viscFacInAd
C-- COMMON /AUTODIFF_PARM_C/ Character valued parameters used by the pkg.
CEH3 ;;; Local Variables: ***
CEH3 ;;; mode:fortran ***
CEH3 ;;; End: ***