- Timestamp:
- Nov 5, 2018, 3:24:59 PM (7 years ago)
- Location:
- LMDZ6/branches/DYNAMICO-conv
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/branches/DYNAMICO-conv
- Property svn:mergeinfo changed
/LMDZ6/trunk removed
- Property svn:mergeinfo changed
-
LMDZ6/branches/DYNAMICO-conv/libf/phylmd/cosp/phys_cosp.F90
r3356 r3411 84 84 use cosp_output_write_mod 85 85 ! use MOD_COSP_Modis_Simulator, only : cosp_modis 86 #ifdef CPP_XIOS87 USE xios, ONLY: xios_field_is_active88 #endif89 use cosp_read_otputkeys90 86 91 87 IMPLICIT NONE … … 140 136 !$OMP THREADPRIVATE(debut_cosp) 141 137 142 logical, save :: first_write=.true.143 !$OMP THREADPRIVATE(first_write)144 145 138 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Input variables from LMDZ-GCM 146 139 integer :: overlaplmdz ! overlap type: 1=max, 2=rand, 3=max/rand ! cosp input (output lmdz) … … 154 147 real :: dtime,freq_cosp 155 148 real,dimension(2) :: time_bnds 156 157 double precision :: d_dtime158 double precision,dimension(2) :: d_time_bnds159 149 160 real,dimension(2,SR_BINS) :: sratio_bounds161 real,dimension(SR_BINS) :: sratio_ax162 163 150 namelist/COSP_INPUT/overlap,isccp_topheight,isccp_topheight_direction, & 164 151 npoints_it,ncolumns,use_vgrid,nlr,csat_vgrid, & … … 170 157 171 158 !---------------- End of declaration of variables -------------- 159 172 160 173 161 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ … … 182 170 CALL read_cosp_input 183 171 184 ! Clefs Outputs initialisation 185 call cosp_outputkeys_init(cfg) 186 !!! call cosp_outputkeys_test(cfg) 187 print*,' Cles des differents simulateurs cosp a itap :',itap 188 print*,'Lradar_sim,Llidar_sim,Lisccp_sim,Lmisr_sim,Lmodis_sim,Lrttov_sim,Lstats', & 189 cfg%Lradar_sim,cfg%Llidar_sim,cfg%Lisccp_sim,cfg%Lmisr_sim,cfg%Lmodis_sim, & 190 cfg%Lrttov_sim,cfg%Lstats 172 ! Clefs Outputs 173 call read_cosp_output_nl(cosp_output_nl,cfg) 191 174 192 175 if (overlaplmdz.ne.overlap) then … … 195 178 print*,'Fin lecture Namelists, debut_cosp =',debut_cosp 196 179 180 print*,' Cles des differents simulateurs cosp :' 181 print*,'Lradar_sim,Llidar_sim,Lisccp_sim,Lmisr_sim,Lmodis_sim,Lrttov_sim', & 182 cfg%Lradar_sim,cfg%Llidar_sim,cfg%Lisccp_sim,cfg%Lmisr_sim,cfg%Lmodis_sim,cfg%Lrttov_sim 183 197 184 endif ! debut_cosp 198 199 !!! Ici on modifie les cles logiques pour les outputs selon les champs actives dans les .xml200 if ((itap.gt.1).and.(first_write))then201 #ifdef CPP_XIOS202 call read_xiosfieldactive(cfg)203 #else204 call read_cosp_output_nl(itap,cosp_output_nl,cfg)205 #endif206 first_write=.false.207 208 print*,' Cles des differents simulateurs cosp a itap :',itap209 print*,'Lradar_sim,Llidar_sim,Lisccp_sim,Lmisr_sim,Lmodis_sim,Lrttov_sim,Lstats', &210 cfg%Lradar_sim,cfg%Llidar_sim,cfg%Lisccp_sim,cfg%Lmisr_sim,cfg%Lmodis_sim, &211 cfg%Lrttov_sim,cfg%Lstats212 endif213 185 214 186 time_bnds(1) = dtime-dtime/2. 215 187 time_bnds(2) = dtime+dtime/2. 216 188 217 d_time_bnds=time_bnds 218 d_dtime=dtime 219 189 ! print*,'Debut phys_cosp itap,dtime,freq_cosp,ecrit_mth,ecrit_day,ecrit_hf ', & 190 ! itap,dtime,freq_cosp,ecrit_mth,ecrit_day,ecrit_hf 220 191 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 221 192 ! Allocate memory for gridbox type … … 224 195 ! print *, 'Allocating memory for gridbox type...' 225 196 197 !! AI 198 ! call construct_cosp_gridbox(dble(itap),radar_freq,surface_radar,use_mie_tables,use_gas_abs,do_ray,melt_lay,k2, & 199 ! Npoints,Nlevels,Ncolumns,N_HYDRO,Nprmts_max_hydro,Naero,Nprmts_max_aero,Npoints_it, & 200 ! lidar_ice_type,isccp_topheight,isccp_topheight_direction,overlap,emsfc_lw, & 201 ! use_precipitation_fluxes,use_reff, & 202 ! Platform,Satellite,Instrument,Nchannels,ZenAng, & 203 ! channels(1:Nchannels),surfem(1:Nchannels),co2,ch4,n2o,co,gbx) 226 204 ! Surafce emissivity 227 205 emsfc_lw = 1. 228 206 229 call construct_cosp_gridbox(d _dtime,d_time_bnds,radar_freq,surface_radar,use_mie_tables,use_gas_abs, &207 call construct_cosp_gridbox(dtime,time_bnds,radar_freq,surface_radar,use_mie_tables,use_gas_abs, & 230 208 do_ray,melt_lay,k2, & 231 209 Npoints,Nlevels,Ncolumns,N_HYDRO,Nprmts_max_hydro,Naero,Nprmts_max_aero,Npoints_it, & … … 343 321 344 322 !+++++++++++++ Open output files and define output files axis !+++++++++++++ 345 !if (debut_cosp) then323 if (debut_cosp) then 346 324 347 325 !$OMP MASTER 348 !print *, ' Open outpts files and define axis'326 print *, ' Open outpts files and define axis' 349 327 call cosp_output_open(Nlevlmdz, Ncolumns, presnivs, dtime, freq_cosp, & 350 328 ok_mensuelCOSP, ok_journeCOSP, ok_hfCOSP, ok_all_xml, & … … 353 331 !$OMP BARRIER 354 332 debut_cosp=.false. 355 ! endif ! debut_cosp 356 ! else 333 endif ! debut_cosp 357 334 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 358 335 ! Call simulator … … 367 344 !#endif 368 345 !! 346 369 347 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 370 348 … … 375 353 cfg, gbx, vgrid, sglidar, sgradar, stlidar, stradar, & 376 354 isccp, misr, modis) 377 ! endif !debut_cosp 355 378 356 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 379 357 ! Deallocate memory in derived types 380 358 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 381 print *, 'Deallocating memory...'359 ! print *, 'Deallocating memory...' 382 360 call free_cosp_gridbox(gbx) 383 361 call free_cosp_subgrid(sgx)
Note: See TracChangeset
for help on using the changeset viewer.