33 implicit real*8(a-h,o-z)
34 character*200 fnamei,fnameo
36 real*4 zrec(100000),nw,ne,sw,se,zmin,zmax
37 integer*2 srec(100000)
38 equivalence(hrec(1),zrec(1),srec(1))
43 write(6,*)
'Program gabs - converts a grid to ABS values' 46 2
format(
'Enter the input grid file name: ',$)
48 open(lin,file=fnamei,status=
'old',form=
'unformatted')
51 3
format(
'Enter the output grid file name: ',$)
53 open(lout,file=fnameo,status=
'new',form=
'unformatted')
58 read(lin) glamn,glomn,dgla,dglo,nla,nlo,ikind
59 write(lout) glamn,glomn,dgla,dglo,nla,nlo,ikind
65 read(lin)(hrec(i),i=1,nlo)
67 hrec(i) = int(abs(hrec(i)))
69 write(lout)(hrec(i),i=1,nlo)
72 elseif(ikind.eq.1)
then 74 read(lin) (zrec(i),i=1,nlo)
76 zrec(i) = abs(zrec(i))
78 write(lout)(zrec(i),i=1,nlo)
81 elseif(ikind.eq.-1)
then 83 read(lin) (srec(i),i=1,nlo)
85 srec(i) = int(abs(srec(i)))
87 write(lout)(srec(i),i=1,nlo)
90 elseif(ikind.eq.2)
then 92 read(lin) (srec(i),i=1,nlo)
94 srec(i) = int(abs(srec(i)))
96 write(lout)(srec(i),i=1,nlo)
program gabs
Part of the NADCON5 NADCON5 Core Library , Convert values in a *.b grid to absolute value...