[1262] | 1 | ! Ecriture des fichiers de sorties COSP |
---|
| 2 | ! Sorties journalierres |
---|
| 3 | ! Abderrahmane Idelkadi Septembre 2009 |
---|
| 4 | |
---|
| 5 | IF (MOD(itap,NINT(freq_COSP/dtime)).EQ.0) THEN |
---|
| 6 | |
---|
| 7 | itau_wcosp = itau_phy + itap |
---|
| 8 | |
---|
| 9 | ! Sorties LIDAR |
---|
| 10 | if (cfg%Llidar_sim) then |
---|
| 11 | if (cfg%Lcllcalipso) then |
---|
[1535] | 12 | CALL histwrite_phy(nid_day_cosp,lCOSP,"cllcalipso", & |
---|
| 13 | itau_wcosp,stlidar%cldlayer(:,1)) |
---|
[1262] | 14 | endif |
---|
| 15 | if (cfg%Lclhcalipso) then |
---|
[1535] | 16 | CALL histwrite_phy(nid_day_cosp,lCOSP,"clhcalipso", & |
---|
| 17 | itau_wcosp,stlidar%cldlayer(:,3)) |
---|
[1262] | 18 | endif |
---|
| 19 | if (cfg%Lclmcalipso) then |
---|
[1535] | 20 | CALL histwrite_phy(nid_day_cosp,lCOSP,"clmcalipso", & |
---|
| 21 | itau_wcosp,stlidar%cldlayer(:,2)) |
---|
[1262] | 22 | endif |
---|
| 23 | if (cfg%Lcltcalipso) then |
---|
[1535] | 24 | CALL histwrite_phy(nid_day_cosp,lCOSP,"cltcalipso", & |
---|
| 25 | itau_wcosp,stlidar%cldlayer(:,4)) |
---|
[1262] | 26 | endif |
---|
| 27 | if (cfg%Lclcalipso) then |
---|
[1535] | 28 | CALL histwrite_phy(nid_day_cosp,lCOSP,"clcalipso", & |
---|
| 29 | itau_wcosp,stlidar%lidarcld) |
---|
[1262] | 30 | endif |
---|
| 31 | if (cfg%Lcfad_lidarsr532) then |
---|
| 32 | do ii=1,SR_BINS |
---|
[1535] | 33 | CALL histwrite_phy(nid_day_cosp,lCOSP, & |
---|
| 34 | "cfad_lidarsr532_"//chcol(ii),itau_wcosp,stlidar%cfad_sr(:,ii,:)) |
---|
[1262] | 35 | enddo |
---|
| 36 | endif |
---|
| 37 | if (cfg%Lparasol_refl) then |
---|
[1535] | 38 | CALL histwrite_phy(nid_day_cosp,lCOSP,"parasol_refl", & |
---|
| 39 | itau_wcosp,stlidar%parasolrefl) |
---|
[1928] | 40 | CALL histwrite_phy(nid_day_cosp,lCOSP,"parasol_crefl", & |
---|
| 41 | itau_wcosp,parasolcrefl) |
---|
| 42 | CALL histwrite_phy(nid_day_cosp,lCOSP,"Ncrefl", & |
---|
| 43 | itau_wcosp,Ncref) |
---|
[1262] | 44 | endif |
---|
| 45 | if (cfg%Latb532) then |
---|
| 46 | do ii=1,Ncolumns |
---|
[1535] | 47 | CALL histwrite_phy(nid_day_cosp,lCOSP,"atb532_"//chcol(ii), & |
---|
| 48 | itau_wcosp,sglidar%beta_tot(:,ii,:)) |
---|
[1262] | 49 | enddo |
---|
| 50 | endif |
---|
| 51 | if (cfg%Lbeta_mol532) then |
---|
[1535] | 52 | CALL histwrite_phy(nid_day_cosp,lCOSP,"beta_mol532", & |
---|
| 53 | itau_wcosp,sglidar%beta_mol) |
---|
[1262] | 54 | endif |
---|
| 55 | endif ! Lidar |
---|
| 56 | |
---|
| 57 | ! Sorties RADAR |
---|
| 58 | !Attention A FAIRE |
---|
| 59 | ! if (cfg%Lradar_sim) then |
---|
| 60 | ! print*,'Ecriture sorties Radar' |
---|
| 61 | ! if (cfg%Lcfad_dbze94) then |
---|
| 62 | ! print*,'Ecriture de cfad_dbze94.nc ' |
---|
| 63 | ! A revoir l axe vertical Nlvgrid |
---|
| 64 | ! do ii=1,DBZE_BINS |
---|
| 65 | ! dbze_ax(ii) = CFAD_ZE_MIN + CFAD_ZE_WIDTH*(ii - 0.5) |
---|
| 66 | ! enddo |
---|
| 67 | ! call write_netcdf4d('cfad_dbze94.nc',use_vgrid,nlon,nlat,Nlevout,DBZE_BINS, & |
---|
| 68 | ! x,y,out_levs,dbze_ax,i,ndays,time,stradar%cfad_ze) |
---|
| 69 | ! endif |
---|
| 70 | ! if (cfg%Lclcalipso2) then |
---|
| 71 | ! call write_netcdf3d('clcalipso2.nc',use_vgrid,'clcalipso2', & |
---|
| 72 | ! nlon,nlat,Nlevout,x,y,out_levs,i,ndays,time,stradar%lidar_only_freq_cloud) |
---|
| 73 | ! endif |
---|
| 74 | ! if (cfg%Ldbze94) then |
---|
| 75 | ! do ii=1,Ncolumns |
---|
| 76 | ! xcol(ii)=float(i) |
---|
| 77 | ! enddo |
---|
| 78 | ! call write_netcdf4d('dbze94.nc',use_vgrid,nlon,nlat,Nlevout,Ncolumns, & |
---|
| 79 | ! x,y,out_levs,xcol,i,ndays,time,sgradar%Ze_tot) |
---|
| 80 | ! endif |
---|
| 81 | ! if (cfg%Lcltlidarradar) then |
---|
| 82 | ! call write_netcdf2d('cltlidarradar.nc','cltlidarradar', & |
---|
| 83 | ! nlon,nlat,x,y,i,ndays,time,stradar%radar_lidar_tcc) |
---|
| 84 | ! endif |
---|
| 85 | ! endif ! Radar |
---|
| 86 | |
---|
| 87 | ! Sorties MISR |
---|
| 88 | !Attention A FAIRE |
---|
| 89 | ! if (cfg%Lmisr_sim) then |
---|
| 90 | ! print*,'Ecriture sorties Misr' |
---|
| 91 | ! call write_netcdf4d('clMISR.nc',use_vgrid,nlon,nlat,MISR_N_CTH,7, & |
---|
| 92 | ! x,y,MISR_CTH,ISCCP_TAU,i,ndays,time,misr%fq_MISR) |
---|
| 93 | ! endif |
---|
| 94 | |
---|
| 95 | ! Sorties ISCCP |
---|
| 96 | if (cfg%Lisccp_sim) then |
---|
[1928] | 97 | CALL histwrite_phy(nid_day_cosp,lCOSP,"sunlit", & |
---|
| 98 | itau_wcosp,sunlit) |
---|
[1262] | 99 | if (cfg%Lclisccp2) then |
---|
| 100 | do ii=1,7 |
---|
[1535] | 101 | CALL histwrite_phy(nid_day_cosp,lCOSP, & |
---|
| 102 | "clisccp2_"//chcol(ii),itau_wcosp,isccp%fq_isccp(:,ii,:)) |
---|
[1262] | 103 | enddo |
---|
| 104 | endif |
---|
| 105 | if (cfg%Lboxtauisccp) then |
---|
[1535] | 106 | CALL histwrite_phy(nid_day_cosp,lCOSP,"boxtauisccp", & |
---|
| 107 | itau_wcosp,isccp%boxtau) |
---|
[1262] | 108 | endif |
---|
| 109 | if (cfg%Lboxptopisccp) then |
---|
[1535] | 110 | CALL histwrite_phy(nid_day_cosp,lCOSP,"boxptopisccp", & |
---|
| 111 | itau_wcosp,isccp%boxptop) |
---|
[1262] | 112 | endif |
---|
| 113 | if (cfg%Ltclisccp) then |
---|
[1535] | 114 | CALL histwrite_phy(nid_day_cosp,lCOSP,"tclisccp", & |
---|
| 115 | itau_wcosp,isccp%totalcldarea) |
---|
[1262] | 116 | endif |
---|
| 117 | if (cfg%Lctpisccp) then |
---|
[1535] | 118 | CALL histwrite_phy(nid_day_cosp,lCOSP,"ctpisccp", & |
---|
| 119 | itau_wcosp,isccp%meanptop) |
---|
[1262] | 120 | endif |
---|
| 121 | if (cfg%Ltauisccp) then |
---|
[1535] | 122 | CALL histwrite_phy(nid_day_cosp,lCOSP,"tauisccp", & |
---|
| 123 | itau_wcosp,isccp%meantaucld) |
---|
[1262] | 124 | endif |
---|
| 125 | if (cfg%Lalbisccp) then |
---|
[1535] | 126 | CALL histwrite_phy(nid_day_cosp,lCOSP,"albisccp", & |
---|
| 127 | itau_wcosp,isccp%meanalbedocld) |
---|
[1262] | 128 | endif |
---|
| 129 | if (cfg%Lmeantbisccp) then |
---|
[1535] | 130 | CALL histwrite_phy(nid_day_cosp,lCOSP,"meantbisccp", & |
---|
| 131 | itau_wcosp,isccp%meantb) |
---|
[1262] | 132 | endif |
---|
| 133 | if (cfg%Lmeantbclrisccp) then |
---|
[1535] | 134 | CALL histwrite_phy(nid_day_cosp,lCOSP,"meantbclrisccp", & |
---|
| 135 | itau_wcosp,isccp%meantbclr) |
---|
[1262] | 136 | endif |
---|
| 137 | endif ! Isccp |
---|
| 138 | |
---|
| 139 | ! if (ok_sync) then |
---|
| 140 | !$OMP MASTER |
---|
| 141 | call histsync(nid_day_cosp) |
---|
| 142 | !$OMP END MASTER |
---|
| 143 | ! endif |
---|
| 144 | |
---|
| 145 | ENDIF ! if freq_COSP |
---|