[868] | 1 | c |
---|
| 2 | c $Header$ |
---|
| 3 | c |
---|
| 4 | c on appelle le simulateur ISCCP toutes les 3h |
---|
| 5 | c et on fait des sorties 1 fois par jour |
---|
| 6 | c |
---|
| 7 | c ATTENTION : le temps de calcul peut augmenter considerablement ! |
---|
| 8 | c =============================================================== c |
---|
| 9 | DO n=1, napisccp |
---|
| 10 | c |
---|
| 11 | nbapp_isccp=30 !appel toutes les 15h |
---|
| 12 | cIM 170107 isccppas=NINT((itap*dtime)/3600.) !Nb. d'heures de la physique |
---|
| 13 | freqin_pdt(n)=ifreq_isccp(n) |
---|
| 14 | c |
---|
| 15 | cIM initialisation nbsunlit pour calculs simulateur ISCCP pdt la journee |
---|
| 16 | c |
---|
| 17 | DO i=1, klon |
---|
| 18 | sunlit(i)=1 |
---|
| 19 | IF(rmu0(i).EQ.0.) sunlit(i)=0 |
---|
| 20 | nbsunlit(1,i,n)=FLOAT(sunlit(i)) |
---|
| 21 | ENDDO |
---|
| 22 | c |
---|
| 23 | cIM calcul tau, emissivite nuages convectifs |
---|
| 24 | c |
---|
| 25 | convfra(:,:)=rnebcon(:,:) |
---|
| 26 | convliq(:,:)=rnebcon(:,:)*clwcon(:,:) |
---|
| 27 | c |
---|
| 28 | CALL newmicro (paprs, pplay,ok_newmicro, |
---|
| 29 | . t_seri, convliq, convfra, dtau_c, dem_c, |
---|
| 30 | . cldh_c, cldl_c, cldm_c, cldt_c, cldq_c, |
---|
| 31 | . flwp_c, fiwp_c, flwc_c, fiwc_c, |
---|
| 32 | e ok_aie, |
---|
| 33 | e sulfate, sulfate_pi, |
---|
| 34 | e bl95_b0, bl95_b1, |
---|
| 35 | s cldtaupi, re, fl) |
---|
| 36 | c |
---|
| 37 | cIM calcul tau, emissivite nuages startiformes |
---|
| 38 | c |
---|
| 39 | CALL newmicro (paprs, pplay,ok_newmicro, |
---|
| 40 | . t_seri, cldliq, cldfra, dtau_s, dem_s, |
---|
| 41 | . cldh_s, cldl_s, cldm_s, cldt_s, cldq_s, |
---|
| 42 | . flwp_s, fiwp_s, flwc_s, fiwc_s, |
---|
| 43 | e ok_aie, |
---|
| 44 | e sulfate, sulfate_pi, |
---|
| 45 | e bl95_b0, bl95_b1, |
---|
| 46 | s cldtaupi, re, fl) |
---|
| 47 | c |
---|
| 48 | cldtot(:,:)=min(max(cldfra(:,:),rnebcon(:,:)),1.) |
---|
| 49 | c |
---|
| 50 | cIM inversion des niveaux de pression ==> de haut en bas |
---|
| 51 | c |
---|
| 52 | CALL haut2bas(klon, klev, pplay, pfull) |
---|
| 53 | CALL haut2bas(klon, klev, q_seri, qv) |
---|
| 54 | CALL haut2bas(klon, klev, cldtot, cc) |
---|
| 55 | CALL haut2bas(klon, klev, rnebcon, conv) |
---|
| 56 | CALL haut2bas(klon, klev, dtau_s, dtau_sH2B) |
---|
| 57 | CALL haut2bas(klon, klev, dtau_c, dtau_cH2B) |
---|
| 58 | CALL haut2bas(klon, klev, t_seri, at) |
---|
| 59 | CALL haut2bas(klon, klev, dem_s, dem_sH2B) |
---|
| 60 | CALL haut2bas(klon, klev, dem_c, dem_cH2B) |
---|
| 61 | CALL haut2bas(klon, klevp1, paprs, phalf) |
---|
| 62 | c |
---|
| 63 | cIM lecture invtau, tautab des fichiers formattes |
---|
| 64 | c |
---|
| 65 | IF (debut) THEN |
---|
| 66 | c$OMP MASTER |
---|
| 67 | c open(99,file='tautab.bin',access='sequential', |
---|
| 68 | c $ form='unformatted',status='old') |
---|
| 69 | c read(99) tautab_omp |
---|
| 70 | c |
---|
| 71 | open(99,file='tautab.formatted', FORM='FORMATTED') |
---|
| 72 | read(99,'(f30.20)') tautab_omp |
---|
| 73 | close(99) |
---|
| 74 | c |
---|
| 75 | open(99,file='invtau.formatted',form='FORMATTED') |
---|
| 76 | read(99,'(i10)') invtau_omp |
---|
| 77 | close(99) |
---|
| 78 | c$OMP END MASTER |
---|
| 79 | c$OMP BARRIER |
---|
| 80 | tautab=tautab_omp |
---|
| 81 | invtau=invtau_omp |
---|
| 82 | c |
---|
| 83 | ENDIF !debut |
---|
| 84 | c |
---|
| 85 | cIM: initialisation de seed |
---|
| 86 | c |
---|
| 87 | DO i=1, klon |
---|
| 88 | c |
---|
| 89 | aa=ABS(paprs(i,2)-NINT(paprs(i,2))) |
---|
| 90 | seed_re(i,n)=1000.*aa+1. |
---|
| 91 | seed(i,n)=NINT(seed_re(i,n)) |
---|
| 92 | c |
---|
| 93 | IF(seed(i,n).LT.50) THEN |
---|
| 94 | c print*,'seed<50 avant i seed itap paprs',i, |
---|
| 95 | c . seed(i,n),itap,paprs(i,2) |
---|
| 96 | seed(i,n)=50+seed(i,n)+i+itap |
---|
| 97 | seed_old(i,n)=seed(i,n) |
---|
| 98 | c |
---|
| 99 | IF(itap.GT.1) then |
---|
| 100 | IF(seed(i,n).EQ.seed_old(i,n)) THEN |
---|
| 101 | seed(i,n)=seed(i,n)+10 |
---|
| 102 | seed_old(i,n)=seed(i,n) |
---|
| 103 | ENDIF |
---|
| 104 | ENDIF |
---|
| 105 | c |
---|
| 106 | c print*,'seed<50 apres i seed itap paprs',i, |
---|
| 107 | c . seed(i,n),itap,paprs(i,2) |
---|
| 108 | c |
---|
| 109 | ELSE IF(seed(i,n).EQ.0) THEN |
---|
| 110 | print*,'seed=0 i paprs aa seed_re', |
---|
| 111 | . i,paprs(i,2),aa,seed_re(i,n) |
---|
| 112 | STOP |
---|
| 113 | ELSE IF(seed(i,n).LT.0) THEN |
---|
| 114 | print*,'seed < 0, i seed itap paprs',i, |
---|
| 115 | . seed(i,n),itap,paprs(i,2) |
---|
| 116 | STOP |
---|
| 117 | ENDIF |
---|
| 118 | c |
---|
| 119 | ENDDO |
---|
| 120 | c |
---|
| 121 | cIM: pas de debug, debugcol |
---|
| 122 | debug=0 |
---|
| 123 | debugcol=0 |
---|
| 124 | c |
---|
| 125 | cIM o500 ==> distribution nuage ftion du regime dynamique (vit. verticale a 500 hPa) |
---|
| 126 | c |
---|
| 127 | DO k=1, klevm1 |
---|
| 128 | kp1=k+1 |
---|
| 129 | c PRINT*,'k, presnivs',k,presnivs(k), presnivs(kp1) |
---|
| 130 | if(presnivs(k).GT.50000.AND.presnivs(kp1).LT.50000.) THEN |
---|
| 131 | DO i=1, klon |
---|
| 132 | o500(i)=omega(i,k)*RDAY/100. |
---|
| 133 | c if(i.EQ.1) print*,' 500hPa lev',k,presnivs(k),presnivs(kp1) |
---|
| 134 | ENDDO |
---|
| 135 | GOTO 1000 |
---|
| 136 | endif |
---|
| 137 | 1000 continue |
---|
| 138 | ENDDO |
---|
| 139 | c |
---|
| 140 | cIM recalcule les nuages vus par satellite, via le simulateur ISCCP |
---|
| 141 | c |
---|
| 142 | CALL ISCCP_CLOUD_TYPES( |
---|
| 143 | & debug, |
---|
| 144 | & debugcol, |
---|
| 145 | & klon, |
---|
| 146 | & sunlit, |
---|
| 147 | & klev, |
---|
| 148 | & ncol(n), |
---|
| 149 | & seed(:,n), |
---|
| 150 | & pfull, |
---|
| 151 | & phalf, |
---|
| 152 | & qv, cc, conv, dtau_sH2B, dtau_cH2B, |
---|
| 153 | & top_height, |
---|
| 154 | & overlap, |
---|
| 155 | & tautab, |
---|
| 156 | & invtau, |
---|
| 157 | & ztsol, |
---|
| 158 | & emsfc_lw, |
---|
| 159 | & at, dem_sH2B, dem_cH2B, |
---|
| 160 | & fq_isccp(:,:,:,n), |
---|
| 161 | & totalcldarea(:,n), |
---|
| 162 | & meanptop(:,n), |
---|
| 163 | & meantaucld(:,n), |
---|
| 164 | & boxtau(:,:,n), |
---|
| 165 | & boxptop(:,:,n)) |
---|
| 166 | c |
---|
| 167 | ENDDO !n=1, napisccp |
---|
| 168 | |
---|