File indexing completed on 2018-03-02 18:37:21 UTC
view on githubraw file Latest commit add29e06 on 2018-01-31 20:35:05 UTC
cdcb187d4c Jean*0001 #include "AIM_OPTIONS.h"
65d8b97200 Jean*0002
0003
0004
cdcb187d4c Jean*0005
0006
0007
0008
0009 SUBROUTINE AIM_SICE_IMPL(
0010 I FMASK, netSW, sFlx,
e749d70ece Jean*0011 I Shf0, dShf, Evp0, dEvp, Slr0, dSlr,
0012 U Tsurf, SHF, EVAP, SLRU,
0013 O dTsurf,
cdcb187d4c Jean*0014 I bi, bj, myTime, myIter, myThid)
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024 IMPLICIT NONE
0025
0026
0027
65d8b97200 Jean*0028 #include "AIM_SIZE.h"
cdcb187d4c Jean*0029
0030 #include "EEPARAMS.h"
0031 #include "PARAMS.h"
0032
0033 #include "AIM_FFIELDS.h"
0034 #include "com_physcon.h"
0035
0036
0037 #ifdef ALLOW_THSICE
65d8b97200 Jean*0038
0039
0040
cdcb187d4c Jean*0041 #endif
0042
0043
0044
0045
0046
0047
0048
e749d70ece Jean*0049
0050
cdcb187d4c Jean*0051
0052
0053
0054
e749d70ece Jean*0055
cdcb187d4c Jean*0056
0057
e749d70ece Jean*0058
cdcb187d4c Jean*0059
0060
0061
0062
0063 _RL FMASK(NGP), netSW(NGP), sFlx(NGP,0:2)
e749d70ece Jean*0064 _RL Shf0(NGP), dShf(NGP), Evp0(NGP), dEvp(NGP)
0065 _RL Slr0(NGP), dSlr(NGP)
0066 _RL Tsurf(NGP), SHF(NGP), EVAP(NGP), SLRU(NGP)
0067 _RL dTsurf(NGP)
cdcb187d4c Jean*0068 INTEGER bi, bj, myIter, myThid
0069 _RL myTime
0070
0071
0072 #ifdef ALLOW_AIM
0073 #ifdef ALLOW_THSICE
0074
0075
0076 INTEGER J
0077
0078
0079
0080 IF ( useThSIce ) THEN
0081
0082 DO J=1,NGP
0083
65d8b97200 Jean*0084
cdcb187d4c Jean*0085
0086 dTsurf(J) = 0.
0087 ENDDO
0088
0089 CALL THSICE_IMPL_TEMP(
0090 I netSW, sFlx,
0091 O dTsurf,
0092 I bi, bj, myTime, myIter, myThid)
0093
0094
0095 DO J=1,NGP
0096 IF ( dTsurf(J) .GT. 999. ) THEN
e749d70ece Jean*0097 dTsurf(J)= tFreeze - Tsurf(J)
cdcb187d4c Jean*0098 Tsurf(J) = tFreeze
e749d70ece Jean*0099 SHF (J) = Shf0(J)
cdcb187d4c Jean*0100 EVAP(J) = Evp0(J)
0101 SLRU(J) = Slr0(J)
0102 ELSE
0103 Tsurf(J) = Tsurf(J)+ dTsurf(J)
e749d70ece Jean*0104 SHF (J) = SHF (J) + dTsurf(J)*dShf(J)
cdcb187d4c Jean*0105 EVAP(J) = EVAP(J) + dTsurf(J)*dEvp(J)
0106 SLRU(J) = SLRU(J) + dTsurf(J)*dSlr(J)
0107 ENDIF
0108 ENDDO
0109
0110 ENDIF
0111
0112 #endif /* ALLOW_THSICE */
0113 #endif /* ALLOW_AIM */
0114
0115 RETURN
0116 END