File indexing completed on 2023-09-21 05:10:49 UTC
view on githubraw file Latest commit 96b00645 on 2023-09-20 15:15:14 UTC
5ca83cd8f7 Dani*0001 #include "STREAMICE_OPTIONS.h"
0002
0003
0004
0005
0006 SUBROUTINE STREAMICE_DIAGNOSTICS_STATE( myTime, myIter, myThid )
0007
0008
887f427c62 Jean*0009
5ca83cd8f7 Dani*0010
0011
0012
0013
0014 IMPLICIT NONE
0015
0016
0017 #include "SIZE.h"
0018 #include "EEPARAMS.h"
0019 #include "PARAMS.h"
0020 #include "STREAMICE.h"
0021
217ff6d33b Jean*0022 _RL myTime
07e785229e dngo*0023 INTEGER myIter, myThid
5ca83cd8f7 Dani*0024
0025 #ifdef ALLOW_STREAMICE
0026 #ifdef ALLOW_DIAGNOSTICS
07e785229e dngo*0027 CHARACTER*(MAX_LEN_MBUF) msgBuf
5ca83cd8f7 Dani*0028
d3f5b776b7 Dani*0029 #ifdef ALLOW_OPENAD
07e785229e dngo*0030 INTEGER i, j, bi, bj
5ca83cd8f7 Dani*0031
d3f5b776b7 Dani*0032 _RL u_streamice_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
0033 _RL v_streamice_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
3bb5c1cc98 Dani*0034 _RL u_surf_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
0035 _RL v_surf_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
d3f5b776b7 Dani*0036 _RL h_streamice_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
0037 _RL area_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
0038 _RL float_frac_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
0039 _RL surf_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
96b006450c dngo*0040 _RL bdot_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
d3f5b776b7 Dani*0041 #ifdef STREAMICE_HYBRID_STRESS
0042 _RL streamice_taubx_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
0043 _RL streamice_tauby_diag(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
0044 #endif
0045 #ifdef ALLOW_STREAMICE_2DTRACER
0046 _RL trac2d_diag
0047 #endif
0048
0049 DO bj = myByLo(myThid), myByHi(myThid)
0050 DO bi = myBxLo(myThid), myBxHi(myThid)
0051 DO j=1-OLy,sNy+OLy
0052 DO i=1-OLx,sNx+OLx
0053 u_streamice_diag(i,j,bi,bj) = u_streamice(i,j,bi,bj)%v
0054 v_streamice_diag(i,j,bi,bj) = v_streamice(i,j,bi,bj)%v
0055 h_streamice_diag(i,j,bi,bj) = H_streamice(i,j,bi,bj)%v
0056 area_diag(i,j,bi,bj) = area_shelf_streamice(i,j,bi,bj)%v
96b006450c dngo*0057 #if (defined(STREAMICE_SMOOTH_FLOATATION2) || defined(STREAMICE_SMOOTH_FLOATATION))
07e785229e dngo*0058 float_frac_diag(i,j,bi,bj) =
d3f5b776b7 Dani*0059 & float_frac_streamice(i,j,bi,bj)%v
4a318c1888 Dani*0060 #endif
d3f5b776b7 Dani*0061 surf_diag(i,j,bi,bj) =
07e785229e dngo*0062 & surf_el_streamice(i,j,bi,bj)%v
96b006450c dngo*0063 bdot_diag(i,j,bi,bj) =
0064 & bdot_streamice(i,j,bi,bj)%v
d3f5b776b7 Dani*0065 #ifdef STREAMICE_HYBRID_STRESS
0066 streamice_taubx_diag(i,j,bi,bj) =
0067 $ streamice_taubx(i,j,bi,bj)%v
0068 streamice_tauby_diag(i,j,bi,bj) =
0069 $ streamice_tauby(i,j,bi,bj)%v
3bb5c1cc98 Dani*0070 u_surf_diag(i,j,bi,bj) = streamice_u_surf(i,j,bi,bj)%v
0071 v_surf_diag(i,j,bi,bj) = streamice_v_surf(i,j,bi,bj)%v
d3f5b776b7 Dani*0072 #endif
0073 #ifdef ALLOW_STREAMICE_2DTRACER
0074 trac2d_diag(i,j,bi,bj)=trac2d(i,j,bi,bj)%v
0075 #endif
887f427c62 Jean*0076
d3f5b776b7 Dani*0077 ENDDO
0078 ENDDO
0079 ENDDO
0080 ENDDO
0081
07e785229e dngo*0082 #endif /* ALLOW_OPENAD */
5ca83cd8f7 Dani*0083
0084 IF ( useDiagnostics ) THEN
0085 WRITE(msgBuf,'(A)') 'CALLING FILL DIAGNOSTICS'
0086 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
0087 & SQUEEZE_RIGHT , 1)
887f427c62 Jean*0088
d3f5b776b7 Dani*0089 #ifdef ALLOW_OPENAD
0090
0091 CALL DIAGNOSTICS_FILL(U_streamice_diag,'SI_Uvel ',
0092 & 0,1,0,1,1,myThid)
0093 CALL DIAGNOSTICS_FILL(V_streamice_diag,'SI_Vvel ',
0094 & 0,1,0,1,1,myThid)
0095 CALL DIAGNOSTICS_FILL(H_streamice_diag,'SI_Thick',
0096 & 0,1,0,1,1,myThid)
0097 CALL DIAGNOSTICS_FILL(area_diag,'SI_area ',
0098 & 0,1,0,1,1,myThid)
0099 CALL DIAGNOSTICS_FILL(surf_diag,'SI_selev',
0100 & 0,1,0,1,1,myThid)
96b006450c dngo*0101 CALL DIAGNOSTICS_FILL(bdot_diag,'BDOT_SI ',
0102 & 0,1,0,1,1,myThid)
d3f5b776b7 Dani*0103
0104 #else
0105
5ca83cd8f7 Dani*0106 CALL DIAGNOSTICS_FILL(U_streamice,'SI_Uvel ',
0107 & 0,1,0,1,1,myThid)
0108 CALL DIAGNOSTICS_FILL(V_streamice,'SI_Vvel ',
0109 & 0,1,0,1,1,myThid)
0110 CALL DIAGNOSTICS_FILL(H_streamice,'SI_Thick',
0111 & 0,1,0,1,1,myThid)
0112 CALL DIAGNOSTICS_FILL(area_shelf_streamice,'SI_area ',
0113 & 0,1,0,1,1,myThid)
0114 CALL DIAGNOSTICS_FILL(float_frac_streamice,'SI_float',
0115 & 0,1,0,1,1,myThid)
d3f5b776b7 Dani*0116 CALL DIAGNOSTICS_FILL(surf_el_streamice,'SI_selev',
0117 & 0,1,0,1,1,myThid)
07e785229e dngo*0118 CALL DIAGNOSTICS_FILL(bdot_streamice,'BDOT_SI ',
0119 & 0,1,0,1,1,myThid)
d3f5b776b7 Dani*0120
0121 #endif
0122
4a318c1888 Dani*0123 #ifdef ALLOW_OPENAD
96b006450c dngo*0124 #if (defined(STREAMICE_SMOOTH_FLOATATION2) || defined(STREAMICE_SMOOTH_FLOATATION))
4a318c1888 Dani*0125 CALL DIAGNOSTICS_FILL(float_frac_diag,'SI_float',
0126 & 0,1,0,1,1,myThid)
0127 #else
0128 CALL DIAGNOSTICS_FILL(float_frac_streamice,'SI_float',
0129 & 0,1,0,1,1,myThid)
0130 #endif
0131 #endif
0132
217ff6d33b Jean*0133 CALL DIAGNOSTICS_FILL_RS(STREAMICE_hmask,'SI_hmask',
5ca83cd8f7 Dani*0134 & 0,1,0,1,1,myThid)
0135 #ifdef STREAMICE_HYBRID_STRESS
7924606b84 Dani*0136 CALL DIAGNOSTICS_FILL(streamice_u_bed,'SI_ubase',
0137 & 0,1,0,1,1,myThid)
0138 CALL DIAGNOSTICS_FILL(STREAMICE_v_bed,'SI_vbase',
0139 & 0,1,0,1,1,myThid)
d3f5b776b7 Dani*0140
0141 #ifdef ALLOW_OPENAD
0142 CALL DIAGNOSTICS_FILL(streamice_taubx_diag,'SI_taubx',
0143 & 0,1,0,1,1,myThid)
0144 CALL DIAGNOSTICS_FILL(STREAMICE_tauby_diag,'SI_tauby',
0145 & 0,1,0,1,1,myThid)
3bb5c1cc98 Dani*0146 CALL DIAGNOSTICS_FILL(u_surf_diag,'SI_usurf',
0147 & 0,1,0,1,1,myThid)
0148 CALL DIAGNOSTICS_FILL(v_surf_diag,'SI_vsurf',
0149 & 0,1,0,1,1,myThid)
d3f5b776b7 Dani*0150 #else
7924606b84 Dani*0151 CALL DIAGNOSTICS_FILL(streamice_taubx,'SI_taubx',
0152 & 0,1,0,1,1,myThid)
0153 CALL DIAGNOSTICS_FILL(STREAMICE_tauby,'SI_tauby',
0154 & 0,1,0,1,1,myThid)
3bb5c1cc98 Dani*0155 CALL DIAGNOSTICS_FILL(streamice_u_surf,'SI_usurf',
0156 & 0,1,0,1,1,myThid)
0157 CALL DIAGNOSTICS_FILL(streamice_v_surf,'SI_vsurf',
0158 & 0,1,0,1,1,myThid)
5ca83cd8f7 Dani*0159 #endif
d3f5b776b7 Dani*0160
0161 #endif
0162
5ca83cd8f7 Dani*0163 #ifdef ALLOW_STREAMICE_2DTRACER
d3f5b776b7 Dani*0164 #ifdef ALLOW_OPENAD
0165 CALL DIAGNOSTICS_FILL(trac2d_diag,'SI2Dtrac',
0166 & 0,1,0,1,1,myThid)
0167 #else
5ca83cd8f7 Dani*0168 CALL DIAGNOSTICS_FILL(trac2d,'SI2Dtrac',
0169 & 0,1,0,1,1,myThid)
0170 #endif
d3f5b776b7 Dani*0171 #endif
0172
5ca83cd8f7 Dani*0173 ENDIF
0174
0175 #endif /* ALLOW_DIAGNOSTICS */
07e785229e dngo*0176 #endif /* ALLOW_STREAMICE */
5ca83cd8f7 Dani*0177 RETURN
0178 END