Changeset 5270 for LMDZ6/trunk/libf/phylmd/Dust/read_surface.f90
- Timestamp:
- Oct 24, 2024, 1:55:38 PM (37 hours ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/libf/phylmd/Dust/read_surface.f90
r5268 r5270 10 10 USE mod_phys_lmdz_para 11 11 USE iophy 12 USE netcdf, ONLY: nf90_ get_var12 USE netcdf, ONLY: nf90_inq_varid,nf90_noerr,nf90_get_var,nf90_nowrite,nf90_inq_varid,nf90_open 13 13 IMPLICIT NONE 14 15 INCLUDE "netcdf.inc"16 14 INCLUDE "dimensions.h" 17 15 INCLUDE "paramet.h" … … 31 29 real surfa_glo(klon_glo,5) 32 30 ! 33 integer ncid 34 integer varid 35 real rcode 31 integer ncid, varid, rcode 36 32 integer start(2),count(2),status 37 33 integer i,j,l,ig … … 43 39 real, dimension(jjp1) :: lats 44 40 real, dimension(nbp_lat) :: lats_glo 45 real :: rcode246 41 integer, dimension(1) :: startj,endj 47 42 !JE20140526>> … … 50 45 51 46 print*,'Lecture du fichier donnees_lisa.nc' 52 ncid= NCOPN('donnees_lisa.nc',NCNOWRIT,rcode)47 ncid=nf90_open('donnees_lisa.nc',nf90_nowrite,rcode) 53 48 54 49 !JE20140526<<: check if are inversed or not the latitude grid in donnes_lisa … … 62 57 if (i==4) aux4s='Latu' 63 58 if (i==5) aux4s='latU' 64 status = NF_INQ_VARID(ncid, aux4s, rcode)59 status = nf90_inq_varid(ncid, aux4s, rcode) 65 60 ! print *,'stat,i',status,i,outcycle,aux4s 66 ! print *,'ifclause',status.NE. NF_NOERR,outcycle == .false.67 IF ((.not.(status.NE. NF_NOERR) ).and.( .not. outcycle )) THEN61 ! print *,'ifclause',status.NE. nf90_noerr ,outcycle == .false. 62 IF ((.not.(status.NE. nf90_noerr) ).and.( .not. outcycle )) THEN 68 63 outcycle=.true. 69 64 latstr=aux4s … … 73 68 ! endj(1)=jjp1 74 69 endj(1)=nbp_lat 75 varid= NCVID(ncid,latstr,rcode)70 varid=nf90_inq_varid(ncid,latstr,rcode) 76 71 77 72 status = nf90_get_var(ncid, varid, lats_glo, startj, endj) 78 73 ! print *,latstr,varid,status,jjp1,rcode 79 ! IF (status .NE. NF_NOERR) print*,'NOOOOOOO'74 ! IF (status .NE. nf90_noerr) print*,'NOOOOOOO' 80 75 ! print *,lats 81 76 !stop … … 90 85 varname=trim(name)//str1 91 86 print*,'lecture variable:',varname 92 varid= NCVID(ncid,trim(varname),rcode)93 ! varid= NCVID(ncid,varname,rcode)87 varid=nf90_inq_varid(ncid,trim(varname),rcode) 88 ! varid=nf90_inq_varid(ncid,varname,rcode) 94 89 95 90 ! dimensions pour les champs scalaires et le vent zonal
Note: See TracChangeset
for help on using the changeset viewer.