Back to home page

MITgcm

 
 

    


File indexing completed on 2022-03-25 05:10:01 UTC

view on githubraw file Latest commit 64811cb0 on 2022-03-25 02:40:24 UTC
0dc94a8572 Patr*0001 #include "MYPACKAGE_OPTIONS.h"
                0002 
3d0c17158b Ed H*0003 C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
64811cb024 Jean*0004 CBOP
3d0c17158b Ed H*0005 C !ROUTINE: MYPACKAGE_DIAGNOSTICS_INIT
                0006 
                0007 C !INTERFACE:
0dc94a8572 Patr*0008       SUBROUTINE MYPACKAGE_DIAGNOSTICS_INIT( myThid )
                0009 
3d0c17158b Ed H*0010 C     !DESCRIPTION:
                0011 C     Initialize list of all available diagnostics
                0012 
0dc94a8572 Patr*0013 C     !USES:
                0014       IMPLICIT NONE
64811cb024 Jean*0015 C     == Global variables ===
0dc94a8572 Patr*0016 #include "EEPARAMS.h"
74fccdfdb4 Jean*0017 #include "SIZE.h"
64811cb024 Jean*0018 #include "PARAMS.h"
74fccdfdb4 Jean*0019 #include "MYPACKAGE.h"
0dc94a8572 Patr*0020 
                0021 C     !INPUT/OUTPUT PARAMETERS:
                0022 C     myThid ::  my Thread Id number
                0023       INTEGER myThid
                0024 CEOP
                0025 
                0026 #ifdef ALLOW_DIAGNOSTICS
                0027 C     !LOCAL VARIABLES:
                0028 C     diagNum   :: diagnostics number in the (long) list of available diag.
74fccdfdb4 Jean*0029 C     diagMate  :: diag. mate number in the (long) list of available diag.
0dc94a8572 Patr*0030 C     diagName  :: local short name (8c) of a diagnostics
                0031 C     diagCode  :: local parser field with characteristics of the diagnostics
                0032 C              cf head of S/R DIAGNOSTICS_INIT_EARLY or DIAGNOSTICS_MAIN_INIT
                0033 C     diagUnits :: local string (16c): physical units of a diagnostic field
                0034 C     diagTitle :: local string (80c): description of field in diagnostic
                0035       INTEGER       diagNum
74fccdfdb4 Jean*0036       INTEGER       diagMate
0dc94a8572 Patr*0037       CHARACTER*8   diagName
                0038       CHARACTER*16  diagCode
                0039       CHARACTER*16  diagUnits
                0040       CHARACTER*(80) diagTitle
                0041 
                0042 C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
                0043 
64811cb024 Jean*0044       IF ( useDiagnostics ) THEN
0dc94a8572 Patr*0045 
5b141690f8 Jean*0046         diagName  = 'MYPaSta1'
                0047         diagTitle = 'Scalar state variable 1 for package MYPACKAGE'
0dc94a8572 Patr*0048         diagUnits = 'unit            '
5b141690f8 Jean*0049         diagCode  = 'SM      MR      '
74fccdfdb4 Jean*0050         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0051      I          diagName, diagCode, diagUnits, diagTitle, 0, myThid )
0dc94a8572 Patr*0052 
5b141690f8 Jean*0053         diagName  = 'MYPaSta2'
                0054         diagTitle = 'Scalar state variable 2 for package MYPACKAGE'
0dc94a8572 Patr*0055         diagUnits = 'unit            '
5b141690f8 Jean*0056         diagCode  = 'SM      MR      '
74fccdfdb4 Jean*0057         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0058      I          diagName, diagCode, diagUnits, diagTitle, 0, myThid )
0dc94a8572 Patr*0059 
5b141690f8 Jean*0060         diagName  = 'MYPaStaU'
                0061         diagTitle = 'uVel-type state variable for package MYPACKAGE'
0dc94a8572 Patr*0062         diagUnits = 'unit            '
74fccdfdb4 Jean*0063         diagCode  = 'UM      MR      '
                0064         diagMate  = diagNum + 2
                0065         IF ( myPa_StaV_Cgrid ) diagCode(2:2) = 'U'
                0066         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0067      I   diagName, diagCode, diagUnits, diagTitle, diagMate, myThid )
