[1591] | 1 | SUBROUTINE SW_venus_rh_1Dglobave(PRMU0, PFRAC, |
---|
| 2 | S PPB, pt, |
---|
| 3 | S PHEAT, |
---|
| 4 | S PTOPSW,PSOLSW,ZFSNET) |
---|
| 5 | |
---|
| 6 | use dimphy |
---|
[1621] | 7 | use cpdet_phy_mod, only: cpdet |
---|
[1591] | 8 | IMPLICIT none |
---|
| 9 | |
---|
| 10 | #include "YOMCST.h" |
---|
| 11 | C |
---|
| 12 | C ------------------------------------------------------------------ |
---|
| 13 | C |
---|
| 14 | C PURPOSE. |
---|
| 15 | C -------- |
---|
| 16 | C |
---|
| 17 | c this routine loads and interpolates the shortwave radiation |
---|
| 18 | c fluxes taken from Rainer Haus calculations for Venus. |
---|
| 19 | c Ref: Haus et al. 2016 |
---|
| 20 | C |
---|
| 21 | C AUTHOR. |
---|
| 22 | C ------- |
---|
| 23 | C Sebastien Lebonnois |
---|
| 24 | C |
---|
| 25 | C MODIFICATIONS. |
---|
| 26 | C -------------- |
---|
| 27 | C ORIGINAL : 5/2016 |
---|
| 28 | C ------------------------------------------------------------------ |
---|
| 29 | C |
---|
| 30 | C* ARGUMENTS: |
---|
| 31 | C |
---|
| 32 | c inputs |
---|
| 33 | |
---|
| 34 | REAL PRMU0 ! COSINE OF ZENITHAL ANGLE |
---|
| 35 | REAL PFRAC ! fraction de la journee |
---|
| 36 | REAL PPB(klev+1) ! inter-couches PRESSURE (bar) |
---|
| 37 | REAL pt(klev) ! mid-layer temperature |
---|
| 38 | C |
---|
| 39 | c output |
---|
| 40 | |
---|
| 41 | REAL PHEAT(klev) ! SHORTWAVE HEATING (K/s) within each layer |
---|
| 42 | REAL PTOPSW ! SHORTWAVE FLUX AT T.O.A. (net) |
---|
| 43 | REAL PSOLSW ! SHORTWAVE FLUX AT SURFACE (net) |
---|
| 44 | REAL ZFSNET(klev+1) ! net solar flux at ppb levels |
---|
| 45 | |
---|
| 46 | C |
---|
| 47 | C* LOCAL VARIABLES: |
---|
| 48 | C |
---|
| 49 | integer nlrh,nszarh,nlatrh |
---|
| 50 | parameter (nlrh=118) ! fichiers Rainer Haus |
---|
| 51 | parameter (nszarh=7) ! fichiers Rainer Haus |
---|
| 52 | parameter (nlatrh=19) ! fichiers Rainer Haus |
---|
| 53 | |
---|
| 54 | integer i,j,lat,nsza,nsza0,nl0 |
---|
| 55 | real zsnetmoy(nlrh+1,nlatrh) ! net solar flux (W/m**2) (+ vers bas) |
---|
| 56 | real presrh(nlrh+1) ! pressure in table (bar) |
---|
| 57 | real altrh(nlrh+1) ! altitude in table (km) |
---|
| 58 | real latrh(nlatrh) ! latitude in table (degrees) |
---|
| 59 | real zsolnet(nlrh+1) ! for mean net solar flux in RH |
---|
| 60 | character*22 nullchar |
---|
| 61 | real factflux |
---|
| 62 | real zsnet(nszarh) ! net solar flux (W/m**2) (+ vers bas) |
---|
| 63 | real deltalat |
---|
| 64 | logical firstcall |
---|
| 65 | data firstcall/.true./ |
---|
| 66 | save zsolnet,altrh,presrh |
---|
| 67 | save firstcall |
---|
| 68 | |
---|
| 69 | c ------------------------ |
---|
| 70 | c Loading the file |
---|
| 71 | c ------------------------ |
---|
| 72 | |
---|
| 73 | if (firstcall) then |
---|
| 74 | |
---|
| 75 | open(11,file='SolarNetFlux_RH.dat') |
---|
| 76 | |
---|
| 77 | do i=1,nlrh+1 |
---|
| 78 | read(11,'(E5.1,4x,F8.2)') altrh(i),presrh(i) |
---|
| 79 | enddo |
---|
| 80 | |
---|
| 81 | do lat=1,nlatrh |
---|
| 82 | latrh(lat)=5.*(lat-1) |
---|
| 83 | read(11,*) nullchar |
---|
| 84 | read(11,*) nullchar |
---|
| 85 | read(11,*) nullchar |
---|
| 86 | read(11,*) nullchar |
---|
| 87 | |
---|
| 88 | do i=1,nlrh+1 |
---|
| 89 | read(11,'(E6.1,7(2x,F11.5),7x,F11.5)') |
---|
| 90 | . altrh(i),zsnet,zsnetmoy(i,lat) |
---|
| 91 | enddo |
---|
| 92 | read(11,*) nullchar |
---|
| 93 | enddo |
---|
| 94 | latrh(nlatrh)=89. |
---|
| 95 | |
---|
| 96 | close(11) |
---|
| 97 | |
---|
| 98 | c ----------- TEST ------------ |
---|
| 99 | c Moyenne planetaire |
---|
| 100 | c ----------------------------- |
---|
| 101 | |
---|
| 102 | zsolnet=0. |
---|
| 103 | do lat=1,nlatrh-1 |
---|
| 104 | deltalat=(latrh(lat+1)-latrh(lat))*RPI/180. |
---|
| 105 | do j=1,nlrh+1 |
---|
| 106 | zsolnet(j) = zsolnet(j)+ |
---|
| 107 | . (zsnetmoy(j,lat+1)+zsnetmoy(j,lat))/2.* |
---|
| 108 | . deltalat*cos((latrh(lat+1)+latrh(lat))*RPI/360.) |
---|
| 109 | enddo |
---|
| 110 | enddo |
---|
| 111 | c ----------------------------- |
---|
| 112 | c -------- FIN TEST ---------- |
---|
| 113 | |
---|
| 114 | firstcall=.false. |
---|
| 115 | endif |
---|
| 116 | |
---|
| 117 | c -------------------------------------- |
---|
| 118 | c Interpolation in the GCM vertical grid |
---|
| 119 | c -------------------------------------- |
---|
| 120 | |
---|
| 121 | c Pressure levels |
---|
| 122 | c --------------- |
---|
| 123 | |
---|
| 124 | do j=1,klev+1 |
---|
| 125 | nl0 = nlrh |
---|
| 126 | do i=nlrh+1,2,-1 |
---|
| 127 | if (presrh(i).ge.PPB(j)) then |
---|
| 128 | nl0 = i-1 |
---|
| 129 | endif |
---|
| 130 | enddo |
---|
| 131 | |
---|
| 132 | factflux = (log10(max(PPB(j),presrh(1)))-log10(presrh(nl0+1))) |
---|
| 133 | . /(log10(presrh(nl0))-log10(presrh(nl0+1))) |
---|
| 134 | |
---|
| 135 | ZFSNET(j) = factflux *zsolnet(nl0) |
---|
| 136 | . + (1.-factflux)*zsolnet(nl0+1) |
---|
| 137 | |
---|
| 138 | c-----TEST------- |
---|
| 139 | c tayloring the solar flux... |
---|
| 140 | c if ((PPB(j).gt.0.236).and.(PPB(j).le.22.52)) then |
---|
| 141 | c ZFSNET(j) = ZFSNET(j)+2.5*(1.+cos((log10(PPB(j)/3.5)/ |
---|
| 142 | c . log10(0.236/3.5))*RPI)) |
---|
| 143 | c endif |
---|
| 144 | c---------------- |
---|
| 145 | enddo |
---|
| 146 | |
---|
| 147 | PTOPSW = ZFSNET(klev+1) |
---|
| 148 | PSOLSW = ZFSNET(1) |
---|
| 149 | |
---|
| 150 | c Heating rates |
---|
| 151 | c ------------- |
---|
| 152 | c On utilise le gradient du flux pour calculer le taux de chauffage: |
---|
| 153 | c heat(K/s) = d(fluxnet) (W/m2) |
---|
| 154 | c *g (m/s2) |
---|
| 155 | c /(-dp) (epaisseur couche, en Pa=kg/m/s2) |
---|
| 156 | c /cp (J/kg/K) |
---|
| 157 | |
---|
| 158 | do j=1,klev |
---|
| 159 | ! ADAPTATION GCM POUR CP(T) |
---|
| 160 | PHEAT(j) = (ZFSNET(j+1)-ZFSNET(j)) |
---|
| 161 | . *RG/cpdet(pt(j)) / ((PPB(j)-PPB(j+1))*1.e5) |
---|
| 162 | c-----TEST------- |
---|
| 163 | c tayloring the solar flux... |
---|
| 164 | if ((PPB(j).gt.1.4).and.(PPB(j).le.10.)) then |
---|
| 165 | PHEAT(j) = PHEAT(j)*3 |
---|
| 166 | c elseif ((PPB(j).gt.10.).and.(PPB(j).le.30.)) then |
---|
| 167 | c PHEAT(j) = PHEAT(j)*1.5 |
---|
| 168 | endif |
---|
| 169 | c---------------- |
---|
| 170 | c print*,PPB(j),ZFSNET(j),PHEAT(j) |
---|
| 171 | enddo |
---|
| 172 | c stop |
---|
| 173 | return |
---|
| 174 | end |
---|
| 175 | |
---|