Changeset 3694
- Timestamp:
- Mar 18, 2025, 3:52:13 PM (5 months ago)
- Location:
- trunk/LMDZ.PLUTO
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.PLUTO/deftank/xios/file_def_physics.xml
r3692 r3694 29 29 </field_group> 30 30 31 <field_group operation=" instant"31 <field_group operation="once" 32 32 grid_ref="altitude_grid" 33 33 freq_op="1ts"> … … 44 44 freq_op="1ts"> 45 45 <field field_ref="area" operation="once" /> 46 <field field_ref="phisfi" operation="once" /> 46 47 <field field_ref="ps" enabled="true" /> 47 48 <field field_ref="ISR" enabled="true" /> -
trunk/LMDZ.PLUTO/libf/phypluto/physiq_mod.F90
r3692 r3694 2129 2129 call write_output("ps","Surface pressure","Pa",ps) 2130 2130 call write_output("emis","Emissivity","",emis) 2131 call write_output('phisfi','Surface Geopotential','m2s-2',phisfi) 2131 2132 if (grid_type == regular_lonlat) then 2132 2133 call write_output("area","Mesh area","m2", & … … 2168 2169 call write_output("zzlay","Midlayer altitude", "m",zzlay(:,:)) 2169 2170 call write_output("zzlev","Interlayer altitude", "m",zzlev(:,1:nlayer)) 2170 !call write_output('pphi','Geopotential','',pphi)2171 call write_output('pphi','Geopotential','m2s-2',pphi) 2171 2172 2172 2173 call write_output("temperature","temperature","K",zt) -
trunk/LMDZ.PLUTO/util/zrecast_plut.F90
r3623 r3694 356 356 ierr=NF_INQ_DIMID(infid,"time",tmpdimid) 357 357 if (ierr.ne.NF_NOERR) then 358 stop "Error: Failed to get londimension ID"359 else360 ierr=NF_INQ_ VARID(infid,"time",tmpvarid)358 write(*,*) "Could not get time dimension ID" 359 write(*,*) " looking for time_counter dimension instead... " 360 ierr=NF_INQ_DIMID(infid,"time_counter",tmpdimid) 361 361 if (ierr.ne.NF_NOERR) then 362 stop "Error: Failed to get time ID"362 stop "Error: Failed to get time/Time/time_counter dimension ID" 363 363 else 364 ierr=NF_INQ_ DIMLEN(infid,tmpdimid,timelength)364 ierr=NF_INQ_VARID(infid,"time",tmpvarid) 365 365 if (ierr.ne.NF_NOERR) then 366 stop "Error: Failed to get time length" 366 ierr=NF_INQ_VARID(infid,"time_instant",tmpvarid) 367 endif 368 if (ierr.ne.NF_NOERR) then 369 stop "Error: Failed to get time ID" 367 370 else 368 allocate(time(timelength),stat=ierr) 369 if (ierr.ne.0) then 370 write(*,*) "Error: Failed to allocate time(timelength)" 371 write(*,*) " timelength=",timelength 372 stop 373 endif 374 ierr=NF_GET_VAR_REAL(infid,tmpvarid,time) 371 ierr=NF_INQ_DIMLEN(infid,tmpdimid,timelength) 375 372 if (ierr.ne.NF_NOERR) then 376 stop "Error: Failed reading time" 373 stop "Error: Failed to get time length" 374 else 375 allocate(time(timelength),stat=ierr) 376 if (ierr.ne.0) then 377 write(*,*) "Error: Failed to allocate time(timelength)" 378 write(*,*) " timelength=",timelength 379 stop 380 endif 381 ierr=NF_GET_VAR_REAL(infid,tmpvarid,time) 382 if (ierr.ne.NF_NOERR) then 383 stop "Error: Failed reading time" 384 endif 377 385 endif 378 386 endif … … 449 457 ierr=NF_INQ_VARID(infid,"aps",tmpvarid) 450 458 if (ierr.ne.NF_NOERR) then 451 stop "Error: Failed to get aps ID" 459 write(*,*) "Problem: Could not find aps" 460 infile2="start.nc" 461 write(*,*) " Trying file ",trim(infile2) 462 ierr=NF_OPEN(infile2,NF_NOWRITE,infid2) 463 if (ierr.ne.NF_NOERR) then 464 write(*,*) "Error: Could not open that file either" 465 stop "Might as well stop here" 466 endif 452 467 else 453 allocate(aps(altlength),stat=ierr) 454 if (ierr.ne.0) then 455 write(*,*) "Error: Failed to allocate aps(altlength)" 456 write(*,*) " altlength=",altlength 457 stop 458 endif 459 ierr=NF_GET_VAR_REAL(infid,tmpvarid,aps) 460 if (ierr.ne.NF_NOERR) then 461 stop "Error: Failed reading aps" 462 endif 468 ! reopen file using infid2 469 ierr=NF_OPEN(infile,NF_NOWRITE,infid2) 463 470 endif 471 472 ierr=NF_INQ_VARID(infid2,"aps",tmpvarid) 473 if (ierr.ne.NF_NOERR) then 474 stop "Error: Failed to get aps ID" 475 endif 476 477 allocate(aps(altlength),stat=ierr) 478 if (ierr.ne.0) then 479 write(*,*) "Error: Failed to allocate aps(altlength)" 480 write(*,*) " altlength=",altlength 481 stop 482 endif 483 ierr=NF_GET_VAR_REAL(infid2,tmpvarid,aps) 484 if (ierr.ne.NF_NOERR) then 485 stop "Error: Failed reading aps" 486 endif 487 488 write(*,*) 'OK, got aps' 489 ierr=NF_CLOSE(infid2) 464 490 465 491 ! hybrid coordinate bps 466 492 ierr=NF_INQ_VARID(infid,"bps",tmpvarid) 467 493 if (ierr.ne.NF_NOERR) then 468 stop "Error: Failed to get bps ID" 494 write(*,*) "Problem: Could not find bps" 495 infile2="start.nc" 496 write(*,*) " Trying file ",trim(infile2) 497 ierr=NF_OPEN(infile2,NF_NOWRITE,infid2) 498 print*, "here" 499 if (ierr.ne.NF_NOERR) then 500 write(*,*) "Error: Could not open that file either" 501 stop "Might as well stop here" 502 endif 469 503 else 470 allocate(bps(altlength),stat=ierr) 471 if (ierr.ne.0) then 472 write(*,*) "Error: Failed to allocate bps(altlength)" 473 write(*,*) " altlength=",altlength 474 stop 475 endif 476 ierr=NF_GET_VAR_REAL(infid,tmpvarid,bps) 477 if (ierr.ne.NF_NOERR) then 478 stop "Error: Failed reading bps" 479 endif 504 ! reopen file using infid2 505 ierr=NF_OPEN(infile,NF_NOWRITE,infid2) 480 506 endif 507 508 ierr=NF_INQ_VARID(infid2,"bps",tmpvarid) 509 if (ierr.ne.NF_NOERR) then 510 stop "Error: Failed to get bps ID" 511 endif 512 513 allocate(bps(altlength),stat=ierr) 514 if (ierr.ne.0) then 515 write(*,*) "Error: Failed to allocate bps(altlength)" 516 write(*,*) " altlength=",altlength 517 stop 518 endif 519 ierr=NF_GET_VAR_REAL(infid2,tmpvarid,bps) 520 if (ierr.ne.NF_NOERR) then 521 stop "Error: Failed reading bps" 522 endif 523 524 write(*,*) 'OK, got bps' 525 ierr=NF_CLOSE(infid2) 481 526 endif !of if (.not.have_sigma) 482 527 … … 498 543 if (ierr.ne.NF_NOERR) then 499 544 write(*,*) "Problem: Could not find/open that file" 500 infile2=" phisinit.nc"545 infile2="startfi.nc" 501 546 write(*,*) " Trying file ",trim(infile2) 502 547 ierr=NF_OPEN(infile2,NF_NOWRITE,infid2) … … 510 555 ierr=NF_INQ_VARID(infid2,"phisinit",tmpvarid) 511 556 if (ierr.ne.NF_NOERR) then 512 stop "Error: Failed to get phisinit ID" 557 ierr=NF_INQ_VARID(infid2,"phisfi",tmpvarid) 558 if (ierr.ne.NF_NOERR) then 559 stop "Error: Failed to get phisinit/phisfi ID" 560 endif 513 561 endif 514 562 ! Get physinit … … 773 821 endif 774 822 775 ierr=NF_INQ_VARID(infid,"temp ",tmpvarid)823 ierr=NF_INQ_VARID(infid,"temperature",tmpvarid) 776 824 if (ierr.ne.NF_NOERR) then 777 825 ! stop "Error: Failed to get temp ID" … … 779 827 ierr=NF_INQ_VARID(infid,"t",tmpvarid) 780 828 if (ierr.ne.NF_NOERR) then 781 ! stop "Error: Failed to get t ID" 782 ierr=NF_INQ_VARID(infid,"temperature",tmpvarid) 783 if (ierr.ne.NF_NOERR) then 784 stop "Error: Failed to get temperature ID" 785 endif 829 stop "Error: Failed to get t ID" 786 830 else 787 831 ierr=NF_GET_VAR_REAL(infid,tmpvarid,temp) … … 1322 1366 if (ierr.ne.NF_NOERR) then 1323 1367 write(*,*) "Error failed to copy long_name attribute:",trim(text) 1324 stop " "1368 stop " " 1325 1369 endif 1326 1370 endif … … 1336 1380 if (ierr.ne.NF_NOERR) then 1337 1381 write(*,*) "Error failed to copy units attribute:",trim(text) 1338 stop " "1382 stop " " 1339 1383 endif 1340 1384 endif
Note: See TracChangeset
for help on using the changeset viewer.