Changeset 5088 for LMDZ6/branches/Amaury_dev/libf/phylmd/Dust
- Timestamp:
- Jul 20, 2024, 4:30:31 PM (6 months ago)
- Location:
- LMDZ6/branches/Amaury_dev/libf/phylmd/Dust
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/condsurfc.F
r5075 r5088 4 4 . lmt_omnat) 5 5 USE dimphy 6 USE lmdz_netcdf, ONLY: nf_close,nf_noerr,nf_inq_varid,nf_open,nf_nowrite,nf90_get_var6 USE netcdf, ONLY: nf90_close,nf90_noerr,nf90_inq_varid,nf90_open,nf90_nowrite,nf90_get_var 7 7 IMPLICIT none 8 8 ! … … 34 34 ENDIF 35 35 ! 36 ierr = NF_OPEN ("limitcarbon.nc", NF_NOWRITE, nid1)37 if (ierr/= NF_NOERR) then36 ierr = nf90_open ("limitcarbon.nc", nf90_nowrite, nid1) 37 if (ierr/=nf90_noerr) then 38 38 write(6,*)' Pb d''ouverture du fichier limitbc.nc' 39 39 write(6,*)' ierr = ', ierr … … 48 48 ! 49 49 ! 50 ierr = NF_INQ_VARID(nid1, "BCFF", nvarid)50 ierr = nf90_inq_varid (nid1, "BCFF", nvarid) 51 51 ierr = nf90_get_var(nid1, nvarid, lmt_bcff, debut, epais) 52 52 ! print *,'IERR = ',ierr 53 ! print *,' NF_NOERR = ',NF_NOERR53 ! print *,'nf90_noerr = ',nf90_noerr 54 54 ! print *,'debut = ',debut 55 55 ! print *,'epais = ',epais 56 IF (ierr /= NF_NOERR) THEN56 IF (ierr /= nf90_noerr) THEN 57 57 PRINT*, 'Pb de lecture pour les sources BC' 58 58 CALL exit(1) … … 60 60 ! 61 61 ! 62 ierr = NF_INQ_VARID(nid1, "BCBB", nvarid)62 ierr = nf90_inq_varid (nid1, "BCBB", nvarid) 63 63 ierr = nf90_get_var(nid1, nvarid, lmt_bcbb, debut, epais) 64 IF (ierr /= NF_NOERR) THEN64 IF (ierr /= nf90_noerr) THEN 65 65 PRINT*, 'Pb de lecture pour les sources BC-biomass' 66 66 CALL exit(1) … … 68 68 ! 69 69 ! 70 ierr = NF_INQ_VARID(nid1, "BCBL", nvarid)70 ierr = nf90_inq_varid (nid1, "BCBL", nvarid) 71 71 ierr = nf90_get_var(nid1, nvarid, lmt_bcbbl, debut, epais) 72 IF (ierr /= NF_NOERR) THEN72 IF (ierr /= nf90_noerr) THEN 73 73 PRINT*, 'Pb de lecture pour les sources BC low' 74 74 CALL exit(1) … … 76 76 ! 77 77 ! 78 ierr = NF_INQ_VARID(nid1, "BCBH", nvarid)78 ierr = nf90_inq_varid (nid1, "BCBH", nvarid) 79 79 ierr = nf90_get_var (nid1, nvarid, lmt_bcbbh, debut, epais) 80 IF (ierr /= NF_NOERR) THEN80 IF (ierr /= nf90_noerr) THEN 81 81 PRINT*, 'Pb de lecture pour les sources BC high' 82 82 CALL exit(1) 83 83 ENDIF 84 84 ! 85 ierr = NF_INQ_VARID(nid1, "TERP", nvarid)85 ierr = nf90_inq_varid (nid1, "TERP", nvarid) 86 86 ierr = nf90_get_var (nid1, nvarid, lmt_terp, debut, epais) 87 IF (ierr /= NF_NOERR) THEN87 IF (ierr /= nf90_noerr) THEN 88 88 PRINT*, 'Pb de lecture pour les sources Terpene' 89 89 CALL exit(1) … … 91 91 ! 92 92 ! 93 ierr = NF_INQ_VARID(nid1, "BC_penner", nvarid)93 ierr = nf90_inq_varid (nid1, "BC_penner", nvarid) 94 94 ierr = nf90_get_var (nid1, nvarid, lmt_bc_penner, debut, epais) 95 IF (ierr /= NF_NOERR) THEN95 IF (ierr /= nf90_noerr) THEN 96 96 PRINT*, 'Pb de lecture pour les sources BC Penner' 97 97 CALL exit(1) … … 99 99 ! 100 100 ! 101 ierr = NF_INQ_VARID(nid1, "OMFF", nvarid)101 ierr = nf90_inq_varid (nid1, "OMFF", nvarid) 102 102 ierr = nf90_get_var (nid1, nvarid, lmt_omff, debut, epais) 103 IF (ierr /= NF_NOERR) THEN103 IF (ierr /= nf90_noerr) THEN 104 104 PRINT*, 'Pb de lecture pour les sources om-ifossil' 105 105 CALL exit(1) … … 114 114 ENDDO 115 115 ! 116 ierr = NF_CLOSE(nid1)116 ierr = nf90_close(nid1) 117 117 PRINT*, 'Carbon sources lues pour jour: ', jour 118 118 ! -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/condsurfc_new.F
r5075 r5088 6 6 USE mod_phys_lmdz_para 7 7 USE dimphy 8 USE lmdz_netcdf, ONLY:nf90_get_var,nf_close,nf_noerr,nf_inq_varid,nf_open,nf_nowrite8 USE netcdf, ONLY:nf90_get_var,nf90_close,nf90_noerr,nf90_inq_varid,nf90_open,nf90_nowrite 9 9 IMPLICIT none 10 10 c … … 57 57 !======================================================================= 58 58 ! 59 ierr = NF_OPEN ("carbon_emissions.nc", NF_NOWRITE, nid1)60 if (ierr/= NF_NOERR) then59 ierr = nf90_open ("carbon_emissions.nc", nf90_nowrite, nid1) 60 if (ierr/=nf90_noerr) then 61 61 write(6,*)' Pb d''ouverture du fichier limitbc.nc' 62 62 write(6,*)' ierr = ', ierr … … 66 66 ! BC emissions from fossil fuel combustion 67 67 ! 68 ierr = NF_INQ_VARID(nid1, "BCFF", nvarid)68 ierr = nf90_inq_varid (nid1, "BCFF", nvarid) 69 69 ierr = nf90_get_var (nid1, nvarid, lmt_bcff_glo, debut, epais) 70 IF (ierr /= NF_NOERR) THEN70 IF (ierr /= nf90_noerr) THEN 71 71 PRINT*, 'Pb de lecture pour les sources BC' 72 72 CALL exit(1) … … 77 77 ! BC emissions from non fossil fuel combustion 78 78 ! 79 ierr = NF_INQ_VARID(nid1, "BCNFF", nvarid)79 ierr = nf90_inq_varid (nid1, "BCNFF", nvarid) 80 80 ierr = nf90_get_var (nid1, nvarid, lmt_bcnff_glo, debut, epais) 81 IF (ierr /= NF_NOERR) THEN81 IF (ierr /= nf90_noerr) THEN 82 82 PRINT*, 'Pb de lecture pour les sources BC' 83 83 CALL exit(1) … … 86 86 ! Low BC emissions from biomass burning 87 87 ! 88 ierr = NF_INQ_VARID(nid1, "BCBBL", nvarid)88 ierr = nf90_inq_varid (nid1, "BCBBL", nvarid) 89 89 ierr = nf90_get_var (nid1, nvarid, lmt_bcbbl_glo, debut, epais) 90 IF (ierr /= NF_NOERR) THEN90 IF (ierr /= nf90_noerr) THEN 91 91 PRINT*, 'Pb de lecture pour les sources BC low' 92 92 CALL exit(1) … … 95 95 ! High BC emissions from biomass burning 96 96 ! 97 ierr = NF_INQ_VARID(nid1, "BCBBH", nvarid)97 ierr = nf90_inq_varid (nid1, "BCBBH", nvarid) 98 98 ierr = nf90_get_var (nid1, nvarid, lmt_bcbbh_glo, debut, epais) 99 IF (ierr /= NF_NOERR) THEN99 IF (ierr /= nf90_noerr) THEN 100 100 PRINT*, 'Pb de lecture pour les sources BC high' 101 101 CALL exit(1) … … 104 104 ! BC emissions from ship transport 105 105 ! 106 ierr = NF_INQ_VARID(nid1, "BCBA", nvarid)106 ierr = nf90_inq_varid (nid1, "BCBA", nvarid) 107 107 ierr = nf90_get_var (nid1, nvarid, lmt_bcba_glo, debut, epais) 108 IF (ierr /= NF_NOERR) THEN108 IF (ierr /= nf90_noerr) THEN 109 109 PRINT*, 'Pb de lecture pour les sources BC' 110 110 CALL exit(1) … … 119 119 ! OM emissions from fossil fuel combustion 120 120 ! 121 ierr = NF_INQ_VARID(nid1, "OMFF", nvarid)121 ierr = nf90_inq_varid (nid1, "OMFF", nvarid) 122 122 ierr = nf90_get_var (nid1, nvarid, lmt_omff_glo, debut, epais) 123 IF (ierr /= NF_NOERR) THEN123 IF (ierr /= nf90_noerr) THEN 124 124 PRINT*, 'Pb de lecture pour les sources OM' 125 125 CALL exit(1) … … 128 128 ! OM emissions from non fossil fuel combustion 129 129 ! 130 ierr = NF_INQ_VARID(nid1, "OMNFF", nvarid)130 ierr = nf90_inq_varid (nid1, "OMNFF", nvarid) 131 131 ierr = nf90_get_var (nid1, nvarid, lmt_omnff_glo, debut, epais) 132 IF (ierr /= NF_NOERR) THEN132 IF (ierr /= nf90_noerr) THEN 133 133 PRINT*, 'Pb de lecture pour les sources OM' 134 134 CALL exit(1) … … 137 137 ! Low OM emissions from biomass burning - low 138 138 ! 139 ierr = NF_INQ_VARID(nid1, "OMBBL", nvarid)139 ierr = nf90_inq_varid (nid1, "OMBBL", nvarid) 140 140 ierr = nf90_get_var (nid1, nvarid, lmt_ombbl_glo, debut, epais) 141 IF (ierr /= NF_NOERR) THEN141 IF (ierr /= nf90_noerr) THEN 142 142 PRINT*, 'Pb de lecture pour les sources OM low' 143 143 CALL exit(1) … … 146 146 ! High OM emissions from biomass burning - high 147 147 ! 148 ierr = NF_INQ_VARID(nid1, "OMBBH", nvarid)148 ierr = nf90_inq_varid (nid1, "OMBBH", nvarid) 149 149 ierr = nf90_get_var (nid1, nvarid, lmt_ombbh_glo, debut, epais) 150 IF (ierr /= NF_NOERR) THEN150 IF (ierr /= nf90_noerr) THEN 151 151 PRINT*, 'Pb de lecture pour les sources OM high' 152 152 CALL exit(1) … … 155 155 ! High OM emissions from ship 156 156 ! 157 ierr = NF_INQ_VARID(nid1, "OMBA", nvarid)157 ierr = nf90_inq_varid (nid1, "OMBA", nvarid) 158 158 ierr = nf90_get_var (nid1, nvarid, lmt_omba_glo, debut, epais) 159 IF (ierr /= NF_NOERR) THEN159 IF (ierr /= nf90_noerr) THEN 160 160 PRINT*, 'Pb de lecture pour les sources OM ship' 161 161 CALL exit(1) … … 164 164 ! Natural Terpene emissions => Natural OM emissions 165 165 ! 166 ierr = NF_INQ_VARID(nid1, "TERP", nvarid)166 ierr = nf90_inq_varid (nid1, "TERP", nvarid) 167 167 ierr = nf90_get_var (nid1, nvarid, lmt_terp_glo, debut, epais) 168 IF (ierr /= NF_NOERR) THEN168 IF (ierr /= nf90_noerr) THEN 169 169 PRINT*, 'Pb de lecture pour les sources Terpene' 170 170 CALL exit(1) … … 175 175 ENDDO 176 176 177 ierr = NF_CLOSE(nid1)177 ierr = nf90_close(nid1) 178 178 ! 179 179 PRINT*, 'Carbon sources lues pour jour: ', jour -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/condsurfs.F
r5075 r5088 4 4 . lmt_dmsbio, lmt_h2sbio, lmt_dms, lmt_dmsconc) 5 5 USE dimphy 6 USE lmdz_netcdf, ONLY:nf_close,nf_noerr,nf_inq_varid,nf_open,nf_nowrite,nf90_get_var6 USE netcdf, ONLY:nf90_close,nf90_noerr,nf90_inq_varid,nf90_open,nf90_nowrite,nf90_get_var 7 7 IMPLICIT none 8 8 c … … 34 34 ENDIF 35 35 c 36 ierr = NF_OPEN ("limitsoufre.nc", NF_NOWRITE, nid)37 if (ierr/= NF_NOERR) then36 ierr = nf90_open ("limitsoufre.nc", nf90_nowrite, nid) 37 if (ierr/=nf90_noerr) then 38 38 write(6,*)' Pb d''ouverture du fichier limitsoufre.nc' 39 39 write(6,*)' ierr = ', ierr … … 47 47 epais(2) = 1 48 48 c 49 ierr = NF_INQ_VARID(nid, "VOLC", nvarid)49 ierr = nf90_inq_varid (nid, "VOLC", nvarid) 50 50 ierr = nf90_get_var(nid, nvarid, lmt_so2volc, debut, epais) 51 IF (ierr /= NF_NOERR) THEN51 IF (ierr /= nf90_noerr) THEN 52 52 PRINT*, 'Pb de lecture pour les sources so2 volcan' 53 53 CALL exit(1) 54 54 ENDIF 55 55 c 56 ierr = NF_INQ_VARID(nid, "ALTI", nvarid)56 ierr = nf90_inq_varid (nid, "ALTI", nvarid) 57 57 ierr = nf90_get_var(nid, nvarid, lmt_altvolc, debut, epais) 58 IF (ierr /= NF_NOERR) THEN58 IF (ierr /= nf90_noerr) THEN 59 59 PRINT*, 'Pb de lecture pour les altitudes volcan' 60 60 CALL exit(1) … … 63 63 IF (edgar) THEN !--EDGAR w/o ship and biomass burning 64 64 c 65 ierr = NF_INQ_VARID(nid, "SO2ED95L", nvarid)65 ierr = nf90_inq_varid (nid, "SO2ED95L", nvarid) 66 66 ierr = nf90_get_var(nid, nvarid, lmt_so2b, debut, epais) 67 IF (ierr /= NF_NOERR) THEN67 IF (ierr /= nf90_noerr) THEN 68 68 PRINT*, 'Pb de lecture pour les sources so2 edgar low' 69 69 CALL exit(1) 70 70 ENDIF 71 71 c 72 ierr = NF_INQ_VARID(nid, "SO2ED95H", nvarid)72 ierr = nf90_inq_varid (nid, "SO2ED95H", nvarid) 73 73 ierr = nf90_get_var(nid, nvarid, lmt_so2h, debut, epais) 74 IF (ierr /= NF_NOERR) THEN74 IF (ierr /= nf90_noerr) THEN 75 75 PRINT*, 'Pb de lecture pour les sources so2 edgar high' 76 76 CALL exit(1) … … 79 79 ELSE !--GEIA 80 80 c 81 ierr = NF_INQ_VARID(nid, "SO2H", nvarid)81 ierr = nf90_inq_varid (nid, "SO2H", nvarid) 82 82 ierr = nf90_get_var(nid, nvarid, lmt_so2h, debut, epais) 83 IF (ierr /= NF_NOERR) THEN83 IF (ierr /= nf90_noerr) THEN 84 84 PRINT*, 'Pb de lecture pour les sources so2 haut' 85 85 CALL exit(1) 86 86 ENDIF 87 87 c 88 ierr = NF_INQ_VARID(nid, "SO2B", nvarid)88 ierr = nf90_inq_varid (nid, "SO2B", nvarid) 89 89 ierr = nf90_get_var(nid, nvarid, lmt_so2b, debut, epais) 90 IF (ierr /= NF_NOERR) THEN90 IF (ierr /= nf90_noerr) THEN 91 91 PRINT*, 'Pb de lecture pour les sources so2 bas' 92 92 CALL exit(1) … … 95 95 ENDIF !--edgar 96 96 c 97 ierr = NF_INQ_VARID(nid, "SO2BB", nvarid)97 ierr = nf90_inq_varid (nid, "SO2BB", nvarid) 98 98 ierr = nf90_get_var(nid, nvarid, lmt_so2bb, debut, epais) 99 IF (ierr /= NF_NOERR) THEN99 IF (ierr /= nf90_noerr) THEN 100 100 PRINT*, 'Pb de lecture pour les sources so2 bb' 101 101 CALL exit(1) 102 102 ENDIF 103 103 c 104 ierr = NF_INQ_VARID(nid, "SO2BA", nvarid)104 ierr = nf90_inq_varid (nid, "SO2BA", nvarid) 105 105 ierr = nf90_get_var(nid, nvarid, lmt_so2ba, debut, epais) 106 IF (ierr /= NF_NOERR) THEN106 IF (ierr /= nf90_noerr) THEN 107 107 PRINT*, 'Pb de lecture pour les sources so2 bateau' 108 108 CALL exit(1) 109 109 ENDIF 110 110 c 111 ierr = NF_INQ_VARID(nid, "DMSB", nvarid)111 ierr = nf90_inq_varid (nid, "DMSB", nvarid) 112 112 ierr = nf90_get_var(nid, nvarid, lmt_dmsbio, debut, epais) 113 IF (ierr /= NF_NOERR) THEN113 IF (ierr /= nf90_noerr) THEN 114 114 PRINT*, 'Pb de lecture pour les sources dms bio' 115 115 CALL exit(1) 116 116 ENDIF 117 117 c 118 ierr = NF_INQ_VARID(nid, "H2SB", nvarid)118 ierr = nf90_inq_varid (nid, "H2SB", nvarid) 119 119 ierr = nf90_get_var(nid, nvarid, lmt_h2sbio, debut, epais) 120 IF (ierr /= NF_NOERR) THEN120 IF (ierr /= nf90_noerr) THEN 121 121 PRINT*, 'Pb de lecture pour les sources h2s bio' 122 122 CALL exit(1) … … 125 125 IF (flag_dms==1) THEN 126 126 c 127 ierr = NF_INQ_VARID(nid, "DMSL", nvarid)127 ierr = nf90_inq_varid (nid, "DMSL", nvarid) 128 128 ierr = nf90_get_var(nid, nvarid, lmt_dms, debut, epais) 129 IF (ierr /= NF_NOERR) THEN129 IF (ierr /= nf90_noerr) THEN 130 130 PRINT*, 'Pb de lecture pour les sources dms liss' 131 131 CALL exit(1) … … 134 134 ELSEIF (flag_dms==2) THEN 135 135 c 136 ierr = NF_INQ_VARID(nid, "DMSW", nvarid)136 ierr = nf90_inq_varid (nid, "DMSW", nvarid) 137 137 ierr = nf90_get_var(nid, nvarid, lmt_dms, debut, epais) 138 IF (ierr /= NF_NOERR) THEN138 IF (ierr /= nf90_noerr) THEN 139 139 PRINT*, 'Pb de lecture pour les sources dms wann' 140 140 CALL exit(1) … … 143 143 ELSEIF (flag_dms==3) THEN 144 144 c 145 ierr = NF_INQ_VARID(nid, "DMSC1", nvarid)146 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 147 IF (ierr /= NF_NOERR) THEN145 ierr = nf90_inq_varid (nid, "DMSC1", nvarid) 146 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 147 IF (ierr /= nf90_noerr) THEN 148 148 PRINT*, 'Pb de lecture pour les sources dmsconc old' 149 149 CALL exit(1) … … 152 152 ELSEIF (flag_dms==4) THEN 153 153 c 154 ierr = NF_INQ_VARID(nid, "DMSC2", nvarid)155 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 156 IF (ierr /= NF_NOERR) THEN154 ierr = nf90_inq_varid (nid, "DMSC2", nvarid) 155 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 156 IF (ierr /= nf90_noerr) THEN 157 157 PRINT*, 'Pb de lecture pour les sources dms conc 2' 158 158 CALL exit(1) … … 161 161 ELSEIF (flag_dms==5) THEN 162 162 c 163 ierr = NF_INQ_VARID(nid, "DMSC3", nvarid)164 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 165 IF (ierr /= NF_NOERR) THEN163 ierr = nf90_inq_varid (nid, "DMSC3", nvarid) 164 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 165 IF (ierr /= nf90_noerr) THEN 166 166 PRINT*, 'Pb de lecture pour les sources dms conc 3' 167 167 CALL exit(1) … … 170 170 ELSEIF (flag_dms==6) THEN 171 171 c 172 ierr = NF_INQ_VARID(nid, "DMSC4", nvarid)173 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 174 IF (ierr /= NF_NOERR) THEN172 ierr = nf90_inq_varid (nid, "DMSC4", nvarid) 173 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 174 IF (ierr /= nf90_noerr) THEN 175 175 PRINT*, 'Pb de lecture pour les sources dms conc 4' 176 176 CALL exit(1) … … 179 179 ELSEIF (flag_dms==7) THEN 180 180 c 181 ierr = NF_INQ_VARID(nid, "DMSC5", nvarid)182 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 183 IF (ierr /= NF_NOERR) THEN181 ierr = nf90_inq_varid (nid, "DMSC5", nvarid) 182 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 183 IF (ierr /= nf90_noerr) THEN 184 184 PRINT*, 'Pb de lecture pour les sources dms conc 5' 185 185 CALL exit(1) … … 188 188 ELSEIF (flag_dms==8) THEN 189 189 c 190 ierr = NF_INQ_VARID(nid, "DMSC6", nvarid)191 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 192 IF (ierr /= NF_NOERR) THEN190 ierr = nf90_inq_varid (nid, "DMSC6", nvarid) 191 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 192 IF (ierr /= nf90_noerr) THEN 193 193 PRINT*, 'Pb de lecture pour les sources dms conc 6' 194 194 CALL exit(1) … … 197 197 ELSEIF (flag_dms==9) THEN 198 198 c 199 ierr = NF_INQ_VARID(nid, "DMSC7", nvarid)200 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 201 IF (ierr /= NF_NOERR) THEN199 ierr = nf90_inq_varid (nid, "DMSC7", nvarid) 200 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 201 IF (ierr /= nf90_noerr) THEN 202 202 PRINT*, 'Pb de lecture pour les sources dms conc 7' 203 203 CALL exit(1) … … 206 206 ELSEIF (flag_dms==10) THEN 207 207 c 208 ierr = NF_INQ_VARID(nid, "DMSC8", nvarid)209 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 210 IF (ierr /= NF_NOERR) THEN208 ierr = nf90_inq_varid (nid, "DMSC8", nvarid) 209 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc, debut, epais) 210 IF (ierr /= nf90_noerr) THEN 211 211 PRINT*, 'Pb de lecture pour les sources dms conc 8' 212 212 CALL exit(1) … … 220 220 ENDIF 221 221 c 222 ierr = NF_CLOSE(nid)222 ierr = nf90_close(nid) 223 223 c 224 224 IF (flag_dms<=2) THEN -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/condsurfs_new.F
r5075 r5088 9 9 USE mod_phys_lmdz_para 10 10 USE dimphy 11 USE lmdz_netcdf, ONLY: nf90_get_var,nf_inq_varid,nf_close,nf_noerr,nf_open,nf_nowrite11 USE netcdf, ONLY: nf90_get_var,nf90_inq_varid,nf90_close,nf90_noerr,nf90_open,nf90_nowrite 12 12 IMPLICIT none 13 13 c … … 61 61 !======================================================================= 62 62 ! 63 ierr = NF_OPEN ("sulphur_emissions_antro.nc", NF_NOWRITE, nid)64 if (ierr/= NF_NOERR) then63 ierr = nf90_open ("sulphur_emissions_antro.nc", nf90_nowrite, nid) 64 if (ierr/=nf90_noerr) then 65 65 write(6,*)' Pb d''ouverture du fichier sulphur_emissions_antro' 66 66 write(6,*)' ierr = ', ierr … … 71 71 ! SO2 Low level emissions 72 72 ! 73 ierr = NF_INQ_VARID(nid, "SO2FF_LOW", nvarid)73 ierr = nf90_inq_varid (nid, "SO2FF_LOW", nvarid) 74 74 ierr = nf90_get_var(nid, nvarid, lmt_so2b_glo, debut, epais) 75 IF (ierr /= NF_NOERR) THEN75 IF (ierr /= nf90_noerr) THEN 76 76 PRINT*, 'Pb de lecture pour les sources so2 low' 77 77 print *,'JE klon, jour, debut ,epais ',klon_glo,jour,debut,epais … … 83 83 ! SO2 High level emissions 84 84 ! 85 ierr = NF_INQ_VARID(nid, "SO2FF_HIGH", nvarid)85 ierr = nf90_inq_varid (nid, "SO2FF_HIGH", nvarid) 86 86 ierr = nf90_get_var(nid, nvarid, lmt_so2h_glo, debut, epais) 87 IF (ierr /= NF_NOERR) THEN87 IF (ierr /= nf90_noerr) THEN 88 88 PRINT*, 'Pb de lecture pour les sources so2 high' 89 89 CALL exit(1) … … 92 92 ! SO2 Biomass burning High level emissions 93 93 ! 94 ierr = NF_INQ_VARID(nid, "SO2BBH", nvarid)94 ierr = nf90_inq_varid (nid, "SO2BBH", nvarid) 95 95 ierr = nf90_get_var(nid, nvarid, lmt_so2bb_h_glo, debut, epais) 96 IF (ierr /= NF_NOERR) THEN96 IF (ierr /= nf90_noerr) THEN 97 97 PRINT*, 'Pb de lecture pour les sources so2 BB high' 98 98 CALL exit(1) … … 101 101 ! SO2 biomass burning low level emissions 102 102 ! 103 ierr = NF_INQ_VARID(nid, "SO2BBL", nvarid)103 ierr = nf90_inq_varid (nid, "SO2BBL", nvarid) 104 104 ierr = nf90_get_var(nid, nvarid, lmt_so2bb_l_glo, debut, epais) 105 IF (ierr /= NF_NOERR) THEN105 IF (ierr /= nf90_noerr) THEN 106 106 PRINT*, 'Pb de lecture pour les sources so2 BB low' 107 107 CALL exit(1) … … 110 110 ! SO2 ship emissions 111 111 ! 112 ierr = NF_INQ_VARID(nid, "SO2BA", nvarid)112 ierr = nf90_inq_varid (nid, "SO2BA", nvarid) 113 113 ierr = nf90_get_var(nid, nvarid, lmt_so2ba_glo, debut, epais) 114 IF (ierr /= NF_NOERR) THEN114 IF (ierr /= nf90_noerr) THEN 115 115 PRINT*, 'Pb de lecture pour les sources so2 ship' 116 116 CALL exit(1) … … 119 119 ! SO2 Non Fossil Fuel Emissions 120 120 ! 121 ierr = NF_INQ_VARID(nid, "SO2NFF", nvarid)121 ierr = nf90_inq_varid (nid, "SO2NFF", nvarid) 122 122 ierr = nf90_get_var(nid, nvarid, lmt_so2nff_glo, debut, epais) 123 IF (ierr /= NF_NOERR) THEN123 IF (ierr /= nf90_noerr) THEN 124 124 PRINT*, 'Pb de lecture pour les sources so2 non FF' 125 125 CALL exit(1) 126 126 ENDIF 127 127 ! 128 ierr = NF_CLOSE(nid)128 ierr = nf90_close(nid) 129 129 ! 130 130 !======================================================================= 131 131 ! READING NATURAL EMISSIONS 132 132 !======================================================================= 133 ierr = NF_OPEN ("sulphur_emissions_nat.nc", NF_NOWRITE, nid)134 if (ierr/= NF_NOERR) then133 ierr = nf90_open ("sulphur_emissions_nat.nc", nf90_nowrite, nid) 134 if (ierr/=nf90_noerr) then 135 135 write(6,*)' Pb d''ouverture du fichier sulphur_emissions_nat' 136 136 write(6,*)' ierr = ', ierr … … 140 140 c Biologenic source of DMS 141 141 c 142 ierr = NF_INQ_VARID(nid, "DMSB", nvarid)142 ierr = nf90_inq_varid (nid, "DMSB", nvarid) 143 143 ierr = nf90_get_var(nid, nvarid, lmt_dmsbio_glo, debut, epais) 144 IF (ierr /= NF_NOERR) THEN144 IF (ierr /= nf90_noerr) THEN 145 145 PRINT*, 'Pb de lecture pour les sources dms bio' 146 146 CALL exit(1) … … 149 149 c Biologenic source of H2S 150 150 c 151 ierr = NF_INQ_VARID(nid, "H2SB", nvarid)151 ierr = nf90_inq_varid (nid, "H2SB", nvarid) 152 152 ierr = nf90_get_var(nid, nvarid, lmt_h2sbio_glo, debut, epais) 153 IF (ierr /= NF_NOERR) THEN153 IF (ierr /= nf90_noerr) THEN 154 154 PRINT*, 'Pb de lecture pour les sources h2s bio' 155 155 CALL exit(1) … … 160 160 IF (flag_dms==4) THEN 161 161 c 162 ierr = NF_INQ_VARID(nid, "DMSC2", nvarid)162 ierr = nf90_inq_varid (nid, "DMSC2", nvarid) 163 163 ierr = nf90_get_var(nid, nvarid, lmt_dmsconc_glo, debut, epais) 164 IF (ierr /= NF_NOERR) THEN164 IF (ierr /= nf90_noerr) THEN 165 165 PRINT*, 'Pb de lecture pour les sources dms conc 2' 166 166 CALL exit(1) … … 179 179 ENDIF 180 180 c 181 ierr = NF_CLOSE(nid)181 ierr = nf90_close(nid) 182 182 c 183 183 !======================================================================= … … 186 186 print *,' *** READING VOLCANIC EMISSIONS *** ' 187 187 print *,' Jour = ',jour 188 ierr = NF_OPEN ("sulphur_emissions_volc.nc", NF_NOWRITE, nid)189 if (ierr/= NF_NOERR) then188 ierr = nf90_open ("sulphur_emissions_volc.nc", nf90_nowrite, nid) 189 if (ierr/=nf90_noerr) then 190 190 write(6,*)' Pb d''ouverture du fichier sulphur_emissions_volc' 191 191 write(6,*)' ierr = ', ierr … … 195 195 c Continuous Volcanic emissions 196 196 c 197 ! ierr = NF_INQ_VARID(nid, "VOLC", nvarid)198 ierr = NF_INQ_VARID(nid, "flx_volc_cont", nvarid)197 ! ierr = nf90_inq_varid (nid, "VOLC", nvarid) 198 ierr = nf90_inq_varid (nid, "flx_volc_cont", nvarid) 199 199 ierr = nf90_get_var(nid, nvarid, lmt_so2volc_cont_glo, debut, epais) 200 IF (ierr /= NF_NOERR) THEN200 IF (ierr /= nf90_noerr) THEN 201 201 PRINT*, 'Pb de lecture pour les sources so2 volcan (cont)' 202 202 CALL exit(1) … … 208 208 c Altitud of continuous volcanic emissions 209 209 c 210 ! ierr = NF_INQ_VARID(nid, "ALTI", nvarid)211 ierr = NF_INQ_VARID(nid, "flx_volc_altcont", nvarid)210 ! ierr = nf90_inq_varid (nid, "ALTI", nvarid) 211 ierr = nf90_inq_varid (nid, "flx_volc_altcont", nvarid) 212 212 ierr = nf90_get_var(nid, nvarid, lmt_altvolc_cont_glo, debut, epais) 213 IF (ierr /= NF_NOERR) THEN213 IF (ierr /= nf90_noerr) THEN 214 214 PRINT*, 'Pb de lecture pour les altitudes volcan (cont)' 215 215 CALL exit(1) … … 218 218 c Explosive Volcanic emissions 219 219 c 220 ierr = NF_INQ_VARID(nid, "flx_volc_expl", nvarid)220 ierr = nf90_inq_varid (nid, "flx_volc_expl", nvarid) 221 221 ierr = nf90_get_var(nid, nvarid, lmt_so2volc_expl_glo, debut, epais) 222 IF (ierr /= NF_NOERR) THEN222 IF (ierr /= nf90_noerr) THEN 223 223 PRINT*, 'Pb de lecture pour les sources so2 volcan (expl)' 224 224 CALL exit(1) … … 230 230 c Altitud of explosive volcanic emissions 231 231 c 232 ierr = NF_INQ_VARID(nid, "flx_volc_altexpl", nvarid)232 ierr = nf90_inq_varid (nid, "flx_volc_altexpl", nvarid) 233 233 ierr = nf90_get_var(nid, nvarid, lmt_altvolc_expl_glo, debut, epais) 234 IF (ierr /= NF_NOERR) THEN234 IF (ierr /= nf90_noerr) THEN 235 235 PRINT*, 'Pb de lecture pour les altitudes volcan' 236 236 CALL exit(1) … … 238 238 ! lmt_altvolc_expl(:)=0.0 239 239 240 ierr = NF_CLOSE(nid)240 ierr = nf90_close(nid) 241 241 c 242 242 PRINT*, 'Sources SOUFRE lues pour jour: ', jour -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/phys_output_write_spl_mod.F90
r5082 r5088 390 390 USE ioipsl, ONLY: histend, histsync 391 391 USE iophy, ONLY: set_itau_iophy, histwrite_phy 392 USE lmdz_netcdf, ONLY: nf90_fill_real392 USE netcdf, ONLY: nf90_fill_real 393 393 ! ug Pour les sorties XIOS 394 394 USE lmdz_xios, ONLY: xios_update_calendar, using_xios -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/phytracr_spl_mod.F90
r5082 r5088 4568 4568 USE mod_grid_phy_lmdz 4569 4569 USE mod_phys_lmdz_para 4570 USE lmdz_netcdf, ONLY:nf_open,nf_close,nf_inq_varid,nf_nowrite,nf_noerr,nf90_get_var4570 USE netcdf, ONLY:nf90_open,nf90_close,nf90_inq_varid,nf90_nowrite,nf90_noerr,nf90_get_var 4571 4571 IMPLICIT NONE 4572 4572 … … 4587 4587 IF (is_mpi_root .AND. is_omp_root) THEN 4588 4588 !nci=NCOPN(trim(adjustl(filescaleparams)),NCNOWRIT,rcode) 4589 ierr = NF_OPEN (trim(adjustl(filescaleparams)),NF_NOWRITE, nid)4590 if (ierr == NF_NOERR) THEN4589 ierr = nf90_open (trim(adjustl(filescaleparams)),nf90_nowrite, nid) 4590 if (ierr == nf90_noerr) THEN 4591 4591 debutread=step_sca 4592 4592 countread=1 … … 4596 4596 varname= trim(adjustl(paramname))//aux_2s 4597 4597 print *,varname 4598 ierr = NF_INQ_VARID(nid,trim(adjustl(varname)), nvarid)4598 ierr = nf90_inq_varid (nid,trim(adjustl(varname)), nvarid) 4599 4599 ierr = nf90_get_var (nid, nvarid, auxreal, debutread, countread) 4600 IF (ierr /= NF_NOERR) THEN4600 IF (ierr /= nf90_noerr) THEN 4601 4601 PRINT*, 'Pb de lecture pour modvalues' 4602 4602 print *,'JE scale_var, step_sca',trim(adjustl(varname)),step_sca … … 4611 4611 enddo 4612 4612 4613 ierr = NF_CLOSE(nid)4613 ierr = nf90_close(nid) 4614 4614 else 4615 4615 print *,'File '//trim(adjustl(filescaleparams))//' not found' -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/read_dust.F
r5075 r5088 3 3 USE mod_grid_phy_lmdz 4 4 USE mod_phys_lmdz_para 5 USE lmdz_netcdf, ONLY:nf90_get_var5 USE netcdf, ONLY:nf90_get_var 6 6 IMPLICIT NONE 7 7 c -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/read_surface.F90
r5087 r5088 10 10 USE mod_phys_lmdz_para 11 11 USE iophy 12 USE lmdz_netcdf, ONLY:nf_inq_varid,nf_noerr,nf90_get_var12 USE netcdf, ONLY:nf90_inq_varid,nf90_noerr,nf90_get_var 13 13 IMPLICIT NONE 14 14 … … 61 61 if (i==4) aux4s='Latu' 62 62 if (i==5) aux4s='latU' 63 status = NF_INQ_VARID(ncid, aux4s, rcode)63 status = nf90_inq_varid (ncid, aux4s, rcode) 64 64 ! print *,'stat,i',status,i,outcycle,aux4s 65 ! print *,'ifclause',status.NE. NF_NOERR,outcycle == .false.66 IF ((.not.(status/= NF_NOERR) ).and.( .not. outcycle )) THEN65 ! print *,'ifclause',status.NE. nf90_noerr ,outcycle == .false. 66 IF ((.not.(status/= nf90_noerr) ).and.( .not. outcycle )) THEN 67 67 outcycle=.true. 68 68 latstr=aux4s … … 76 76 status=nf90_get_var(ncid,varid,lats_glo,startj,endj) 77 77 ! print *,latstr,varid,status,jjp1,rcode 78 ! IF (status .NE. NF_NOERR) print*,'NOOOOOOO'78 ! IF (status .NE. nf90_noerr) print*,'NOOOOOOO' 79 79 ! print *,lats 80 80 !stop -
LMDZ6/branches/Amaury_dev/libf/phylmd/Dust/read_vent.F
r5075 r5088 3 3 USE mod_grid_phy_lmdz 4 4 USE mod_phys_lmdz_para 5 USE lmdz_netcdf, ONLY: nf90_get_var5 USE netcdf, ONLY: nf90_get_var 6 6 ! USE write_field_phy 7 7 IMPLICIT NONE
Note: See TracChangeset
for help on using the changeset viewer.