source: LMDZ4/trunk/libf/cosp/ini_histmthCOSP.h @ 1327

Last change on this file since 1327 was 1327, checked in by yann meurdesoif, 14 years ago

parallelisation COSP
YM

File size: 8.2 KB
Line 
1! Abderrahmane Idelkadi Septebmre 2009
2! Sorties journalieres de COSP
3! Pour l'instant sorties Lidar et ISCCP
4!
5! sorties par jour
6!
7!$OMP MASTER
8        zstomth = ecrit_mth
9        zout = freq_COSP
10!
11!       PRINT*, 'La frequence de sortie hf3d est de ', ecrit_hf
12!
13
14        idayref = day_ref
15        CALL ymds2ju(annee_ref, 1, idayref, 0.0, zjulian)
16
17        CALL histbeg_phy("histmthCOSP",itau_phy,zjulian,dtime,nhori,nid_mth_cosp) 
18
19! Definition de l'axe vertical
20        CALL histvert(nid_mth_cosp,"height","height","m",Nlevout,vgrid%z,nvert)
21        CALL histvert(nid_mth_cosp,"height_mlev","height_mlev","m",Nlevlmdz,vgrid%mz,nvertm)
22!        CALL histvert(nid_mth_cosp,"presnivs","Vertical levels","mb",Nlevout,presnivs,nvert)
23
24        CALL histvert(nid_mth_cosp,"sza","solar_zenith_angle","degrees",PARASOL_NREFL,PARASOL_SZA,nvertp)
25
26        CALL histvert(nid_mth_cosp,"pressure2","pressure","mb",7,ISCCP_PC,nvertisccp)
27
28        CALL histvert(nid_mth_cosp,"column","column","count",Ncolumns,column_ax,nvertcol)
29
30! Sorties LIDAR
31       if (cfg%Llidar_sim) then
32         if (cfg%Lcllcalipso) then
33         CALL histdef(nid_mth_cosp, "cllcalipso", &
34                     "Lidar Low-level Cloud Fraction", "1", &
35                     iim, jj_nb,nhori,1,1,1,-99,32, &
36                     "ave(X)", zout,zstomth)
37         endif
38         if (cfg%Lclhcalipso) then
39         CALL histdef(nid_mth_cosp, "clhcalipso", &
40                     "Lidar High-level Cloud Fraction", "1", &
41                     iim, jj_nb,nhori,1,1,1,-99,32, &
42                     "ave(X)", zout,zstomth)
43         endif
44         if (cfg%Lclmcalipso) then
45         CALL histdef(nid_mth_cosp, "clmcalipso", &
46                     "Lidar Mid-level Cloud Fraction", "1", &
47                     iim, jj_nb,nhori,1,1,1,-99,32, &
48                     "ave(X)", zout,zstomth)
49         endif
50         if (cfg%Lcltcalipso) then
51         CALL histdef(nid_mth_cosp, "cltcalipso", &
52                     "Lidar Total Cloud Fraction", "1", &
53                     iim, jj_nb,nhori,1,1,1,-99,32, &
54                     "ave(X)", zout,zstomth)
55         endif
56         if (cfg%Lclcalipso) then
57         CALL histdef(nid_mth_cosp, "clcalipso", &
58                     "Lidar Cloud Fraction (532 nm)", "1", &
59                     iim,jj_nb,nhori, Nlevout,1,Nlevout,nvert, 32, &
60                     "ave(X)", zout,zstomth)
61         endif
62           if (cfg%Lcfad_lidarsr532) then
63              do ii=1,SR_BINS
64               CALL histdef(nid_mth_cosp, "cfad_lidarsr532_"//chcol(ii), &
65                           "Lidar Scattering Ratio CFAD (532 nm)","1", &
66                           iim,jj_nb,nhori, Nlevout,1,Nlevout,nvert, 32, &
67                           "ave(X)", zout,zstomth)   
68              enddo
69           endif
70           if (cfg%Lparasol_refl) then
71            CALL histdef(nid_mth_cosp, "parasol_refl", &
72                        "PARASOL-like mono-directional reflectance","1", &
73                        iim,jj_nb,nhori, PARASOL_NREFL,1, PARASOL_NREFL, nvertp,32, &
74                        "ave(X)", zout,zstomth)   
75           endif
76           if (cfg%Latb532) then
77            do ii=1,Ncolumns
78             CALL histdef(nid_mth_cosp, "atb532_"//chcol(ii), &
79                         "Lidar Attenuated Total Backscatter (532 nm)","1", &
80                         iim,jj_nb,nhori, Nlevlmdz,1,Nlevlmdz,nvertm, 32, &
81                         "ave(X)", zout,zstomth)
82            enddo
83           endif
84           if (cfg%Lbeta_mol532) then
85            CALL histdef(nid_mth_cosp, "beta_mol532", &
86                        "Lidar Molecular Backscatter (532 nm)","m-1 sr-1", &
87                        iim,jj_nb,nhori, Nlevlmdz,1,Nlevlmdz,nvertm, 32, &
88                         "ave(X)", zout,zstomth)
89           endif
90        endif ! Lidar
91
92! Sorties RADAR
93!Attention A FAIRE
94!        if (cfg%Lradar_sim) then
95!         print*,'Ecriture sorties Radar'
96!          if (cfg%tttttttttttt) then
97!              print*,'Ecriture de cfad_dbze94.nc '
98!              A revoir l axe vertical Nlvgrid
99!               do ii=1,DBZE_BINS
100!                   dbze_ax(ii) = CFAD_ZE_MIN + CFAD_ZE_WIDTH*(ii - 0.5)
101!               enddo
102!               call write_netcdf4d('cfad_dbze94.nc',use_vgrid,nlon,nlat,Nlevout,DBZE_BINS, &
103!                                   x,y,out_levs,dbze_ax,i,ndays,time,stradar%cfad_ze)
104!          endif
105!          if (cfg%Lclcalipso2) then
106!               call write_netcdf3d('clcalipso2.nc',use_vgrid,'clcalipso2', &
107!                              nlon,nlat,Nlevout,x,y,out_levs,i,ndays,time,stradar%lidar_only_freq_cloud)
108!          endif
109!          if (cfg%Ldbze94) then
110!             do ii=1,Ncolumns
111!                xcol(ii)=float(i)
112!             enddo
113!             call write_netcdf4d('dbze94.nc',use_vgrid,nlon,nlat,Nlevout,Ncolumns, &
114!                                 x,y,out_levs,xcol,i,ndays,time,sgradar%Ze_tot)
115!          endif
116!          if (cfg%Lcltlidarradar) then
117!             call write_netcdf2d('cltlidarradar.nc','cltlidarradar', &
118!                                 nlon,nlat,x,y,i,ndays,time,stradar%radar_lidar_tcc)
119!          endif
120!        endif  ! Radar
121
122! Sorties MISR
123!Attention A FAIRE
124!        if (cfg%Lmisr_sim) then
125!         print*,'Ecriture sorties Misr'
126!            call write_netcdf4d('clMISR.nc',use_vgrid,nlon,nlat,MISR_N_CTH,7, &
127!                                x,y,MISR_CTH,ISCCP_TAU,i,ndays,time,misr%fq_MISR)
128!        endif
129
130! Sorties ISCCP
131        if (cfg%Lisccp_sim) then
132         if (cfg%Lclisccp2) then
133            do ii=1,7
134             CALL histdef(nid_mth_cosp, "clisccp2_"//chcol(ii), &
135                         "Cloud Fraction as Calculated by the ISCCP Simulator","1", &
136                         iim,jj_nb,nhori,7,1,7,nvertisccp, 32, &
137                         "ave(X)", zout,zstomth)
138            enddo
139          endif
140          if (cfg%Lboxtauisccp) then
141            CALL histdef(nid_mth_cosp, "boxtauisccp", &
142                         "Optical Depth in Each Column as Calculated by the ISCCP Simulator","1", &
143                         iim,jj_nb,nhori,Ncolumns,1,Ncolumns,nvertcol, 32, &
144                         "ave(X)", zout,zstomth)
145          endif
146          if (cfg%Lboxptopisccp) then
147            CALL histdef(nid_mth_cosp, "boxptopisccp", &
148                         "Cloud Top Pressure in Each Column as Calculated by the ISCCP Simulator","Pa", &
149                         iim,jj_nb,nhori,Ncolumns,1,Ncolumns,nvertcol, 32, &
150                         "ave(X)", zout,zstomth)
151          endif
152          if (cfg%Ltclisccp) then
153           CALL histdef(nid_mth_cosp, "tclisccp", &
154                     "Total Cloud Fraction as Calculated by the ISCCP Simulator", "1", &
155                     iim, jj_nb,nhori,1,1,1,-99,32, &
156                     "ave(X)", zout,zstomth)
157          endif
158          if (cfg%Lctpisccp) then
159            CALL histdef(nid_mth_cosp, "ctpisccp", &
160                     "Mean Cloud Top Pressure as Calculated by the ISCCP Simulator", "Pa", &
161                     iim, jj_nb,nhori,1,1,1,-99,32, &
162                     "ave(X)", zout,zstomth)
163          endif
164          if (cfg%Ltauisccp) then
165           CALL histdef(nid_mth_cosp, "tauisccp", &
166                     "Optical Depth as Calculated by the ISCCP Simulator", "1", &
167                     iim, jj_nb,nhori,1,1,1,-99,32, &
168                     "ave(X)", zout,zstomth)
169          endif
170          if (cfg%Lalbisccp) then
171           CALL histdef(nid_mth_cosp, "albisccp", &
172                     "Mean Cloud Albedo as Calculated by the ISCCP Simulator", "1", &
173                     iim, jj_nb,nhori,1,1,1,-99,32, &
174                     "ave(X)", zout,zstomth) 
175          endif
176          if (cfg%Lmeantbisccp) then
177            CALL histdef(nid_mth_cosp, "meantbisccp", &
178             " Mean all-sky 10.5 micron brightness temperature as calculated by the ISCCP Simulator","K", &
179             iim, jj_nb,nhori,1,1,1,-99,32, &
180             "ave(X)", zout,zstomth)
181          endif
182          if (cfg%Lmeantbclrisccp) then
183           CALL histdef(nid_mth_cosp, "meantbclrisccp", &
184            "Mean clear-sky 10.5 micron brightness temperature as calculated by the ISCCP Simulator","K", &
185             iim, jj_nb,nhori,1,1,1,-99,32, &
186             "ave(X)", zout,zstomth) 
187          endif
188        endif ! Isccp
189
190
191        CALL histend(nid_mth_cosp)
192!$OMP END MASTER
193!$OMP BARRIER
Note: See TracBrowser for help on using the repository browser.