#!/bin/ksh integer count=1 while ((count <= 50)) do echo now running simulation number $count uncompress sisim.$count.out.z cp sisim.$count.out sisim.out compress sisim.$count.out ./gamfil mv gam.res gam.$count.res ((count=count+1)) doneAttachment III: Software routine documentation: cr8_50_feat.ksh UNIX shell
#!/bin/ksh integer count=1 while ((count <= 50)) do echo NOW RUNNING SIMULATION number $count uncompress ../SISIM/SET1/sisim.$count.out.Z cp ../SISIM/SET1/sisim.$count.out ../SISIM/SET1/sisim.out compress ../SISIM/SET1/sisim.$count.out /home/samcken_c/programs/ellipsim/ellip2/ellip2_MC ./combine ./gamfil mv gam.res gam.$count.res ./modgeom cp temp ellip2.par ((count=count+1)) doneAttachment IV: Software routine documentation sisim, Version 2.0 The GSLIB software routine sisim (version 2.0) is baselined by another organization. The Software activity Number is: LBNL-1999-098. The Software Name and Version is: GSLIB V2.0MSISIMV2.0, and the Software Tracking Number is: 10098-2.0MSISIMV2.0-00. An OCRWM Software User Request for application of sisim version 2.0 in this AMR from the software configuration management system is on file with the Software Configuration Secretariat. For this work, sisim version 2.0 was run on both a Dell Latitude Pentium MMX laptop (DE&S Property number 0010037) and on a Gateway 2000 90MHz Pentium (Serial number 2602178). These simulations were conducted at the Duke Engineering and Services office in Albuquerque, NM. The routine was an appropriate for this use, and it was used only within the range of validation as specified in Deutsch and Journel (1998)
Attachment V: Software routine documentation ellip2_MC FORTRAN Routine (Version 1.0) The ellip2_MC software routine is used to generate the locations and shape of the large-scale high permeability features used in the "enhanced" permeability models. The ellip2_MC routine reads in a parameter file (ellip2.par) and generates an output file that is a series of zeros and ones in a three-dimensional matrix. The ones represent the locations of the high permeability features and the zeroes represent the locations of the background permeability material. This output file is read as input by the combine.c software routine. The second output file is ellip2.dbg and this file provides information on the result of the simulation including the total number of features generated, the orientation and radius of each feature and the location of the center of each feature.. The ellip2_MC software routine is written in the FORTRAN programming language on a Sun Ultra Sparc Server. The version of the FORTRAN compiler is 4.2 and the operating system is Solaris 2.7. This routine is composed of six separate source code files: acorni.f, ellip2_MC.f, expon.f, chknam.f, gcumf, sqdist.f and setrot.f. The functionality of the ellip2_MC software routine is tested by making one run with an input parameter file from this AMR but with different random number seeds. Three specific outputs of the ellip2_MC software routine are tested here: 1) the ability of the routine to produce the requested proportion of the domain that lies within the high permeability zones; 2) the ability of the code to reproduce the specified distribution of high permeability feature radii; and 3) the ability of the routine to produce the specified distribution of high permeability feature orientations. The input parameter file, ellip2.par is shown below. This file as used for the test run of the ellip2_MC routine.
Parameters for ELLIP2 *********************** START OF PARAMETERS: ellip2.out \file for output realizations 1 \number of realizations 125 2.0 4.0 \nx,xmn,xsiz 125 2.0 4.0 \ny,ymn,ysiz 25 1.0 2.0 \nz,zmn,zsiz 1 \debugging level 68869 \random 0.0200 \target proportion (in ellipsoids) 1 \number of ellipsoid sets to model 600.0 4.0 600.0 1 1 \SET 1 radius[1,2,3], anis1, anis2 (anis1&2 can only be 1 for now) 1 600.0 70.0 1.0 1.0 \SET 1 rad_par[1,2,3,4],weight 00.0 0.0 0.0 \SET 1 angle[1,2,3] 1 0.0 15.0 52.0 \SET 1 angpar[1,2,3,4] ellip2_1.dbg \file for SET 1 debugging outputCHECK (proportion, radii, orientation): The output file, ellip2.out consists of a three line header followed by 390,625 lines containing either a zero or a one This file is examined to determine the proportion of ones in the domain. The target proportion as indicated above in the input file is 0.0200. The resulting proportion for the test run of ellip2_MC is 0.0213. The other output file produced by ellip2_MC is called ellip2.dbg and this file consists of a nine line header followed by nine columns of data. There is one line for every feature simulated within a virtual domain that is much larger than the actual model domain. This larger virtual domain is used such that features with center outside of the model domain can still be simulated and portions of these features may show up within the model domain. The nine columns of data are the X, Y, and Z coordinates for the center of the feature, the radius of the feature, the orientation of the feature and two debugging flags. In order to check the reproduction of the distributions specified in the parameter file, the mean and the standard deviation for the radius and the orientation of all simulated features are calculated and compared to the specified values in the ellip2.par file above. For the radius, the specified mean is 600.0 and the specified standard deviation is 70.0. A total of 160 features were simulated. The mean of the simulated values in the ellip2.dbg file is 600.66 and the standard deviation is 64.04. The specified values for the orientation are a mean of 0.0 and a standard deviation of 15.0. The actual simulated values produce a mean and standard deviation of 0.18 and 16.63 as calculated across all 160 features. RESULTS OF TESTING The three checks done to test the ellip2_MC software routine confirmed that the routine creates the correct proportion of features within the domain and gives these features the correct radii and orientations as defined in the parameter file. This routine is run in a stochastic mode. Each different random seed number in the input parameter file will produce slightly different results. Therefore the results in any one simulation will not match the input target values exactly. In this case, all of the outputs are within plus or minus 11 percent of the input values and this is deemed to be close enough for the purpose of this AMR. The results of these checks prove that the required functionality of the routine works within the range of the routine design. SOURCE CODE:
double precision function acorni(idum) c----------------------------------------------------------------------- c c Fortran implementation of ACORN random number generator of order less c than or equal to 12 (higher orders can be obtained by increasing the c parameter value MAXORD). c c c NOTES: 1. The variable idum is a dummy variable. The common block c IACO is used to transfer data into the function. c c 2. Before the first call to ACORN the common block IACO must c be initialised by the user, as follows. The values of c variables in the common block must not subsequently be c changed by the user. c c KORDEI - order of generator required ( must be =< MAXORD) c c MAXINT - modulus for generator, must be chosen small c enough that 2*MAXINT does not overflow c c ixv(1) - seed for random number generator c require 0 < ixv(1) < MAXINT c c (ixv(I+1),I=1,KORDEI) c - KORDEI initial values for generator c require 0 =< ixv(I+1) < MAXINT c c 3. After initialisation, each call to ACORN generates a single c random number between 0 and 1. c c 4. An example of suitable values for parameters is c c KORDEI = 10 c MAXINT = 2**30 c ixv(1) = an odd integer in the (approximate) range c (0.001 * MAXINT) to (0.999 * MAXINT) c ixv(I+1) = 0, I=1,KORDEI c c c c Author: R.S.Wikramaratna, Date: October 1990 c A.E.A. Petroleum Services c Winfrith, Dorchester, c Dorset, DT2 8DH, United Kingdom c----------------------------------------------------------------------- implicit double precision (a-h,o-z) parameter (KORDEI=12,MAXOP1=KORDEI+1,MAXINT=2**30) common/iaco/ ixv(MAXOP1) do i=1,KORDEI ixv(i+1)=(ixv(i+1)+ixv(i)) if(ixv(i+1).ge.MAXINT) ixv(i+1)=ixv(i+1)-MAXINT end do acorni=dble(ixv(KORDEI+1))/MAXINT return end program ellip2 C%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% C % C Copyright (C) 1995 Stanford Center for Reservoir Forecasting. All % C rights reserved. Distributed with: C.V. Deutsch and A.G. Journel. % C ``GSLIB: Geostatistical Software Library and User's Guide,'' Oxford % C University Press, New York, 1995. (Second Edition) % C % C The programs in GSLIB are distributed in the hope that they will be % C useful, but WITHOUT ANY WARRANTY. No author or distributor accepts % C responsibility to anyone for the consequences of using them or for % C whether they serve any particular purpose or work at all, unless he % C says so in writing. Everyone is granted permission to copy, modify % C and redistribute the programs in GSLIB, but only under the condition % C that this notice and the above copyright notice remain intact. % C % C%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% c----------------------------------------------------------------------- c c Boolean Simulation of Ellipsoids c ******************************** c c The program is executed with no command line arguments. The user c will be prompted for the name of a parameter file. The parameter c file is described in the documentation (see the example ellipsim.par) c and should contain the following information: c c The output file will be a GEOEAS file containing the simulated integer c code ordered by x, y, and then simulation. c c c c Original: C.V. Deutsch Date: October 1991 c----------------------------------------------------------------------- c MODIFIED by Sean A. McKenna Date: January 1999 c c Adding capability to draw the radii and orientations from a c statistical distribution rather than just as a single value c Distributions to be used include power-law, negative exponential c and log-normal for the radii and gaussian for the orientation. c c March 1999 c Adding triangular distribution option to the variability in the c azimuth of the features c c Questions: Rather have constant radii or constant anisotropy? c currently the latter c Input is way too confusing!!! c Where do first three entries in the debug file c come from c Seperate debug files for each set of features? c c c----------------------------------------------------------------------- parameter(MAXXYZ = 5000000, MAXELP = 5) parameter(KORDEI=12,MAXOP1=KORDEI+1,MAXINT=2**30,MAXROT=MAXELP, + EPSLON=1.0e-10,VERSION = 2.000) c c Variable declaration: c real aa(MAXELP),anis1(MAXELP),anis2(MAXELP),ang1(MAXELP), + ang2(MAXELP),ang3(MAXELP),wt(MAXELP),tmp1(MAXELP), + lpar2(MAXELP),lpar3(MAXELP),lpar4(MAXELP), + apar2(MAXELP),apar3(MAXELP),apar4(MAXELP), + tmp2(MAXELP),atmp(MAXELP) real*8 rotmat(MAXROT,3,3),sdist,sqdist integer apar1(MAXELP),lpar1(MAXELP),sim(MAXXYZ),dbglvl integer anflg1(MAXELP),anflg2(MAXELP),t_flg character outfl*40,str*40,dbg1*40,dbg2*40,dbg3*40,dbg4*40,dbg5*40 logical testfl data ldbg1/1/,ldbg2/2/,ldbg3/3/,ldbg4/4/,ldbg5/5/ data lin/8/,lout/9/,nvec/5/ c c For random number generator: c real*8 acorni common /iaco/ ixv(MAXOP1) data ixv/MAXOP1*0.0/ c c Note VERSION number: c write(*,9999) VERSION 9999 format(/' ELLIPSIM Version: ',f5.3/) c c Get the name of the parameter file - try the default name if no input: c c write(*,*) 'Which parameter file do you want to use?' c read (*,'(a40)') str c if(str(1:1).eq.' ')str='ellip2.par ' c inquire(file=str,exist=testfl) c if(.not.testfl) then c write(*,*) 'ERROR - the parameter file does not exist,' c write(*,*) ' check for the file and try again ' c stop c endif c open(lin,file=str,status='OLD') c SAM 3/15/99 Don;t inquire for file name open(lin,file='ellip2.par',status='OLD') c c Find Start of Parameters: c 1 read(lin,'(a4)',end=99) str(1:4) if(str(1:4).ne.'STAR') go to 1 c c Read Input Parameters: c write(*,*) ' Starting to read input parameters' read(lin,'(a40)',err=99) outfl call chknam(outfl,40) write(*,*) ' output file: ',outfl read(lin,*,err=99) nsim write(*,*) ' number of realizations = ',nsim read(lin,*,err=99) nx,xmn,xsiz write(*,*) ' nx, xmn, and xsiz = ',nx,xmn,xsiz read(lin,*,err=99) ny,ymn,ysiz write(*,*) ' ny, ymn, and ysiz = ',ny,ymn,ysiz read(lin,*,err=99) nz,zmn,zsiz write(*,*) ' nz, zmn, and zsiz = ',nz,zmn,zsiz read(lin,*,err=99) dbglvl write(*,*) ' debugging level is: ', dbglvl read(lin,*,err=99) ixv(1) write(*,*) ' random number seed = ',ixv(1) do i=1,10000 zz = real(acorni(idum)) end do read(lin,*,err=99) targprop write(*,*) ' target proportion = ',targprop targprop = targprop * nx * ny * nz read(lin,*,err=99) nnelp write(*,*) ' number of ellipsoid sets = ', nnelp sumwt = 0.0 do nelp=1,nnelp read(lin,*,err=98) aa(nelp),tmp1(nelp),tmp2(nelp), + anflg1(nelp), anflg2(nelp) write(*,*) ' radius & aniso flags for set ', nelp, ' are ', + aa(nelp),anflg1(nelp), anflg2(nelp) read(lin,*,err=98) lpar1(nelp),lpar2(nelp),lpar3(nelp), + lpar4(nelp),wt(nelp) write(*,*) ' radius params and wt for set ', nelp, ' are ', + lpar1(nelp),lpar2(nelp),lpar3(nelp),lpar4(nelp),wt(nelp) if (lpar1(nelp) .eq. 1) then write(*,*) ' normal length distribution' endif if (lpar1(nelp) .eq. 2) then write(*,*) ' lognormal length distribution' endif if (lpar1(nelp) .eq. 3) then write(*,*), ' exponential length distribution' if (lpar2(nelp) .le. 0.0) then write (*,*) ' you must specify b greater than zero for' write (*,*) ' an exponential distribution ' write (*,*) ' ' stop end if end if if (lpar1(nelp) .eq. 4) then write(*,*) ' Pareto length distribution' if (lpar2(nelp) .le. 0.0) then write (*,*) ' you must specify a greater than zero for' write (*,*) ' a Pareto distribution ' write (*,*) ' ' stop end if if (lpar3(nelp) .le. 0.0) then write (*,*) ' you must specify c greater than zero for' write (*,*) ' a Pareto distribution ' write (*,*) ' ' stop end if end if if (lpar1(nelp) .eq. 5) then write(*,*) ' power-law length distribution' if (lpar2(nelp) .le. 0.0) then write (*,*) ' you must specify b greater than zero for' write (*,*) ' a power-law distribution' write (*,*) ' ' stop end if end if if (lpar1(nelp) .eq. 6) then write(*,*) ' truncated power-law length distribution' write(*,*) ' NOTE: the power is hard wired to 2.0!! ' if (lpar3(nelp) .le. lpar2(nelp)) then write (*,*) ' you must specify rmin less than rmax for' write(*,*) ' truncated power-law distribution' endif endif read(lin,*,err=98) ang1(nelp),ang2(nelp),ang3(nelp) write(*,*) ' angle for set', nelp, ' is ', + ang1(nelp) read(lin,*,err=98) apar1(nelp),apar2(nelp),apar3(nelp), + apar4(nelp) if (apar1(nelp) .eq. 1) then write(*,*) ' You have specified normally distributed ' write(*,*) ' azimuths about a mean of ', apar2(nelp) else if (apar1(nelp) .eq. 1) then write(*,*) ' You have specified trianglular distributed ' write(*,*) ' deviations about azimuth of ', ang1(nelp) write(*,*) ' Min, Mode and Max are: ', apar2(nelp), + apar2(nelp), apar4(nelp) endif if (nelp .eq. 1) then read(lin,'(a40)',err=99) dbg1 call chknam(dbg1,40) write(*,*) ' debug file: ',dbg1 else if (nelp .eq. 2) then read(lin,'(a40)',err=99) dbg2 call chknam(dbg2,40) write(*,*) ' debug file: ',dbg2 else if (nelp .eq. 3) then read(lin,'(a40)',err=99) dbg3 call chknam(dbg3,40) write(*,*) ' debug file: ',dbg3 else if (nelp .eq. 4) then read(lin,'(a40)',err=99) dbg4 call chknam(dbg4,40) write(*,*) ' debug file: ',dbg4 else if (nelp .eq. 5) then read(lin,'(a40)',err=99) dbg5 call chknam(dbg5,40) write(*,*) ' debug file: ',dbg5 endif atmp(nelp) = ang1(nelp) c c If anisotropy flags equal one, then a constant anisotropy ratio is used c if (anflg1(nelp).eq.1) then anis1(nelp) = tmp1(nelp) / max(aa(nelp),EPSLON) endif if (anflg2(nelp).eq.1) then anis2(nelp) = tmp2(nelp) / max(aa(nelp),EPSLON) endif sumwt = sumwt + wt(nelp) dmax = max(dmax,aa(nelp)) end do close(lin) if(nnelp.lt.1.or.sumwt.lt.EPSLON) then write(*,*) 'ERROR: no ellipsoid geometries ' stop end if c c Get CDF of weighted ellipsoid specifications: c do nelp=1,nnelp wt(nelp) = wt(nelp) / sumwt end do wt(1) = wt(1) / sumwt do i=2,nnelp wt(i) = wt(i-1) + wt(i)/sumwt end do c c Border zone: c ixa = 1 + int(dmax/max(xsiz,EPSLON)) iya = 1 + int(dmax/max(ysiz,EPSLON)) iza = 1 + int(dmax/max(zsiz,EPSLON)) write(*,*) write(*,*) 'Read in ',nnelp,' possible ellipsoid geometries' write(*,*) c c Perform some error checking and open files: c nxyz = nx * ny * nz if(nxyz.gt.MAXXYZ) then write(*,*) 'ERROR: model size too big. have = ',MAXXYZ write(*,*) ' asked for = ',nxyz stop end if open(lout,file=outfl,status='UNKNOWN') write(lout,100) 100 format('Output from ELLIPSIM',/,'1',/,'in/out code') do nelp=1,nnelp if (nelp .eq. 1) then open(ldbg1,file=dbg1,status='UNKNOWN') if (dbglvl .gt. 1) then write(ldbg1,101) else write(ldbg1,102) endif else if (nelp .eq. 2) then open(ldbg2,file=dbg2,status='UNKNOWN') if (dbglvl .gt. 1) then write(ldbg2,101) else write(ldbg2,102) endif else if (nelp .eq. 3) then open(ldbg3,file=dbg3,status='UNKNOWN') if (dbglvl .gt. 1) then write(ldbg3,101) else write(ldbg3,102) endif else if (nelp .eq. 4) then open(ldbg4,file=dbg4,status='UNKNOWN') if (dbglvl .gt. 1) then write(ldbg4,101) else write(ldbg4,102) endif else if (nelp .eq. 5) then open(ldbg5,file=dbg5,status='UNKNOWN') if (dbglvl .gt. 1) then write(ldbg5,101) else write(ldbg5,102) endif end if 101 format('Output from ELLIPSIM',/,'10',/,'Centroid X coord',/, + 'Centroid Y Coord',/,'Centroid Z Coord',/,'Radius 1',/, + 'Radius 2',/,'Radius 3',/,'Angle 1',/,'Angle 2',/, + 'Angle 3',/,'Fracture Set',/,'Truncation Flag') 102 format('Output from ELLIPSIM',/,'7',/,'Centroid X coord',/, + 'Centroid Y Coord',/,'Centroid Z Coord',/,'Radius 1',/, + 'Angle 1',/,'Fracture Set',/,'Truncation Flag') end do c c Loop over all simulations: c do isim=1,nsim write(*,*) ' Starting simulation ',isim do i=1,nxyz sim(i) = 0 end do prop = 0.0 c c Keep looping until target proportion is reached: c 20 if(prop.ge.targprop) go to 21 c write(*,*) 'prop and target', prop, targprop c c Randomly choose the ellipsoid class c rnum = real(acorni(idum)) do i=1,nnelp if(rnum.lt.wt(i)) then ielp = i go to 10 end if end do 10 continue c c Do a random draw from the specified distribution to get the radius c c normal or log normal if (lpar1(ielp) .le. 2) then 30 r1 = real(acorni(idum)) r2 = real(acorni(idum)) gasdev = sqrt(-2.0*log(r1))*sin(2.0*3.1415927*r2) if (lpar1(ielp) .eq. 1) then aa(ielp) = lpar3(ielp)*gasdev+lpar2(ielp) c write(*,*), 'r1,r2,gasdev,aa', r1,r2,gasdev,aa(ielp) if (aa(ielp).le.0.0) go to 30 else if (lpar1(ielp) .eq. 2) then aa(ielp) = exp(lpar3(ielp)*gasdev+lpar2(ielp)) write(*,*), 'log norm r1,r2,gasdev,aa', r1, + r2,gasdev,aa(ielp) end if c exponential else if (lpar1(ielp) .eq. 3) then aa(ielp) = real(expon(rnum,lpar2(ielp))) c pareto else if (lpar1(ielp) .eq. 4) then aa(ielp) = lpar2(ielp)*(1.0-rnum)**(-1.0/lpar3(ielp)) c power-law else if (lpar1(ielp) .eq. 5) then aa(ielp) = lpar2(ielp)*rnum**(1.0/lpar3(ielp)) c truncated power-law else if (lpar1(ielp) .eq. 6) then rpow = lpar2(ielp)/lpar3(ielp) rpow = 1.0-rpow*rpow aa(ielp) = lpar2(ielp)/(sqrt(1.0-rnum*rpow)) c make sure rad is .gt. other rmin and also c HARD WIRE the the anisotropy ratio to 0.1500 c such that features at the truncation limit don't c just look like squares if(aa(ielp).lt.lpar4(ielp))then aa(ielp) = lpar4(ielp) anis1(ielp) = 0.15000 t_flg = 0 else anis1(ielp) = tmp1(ielp) / max(aa(ielp),EPSLON) t_flg = 1 endif c make z radius equal to main radius anis2(ielp) = 1.0 endif radsqd = aa(ielp) * aa(ielp) nxc = max(min((1+int(aa(ielp)/max(xsiz,EPSLON))),nx),1) nyc = max(min((1+int(aa(ielp)/max(ysiz,EPSLON))),ny),1) nzc = max(min((1+int(aa(ielp)/max(zsiz,EPSLON))),nz),1) c c Centroid of the ellipsoid: c ixc = -ixa + int(real(acorni(idum)) * (nx+2*ixa)) iyc = -iya + int(real(acorni(idum)) * (ny+2*iya)) izc = -iza + int(real(acorni(idum)) * (nz+2*iza)) if(nx.eq.1) ixc = 1 if(ny.eq.1) iyc = 1 if(nz.eq.1) izc = 1 c c Do a random draw from to get the angle c SO FAR ONLY PUTTING VARIABILITY ON ANGLE 1 c c Normal distribution where mean equals the angle c if (apar1(ielp) .eq. 1) then 31 r1 = real(acorni(idum)) r2 = real(acorni(idum)) gasdev = sqrt(-2.0*log(r1))*sin(2.0*3.1415927*r2) ang1(ielp) = apar3(ielp)*gasdev+apar2(ielp) c write(*,*), 'r1,r2,gasdev,ang1', r1,r2,gasdev,ang1(ielp) end if c c Triangular distribution of DEVIATIONS from ang1 c if (apar1(ielp) .eq. 2) then r1 = real(acorni(idum)) r2 = real(acorni(idum)) part1 =(apar4(ielp)-apar2(ielp))* + (apar3(ielp)-apar2(ielp)) tmed =((apar3(ielp)-apar2(ielp))* + (apar3(ielp)-apar2(ielp)))/part1 c write(*,*) ' r2 and tmed are: ', r2, tmed if (r2.gt.tmed) then c the x value is greater than the mode part1 =(apar4(ielp)-apar2(ielp))* + (apar4(ielp)-apar3(ielp)) adev = apar4(ielp)-sqrt(part1-r2*part1) else c the x value is less than the mode adev = sqrt(part1*r2) + apar2(ielp) endif c add plus or minus deviation to angle if (r1.gt.0.50000) then ang1(ielp) = atmp(ielp) + adev else ang1(ielp) = atmp(ielp) - adev endif endif c c Set up the rotation/anisotropy matrices for each ellipsoid: c c write(*,*) 'Setting up rotation matrix for ellipsoid' c write(*,*) call setrot(ang1(ielp),ang2(ielp),ang3(ielp),anis1(ielp), + anis2(ielp),ielp,MAXROT,rotmat) c c Fill the ellipsoid: c do 40 ix=-nxc,nxc i = ixc + ix if(i.le.0.or.i.gt.nx) go to 40 do 41 iy=-nyc,nyc j = iyc + iy if(j.le.0.or.j.gt.ny) go to 41 do 42 iz=-nzc,nzc k = izc + iz if(k.le.0.or.k.gt.nz) go to 42 xx = real(ix) * xsiz yy = real(iy) * ysiz zz = real(iz) * zsiz sdist = sqdist(0.,0.,0.,xx,yy,zz, + ielp,MAXROT,rotmat) if(real(sdist).lt.radsqd) then ind = i+(j-1)*nx+(k-1)*nx*ny if(sim(ind).eq.0) then sim(ind) = 1 prop = prop + 1. endif endif 42 continue 41 continue 40 continue c c Currently, the ldbg values correspond to ielp c if (dbglvl .gt. 1) then write(ielp,*) ixc,iyc,izc,aa(ielp), + anis1(ielp)*max(aa(ielp),EPSLON), + anis2(ielp)*max(aa(ielp),EPSLON),ang1(ielp), + ang2(ielp),ang3(ielp),ielp,t_flg else write(ielp,*) ixc,iyc,izc,aa(ielp), + ang1(ielp),ielp,t_flg endif c c Go back for another ellipse: c go to 20 21 continue c c Write out simulation and go back for another: c do i=1,nxyz write(lout,'(i1)') sim(i) end do end do c c Finished: c close(lout) write(*,9998) VERSION 9998 format(/' ELLIPSIM Version: ',f5.3, ' Finished'/) stop 98 stop 'ERROR in data file' 99 stop 'ERROR in parameter file' c c c end real*8 function expon(x1,bb) c----------------------------------------------------------------------- c c Draw From An Exponentail Distribution Given the Random Number c *************************************************************** c c This routine uses the cumulative distribution function of the exponential c distribution with parameter bb to return a value based on the randomly drawn c number "x1". c c c INPUT VARIABLES: c c x1 Random number drawn from a uniform distribution c bb Scale parameter of the exponential distribution c c c OUTPUT VARIABLES: c c expon The value corresponding to the probability, x1, of the c exponential distribution defined by bb c c c NO EXTERNAL REFERENCES c c c Author: S.A. McKenna Date: January, 1999 c----------------------------------------------------------------------- real*8 x1,bb c c determine the quantile corresponding to x1 in a exponential distribution: c expon = 1.0-exp((-1.0*x1)/bb) return end real function gcum(x) c----------------------------------------------------------------------- c c Evaluate the standard normal cdf given a normal deviate x. gcum is c the area under a unit normal curve to the left of x. The results are c accurate only to about 5 decimal places. c c c----------------------------------------------------------------------- z = x if(z.lt.0.) z = -z t = 1./(1.+ 0.2316419*z) gcum = t*(0.31938153 + t*(-0.356563782 + t*(1.781477937 + + t*(-1.821255978 + t*1.330274429)))) e2 = 0. c c 6 standard deviations out gets treated as infinity: c if(z.le.6.) e2 = exp(-z*z/2.)*0.3989422803 gcum = 1.0- e2 * gcum if(x.ge.0.) return gcum = 1.0 - gcum return end subroutine setrot(ang1,ang2,ang3,anis1,anis2,ind,MAXROT,rotmat) c----------------------------------------------------------------------- c c Sets up an Anisotropic Rotation Matrix c ************************************** c c Sets up the matrix to transform cartesian coordinates to coordinates c accounting for angles and anisotropy (see manual for a detailed c definition): c c c INPUT PARAMETERS: c c ang1 Azimuth angle for principal direction c ang2 Dip angle for principal direction c ang3 Third rotation angle c anis1 First anisotropy ratio c anis2 Second anisotropy ratio c ind matrix indicator to initialize c MAXROT maximum number of rotation matrices dimensioned c rotmat rotation matrices c c c NO EXTERNAL REFERENCES c c c Author: C. Deutsch Date: September 1989 c----------------------------------------------------------------------- parameter(DEG2RAD=3.141592654/180.0,EPSLON=1.e-20) real*8 rotmat(MAXROT,3,3),afac1,afac2,sina,sinb,sint, + cosa,cosb,cost c c Converts the input angles to three angles which make more c mathematical sense: c c alpha angle between the major axis of anisotropy and the c E-W axis. Note: Counter clockwise is positive. c beta angle between major axis and the horizontal plane. c (The dip of the ellipsoid measured positive down) c theta Angle of rotation of minor axis about the major axis c of the ellipsoid. c if(ang1.ge.0.0.and.ang1.lt.270.0) then alpha = (90.0 - ang1) * DEG2RAD else alpha = (450.0 - ang1) * DEG2RAD endif beta = -1.0 * ang2 * DEG2RAD theta = ang3 * DEG2RAD c c Get the required sines and cosines: c sina = dble(sin(alpha)) sinb = dble(sin(beta)) sint = dble(sin(theta)) cosa = dble(cos(alpha)) cosb = dble(cos(beta)) cost = dble(cos(theta)) c c Construct the rotation matrix in the required memory: c afac1 = 1.0 / dble(max(anis1,EPSLON)) afac2 = 1.0 / dble(max(anis2,EPSLON)) rotmat(ind,1,1) = (cosb * cosa) rotmat(ind,1,2) = (cosb * sina) rotmat(ind,1,3) = (-sinb) rotmat(ind,2,1) = afac1*(-cost*sina + sint*sinb*cosa) rotmat(ind,2,2) = afac1*(cost*cosa + sint*sinb*sina) rotmat(ind,2,3) = afac1*( sint * cosb) rotmat(ind,3,1) = afac2*(sint*sina + cost*sinb*cosa) rotmat(ind,3,2) = afac2*(-sint*cosa + cost*sinb*sina) rotmat(ind,3,3) = afac2*(cost * cosb) c c Return to calling program: c return end real*8 function sqdist(x1,y1,z1,x2,y2,z2,ind,MAXROT,rotmat) c----------------------------------------------------------------------- c c Squared Anisotropic Distance Calculation Given Matrix Indicator c *************************************************************** c c This routine calculates the anisotropic distance between two points c given the coordinates of each point and a definition of the c anisotropy. c c c INPUT VARIABLES: c c x1,y1,z1 Coordinates of first point c x2,y2,z2 Coordinates of second point c ind The rotation matrix to use c MAXROT The maximum number of rotation matrices dimensioned c rotmat The rotation matrices c c c c OUTPUT VARIABLES: c c sqdist The squared distance accounting for the anisotropy c and the rotation of coordinates (if any). c c c NO EXTERNAL REFERENCES c c c Author: C. Deutsch Date: September 1989 c----------------------------------------------------------------------- real*8 rotmat(MAXROT,3,3),cont,dx,dy,dz c c Compute component distance vectors and the squared distance: c dx = dble(x1 - x2) dy = dble(y1 - y2) dz = dble(z1 - z2) sqdist = 0.0 do i=1,3 cont = rotmat(ind,i,1) * dx + + rotmat(ind,i,2) * dy + + rotmat(ind,i,3) * dz sqdist = sqdist + cont * cont end do return end subroutine chknam(str,len) c----------------------------------------------------------------------- c c Check for a Valid File Name c *************************** c c This subroutine takes the character string "str" of length "len" and c removes all leading blanks and blanks out all characters after the c first blank found in the string (leading blanks are removed first). c c c c Author: C.V. Deutsch Date: January 1993 c----------------------------------------------------------------------- parameter (MAXLEN=132) character str(MAXLEN)*1 c c Remove leading blanks: c do i=1,len-1 if(str(i).ne.' ') then if(i.eq.1) go to 1 do j=1,len-i+1 k = j + i - 1 str(j) = str(k) end do do j=len,len-i+2,-1 str(j) = ' ' end do go to 1 end if end do 1 continue c c Find first blank and blank out the remaining characters: c do i=1,len-1 if(str(i).eq.' ') then do j=i+1,len str(j) = ' ' end do go to 2 end if end do 2 continue c c Return with modified file name: c return end
Attachment VI: Software routine documentation combine.c Routine (Version 1.0) The combine.c software routine is used to combine the output of sisim and ellip2_MC into a final permeability model. This combination is accomplished by writing the value contained in the sisim file to the combine.c output file ("combine.out") for every location at which the output of the ellip2_MC file is equal to zero (outside the enhanced permeability features). When the value of the ellip2_MC output is equal to 1, then the value written to combine.out is a constant log10 permeability value of -11.00. The combine.c software routine is only used in the construction of the enhanced permeability models. The outputs of sisim and ellip2_MC are taken as inputs to combine.c. The output of combine.c is the file combine.out. All input and output files are in the GeoEAS (aka GSLIB) format. The combine.c software routine is written in the C programming language on a Sun Ultra Sparc Server. The version of the C compiler is 4.2 and the operating system is Solaris 2.7. An example run of the combine.c software routine was done to test the ability of the software routine to assign the -11.00 permeability value in the correct locations. This simple test is deemed adequate for this software routine. INPUT (file sisim.out): A sisim realization provides the input for this code. The top 80 lines of this file are shown below. The entire file is 390,628 lines long-too long to include in this attachment (see the CD-ROM Submitted to the TDMS).
Realization number 50 1 simulated permeability value -13.7371 -13.6896 -12.8068 -13.5099 -14.1110 -12.6552 -14.9141 -12.7743 -14.8956 -14.2879 -13.9661 -11.0565 -15.4176 -12.0948 -13.0222 -11.7484 -15.5224 -13.4511 -12.8096 -11.6129 -12.4824 -12.6322 -11.9999 -12.2957 -15.6676 -14.6862 -13.0709 -11.8815 -11.7959 -12.0087 -12.8610 -15.7901 -14.1781 -15.3681 -15.4008 -13.5921 -11.4143 -11.6736 -12.7716 -12.5909 -15.4378 -14.0943 -10.4479 -12.5511 -14.0816 -14.2122 -12.6385 -12.7820 -12.1047 -11.9920 -15.8023 -14.6352 -11.6963 -15.5383 -12.7202 -12.8801 -11.7240 -11.1408 -12.0514 -14.2421 -14.4381 -15.1086 -14.4077 -12.2894 -15.0924 -12.1726 -13.5187 -11.7727 -14.6535 -14.2326 -10.7093 -12.9640 -14.8340 -13.9497 -14.2614 -14.4089 -12.7268INPUT (file ellip2..out):ellip2_MC realization provides the other input for this routine. The top 80 lines of this file are shown below. The entire file is 390,628 lines long-too long to include in this attachment.
Output from ELLIPSIM 1 in/out code 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0OUTPUT (file combine.out): The top 80 lines of an output file, combine.out, are shown below. Note that on lines 44 and 45 and lines 76 and 77 of the ellip2.out file, the integer code is "1". On these lines the combine.c routine must assign a "-11.00" value to the combine.out file. On all other lines, combine.c must assign the log10 permeability as shown above in the sisim.out file. The results below indicate that the software routine is capable of creating the correct output. At lines 44,45,76 and 77, the value of -11.00 is assigned. For all other lines, the sisim output is reproduced exactly.
Combine indicator and boolean permeability model 1 Log10 Permeability in m2 -13.7371 -13.6896 -12.8068 -13.5099 -14.1110 -12.6552 -14.9141 -12.7743 -14.8956 -14.2879 -13.9661 -11.0565 -15.4176 -12.0948 -13.0222 -11.7484 -15.5224 -13.4511 -12.8096 -11.6129 -12.4824 -12.6322 -11.9999 -12.2957 -15.6676 -14.6862 -13.0709 -11.8815 -11.7959 -12.0087 -12.8610 -15.7901 -14.1781 -15.3681 -15.4008 -13.5921 -11.4143 -11.6736 -12.7716 -12.5909 -11.0000 -11.0000 -10.4479 -12.5511 -14.0816 -14.2122 -12.6385 -12.7820 -12.1047 -11.9920 -15.8023 -14.6352 -11.6963 -15.5383 -12.7202 -12.8801 -11.7240 -11.1408 -12.0514 -14.2421 -14.4381 -15.1086 -14.4077 -12.2894 -15.0924 -12.1726 -13.5187 -11.7727 -14.6535 -14.2326 -10.7093 -12.9640 -11.0000 -11.0000 -14.2614 -14.4089 -12.7268RESULTS OF TESTING The simple check done here to test the combine.c routine confirmed that the routine correctly combines the sisim permeability values and the indicator flag from ellip2_MC into a permeability value in Geo-EAS (GSLIB) format. The results of these checks prove that the required functionality of the routine works within the range of the routine design. SOURCE CODE:
#include <stdio.h> /* Take two input files in GSLIB format both of the same size. The second one has integer values (like output from the ellipsim code) and combine them. At any location where the second file has value, set the output permeability equal to a constant, otherwise retain the permeability value in the first file. */ char *read_line (stream) FILE *stream; { static char string[512]; string[0] = '\0'; do fgets (string, 512, stream); while ((string[0] == '!') && !feof (stream)); return (string); } main () { FILE *stream1,*stream2,*stream3; char string[256],file1[256],file2[256],title[256],value_title[256]; char file3[256]; int i,j,k,nx,ny,nz,data_col,indic[126][126][26]; float data[126][126][26],delx,dely,delz; float o_x,o_y,o_z,perm_const; perm_const = -11.0000; nx = 125; ny = 125; nz = 25; delx = 4.0; dely = 4.0; delz = 2.0; /* Origin of grid, _not_ centroid of first element */ o_x = 0.0; o_y = 0.0; o_z = 0.0; for (k=0;k<nz;k++) for (j=0;j<ny;j++) for (i=0;i<nx;i++) data[i][j][k] = 0; /* open the input and output files */ stream1 = fopen("/home/samcken_c/YMP99/SISIM/SET1/sisim.out","r"); stream2 = fopen("/home/samcken_c/YMP99/ELLIP/ellip2.out","r"); stream3 = fopen("/home/samcken_c/YMP99/ELLIP/combine.out","w"); /* Read in the gslib output file */ sprintf (string, "%s", read_line (stream1)); sscanf (string, "%s", &title); sprintf (string, "%s", read_line (stream1)); sscanf (string, "%d", &data_col); sprintf (string, "%s", read_line (stream1)); sscanf (string, "%s", &value_title); sprintf (string, "%s", read_line (stream2)); sscanf (string, "%s", &title); sprintf (string, "%s", read_line (stream2)); sscanf (string, "%d", &data_col); sprintf (string, "%s", read_line (stream2)); sscanf (string, "%s", &value_title); for (k=0;k<nz;k++) for (j=0;j<ny;j++) for (i=0;i<nx;i++) { fscanf (stream1, "%f", &data[i][j][k]); fscanf (stream2, "%d", &indic[i][j][k]); if (indic[i][j][k]) data[i][j][k] = perm_const; } /* Write the subregion specified by nx,ny,nz to a *.srf formatted file */ fprintf (stream3,"Combine indicator and boolean permeability model\n"); fprintf (stream3,"1\n"); fprintf (stream3,"Log10 Permeability in m2\n"); for (k=0;k<nz;k++) { for (j=0;j<ny;j++) { /* for (j=(ny-1);j>=0;j--) { */ for (i=0;i<nx;i++) { fprintf (stream3," %7.4f\n ", data[i][j][k]); } } } }The calc_cdf.c software routine is used to calculate the cdf of the simulated permeability distribution at eight predefined thresholds. The input to the calc_cdf software routine is the file combine.out. The output file, result_cdf.out is a single line file that gives the value of the cdf at each of the eight thresholds. The calc_cdf.c software routine is written in the C programming language on a Sun Ultra Sparc Server. The version of the C compiler is 4.2 and the operating system is Solaris 2.7. An example run of the calc_cdf.c software routine was done to test the ability of the software routine to calculate the values of a cdf. This test was done by using a file of the same size as the combine.out files with a Gaussian distribution having a mean of –13.0 and a standard deviation of 1.0. The theoretical values for the cdf of the Gaussian distribution can be obtained from any statistical textbook. These values are tabulated below. [Table V11-1.] The results of the test show that the calc_cdf.c results are within 1/1000th of the theoretical values for all eight of the thresholds. This resolution is adequate for the verification calculations of the cdfs done in this AMR. INPUT (file combine.out): A test file was created with a normal distribution where the mean is –13.0 and the standard deviation is 1.0. This input file consists of 125x125x25 (390,625) values of log10 permeability in m2. This file is too large to show in this attachment. This input test file was processed with the calc_cdf.c software routine to determine the values of the cdf at the 8 thresholds. OUTPUT (file result_cdf.out): An additional test was done to make sure that the calc_cdf.c software routine would append a second run of the routine to the bottom of the existing output file. The same input file was used, so the results on each line are identical. The output file below shows that the routine successfully appends the new results to the line below the previous results. 0.003 0.022 0.066 0.241 0.501 0.789 0.885 0.919
#include<stdio.h> #include<math.h> /* Simple code to read in a GSLIB formatted file and calculate the values of the cdf at each of a user set number of thresholds. Output is in append mode and this is desinged to run in a UNIX shell with hardwired I/O file names */ char *read_line (stream) FILE *stream; { static char string[512]; string[0] = '\0'; do fgets (string, 512, stream); while ((string[0] == '!') && !feof (stream)); return (string); } main () { FILE *stream1,*stream2; char string[256],file1[256],file2[256],title[256],value_title[256]; int i,j,k,l,count,nx,ny,nz,data_col; int cnt1,cnt2,cnt3,cnt4,cnt5,cnt6,cnt7,cnt8; float nr,data,thresh1,thresh2,thresh3,thresh4,thresh5,thresh6,thresh7,thresh8; thresh1 = -15.700; cnt1 = 0; thresh2 = -15.000; cnt2 = 0; thresh3 = -14.500; cnt3 = 0; thresh4 = -13.700; cnt4 = 0; thresh5 = -13.000; cnt5 = 0; thresh6 = -12.200; cnt6 = 0; thresh7 = -11.800; cnt7 = 0; thresh8 = -11.600; cnt8 = 0; nx = 125; ny = 125; nz = 25; nr = (float)(nx*ny*nz); /* open the input and output file */ stream1 = fopen("sisim.out","r"); stream2 = fopen("result_cdf.out","a"); /* open the input file and read the header */ sprintf (string, "%s", read_line (stream1)); sscanf (string, "%s", &title); sprintf (string, "%s", read_line (stream1)); sscanf (string, "%d", &data_col); sprintf (string, "%s", read_line (stream1)); sscanf (string, "%s", &value_title); for (k=0;k<nz;k++) { for (j=0;j<ny;j++) { for (i=0;i<nx;i++) { fscanf (stream1, "%f", &data); if (data <= thresh1) cnt1++; else if (data <= thresh2) cnt2++; else if (data <= thresh3) cnt3++; else if (data <= thresh4) cnt4++; else if (data <= thresh5) cnt5++; else if (data <= thresh6) cnt6++; else if (data <= thresh7) cnt7++; else if (data <= thresh8) cnt8++; } } } fprintf (stream2,"%5.3f %5.3f %5.3f %5.3f %5.3f %5.3f %5.3f %5.3f\n", (float)cnt1/nr,(float)(cnt1+cnt2)/nr,(float)(cnt1+cnt2+cnt3)/nr, (float)(cnt1+cnt2+cnt3+cnt4)/nr,(float)(cnt1+cnt2+cnt3+cnt4+cnt5)/nr, (float)(cnt1+cnt2+cnt3+cnt4+cnt5+cnt6)/nr, (float)(cnt1+cnt2+cnt3+cnt4+cnt5+cnt6+cnt7)/nr, (float)(cnt1+cnt2+cnt3+cnt4+cnt5+cnt6+cnt7+cnt8)/nr); fclose (stream2); }
Attachment VIII: Software routine documentation gs2fehm.c Routine (Version 1.0) The gs2fehm.c software routine is used to reformat files created in GeoEAS (aka GSLIB) format into the correct input format necessary for perm macro of the FEHM flow and transport modeling software. The input to the gs2fehm software routine is the file sisim.out. This file is the output of either sisim or combine.c. The output file, perm.dat is a six column file with the columns identifying: node number, node number, node increment, permeability in the X, Y and Z directions. The gs2fehm.c software routine is written in the C programming language on a Sun Ultra Sparc Server. The version of the C compiler is 4.2 and the operating system is Solaris 2.7. An example run of the gs2fehm.c software routine was done to test the ability of the software routine to calculate the values of a cdf. INPUT (file sisim.out): A sisim realization provides the input for this code. The top 50 lines of this file are shown below. The file 390,628 lines long-too long to include in this attachment.
Realization number 50 1 simulated permeability value -13.7371 -13.6896 -12.8068 -13.5099 -14.1110 -12.6552 -14.9141 -12.7743 -14.8956 -14.2879 -13.9661 -11.0565 -15.4176 -12.0948 -13.0222 -11.7484 -15.5224 -13.4511 -12.8096 -11.6129 -12.4824 -12.6322 -11.9999 -12.2957 -15.6676 -14.6862 -13.0709 -11.8815 -11.7959 -12.0087 -12.8610 -15.7901 -14.1781 -15.3681 -15.4008 -13.5921 -11.4143 -11.6736 -12.7716 -12.5909 -15.4378 -14.0943 -10.4479 -12.5511 -14.0816 -14.2122 -12.6385OUTPUT (file perm.dat): The top 50 lines of an output file, perm.dat, are shown below. The results indicate that the software routine is capable of creating the 6-column output format and transforming the log10 input data to raw space data. Note that because the GSLIB and FEHM grids are numbered differently, the lines in the input and output files are not directly correlated.
perm 1 1 1 6.400e-13 6.400e-13 6.400e-13 2 2 1 3.171e-16 3.171e-16 3.171e-16 3 3 1 2.740e-13 2.740e-13 2.740e-13 4 4 1 2.021e-15 2.021e-15 2.021e-15 5 5 1 3.732e-15 3.732e-15 3.732e-15 6 6 1 4.513e-15 4.513e-15 4.513e-15 7 7 1 1.139e-13 1.139e-13 1.139e-13 8 8 1 9.629e-13 9.629e-13 9.629e-13 9 9 1 1.124e-15 1.124e-15 1.124e-15 10 10 1 1.725e-13 1.725e-13 1.725e-13 11 11 1 4.660e-11 4.660e-11 4.660e-11 12 12 1 2.944e-16 2.944e-16 2.944e-16 13 13 1 1.043e-14 1.043e-14 1.043e-14 14 14 1 8.674e-13 8.674e-13 8.674e-13 15 15 1 2.055e-16 2.055e-16 2.055e-16 16 16 1 2.044e-13 2.044e-13 2.044e-13 17 17 1 1.223e-15 1.223e-15 1.223e-15 18 18 1 4.247e-17 4.247e-17 4.247e-17 19 19 1 4.737e-17 4.737e-17 4.737e-17 20 20 1 6.230e-13 6.230e-13 6.230e-13 21 21 1 4.222e-14 4.222e-14 4.222e-14 22 22 1 1.584e-15 1.584e-15 1.584e-15 23 23 1 2.541e-15 2.541e-15 2.541e-15 24 24 1 1.028e-15 1.028e-15 1.028e-15 25 25 1 1.017e-12 1.017e-12 1.017e-12 26 26 1 4.638e-16 4.638e-16 4.638e-16 27 27 1 6.931e-13 6.931e-13 6.931e-13 28 28 1 1.143e-14 1.143e-14 1.143e-14 29 29 1 1.061e-15 1.061e-15 1.061e-15 30 30 1 1.041e-14 1.041e-14 1.041e-14 31 31 1 1.311e-12 1.311e-12 1.311e-12 32 32 1 1.186e-13 1.186e-13 1.186e-13 33 33 1 5.419e-14 5.419e-14 5.419e-14 34 34 1 5.673e-16 5.673e-16 5.673e-16 35 35 1 9.548e-15 9.548e-15 9.548e-15 36 36 1 2.700e-14 2.700e-14 2.700e-14 37 37 1 4.439e-13 4.439e-13 4.439e-13 38 38 1 1.819e-13 1.819e-13 1.819e-13 39 39 1 1.772e-14 1.772e-14 1.772e-14 40 40 1 2.155e-17 2.155e-17 2.155e-17 41 41 1 6.214e-15 6.214e-15 6.214e-15 42 42 1 1.458e-14 1.458e-14 1.458e-14 43 43 1 3.446e-13 3.446e-13 3.446e-13 44 44 1 2.120e-16 2.120e-16 2.120e-16 45 45 1 7.135e-16 7.135e-16 7.135e-16 46 46 1 5.391e-14 5.391e-14 5.391e-14 47 47 1 8.072e-16 8.072e-16 8.072e-16 48 48 1 1.888e-13 1.888e-13 1.888e-13 49 49 1 3.048e-12 3.048e-12 3.048e-12SOURCE CODE:
#include<stdio.h> #include<math.h> /* Convert GSLIB simulation output (2-D or 3-D) to a UNCERT *.srf format file */ char *read_line (stream) FILE *stream; { static char string[512]; string[0] = '\0'; do fgets (string, 512, stream); while ((string[0] == '!') && !feof (stream)); return (string); } main () { FILE *stream1, *stream2; char string[256],file1[256],file2[256],title[256],value_title[256]; float data[126][126][26]; int i,j,k,nx,ny,nz,data_col,cnt,step; nx = 125; ny = 125; nz = 25; cnt =0; step=1; for (k=0;k<nz;k++) for (j=0;j<ny;j++) for (i=0;i<nx;i++) data[i][j][k] = 0.0; /* open the input and output files */ stream1 = fopen("sisim.out","r"); stream2 = fopen("perm.dat","w"); /* Read in the gslib output file */ sprintf (string, "%s", read_line (stream1)); sscanf (string, "%s", &title); sprintf (string, "%s", read_line (stream1)); sscanf (string, "%d", &data_col); sprintf (string, "%s", read_line (stream1)); sscanf (string, "%s", &value_title); /* READ IN AND ADD APPROXIMATE MEAN TO DATA VALUES */ for (k=0;k<nz;k++) for (j=0;j<ny;j++) for (i=0;i<nx;i++) { fscanf (stream1, "%f", &data[i][j][k]); } fclose (stream1); /* Write the subregion specified by nx,ny,nz to a FEHM formatted file */ fprintf (stream2,"perm\n"); /* for (k=0;k<nz;k++) { */ for (k=(nz-1);k>=0;k--) { for (j=0;j<ny;j++) { /* for (j=(ny-1);j>=0;j--) { */ for (i=0;i<nx;i++) { cnt++; fprintf (stream2," %7d %7d %7d %15.3e %15.3e %15.3e\n", cnt,cnt,step,pow(10.0,data[i][j][k]),pow(10.0,data[i][j][k]),pow(10.0,data[i][j][k])); } } } fprintf (stream2,"\n"); fprintf (stream2,"stop\n"); fclose (stream2); }
Attachment IX: Software documentation gamfil FORTRAN Routine (Version 1.0) The gamfil software routine is used as a post-processor to read in the output permeability models from sisim or ellip2_MC and determines the average spacing between high permeability features and the average width of these features. The output of the gamfil routine is a one line file that contains the x and y locations of the randomly located transect, the number of features counted along the transect and the mean spacing between features and the average width of the features. The gamfil software routine is written in the FORTRAN programming language on a Sun Ultra Sparc Server. The version of the FORTRAN compiler is 4.2 and the operating system is Solaris 2.7. This routine is composed of three separate source code files: CHKNAM.f, gamfil1.f and RAND.f and an include file gamfil.inc. The functionality of the gamfil software routine is tested by making one run with a specially constructed input file. All three capabilities of the gamfil routine are checked: the correct number of features must be found and the average feature spacing and the average thickness must be calculated correctly. This check is done with an input permeability field that has 6 high permeability features across the 500 meter wide domain. This input file is constructed such that every feature is 2 grid cells thick (8 meters). The log10 permeability of the high permeability features within this file is set to a constant value of -8.0. The background permeability is set to random values with a mean of -14.0. The same log10 permeability threshold value as used in the simulations done for this AMR, -12.2, is used to distinguish high-permeability features. Since the number of features, the width and the average spacing are all known for this input file, the check of the routine is simply to compare the output to these known inputs. The input parameter file, gamfil.par is shown below. Parameters for GAMfil 0.100 (Gamf_tst.par, 99.5.25)
****************** START OF PARAMETERS: gam_test2.out \file with data 1 1 \ number of variables, column numbers -1.0e21 1.0e21 \ trimming limits gam_vario.out \file for variogram output 1 \number of fields to analyze 125 2.0 4.0 \nx, xmn, xsiz 125 2.0 4.0 \ny, ymn, ysiz 25 1.0 2.0 \nz, zmn, zsiz 2 10 \number of directions, number of lags 1 0 0 \ixd(1),iyd(1),izd(1) 0 1 0 \ixd(2),iyd(2),izd(2) 0 \standardize sill? (0=no, 1=yes) 1 \number of variograms 1 1 9 -12.2 \tail variable, head variable, variogram type 69069 -12.2 \seed, threshCHECK (determining the number, average spacing and width of features): The output file, gam.res, is shown :38 1 6 83.333 8.000The x and y locations of the transect are 38 and 1 respectively, the number of features found is 6, the average spacing between features is 83.333 meters and the average feature width is 8.000 meters. The number of features in the specially constructed input file is 6, the average spacing is calculated as the number of features divided by the width of the simulation domain (500/6 = 83.333) and all features in the input file are 2 cells, or 8 meters wide. The gamfil software routine passes all three checks. RESULTS OF TESTING The three checks done to test the gamfil software routine confirmed that the routine finds the correct number of high permeability features in the input file, correctly determined the average spacing between features and also correctly determines the average width of the features. The results of these checks prove that the required functionality of the routine works within the range of the routine design. The gamfil routine also calculates a variogram for the permeability field. This variogram functionality was not used in the work for this AMR and therefore this functionality is not tested herein. SOURCE CODE:C%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% C % C Copyright (C) 1996, The Board of Trustees of the Leland Stanford % C Junior University. All rights reserved. % C % C The programs in GSLIB are distributed in the hope that they will be % C useful, but WITHOUT ANY WARRANTY. No author or distributor accepts % C responsibility to anyone for the consequences of using them or for % C whether they serve any particular purpose or work at all, unless he % C says so in writing. Everyone is granted permission to copy, modify % C and redistribute the programs in GSLIB, but only under the condition % C that this notice and the above copyright notice remain intact. % C % C%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% c----------------------------------------------------------------------- c c Variogram of Data on a Regular Grid c *********************************** c c The following Parameters control static dimensioning within gam3: c c MAXXYZ maximum number of nodes in the 3-D grid c MAXVAR maximum number of variables c c MAXDIR maximum number of directions possible at one time c MAXLAG maximum number of lags at one time c MXVARG maximum number of variograms possible at one time c c MXDLV MAXDIR*MAXLAG*MXVARG - used for dimensioning c EPSLON a small number to avoid dividing by zero c c----------------------------------------------------------------------- c c User Adjustable Parameters: c parameter(MAXXYZ = 800000, + MAXVAR = 5, + MAXDIR = 5, + MAXLAG = 200, + MXVARG = 5 ) c c Fixed Parameters: c parameter(MAXLG=MAXLAG+2,MXDLV=MAXDIR*MAXLG*MXVARG, + EPSLON=1.0e-20,VERSION=0.100) c c Variable Declaration: c real xsiz,ysiz,zsiz,tmin,tmax,vr(MAXXYZ*MAXVAR) real*8 gam(MXDLV),hm(MXDLV),tm(MXDLV),hv(MXDLV),tv(MXDLV), + np(MXDLV),sills(MAXVAR) integer nlag,nx,ny,nz,nxy,nxyz,ndir,ixd(MAXDIR),iyd(MAXDIR), + izd(MAXDIR),ivtail(MXVARG),ivhead(MXVARG), + ivtype(MXVARG),isill,nvarg character outfl*40,names(MAXVAR)*12 c c Common Blocks: c common /datagv/ xsiz,ysiz,zsiz,tmin,tmax,vr,nlag,nx,ny,nz,nxy, + nxyz,ndir,ixd,iyd,izd,ivtail,ivhead,ivtype, + isill,nvarg common /parmdp/ gam,hm,tm,hv,tv,np,sills common /chargv/ outfl,names subroutine chknam(str,len) c----------------------------------------------------------------------- c c Check for a Valid File Name c *************************** c c This subroutine takes the character string "str" of length "len" and c removes all leading blanks and blanks out all characters after the c first blank found in the string (leading blanks are removed first). c c c c----------------------------------------------------------------------- parameter (MAXLEN=132) character str(MAXLEN)*1 c c Remove leading blanks: c do i=1,len-1 if(str(i).ne.' ') then if(i.eq.1) go to 1 do j=1,len-i+1 k = j + i - 1 str(j) = str(k) end do do j=len,len-i+2,-1 str(j) = ' ' end do go to 1 end if end do 1 continue c c Find first blank and blank out the remaining characters: c do i=1,len-1 if(str(i).eq.' ') then do j=i+1,len str(j) = ' ' end do go to 2 end if end do 2 continue c c Return with modified file name: c return end subroutine rand(seed,n,vector) c--------------------------------------------------------------------- c c This random number generator generates random numbers in ]0,1[ c Note that if the seed value is zero on the first call, a default c value of 7931 will be used in a linear congruential generator to c generate 55 odd integers for the array 'itab()'. These values are c preserved by a common statement, so that they may be used in sub- c sequent calls by setting the seed to zero.If the value of 'seed' c is greater than zero in a call to the subroutine, then the array c 'itab' will be initialized and a new seed value will be returned c by the subroutine. Best results are obtained by making the initial c call with a seed of your choice and then setting the seed to '0' c for all subsequent calls. c c--------------------------------------------------------------------- dimension vector(*) common /unusual/itab(55),n1,n2,nseed integer rn1,seed c c Test to see if 55 odd integers must be generated. c if((seed.gt.0).or.(nseed.lt.1)) then nseed = seed if(seed.le.0) nseed = 7931 do i=1,55 rn1=mod(nseed*9069,32768) if(mod(rn1,2).eq.0) rn1 = rn1-1 itab(i) = rn1 nseed = rn1 end do n1 = 0 n2 = 24 endif c c Generate "n" random components for the vector "VECTOR" c do i=1,n itab(55-n1) = mod(itab(55-n2)*itab(55-n1),32768) vector(i) = abs(float(itab(55-n1))/float(32768)) n1 = mod(n1+1,55) n2 = mod(n2+1,55) end do if(seed.gt.0) seed=nseed c c Return with the vector of random numbers: c return end program main C%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% C % C Copyright (C) 1996, The Board of Trustees of the Leland Stanford % C Junior University. All rights reserved. % C % C The programs in GSLIB are distributed in the hope that they will be % C useful, but WITHOUT ANY WARRANTY. No author or distributor accepts % C responsibility to anyone for the consequences of using them or for % C whether they serve any particular purpose or work at all, unless he % C says so in writing. Everyone is granted permission to copy, modify % C and redistribute the programs in GSLIB, but only under the condition % C that this notice and the above copyright notice remain intact. % C % C%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% c----------------------------------------------------------------------- c c Variogram of Data on a Regular Grid c *********************************** c c This is a template driver program for GSLIB's "gam" subroutine. The c input data is ordered rowwise (x cycles fastest, then y, then z) in a c GEOEAS format file. The User's Guide contains more details. c c The program is executed with no command line arguments. The user c will be prompted for the name of a parameter file. The parameter c file is described in the documentation (see the example gam.par) c c c The output file will contain each directional variogram ordered by c direction and then variogram (the directions cycle fastest then the c variogram number). For each variogram there will be a one line c description and then "nlag" lines with the following: c c a) lag number (increasing from 1 to nlag) c b) separation distance c c) the "variogram" value c d) the number of pairs for the lag c e) the mean of the data contributing to the tail c f) the mean of the data contributing to the head c c......................................................................... c This version, GAMFIL, uses a single transect along random rows (in the c x-direction) as fixed interval line surveys to compute the frequency of c occurence of features exceeding a specific cutoff. c New Variables: c seed input random seed (INPUT) c thresh threshold value; if v > thresh, we count the number of c consecutive blocks for which v > thresh, compute and compile c the width, and count this feature. (INPUT) c nfcnt the number of features encountered on the current line c sumfwid accumulated sum of widths of features c Revised Variables: c isim last grid/simulation number to sample (i.e., sample one c transect in each of grid numbers 1 through isim). (INPUT) c c D. Walker, 99.5.25 c FURTHER REVISED ON 7/15/99 by S. McKenna c this version doesn't ask for the par file name, it just assumes c it is called gamfil.par c c The output file gam.res is also modified to give the data in c columnar format without the comments c c----------------------------------------------------------------------- include 'gamfil.inc' c c Read the Parameter File: c call readparm c c Call gam to compute the required variograms: c call gamma c c Write Results: c call writeout c c Finished: c write(*,9998) VERSION 9998 format(/' GAMfil Version: ',f5.3, ' Finished'/) stop end subroutine readparm c----------------------------------------------------------------------- c c Initialization and Read Parameters c ********************************** c c The input parameters and data are read in from their files. Some quick c error checking is performed and the statistics of all the variables c being considered are written to standard output. c c c c----------------------------------------------------------------------- include 'gamfil.inc' parameter(MV=20) real var(MV),cut(MXVARG) real*8 avg(MV),ssq(MV) real vrmin(MAXVAR),vrmax(MAXVAR) integer ivar(MV),num(MV),ivc(MXVARG),indflag(MXVARG) character datafl*40,str*40 logical testfl cddw ..................... logical previous real vector(55), thresh, sumfwid integer nfcnt, seed cddw ...................... data lin/1/,ncut/0/ c c Note VERSION number: c write(*,9999) VERSION 9999 format(/' GAM Version: ',f5.3/) c c Get the name of the parameter file - try the default name if no input: c c write(*,*) 'Which parameter file do you want to use?' c read (*,'(a40)') str c if(str(1:1).eq.' ')str='gam.par ' c inquire(file=str,exist=testfl) c if(.not.testfl) then c write(*,*) 'ERROR - the parameter file does not exist,' c write(*,*) ' check for the file and try again ' c write(*,*) c if(str(1:20).eq.'gam.par ') then c write(*,*) ' creating a blank parameter file' c call makepar c write(*,*) c end if c stop c endif c open(lin,file=str,status='OLD') c c SAM 7/15/99 making it read file without prompt c open(lin,file='gamfil.par',status='OLD') cddw .....open a results output file ................................ lres = lin+1 c str(4:7)='.res' c str(8:40)=' ' c open(lres,file=str,status='UNKNOWN') c write(lres,9999) VERSION cddw .................................................................. open(lres,file='gam.res',status='UNKNOWN') c c Find Start of Parameters: c 1 read(lin,'(a4)',end=98) str(1:4) if(str(1:4).ne.'STAR') go to 1 c c Read Input Parameters: c read(lin,'(a40)',err=98) datafl call chknam(datafl,40) c write(*,*) ' data file = ',datafl c write(lres,*) ' data file = ',datafl read(lin,*,err=98) nvar write(*,*) ' number of variables = ',nvar if(nvar.lt.1) stop 'nvar is too small: check parameters' if(nvar.gt.MAXVAR) stop 'nvar is too big: check gam.inc' backspace lin read(lin,*,err=98) j,(ivar(i),i=1,nvar) write(*,*) ' columns = ',(ivar(i),i=1,nvar) read(lin,*,err=98) tmin,tmax write(*,*) ' trimming limits = ',tmin,tmax read(lin,'(a40)',err=98) outfl call chknam(outfl,40) write(*,*) ' output file = ',outfl c write(lres,*) ' output file = ',outfl read(lin,*,err=98) isim write(*,*) ' grid number = ',isim read(lin,*,err=98) nx,xmn,xsiz write(*,*) ' nx,xmn,xsiz = ',nx,xmn,xsiz read(lin,*,err=98) ny,ymn,ysiz write(*,*) ' ny,ymn,ysiz = ',ny,ymn,ysiz read(lin,*,err=98) nz,zmn,zsiz write(*,*) ' nz,zmn,zsiz = ',nz,zmn,zsiz nxy = nx * ny nxyz = nx * ny * nz if(nx.lt.1) stop 'nx must be at least 1: check parameters' if(ny.lt.1) stop 'ny must be at least 1: check parameters' if(nz.lt.1) stop 'nz must be at least 1: check parameters' if(nxyz.gt.MAXXYZ) stop 'model is too big - check gam.inc' read(lin,*,err=98) ndir,nlag write(*,*) ' ndir,nlag = ',ndir,nlag if(ndir.lt.1) stop 'ndir is too small: check parameters' if(ndir.gt.MAXDIR) stop 'ndir is too big: check gam.inc' if(nlag.lt.1) stop 'nlag is too small: check parameters' if(nlag.gt.MAXLAG) stop 'nlag is too big: check gam.inc' do i=1,ndir read(lin,*,err=98) ixd(i),iyd(i),izd(i) write(*,*) ' direction = ',ixd(i),iyd(i),izd(i) end do read(lin,*,err=98) isill write(*,*) ' flag to standardize sills = ',isill read(lin,*,err=98) nvarg write(*,*) ' number of variograms = ',nvarg if(nvarg.lt.1) stop 'nvarg is too small: check parameters' if(nvarg.gt.MXVARG) stop 'nvarg is too big: check gam.inc' do i=1,nvarg read(lin,*,err=98) ivtail(i),ivhead(i),ivtype(i) write(*,*) ' tail,head,type = ', + ivtail(i),ivhead(i),ivtype(i) if(ivtype(i).eq.9.or.ivtype(i).eq.10) then ncut = ncut + 1 if(tmin.gt.0.0)stop'tmin interferes with indicators!' if(tmax.le.1.0)stop'tmax interferes with indicators!' if((nvar+ncut).gt.MAXVAR) then write(*,*) ' Too many indicator cutoffs!' write(*,*) ' use fewer or increase MAXVAR' stop endif backspace lin read(lin,*,err=98) ii,jj,kk,cut(ncut) if(ivtype(i).eq.9) indflag(ncut) = 1 if(ivtype(i).eq.10) indflag(ncut) = 0 ivc(ncut) = ivtail(i) ivtail(i) = nvar + ncut ivhead(i) = nvar + ncut write(names(nvar+ncut),140) ncut 140 format('Indicator ',i2) write(*,*) ' indicator threshold: ',cut(ncut) endif end do cddw .................... read(lin,*,err=99) seed, thresh write(*,*) ' Seed, threshold for features: ', seed, thresh c write(lres,*) ' Seed, threshold for features: ', seed, thresh c write(*,*) ' ' c write(*,*) 'press RETURN to continue' c read(*,*) cddw .................... write(*,*) close(lin) c c Check to make sure the data file exists, then either read in the c data or write an error message and stop: c inquire(file=datafl,exist=testfl) if(.not.testfl) then write(*,*) 'ERROR data file ',datafl,' does not exist!' stop endif c c The data file exists so open the file and read in the header c information. Initialize the storage that will be used to summarize c the data found in the file: c open(lin,file=datafl,status='OLD') read(lin,'(a40)',err=99) str read(lin,*,err=99) nvari do i=1,nvari read(lin,'(a40)',err=99) str do iv=1,nvar j=ivar(iv) if(i.eq.j) names(iv) = str(1:12) end do num(i) = 0 avg(i) = 0.0 ssq(i) = 0.0 end do c c Read the regular grid information row wise (x cycles fastest): c cddw .....Initial random number generator and accumulators...... call rand(seed,n,vector) sumswid = 0.0 sumswave = 0.0 cddw ........................ do is=1,isim cddw ......find a random transect in x for this simulation: n = 2 call rand(0,n,vector) iyloc = 1+aint( ny*vector(1) ) izloc = 1+aint( nz*vector(2) ) previous = .FALSE. nfcnt = 0 nbcnt = 0 sumfwid = 0.0 c ..... check for features in the head value of variogram 1 ichk = ivhead(1) if(ivtype(1).eq.9) ichk = ichk - ncut c write(lres,*) ' ' c write(lres,*) '**** Simulation: ', is,' *********' c write(lres,*) ' For head value of vario1,' c write(lres,*) ' Transect iyloc,izloc :',iyloc, ', ',izloc c write(lres,*) ' for variable/ichk :', ichk cddw .............................................................. do iz=1,nz do iy=1,ny do ix=1,nx cddw if(is.ne.isim) then cddw read(lin,'()',err=99) cddw else read(lin,*,err=99) (var(i),i=1,nvari) cddw........................ for the (y,z) of interest if (iz.eq.izloc .and. iy.eq.iyloc) then if (var(ichk).ge.thresh) then if(.not. previous) then nfcnt = nfcnt + 1 previous = .TRUE. end if nbcnt = nbcnt + 1 end if if ( ( (var(ichk).lt.thresh) .or. ix.eq.nx ) + .and. previous) then previous = .FALSE. sumfwid = sumfwid + (nbcnt * xsiz) nbcnt = 0 end if end if cddw........................................................................... do iv=1,nvar i=ivar(iv) index=ix+(iy-1)*nx+(iz-1)*nxy+(iv-1)*nxyz vr(index) = var(i) if(var(i).ge.tmin.and.var(i).lt.tmax) then num(iv) = num(iv) + 1 avg(iv) = avg(iv) + dble(var(i)) ssq(iv) = ssq(iv) + + dble(var(i)*var(i)) end if end do cddw end if end do end do end do cddw ......Compile feature stats for one transect avefwid = sumfwid / nfcnt wave = (nx*xsiz) / nfcnt sumswid = sumswid + avefwid sumswave = sumswave + wave c write(lres,*) ' ' c write(lres,*) ' number of features =', nfcnt c write(lres,*) ' arith. mean spacing=', wave, ' m' c write(lres,*) ' arith. mean width =', avefwid,' m' write(lres,202) iyloc,izloc,nfcnt,wave,avefwid 202 format (1X,I4,1X,I4,1X,I4,1X,F7.3,1X,F7.3) cddw........................................................................... end do cddw ......Compile feature stats for ALL transects avefwid = sumswid / isim wave = sumswave / isim c write(lres,*) ' ' c write(lres,*) ' ======== Summary over ',isim, c + ' realisations =========' c write(lres,*) ' arith. mean spacing=', wave, ' m' c write(lres,*) ' arith. mean width =', avefwid,' m' close(lres) cddw........................................................................... close(lin) c c Compute the averages and variances as an error check for the user: c do iv=1,nvar sills(iv) = -999. if(num(iv).gt.0) then avg(iv) = avg(iv) / dble(num(iv)) ssq(iv) =(ssq(iv) / dble(num(iv))) - avg(iv) * avg(iv) sills(iv) = ssq(iv) write(*,*) 'Variable number ',iv write(*,*) ' Number = ',num(iv) write(*,*) ' Average = ',real(avg(iv)) write(*,*) ' Variance = ',real(ssq(iv)) endif end do c c Construct Indicator Variables if necessary: c do ic=1,ncut iv = ivc(ic) jv = nvar + ic p0 = 0.0 p1 = 0.0 do ix=1,nx do iy=1,ny do iz=1,nz index = ix+(iy-1)*nx+(iz-1)*nxy+(iv-1)*nxyz jndex = ix+(iy-1)*nx+(iz-1)*nxy+(jv-1)*nxyz if(vr(index).lt.tmin.or.vr(index).ge.tmax) then vr(jndex) = tmin - EPSLON else if(indflag(ic).eq.1) then if(vr(index).lt.cut(ic)) then vr(jndex) = 0.0 p0 = p0 + 1.0 else vr(jndex) = 1.0 p1 = p1 + 1.0 end if else vr(jndex) = 0.0 if(int(vr(index)+0.5).eq.int(cut(ic)+0.5)) + vr(jndex) = 1.0 end if end if end do end do end do p0 = p0 / max((p1+p0),1.0) sills(jv) = dble(p0*(1.0-p0)) end do c c Establish minimums and maximums: c do i=1,MAXVAR vrmin(i) = 1.0e21 vrmax(i) = -1.0e21 end do do ix=1,nx do iy=1,ny do iz=1,nz do iv=1,nvar+ncut index = ix+(iy-1)*nx+(iz-1)*nxy+(iv-1)*nxyz if(vr(index).ge.tmin.and.vr(index).lt.tmax) then if(vr(index).lt.vrmin(iv)) vrmin(iv) = vr(index) if(vr(index).gt.vrmax(iv)) vrmax(iv) = vr(index) end if end do end do end do end do c c Check on the variogams that were requested: c call check(nvarg,ivtail,ivhead,ivtype,vrmin,vrmax,names,MAXVAR) c c Return: c return c c Error in an Input File Somewhere: c 98 stop 'ERROR in parameter file!' 99 stop 'ERROR in data file!' end subroutine gamma c----------------------------------------------------------------------- c c Variogram of Data on a Regular Grid c *********************************** c c This subroutine computes any of eight different measures of spatial c continuity for regular spaced 3-D data. Missing values are allowed c and the grid need not be cubic. c c c c INPUT VARIABLES: c c nlag Maximum number of lags to be calculated c nx Number of units in x (number of columns) c ny Number of units in y (number of lines) c nz Number of units in z (number of levels) c ndir Number of directions to consider c ixd(ndir) X (column) indicator of direction - number of grid c columns that must be shifted to move from a node c on the grid to the next nearest node on the grid c which lies on the directional vector c iyd(ndir) Y (line) indicator of direction - similar to ixd, c number of grid lines that must be shifted to c nearest node which lies on the directional vector c izd(ndir) Z (level) indicator of direction - similar to ixd, c number of grid levels that must be shifted to c nearest node of directional vector c nv The number of variables c vr(nx*ny*nz*nv) Array of data c tmin,tmax Trimming limits c isill 1=attempt to standardize, 0=do not c sills the sills (variances) to standardize with c nvarg Number of variograms to compute c ivtail(nvarg) Variable for the tail of the variogram c ivhead(nvarg) Variable for the head of the variogram c ivtype(nvarg) Type of variogram to compute: c 1. semivariogram c 2. cross-semivariogram c 3. covariance c 4. correlogram c 5. general relative semivariogram c 6. pairwise relative semivariogram c 7. semivariogram of logarithms c 8. madogram c 9. indicator semivariogram: an indicator variable c is constructed in the main program. c c OUTPUT VARIABLES: The following arrays are ordered by direction, c then variogram, and finally lag, i.e., c iloc = (id-1)*nvarg*nlag+(iv-1)*nlag+il c c np() Number of pairs c gam() Semivariogram, covariance, correlogram,... value c hm() Mean of the tail data c tm() Mean of the head data c hv() Variance of the tail data c tv() Variance of the head data c c c c Original: A.G. Journel 1978 c Revisions: B.E. Buxton Apr. 1982 c----------------------------------------------------------------------- include 'gamfil.inc' c c Initialize the summation arrays for each direction, variogram, and lag c nsiz = ndir*nvarg*nlag if(nsiz.gt.MXDLV) then write(*,*) 'ERROR: available storage in gam = ',MXDLV write(*,*) ' requested storage = ',nsiz stop endif do i=1,nsiz np(i) = 0. gam(i) = 0.0 hm(i) = 0.0 tm(i) = 0.0 hv(i) = 0.0 tv(i) = 0.0 end do c c First fix the location of a seed point on the grid (ix,iy,iz): c do ix=1,nx do iy=1,ny do iz=1,nz c c For the fixed seed point, loop through all directions: c do id=1,ndir ixinc = ixd(id) iyinc = iyd(id) izinc = izd(id) ix1 = ix iy1 = iy iz1 = iz c c For this direction, loop over all the lags: c do il=1,nlag c c Check to be sure that the point being considered is still in the c grid - if not, then finished with this direction: c ix1 = ix1 + ixinc if(ix1.lt.1.or.ix1.gt.nx) go to 3 iy1 = iy1 + iyinc if(iy1.lt.1.or.iy1.gt.ny) go to 3 iz1 = iz1 + izinc if(iz1.lt.1.or.iz1.gt.nz) go to 3 c c For this direction and lag, loop over all variograms: c do iv=1,nvarg it = ivtype(iv) c c Get the head value, skip this value if missing: c i = ivhead(iv) index = ix+(iy-1)*nx+(iz-1)*nxy+(i-1)*nxyz vrt = vr(index) if(vrt.lt.tmin.or.vrt.ge.tmax) go to 5 c c Get the tail value, skip this value if missing: c i = ivtail(iv) index = ix1+(iy1-1)*nx+(iz1-1)*nxy+(i-1)*nxyz vrh = vr(index) if(vrh.lt.tmin.or.vrh.ge.tmax) go to 5 c c Need increment for the cross semivariogram only: c if(it.eq.2) then i = ivtail(iv) index = ix+(iy-1)*nx+(iz-1)*nxy+(i-1)*nxyz vrhpr = vr(index) if(vrhpr.lt.tmin.or.vrhpr.ge.tmax) go to 5 i = ivhead(iv) index = ix1+(iy1-1)*nx+(iz1-1)*nxy+(i-1)*nxyz vrtpr = vr(index) if(vrtpr.lt.tmin.or.vrtpr.ge.tmax) go to 5 endif c c We have an acceptable pair, therefore accumulate all the statistics c that are required for the variogram: c i = (id-1)*nvarg*nlag+(iv-1)*nlag+il np(i) = np(i) + 1. tm(i) = tm(i) + dble(vrt) hm(i) = hm(i) + dble(vrh) c c Choose the correct variogram type and keep relevant sums: c if(it.eq.1.or.it.ge.9) then gam(i) = gam(i) + dble((vrh-vrt)*(vrh-vrt)) else if(it.eq.2) then gam(i) = gam(i) + dble((vrhpr-vrh)*(vrt-vrtpr)) else if(abs(it).eq.3) then gam(i) = gam(i) + dble(vrh*vrt) else if(it.eq.4) then gam(i) = gam(i) + dble(vrh*vrt) hv(i) = hv(i) + dble(vrh*vrh) tv(i) = tv(i) + dble(vrt*vrt) else if(it.eq.5) then gam(i) = gam(i) + dble((vrh-vrt)*(vrh-vrt)) else if(it.eq.6) then if((vrt+vrh).lt.EPSLON) then np(i) = np(i) - 1. tm(i) = tm(i) - dble(vrt) hm(i) = hm(i) - dble(vrh) else tempvar= 2.0*(vrt-vrh)/(vrt+vrh) gam(i) = gam(i) + dble(tempvar*tempvar) endif else if(it.eq.7) then if(vrt.lt.EPSLON.or.vrh.lt.EPSLON) then np(i) = np(i) - 1. tm(i) = tm(i) - dble(vrt) hm(i) = hm(i) - dble(vrh) else tempvar= alog(vrt)-alog(vrh) gam(i) = gam(i) + dble(tempvar*tempvar) endif else if(it.eq.8) then gam(i) = gam(i) + dble(abs(vrt-vrh)) endif 5 continue end do 4 continue end do 3 continue end do end do end do end do c c Get average values for gam, hm, tm, hv, and tv, then compute c the correct "variogram" measure: c do id=1,ndir do iv=1,nvarg do il=1,nlag i = (id-1)*nvarg*nlag+(iv-1)*nlag+il if(np(i).eq.0.) go to 6 rnum = np(i) gam(i) = gam(i) / dble(rnum) hm(i) = hm(i) / dble(rnum) tm(i) = tm(i) / dble(rnum) hv(i) = hv(i) / dble(rnum) tv(i) = tv(i) / dble(rnum) it = ivtype(iv) c c Attempt to standardize: c if(isill.eq.1) then if(ivtail(iv).eq.ivhead(iv)) then iii = ivtail(iv) if((it.eq.1.or.it.ge.9).and.sills(iii).gt.0.0) + gam(i) = gam(i) / sills(iii) end if end if c c 1. report the semivariogram rather than variogram c 2. report the cross-semivariogram rather than variogram c 3. the covariance requires "centering" c 4. the correlogram requires centering and normalizing c 5. general relative requires division by lag mean c 6. report the semi(pairwise relative variogram) c 7. report the semi(log variogram) c 8. report the semi(madogram) c if(it.eq.1.or.it.eq.2) then gam(i) = 0.5 * gam(i) else if(abs(it).eq.3) then gam(i) = gam(i) - hm(i)*tm(i) if(it.lt.0) then if(sills(ivtail(iv)).lt.0.0.or. + sills(ivhead(iv)).lt.0.0) then gam(i) = -999.0 else variance = ( sqrt(sills(ivtail(iv))) + * sqrt(sills(ivhead(iv))) ) gam(i) = variance - gam(i) end if end if else if(it.eq.4) then hv(i) = hv(i)-hm(i)*hm(i) if(hv(i).le.0.0) hv(i) = 0.0 hv(i) = sqrt(hv(i)) tv(i) = tv(i)-tm(i)*tm(i) if(tv(i).le.0.0) tv(i) = 0.0 tv(i) = sqrt(tv(i)) if((hv(i)*tv(i)).lt.EPSLON) then gam(i) = 0.0 else gam(i) =(gam(i)-hm(i)*tm(i))/(hv(i)*tv(i)) endif c c Square "hv" and "tv" so that we return the variance: c hv(i) = hv(i)*hv(i) tv(i) = tv(i)*tv(i) else if(it.eq.5) then htave = 0.5*(hm(i)+tm(i)) htave = htave * htave if(htave.lt.EPSLON) then gam(i) = 0.0 else gam(i) = gam(i)/dble(htave) endif else if(it.ge.6) then gam(i) = 0.5 * gam(i) endif 6 continue end do end do end do return end subroutine writeout c----------------------------------------------------------------------- c c Write Out the Results of GAM c **************************** c c An output file will be written which contains each directional c variogram ordered by direction and then variogram (the directions c cycle fastest then the variogram number). For each variogram there c will be a one line description and then "nlag" lines with: c c a) lag number (increasing from 1 to nlag) c b) separation distance c c) the "variogram" value c d) the number of pairs for the lag c e) the mean of the data contributing to the tail c f) the mean of the data contributing to the head c g) IF the correlogram - variance of tail values c h) IF the correlogram - variance of head values c c c c c c----------------------------------------------------------------------- include 'gamfil.inc' character title*80 data lout/1/ c c Loop over all the variograms that have been computed: c open(lout,file=outfl,status='UNKNOWN') do iv=1,nvarg c c Construct a title that reflects the variogram type and the variables c that were used to calculate the variogram: c it = abs(ivtype(iv)) if(it.eq. 1) title(1:24) = 'Semivariogram ' if(it.eq. 2) title(1:24) = 'Cross Semivariogram ' if(it.eq. 3) title(1:24) = 'Covariance ' if(it.eq. 4) title(1:24) = 'Correlogram ' if(it.eq. 5) title(1:24) = 'General Relative ' if(it.eq. 6) title(1:24) = 'Pairwise Relative ' if(it.eq. 7) title(1:24) = 'Variogram of Logarithms ' if(it.eq. 8) title(1:24) = 'Semimadogram ' if(it.eq. 9) title(1:24) = 'Indicator 1/2 Variogram ' if(it.eq.10) title(1:24) = 'Indicator 1/2 Variogram ' write(title(25:62),100) names(ivtail(iv)),names(ivhead(iv)) 100 format('tail:',a12,' head:',a12) c c Loop over all the directions (note the direction in the title): c do id=1,ndir write(title(62:74),101) id 101 format('direction ',i2) write(lout,'(a74)') title(1:74) c c Compute the unit lag distance along the directional vector: c dis = sqrt( max(((ixd(id)*xsiz)**2 + (iyd(id)*ysiz)**2 + + (izd(id)*zsiz)**2),0.0) ) c c Write out all the lags: c do il=1,nlag i = (id-1)*nvarg*nlag+(iv-1)*nlag+il disl = real(il)*dis nump = int(np(i)) if(it.eq.4) then write(lout,102) il,disl,gam(i),nump, + hm(i),tm(i),hv(i),tv(i) else write(lout,102) il,disl,gam(i),nump, + hm(i),tm(i) endif 102 format(1x,i3,1x,f12.3,1x,f12.5,1x,i8,4(1x,f14.5)) end do end do end do close(lout) return end subroutine check(nvarg,ivtail,ivhead,ivtype,vrmin,vrmax, + names,MAXVAR) c----------------------------------------------------------------------- c c Error Check and Note Variogram Types c ************************************ c c Go through each variogram type and note the type to the screen and c report any possible errors. c c c c c c----------------------------------------------------------------------- real vrmin(*),vrmax(*) integer ivtail(*),ivhead(*),ivtype(*) character title*80,names(MAXVAR)*12 c c Loop over all the variograms to be computed: c write(*,*) do iv=1,nvarg c c Note the variogram type and the variables being used: c it = abs(ivtype(iv)) if(it.eq. 1) title(1:24) = 'Semivariogram :' if(it.eq. 2) title(1:24) = 'Cross Semivariogram :' if(it.eq. 3) title(1:24) = 'Covariance :' if(it.eq. 4) title(1:24) = 'Correlogram :' if(it.eq. 5) title(1:24) = 'General Relative :' if(it.eq. 6) title(1:24) = 'Pairwise Relative :' if(it.eq. 7) title(1:24) = 'Variogram of Logarithms:' if(it.eq. 8) title(1:24) = 'Semimadogram :' if(it.eq. 9) title(1:24) = 'Indicator 1/2 Variogram:' if(it.eq.10) title(1:24) = 'Indicator 1/2 Variogram:' write(title(25:64),100) names(ivtail(iv)),names(ivhead(iv)) 100 format(' tail=',a12,' head=',a12) write(*,101) iv,title(1:64) 101 format(' Variogram ',i2,1x,a64) c c Check for possible errors or inconsistencies: c if(it.eq.2) then if(ivtail(iv).eq.ivhead(iv)) write(*,201) 201 format(' WARNING: cross variogram with the same variable!') else if(it.eq.5) then if(ivtail(iv).ne.ivhead(iv)) write(*,501) if(vrmin(ivtail(iv)).lt.0.0.and.vrmax(ivtail(iv)).gt.0.0) + write(*,502) if(vrmin(ivhead(iv)).lt.0.0.and.vrmax(ivhead(iv)).gt.0.0) + write(*,502) 501 format(' WARNING: cross general relative variogram are', + ' difficult to interpret!') 502 format(' WARNING: there are both positive and negative', + ' values - lag mean could be zero!') else if(it.eq.6) then if(ivtail(iv).ne.ivhead(iv)) write(*,601) if(vrmin(ivtail(iv)).lt.0.0.and.vrmax(ivtail(iv)).gt.0.0) + write(*,602) if(vrmin(ivhead(iv)).lt.0.0.and.vrmax(ivhead(iv)).gt.0.0) + write(*,602) 601 format(' WARNING: cross pairwise relative variogram are', + ' difficult to interpret!') 602 format(' WARNING: there are both positive and negative', + ' values - pair means could be zero!') else if(it.eq.7) then if(ivtail(iv).ne.ivhead(iv)) write(*,701) if(vrmin(ivtail(iv)).lt.0.0.or.vrmin(ivhead(iv)).lt.0.0) + write(*,702) 701 format(' WARNING: cross logarithmic variograms may be', + ' difficult to interpret!') 702 format(' WARNING: there are zero or negative', + ' values - logarithm undefined!') else if(it.eq.8) then if(ivtail(iv).ne.ivhead(iv)) write(*,901) 901 format(' WARNING: cross madograms may be difficult to', + ' interpret!') endif c c Loop over all variograms: c end do return end subroutine makepar c----------------------------------------------------------------------- c c Write a Parameter File c ********************** c c c c----------------------------------------------------------------------- lun = 99 open(lun,file='gam.par',status='UNKNOWN') write(lun,10) 10 format(' Parameters for GAM',/, + ' ******************',/,/, + 'START OF PARAMETERS:') write(lun,11) 11 format('../data/true.dat ', + '-file with data') write(lun,12) 12 format('2 1 2 ', + '- number of variables, column numbers') write(lun,13) 13 format('-1.0e21 1.0e21 ', + '- trimming limits') write(lun,14) 14 format('gam.out ', + '-file for variogram output') write(lun,15) 15 format('1 ', + '-grid or realization number') write(lun,16) 16 format('50 0.5 1.0 ', + '-nx, xmn, xsiz') write(lun,17) 17 format('50 0.5 1.0 ', + '-ny, ymn, ysiz') write(lun,18) 18 format(' 1 0.5 1.0 ', + '-nz, zmn, zsiz') write(lun,19) 19 format('2 10 ', + '-number of directions, number of lags') write(lun,20) 20 format(' 1 0 0 ', + '-ixd(1),iyd(1),izd(1)') write(lun,21) 21 format(' 0 1 0 ', + '-ixd(2),iyd(2),izd(2)') write(lun,22) 22 format('1 ', + '-standardize sill? (0=no, 1=yes)') write(lun,23) 23 format('5 ', + '-number of variograms') write(lun,24) 24 format('1 1 1 ', + '-tail variable, head variable, variogram type') write(lun,25) 25 format('1 1 3 ', + '-tail variable, head variable, variogram type') write(lun,26) 26 format('2 2 1 ', + '-tail variable, head variable, variogram type') write(lun,27) 27 format('2 2 3 ', + '-tail variable, head variable, variogram type') write(lun,28) 28 format('1 1 9 2.5 ', + '-tail variable, head variable, variogram type') write(lun,40) 40 format(//,'type 1 = traditional semivariogram',/, + ' 2 = traditional cross semivariogram',/, + ' 3 = covariance',/, + ' 4 = correlogram',/, + ' 5 = general relative semivariogram',/, + ' 6 = pairwise relative semivariogram',/, + ' 7 = semivariogram of logarithms',/, + ' 8 = semimadogram',/, + ' 9 = indicator semivariogram - continuous',/, + ' 10= indicator semivariogram - categorical') close(lun) return end
Attachment X: Software routine documentation modgeom.c Routine (Version 1.0) The modgeom.c software routine is used to decrement the seed number in the input file to the ellip2.f software subroutine. The input to the modgeom.c software routine is the input parameter file for the ellip2.f software routine. The random seed number in the input file is decreased by 4. The output file, temp, is written to be exactly the same as the input file with the exception of the new seed number. The modgeom.c software routine is written in the C programming language on a Sun Ultra Sparc Server. The version of the C compiler is 4.2 and the operating system is Solaris 2.7. An example run of the modgeom.c software routine is documented below. The input file has random seed number of 68869 and the output file has a random seed value of 68865. The software routine is written to read in a random seed as an integer. This software routine will not work if the numbers of lines in the file above and below the random seed line are different than shown in example below. INPUT (file ellip2.par):
Parameters for ELLIP2 *********************** START OF PARAMETERS: ellip2.out \file for output realizations 1 \number of realizations 125 2.0 4.0 \nx,xmn,xsiz 125 2.0 4.0 \ny,ymn,ysiz 25 1.0 2.0 \nz,zmn,zsiz 1 \debugging level 68869 \random 0.0200 \target proportion (in ellipsoids) 1 \number of ellipsoid sets to model 600.0 4.0 600.0 1 1 \SET 1 radius[1,2,3], anis1, anis2 (anis1&2 can only be 1 for now) 1 600.0 70.0 1.0 1.0 \SET 1 rad_par[1,2,3,4],weight 00.0 0.0 0.0 \SET 1 angle[1,2,3] 1 0.0 15.0 52.0 \SET 1 angpar[1,2,3,4] ellip2_1.dbg \file for SET 1 debugging output OUTPUT (file temp): Parameters for ELLIP2 *********************** START OF PARAMETERS: ellip2.out \file for output realizations 1 \number of realizations 125 2.0 4.0 \nx,xmn,xsiz 125 2.0 4.0 \ny,ymn,ysiz 25 1.0 2.0 \nz,zmn,zsiz 1 \debugging level 68865 \random 0.0200 \target proportion (in ellipsoids) 1 \number of ellipsoid sets to model 600.0 4.0 600.0 1 1 \SET 1 radius[1,2,3], anis1, anis2 (anis1&2 can only be 1 for now) 1 600.0 70.0 1.0 1.0 \SET 1 rad_par[1,2,3,4],weight 00.0 0.0 0.0 \SET 1 angle[1,2,3] 1 0.0 15.0 52.0 \SET 1 angpar[1,2,3,4] ellip2_1.dbg \file for SET 1 debugging output SOURCE CODE: #include<stdio.h> main () { FILE *in_stream, *out_stream; char string[256], junk[70]; int i, counter; in_stream = fopen ("/home/samcken_c/YMP99/ELLIP/ellip2.par", "r"); out_stream = fopen ("/home/samcken_c/YMP99/ELLIP/temp", "w"); for (i=1;i<11;i++) { fgets (string, 256, in_stream); fprintf (out_stream, "%s", string); } fgets (string, 256, in_stream); sscanf (string, "%d %s", &counter,&junk); counter -= 4; fprintf (out_stream, "%d %s\n", counter, junk); for (i=1;i<8;i++) { fgets (string, 256, in_stream); fprintf (out_stream, "%s", string); } /* fprintf (out_stream, "\n"); */ fclose (out_stream); }
Attachment XI: Software routine documentation run_50_feat.ksh UNIX shell (Version 1.0) The run_50_feat.ksh software routine is a UNIX shell file that is used to sequentially set up the appropriate input files and execute the ellip2_MC, combine, modgeom, gs2fehm_feat, and calc_D_old software routines used in the analysis. In addition, the run_50_feat.ksh UNIX shell file runs the FEHM software code (xfehm_v2.00) to obtain the steady-state groundwater flow solution for each permeability field and to perform the particle tracking simulations for the planar source and the point source. The software routines cr8sptr and cr8sptr_cell are used write the input files for the particle tracking algorithm in the FEHM code for the planar- and point-particle sources, respectively. The UNIX shell file is simply a script containing a list of UNIX commands to be executed. In the run_50_feat.ksh shell file, a counter is incremented from 1 to 50 for the 50 realizations used in the analysis. The input file for each realization is the file sisim.xx.out, where xx is the realization number. The output files from the particle tracking simulations for the planar source are the files disper_L.out, disper_X.out, and disper_Z.out. The output files from the particle tracking simulations for the point source are the files disper_L_cell.out, disper_X_cell.out, and disper_Z_cell.out. Please note that the run_50_feat.ksh UNIX shell file is simply for file copying, file compression/uncompression, and running the appropriate software routines in a sequential manner for the enhanced permeability model. The run_50_feat.ksh software routine is executed on a Sun Ultra Sparc Server using the Solaris 2.7 operating system. Validation of the run_50_feat.ksh UNIX shell file is accomplished by visual inspection of the source code for the shell file and by checking to see that the appropriate output files have been generated following execution of the shell file. Following execution of the run_50_feat.ksh UNIX shell file, results for all 50 realizations are present as output. SOURCE CODE:
#!/bin/ksh integer count=1 while ((count <= 50)) do echo NOW RUNNING SIMULATION number $count uncompress ../SISIM/SET1/sisim.$count.out.Z cp ../SISIM/SET1/sisim.$count.out sisim.out compress ../SISIM/SET1/sisim.$count.out cd ../ELLIP /home/samcken_c/programs/ellipsim/ellip2/ellip2_MC cd ../FEHM ../ELLIP/./combine ../ELLIP/./modgeom cp ../ELLIP/temp ../ELLIP/ellip2.par mv ../ELLIP/ellip2_1.dbg ../ELLIP/ellip2.$count.dbg ./gs2fehm_feat /home/bwarnol/bin/xfehm_v2.00 ./cr8sptr ./cr8sptr_cell cp het_flow.fin track/het_flow.ini cd track mv disper_L_plane.out disper_L.out mv disper_X_plane.out disper_X.out mv disper_Z_plane.out disper_Z.out mv debug_plane.out debug.out /home/bwarnol/bin/xfehm_v2.00 ./calc_D_old mv disper_L.out disper_L_plane.out mv disper_X.out disper_X_plane.out mv disper_Z.out disper_Z_plane.out mv debug.out debug_plane.out mv disper_L_cell.out disper_L.out mv disper_X_cell.out disper_X.out mv disper_Z_cell.out disper_Z.out mv debug_cell.out debug.out cp ../sptr_cell.dat ../sptr.dat /home/bwarnol/bin/xfehm_v2.00 ./calc_D_old mv disper_L.out disper_L_cell.out mv disper_X.out disper_X_cell.out mv disper_Z.out disper_Z_cell.out mv debug.out debug_cell.out cd ../ ((count=count+1)) done
The run_50_back.ksh software routine is a UNIX shell file that is used to sequentially set up the appropriate input files and execute the gs2fehm and calc_D_old software routines used in the analysis. In addition, the run_50_back.ksh UNIX shell file runs the FEHM software code (xfehm_v2.00) to obtain the steady-state groundwater flow solution for each permeability field and to perform the particle tracking simulations for the planar source and the point source. The software routines cr8sptr and cr8sptr_cell are used to write the input files for the particle tracking algorithm in the FEHM code for the planar- and point-particle sources, respectively. The UNIX shell file is simply a script containing a list of UNIX commands to be executed. In the run_50_back.ksh shell file, a counter is incremented from 1 to 50 for the 50 realizations used in the analysis. The input file for each realization is the file sisim.xx.out, where xx is the realization number. The output files from the particle tracking simulations for the planar sourceare the files disper_L.out, disper_X.out, and disper_Z.out. The output files from the particle tracking simulations for the point sourceare the files disper_L_cell.out, disper_X_cell.out, and disper_Z_cell.out. Please note that the run_50_back.ksh UNIX shell file is simply for file copying, file compression/uncompression, and running the appropriate software routines in a sequential manner for the background permeability model. The run_50_back.ksh software routine is executed on a Sun Ultra Sparc Server using the Solaris 2.7 operating system. Validation of the run_50_back.ksh UNIX shell file is accomplished by visual inspection of the source code for the shell file and by checking to see that the appropriate output files have been generated following execution of the shell file. Following execution of the run_50_back.ksh UNIX shell file, results for all 50 realizations are present as output. SOURCE CODE:
#!/bin/ksh integer count=1 while ((count <= 50)) do echo NOW RUNNING SIMULATION number $count uncompress ../SISIM/SET1/sisim.$count.out.Z cp ../SISIM/SET1/sisim.$count.out sisim.out compress ../SISIM/SET1/sisim.$count.out ./gs2fehm /home/bwarnol/bin/xfehm_v2.00 ./cr8sptr ./cr8sptr_cell cp het_flow.fin track/het_flow.ini cd track mv disper_L_plane.out disper_L.out mv disper_X_plane.out disper_X.out mv disper_Z_plane.out disper_Z.out mv debug_plane.out debug.out /home/bwarnol/bin/xfehm_v2.00 ./calc_D_old mv disper_L.out disper_L_plane.out mv disper_X.out disper_X_plane.out mv disper_Z.out disper_Z_plane.out mv debug.out debug_plane.out mv disper_L_cell.out disper_L.out mv disper_X_cell.out disper_X.out mv disper_Z_cell.out disper_Z.out mv debug_cell.out debug.out cp ../sptr_cell.dat ../sptr.dat /home/bwarnol/bin/xfehm_v2.00 ./calc_D_old mv disper_L.out disper_L_cell.out mv disper_X.out disper_X_cell.out mv disper_Z.out disper_Z_cell.out mv debug.out debug_cell.out cd ../ ((count=count+1)) done
Attachment XIII: Software routine documentation: cr8sptr.c Routine (Version 1.0) The cr8sptr.c software routine is used to read in the output of the flxo macro in FEHM and determine the starting locations of the streamlines for the sptr particle tracking macro in FEHM. The output of the cr8sptr.c routine is written in the format necessary to be read by the sptr macro. The starting locations of the particles are determined by a flux-weighted placement scheme: cells with greater flux receive more particles than cells with lower amounts of flux. The cr8sptr.c software routine is written in the C programming language on a Sun Ultra Sparc Server. The version of the C compiler is 4.2 and the operating system is Solaris 2.7. The functionality of the cr8sptr.c software routine is tested in three ways:
pp_fac and total flux are: 1.287e+06 3.107e-03 Total particles requested: 4000 Total particles assigned in step 1: 3988 Difference is target - assigned: 12 Final simulation time is 5.000e+07 days Total particles requested: 4000 Total particles assigned at end of step 2: 4000From the last number in the first line, the sum of the fluxes is 3.107e-03 m3/sec. The FEHM macro flxo provides the input for this software routine. The output from flxo is written to the screen as a screen dump during the running of FEHM. The flxo output is written three times and the final time provides the flux values for the 500 designated cells at steady state. This third and final output from the flxo macro is shown below for an example run The flux values in column 7 are converted to positive numbers and summed (the negative number in the output indicates the direction of flow, we are only concerned with magnitude of the flux). Any numbers that indicate flux in the opposite direction (negative numbers after the sign change) are set to zero such that no particles will be started in those cells. These zero values are used in the summation. The flxo output below was read into Excel, the sign of the numbers was changed, and any negative values remaining after the sign change were converted to zeroes. The values were then summed. The resulting sum is: 0.003107038. The Excel calculation and the cr8sptr.c calculation agree to the 6th decimal place. Additionally, the cr8sptr.c file located the correct set of flxo outputs in the het_flow.out file. The first two flxo outputs in that file do not sum to the same number as the third and final output.
Internode Fluxes Node1 Node2 X,Y,Z Vapor Flux(kg/sec) X,Y,Z Liquid Flux (kg/sec) 155638 155513 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.712752E-07 0.000000E+00 155639 155514 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.226774E-05 0.000000E+00 155640 155515 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.127233E-05 0.000000E+00 155641 155516 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.264136E-05 0.000000E+00 155642 155517 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.550743E-04 0.000000E+00 155643 155518 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.113521E-04 0.000000E+00 155644 155519 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.453207E-08 0.000000E+00 155645 155520 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.857072E-08 0.000000E+00 155646 155521 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.179074E-06 0.000000E+00 155647 155522 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.333594E-06 0.000000E+00 155648 155523 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.709377E-06 0.000000E+00 155649 155524 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.649807E-07 0.000000E+00 155650 155525 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.206155E-06 0.000000E+00 155651 155526 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.234651E-06 0.000000E+00 155652 155527 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.572755E-07 0.000000E+00 155653 155528 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.660471E-07 0.000000E+00 155654 155529 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.166451E-09 0.000000E+00 155655 155530 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.638951E-05 0.000000E+00 155656 155531 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.361878E-10 0.000000E+00 155657 155532 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.601006E-08 0.000000E+00 155658 155533 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.577183E-07 0.000000E+00 155659 155534 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.728317E-05 0.000000E+00 155660 155535 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.376014E-08 0.000000E+00 155661 155536 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.167448E-06 0.000000E+00 155662 155537 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.521587E-07 0.000000E+00 155663 155538 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.522938E-10 0.000000E+00 155664 155539 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.656947E-07 0.000000E+00 155665 155540 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.266192E-06 0.000000E+00 155666 155541 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.282939E-07 0.000000E+00 155667 155542 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.771346E-07 0.000000E+00 155668 155543 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.413010E-09 0.000000E+00 155669 155544 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.104130E-05 0.000000E+00 155670 155545 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.308429E-05 0.000000E+00 155671 155546 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.110011E-07 0.000000E+00 155672 155547 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.188751E-07 0.000000E+00 155673 155548 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.324748E-05 0.000000E+00 155674 155549 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.431083E-06 0.000000E+00 155675 155550 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.143547E-03 0.000000E+00 155676 155551 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.124666E-08 0.000000E+00 155677 155552 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.300589E-07 0.000000E+00 155678 155553 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.121235E-05 0.000000E+00 155679 155554 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.297295E-06 0.000000E+00 155680 155555 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.185165E-07 0.000000E+00 155681 155556 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.474439E-04 0.000000E+00 155682 155557 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.135775E-08 0.000000E+00 155683 155558 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.914389E-06 0.000000E+00 155684 155559 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.354780E-07 0.000000E+00 155685 155560 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.407558E-05 0.000000E+00 155686 155561 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.483210E-08 0.000000E+00 155687 155562 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.559679E-07 0.000000E+00 155688 155563 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.148144E-05 0.000000E+00 155689 155564 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.415004E-08 0.000000E+00 155690 155565 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.323312E-09 0.000000E+00 155691 155566 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.153404E-06 0.000000E+00 155692 155567 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.455093E-07 0.000000E+00 155693 155568 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.799673E-10 0.000000E+00 155694 155569 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155686E-05 0.000000E+00 155695 155570 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.606638E-09 0.000000E+00 155696 155571 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.304327E-07 0.000000E+00 155697 155572 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.789937E-05 0.000000E+00 155698 155573 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.857557E-08 0.000000E+00 155699 155574 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.571900E-05 0.000000E+00 155700 155575 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.198367E-07 0.000000E+00 155701 155576 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.126990E-06 0.000000E+00 155702 155577 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.515676E-05 0.000000E+00 155703 155578 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.510269E-08 0.000000E+00 155704 155579 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.182161E-05 0.000000E+00 155705 155580 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.151546E-06 0.000000E+00 155706 155581 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.346580E-09 0.000000E+00 155707 155582 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.259398E-06 0.000000E+00 155708 155583 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.239679E-05 0.000000E+00 155709 155584 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.385179E-10 0.000000E+00 155710 155585 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.768764E-09 0.000000E+00 155711 155586 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.118629E-04 0.000000E+00 155712 155587 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.395465E-08 0.000000E+00 155713 155588 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.127208E-06 0.000000E+00 155714 155589 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.344762E-04 0.000000E+00 155715 155590 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.955926E-08 0.000000E+00 155716 155591 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.101967E-07 0.000000E+00 155717 155592 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.597666E-08 0.000000E+00 155718 155593 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.241876E-07 0.000000E+00 155719 155594 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.105260E-07 0.000000E+00 155720 155595 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.243193E-06 0.000000E+00 155721 155596 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.654799E-05 0.000000E+00 155722 155597 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.807059E-06 0.000000E+00 155723 155598 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.171237E-07 0.000000E+00 155724 155599 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.943445E-07 0.000000E+00 155725 155600 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.158196E-07 0.000000E+00 155726 155601 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.516613E-07 0.000000E+00 155727 155602 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.389093E-05 0.000000E+00 155728 155603 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.177429E-06 0.000000E+00 155729 155604 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.657965E-07 0.000000E+00 155730 155605 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.129648E-06 0.000000E+00 155731 155606 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.257448E-03 0.000000E+00 155732 155607 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.132619E-05 0.000000E+00 155733 155608 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.158651E-09 0.000000E+00 155734 155609 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.148427E-05 0.000000E+00 155735 155610 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.459063E-06 0.000000E+00 155736 155611 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.268370E-06 0.000000E+00 155737 155612 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.619750E-06 0.000000E+00 171263 171138 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.423994E-06 0.000000E+00 171264 171139 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.169743E-04 0.000000E+00 171265 171140 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.916163E-06 0.000000E+00 171266 171141 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.129867E-06 0.000000E+00 171267 171142 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.599029E-04 0.000000E+00 171268 171143 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.716648E-08 0.000000E+00 171269 171144 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.911853E-08 0.000000E+00 171270 171145 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.111074E-07 0.000000E+00 171271 171146 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.140435E-06 0.000000E+00 171272 171147 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.407802E-06 0.000000E+00 171273 171148 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.795657E-07 0.000000E+00 171274 171149 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.580564E-07 0.000000E+00 171275 171150 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.150064E-06 0.000000E+00 171276 171151 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.432307E-06 0.000000E+00 171277 171152 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.971528E-07 0.000000E+00 171278 171153 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.883260E-07 0.000000E+00 171279 171154 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.285747E-04 0.000000E+00 171280 171155 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.583222E-05 0.000000E+00 171281 171156 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.265384E-07 0.000000E+00 171282 171157 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.206381E-07 0.000000E+00 171283 171158 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.243049E-07 0.000000E+00 171284 171159 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.102193E-04 0.000000E+00 171285 171160 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.152461E-07 0.000000E+00 171286 171161 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.645363E-07 0.000000E+00 171287 171162 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.183555E-05 0.000000E+00 171288 171163 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.165334E-09 0.000000E+00 171289 171164 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.898474E-07 0.000000E+00 171290 171165 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.248346E-06 0.000000E+00 171291 171166 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.225430E-07 0.000000E+00 171292 171167 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.449864E-07 0.000000E+00 171293 171168 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.457760E-08 0.000000E+00 171294 171169 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.137437E-05 0.000000E+00 171295 171170 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.411442E-05 0.000000E+00 171296 171171 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.429940E-08 0.000000E+00 171297 171172 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.375314E-07 0.000000E+00 171298 171173 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.160776E-06 0.000000E+00 171299 171174 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.685003E-06 0.000000E+00 171300 171175 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.142378E-03 0.000000E+00 171301 171176 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.891629E-09 0.000000E+00 171302 171177 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.241327E-07 0.000000E+00 171303 171178 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.168780E-07 0.000000E+00 171304 171179 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.248060E-06 0.000000E+00 171305 171180 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.187311E-07 0.000000E+00 171306 171181 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.358867E-04 0.000000E+00 171307 171182 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.994240E-09 0.000000E+00 171308 171183 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.230193E-05 0.000000E+00 171309 171184 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.409721E-06 0.000000E+00 171310 171185 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.786284E-05 0.000000E+00 171311 171186 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154814E-08 0.000000E+00 171312 171187 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.644689E-07 0.000000E+00 171313 171188 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.306139E-05 0.000000E+00 171314 171189 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.114821E-09 0.000000E+00 171315 171190 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.212285E-09 0.000000E+00 171316 171191 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.282442E-06 0.000000E+00 171317 171192 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.422539E-07 0.000000E+00 171318 171193 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.570583E-08 0.000000E+00 171319 171194 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.203973E-05 0.000000E+00 171320 171195 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.348854E-08 0.000000E+00 171321 171196 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.608445E-07 0.000000E+00 171322 171197 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.567937E-05 0.000000E+00 171323 171198 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.181253E-07 0.000000E+00 171324 171199 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.264325E-05 0.000000E+00 171325 171200 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.157358E-07 0.000000E+00 171326 171201 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154932E-06 0.000000E+00 171327 171202 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.464688E-05 0.000000E+00 171328 171203 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.284359E-09 0.000000E+00 171329 171204 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.201487E-05 0.000000E+00 171330 171205 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.768847E-07 0.000000E+00 171331 171206 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.221908E-07 0.000000E+00 171332 171207 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.890164E-10 0.000000E+00 171333 171208 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.268676E-04 0.000000E+00 171334 171209 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.222949E-04 0.000000E+00 171335 171210 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.275018E-10 0.000000E+00 171336 171211 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.104985E-04 0.000000E+00 171337 171212 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.696395E-08 0.000000E+00 171338 171213 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.224685E-06 0.000000E+00 171339 171214 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.191306E-04 0.000000E+00 171340 171215 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.618515E-08 0.000000E+00 171341 171216 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.514689E-07 0.000000E+00 171342 171217 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.309938E-07 0.000000E+00 171343 171218 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.690398E-07 0.000000E+00 171344 171219 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.103656E-07 0.000000E+00 171345 171220 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.214579E-06 0.000000E+00 171346 171221 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.197921E-05 0.000000E+00 171347 171222 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.108152E-05 0.000000E+00 171348 171223 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.274700E-07 0.000000E+00 171349 171224 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.142920E-06 0.000000E+00 171350 171225 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.211206E-07 0.000000E+00 171351 171226 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.438010E-07 0.000000E+00 171352 171227 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.169661E-05 0.000000E+00 171353 171228 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.679295E-07 0.000000E+00 171354 171229 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.173496E-07 0.000000E+00 171355 171230 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.477761E-05 0.000000E+00 171356 171231 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.227692E-08 0.000000E+00 171357 171232 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.887528E-07 0.000000E+00 171358 171233 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.176997E-09 0.000000E+00 171359 171234 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.897392E-07 0.000000E+00 171360 171235 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.405783E-06 0.000000E+00 171361 171236 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.383955E-05 0.000000E+00 171362 171237 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.757902E-06 0.000000E+00 186888 186763 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.214950E-06 0.000000E+00 186889 186764 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.130460E-04 0.000000E+00 186890 186765 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.851044E-06 0.000000E+00 186891 186766 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.246254E-07 0.000000E+00 186892 186767 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.821533E-09 0.000000E+00 186893 186768 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.208034E-05 0.000000E+00 186894 186769 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.106030E-07 0.000000E+00 186895 186770 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.927399E-08 0.000000E+00 186896 186771 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.365914E-06 0.000000E+00 186897 186772 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.537466E-06 0.000000E+00 186898 186773 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.234021E-10 0.000000E+00 186899 186774 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.372904E-07 0.000000E+00 186900 186775 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.822897E-06 0.000000E+00 186901 186776 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.223682E-06 0.000000E+00 186902 186777 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.515598E-07 0.000000E+00 186903 186778 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.315820E-07 0.000000E+00 186904 186779 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.250526E-04 0.000000E+00 186905 186780 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.565097E-05 0.000000E+00 186906 186781 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.138686E-07 0.000000E+00 186907 186782 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.110433E-07 0.000000E+00 186908 186783 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.305624E-07 0.000000E+00 186909 186784 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.746976E-05 0.000000E+00 186910 186785 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.122800E-07 0.000000E+00 186911 186786 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.383087E-04 0.000000E+00 186912 186787 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.120856E-05 0.000000E+00 186913 186788 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.137832E-07 0.000000E+00 186914 186789 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.225897E-07 0.000000E+00 186915 186790 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.567575E-05 0.000000E+00 186916 186791 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.174294E-07 0.000000E+00 186917 186792 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.274347E-07 0.000000E+00 186918 186793 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.151249E-07 0.000000E+00 186919 186794 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.326587E-08 0.000000E+00 186920 186795 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.130036E-05 0.000000E+00 186921 186796 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.331049E-08 0.000000E+00 186922 186797 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.526617E-07 0.000000E+00 186923 186798 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.369705E-09 0.000000E+00 186924 186799 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.298226E-05 0.000000E+00 186925 186800 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.141107E-03 0.000000E+00 186926 186801 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.285346E-10 0.000000E+00 186927 186802 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.739368E-07 0.000000E+00 186928 186803 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.882519E-07 0.000000E+00 186929 186804 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.114241E-07 0.000000E+00 186930 186805 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.246605E-07 0.000000E+00 186931 186806 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154862E-04 0.000000E+00 186932 186807 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.340916E-07 0.000000E+00 186933 186808 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.597170E-05 0.000000E+00 186934 186809 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.256598E-06 0.000000E+00 186935 186810 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.444097E-05 0.000000E+00 186936 186811 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.252688E-05 0.000000E+00 186937 186812 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.344597E-07 0.000000E+00 186938 186813 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.914038E-06 0.000000E+00 186939 186814 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.184534E-07 0.000000E+00 186940 186815 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.300415E-09 0.000000E+00 186941 186816 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.162636E-05 0.000000E+00 186942 186817 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.207800E-07 0.000000E+00 186943 186818 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.886810E-09 0.000000E+00 186944 186819 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.774395E-06 0.000000E+00 186945 186820 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.774752E-10 0.000000E+00 186946 186821 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.925222E-07 0.000000E+00 186947 186822 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.309368E-05 0.000000E+00 186948 186823 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.195833E-05 0.000000E+00 186949 186824 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.607478E-06 0.000000E+00 186950 186825 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.898886E-08 0.000000E+00 186951 186826 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.146138E-08 0.000000E+00 186952 186827 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.332705E-05 0.000000E+00 186953 186828 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.530405E-08 0.000000E+00 186954 186829 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.151758E-05 0.000000E+00 186955 186830 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.209980E-05 0.000000E+00 186956 186831 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.273420E-04 0.000000E+00 186957 186832 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.532862E-09 0.000000E+00 186958 186833 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.258901E-04 0.000000E+00 186959 186834 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.467744E-07 0.000000E+00 186960 186835 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.208916E-10 0.000000E+00 186961 186836 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.136542E-06 0.000000E+00 186962 186837 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.148637E-07 0.000000E+00 186963 186838 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.614139E-06 0.000000E+00 186964 186839 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.184538E-04 0.000000E+00 186965 186840 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.675110E-08 0.000000E+00 186966 186841 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.324651E-07 0.000000E+00 186967 186842 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.123691E-06 0.000000E+00 186968 186843 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.177220E-06 0.000000E+00 186969 186844 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.317130E-07 0.000000E+00 186970 186845 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.821282E-06 0.000000E+00 186971 186846 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.168582E-05 0.000000E+00 186972 186847 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155236E-05 0.000000E+00 186973 186848 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.464256E-07 0.000000E+00 186974 186849 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.243578E-03 0.000000E+00 186975 186850 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.107930E-07 0.000000E+00 186976 186851 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.193292E-07 0.000000E+00 186977 186852 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.205476E-04 0.000000E+00 186978 186853 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.466610E-07 0.000000E+00 186979 186854 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.200365E-07 0.000000E+00 186980 186855 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.134729E-05 0.000000E+00 186981 186856 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.117966E-09 0.000000E+00 186982 186857 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.601081E-07 0.000000E+00 186983 186858 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.417807E-08 0.000000E+00 186984 186859 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.191059E-06 0.000000E+00 186985 186860 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.339589E-06 0.000000E+00 186986 186861 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.775899E-05 0.000000E+00 186987 186862 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.170345E-05 0.000000E+00 202513 202388 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.361007E-06 0.000000E+00 202514 202389 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.108612E-04 0.000000E+00 202515 202390 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.285807E-07 0.000000E+00 202516 202391 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.295866E-05 0.000000E+00 202517 202392 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.240877E-08 0.000000E+00 202518 202393 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.133471E-04 0.000000E+00 202519 202394 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154780E-07 0.000000E+00 202520 202395 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.992945E-08 0.000000E+00 202521 202396 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.420650E-06 0.000000E+00 202522 202397 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.408846E-06 0.000000E+00 202523 202398 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.269112E-09 0.000000E+00 202524 202399 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.424374E-07 0.000000E+00 202525 202400 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.438136E-06 0.000000E+00 202526 202401 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.118551E-06 0.000000E+00 202527 202402 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.447627E-07 0.000000E+00 202528 202403 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.586355E-07 0.000000E+00 202529 202404 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.493577E-04 0.000000E+00 202530 202405 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.645434E-05 0.000000E+00 202531 202406 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.171662E-07 0.000000E+00 202532 202407 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.111841E-07 0.000000E+00 202533 202408 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.138711E-07 0.000000E+00 202534 202409 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.940584E-05 0.000000E+00 202535 202410 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.315905E-08 0.000000E+00 202536 202411 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.318288E-04 0.000000E+00 202537 202412 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.485275E-06 0.000000E+00 202538 202413 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.845192E-07 0.000000E+00 202539 202414 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.218341E-06 0.000000E+00 202540 202415 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.692886E-05 0.000000E+00 202541 202416 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.314963E-07 0.000000E+00 202542 202417 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.114361E-07 0.000000E+00 202543 202418 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.335869E-08 0.000000E+00 202544 202419 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.158701E-08 0.000000E+00 202545 202420 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.485949E-06 0.000000E+00 202546 202421 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.849957E-08 0.000000E+00 202547 202422 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.117648E-06 0.000000E+00 202548 202423 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.486635E-08 0.000000E+00 202549 202424 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.378916E-05 0.000000E+00 202550 202425 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.139928E-03 0.000000E+00 202551 202426 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.409327E-07 0.000000E+00 202552 202427 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.103560E-06 0.000000E+00 202553 202428 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.425886E-07 0.000000E+00 202554 202429 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.231629E-07 0.000000E+00 202555 202430 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.135431E-06 0.000000E+00 202556 202431 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.324206E-04 0.000000E+00 202557 202432 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.392070E-05 0.000000E+00 202558 202433 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.446774E-05 0.000000E+00 202559 202434 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.238504E-06 0.000000E+00 202560 202435 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.877541E-05 0.000000E+00 202561 202436 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.294104E-05 0.000000E+00 202562 202437 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.345835E-05 0.000000E+00 202563 202438 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.637859E-06 0.000000E+00 202564 202439 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.292363E-07 0.000000E+00 202565 202440 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.687483E-07 0.000000E+00 202566 202441 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.244850E-05 0.000000E+00 202567 202442 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.207600E-07 0.000000E+00 202568 202443 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.883667E-10 0.000000E+00 202569 202444 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.305035E-06 0.000000E+00 202570 202445 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.131101E-09 0.000000E+00 202571 202446 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.143733E-06 0.000000E+00 202572 202447 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.394717E-05 0.000000E+00 202573 202448 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.237562E-05 0.000000E+00 202574 202449 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.772855E-06 0.000000E+00 202575 202450 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.147307E-05 0.000000E+00 202576 202451 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.115567E-07 0.000000E+00 202577 202452 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.814818E-07 0.000000E+00 202578 202453 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.731202E-08 0.000000E+00 202579 202454 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.405142E-05 0.000000E+00 202580 202455 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.636567E-05 0.000000E+00 202581 202456 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.118319E-04 0.000000E+00 202582 202457 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.131875E-07 0.000000E+00 202583 202458 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.231796E-04 0.000000E+00 202584 202459 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.234372E-07 0.000000E+00 202585 202460 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.352987E-10 0.000000E+00 202586 202461 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.123320E-07 0.000000E+00 202587 202462 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.835457E-08 0.000000E+00 202588 202463 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.132962E-05 0.000000E+00 202589 202464 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.546449E-07 0.000000E+00 202590 202465 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.649531E-08 0.000000E+00 202591 202466 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.152542E-07 0.000000E+00 202592 202467 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.537060E-08 0.000000E+00 202593 202468 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.533780E-06 0.000000E+00 202594 202469 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.653662E-07 0.000000E+00 202595 202470 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.556183E-05 0.000000E+00 202596 202471 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.611290E-06 0.000000E+00 202597 202472 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.976825E-06 0.000000E+00 202598 202473 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.290978E-07 0.000000E+00 202599 202474 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.238601E-03 0.000000E+00 202600 202475 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.147497E-07 0.000000E+00 202601 202476 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.348440E-07 0.000000E+00 202602 202477 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.167519E-04 0.000000E+00 202603 202478 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.129476E-06 0.000000E+00 202604 202479 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.840925E-08 0.000000E+00 202605 202480 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.142028E-06 0.000000E+00 202606 202481 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.535950E-05 0.000000E+00 202607 202482 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.277998E-06 0.000000E+00 202608 202483 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.140631E-05 0.000000E+00 202609 202484 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.128862E-06 0.000000E+00 202610 202485 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.319683E-06 0.000000E+00 202611 202486 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.449786E-05 0.000000E+00 202612 202487 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.227803E-06 0.000000E+00 218138 218013 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.447174E-06 0.000000E+00 218139 218014 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.316196E-10 0.000000E+00 218140 218015 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.304798E-07 0.000000E+00 218141 218016 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.217288E-05 0.000000E+00 218142 218017 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.612319E-04 0.000000E+00 218143 218018 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.607152E-05 0.000000E+00 218144 218019 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.224676E-07 0.000000E+00 218145 218020 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.868943E-05 0.000000E+00 218146 218021 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.108513E-06 0.000000E+00 218147 218022 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.446494E-06 0.000000E+00 218148 218023 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155213E-06 0.000000E+00 218149 218024 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.232154E-07 0.000000E+00 218150 218025 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.350975E-06 0.000000E+00 218151 218026 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.194399E-06 0.000000E+00 218152 218027 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.409879E-07 0.000000E+00 218153 218028 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.130903E-06 0.000000E+00 218154 218029 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.361340E-04 0.000000E+00 218155 218030 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.623667E-05 0.000000E+00 218156 218031 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.240124E-07 0.000000E+00 218157 218032 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.116086E-07 0.000000E+00 218158 218033 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.179845E-07 0.000000E+00 218159 218034 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.256327E-08 0.000000E+00 218160 218035 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.171026E-05 0.000000E+00 218161 218036 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.987706E-07 0.000000E+00 218162 218037 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.230388E-06 0.000000E+00 218163 218038 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.265946E-07 0.000000E+00 218164 218039 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.367272E-05 0.000000E+00 218165 218040 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.898553E-05 0.000000E+00 218166 218041 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.275607E-07 0.000000E+00 218167 218042 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.111608E-07 0.000000E+00 218168 218043 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.164084E-07 0.000000E+00 218169 218044 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.530732E-06 0.000000E+00 218170 218045 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.201889E-04 0.000000E+00 218171 218046 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.113523E-07 0.000000E+00 218172 218047 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.461255E-07 0.000000E+00 218173 218048 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.664410E-06 0.000000E+00 218174 218049 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.160854E-05 0.000000E+00 218175 218050 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.139640E-03 0.000000E+00 218176 218051 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.628889E-07 0.000000E+00 218177 218052 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.766898E-06 0.000000E+00 218178 218053 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155874E-04 0.000000E+00 218179 218054 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.107814E-07 0.000000E+00 218180 218055 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.292950E-08 0.000000E+00 218181 218056 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.132686E-04 0.000000E+00 218182 218057 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.256900E-05 0.000000E+00 218183 218058 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.572920E-06 0.000000E+00 218184 218059 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.206551E-06 0.000000E+00 218185 218060 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.671334E-06 0.000000E+00 218186 218061 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.394884E-08 0.000000E+00 218187 218062 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.366409E-05 0.000000E+00 218188 218063 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.529741E-06 0.000000E+00 218189 218064 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.183119E-07 0.000000E+00 218190 218065 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.182166E-09 0.000000E+00 218191 218066 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.342523E-07 0.000000E+00 218192 218067 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.861261E-05 0.000000E+00 218193 218068 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.183942E-08 0.000000E+00 218194 218069 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.124462E-05 0.000000E+00 218195 218070 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.354869E-09 0.000000E+00 218196 218071 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.120017E-06 0.000000E+00 218197 218072 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.355767E-06 0.000000E+00 218198 218073 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.352665E-05 0.000000E+00 218199 218074 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.318501E-08 0.000000E+00 218200 218075 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.271898E-05 0.000000E+00 218201 218076 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.927548E-08 0.000000E+00 218202 218077 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.668274E-07 0.000000E+00 218203 218078 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.326892E-09 0.000000E+00 218204 218079 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.366661E-05 0.000000E+00 218205 218080 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.169872E-05 0.000000E+00 218206 218081 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.139478E-04 0.000000E+00 218207 218082 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.332128E-07 0.000000E+00 218208 218083 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.210968E-04 0.000000E+00 218209 218084 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.117372E-07 0.000000E+00 218210 218085 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.855757E-10 0.000000E+00 218211 218086 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.337532E-04 0.000000E+00 218212 218087 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.959799E-08 0.000000E+00 218213 218088 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.140593E-05 0.000000E+00 218214 218089 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.388622E-07 0.000000E+00 218215 218090 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.241316E-07 0.000000E+00 218216 218091 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.194606E-07 0.000000E+00 218217 218092 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.197309E-07 0.000000E+00 218218 218093 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.814237E-06 0.000000E+00 218219 218094 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.202255E-07 0.000000E+00 218220 218095 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.509987E-05 0.000000E+00 218221 218096 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.718005E-06 0.000000E+00 218222 218097 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.729884E-06 0.000000E+00 218223 218098 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.347941E-04 0.000000E+00 218224 218099 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.231372E-03 0.000000E+00 218225 218100 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.144850E-07 0.000000E+00 218226 218101 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.354176E-07 0.000000E+00 218227 218102 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.156171E-04 0.000000E+00 218228 218103 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.543603E-07 0.000000E+00 218229 218104 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.812316E-09 0.000000E+00 218230 218105 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.833799E-06 0.000000E+00 218231 218106 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.135694E-05 0.000000E+00 218232 218107 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.923721E-07 0.000000E+00 218233 218108 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154140E-06 0.000000E+00 218234 218109 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.911588E-07 0.000000E+00 218235 218110 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.342910E-05 0.000000E+00 218236 218111 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.893056E-08 0.000000E+00 218237 218112 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.292114E-06 0.000000E+00CHECK 2 (flux weighting of the particle start locations): The flux weighted particle placement is accomplished within cr8sptr.c If this algorithm is working correctly there will be a linear relationship between the number of particles in a cell and the flux moving through that cell. A simple check of the working of this piece of the routine is to plot the number of particles per cell versus the flux in that cell for all 500 cells. If the scatter plot defines a straight line, the particles are being located properly. An example run was made with cr8sptr.c (same run as used in Check 1) and the results are shown in Figure XIII-1 below. The coefficient of determination (r2 value) for the linear regression calculated through the points is 0.99997. The relationship between flux and starting locations is linear and the flux weighting with the routine is working. [Figure X111-1] CHECK 3 (visual inspection of output file): The output from cr8sptr.c is written to the file sptr.dat. The top 50 lines of this file from the example run discussed above are shown below. The header information is consistent with the parameterization of the FEHM sptr macro for this study. The columns of numbers below the header specify a dummy cell number and the X,Y and Z coordinates of each particles starting location. If the X,Y and Z coordinates are specified, then the cell number is not used in the FEHM sptr macro; however, the file format requires that a cell number be in the input file even though it is not read. This is the reason the dummy cell number ("30837") begins each line.
sptr 1.0e+20 0 1 0 0 0 0 0 0 0 0 100 1 10 1 10 100. 495. -20. 300. 1. 10. 30837 55.442 482.000 -19.851 30837 53.672 482.000 -18.579 30837 52.569 482.000 -18.899 30837 56.986 482.000 -18.434 30837 58.260 482.000 -18.800 30837 63.351 482.000 -19.460 30837 62.254 482.000 -19.644 30837 61.309 482.000 -19.377 30837 66.974 482.000 -18.493 30837 67.613 482.000 -19.585 30837 65.771 482.000 -19.417 30837 64.907 482.000 -19.251 30837 65.934 482.000 -18.300 30837 66.964 482.000 -19.170 30837 66.803 482.000 -18.193 30837 67.918 482.000 -19.308 30837 66.719 482.000 -18.937 30837 64.514 482.000 -18.245 30837 64.699 482.000 -18.426 30837 67.310 482.000 -18.404 30837 67.939 482.000 -19.063 30837 66.338 482.000 -18.236 30837 65.165 482.000 -19.479 30837 66.061 482.000 -19.275 30837 66.089 482.000 -18.922 30837 65.687 482.000 -19.907 30837 64.645 482.000 -19.168 30837 67.825 482.000 -18.413 30837 64.983 482.000 -19.899 30837 64.645 482.000 -18.040 30837 65.100 482.000 -18.067 30837 65.558 482.000 -18.726 30837 65.661 482.000 -18.612 30837 64.583 482.000 -18.891 30837 66.122 482.000 -19.175 30837 64.693 482.000 -18.212 30837 66.898 482.000 -18.885 30837 65.484 482.000 -18.979 30837 66.188 482.000 -19.285 30837 66.677 482.000 -18.554 30837 67.618 482.000 -19.583RESULTS OF TESTING The three checks done to test the cr8sptr.c routine confirmed that the routine finds the correct data set in the input file, correctly sums the fluxes, correctly determines the flux-weighted starting locations of the particles and produces output in the correct format to be read by the sptr macro in FEHM. The results of these checks prove that the required functionality of the routine works within the range of the routine design SOURCE CODE: #include <stdio.h>
/* Create the input file for the FEHM macro "sptr". This macro governs the streamline particle tracking. The idea here is to write the header info for sptr and then all of the xyz starting locations for the particles. The starting locations will be derived from a flux weighting scheme based on fluxes calculated in the "flxo" macro of FEHM. The total number of particles to track will be set inside this code by the user. Hoping to do 1-2000 for outputs at a plane or more like 10-20 that are tracked all the way through. */ #define MBIG 1000000000 #define MSEED 161803398 #define MZ 0 #define FAC (1.0/MBIG) char *read_line (); float get_big_C (); float ran2(); void nrerror(); void write_header_1 (); /*----------------------------------------------------------------------------*/ char *read_line (stream) FILE *stream; { static char string[512]; string[0] = '\0'; do fgets (string, 512, stream); while ((string[0] == '!') && !feof (stream)); return (string); } /*----------------------------------------------------------------------------*/ void write_header_1 (fp,fin_time) FILE *fp; float fin_time; /* write FEHM header information to output file */ { fprintf (fp,"sptr\n"); fprintf (fp,"1.0e+20 0 1\n"); fprintf (fp,"0 0\n"); fprintf (fp,"0 0 0 0 0 0\n"); fprintf (fp,"100 1\n"); fprintf (fp,"10 1 10\n"); fprintf (fp,"100. 495. -20.\n"); fprintf (fp,"300. 1. 10.\n"); } /*----------------------------------------------------------------------------*/ float get_big_C (index,offset,del) int index; float offset,del; /* given the index, the offset to the origin of the flux weighted subdomain and the delta of the grid, determine the coordinate at the lower left corner of the current gridblock for positive coordinate system and at the upper left corner of the block for a negative down coordinated system such as that used here for the z axis */ { float coord; if (offset >= 0.0) coord = offset + (float)index * del; else coord = offset - (float)index * del; return (coord); } /*----------------------------------------------------------------------------*/ float ran3(idum) int *idum; /* Returns a uniform random deviate between 0.0 and 1.0. Set idum to any negative value to initialize or reinitialize the sequence. Taken from page 213 of Numerical Recipes in C. */ { static int inext,inextp; static long ma[56]; static int iff=0; long mj,mk; int i,ii,k; if (*idum < 0 || iff == 0) { iff=1; mj=MSEED-(*idum < 0 ? -*idum : *idum); mj %= MBIG; ma[55] = mj; mk=1; for (i=1;i<=54;i++) { ii=(21*i) % 55; ma[ii] = mk; mk=mj-mk; if (mk < MZ) mk += MBIG; mj=ma[ii]; } for (k=1;k<=4;k++) for (i=1;i<=55;i++) { ma[i] -= ma[1+(i+30) % 55]; if (ma[i] < MZ) ma[i] += MBIG; } inext=0; inextp=31; *idum=1; } if (++inext == 56) inext=1; if (++inextp == 56) inextp=1; mj=ma[inext]-ma[inextp]; if (mj < MZ) mj += MBIG; ma[inext]=mj; return (mj*FAC); } /*----------------------------------------------------------------------------*/ void nrerror(error_text) char error_text[]; /* Numerical recipes standard error handler */ { fprintf (stderr, "Run Time Error\n"); fprintf (stderr, "%s\n",error_text); fprintf (stderr, "Exiting Program\n\n"); exit(1); } /*----------------------------------------------------------------------------*/ main () { FILE *stream1, *stream2; char string[256],file1[256],file2[256],line[800]; char st1[8],st2[8],st3[8],st4[8]; double flux[101][2][6],flux_tot,pp_fac; int i,j,k,l,nx,ny,nz,target_n,npart_tot,npart[101][2][6],cnt,nn; int node1,node2,len,time_steps,final_cnt,part_diff,filter; float delx,dely,delz,j1,j2,j3,j4,j5,fin_time,big_x,big_y,big_z; float x_off,y_off,z_off,rnum1,rnum2; long seed; seed = 12345; rnum1 = 1.000; rnum2 = 1.000; /* size of flux weighted boundary zone, _not_ the size of the model domain */ nx = 100; ny = 1; nz = 5; delx = dely = 4.0; delz = 2.0; /* Currently just guesses for the lower, left corner of the subdomain for the flux weighting. Need to ask Bill just how it is being done, ALSO, need to keep in mind that the indices begin at 0 */ x_off = 12.0*delx; y_off = 120.0*dely; z_off = 0.0-(9.0*delz); target_n = 4000; /* requested number of particles */ filter = 5; /* lower limit of number of particles below which the the number cannot be adjusted */ npart_tot = 0; cnt =0; for (k=0;k<nz;k++) for (j=0;j<ny;j++) for (i=0;i<nx;i++) { flux[i][j][k] = 0.0; npart[i][j][k] = 0; } /* open the input and output files */ stream1 = fopen ("het_flow.out", "r"); stream2 = fopen ("sptr.dat", "w"); /* Read in the fluxes/velocities in the screen dump file coming out of FEHM. Using the same logic as for reading MODFLOW screen dump files to get heads. Although, the fluxes are written 3 times (????) for FEHM and we only want the last set */ len = strlen(" Node1 Node2"); nn=0; do { fgets (line, 800, stream1); nn++; } while (strncmp (line," Node1 Node2", len) != 0); fgets (line, 800, stream1); nn++; do { fgets (line, 800, stream1); nn++; } while (strncmp (line," Node1 Node2", len) != 0); fgets (line, 800, stream1); nn++; do { fgets (line, 800, stream1); nn++; } while (strncmp (line," Node1 Node2", len) != 0); /* Now read in the fluxes and retain the sum. For the problem setup here, the fluxes are negative in the flow direction. For purposes of flux weighting, convert them to positive numbers */ flux_tot = 0.0; for (k=0;k<nz;k++) { for (j=0;j<ny;j++) { for (i=0;i<nx;i++) { nn++; fscanf (stream1, "%d %d %f %f %f %f %lf %f", &node1,&node2,&j1,&j2,&j3,&j4,&flux[i][j][k],&j5); flux[i][j][k] = -1.0*flux[i][j][k]; if (flux[i][j][k] < 0) flux[i][j][k] = 0.000; flux_tot += flux[i][j][k]; } } } pp_fac = (double)target_n/flux_tot; printf ("pp_fac and total flux are: %8.3e %8.3e\n\n", pp_fac,flux_tot); /* Determine the number of particles to put into each gridblock */ for (k=0;k<nz;k++) { for (j=0;j<ny;j++) { for (i=0;i<nx;i++) { npart[i][j][k] = (int)(pp_fac*flux[i][j][k]+0.500); npart_tot += npart[i][j][k]; } } } printf ("Total particles requested: %5d\n", target_n); printf ("Total particles assigned in step 1: %5d\n", npart_tot); part_diff = target_n - npart_tot; printf ("Difference is target - assigned: %3d\n\n", part_diff); /* Continue scanning the input file to locate the final simulation time, it is located three lines below the "Conservation Errors:" line */ len = strlen(" Conservation Errors:"); do { fgets (line, 800, stream1); nn++; } while (strncmp (line," Conservation Errors:", len) != 0); fgets (line, 800, stream1); nn++; fgets (line, 800, stream1); nn++; fgets (line, 800, stream1); nn++; sscanf(line,"%s %s %s %f %s %d", &st1,&st2,&st3,&fin_time,&st4,&time_steps); printf ("Final simulation time is %8.3e days\n\n", fin_time); fclose (stream1); /* write out the "sptr" macro for FEHM */ write_header_1 (stream2,fin_time); final_cnt = 0; for (k=0;k<nz;k++) { for (j=0;j<ny;j++) { for (i=0;i<nx;i++) { if (npart[i][j][k] == 0) continue; else { big_x = get_big_C (i,x_off,delx); big_y = get_big_C (j,y_off,dely); big_z = get_big_C (k,z_off,delz); /* keep doing ad hoc adjustment to the number of particles in a given cell until the target and actual particle numbers are equal. Don't mess with any cells where npart < filter. */ if ((part_diff > 0) && (npart[i][j][k] >= filter)) { npart[i][j][k] += 1; part_diff -= 1; } else if ((part_diff < 0) && (npart[i][j][k] >= filter)) { npart[i][j][k] -= 1; part_diff += 1; } /* now assign random starting locations to the particles within the given cell. Note that z is negative down */ for (l=0;l<npart[i][j][k];l++) { rnum1 = ran3(&seed); rnum2 = ran3(&seed); fprintf (stream2," 30837 %7.3f %7.3f %7.3f\n", big_x+rnum1*delx,big_y+dely/2.0,big_z-rnum2*delz); final_cnt++; } } } } } printf ("Total particles requested: %5d\n", target_n); printf ("Total particles assigned at end of step 2: %5d\n\n", final_cnt); if (target_n != final_cnt) { printf ("DANGER Will Robinson!!\n"); printf (" Final particle count does not equal target number\n"); printf (" Most likely need to request more particles or decrease filter size\n\n"); } fprintf (stream2,"\n"); fprintf (stream2,"stop\n"); fclose (stream2); }
Attachment XIV: Software routine documentation: cr8sptr_cell.c Routine (Version 1.0) The cr8sptr_cell.c software routine is used to read in the output of the flxo macro in FEHM and determine the starting locations of the streamlines for the sptr particle tracking macro in FEHM. The output of the cr8sptr_cell.c routine is written in the format necessary to be read by the sptr macro. The starting locations of the particles are randomly located in the cell with the highest flux value in the flxo output. This routine is very similar to the cr8sptr.c routine with the exception of placing all the streamline particle-starting locations in the cell with the highest flux, rather than using a flux-weighted scheme as done in cr8sptr.c. The cr8sptr_cell.c software routine is written in the C programming language on a Sun Ultra Sparc Server. The version of the C compiler is 4.2 and the operating system is Solaris 2.7. The functionality of the cr8sptr_cell.c software routine is tested in three ways:
Max Flux occurs at: 93 0 0 With Coordinates: 420.00 480.00 -18.00 Total particles requested: 4000 Total particles assigned at end of step 2: 4000From the first line, the cell with the maximum flux has X,Y and Z indices of 0, 0, 93 the upper left corner coordinates are 420.0, 480.0 and -18.0. This is the 94th cell in the flxo output (Indices are numbered starting at zero). The FEHM macro flxo provides the input for this software routine. The output from flxo is written to the screen as a screen dump during the running of FEHM. The flxo output is written three times and the final time provides the flux values for the 500 designated cells at steady state. This third and final output from the flxo macro is shown below for an example run The flux values in column 7 are converted to positive numbers and summed (the negative number in the output indicates the direction of flow, we are only concerned with magnitude of the flux). Any numbers that indicate flux in the opposite direction (negative numbers after the sign change) are set to zero such that no particles will be started in those cells. These zero values are used in the summation. The flxo output below was read into Excel, the sign of the numbers was changed, and any negative values remaining after the sign change were converted to zeroes. The maximum value was then determined with the MAX function, and it returned the flux value on the 94th line of the file corresponding to the indices of 0, 0, 93 as determined by the cr8sptr_cell.c routine.
Internode Fluxes Node1 Node2 X,Y,Z Vapor Flux(kg/sec) X,Y,Z Liquid Flux (kg/sec) 155638 155513 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.712752E-07 0.000000E+00 155639 155514 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.226774E-05 0.000000E+00 155640 155515 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.127233E-05 0.000000E+00 155641 155516 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.264136E-05 0.000000E+00 155642 155517 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.550743E-04 0.000000E+00 155643 155518 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.113521E-04 0.000000E+00 155644 155519 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.453207E-08 0.000000E+00 155645 155520 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.857072E-08 0.000000E+00 155646 155521 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.179074E-06 0.000000E+00 155647 155522 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.333594E-06 0.000000E+00 155648 155523 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.709377E-06 0.000000E+00 155649 155524 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.649807E-07 0.000000E+00 155650 155525 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.206155E-06 0.000000E+00 155651 155526 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.234651E-06 0.000000E+00 155652 155527 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.572755E-07 0.000000E+00 155653 155528 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.660471E-07 0.000000E+00 155654 155529 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.166451E-09 0.000000E+00 155655 155530 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.638951E-05 0.000000E+00 155656 155531 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.361878E-10 0.000000E+00 155657 155532 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.601006E-08 0.000000E+00 155658 155533 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.577183E-07 0.000000E+00 155659 155534 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.728317E-05 0.000000E+00 155660 155535 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.376014E-08 0.000000E+00 155661 155536 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.167448E-06 0.000000E+00 155662 155537 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.521587E-07 0.000000E+00 155663 155538 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.522938E-10 0.000000E+00 155664 155539 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.656947E-07 0.000000E+00 155665 155540 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.266192E-06 0.000000E+00 155666 155541 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.282939E-07 0.000000E+00 155667 155542 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.771346E-07 0.000000E+00 155668 155543 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.413010E-09 0.000000E+00 155669 155544 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.104130E-05 0.000000E+00 155670 155545 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.308429E-05 0.000000E+00 155671 155546 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.110011E-07 0.000000E+00 155672 155547 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.188751E-07 0.000000E+00 155673 155548 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.324748E-05 0.000000E+00 155674 155549 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.431083E-06 0.000000E+00 155675 155550 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.143547E-03 0.000000E+00 155676 155551 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.124666E-08 0.000000E+00 155677 155552 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.300589E-07 0.000000E+00 155678 155553 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.121235E-05 0.000000E+00 155679 155554 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.297295E-06 0.000000E+00 155680 155555 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.185165E-07 0.000000E+00 155681 155556 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.474439E-04 0.000000E+00 155682 155557 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.135775E-08 0.000000E+00 155683 155558 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.914389E-06 0.000000E+00 155684 155559 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.354780E-07 0.000000E+00 155685 155560 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.407558E-05 0.000000E+00 155686 155561 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.483210E-08 0.000000E+00 155687 155562 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.559679E-07 0.000000E+00 155688 155563 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.148144E-05 0.000000E+00 155689 155564 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.415004E-08 0.000000E+00 155690 155565 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.323312E-09 0.000000E+00 155691 155566 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.153404E-06 0.000000E+00 155692 155567 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.455093E-07 0.000000E+00 155693 155568 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.799673E-10 0.000000E+00 155694 155569 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155686E-05 0.000000E+00 155695 155570 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.606638E-09 0.000000E+00 155696 155571 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.304327E-07 0.000000E+00 155697 155572 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.789937E-05 0.000000E+00 155698 155573 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.857557E-08 0.000000E+00 155699 155574 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.571900E-05 0.000000E+00 155700 155575 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.198367E-07 0.000000E+00 155701 155576 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.126990E-06 0.000000E+00 155702 155577 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.515676E-05 0.000000E+00 155703 155578 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.510269E-08 0.000000E+00 155704 155579 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.182161E-05 0.000000E+00 155705 155580 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.151546E-06 0.000000E+00 155706 155581 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.346580E-09 0.000000E+00 155707 155582 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.259398E-06 0.000000E+00 155708 155583 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.239679E-05 0.000000E+00 155709 155584 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.385179E-10 0.000000E+00 155710 155585 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.768764E-09 0.000000E+00 155711 155586 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.118629E-04 0.000000E+00 155712 155587 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.395465E-08 0.000000E+00 155713 155588 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.127208E-06 0.000000E+00 155714 155589 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.344762E-04 0.000000E+00 155715 155590 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.955926E-08 0.000000E+00 155716 155591 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.101967E-07 0.000000E+00 155717 155592 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.597666E-08 0.000000E+00 155718 155593 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.241876E-07 0.000000E+00 155719 155594 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.105260E-07 0.000000E+00 155720 155595 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.243193E-06 0.000000E+00 155721 155596 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.654799E-05 0.000000E+00 155722 155597 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.807059E-06 0.000000E+00 155723 155598 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.171237E-07 0.000000E+00 155724 155599 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.943445E-07 0.000000E+00 155725 155600 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.158196E-07 0.000000E+00 155726 155601 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.516613E-07 0.000000E+00 155727 155602 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.389093E-05 0.000000E+00 155728 155603 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.177429E-06 0.000000E+00 155729 155604 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.657965E-07 0.000000E+00 155730 155605 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.129648E-06 0.000000E+00 155731 155606 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.257448E-03 0.000000E+00 155732 155607 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.132619E-05 0.000000E+00 155733 155608 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.158651E-09 0.000000E+00 155734 155609 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.148427E-05 0.000000E+00 155735 155610 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.459063E-06 0.000000E+00 155736 155611 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.268370E-06 0.000000E+00 155737 155612 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.619750E-06 0.000000E+00 171263 171138 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.423994E-06 0.000000E+00 171264 171139 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.169743E-04 0.000000E+00 171265 171140 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.916163E-06 0.000000E+00 171266 171141 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.129867E-06 0.000000E+00 171267 171142 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.599029E-04 0.000000E+00 171268 171143 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.716648E-08 0.000000E+00 171269 171144 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.911853E-08 0.000000E+00 171270 171145 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.111074E-07 0.000000E+00 171271 171146 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.140435E-06 0.000000E+00 171272 171147 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.407802E-06 0.000000E+00 171273 171148 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.795657E-07 0.000000E+00 171274 171149 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.580564E-07 0.000000E+00 171275 171150 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.150064E-06 0.000000E+00 171276 171151 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.432307E-06 0.000000E+00 171277 171152 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.971528E-07 0.000000E+00 171278 171153 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.883260E-07 0.000000E+00 171279 171154 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.285747E-04 0.000000E+00 171280 171155 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.583222E-05 0.000000E+00 171281 171156 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.265384E-07 0.000000E+00 171282 171157 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.206381E-07 0.000000E+00 171283 171158 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.243049E-07 0.000000E+00 171284 171159 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.102193E-04 0.000000E+00 171285 171160 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.152461E-07 0.000000E+00 171286 171161 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.645363E-07 0.000000E+00 171287 171162 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.183555E-05 0.000000E+00 171288 171163 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.165334E-09 0.000000E+00 171289 171164 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.898474E-07 0.000000E+00 171290 171165 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.248346E-06 0.000000E+00 171291 171166 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.225430E-07 0.000000E+00 171292 171167 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.449864E-07 0.000000E+00 171293 171168 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.457760E-08 0.000000E+00 171294 171169 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.137437E-05 0.000000E+00 171295 171170 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.411442E-05 0.000000E+00 171296 171171 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.429940E-08 0.000000E+00 171297 171172 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.375314E-07 0.000000E+00 171298 171173 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.160776E-06 0.000000E+00 171299 171174 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.685003E-06 0.000000E+00 171300 171175 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.142378E-03 0.000000E+00 171301 171176 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.891629E-09 0.000000E+00 171302 171177 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.241327E-07 0.000000E+00 171303 171178 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.168780E-07 0.000000E+00 171304 171179 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.248060E-06 0.000000E+00 171305 171180 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.187311E-07 0.000000E+00 171306 171181 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.358867E-04 0.000000E+00 171307 171182 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.994240E-09 0.000000E+00 171308 171183 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.230193E-05 0.000000E+00 171309 171184 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.409721E-06 0.000000E+00 171310 171185 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.786284E-05 0.000000E+00 171311 171186 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154814E-08 0.000000E+00 171312 171187 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.644689E-07 0.000000E+00 171313 171188 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.306139E-05 0.000000E+00 171314 171189 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.114821E-09 0.000000E+00 171315 171190 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.212285E-09 0.000000E+00 171316 171191 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.282442E-06 0.000000E+00 171317 171192 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.422539E-07 0.000000E+00 171318 171193 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.570583E-08 0.000000E+00 171319 171194 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.203973E-05 0.000000E+00 171320 171195 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.348854E-08 0.000000E+00 171321 171196 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.608445E-07 0.000000E+00 171322 171197 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.567937E-05 0.000000E+00 171323 171198 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.181253E-07 0.000000E+00 171324 171199 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.264325E-05 0.000000E+00 171325 171200 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.157358E-07 0.000000E+00 171326 171201 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154932E-06 0.000000E+00 171327 171202 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.464688E-05 0.000000E+00 171328 171203 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.284359E-09 0.000000E+00 171329 171204 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.201487E-05 0.000000E+00 171330 171205 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.768847E-07 0.000000E+00 171331 171206 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.221908E-07 0.000000E+00 171332 171207 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.890164E-10 0.000000E+00 171333 171208 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.268676E-04 0.000000E+00 171334 171209 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.222949E-04 0.000000E+00 171335 171210 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.275018E-10 0.000000E+00 171336 171211 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.104985E-04 0.000000E+00 171337 171212 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.696395E-08 0.000000E+00 171338 171213 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.224685E-06 0.000000E+00 171339 171214 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.191306E-04 0.000000E+00 171340 171215 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.618515E-08 0.000000E+00 171341 171216 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.514689E-07 0.000000E+00 171342 171217 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.309938E-07 0.000000E+00 171343 171218 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.690398E-07 0.000000E+00 171344 171219 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.103656E-07 0.000000E+00 171345 171220 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.214579E-06 0.000000E+00 171346 171221 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.197921E-05 0.000000E+00 171347 171222 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.108152E-05 0.000000E+00 171348 171223 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.274700E-07 0.000000E+00 171349 171224 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.142920E-06 0.000000E+00 171350 171225 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.211206E-07 0.000000E+00 171351 171226 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.438010E-07 0.000000E+00 171352 171227 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.169661E-05 0.000000E+00 171353 171228 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.679295E-07 0.000000E+00 171354 171229 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.173496E-07 0.000000E+00 171355 171230 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.477761E-05 0.000000E+00 171356 171231 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.227692E-08 0.000000E+00 171357 171232 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.887528E-07 0.000000E+00 171358 171233 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.176997E-09 0.000000E+00 171359 171234 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.897392E-07 0.000000E+00 171360 171235 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.405783E-06 0.000000E+00 171361 171236 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.383955E-05 0.000000E+00 171362 171237 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.757902E-06 0.000000E+00 186888 186763 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.214950E-06 0.000000E+00 186889 186764 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.130460E-04 0.000000E+00 186890 186765 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.851044E-06 0.000000E+00 186891 186766 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.246254E-07 0.000000E+00 186892 186767 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.821533E-09 0.000000E+00 186893 186768 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.208034E-05 0.000000E+00 186894 186769 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.106030E-07 0.000000E+00 186895 186770 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.927399E-08 0.000000E+00 186896 186771 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.365914E-06 0.000000E+00 186897 186772 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.537466E-06 0.000000E+00 186898 186773 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.234021E-10 0.000000E+00 186899 186774 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.372904E-07 0.000000E+00 186900 186775 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.822897E-06 0.000000E+00 186901 186776 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.223682E-06 0.000000E+00 186902 186777 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.515598E-07 0.000000E+00 186903 186778 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.315820E-07 0.000000E+00 186904 186779 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.250526E-04 0.000000E+00 186905 186780 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.565097E-05 0.000000E+00 186906 186781 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.138686E-07 0.000000E+00 186907 186782 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.110433E-07 0.000000E+00 186908 186783 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.305624E-07 0.000000E+00 186909 186784 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.746976E-05 0.000000E+00 186910 186785 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.122800E-07 0.000000E+00 186911 186786 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.383087E-04 0.000000E+00 186912 186787 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.120856E-05 0.000000E+00 186913 186788 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.137832E-07 0.000000E+00 186914 186789 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.225897E-07 0.000000E+00 186915 186790 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.567575E-05 0.000000E+00 186916 186791 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.174294E-07 0.000000E+00 186917 186792 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.274347E-07 0.000000E+00 186918 186793 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.151249E-07 0.000000E+00 186919 186794 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.326587E-08 0.000000E+00 186920 186795 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.130036E-05 0.000000E+00 186921 186796 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.331049E-08 0.000000E+00 186922 186797 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.526617E-07 0.000000E+00 186923 186798 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.369705E-09 0.000000E+00 186924 186799 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.298226E-05 0.000000E+00 186925 186800 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.141107E-03 0.000000E+00 186926 186801 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.285346E-10 0.000000E+00 186927 186802 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.739368E-07 0.000000E+00 186928 186803 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.882519E-07 0.000000E+00 186929 186804 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.114241E-07 0.000000E+00 186930 186805 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.246605E-07 0.000000E+00 186931 186806 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154862E-04 0.000000E+00 186932 186807 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.340916E-07 0.000000E+00 186933 186808 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.597170E-05 0.000000E+00 186934 186809 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.256598E-06 0.000000E+00 186935 186810 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.444097E-05 0.000000E+00 186936 186811 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.252688E-05 0.000000E+00 186937 186812 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.344597E-07 0.000000E+00 186938 186813 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.914038E-06 0.000000E+00 186939 186814 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.184534E-07 0.000000E+00 186940 186815 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.300415E-09 0.000000E+00 186941 186816 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.162636E-05 0.000000E+00 186942 186817 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.207800E-07 0.000000E+00 186943 186818 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.886810E-09 0.000000E+00 186944 186819 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.774395E-06 0.000000E+00 186945 186820 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.774752E-10 0.000000E+00 186946 186821 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.925222E-07 0.000000E+00 186947 186822 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.309368E-05 0.000000E+00 186948 186823 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.195833E-05 0.000000E+00 186949 186824 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.607478E-06 0.000000E+00 186950 186825 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.898886E-08 0.000000E+00 186951 186826 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.146138E-08 0.000000E+00 186952 186827 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.332705E-05 0.000000E+00 186953 186828 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.530405E-08 0.000000E+00 186954 186829 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.151758E-05 0.000000E+00 186955 186830 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.209980E-05 0.000000E+00 186956 186831 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.273420E-04 0.000000E+00 186957 186832 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.532862E-09 0.000000E+00 186958 186833 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.258901E-04 0.000000E+00 186959 186834 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.467744E-07 0.000000E+00 186960 186835 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.208916E-10 0.000000E+00 186961 186836 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.136542E-06 0.000000E+00 186962 186837 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.148637E-07 0.000000E+00 186963 186838 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.614139E-06 0.000000E+00 186964 186839 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.184538E-04 0.000000E+00 186965 186840 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.675110E-08 0.000000E+00 186966 186841 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.324651E-07 0.000000E+00 186967 186842 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.123691E-06 0.000000E+00 186968 186843 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.177220E-06 0.000000E+00 186969 186844 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.317130E-07 0.000000E+00 186970 186845 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.821282E-06 0.000000E+00 186971 186846 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.168582E-05 0.000000E+00 186972 186847 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155236E-05 0.000000E+00 186973 186848 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.464256E-07 0.000000E+00 186974 186849 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.243578E-03 0.000000E+00 186975 186850 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.107930E-07 0.000000E+00 186976 186851 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.193292E-07 0.000000E+00 186977 186852 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.205476E-04 0.000000E+00 186978 186853 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.466610E-07 0.000000E+00 186979 186854 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.200365E-07 0.000000E+00 186980 186855 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.134729E-05 0.000000E+00 186981 186856 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.117966E-09 0.000000E+00 186982 186857 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.601081E-07 0.000000E+00 186983 186858 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.417807E-08 0.000000E+00 186984 186859 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.191059E-06 0.000000E+00 186985 186860 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.339589E-06 0.000000E+00 186986 186861 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.775899E-05 0.000000E+00 186987 186862 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.170345E-05 0.000000E+00 202513 202388 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.361007E-06 0.000000E+00 202514 202389 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.108612E-04 0.000000E+00 202515 202390 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.285807E-07 0.000000E+00 202516 202391 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.295866E-05 0.000000E+00 202517 202392 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.240877E-08 0.000000E+00 202518 202393 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.133471E-04 0.000000E+00 202519 202394 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154780E-07 0.000000E+00 202520 202395 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.992945E-08 0.000000E+00 202521 202396 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.420650E-06 0.000000E+00 202522 202397 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.408846E-06 0.000000E+00 202523 202398 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.269112E-09 0.000000E+00 202524 202399 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.424374E-07 0.000000E+00 202525 202400 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.438136E-06 0.000000E+00 202526 202401 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.118551E-06 0.000000E+00 202527 202402 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.447627E-07 0.000000E+00 202528 202403 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.586355E-07 0.000000E+00 202529 202404 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.493577E-04 0.000000E+00 202530 202405 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.645434E-05 0.000000E+00 202531 202406 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.171662E-07 0.000000E+00 202532 202407 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.111841E-07 0.000000E+00 202533 202408 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.138711E-07 0.000000E+00 202534 202409 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.940584E-05 0.000000E+00 202535 202410 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.315905E-08 0.000000E+00 202536 202411 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.318288E-04 0.000000E+00 202537 202412 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.485275E-06 0.000000E+00 202538 202413 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.845192E-07 0.000000E+00 202539 202414 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.218341E-06 0.000000E+00 202540 202415 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.692886E-05 0.000000E+00 202541 202416 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.314963E-07 0.000000E+00 202542 202417 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.114361E-07 0.000000E+00 202543 202418 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.335869E-08 0.000000E+00 202544 202419 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.158701E-08 0.000000E+00 202545 202420 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.485949E-06 0.000000E+00 202546 202421 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.849957E-08 0.000000E+00 202547 202422 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.117648E-06 0.000000E+00 202548 202423 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.486635E-08 0.000000E+00 202549 202424 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.378916E-05 0.000000E+00 202550 202425 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.139928E-03 0.000000E+00 202551 202426 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.409327E-07 0.000000E+00 202552 202427 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.103560E-06 0.000000E+00 202553 202428 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.425886E-07 0.000000E+00 202554 202429 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.231629E-07 0.000000E+00 202555 202430 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.135431E-06 0.000000E+00 202556 202431 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.324206E-04 0.000000E+00 202557 202432 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.392070E-05 0.000000E+00 202558 202433 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.446774E-05 0.000000E+00 202559 202434 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.238504E-06 0.000000E+00 202560 202435 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.877541E-05 0.000000E+00 202561 202436 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.294104E-05 0.000000E+00 202562 202437 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.345835E-05 0.000000E+00 202563 202438 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.637859E-06 0.000000E+00 202564 202439 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.292363E-07 0.000000E+00 202565 202440 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.687483E-07 0.000000E+00 202566 202441 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.244850E-05 0.000000E+00 202567 202442 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.207600E-07 0.000000E+00 202568 202443 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.883667E-10 0.000000E+00 202569 202444 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.305035E-06 0.000000E+00 202570 202445 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.131101E-09 0.000000E+00 202571 202446 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.143733E-06 0.000000E+00 202572 202447 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.394717E-05 0.000000E+00 202573 202448 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.237562E-05 0.000000E+00 202574 202449 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.772855E-06 0.000000E+00 202575 202450 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.147307E-05 0.000000E+00 202576 202451 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.115567E-07 0.000000E+00 202577 202452 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.814818E-07 0.000000E+00 202578 202453 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.731202E-08 0.000000E+00 202579 202454 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.405142E-05 0.000000E+00 202580 202455 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.636567E-05 0.000000E+00 202581 202456 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.118319E-04 0.000000E+00 202582 202457 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.131875E-07 0.000000E+00 202583 202458 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.231796E-04 0.000000E+00 202584 202459 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.234372E-07 0.000000E+00 202585 202460 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.352987E-10 0.000000E+00 202586 202461 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.123320E-07 0.000000E+00 202587 202462 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.835457E-08 0.000000E+00 202588 202463 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.132962E-05 0.000000E+00 202589 202464 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.546449E-07 0.000000E+00 202590 202465 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.649531E-08 0.000000E+00 202591 202466 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.152542E-07 0.000000E+00 202592 202467 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.537060E-08 0.000000E+00 202593 202468 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.533780E-06 0.000000E+00 202594 202469 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.653662E-07 0.000000E+00 202595 202470 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.556183E-05 0.000000E+00 202596 202471 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.611290E-06 0.000000E+00 202597 202472 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.976825E-06 0.000000E+00 202598 202473 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.290978E-07 0.000000E+00 202599 202474 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.238601E-03 0.000000E+00 202600 202475 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.147497E-07 0.000000E+00 202601 202476 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.348440E-07 0.000000E+00 202602 202477 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.167519E-04 0.000000E+00 202603 202478 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.129476E-06 0.000000E+00 202604 202479 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.840925E-08 0.000000E+00 202605 202480 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.142028E-06 0.000000E+00 202606 202481 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.535950E-05 0.000000E+00 202607 202482 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.277998E-06 0.000000E+00 202608 202483 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.140631E-05 0.000000E+00 202609 202484 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.128862E-06 0.000000E+00 202610 202485 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.319683E-06 0.000000E+00 202611 202486 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.449786E-05 0.000000E+00 202612 202487 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.227803E-06 0.000000E+00 218138 218013 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.447174E-06 0.000000E+00 218139 218014 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.316196E-10 0.000000E+00 218140 218015 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.304798E-07 0.000000E+00 218141 218016 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.217288E-05 0.000000E+00 218142 218017 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.612319E-04 0.000000E+00 218143 218018 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.607152E-05 0.000000E+00 218144 218019 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.224676E-07 0.000000E+00 218145 218020 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.868943E-05 0.000000E+00 218146 218021 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.108513E-06 0.000000E+00 218147 218022 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.446494E-06 0.000000E+00 218148 218023 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155213E-06 0.000000E+00 218149 218024 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.232154E-07 0.000000E+00 218150 218025 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.350975E-06 0.000000E+00 218151 218026 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.194399E-06 0.000000E+00 218152 218027 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.409879E-07 0.000000E+00 218153 218028 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.130903E-06 0.000000E+00 218154 218029 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.361340E-04 0.000000E+00 218155 218030 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.623667E-05 0.000000E+00 218156 218031 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.240124E-07 0.000000E+00 218157 218032 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.116086E-07 0.000000E+00 218158 218033 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.179845E-07 0.000000E+00 218159 218034 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.256327E-08 0.000000E+00 218160 218035 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.171026E-05 0.000000E+00 218161 218036 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.987706E-07 0.000000E+00 218162 218037 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.230388E-06 0.000000E+00 218163 218038 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.265946E-07 0.000000E+00 218164 218039 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.367272E-05 0.000000E+00 218165 218040 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.898553E-05 0.000000E+00 218166 218041 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.275607E-07 0.000000E+00 218167 218042 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.111608E-07 0.000000E+00 218168 218043 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.164084E-07 0.000000E+00 218169 218044 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.530732E-06 0.000000E+00 218170 218045 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.201889E-04 0.000000E+00 218171 218046 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.113523E-07 0.000000E+00 218172 218047 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.461255E-07 0.000000E+00 218173 218048 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.664410E-06 0.000000E+00 218174 218049 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.160854E-05 0.000000E+00 218175 218050 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.139640E-03 0.000000E+00 218176 218051 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.628889E-07 0.000000E+00 218177 218052 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.766898E-06 0.000000E+00 218178 218053 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.155874E-04 0.000000E+00 218179 218054 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.107814E-07 0.000000E+00 218180 218055 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.292950E-08 0.000000E+00 218181 218056 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.132686E-04 0.000000E+00 218182 218057 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.256900E-05 0.000000E+00 218183 218058 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.572920E-06 0.000000E+00 218184 218059 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.206551E-06 0.000000E+00 218185 218060 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.671334E-06 0.000000E+00 218186 218061 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.394884E-08 0.000000E+00 218187 218062 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.366409E-05 0.000000E+00 218188 218063 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.529741E-06 0.000000E+00 218189 218064 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.183119E-07 0.000000E+00 218190 218065 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.182166E-09 0.000000E+00 218191 218066 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.342523E-07 0.000000E+00 218192 218067 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.861261E-05 0.000000E+00 218193 218068 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.183942E-08 0.000000E+00 218194 218069 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.124462E-05 0.000000E+00 218195 218070 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.354869E-09 0.000000E+00 218196 218071 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.120017E-06 0.000000E+00 218197 218072 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.355767E-06 0.000000E+00 218198 218073 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.352665E-05 0.000000E+00 218199 218074 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.318501E-08 0.000000E+00 218200 218075 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.271898E-05 0.000000E+00 218201 218076 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.927548E-08 0.000000E+00 218202 218077 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.668274E-07 0.000000E+00 218203 218078 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.326892E-09 0.000000E+00 218204 218079 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.366661E-05 0.000000E+00 218205 218080 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.169872E-05 0.000000E+00 218206 218081 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.139478E-04 0.000000E+00 218207 218082 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.332128E-07 0.000000E+00 218208 218083 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.210968E-04 0.000000E+00 218209 218084 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.117372E-07 0.000000E+00 218210 218085 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.855757E-10 0.000000E+00 218211 218086 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.337532E-04 0.000000E+00 218212 218087 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.959799E-08 0.000000E+00 218213 218088 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.140593E-05 0.000000E+00 218214 218089 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.388622E-07 0.000000E+00 218215 218090 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.241316E-07 0.000000E+00 218216 218091 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 0.194606E-07 0.000000E+00 218217 218092 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.197309E-07 0.000000E+00 218218 218093 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.814237E-06 0.000000E+00 218219 218094 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.202255E-07 0.000000E+00 218220 218095 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.509987E-05 0.000000E+00 218221 218096 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.718005E-06 0.000000E+00 218222 218097 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.729884E-06 0.000000E+00 218223 218098 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.347941E-04 0.000000E+00 218224 218099 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.231372E-03 0.000000E+00 218225 218100 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.144850E-07 0.000000E+00 218226 218101 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.354176E-07 0.000000E+00 218227 218102 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.156171E-04 0.000000E+00 218228 218103 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.543603E-07 0.000000E+00 218229 218104 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.812316E-09 0.000000E+00 218230 218105 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.833799E-06 0.000000E+00 218231 218106 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.135694E-05 0.000000E+00 218232 218107 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.923721E-07 0.000000E+00 218233 218108 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.154140E-06 0.000000E+00 218234 218109 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.911588E-07 0.000000E+00 218235 218110 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.342910E-05 0.000000E+00 218236 218111 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.893056E-08 0.000000E+00 218237 218112 0.000000E+00 0.000000E+00 0.000000E+00 0.000000E+00 -.292114E-06 0.000000E+00CHECK 2 (random location of the particle start locations): The random particle placement within the cell having the highest flux is accomplished within cr8sptr_cell.c. If this algorithm is working correctly, the particle locations will randomly and uniformly populate the domain of the chose cell. A simple check of the working of this piece of the routine is to plot the locations of all 4000 particles started in the chosen cell. If the scatter plot shows a uniformly random placement of the particles, then the particles are being located properly. An example run was made with cr8sptr_cell.c (same run as used in Check 1) and the results are shown in Figure XIV-1 below. The start locations are random and the routine is working correctly [Figure XIV-1] CHECK 3 (visual inspection of output file): The output from cr8sptr_cell.c is written to the file sptr_cell.dat. The top 50 lines of this file from the example run discussed above are shown below. The header information is consistent with the parameterization of the FEHM sptr macro for this study. The columns of numbers below the header specify a dummy cell number and the X,Y and Z coordinates of each particles starting location. If the X,Y and Z coordinates are specified, then the cell number is not used in the FEHM sptr macro; however, the file format requires that a cell number be in the input file even though it is not read. This is the reason the dummy cell number ("30837") begins each line.
sptr 1.0e+20 0 1 0 0 0 0 0 0 0 0 100 1 10 1 10 100. 495. -20. 300. 1. 10. 30837 423.442 482.000 -19.851 30837 421.672 482.000 -18.579 30837 420.569 482.000 -18.899 30837 420.986 482.000 -18.434 30837 422.260 482.000 -18.800 30837 423.351 482.000 -19.460 30837 422.254 482.000 -19.644 30837 421.309 482.000 -19.377 30837 422.974 482.000 -18.493 30837 423.613 482.000 -19.585 30837 421.771 482.000 -19.417 30837 420.907 482.000 -19.251 30837 421.934 482.000 -18.300 30837 422.964 482.000 -19.170 30837 422.803 482.000 -18.193 30837 423.918 482.000 -19.308 30837 422.719 482.000 -18.937 30837 420.514 482.000 -18.245 30837 420.699 482.000 -18.426 30837 423.310 482.000 -18.404 30837 423.939 482.000 -19.063 30837 422.338 482.000 -18.236 30837 421.165 482.000 -19.479 30837 422.061 482.000 -19.275 30837 422.089 482.000 -18.922 30837 421.687 482.000 -19.907 30837 420.645 482.000 -19.168 30837 423.825 482.000 -18.413 30837 420.983 482.000 -19.899 30837 420.645 482.000 -18.040 30837 421.100 482.000 -18.067 30837 421.558 482.000 -18.726 30837 421.661 482.000 -18.612 30837 420.583 482.000 -18.891 30837 422.122 482.000 -19.175 30837 420.693 482.000 -18.212 30837 422.898 482.000 -18.885 30837 421.484 482.000 -18.979 30837 422.188 482.000 -19.285 30837 422.677 482.000 -18.554 30837 423.618 482.000 -19.583 30837 421.696 482.000 -19.362RESULTS OF TESTING The three checks done to test the cr8sptr_cell.c routine confirmed that the routine, correctly finds the model cell in the flxo output with the maximum flux, correctly determines the random starting locations of the particles within the cell having the maximum amount of flux and produces output in the correct format to be read by the sptr macro in FEHM. The results of these checks prove that the required functionality of the routine works within the range of the routine design SOURCE CODE:
#include <stdio.h> #include <math.h> #include <string.h> /* Create the input file for the FEHM macro "sptr". This macro governs the streamline particle tracking. The idea here is to write the header info for sptr and then all of the xyz starting locations for the particles. The starting locations will be derived from a flux weighting scheme based on fluxes calculated in the "flxo" macro of FEHM. The total number of particles to track will be set inside this code by the user. Hoping to do 1-2000 for outputs at a plane or more like 10-20 that are tracked all the way through. This is the point source version. All particles are started at the cell with the highest flux. Using 4000 particles. */ #define MBIG 1000000000 #define MSEED 161803398 #define MZ 0 #define FAC (1.0/MBIG) char *read_line (); float get_big_C (); float ran2(); void nrerror(); void write_header_1 (); /*----------------------------------------------------------------------------*/ char *read_line (stream) FILE *stream; { static char string[512]; string[0] = '\0'; do fgets (string, 512, stream); while ((string[0] == '!') && !feof (stream)); return (string); } /*----------------------------------------------------------------------------*/ void write_header_1 (fp) FILE *fp; /* write FEHM header information to output file */ { fprintf (fp,"sptr\n"); fprintf (fp,"1.0e+20 0 1\n"); fprintf (fp,"0 0\n"); fprintf (fp,"0 0 0 0 0 0\n"); fprintf (fp,"100 1\n"); fprintf (fp,"10 1 10\n"); fprintf (fp,"100. 495. -20.\n"); fprintf (fp,"300. 1. 10.\n"); } /*----------------------------------------------------------------------------*/ float get_big_C (index,offset,del) int index; float offset,del; /* given the index, the offset to the origin of the flux weighted subdomain and the delta of the grid, determine the coordinate at the lower left corner of the current gridblock for positive coordinate system and at the upper left corner of the block for a negative down coordinated system such as that used here for the z axis */ { float coord; if (offset >= 0.0) coord = offset + (float)index * del; else coord = offset - (float)index * del; return (coord); } /*----------------------------------------------------------------------------*/ float ran3(idum) int *idum; /* Returns a uniform random deviate between 0.0 and 1.0. Set idum to any negative value to initialize or reinitialize the sequence. Taken from page 213 of Numerical Recipes in C. */ { static int inext,inextp; static long ma[56]; static int iff=0; long mj,mk; int i,ii,k; if (*idum < 0 || iff == 0) { iff=1; mj=MSEED-(*idum < 0 ? -*idum : *idum); mj %= MBIG; ma[55] = mj; mk=1; for (i=1;i<=54;i++) { ii=(21*i) % 55; ma[ii] = mk; mk=mj-mk; if (mk < MZ) mk += MBIG; mj=ma[ii]; } for (k=1;k<=4;k++) for (i=1;i<=55;i++) { ma[i] -= ma[1+(i+30) % 55]; if (ma[i] < MZ) ma[i] += MBIG; } inext=0; inextp=31; *idum=1; } if (++inext == 56) inext=1; if (++inextp == 56) inextp=1; mj=ma[inext]-ma[inextp]; if (mj < MZ) mj += MBIG; ma[inext]=mj; return (mj*FAC); } /*----------------------------------------------------------------------------*/ void nrerror(error_text) char error_text[]; /* Numerical recipes standard error handler */ { fprintf (stderr, "Run Time Error\n"); fprintf (stderr, "%s\n",error_text); fprintf (stderr, "Exiting Program\n\n"); exit(1); } /*----------------------------------------------------------------------------*/ main () { FILE *stream1, *stream2; char string[256],file1[256],file2[256],line[800]; char st1[8],st2[8],st3[8],st4[8]; double flux,old_flux; int i,j,k,l,nx,ny,nz,target_n,npart_tot,cnt,nn,iindex,jindex,kindex; int node1,node2,len,time_steps,final_cnt,part_diff,filter; float delx,dely,delz,j1,j2,j3,j4,j5,big_x,big_y,big_z; float x_off,y_off,z_off,rnum1,rnum2; long seed; seed = 12345; rnum1 = 1.000; rnum2 = 1.000; iindex = jindex= kindex = 0; /* size of flux weighted boundary zone, _not_ the size of the model domain */ nx = 100; ny = 1; nz = 5; delx = dely = 4.0; delz = 2.0; /* The lower, left corner of the subdomain for the flux weighting. ALSO, need to keep in mind that the indices begin at 0 */ x_off = 12.0*delx; y_off = 120.0*dely; z_off = 0.0-(9.0*delz); target_n = 4000; /* requested number of particles */ filter = 5; /* lower limit of number of particles below which the the number cannot be adjusted */ npart_tot = 0; cnt =0; /* open the input and output files */ stream1 = fopen ("het_flow.out", "r"); stream2 = fopen ("sptr_cell.dat", "w"); /* Read in the fluxes/velocities in the screen dump file coming out of FEHM. Using the same logic as for reading MODFLOW screen dump files to get heads. Although, the fluxes are written 3 times for FEHM and we only want the last set */ len = strlen(" Node1 Node2"); nn=0; do { fgets (line, 800, stream1); nn++; } while (strncmp (line," Node1 Node2", len) != 0); fgets (line, 800, stream1); nn++; do { fgets (line, 800, stream1); nn++; } while (strncmp (line," Node1 Node2", len) != 0); fgets (line, 800, stream1); nn++; do { fgets (line, 800, stream1); nn++; } while (strncmp (line," Node1 Node2", len) != 0); /* Now read in the fluxes and determine the cell with the greatest flux. retain the indices for that cell. */ flux = old_flux = -10000000.0; for (k=0;k<nz;k++) { for (j=0;j<ny;j++) { for (i=0;i<nx;i++) { nn++; fscanf (stream1, "%d %d %f %f %f %f %lf %f", &node1,&node2,&j1,&j2,&j3,&j4,&flux,&j5); flux = -1.0*flux; if (flux < 0) flux = 0.000; if (flux > old_flux) { iindex = i; jindex = j; kindex = k; old_flux = flux; } } } } fclose (stream1); /* write out the "sptr" macro for FEHM */ write_header_1 (stream2); big_x = get_big_C (iindex,x_off,delx); big_y = get_big_C (jindex,y_off,dely); big_z = get_big_C (kindex,z_off,delz); printf ("Max Flux occurs at: %3d %3d %3d\n", iindex,jindex,kindex); printf ("With Coordinates: %7.2f %7.2f %7.2f\n\n", big_x,big_y,big_z); /* now assign random starting locations to the particles within the given cell. Note that z is negative down */ final_cnt=0; for (l=0;l<target_n;l++) { rnum1 = ran3(&seed); rnum2 = ran3(&seed); final_cnt++; fprintf (stream2," 30837 %7.3f %7.3f %7.3f\n", big_x+rnum1*delx,big_y+(dely/2.0),big_z-rnum2*delz); } printf ("Total particles requested: %5d\n", target_n); printf ("Total particles assigned at end of step 2: %5d\n\n", final_cnt); if (target_n != final_cnt) { printf ("DANGER Will Robinson!!\n"); printf (" Final particle count does not equal target number\n"); printf (" Most likely need to request more particles or decrease filter size\n\n"); } fprintf (stream2,"\n"); fprintf (stream2,"stop\n"); fclose (stream2); }
The calc_D_old.c software routine is used to determine the values of the longitudinal, and transverse dispersivities at nine different X-Z planes down gradient (Y-dimension) of the particle source locations. There are two important steps that the calc_D_old.c routine must complete: 1) the particle locations for every time step must be read in correctly and the 2) dispersivity values must be calculated correctly. The input to calc_D_old.c is the "het_flow.sptr2" file that is output from running the FEHM groundwater model. The calc_D_old.c routine creates four output files: disper_L.out, disper_X.out, disper_Y.out and debug.out. The first three of these output files contain the calculated values of longitudinal, transverse horizontal and transverse vertical dispersivity respectively. Each one of these files contains one line with 9 columns. The values in the columns are the values of the respective dispersivity for each of the 9 downstream planes. For each run of the calc_D_old.c subroutine, these files are appended with a new line containing the calculated values from the next permeability realization. The fourth output file, debug.out, contains 1 line for each run of calc_D_old.c with 9 columns. These columns are the total number of particles that have crossed each plane at the end of the simulation. The results in debug.out are not used in the analysis, they simply provide a check on the code performance. The final results presented in the AMR are the median, or mean, value of the dispersivities calculated across the 50 realizations at each downstream plane The calc_D_old.c software routine is written in the C programming language on a Sun Ultra Sparc Server. The version of the C compiler is 4.2 and the operating system is Solaris 2.7. This routine is composed of a single source code file. The functionality of the calc_D_old.c software routine is tested by making three checks. The first check is done to test the ability of the calc_D_old.c software routine to determine the particle locations as they cross the downstream plane. This check is done with the particle tracking results from FEHM as run on a homogeneous permeability field in order to check the accuracy of the calc_D_old.c software routine. The second check is also done on the output from the run with the homogeneous permeability field. A hand calculation verified that the travel time of the particles is within the expected accuracy. The third check is done with the results from a heterogeneous permeability field and is used to check the ability of the calc_D_old.c routine to correctly determine the values of dispersivity. CHECK 1 (determining locations of particles) In order to check the capability of the calc_D_old.c routine to determine the X and Z coordinates of each particle at each downstream plane, FEHM was run with a homogeneous permeability field. The use of a homogenous permeability field ensures that for every particle/stream line there are no deviations in the X and Z coordinates of the particles from the original starting locations. Only the Y coordinate of the particles will change when run in a homogeneous permeability field. Under these conditions, it is easy to check the functionality of the calc_D_old.c routine by comparing the particle locations at any downstream plane with the starting locations. If calc_D_old.c is functioning correctly, the X and Z coordinates of the particles at a downstream plane will be the same as the X and Z starting coordinates. This check is done by plotting the starting locations and the locations at the 3rd downstream plane (80 meters of travel distance) on the same graph for a portion of the particles. This graph is shown in Figure XV-1. [Figure XV-1] Figure XV-1 shows that all particles at the downstream plane are colocated with the starting locations of the particles. This is the correct result for a homogenous permeability field, and these results confirm that the calc_D_old.c software routine finds the correct locations of the particles at the downstream locations. CHECK 2 (Determining travel time of particles) The second check is done to make sure that in addition to being able to determine the correct X and Z coordinates of the particles, calc_D_old.c is also capable of determining the correct time for the particles as they reach each downstream plane. This check is made by comparing the times determined by calc_D_old.c to those done with a hand calculation. It is only possible to check these times against a hand-calculation for the case of homogeneous permeability field. The advective velocity, Vy, is given by:
![]() |
![]() |
disper_L.out 1328.842 551.628 583.222 596.864 327.605 278.641 318.002 290.065 257.661 disper_X.out 0.966 0.846 0.660 0.553 0.809 0.718 0.751 0.932 0.995 disper_Z.out 1.090 1.289 0.853 0.467 0.445 0.238 0.276 0.254 0.225The columns in the output files correspond to each downstream plane at which dispersivity is calculated. For this check, the third column (third downstream plane) is compared to the Excel results. The third column has been highlighted in the above outputs. The results of the calculations of dispersivity done in Excel are:
583.9553 | ||
Trans X Dispersivity | ||
0.851789 |
#include <stdio.h> #include <string.h> #include <math.h> /* Sean A. McKenna 6/10/99 Geohydrology Department Sandia National Laboratories PO Box 5800 MS0735 Albuquerque, NM 87185-0735 ph: 505 844-2450 em: samcken@sandia.gov Read in FEHM particle track output from file *.sptr2 and calculate the longitudinal and transverse dispersivities at multiple distances downgradient of the particle release plane. Also calculate the segment velocities along the flow paths for a smaller number of paths (like 10 -20). Output dispersivity and velocity metrics to seperate output files */ #define TINY 0.01 char *read_line (); float calc_dist (); float calc_disp_L (); float calc_disp_T (); /*----------------------------------------------------------------------------*/ char *read_line (stream) FILE *stream; { static char string[256]; string[0] = '\0'; do fgets (string, 256, stream); while ((string[0] == '!') && !feof (stream)); return (string); } /*----------------------------------------------------------------------------*/ float calc_dist(x1,x2,y1,y2,z1,z2) float x1,x2,y1,y2,z1,z2; { float dist; dist = sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2)+(z1-z2)*(z1-z2)); return (dist); } /*----------------------------------------------------------------------------*/ float calc_disp_L(dist,mean,stdev) float dist,mean,stdev; /* use the mean and the variance of travel time arrivals at a plane to calculate the LONGITUDINAL dispersivity (basically equations 8 and 9 in Wen and Gomez- Hernandez, 1998). */ { double disper; disper = (dist/2.0)*((stdev/mean)*(stdev/mean)); return (disper); } /*----------------------------------------------------------------------------*/ float calc_disp_T(dist,var) float dist,var; /* use the variance of the transverse displacements at the current plane downstream from the source to determine the transverse dispersivity. This same function can be called for both X and Z transverse dispersivityes. See pp. 144-145 in Wen and Gomez-Hernandez, 1998). */ { float disper; disper = var/(2.0*dist); return (disper); } /*----------------------------------------------------------------------------*/ main () { FILE *stream1,*stream2,*stream3,*stream4,*stream5; char string[256]; float plane_x[11][4001],plane_y[11][4001],plane_z[11][4001],plane_t[11][4001]; float start_x[4001],start_z[4001],start_t[4001],start_y,disper_X[11],disper_Z[11]; float junk,poros,vel,dist,yplane[11],sum_time[11],sumsq_time[11],var_X,var_Z; float hold_x[4001],hold_y[4001],hold_z[4001],hold_t[4001],disper_L[11]; float xcross,ycross,zcross,tcross,short_dist,tot_dist,mean_time,var_time; float sum_xdisplace[11],sum_zdisplace[11],sumsq_xdisplace[11],sumsq_zdisplace[11]; int i,j,k,cnt,end_time,time_step,indjunk,npath,ncol,nrow; int plane_cnt[4001],nplane,plane_paths[11]; long unsigned int j1,j2,j3,j4,j5,j6,j7,j8,j9,j10; npath = 4000; ncol = 10; /* FEHM output format is ten columns per line */ nrow = npath/10; start_y = 482.0000; for (i=1;i<=4001;i++) { for (j=0;j<=10;j++) { plane_x[j][i]=plane_y[j][i]=plane_z[j][i]=plane_t[j][i] = -10000.0; } plane_cnt[i] = 0; start_x[i] = start_z[i] = start_t[i] = -10000.0; } for (j=1;j<=10;j++) { plane_paths[j] = 0; sum_time[j] = 0.0; sumsq_time[j] = 0.0; sum_xdisplace[j] = 0.0; sumsq_xdisplace[j] = 0.0; sum_zdisplace[j] = 0.0; sumsq_zdisplace[j] = 0.0; disper_L[j] = disper_X[j] = disper_Z[j] = 0.0; } junk = 0.0; indjunk = 0; j1=j2=j3=j4=j5=j6=j7=j8=j9=j10=0; nplane = 10; yplane[0] = 478.000; /* 0 lambda, to get started */ yplane[1] = 462.000; /* 1 lambda */ yplane[2] = 442.000; /* 2 lambda */ yplane[3] = 402.000; /* 4 lambda */ yplane[4] = 362.000; /* 6 lambda */ yplane[5] = 302.000; /* 9 lambda */ yplane[6] = 242.000; /* 12 lambda */ yplane[7] = 182.000; /* 15 lambda */ yplane[8] = 102.000; /* 19 lambda */ yplane[9] = 22.000; /* 23 lambda */ yplane[10] = 2.000; /* Catch all at end */ /* open the input and output files */ stream1 = fopen ("het_flow.sptr2", "r"); stream2 = fopen ("disper_L.out", "a"); stream3 = fopen ("disper_X.out", "a"); stream4 = fopen ("disper_Z.out", "a"); stream5 = fopen ("debug.out", "a"); printf ("IO Files opened\n\n"); /* Read in the first time step worth of data to get the starting locations of the pathlines. Only concerned with x,z and times at start */ sprintf (string, "%s", read_line (stream1)); sscanf (string, "%d", &time_step); i=0; for (k=1;k<=nrow;k++) { for (j=1;j<=ncol;j++) { i++; fscanf (stream1," %f ", &start_x[i]); } } i=0; for (k=1;k<=nrow;k++) { sprintf (string, "%s", read_line (stream1)); } i=0; for (k=1;k<=nrow;k++) { for (j=1;j<=ncol;j++) { i++; fscanf (stream1," %f ", &start_z[i]); } } i=0; for (k=1;k<=nrow;k++) { for (j=1;j<=ncol;j++) { i++; fscanf (stream1," %f ", &start_t[i]); } } i=0; for (k=1;k<=nrow;k++) { sprintf (string, "%s", read_line (stream1)); } i=0; for (k=1;k<=nrow;k++) { sprintf (string, "%s", read_line (stream1)); } i=0; for (k=1;k<=nrow;k++) { sprintf (string, "%s", read_line (stream1)); } for (i=1;i<=npath;i++) { hold_x[i] = start_x[i]; hold_y[i] = start_y; hold_z[i] = start_z[i]; hold_t[i] = start_t[i]; } printf ("starting locations read \n\n"); /* now scroll through the rest of the file grabbing the X, Z and time coordinates for each particle as it crosses each plane */ cnt = 0; end_time = 0; i = 0; do { junk = 0.0; indjunk = 0; j1=j2=j3=j4=j5=j6=j7=j8=j9=j10=0; sprintf (string, "%s", read_line (stream1)); sscanf (string, "%d", &time_step); printf ("print block = %5d\n", time_step); i=0; for (k=1;k<=nrow;k++) { for (j=1;j<=ncol;j++) { i++; fscanf (stream1," %f ", &plane_x[plane_cnt[i]][i]); } } i=0; for (k=1;k<=nrow;k++) { for (j=1;j<=ncol;j++) { i++; fscanf (stream1," %f ", &plane_y[plane_cnt[i]][i]); } } i=0; for (k=1;k<=nrow;k++) { for (j=1;j<=ncol;j++) { i++; fscanf (stream1," %f ", &plane_z[plane_cnt[i]][i]); } } i=0; for (k=1;k<=nrow;k++) { for (j=1;j<=ncol;j++) { i++; fscanf (stream1," %f ", &plane_t[plane_cnt[i]][i]); } } i=0; for (k=1;k<=nrow;k++) { sprintf (string, "%s", read_line (stream1)); } i=0; for (k=1;k<=nrow;k++) { sprintf (string, "%s", read_line (stream1)); } for (k=1;k<=nrow;k++) { sprintf (string, "%s", read_line (stream1)); } /* now have all coordinates for all particles for this print block. See which ones have crossed the current y_plane and for only those particles, use linear interpolation to determine the x and z coords as well as the time when it crossed the plane and then update the plane_cnt */ for (i=1;i<=npath;i++) { if ((plane_y[plane_cnt[i]][i] <= (yplane[plane_cnt[i]]+TINY))&& (plane_y[plane_cnt[i]][i] >= (yplane[plane_cnt[i]]-TINY))&& (plane_cnt[i]<nplane)) { ycross = yplane[plane_cnt[i]]; xcross = ((hold_y[i]-yplane[plane_cnt[i]])*(plane_x[plane_cnt[i]][i]-hold_x[i]))/ (hold_y[i]-plane_y[plane_cnt[i]][i]); xcross = xcross + hold_x[i]; zcross = ((hold_y[i]-yplane[plane_cnt[i]])*(plane_z[plane_cnt[i]][i]-hold_z[i]))/ (hold_y[i]-plane_y[plane_cnt[i]][i]); zcross = zcross + hold_z[i]; short_dist = calc_dist(hold_x[i],xcross,hold_y[i],ycross,hold_z[i],zcross); tot_dist = calc_dist(hold_x[i],plane_x[plane_cnt[i]][i], hold_y[i],plane_y[plane_cnt[i]][i], hold_z[i],plane_z[plane_cnt[i]][i]); tcross = ((plane_t[plane_cnt[i]][i]-hold_t[i])*short_dist)/tot_dist; tcross = tcross + hold_t[i]; /* plane_x[plane_cnt[i]][i] = xcross; plane_y[plane_cnt[i]][i] = ycross; plane_z[plane_cnt[i]][i] = zcross; plane_t[plane_cnt[i]][i] = tcross; */ hold_x[i] = plane_x[plane_cnt[i]][i]; hold_y[i] = plane_y[plane_cnt[i]][i]; hold_z[i] = plane_z[plane_cnt[i]][i]; hold_t[i] = plane_t[plane_cnt[i]][i]; plane_cnt[i]++; } else { hold_x[i] = plane_x[plane_cnt[i]][i]; hold_y[i] = plane_y[plane_cnt[i]][i]; hold_z[i] = plane_z[plane_cnt[i]][i]; hold_t[i] = plane_t[plane_cnt[i]][i]; } } } while (!feof(stream1)); fclose (stream1); /* Now calculate statistics for dispersion calculations */ /* reset all times to ln times and calcualte first and second moments of the transverse displacements */ for (j=1;j<nplane;j++) { for (i=1;i<=npath;i++) { if (plane_t[j][i] > 0.0) { plane_t[j][i] = log(plane_t[j][i]); sum_time[j] += plane_t[j][i]; sumsq_time[j] += (plane_t[j][i]*plane_t[j][i]); sum_xdisplace[j] += (plane_x[j][i]-start_x[i]); sumsq_xdisplace[j] += ((plane_x[j][i]-start_x[i])*(plane_x[j][i]-start_x[i])); sum_zdisplace[j] += (plane_z[j][i]-start_z[i]); sumsq_zdisplace[j] += ((plane_z[j][i]-start_z[i])*(plane_z[j][i]-start_z[i])); plane_paths[j]++; } } } /* Calculate the longitudinal and transverse dispersivities */ mean_time=var_time=var_X=var_Z=0.0; for (j=1;j<nplane;j++) { mean_time = sum_time[j]/(float)plane_paths[j]; var_time = ((float)plane_paths[j]*sumsq_time[j]-(sum_time[j]*sum_time[j]))/ ((float)plane_paths[j]*(float)(plane_paths[j]-1)); /* now get raw space mean and variance */ mean_time = exp(mean_time + (var_time/2.0)); var_time = (mean_time*mean_time)*(exp(var_time)-1.0); /* feed these values into dispersivity calculation */ disper_L[j] = calc_disp_L((start_y-yplane[j]),mean_time,sqrt(var_time)); var_X = ((float)plane_paths[j]*sumsq_xdisplace[j]-(sum_xdisplace[j]*sum_xdisplace[j]))/ ((float)plane_paths[j]*(float)(plane_paths[j]-1)); disper_X[j] = calc_disp_T((start_y-yplane[j]),var_X); var_Z = ((float)plane_paths[j]*sumsq_zdisplace[j]-(sum_zdisplace[j]*sum_zdisplace[j]))/ ((float)plane_paths[j]*(float)(plane_paths[j]-1)); disper_Z[j] = calc_disp_T((start_y-yplane[j]),var_Z); fprintf (stream2," %8.3f",disper_L[j]); fprintf (stream3," %7.3f",disper_X[j]); fprintf (stream4," %7.3f",disper_Z[j]); fprintf (stream5," %5d",plane_paths[j]); mean_time=var_time=var_X=var_Z=0.0; } fprintf(stream2,"\n"); fprintf(stream3,"\n"); fprintf(stream4,"\n"); fprintf(stream5,"\n"); fclose (stream2); fclose (stream3); fclose (stream4); fclose (stream5); }
Previous Section | Next Section