Changeset 5068
- Timestamp:
- Jul 18, 2024, 12:14:04 PM (7 weeks ago)
- Location:
- LMDZ6/trunk/libf
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/libf/dyn3d/dynredem_mod.F90
r5060 r5068 94 94 ! 95 95 !=============================================================================== 96 USE lmdz_netcdf, ONLY: NF90_FORMAT 96 97 IMPLICIT NONE 97 98 !=============================================================================== … … 102 103 CHARACTER(LEN=*), OPTIONAL, INTENT(IN) :: units 103 104 !=============================================================================== 104 #ifdef NC_DOUBLE 105 CALL err(NF90_DEF_VAR(ncid,var,NF90_DOUBLE,did,nvarid),"inq",var) 106 #else 107 CALL err(NF90_DEF_VAR(ncid,var,NF90_FLOAT ,did,nvarid),"inq",var) 108 #endif 105 CALL err(NF90_DEF_VAR(ncid,var,NF90_FORMAT,did,nvarid),"inq",var) 109 106 IF(title/="") CALL err(NF90_PUT_ATT(ncid,nvarid,"title",title),var) 110 107 IF(PRESENT(units)) CALL err(NF90_PUT_ATT(ncid,nvarid,"units",units),var) -
LMDZ6/trunk/libf/dyn3d/guide_mod.F90
r5067 r5068 9 9 !======================================================================= 10 10 11 USE getparam, only: ini_getparam, fin_getparam, getpar11 USE getparam, ONLY: ini_getparam, fin_getparam, getpar 12 12 USE Write_Field 13 use netcdf, only: nf90_nowrite, nf90_open, nf90_inq_varid, nf90_close, & 14 nf90_inq_dimid, nf90_inquire_dimension 15 use pres2lev_mod, only: pres2lev 13 USE lmdz_netcdf, ONLY: nf90_nowrite, nf90_open, nf90_inq_varid, nf90_close, & 14 nf90_inq_dimid, nf90_inquire_dimension, nf_put_var_rd, nf90_float, nf90_def_var, & 15 nf_create, nf_def_dim, nf_open, nf_unlimited, nf_write, nf_enddef, nf_redef, & 16 nf_close, nf_inq_varid, nf_put_vara_rd, nf90_get_var, nf90_noerr, nf_clobber, & 17 nf_64bit_offset, nf_inq_dimid, nf_inq_dimlen 18 USE pres2lev_mod, ONLY: pres2lev 16 19 17 20 IMPLICIT NONE … … 77 80 INCLUDE "dimensions.h" 78 81 INCLUDE "paramet.h" 79 INCLUDE "netcdf.inc"80 82 81 83 INTEGER :: error,ncidpl,rid,rcod … … 1089 1091 !======================================================================= 1090 1092 SUBROUTINE guide_read(timestep) 1091 1092 use netcdf, only: NF90_GET_VAR, nf90_noerr1093 1094 1093 IMPLICIT NONE 1095 1094 … … 1389 1388 !======================================================================= 1390 1389 SUBROUTINE guide_read2D(timestep) 1391 1392 use netcdf, only: nf90_get_var, nf90_noerr1393 1394 1390 IMPLICIT NONE 1395 1391 … … 1653 1649 USE comconst_mod, ONLY: pi 1654 1650 USE comvert_mod, ONLY: presnivs 1655 use netcdf95, only: nf95_def_var, nf95_put_var 1656 use netcdf, only: nf90_float, nf90_def_var 1657 1651 USE netcdf95, ONLY: nf95_def_var, nf95_put_var 1652 1658 1653 IMPLICIT NONE 1659 1654 1660 1655 INCLUDE "dimensions.h" 1661 1656 INCLUDE "paramet.h" 1662 INCLUDE "netcdf.inc"1663 1657 INCLUDE "comgeom2.h" 1664 1658 … … 1713 1707 1714 1708 ! Enregistrement des variables dimensions 1715 #ifdef NC_DOUBLE 1716 ierr = NF_PUT_VAR_DOUBLE(nid,vid_lonu,rlonu*180./pi) 1717 ierr = NF_PUT_VAR_DOUBLE(nid,vid_lonv,rlonv*180./pi) 1718 ierr = NF_PUT_VAR_DOUBLE(nid,vid_latu,rlatu*180./pi) 1719 ierr = NF_PUT_VAR_DOUBLE(nid,vid_latv,rlatv*180./pi) 1720 ierr = NF_PUT_VAR_DOUBLE(nid,vid_lev,presnivs) 1721 ierr = NF_PUT_VAR_DOUBLE(nid,vid_cu,cu) 1722 ierr = NF_PUT_VAR_DOUBLE(nid,vid_cv,cv) 1723 ierr = NF_PUT_VAR_DOUBLE(nid,vid_au,alpha_u) 1724 ierr = NF_PUT_VAR_DOUBLE(nid,vid_av,alpha_v) 1725 #else 1726 ierr = NF_PUT_VAR_REAL(nid,vid_lonu,rlonu*180./pi) 1727 ierr = NF_PUT_VAR_REAL(nid,vid_lonv,rlonv*180./pi) 1728 ierr = NF_PUT_VAR_REAL(nid,vid_latu,rlatu*180./pi) 1729 ierr = NF_PUT_VAR_REAL(nid,vid_latv,rlatv*180./pi) 1730 ierr = NF_PUT_VAR_REAL(nid,vid_lev,presnivs) 1731 ierr = NF_PUT_VAR_REAL(nid,vid_cu,cu) 1732 ierr = NF_PUT_VAR_REAL(nid,vid_cv,cv) 1733 ierr = NF_PUT_VAR_REAL(nid,vid_au,alpha_u) 1734 ierr = NF_PUT_VAR_REAL(nid,vid_av,alpha_v) 1735 #endif 1709 ierr = nf_put_var_rd(nid,vid_lonu,rlonu*180./pi) 1710 ierr = nf_put_var_rd(nid,vid_lonv,rlonv*180./pi) 1711 ierr = nf_put_var_rd(nid,vid_latu,rlatu*180./pi) 1712 ierr = nf_put_var_rd(nid,vid_latv,rlatv*180./pi) 1713 ierr = nf_put_var_rd(nid,vid_lev,presnivs) 1714 ierr = nf_put_var_rd(nid,vid_cu,cu) 1715 ierr = nf_put_var_rd(nid,vid_cv,cv) 1716 ierr = nf_put_var_rd(nid,vid_au,alpha_u) 1717 ierr = nf_put_var_rd(nid,vid_av,alpha_v) 1736 1718 call nf95_put_var(nid, varid_alpha_t, alpha_t) 1737 1719 call nf95_put_var(nid, varid_alpha_q, alpha_q) … … 1807 1789 END SELECT 1808 1790 1809 1810 #ifdef NC_DOUBLE 1811 ierr = NF_PUT_VARA_DOUBLE(nid,varid,start,count,field2) 1812 #else 1813 ierr = NF_PUT_VARA_REAL(nid,varid,start,count,field2) 1814 #endif 1815 1791 ierr = nf_put_vara_rd(nid,varid,start,count,field2) 1816 1792 ierr = NF_CLOSE(nid) 1817 1793
Note: See TracChangeset
for help on using the changeset viewer.