1 | ! |
---|
2 | ! $Header: /home/cvsroot/LMDZ4/libf/phylmd/write_histday.h,v 1.2 2004/06/01 09:27:10 lmdzadmin Exp $ |
---|
3 | ! |
---|
4 | IF (ok_journe) THEN |
---|
5 | c |
---|
6 | ndex2d = 0 |
---|
7 | ndex3d = 0 |
---|
8 | zx_tmp_2d = 0. |
---|
9 | zx_tmp_3d = 0. |
---|
10 | zx_tmp_fi2d=0. |
---|
11 | zx_tmp_fi3d=0. |
---|
12 | |
---|
13 | c |
---|
14 | zsto = dtime |
---|
15 | zout = dtime * REAL(ecrit_day) |
---|
16 | itau_w = itau_phy + itap |
---|
17 | |
---|
18 | c |
---|
19 | c------------------------------------------------------- |
---|
20 | IF(lev_histday.GE.1) THEN |
---|
21 | c |
---|
22 | ccccccccccccc 2D fields, basics |
---|
23 | c |
---|
24 | i = NINT(zout/zsto) |
---|
25 | CALL gr_fi_ecrit(1,klon,iim,jjmp1,pphis,zx_tmp_2d) |
---|
26 | CALL histwrite(nid_day,"phis",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
27 | C |
---|
28 | i = NINT(zout/zsto) |
---|
29 | CALL gr_fi_ecrit(1,klon,iim,jjmp1,airephy,zx_tmp_2d) |
---|
30 | CALL histwrite(nid_day,"aire",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
31 | c |
---|
32 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, ftsol,zx_tmp_2d) |
---|
33 | CALL histwrite(nid_day,"tsol",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
34 | c |
---|
35 | DO i = 1, klon |
---|
36 | zx_tmp_fi2d(i) = paprs(i,1) |
---|
37 | ENDDO |
---|
38 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, zx_tmp_fi2d,zx_tmp_2d) |
---|
39 | CALL histwrite(nid_day,"psol",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
40 | c |
---|
41 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, ue,zx_tmp_2d) |
---|
42 | CALL histwrite(nid_day,"ue",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
43 | c |
---|
44 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, ve,zx_tmp_2d) |
---|
45 | CALL histwrite(nid_day,"ve",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
46 | c |
---|
47 | ENDIF !lev_histday.GE.1 |
---|
48 | c |
---|
49 | c------------------------------------------------------- |
---|
50 | IF(lev_histday.GE.2) THEN |
---|
51 | c |
---|
52 | ccccccccccccc 3D fields, basics |
---|
53 | c |
---|
54 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, t_seri, zx_tmp_3d) |
---|
55 | CALL histwrite(nid_day,"temp",itau_w,zx_tmp_3d, |
---|
56 | . iim*jjmp1*klev,ndex3d) |
---|
57 | c |
---|
58 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, pplay, zx_tmp_3d) |
---|
59 | CALL histwrite(nid_day,"pres",itau_w,zx_tmp_3d, |
---|
60 | . iim*jjmp1*klev,ndex3d) |
---|
61 | c |
---|
62 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, zphi, zx_tmp_3d) |
---|
63 | CALL histwrite(nid_day,"geop",itau_w,zx_tmp_3d, |
---|
64 | . iim*jjmp1*klev,ndex3d) |
---|
65 | c |
---|
66 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, u_seri, zx_tmp_3d) |
---|
67 | CALL histwrite(nid_day,"vitu",itau_w,zx_tmp_3d, |
---|
68 | . iim*jjmp1*klev,ndex3d) |
---|
69 | c |
---|
70 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, v_seri, zx_tmp_3d) |
---|
71 | CALL histwrite(nid_day,"vitv",itau_w,zx_tmp_3d, |
---|
72 | . iim*jjmp1*klev,ndex3d) |
---|
73 | c |
---|
74 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, omega, zx_tmp_3d) |
---|
75 | CALL histwrite(nid_day,"vitw",itau_w,zx_tmp_3d, |
---|
76 | . iim*jjmp1*klev,ndex3d) |
---|
77 | c |
---|
78 | ENDIF !lev_histday.GE.2 |
---|
79 | c |
---|
80 | c------------------------------------------------------- |
---|
81 | IF(lev_histday.GE.3) THEN |
---|
82 | c |
---|
83 | cccccccccccccccccc Radiative transfer |
---|
84 | c |
---|
85 | c 2D |
---|
86 | c |
---|
87 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, topsw,zx_tmp_2d) |
---|
88 | CALL histwrite(nid_day,"tops",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
89 | c |
---|
90 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, toplw,zx_tmp_2d) |
---|
91 | CALL histwrite(nid_day,"topl",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
92 | c |
---|
93 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, solsw,zx_tmp_2d) |
---|
94 | CALL histwrite(nid_day,"sols",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
95 | c |
---|
96 | CALL gr_fi_ecrit(1, klon,iim,jjmp1, sollw,zx_tmp_2d) |
---|
97 | CALL histwrite(nid_day,"soll",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
98 | c |
---|
99 | c 3D |
---|
100 | c |
---|
101 | zx_tmp_fi3d(1:klon,1:klev)=swnet(1:klon,1:klev) |
---|
102 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1,zx_tmp_fi3d,zx_tmp_3d) |
---|
103 | CALL histwrite(nid_day,"SWnet",itau_w,zx_tmp_3d, |
---|
104 | . iim*jjmp1*klev,ndex3d) |
---|
105 | c |
---|
106 | zx_tmp_fi3d(1:klon,1:klev)=lwnet(1:klon,1:klev) |
---|
107 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1,zx_tmp_fi3d,zx_tmp_3d) |
---|
108 | CALL histwrite(nid_day,"LWnet",itau_w,zx_tmp_3d, |
---|
109 | . iim*jjmp1*klev,ndex3d) |
---|
110 | c |
---|
111 | ENDIF !lev_histday.GE.3 |
---|
112 | c |
---|
113 | c------------------------------------------------------- |
---|
114 | IF(lev_histday.GE.4) THEN |
---|
115 | c |
---|
116 | c en K/s |
---|
117 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_t_dyn, zx_tmp_3d) |
---|
118 | CALL histwrite(nid_day,"dtdyn",itau_w,zx_tmp_3d, |
---|
119 | . iim*jjmp1*klev,ndex3d) |
---|
120 | c |
---|
121 | c en K/s |
---|
122 | c CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_t, zx_tmp_3d) |
---|
123 | c CALL histwrite(nid_day,"dtphy",itau_w,zx_tmp_3d, |
---|
124 | c . iim*jjmp1*klev,ndex3d) |
---|
125 | c |
---|
126 | c en K/s |
---|
127 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1,d_t_vdf,zx_tmp_3d) |
---|
128 | CALL histwrite(nid_day,"dtvdf",itau_w,zx_tmp_3d, |
---|
129 | . iim*jjmp1*klev,ndex3d) |
---|
130 | c |
---|
131 | c en K/s |
---|
132 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1,d_t_ajs,zx_tmp_3d) |
---|
133 | CALL histwrite(nid_day,"dtajs",itau_w,zx_tmp_3d, |
---|
134 | . iim*jjmp1*klev,ndex3d) |
---|
135 | c |
---|
136 | c K/day ==> K/s |
---|
137 | zx_tmp_fi3d(1:klon,1:klev)=heat(1:klon,1:klev)/RDAY |
---|
138 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1,zx_tmp_fi3d,zx_tmp_3d) |
---|
139 | CALL histwrite(nid_day,"dtswr",itau_w,zx_tmp_3d, |
---|
140 | . iim*jjmp1*klev,ndex3d) |
---|
141 | c |
---|
142 | c K/day ==> K/s |
---|
143 | zx_tmp_fi3d(1:klon,1:klev)=-1.*cool(1:klon,1:klev)/RDAY |
---|
144 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1,zx_tmp_fi3d,zx_tmp_3d) |
---|
145 | CALL histwrite(nid_day,"dtlwr",itau_w,zx_tmp_3d, |
---|
146 | . iim*jjmp1*klev,ndex3d) |
---|
147 | c en K/s |
---|
148 | c zx_tmp_fi3d(1:klon,1:klev)=d_t_ec(1:klon,1:klev) |
---|
149 | c CALL gr_fi_ecrit(klev,klon,iim,jjmp1,zx_tmp_fi3d,zx_tmp_3d) |
---|
150 | c CALL histwrite(nid_day,"dtec",itau_w,zx_tmp_3d, |
---|
151 | c . iim*jjmp1*klev,ndex3d) |
---|
152 | c |
---|
153 | c en (m/s)/s |
---|
154 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_u_dyn, zx_tmp_3d) |
---|
155 | CALL histwrite(nid_day,"dudyn",itau_w,zx_tmp_3d, |
---|
156 | . iim*jjmp1*klev,ndex3d) |
---|
157 | c |
---|
158 | c en (m/s)/s |
---|
159 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_u_vdf, zx_tmp_3d) |
---|
160 | CALL histwrite(nid_day,"duvdf",itau_w,zx_tmp_3d, |
---|
161 | . iim*jjmp1*klev,ndex3d) |
---|
162 | c |
---|
163 | c en (m/s)/s |
---|
164 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_u_ajs, zx_tmp_3d) |
---|
165 | CALL histwrite(nid_day,"duajs",itau_w,zx_tmp_3d, |
---|
166 | . iim*jjmp1*klev,ndex3d) |
---|
167 | c |
---|
168 | c en (m/s)/s |
---|
169 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_u_oro, zx_tmp_3d) |
---|
170 | CALL histwrite(nid_day,"dugwo",itau_w,zx_tmp_3d, |
---|
171 | . iim*jjmp1*klev,ndex3d) |
---|
172 | c |
---|
173 | c en (m/s)/s |
---|
174 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_u_hin, zx_tmp_3d) |
---|
175 | CALL histwrite(nid_day,"dugwno",itau_w,zx_tmp_3d, |
---|
176 | . iim*jjmp1*klev,ndex3d) |
---|
177 | c |
---|
178 | c en (m/s)/s |
---|
179 | c CALL gr_fi_ecrit(klev,klon,iim,jjmp1, d_v_vdf, zx_tmp_3d) |
---|
180 | c VENUS: regardee a l'envers!!!!!!!!!!!!!!! |
---|
181 | c zx_tmp_3d=-1.*zx_tmp_3d |
---|
182 | c CALL histwrite(nid_day,"dvvdf",itau_w,zx_tmp_3d, |
---|
183 | c . iim*jjmp1*klev,ndex3d) |
---|
184 | c |
---|
185 | ENDIF !lev_histday.GE.4 |
---|
186 | c |
---|
187 | c------------------------------------------------------- |
---|
188 | IF(lev_histday.GE.5) THEN |
---|
189 | c |
---|
190 | IF (nqmax.GE.3) THEN |
---|
191 | DO iq=1,nqmax-2 |
---|
192 | IF (iq.LE.99) THEN |
---|
193 | CALL gr_fi_ecrit(klev,klon,iim,jjmp1, qx(1,1,iq+2), zx_tmp_3d) |
---|
194 | WRITE(str2,'(i2.2)') iq |
---|
195 | CALL histwrite(nid_day,"trac"//str2,itau_w,zx_tmp_3d, |
---|
196 | . iim*jjmp1*klev,ndex3d) |
---|
197 | ELSE |
---|
198 | PRINT*, "Trop de traceurs" |
---|
199 | CALL abort |
---|
200 | ENDIF |
---|
201 | ENDDO |
---|
202 | ENDIF |
---|
203 | c |
---|
204 | c CALL gr_fi_ecrit(1, klon,iim,jjmp1, fluxu , zx_tmp_2d) |
---|
205 | c CALL histwrite(nid_day,"taux_",itau_w, |
---|
206 | c $ zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
207 | c |
---|
208 | c CALL gr_fi_ecrit(1, klon,iim,jjmp1, fluxv , zx_tmp_2d) |
---|
209 | c CALL histwrite(nid_day,"tauy_",itau_w, |
---|
210 | c $ zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
211 | c |
---|
212 | c CALL gr_fi_ecrit(1, klon,iim,jjmp1, cdragm,zx_tmp_2d) |
---|
213 | c CALL histwrite(nid_day,"cdrm",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
214 | c |
---|
215 | c CALL gr_fi_ecrit(1, klon,iim,jjmp1, cdragh,zx_tmp_2d) |
---|
216 | c CALL histwrite(nid_day,"cdrh",itau_w,zx_tmp_2d,iim*jjmp1,ndex2d) |
---|
217 | c |
---|
218 | ENDIF !lev_histday.GE.5 |
---|
219 | c------------------------------------------------------- |
---|
220 | c |
---|
221 | if (ok_sync) then |
---|
222 | call histsync(nid_day) |
---|
223 | endif |
---|
224 | |
---|
225 | ENDIF |
---|