0dc94a8572 Patr*0068 
5b141690f8 Jean*0069         diagName  = 'MYPaStaV'
                0070         diagTitle = 'vVel-type state variable for package MYPACKAGE'
0dc94a8572 Patr*0071         diagUnits = 'unit            '
74fccdfdb4 Jean*0072         diagCode  = 'VM      MR      '
                0073         diagMate  = diagNum
                0074         IF ( myPa_StaV_Cgrid ) diagCode(2:2) = 'V'
                0075         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0076      I   diagName, diagCode, diagUnits, diagTitle, diagMate, myThid )
0dc94a8572 Patr*0077 
5b141690f8 Jean*0078         diagName  = 'MYPaSur1'
                0079         diagTitle = 'Surface field 1 for package MYPACKAGE'
0dc94a8572 Patr*0080         diagUnits = 'unit            '
5b141690f8 Jean*0081         diagCode  = 'SM      L1      '
74fccdfdb4 Jean*0082         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0083      I          diagName, diagCode, diagUnits, diagTitle, 0, myThid )
0dc94a8572 Patr*0084 
5b141690f8 Jean*0085         diagName  = 'MYPaSur2'
                0086         diagTitle = 'Surface field 2 for package MYPACKAGE'
0dc94a8572 Patr*0087         diagUnits = 'unit            '
5b141690f8 Jean*0088         diagCode  = 'SM      L1      '
74fccdfdb4 Jean*0089         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0090      I          diagName, diagCode, diagUnits, diagTitle, 0, myThid )
                0091 
                0092         diagName  = 'MYPadTdt'
                0093         diagTitle = ' Pot.Temp. tendency from package MYPACKAGE'
                0094         diagUnits = 'K/s             '
adb65eb180 Jean*0095         diagCode  = 'SMR     MR      '
74fccdfdb4 Jean*0096         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0097      I          diagName, diagCode, diagUnits, diagTitle, 0, myThid )
                0098 
                0099         diagName  = 'MYPadSdt'
                0100         diagTitle = ' Salinity  tendency from package MYPACKAGE'
ba0b047096 Mart*0101         diagUnits = 'g/kg/s          '
adb65eb180 Jean*0102         diagCode  = 'SMR     MR      '
74fccdfdb4 Jean*0103         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0104      I          diagName, diagCode, diagUnits, diagTitle, 0, myThid )
                0105 
                0106         diagName  = 'MYPadUdt'
                0107         diagTitle = 'u-Velocity tendency from package MYPACKAGE'
                0108         diagUnits = 'm/s^2           '
adb65eb180 Jean*0109         diagCode  = 'UMR     MR      '
74fccdfdb4 Jean*0110         diagMate  = diagNum + 2
                0111         IF ( myPa_Tend_Cgrid ) diagCode(2:2) = 'U'
                0112         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0113      I   diagName, diagCode, diagUnits, diagTitle, diagMate, myThid )
                0114 
                0115         diagName  = 'MYPadVdt'
                0116         diagTitle = 'v-Velocity tendency from package MYPACKAGE'
                0117         diagUnits = 'm/s^2           '
adb65eb180 Jean*0118         diagCode  = 'VMR     MR      '
74fccdfdb4 Jean*0119         diagMate  = diagNum
                0120         IF ( myPa_Tend_Cgrid ) diagCode(2:2) = 'V'
                0121         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0122      I   diagName, diagCode, diagUnits, diagTitle, diagMate, myThid )
0dc94a8572 Patr*0123 
adb65eb180 Jean*0124 C--     an example of how to set "free levels option" diagnostics
                0125         diagName  = 'MYPaLev3'
                0126         diagTitle = '3-levels field for package MYPACKAGE'
                0127         diagUnits = 'unit            '
                0128         diagCode  = 'SM      MX      '
                0129         CALL DIAGNOSTICS_ADDTOLIST( diagNum,
                0130      I          diagName, diagCode, diagUnits, diagTitle, 0, myThid )
                0131         CALL DIAGNOSTICS_SETKLEV( diagName, 3, myThid )
                0132 
64811cb024 Jean*0133       ENDIF
0dc94a8572 Patr*0134 
                0135 #endif /* ALLOW_DIAGNOSTICS */
                0136 
                0137       RETURN
                0138       END