[198] | 1 | c $Header |
---|
| 2 | subroutine read_dstoke(irec,zdtvr,ziadvtrac,ziadvtrac2) |
---|
| 3 | |
---|
| 4 | |
---|
| 5 | IMPLICIT NONE |
---|
| 6 | |
---|
| 7 | #include "netcdf.inc" |
---|
| 8 | #include "dimensions.h" |
---|
| 9 | #include "paramet.h" |
---|
| 10 | #include "comgeom.h" |
---|
| 11 | #include "comvert.h" |
---|
| 12 | |
---|
| 13 | |
---|
| 14 | integer ncidfd |
---|
| 15 | save ncidfd |
---|
| 16 | integer variddt,varididvt,varididvp |
---|
| 17 | save variddt,varididvt,varididvp |
---|
| 18 | real*4 dtv(1,1,1),adv2(1,1,1),adv(1,1,1) |
---|
| 19 | real zdtvr,ziadvtrac,ziadvtrac2 |
---|
| 20 | integer status,irec |
---|
| 21 | real rcode |
---|
| 22 | INTEGER epais(2), debut(2) |
---|
| 23 | |
---|
| 24 | if (irec .eq. 0) then |
---|
| 25 | |
---|
| 26 | ncidfd=NCOPN('defstoke.nc',NCNOWRIT,rcode) |
---|
| 27 | |
---|
| 28 | variddt=NCVID(ncidfd,'dtvr',rcode) |
---|
| 29 | print*,'ncidfd,variddt',ncidfd,variddt |
---|
| 30 | |
---|
| 31 | varididvt=NCVID(ncidfd,'istdyn',rcode) |
---|
| 32 | print*,'ncidfd,varididvt',ncidfd,varididvt |
---|
| 33 | |
---|
| 34 | varididvp=NCVID(ncidfd,'istphy',rcode) |
---|
| 35 | print*,'ncidfd,varididvp',ncidfd,varididvp |
---|
| 36 | |
---|
| 37 | c lecture de zdtvr et ziadvtrac |
---|
| 38 | |
---|
| 39 | epais(1) = 1 |
---|
| 40 | epais(2) = 1 |
---|
| 41 | debut(1) = 1 |
---|
| 42 | debut(2) = 1 |
---|
| 43 | |
---|
| 44 | status=NF_GET_VARA_REAL(ncidfd,variddt,debut,epais,dtv) |
---|
| 45 | zdtvr=dtv(1,1,1) |
---|
| 46 | |
---|
| 47 | status=NF_GET_VARA_REAL(ncidfd,varididvt,debut,epais,adv) |
---|
| 48 | ziadvtrac= adv(1,1,1) |
---|
| 49 | |
---|
| 50 | status=NF_GET_VARA_REAL(ncidfd,varididvp,debut,epais,adv2) |
---|
| 51 | ziadvtrac2= adv2(1,1,1) |
---|
| 52 | |
---|
| 53 | write(*,*) 'ds read_dstoke zdtvr = ', zdtvr |
---|
| 54 | write(*,*) 'ds read_dstoke ziadvtrac = ', ziadvtrac |
---|
| 55 | write(*,*) 'ds read_dstoke ziadvtrac2 = ', ziadvtrac2 |
---|
| 56 | |
---|
| 57 | c status=NF_CLOSE(ncidfd) |
---|
| 58 | |
---|
| 59 | else |
---|
| 60 | stop'Pas bon irec ne 0' |
---|
| 61 | endif |
---|
| 62 | |
---|
| 63 | return |
---|
| 64 | |
---|
| 65 | end |
---|
| 66 | |
---|