Changeset 115 for LMDZ.3.3/branches/rel-LF
- Timestamp:
- Jul 28, 2000, 6:49:17 PM (24 years ago)
- Location:
- LMDZ.3.3/branches/rel-LF/libf
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ.3.3/branches/rel-LF/libf/dyn3d/etat0_netcdf.F
r112 r115 500 500 frugs(:,is_sic) = rugmer 501 501 502 call phy redem("startphy.nc",phystep,radpas, co2_ppm, solaire,502 call physdem("startphy.nc",phystep,radpas, co2_ppm, solaire, 503 503 $ latfi, lonfi, pctsrf, tsolsrf, tsoil, deltat, qsolsrf, snsrf, 504 504 $ albe, evap, rain_fall, snow_fall, solsw, sollw, -
LMDZ.3.3/branches/rel-LF/libf/dyn3d/physdem.F
r110 r115 1 subroutine physdem(lonfi, latfi,phystep,radpas,co2_ppm,2 . solaire, ts, ws,3 . sn, radsol, deltat, rugmer,4 . agesno, zmea, zstd, zsig,5 . zgam, zthe, zpic, zval,6 . rugsrel)7 1 SUBROUTINE physdem (fichnom,dtime,radpas,co2_ppm,solaire, 2 . rlat,rlon, pctsrf,tsol,tsoil,deltat,qsol,snow, 3 . albedo, evap, rain_fall, snow_fall, 4 . solsw, sollw, 5 . radsol,frugs,agesno, 6 . zmea,zstd,zsig,zgam,zthe,zpic,zval,rugsrel, 7 . t_ancien, q_ancien) 8 8 IMPLICIT none 9 c------------------------------------------------------------- 10 C Author : L. Fairhead 11 C Date : 01/10/1999 12 C Objet : Ecriture des etats initiaux physiques 13 c------------------------------------------------------------- 14 c 15 c 16 c 17 INTEGER ivap 18 PARAMETER (ivap=1) 19 c 20 REAL qsolmax 21 PARAMETER ( qsolmax = 150.0 ) 22 c 9 c====================================================================== 10 c Auteur(s) Z.X. Li (LMD/CNRS) date: 19930818 11 c Objet: Ecriture de l'etat de redemarrage pour la physique 12 c====================================================================== 23 13 #include "dimensions.h" 24 #include "paramet.h" 25 c----------------------------------------------------------------------- 26 INTEGER KIDIA, KFDIA, KLON, KLEV 27 PARAMETER (KIDIA=1,KFDIA=iim*(jjm-1)+2, 28 . KLON=KFDIA-KIDIA+1,KLEV=llm) 29 c----------------------------------------------------------------------- 30 #include "comconst.h" 31 #include "comvert.h" 32 #include "comgeom2.h" 14 #include "dimphy.h" 15 #include "netcdf.inc" 16 #include "indicesol.h" 17 #include "dimsoil.h" 18 #include "clesph0.h" 33 19 #include "control.h" 34 #include "comdissnew.h" 35 #include "logic.h" 36 #include "ener.h" 37 #include "netcdf.inc" 38 c 39 INTEGER nid 40 41 c Ajout de quelques parametres orographiques (F. LOTT janvier 1995) 42 43 REAL zmea(klon),zstd(klon) 44 REAL zsig(klon),zgam(klon),zthe(klon) 45 REAL zpic(klon),zval(klon) 46 REAL rugsrel(klon) 47 INTEGER idayref,anneeref 48 49 50 integer ierr, idim1, idim2, nvarid 51 52 c 53 REAL phystep 20 #include "temps.h" 21 c====================================================================== 22 CHARACTER*(*) fichnom 23 REAL dtime 54 24 INTEGER radpas 25 REAL rlat(klon), rlon(klon) 55 26 REAL co2_ppm 56 27 REAL solaire 57 REAL latfi(klon), lonfi(klon) 58 REAL champhys(klon) 59 REAL ts(klon) 28 REAL tsol(klon,nbsrf) 29 REAL tsoil(klon,nsoilmx,nbsrf) 60 30 REAL deltat(klon) 61 REAL ws(klon) 62 REAL sn(klon) 31 REAL qsol(klon,nbsrf) 32 REAL snow(klon,nbsrf) 33 REAL albedo(klon,nbsrf) 34 REAL evap(klon,nbsrf) 35 REAL rain_fall(klon) 36 REAL snow_fall(klon) 37 real solsw(klon) 38 real sollw(klon) 63 39 REAL radsol(klon) 64 REAL rugmer(klon)40 REAL frugs(klon,nbsrf) 65 41 REAL agesno(klon) 42 REAL zmea(klon) 43 REAL zstd(klon) 44 REAL zsig(klon) 45 REAL zgam(klon) 46 REAL zthe(klon) 47 REAL zpic(klon) 48 REAL zval(klon) 49 REAL rugsrel(klon) 50 REAL pctsrf(klon, nbsrf) 51 REAL t_ancien(klon,klev), q_ancien(klon,klev) 52 c 53 INTEGER nid, nvarid, idim1, idim2, idim3 54 INTEGER ierr 66 55 INTEGER length 67 56 PARAMETER (length=100) 68 57 REAL tab_cntrl(length) 69 70 c 71 72 EXTERNAL defrun_new,iniconst,geopot,inigeom,massdair,pression 73 EXTERNAL exner_hyb , SSUM 74 c 75 #include "serre.h" 76 #include "clesph0.h" 77 #include "fxyprim.h" 78 c----------------------------------------------------------------------- 79 c 80 c stockage sur le fichier Physique: 81 c 82 ierr = NF_CREATE("startphy.nc", NF_CLOBBER, nid) 58 c 59 INTEGER isoil, nsrf 60 CHARACTER*7 str7 61 CHARACTER*2 str2 62 c 63 ierr = NF_CREATE(fichnom, NF_CLOBBER, nid) 83 64 IF (ierr.NE.NF_NOERR) THEN 84 WRITE(6,*)' Pb d''ouverture du fichier startphy.nc'85 WRITE(6,*)' ierr = ', ierr65 write(6,*)' Pb d''ouverture du fichier '//fichnom 66 write(6,*)' ierr = ', ierr 86 67 CALL ABORT 87 68 ENDIF 88 69 c 89 70 ierr = NF_PUT_ATT_TEXT (nid, NF_GLOBAL, "title", 28, 90 . "Fichier demmarage physique")71 . "Fichier redemmarage physique") 91 72 c 92 73 ierr = NF_DEF_DIM (nid, "index", length, idim1) 93 74 ierr = NF_DEF_DIM (nid, "points_physiques", klon, idim2) 75 ierr = NF_DEF_DIM (nid, "horizon_vertical", klon*klev, idim3) 94 76 c 95 77 ierr = NF_ENDDEF(nid) … … 98 80 tab_cntrl(ierr) = 0.0 99 81 ENDDO 100 tab_cntrl(1) = phystep 101 tab_cntrl(2) = radpas 102 tab_cntrl(3) = co2_ppm 103 tab_cntrl(4) = solaire 104 tab_cntrl(5) = iflag_con 105 tab_cntrl(6) = nbapp_rad 106 c 107 cc Modif ( P. Le Van ) 108 c 109 tab_cntrl( 7 ) = 0. 110 tab_cntrl( 8 ) = 0. 111 tab_cntrl( 9 ) = 0. 112 tab_cntrl(10 ) = 0. 113 tab_cntrl(11 ) = 0. 114 tab_cntrl(12 ) = 0. 82 tab_cntrl(1) = dtime 83 tab_cntrl(2) = radpas 84 tab_cntrl(3) = co2_ppm 85 tab_cntrl(4) = solaire 86 tab_cntrl(5) = iflag_con 87 tab_cntrl(6) = nbapp_rad 115 88 116 IF( cycle_diurne ) tab_cntrl( 7 ) = 1. 117 IF( soil_model ) tab_cntrl( 8 ) = 1. 118 IF( new_oliq ) tab_cntrl( 9 ) = 1. 119 IF( ok_orodr ) tab_cntrl(10 ) = 1. 120 IF( ok_orolf ) tab_cntrl(11 ) = 1. 121 IF( ok_limitvrai ) tab_cntrl(12 ) = 1. 89 IF( cycle_diurne ) tab_cntrl( 7 ) = 1. 90 IF( soil_model ) tab_cntrl( 8 ) = 1. 91 IF( new_oliq ) tab_cntrl( 9 ) = 1. 92 IF( ok_orodr ) tab_cntrl(10 ) = 1. 93 IF( ok_orolf ) tab_cntrl(11 ) = 1. 122 94 123 tab_cntrl(13) = dayref 124 tab_cntrl(14) = anneeref 125 126 127 cc *** new_oliq ( commentaires de L. LI dans routine physique ) 128 cc *** ok_orodr et ok_orolf si on appelle l'orographie **** 129 95 tab_cntrl(13) = dayref 96 tab_cntrl(14) = anneeref 97 tab_cntrl(13) = day_end 98 tab_cntrl(14) = anne_ini 130 99 c 131 100 ierr = NF_REDEF (nid) … … 153 122 . "Longitudes de la grille physique") 154 123 ierr = NF_ENDDEF(nid) 155 156 #ifdef NC_DOUBLE 157 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,lonfi) 158 #else 159 ierr = NF_PUT_VAR_REAL (nid,nvarid,lonfi) 124 #ifdef NC_DOUBLE 125 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,rlon) 126 #else 127 ierr = NF_PUT_VAR_REAL (nid,nvarid,rlon) 160 128 #endif 161 129 c … … 170 138 ierr = NF_ENDDEF(nid) 171 139 #ifdef NC_DOUBLE 172 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,latfi) 173 #else 174 ierr = NF_PUT_VAR_REAL (nid,nvarid,latfi) 175 #endif 176 c 177 ierr = NF_REDEF (nid) 178 #ifdef NC_DOUBLE 179 ierr = NF_DEF_VAR (nid, "TS", NF_DOUBLE, 1, idim2,nvarid) 180 #else 181 ierr = NF_DEF_VAR (nid, "TS", NF_FLOAT, 1, idim2,nvarid) 182 #endif 183 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 25, 184 . "Temperature de la surface") 185 ierr = NF_ENDDEF(nid) 186 #ifdef NC_DOUBLE 187 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,ts) 188 #else 189 ierr = NF_PUT_VAR_REAL (nid,nvarid,ts) 190 #endif 191 c 192 ierr = NF_REDEF (nid) 193 #ifdef NC_DOUBLE 194 ierr = NF_DEF_VAR (nid, "QS", NF_DOUBLE, 1, idim2,nvarid) 195 #else 196 ierr = NF_DEF_VAR (nid, "QS", NF_FLOAT, 1, idim2,nvarid) 197 #endif 198 ierr = NF_PUT_ATT_TEXT (nid, nvarid, "title", 15, 199 . "Humidite du sol") 200 ierr = NF_ENDDEF(nid) 201 #ifdef NC_DOUBLE 202 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,ws) 203 #else 204 ierr = NF_PUT_VAR_REAL (nid,nvarid,ws) 205 #endif 206 c 207 ierr = NF_REDEF (nid) 208 #ifdef NC_DOUBLE 209 ierr = NF_DEF_VAR (nid, "SNOW", NF_DOUBLE, 1, idim2,nvarid) 210 #else 211 ierr = NF_DEF_VAR (nid, "SNOW", NF_FLOAT, 1, idim2,nvarid) 212 #endif 213 ierr = NF_PUT_ATT_TEXT (nid, nvarid, "title", 5, 214 . "Neige") 215 ierr = NF_ENDDEF(nid) 216 #ifdef NC_DOUBLE 217 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,sn) 218 #else 219 ierr = NF_PUT_VAR_REAL (nid,nvarid,sn) 220 #endif 140 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,rlat) 141 #else 142 ierr = NF_PUT_VAR_REAL (nid,nvarid,rlat) 143 #endif 144 c 145 C PB ajout du masque terre/mer 146 C 147 ierr = NF_REDEF (nid) 148 #ifdef NC_DOUBLE 149 ierr = NF_DEF_VAR (nid, "masque", NF_DOUBLE, 1, idim2,nvarid) 150 #else 151 ierr = NF_DEF_VAR (nid, "masque", NF_FLOAT, 1, idim2,nvarid) 152 #endif 153 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 16, 154 . "masque terre mer") 155 ierr = NF_ENDDEF(nid) 156 #ifdef NC_DOUBLE 157 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zmasq) 158 #else 159 ierr = NF_PUT_VAR_REAL (nid,nvarid,zmasq) 160 #endif 161 c BP ajout des fraction de chaque sous-surface 162 C 163 C 1. fraction de terre 164 C 165 ierr = NF_REDEF (nid) 166 #ifdef NC_DOUBLE 167 ierr = NF_DEF_VAR (nid, "FTER", NF_DOUBLE, 1, idim2,nvarid) 168 #else 169 ierr = NF_DEF_VAR (nid, "FTER", NF_FLOAT, 1, idim2,nvarid) 170 #endif 171 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 21, 172 . "fraction de continent") 173 ierr = NF_ENDDEF(nid) 174 #ifdef NC_DOUBLE 175 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,pctsrf(1 : klon, is_ter)) 176 #else 177 ierr = NF_PUT_VAR_REAL (nid,nvarid,pctsrf(1 : klon, is_ter)) 178 #endif 179 C 180 C 2. Fraction de glace de terre 181 C 182 ierr = NF_REDEF (nid) 183 #ifdef NC_DOUBLE 184 ierr = NF_DEF_VAR (nid, "FLIC", NF_DOUBLE, 1, idim2,nvarid) 185 #else 186 ierr = NF_DEF_VAR (nid, "FLIC", NF_FLOAT, 1, idim2,nvarid) 187 #endif 188 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 24, 189 . "fraction glace de terre") 190 ierr = NF_ENDDEF(nid) 191 #ifdef NC_DOUBLE 192 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,pctsrf(1 : klon,is_lic)) 193 #else 194 ierr = NF_PUT_VAR_REAL (nid,nvarid,pctsrf(1 : klon, is_lic)) 195 #endif 196 C 197 C 3. fraction ocean 198 C 199 ierr = NF_REDEF (nid) 200 #ifdef NC_DOUBLE 201 ierr = NF_DEF_VAR (nid, "FOCE", NF_DOUBLE, 1, idim2,nvarid) 202 #else 203 ierr = NF_DEF_VAR (nid, "FOCE", NF_FLOAT, 1, idim2,nvarid) 204 #endif 205 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 14, 206 . "fraction ocean") 207 ierr = NF_ENDDEF(nid) 208 #ifdef NC_DOUBLE 209 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,pctsrf(1 : klon, is_oce)) 210 #else 211 ierr = NF_PUT_VAR_REAL (nid,nvarid,pctsrf(1 : klon, is_oce)) 212 #endif 213 C 214 C 4. Fraction glace de mer 215 C 216 ierr = NF_REDEF (nid) 217 #ifdef NC_DOUBLE 218 ierr = NF_DEF_VAR (nid, "FSIC", NF_DOUBLE, 1, idim2,nvarid) 219 #else 220 ierr = NF_DEF_VAR (nid, "FSIC", NF_FLOAT, 1, idim2,nvarid) 221 #endif 222 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 18, 223 . "fraction glace mer") 224 ierr = NF_ENDDEF(nid) 225 #ifdef NC_DOUBLE 226 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,pctsrf(1 : klon, is_sic)) 227 #else 228 ierr = NF_PUT_VAR_REAL (nid,nvarid,pctsrf(1 : klon, is_sic)) 229 #endif 230 C 231 C 232 c 233 DO nsrf = 1, nbsrf 234 IF (nsrf.LE.99) THEN 235 WRITE(str2,'(i2.2)') nsrf 236 ierr = NF_REDEF (nid) 237 #ifdef NC_DOUBLE 238 ierr = NF_DEF_VAR (nid, "TS"//str2, NF_DOUBLE, 1, idim2,nvarid) 239 #else 240 ierr = NF_DEF_VAR (nid, "TS"//str2, NF_FLOAT, 1, idim2,nvarid) 241 #endif 242 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 28, 243 . "Temperature de surface No."//str2) 244 ierr = NF_ENDDEF(nid) 245 ELSE 246 PRINT*, "Trop de sous-mailles" 247 CALL abort 248 ENDIF 249 #ifdef NC_DOUBLE 250 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,tsol(1,nsrf)) 251 #else 252 ierr = NF_PUT_VAR_REAL (nid,nvarid,tsol(1,nsrf)) 253 #endif 254 ENDDO 255 c 256 DO nsrf = 1, nbsrf 257 DO isoil=1, nsoilmx 258 IF (isoil.LE.99 .AND. nsrf.LE.99) THEN 259 WRITE(str7,'(i2.2,"srf",i2.2)') isoil,nsrf 260 ierr = NF_REDEF (nid) 261 #ifdef NC_DOUBLE 262 ierr = NF_DEF_VAR (nid, "Tsoil"//str7,NF_DOUBLE,1,idim2,nvarid) 263 #else 264 ierr = NF_DEF_VAR (nid, "Tsoil"//str7,NF_FLOAT,1,idim2,nvarid) 265 #endif 266 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 29, 267 . "Temperature du sol No."//str7) 268 ierr = NF_ENDDEF(nid) 269 ELSE 270 PRINT*, "Trop de couches" 271 CALL abort 272 ENDIF 273 #ifdef NC_DOUBLE 274 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,tsoil(1,isoil,nsrf)) 275 #else 276 ierr = NF_PUT_VAR_REAL (nid,nvarid,tsoil(1,isoil,nsrf)) 277 #endif 278 ENDDO 279 ENDDO 280 c 281 c 282 ierr = NF_REDEF (nid) 283 #ifdef NC_DOUBLE 284 ierr = NF_DEF_VAR (nid, "DELTAT", NF_DOUBLE, 1, idim2,nvarid) 285 #else 286 ierr = NF_DEF_VAR (nid, "DELTAT", NF_FLOAT, 1, idim2,nvarid) 287 #endif 288 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 33, 289 . "Ecart de la SST (pour slab-ocean)") 290 ierr = NF_ENDDEF(nid) 291 #ifdef NC_DOUBLE 292 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,deltat) 293 #else 294 ierr = NF_PUT_VAR_REAL (nid,nvarid,deltat) 295 #endif 296 c 297 DO nsrf = 1, nbsrf 298 IF (nsrf.LE.99) THEN 299 WRITE(str2,'(i2.2)') nsrf 300 ierr = NF_REDEF (nid) 301 #ifdef NC_DOUBLE 302 ierr = NF_DEF_VAR (nid,"QS"//str2,NF_DOUBLE,1,idim2,nvarid) 303 #else 304 ierr = NF_DEF_VAR (nid,"QS"//str2,NF_FLOAT,1,idim2,nvarid) 305 #endif 306 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 25, 307 . "Humidite de surface No."//str2) 308 ierr = NF_ENDDEF(nid) 309 ELSE 310 PRINT*, "Trop de sous-mailles" 311 CALL abort 312 ENDIF 313 #ifdef NC_DOUBLE 314 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,qsol(1,nsrf)) 315 #else 316 ierr = NF_PUT_VAR_REAL (nid,nvarid,qsol(1,nsrf)) 317 #endif 318 ENDDO 319 c 320 DO nsrf = 1, nbsrf 321 IF (nsrf.LE.99) THEN 322 WRITE(str2,'(i2.2)') nsrf 323 ierr = NF_REDEF (nid) 324 #ifdef NC_DOUBLE 325 ierr = NF_DEF_VAR (nid,"ALBE"//str2,NF_DOUBLE,1,idim2,nvarid) 326 #else 327 ierr = NF_DEF_VAR (nid,"ALBE"//str2,NF_FLOAT,1,idim2,nvarid) 328 #endif 329 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 23, 330 . "albedo de surface No."//str2) 331 ierr = NF_ENDDEF(nid) 332 ELSE 333 PRINT*, "Trop de sous-mailles" 334 CALL abort 335 ENDIF 336 #ifdef NC_DOUBLE 337 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,albedo(1,nsrf)) 338 #else 339 ierr = NF_PUT_VAR_REAL (nid,nvarid,albedo(1,nsrf)) 340 #endif 341 ENDDO 342 c 343 DO nsrf = 1, nbsrf 344 IF (nsrf.LE.99) THEN 345 WRITE(str2,'(i2.2)') nsrf 346 ierr = NF_REDEF (nid) 347 #ifdef NC_DOUBLE 348 ierr = NF_DEF_VAR (nid,"EVAP"//str2,NF_DOUBLE,1,idim2,nvarid) 349 #else 350 ierr = NF_DEF_VAR (nid,"EVAP"//str2,NF_FLOAT,1,idim2,nvarid) 351 #endif 352 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 28, 353 . "Evaporation de surface No."//str2) 354 ierr = NF_ENDDEF(nid) 355 ELSE 356 PRINT*, "Trop de sous-mailles" 357 CALL abort 358 ENDIF 359 #ifdef NC_DOUBLE 360 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,evap(1,nsrf)) 361 #else 362 ierr = NF_PUT_VAR_REAL (nid,nvarid,evap(1,nsrf)) 363 #endif 364 ENDDO 365 366 c 367 DO nsrf = 1, nbsrf 368 IF (nsrf.LE.99) THEN 369 WRITE(str2,'(i2.2)') nsrf 370 ierr = NF_REDEF (nid) 371 #ifdef NC_DOUBLE 372 ierr = NF_DEF_VAR (nid,"SNOW"//str2,NF_DOUBLE,1,idim2,nvarid) 373 #else 374 ierr = NF_DEF_VAR (nid,"SNOW"//str2,NF_FLOAT,1,idim2,nvarid) 375 #endif 376 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 22, 377 . "Neige de surface No."//str2) 378 ierr = NF_ENDDEF(nid) 379 ELSE 380 PRINT*, "Trop de sous-mailles" 381 CALL abort 382 ENDIF 383 #ifdef NC_DOUBLE 384 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,snow(1,nsrf)) 385 #else 386 ierr = NF_PUT_VAR_REAL (nid,nvarid,snow(1,nsrf)) 387 #endif 388 ENDDO 389 221 390 c 222 391 ierr = NF_REDEF (nid) … … 237 406 ierr = NF_REDEF (nid) 238 407 #ifdef NC_DOUBLE 239 ierr = NF_DEF_VAR (nid, "DELTAT", NF_DOUBLE, 1, idim2,nvarid) 240 #else 241 ierr = NF_DEF_VAR (nid, "DELTAT", NF_FLOAT, 1, idim2,nvarid) 242 #endif 243 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 33, 244 . "Ecart de la SST (pour slab-ocean)") 245 ierr = NF_ENDDEF(nid) 246 #ifdef NC_DOUBLE 247 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,deltat) 248 #else 249 ierr = NF_PUT_VAR_REAL (nid,nvarid,deltat) 250 #endif 251 c 252 ierr = NF_REDEF (nid) 253 #ifdef NC_DOUBLE 254 ierr = NF_DEF_VAR (nid, "RUGMER", NF_DOUBLE, 1, idim2,nvarid) 255 #else 256 ierr = NF_DEF_VAR (nid, "RUGMER", NF_FLOAT, 1, idim2,nvarid) 257 #endif 258 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 28, 259 . "Longueur de rugosite sur mer") 260 ierr = NF_ENDDEF(nid) 261 #ifdef NC_DOUBLE 262 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,rugmer) 263 #else 264 ierr = NF_PUT_VAR_REAL (nid,nvarid,rugmer) 265 #endif 408 ierr = NF_DEF_VAR (nid, "solsw", NF_DOUBLE, 1, idim2,nvarid) 409 #else 410 ierr = NF_DEF_VAR (nid, "solsw", NF_FLOAT, 1, idim2,nvarid) 411 #endif 412 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 32, 413 . "Rayonnement solaire a la surface") 414 ierr = NF_ENDDEF(nid) 415 #ifdef NC_DOUBLE 416 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,solsw) 417 #else 418 ierr = NF_PUT_VAR_REAL (nid,nvarid,solsw) 419 #endif 420 c 421 ierr = NF_REDEF (nid) 422 #ifdef NC_DOUBLE 423 ierr = NF_DEF_VAR (nid, "sollw", NF_DOUBLE, 1, idim2,nvarid) 424 #else 425 ierr = NF_DEF_VAR (nid, "sollw", NF_FLOAT, 1, idim2,nvarid) 426 #endif 427 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 27, 428 . "Rayonnement IF a la surface") 429 ierr = NF_ENDDEF(nid) 430 #ifdef NC_DOUBLE 431 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,sollw) 432 #else 433 ierr = NF_PUT_VAR_REAL (nid,nvarid,sollw) 434 #endif 435 c 436 ierr = NF_REDEF (nid) 437 #ifdef NC_DOUBLE 438 ierr = NF_DEF_VAR (nid, "rain_f", NF_DOUBLE, 1, idim2,nvarid) 439 #else 440 ierr = NF_DEF_VAR (nid, "rain_f", NF_FLOAT, 1, idim2,nvarid) 441 #endif 442 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 21, 443 . "precipitation liquide") 444 ierr = NF_ENDDEF(nid) 445 #ifdef NC_DOUBLE 446 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,rain_fall) 447 #else 448 ierr = NF_PUT_VAR_REAL (nid,nvarid,rain_fall) 449 #endif 450 c 451 ierr = NF_REDEF (nid) 452 #ifdef NC_DOUBLE 453 ierr = NF_DEF_VAR (nid, "snow_f", NF_DOUBLE, 1, idim2,nvarid) 454 #else 455 ierr = NF_DEF_VAR (nid, "snow_f", NF_FLOAT, 1, idim2,nvarid) 456 #endif 457 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 20, 458 . "precipitation solide") 459 ierr = NF_ENDDEF(nid) 460 #ifdef NC_DOUBLE 461 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,snow_fall) 462 #else 463 ierr = NF_PUT_VAR_REAL (nid,nvarid,snow_fall) 464 #endif 465 c 466 DO nsrf = 1, nbsrf 467 IF (nsrf.LE.99) THEN 468 WRITE(str2,'(i2.2)') nsrf 469 ierr = NF_REDEF (nid) 470 #ifdef NC_DOUBLE 471 ierr = NF_DEF_VAR (nid,"RUG"//str2,NF_DOUBLE,1,idim2,nvarid) 472 #else 473 ierr = NF_DEF_VAR (nid,"RUG"//str2,NF_FLOAT,1,idim2,nvarid) 474 #endif 475 ierr = NF_PUT_ATT_TEXT (nid,nvarid,"title", 23, 476 . "rugosite de surface No."//str2) 477 ierr = NF_ENDDEF(nid) 478 ELSE 479 PRINT*, "Trop de sous-mailles" 480 CALL abort 481 ENDIF 482 #ifdef NC_DOUBLE 483 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,frugs(1,nsrf)) 484 #else 485 ierr = NF_PUT_VAR_REAL (nid,nvarid,frugs(1,nsrf)) 486 #endif 487 ENDDO 266 488 c 267 489 ierr = NF_REDEF (nid) … … 288 510 ierr = NF_ENDDEF(nid) 289 511 #ifdef NC_DOUBLE 290 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid, champhys)291 #else 292 ierr = NF_PUT_VAR_REAL (nid,nvarid, champhys)512 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zmea) 513 #else 514 ierr = NF_PUT_VAR_REAL (nid,nvarid,zmea) 293 515 #endif 294 516 c … … 301 523 ierr = NF_ENDDEF(nid) 302 524 #ifdef NC_DOUBLE 303 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid, champhys)304 #else 305 ierr = NF_PUT_VAR_REAL (nid,nvarid, champhys)306 #endif 307 525 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zstd) 526 #else 527 ierr = NF_PUT_VAR_REAL (nid,nvarid,zstd) 528 #endif 529 c 308 530 ierr = NF_REDEF (nid) 309 531 #ifdef NC_DOUBLE … … 314 536 ierr = NF_ENDDEF(nid) 315 537 #ifdef NC_DOUBLE 316 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid, champhys)317 #else 318 ierr = NF_PUT_VAR_REAL (nid,nvarid, champhys)319 #endif 320 538 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zsig) 539 #else 540 ierr = NF_PUT_VAR_REAL (nid,nvarid,zsig) 541 #endif 542 c 321 543 ierr = NF_REDEF (nid) 322 544 #ifdef NC_DOUBLE … … 327 549 ierr = NF_ENDDEF(nid) 328 550 #ifdef NC_DOUBLE 329 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid, champhys)330 #else 331 ierr = NF_PUT_VAR_REAL (nid,nvarid, champhys)332 #endif 333 551 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zgam) 552 #else 553 ierr = NF_PUT_VAR_REAL (nid,nvarid,zgam) 554 #endif 555 c 334 556 ierr = NF_REDEF (nid) 335 557 #ifdef NC_DOUBLE … … 340 562 ierr = NF_ENDDEF(nid) 341 563 #ifdef NC_DOUBLE 342 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid, champhys)343 #else 344 ierr = NF_PUT_VAR_REAL (nid,nvarid, champhys)345 #endif 346 564 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zthe) 565 #else 566 ierr = NF_PUT_VAR_REAL (nid,nvarid,zthe) 567 #endif 568 c 347 569 ierr = NF_REDEF (nid) 348 570 #ifdef NC_DOUBLE … … 353 575 ierr = NF_ENDDEF(nid) 354 576 #ifdef NC_DOUBLE 355 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid, champhys)356 #else 357 ierr = NF_PUT_VAR_REAL (nid,nvarid, champhys)358 #endif 359 577 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zpic) 578 #else 579 ierr = NF_PUT_VAR_REAL (nid,nvarid,zpic) 580 #endif 581 c 360 582 ierr = NF_REDEF (nid) 361 583 #ifdef NC_DOUBLE … … 366 588 ierr = NF_ENDDEF(nid) 367 589 #ifdef NC_DOUBLE 368 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid, champhys)369 #else 370 ierr = NF_PUT_VAR_REAL (nid,nvarid, champhys)371 #endif 372 590 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,zval) 591 #else 592 ierr = NF_PUT_VAR_REAL (nid,nvarid,zval) 593 #endif 594 c 373 595 ierr = NF_REDEF (nid) 374 596 #ifdef NC_DOUBLE … … 379 601 ierr = NF_ENDDEF(nid) 380 602 #ifdef NC_DOUBLE 381 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,champhys) 382 #else 383 ierr = NF_PUT_VAR_REAL (nid,nvarid,champhys) 603 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,rugsrel) 604 #else 605 ierr = NF_PUT_VAR_REAL (nid,nvarid,rugsrel) 606 #endif 607 c 608 ierr = NF_REDEF (nid) 609 #ifdef NC_DOUBLE 610 ierr = NF_DEF_VAR (nid, "TANCIEN", NF_DOUBLE, 1, idim3,nvarid) 611 #else 612 ierr = NF_DEF_VAR (nid, "TANCIEN", NF_FLOAT, 1, idim3,nvarid) 613 #endif 614 ierr = NF_ENDDEF(nid) 615 #ifdef NC_DOUBLE 616 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,t_ancien) 617 #else 618 ierr = NF_PUT_VAR_REAL (nid,nvarid,t_ancien) 619 #endif 620 c 621 ierr = NF_REDEF (nid) 622 #ifdef NC_DOUBLE 623 ierr = NF_DEF_VAR (nid, "QANCIEN", NF_DOUBLE, 1, idim3,nvarid) 624 #else 625 ierr = NF_DEF_VAR (nid, "QANCIEN", NF_FLOAT, 1, idim3,nvarid) 626 #endif 627 ierr = NF_ENDDEF(nid) 628 #ifdef NC_DOUBLE 629 ierr = NF_PUT_VAR_DOUBLE (nid,nvarid,q_ancien) 630 #else 631 ierr = NF_PUT_VAR_REAL (nid,nvarid,q_ancien) 384 632 #endif 385 633 c 386 634 ierr = NF_CLOSE(nid) 387 635 c 388 636 RETURN 389 390 637 END -
LMDZ.3.3/branches/rel-LF/libf/phylmd/interface_surf.F90
r112 r115 1000 1000 call cpl2gath(read_alb_sic, alb_new, klon, knon,iim,jjm, knindex) 1001 1001 endif 1002 1003 ! if (lafin) call quitcpl 1002 1004 1003 1005 END SUBROUTINE interfoce_cpl
Note: See TracChangeset
for help on using the changeset viewer.