   Input file: ../examples/ex21
  Output file: ex21.out
Database file: ../database/phreeqc.dat

------------------
Reading data base.
------------------

	SOLUTION_MASTER_SPECIES
	SOLUTION_SPECIES
	PHASES
	GAS_BINARY_PARAMETERS
	EXCHANGE_MASTER_SPECIES
	EXCHANGE_SPECIES
	SURFACE_MASTER_SPECIES
	SURFACE_SPECIES
	MEAN_GAMMAS
	RATES
	END
------------------------------------
Reading input data for simulation 1.
------------------------------------

	TITLE Diffusion through Opalinus Clay in a radial diffusion cell, Appelo, Van Loon and Wersin, 2010, GCA 74, 1201
	KNOBS
	 tolerance 1e-16
	 diagonal_scale true
	SOLUTION_MASTER_SPECIES
	  Hto       Hto       0.0   20        20
	  Na_tr     Na_tr+    0.0   22        22
	  Cl_tr     Cl_tr-    0.0   36        36
	  Cs        Cs+       0.0  132.905   132.905
	SOLUTION_SPECIES
	  Hto = Hto
	        log_k 0
	 gamma 1e5   0
	   dw 2.3e-9  0 0 0 0 0 0.5 # diffusion coefficient is multiplied by (viscos_0 /viscos)^0.5, the viscosity of the DDL is calculated.
	  Cl_tr- = Cl_tr-
	  log_k 0
	 gamma 3.5 0.015
	 dw 1.35e-9 0 0 0 0 0 0.5 # increase tortuosity for anions: 2.03e-9 / 1.35e-9 = 1.5
	  Na_tr+ = Na_tr+
	  log_k 0
	 gamma 4.0 0.075
	 dw 1.33e-9 0 0 0 0 0 0.5 
	 erm_ddl 1.3 
	  Cs+ = Cs+
	        log_k 0
	 gamma 3.5 0.015
	 dw 2.07e-9 0 0 0 0 0 0.5 
	 erm_ddl 1.3
	SURFACE_MASTER_SPECIES
	  Su_fes Su_fes-   # Frayed Edge Sites
	  Su_ii Su_ii-     # Type II sites of intermediate strength
	  Su_ Su_-         # Double layer, planar sites are modeled with EXCHANGE
	SURFACE_SPECIES
	  Su_fes- = Su_fes-
	 log_k 0
	  Na+ + Su_fes- = NaSu_fes
	 log_k 10
	  Na_tr+ + Su_fes- = Na_trSu_fes
	 log_k 10
	  K+ + Su_fes- = KSu_fes
	 log_k 12.4
	  Cs+ + Su_fes- = CsSu_fes
	 log_k 17.14
	  Su_ii- = Su_ii-
	 log_k 0
	  Na+ + Su_ii- = NaSu_ii
	 log_k 10
	  Na_tr+ + Su_ii- = Na_trSu_ii
	 log_k 10
	  K+ + Su_ii- = KSu_ii
	 log_k 12.1
	  Cs+ + Su_ii- = CsSu_ii
	 log_k 14.6
	  Su_- = Su_-
	 log_k 0
	EXCHANGE_SPECIES
	  Na_tr+ + X- = Na_trX
	 log_k 0.0
	  gamma 4.0 0.075
	  Cs+ + X- = CsX
	       log_k 2.04
	 gamma 3.5 0.015
	SOLUTION 0-2 column with only cell 1, two boundary solutions 0 and 2.
	  Na 1
	 Cl 1
	END
-----
TITLE
-----

 Diffusion through Opalinus Clay in a radial diffusion cell, Appelo, Van Loon and Wersin, 2010, GCA 74, 1201

-------------------------------------------
Beginning of initial solution calculations.
-------------------------------------------

Initial solution 0.	column with only cell 1, two boundary solutions 0 and 2.

-----------------------------Solution composition------------------------------

	Elements           Molality       Moles

	Cl                1.000e-03   1.000e-03
	Na                1.000e-03   1.000e-03

----------------------------Description of solution----------------------------

                                       pH  =   7.000    
                                       pe  =   4.000    
      Specific Conductance (µS/cm,  25°C)  = 122
                          Density (g/cm³)  =   0.99708
                               Volume (L)  =   1.00298
                        Viscosity (mPa s)  =   0.89026
                        Activity of water  =   1.000
                 Ionic strength (mol/kgw)  =   1.000e-03
                       Mass of water (kg)  =   1.000e+00
                 Total alkalinity (eq/kg)  =   1.417e-09
                         Temperature (°C)  =  25.00
                  Electrical balance (eq)  =  -1.417e-09
 Percent error, 100*(Cat-|An|)/(Cat+|An|)  =  -0.00
                               Iterations  =   3
                                  Total H  = 1.110124e+02
                                  Total O  = 5.550622e+01

----------------------------Distribution of species----------------------------

                                               Log       Log       Log    mole V
   Species          Molality    Activity  Molality  Activity     Gamma   cm³/mol

   OH-             1.049e-07   1.012e-07    -6.979    -6.995    -0.016     -4.11
   H+              1.035e-07   1.000e-07    -6.985    -7.000    -0.015      0.00
   H2O             5.551e+01   1.000e+00     1.744    -0.000     0.000     18.07
Cl            1.000e-03
   Cl-             1.000e-03   9.649e-04    -3.000    -3.016    -0.016     18.07
   HCl             3.321e-11   3.324e-11   -10.479   -10.478     0.000     (0)  
H(0)          1.416e-25
   H2              7.078e-26   7.079e-26   -25.150   -25.150     0.000     28.61
Na            1.000e-03
   Na+             1.000e-03   9.652e-04    -3.000    -3.015    -0.015     -1.48
O(0)          0.000e+00
   O2              0.000e+00   0.000e+00   -42.080   -42.080     0.000     30.40

------------------------------Saturation indices-------------------------------

  Phase               SI** log IAP   log K(298 K,   1 atm)

  H2(g)           -22.05    -25.15   -3.10  H2
  H2O(g)           -1.50     -0.00    1.50  H2O
  Halite           -7.60     -6.03    1.57  NaCl
  O2(g)           -39.19    -42.08   -2.89  O2

**For a gas, SI = log10(fugacity). Fugacity = pressure * phi / 1 atm.
  For ideal gases, phi = 1.

------------------
End of simulation.
------------------

------------------------------------
Reading input data for simulation 2.
------------------------------------

	SOLUTION 3 tracer solution
	  pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	  Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	  Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476
	  Hto 1.14e-6
	   water 0.2
	SELECTED_OUTPUT
	  file radial
	 reset false
	USER_PUNCH
	1    nl$ = EOL$                # newline
	2    x$  = CHR$(35)            # cross '#'
	3    sc$ = CHR$(59)            # semicolon ';'
	4    pi  = 2 * ARCTAN(1e10)    # 3.14159...
	10   height = 0.052           # length of the clay cylinder / m
	20   r_int = 6.58e-3          # inner radius of clay cylinder / m
	30   r_ext = 25.4e-3          # outer radius
	40   thickn_filter1 = 1.8e-3  # tracer-in filter thickness / m
	50   thickn_filter2 = 1.6e-3  # tracer-out filter thickness / m
	60   por_filter1 = 0.418      # porosity
	70   por_filter2 = 0.367
	80   G_filter1 = 4.18         # geometrical factor. (for filters, G = por / 10)
	90   G_filter2 = 3.67
	100  V_end = 0.2              # volume of the tracer-out solution / L
	110  thickn_clay = r_ext - r_int # clay thickness / m
	120  por_clay = 0.159
	130  rho_b_eps = 2.7 * (1 - por_clay) / por_clay  # clay bulk density / porosity / (kg/L)
	140  CEC = 0.12 * rho_b_eps   # CEC / (eq/L porewater)
	150  A_por = 37e3 * rho_b_eps # pore surface area / (m²/L porewater)
	151  correct_$  = ' false'
	160  DIM tracer$(4), exp_time(4), scale_y1$(4), scale_y2$(4), profile_y1$(4), profile_y2$(4)
	170  DATA 'Hto', 'Cl_tr', 'Na_tr', 'Cs'
	180  READ tracer$(1), tracer$(2), tracer$(3), tracer$(4)
	200  DATA 86400 * 20, 86400 * 40, 86400 * 45, 86400 * 1000
	210  READ exp_time(1), exp_time(2), exp_time(3), exp_time(4)
	230  DATA '1', '1', '1', '1'
	240  READ scale_y1$(1), scale_y1$(2), scale_y1$(3), scale_y1$(4)
	260  DATA '1', '1', '1', '1'
	270  READ scale_y2$(1), scale_y2$(2), scale_y2$(3), scale_y2$(4)
	280  DATA '0 1.2e-9', '0 2.5e-5', '0 2e-10', '0 auto'
	290  READ profile_y1$(1), profile_y1$(2), profile_y1$(3), profile_y1$(4)
	300  DATA '0 1.2e-9', '0 2.5e-5', '0 6e-10', '0 auto'
	310  READ profile_y2$(1), profile_y2$(2), profile_y2$(3), profile_y2$(4)
	350  Dw = 2.5e-9              # default tracer diffusion coefficient / (m²/s)
	360  nfilt1 = 1               # number of cells in filter 1
	370  nfilt2 = 1               # number of cells in filter 2
	380  nclay = 11               # number of clay cells
	390  f_free = 0.11             # fraction of free pore water (0.01 - 1)
	400  f_DL_charge = 0.48       # fraction of CEC charge in electrical double layer
	410  tort_n = -1.00           # exponent in Archie's law, found from HTO
	420  G_clay = por_clay^tort_n # geometrical factor
	430  interlayer_D$ = 'true'  # 'true' or 'false' for interlayer diffusion
	440  G_IL = 1300               # geometrical factor for clay interlayers... the initial rise of Cs suggests stagnant water, see Appelo et al for the calculation
	450  punch_time = 60 * 60 * 6 # punch time / seconds
	460  profile$ = 'false'        # 'true' or 'false' for c/x profile visualization
	470  IF nfilt1 = 0 THEN thickn_filter1 = 0
	480  IF nfilt2 = 0 THEN thickn_filter2 = 0
	490  IF tot("Hto") > 1e-10 THEN tracer = 1 ELSE      IF tot("Cl_tr") > 1e-10 THEN tracer = 2 ELSE tracer = 3
	520  sol$ = nl$ + ' pH 7.6' + sc$ +' pe 14 O2(g) -1.0' + sc$ +' temp 23'
	530  sol$ = sol$ + nl$ + ' Na 240' + sc$ +' K 1.61' + sc$ +' Mg 16.9' + sc$ +' Ca 25.8' + sc$ +' Sr 0.505'
	540  sol$ = sol$ + nl$ + ' Cl 300' + sc$ +' S(6) 14.1' + sc$ +' Fe(2) 0.0' + sc$ +' Alkalinity 0.476'
	550  tracer_phases$ = nl$ + 'PHASES '
	560  tracer_phases$ = tracer_phases$ + nl$ + ' A_Hto' + nl$ + ' Hto = Hto' + sc$ +' log_k -15'
	570  tracer_phases$ = tracer_phases$ + nl$ + ' A_Na_tr' + nl$ + ' Na_trCl = Na_tr+ + Cl-' + sc$ + ' log_k -14'
	580  tracer_phases$ = tracer_phases$ + nl$ + ' A_Cl_tr' + nl$ + ' NaCl_tr = Na+ + Cl_tr-' + sc$ +' log_k -14'
	590  tracer_phases$ = tracer_phases$ + nl$ + ' A_Cs' + nl$ + ' CsCl = Cs+ + Cl-' + sc$ + ' log_k -13'
	600  DIM tracer_equi$(4)
	610  FOR i = 1 TO 4
	620    tracer_equi$(i) = nl$ + 'A_' + tracer$(i) + ' 0 0'
	630  NEXT i
	650  punch nl$ + 'PRINT ' + sc$ + ' -reset false' + sc$ + ' -echo_input true' + sc$ + ' -user_print true'
	660  IF nfilt1 = 0 THEN GOTO 800
	670  punch nl$ + x$ + ' filter cells at tracer-in side...'
	680  r1 = r_int - thickn_filter1
	690  xf1 = thickn_filter1 / nfilt1
	700  FOR i = 1 TO nfilt1
	710    num$ = TRIM(STR$(i + 3)) + sc$
	720    V_water = 1e3 * height * por_filter1 * pi * (SQR(r1 + xf1) - SQR(r1))
	730    punch nl$ + 'SOLUTION ' + num$ + ' -water ' + STR$(V_water)
	740    punch sol$ + nl$
	750    r1 = r1 + xf1
	760  NEXT i
	800  punch nl$ + nl$ + x$ + ' cells in Opalinus Clay...'
	810  r1 = r_int
	820  x = thickn_clay / nclay
	830  FOR i = 1 TO nclay
	840    num$ = TRIM(STR$(i + 3 + nfilt1)) + sc$
	850    V_water = 1e3 * height * por_clay * pi * (SQR(r1 + x) - SQR(r1))
	860    punch nl$ + 'SOLUTION ' + num$ + ' -water ' + STR$(V_water * f_free)
	870    punch sol$
	880    IF f_free = 1 and tracer = 1  THEN GOTO 960
	890    punch nl$ + 'SURFACE ' + num$ + ' -equil ' + num$
	900    punch nl$ + ' Su_ ' + TRIM(STR$(f_DL_charge * CEC * V_water)) + STR$(A_por) + ' ' + STR$(V_water)
	910    punch nl$ + ' Su_ii ' + TRIM(STR$(7.88e-4 * rho_b_eps * V_water))
	920    punch nl$ + ' Su_fes ' + TRIM(STR$(7.4e-5 * rho_b_eps * V_water))
	930    IF f_free < 1 THEN punch nl$ + ' -Donnan ' + TRIM(STR$((1 - f_free) * 1e-3 / A_por)) + ' viscosity calc' + ' correct ' + correct_$
	940    punch nl$ + 'EXCHANGE ' + num$ + ' -equil ' + num$
	950    punch nl$ + ' X ' + TRIM(STR$((1 - f_DL_charge) * CEC * V_water)) + nl$
	960    r1 = r1 + x
	970  NEXT i
	1000 IF nfilt2 = 0 THEN GOTO 1200
	1010 punch nl$ + nl$ + x$ + ' tracer-out filter cells...'
	1020 r1 = r_ext
	1030 xf2 = thickn_filter2 / nfilt2
	1040 FOR i = 1 TO nfilt2
	1050   num$ = TRIM(STR$(i + 3 + nfilt1 + nclay)) + sc$
	1060   V_water = 1e3 * height * por_filter2 * pi * (SQR(r1 + xf2) - SQR(r1))
	1070   punch nl$ + 'SOLUTION ' + num$ + ' -water ' + STR$(V_water)
	1080   punch sol$ + nl$
	1090   r1 = r1 + xf2
	1100 NEXT i
	1200 punch nl$ + x$ + ' outside solution...'
	1210 num$ = TRIM(STR$(4 + nfilt1 + nclay + nfilt2)) + sc$
	1220 punch nl$ + 'SOLUTION ' + num$ + ' -water ' + STR$(V_end)
	1230 punch sol$
	1240 punch nl$ + 'END'
	1300 punch nl$ + tracer_phases$
	1310 punch nl$ + 'EQUILIBRIUM_PHASES ' + num$ + tracer_equi$(tracer)
	1312 If tracer = 3 THEN punch nl$ + tracer_equi$(tracer + 1)
	1320 punch nl$ + 'END'
	1400 IF nfilt1 > 0 THEN gf1 = por_filter1 / G_filter1
	1410 IF nfilt2 > 0 THEN gf2 = por_filter2 / G_filter2
	1420 g = por_clay / G_clay
	1500 IF nfilt1 = 0 THEN GOTO 1530
	1510   r1 = r_int - thickn_filter1
	1520   ff = (SQR(r1 + xf1) - SQR(r1)) * xf1 * G_filter1 / (r1 * 2) / 2
	1530 ff1 = (SQR(r_int + x) - SQR(r_int)) * x * G_clay / (r_int * 2) / 2
	1540 IF nfilt1 = 0 THEN ff = ff1 ELSE IF ff1 * 2 < ff THEN ff = ff1 * 2
	1550 IF nfilt1 > 0 THEN ff1 = (SQR(r_int + x) - SQR(r_int)) * (xf1 / gf1 + x / g) / (2 * r_int * 2)
	1560 IF nfilt1 > 0 AND ff1 < ff THEN ff = ff1
	1570 IF nfilt2 > 0 THEN ff1 = (SQR(r_ext + xf2) - SQR(r_ext)) * xf2 * G_filter2 / (r_ext * 2)
	1580 IF nfilt2 > 0 AND ff1 < ff THEN ff = ff1
	1590 dt_max = 0.5 * ff / Dw
	1610 IF punch_time < dt_max THEN dt = punch_time ELSE dt = dt_max
	1620 punch_fr = 1
	1630 IF dt < punch_time THEN punch_fr = ceil(punch_time / dt)
	1640 dt = punch_time / punch_fr
	1650 shifts = ceil(exp_time(tracer) / dt)
	1700 punch nl$ + nl$ + x$ + ' mixing factors...'
	1710 r1 = r_int
	1720 IF nfilt1 > 0 THEN r1 = r_int - thickn_filter1
	1730 A = height * 2 * pi
	1740 FOR i = 0 TO nfilt1 + nclay + nfilt2
	1750   IF i = 0 OR i = nfilt1 + nclay + nfilt2 THEN fbc = 2 ELSE fbc = 1
	1760   IF i > nfilt1 OR nfilt1 = 0 THEN GOTO 1810
	1770     IF i < nfilt1 THEN mixf = Dw * fbc / (xf1 / gf1) * dt * A * r1 / 1e-3
	1780     IF i = nfilt1 THEN mixf = 2 * Dw / (xf1 / gf1 + x / g) * dt * A * r1 / 1e-3
	1790     IF i < nfilt1 THEN r1 = r1 + xf1 ELSE r1 = r1 + x
	1800     GOTO 1880
	1810   IF i > nfilt1 + nclay THEN GOTO 1860
	1820     mixf = Dw * fbc / (x / g) * dt * A * r1 / 1e-3
	1830     IF i = nfilt1 + nclay AND nfilt2 > 0 THEN mixf = 2 * Dw / (xf2 / gf2 + x / g) * dt * A * r1 / 1e-3
	1840     IF i < nfilt1 + nclay THEN r1 = r1 + x ELSE r1 = r1 + xf2
	1850     GOTO 1880
	1860   mixf = Dw * fbc / (xf2 / gf2) * dt * A * r1 / 1e-3
	1870   r1 = r1 + xf2
	1880   punch nl$ + 'MIX ' + TRIM(STR$(i + 3)) + sc$ + STR$(i + 4) + STR$(mixf)
	1890 NEXT i
	1900 punch nl$ + 'END'
	2000 punch nl$ + 'TRANSPORT'
	2010 stag = 2 + nfilt1 + nclay + nfilt2
	2020 punch nl$ + ' -warnings true'
	2030 punch nl$ + ' -shifts ' + TRIM(STR$(shifts))
	2040 punch nl$ + ' -flow diff' + sc$ + ' -cells 1' + sc$ + ' -bcon 1 2' + sc$ + ' -stag ' + TRIM(STR$(stag))
	2050 punch nl$ + ' -time ' + STR$(dt)
	2060 punch nl$ + ' -multi_D true ' + STR$(Dw) + STR$(por_clay) + ' 0.0 ' + TRIM(STR$(-tort_n))
	2070 punch nl$ + ' -interlayer_D ' + interlayer_D$ + ' 0.001 0.0 ' + TRIM(STR$(G_IL))
	2080 punch nl$ + ' -punch_fr ' + TRIM(STR$(punch_fr)) + sc$ + ' -punch_c ' + TRIM(STR$(2 + stag))
	2180 FOR i = 0 to 1
	2190   punch nl$ + 'USER_GRAPH ' + TRIM(STR$(tracer + i)) + ' Example 21' + nl$
	2200   punch nl$ + ' -chart_title " ' + tracer$(tracer + i) + ' Diffusion to Outer Cell"'
	2210   punch nl$ + ' -plot_tsv_file ex21_' + tracer$(tracer + i) + '_rad.tsv'
	2220   punch nl$ + ' -axis_scale x_axis 0 ' + TRIM(STR$(exp_time(tracer + i) / (3600 * 24)))
	2230   punch nl$ + ' -axis_titles "TIME, IN DAYS" "FLUX, IN MOL/M2/S" "ACCUMULATED MASS, IN MOL"'
	2240   punch nl$ + ' -plot_concentration_vs time'
	2250   punch nl$ + ' 10 days = total_time / (3600 * 24)'
	2260   punch nl$ + ' 20 a = equi("A_' + tracer$(tracer + i) + '")'
	2270   punch nl$ + ' 30 IF get(1) = 0 AND total_time > 0 THEN put(total_time, 1)'
	2280   punch nl$ + ' 40 dt = get(1)'
	2290   A = 2 * pi * r_ext * height
	2300   i$ = TRIM(STR$(2 + i))
	2310   punch nl$ + ' 50 plot_xy days - dt / (2 * 3600 * 24), (a - get(' + i$ + ')) / dt /' + STR$(A) +', color = Green, symbol = None'
	2320   punch nl$ + ' 60 put(a, ' + i$ + ')'
	2330   punch nl$ + ' 70 plot_xy days, equi("A_' + tracer$(tracer + i) + '"), y_axis = 2, color = Red, symbol = None'
	2340   IF tracer < 3 THEN GOTO 2360
	2350 NEXT i
	2360 punch nl$ + 'END'
	2400 IF profile$ = 'true' THEN GOSUB 3000
	2410 IF tracer < 3 THEN END # finished for Hto and Cl
	2420 IF profile$ = 'false' THEN punch nl$ + 'USER_GRAPH ' + TRIM(STR$(tracer)) + sc$ + ' -detach' ELSE                                 punch nl$ + 'USER_GRAPH ' + TRIM(STR$(tracer + 4)) + sc$ + ' -detach'
	2440 tracer = tracer + 1
	2450 punch nl$ + 'TRANSPORT'
	2460 shifts = ceil((exp_time(tracer) - exp_time(tracer - 1))/ dt)
	2480 punch nl$ + ' -shifts ' + TRIM(STR$(shifts))
	2490 punch nl$ + ' -punch_fr ' + TRIM(STR$(punch_fr)) + sc$ + ' -punch_c ' + TRIM(STR$(2 + stag))
	2500 punch nl$ + 'END'
	2510 IF profile$ = 'true' THEN GOSUB 3000
	2520 END # finished...
	3000 punch nl$ + 'TRANSPORT'
	3010 punch nl$ + ' -shifts 0'
	3020 punch nl$ + ' -punch_fr 2' + sc$ + ' -punch_c 3-' + TRIM(STR$(2 + stag))
	3030 punch nl$ + 'USER_GRAPH ' + TRIM(STR$(tracer)) + sc$ + ' -detach'
	3040 punch nl$ + 'USER_GRAPH ' + TRIM(STR$(tracer + 4)) + ' Example 21' + nl$
	3050 punch nl$ + ' -chart_title "' + tracer$(tracer) + ' Concentration Profile: Filter1 | Clay | Filter2"'
	3060 REM punch nl$ + ' -plot_tsv_file ' + tracer$(tracer) + '_prof.tsv'
	3070 punch nl$ + ' -axis_scale x_axis 0 ' + TRIM(STR$((thickn_filter1 + thickn_clay + thickn_filter2) * 1e3))
	3080 punch nl$ + ' -axis_scale y_axis ' + profile_y1$(tracer)
	3090 punch nl$ + ' -axis_scale sy_axis ' + profile_y2$(tracer)
	3100 punch nl$ + ' -axis_titles ' + '"DISTANCE, IN MILLIMETERS" "FREE PORE-WATER MOLALITY" "TOTAL MOLALITY"'
	3110 punch nl$ + ' -headings ' + tracer$(tracer) + '_free ' + tracer$(tracer) + '_tot'
	3120 punch nl$ + ' -plot_concentration_vs x'
	3130 punch nl$ + ' -initial_solutions true'
	3140 punch nl$ + ' 10 IF cell_no = 3 THEN xval = 0 ELSE xval = get(14)'
	3150 punch nl$ + ' 20 IF (' + TRIM(STR$(nfilt1)) + ' = 0 OR cell_no > ' + TRIM(STR$(nfilt1 + 3)) + ') THEN GOTO 60'
	3160 punch nl$ + ' 30 IF (cell_no = 4) THEN xval = xval + 0.5 * ' + TRIM(STR$(xf1))
	3170 punch nl$ + ' 40 IF (cell_no > 4 AND cell_no < ' + TRIM(STR$(nfilt1 + 4)) + ') THEN xval = xval + ' + TRIM(STR$(xf1))
	3180 punch nl$ + ' 50 GOTO 200'
	3190 punch nl$ + ' 60 IF (cell_no = ' + TRIM(STR$(4 + nfilt1)) + ') THEN xval = xval + 0.5 * ' + TRIM(STR$(xf1)) + ' + 0.5 * ' + TRIM(STR$(x))
	3200 punch nl$ + ' 70 IF (cell_no > ' + TRIM(STR$(4 + nfilt1)) + ' AND cell_no < ' + TRIM(STR$(4 + nfilt1 + nclay)) + ') THEN xval = xval + ' + TRIM(STR$(x)) + ' ELSE GOTO 90'
	3210 punch nl$ + ' 80 GOTO 200'
	3220 punch nl$ + ' 90 IF (cell_no = ' + TRIM(STR$(4 + nfilt1 + nclay)) + ') THEN xval = xval + 0.5 * ' + TRIM(STR$(x)) + ' + 0.5 * ' + TRIM(STR$(xf2))
	3230 punch nl$ + ' 100 IF (cell_no > ' + TRIM(STR$(4 + nfilt1 + nclay)) + ' AND cell_no <= ' + TRIM(STR$(3 + nfilt1 + nclay + nfilt2)) + ') THEN xval = xval + ' + TRIM(STR$(xf2))
	3240 punch nl$ + ' 110 IF (cell_no = ' + TRIM(STR$(4 + nfilt1 + nclay + nfilt2)) + ') THEN xval = xval + 0.5 * ' + TRIM(STR$(xf2))
	3250 punch nl$ + ' 200 y1 = TOT("' + tracer$(tracer) + '")'
	3260 punch nl$ + ' 210 plot_xy xval * 1e3, y1, color = Blue, symbol = Plus'
	3270 punch nl$ + ' 220 IF cell_no = 3 THEN put(y1, 15)'
	3280 punch nl$ + ' 230 IF (cell_no < ' + TRIM(STR$(4 + nfilt1)) + ' OR cell_no > ' + TRIM(STR$(3 + nfilt1 + nclay)) + ') THEN GOTO 400'
	3290 punch nl$ + ' 240 y2 = SYS("' + tracer$(tracer) + '") / (tot("water") + edl("water"))'
	3310 punch nl$ + ' 250 REM y2 = y2 / ' + TRIM(STR$(rho_b_eps)) + x$ + ' conc / kg solid'
	3320 punch nl$ + ' 260 plot_xy xval * 1e3, y2, symbol = Circle, y_axis = 2'
	3330 punch nl$ + ' 270 IF (cell_no > ' + TRIM(STR$(5 + nfilt1)) + ') THEN GOTO 400'
	3340 punch nl$ + ' 280 IF ' + TRIM(STR$(nfilt1)) + ' THEN plot_xy ' + TRIM(STR$(thickn_filter1 * 1e3)) + ', get(15), color = Black, symbol = None'
	3350 punch nl$ + ' 290 IF ' + TRIM(STR$(nfilt2)) + ' THEN plot_xy ' + TRIM(STR$((thickn_filter1 + thickn_clay) * 1e3)) + ', get(15), color = Black, symbol = None'
	3360 punch nl$ + ' 300 put(0, 15)'
	3370 punch nl$ + ' 400 put(xval, 14)'
	3380 punch nl$ + 'END'
	3390 RETURN
	END
-------------------------------------------
Beginning of initial solution calculations.
-------------------------------------------

Initial solution 3.	tracer solution

WARNING: USER_PUNCH: Headings count does not match number of calls to PUNCH.

-----------------------------Solution composition------------------------------

	Elements           Molality       Moles

	Alkalinity        4.760e-04   9.520e-05
	Ca                2.580e-02   5.160e-03
	Cl                3.000e-01   6.000e-02
	Hto               1.140e-09   2.280e-10
	K                 1.610e-03   3.220e-04
	Mg                1.690e-02   3.380e-03
	Na                2.400e-01   4.800e-02
	S(6)              1.410e-02   2.820e-03
	Sr                5.050e-04   1.010e-04

----------------------------Description of solution----------------------------

                                       pH  =   7.600    
                                       pe  =  13.120      Equilibrium with O2(g)
      Specific Conductance (µS/cm,  23°C)  = 29069
                          Density (g/cm³)  =   1.01168
                               Volume (L)  =   0.20146
                        Viscosity (mPa s)  =   0.96932
                        Activity of water  =   0.990
                 Ionic strength (mol/kgw)  =   3.633e-01
                       Mass of water (kg)  =   2.000e-01
                    Total carbon (mol/kg)  =   4.811e-04
                       Total CO2 (mol/kg)  =   4.811e-04
                         Temperature (°C)  =  23.00
                  Electrical balance (eq)  =  -1.312e-04
 Percent error, 100*(Cat-|An|)/(Cat+|An|)  =  -0.10
                               Iterations  =   6
                                  Total H  = 2.220258e+01
                                  Total O  = 1.111286e+01

----------------------------Distribution of species----------------------------

                                               Log       Log       Log    mole V
   Species          Molality    Activity  Molality  Activity     Gamma   cm³/mol

   OH-             5.188e-07   3.419e-07    -6.285    -6.466    -0.181     -3.26
   H+              3.237e-08   2.512e-08    -7.490    -7.600    -0.110      0.00
   H2O             5.551e+01   9.899e-01     1.744    -0.004     0.000     18.06
C(4)          4.811e-04
   HCO3-           3.911e-04   2.781e-04    -3.408    -3.556    -0.148     25.30
   NaHCO3          3.292e-05   3.892e-05    -4.483    -4.410     0.073     31.75
   MgHCO3+         2.266e-05   1.528e-05    -4.645    -4.816    -0.171      5.70
   CO2             1.541e-05   1.628e-05    -4.812    -4.788     0.024     34.33
   CaHCO3+         9.133e-06   6.615e-06    -5.039    -5.179    -0.140      9.83
   CaCO3           4.998e-06   5.434e-06    -5.301    -5.265     0.036    -14.61
   MgCO3           2.008e-06   2.184e-06    -5.697    -5.661     0.036    -17.09
   CO3-2           1.949e-06   4.981e-07    -5.710    -6.303    -0.593     -1.75
   SrHCO3+         7.330e-07   5.211e-07    -6.135    -6.283    -0.148     (0)  
   KHCO3           1.261e-07   1.271e-07    -6.899    -6.896     0.003     41.01
   SrCO3           3.617e-08   3.932e-08    -7.442    -7.405     0.036    -14.14
   (CO2)2          4.185e-12   4.551e-12   -11.378   -11.342     0.036     68.67
Ca            2.580e-02
   Ca+2            2.429e-02   6.749e-03    -1.615    -2.171    -0.556    -17.03
   CaSO4           1.496e-03   1.626e-03    -2.825    -2.789     0.036      7.42
   CaHCO3+         9.133e-06   6.615e-06    -5.039    -5.179    -0.140      9.83
   CaCO3           4.998e-06   5.434e-06    -5.301    -5.265     0.036    -14.61
   CaOH+           6.034e-08   4.414e-08    -7.219    -7.355    -0.136     (0)  
   CaHSO4+         3.568e-10   2.610e-10    -9.448    -9.583    -0.136     (0)  
Cl            3.000e-01
   Cl-             3.000e-01   2.018e-01    -0.523    -0.695    -0.172     18.53
   HCl             1.239e-09   1.768e-09    -8.907    -8.752     0.155     (0)  
H(0)          0.000e+00
   H2              0.000e+00   0.000e+00   -44.617   -44.580     0.036     28.61
Hto           1.140e-09
   Hto             1.140e-09   1.140e-09    -8.943    -8.943     0.000     (0)  
K             1.610e-03
   K+              1.584e-03   1.057e-03    -2.800    -2.976    -0.176      9.40
   KSO4-           2.634e-05   2.195e-05    -4.579    -4.659    -0.079     13.22
   KHCO3           1.261e-07   1.271e-07    -6.899    -6.896     0.003     41.01
Mg            1.690e-02
   Mg+2            1.548e-02   4.737e-03    -1.810    -2.325    -0.514    -20.64
   MgSO4           1.371e-03   1.620e-03    -2.863    -2.790     0.073     -8.62
   Mg(SO4)2-2      2.392e-05   7.620e-06    -4.621    -5.118    -0.497     27.97
   MgHCO3+         2.266e-05   1.528e-05    -4.645    -4.816    -0.171      5.70
   MgCO3           2.008e-06   2.184e-06    -5.697    -5.661     0.036    -17.09
   MgOH+           7.694e-07   5.651e-07    -6.114    -6.248    -0.134     (0)  
Na            2.400e-01
   Na+             2.347e-01   1.701e-01    -0.629    -0.769    -0.140     -0.85
   NaSO4-          5.251e-03   3.746e-03    -2.280    -2.426    -0.147      2.97
   NaHCO3          3.292e-05   3.892e-05    -4.483    -4.410     0.073     31.75
O(0)          2.438e-04
   O2              1.219e-04   1.325e-04    -3.914    -3.878     0.036     30.24
S(6)          1.410e-02
   SO4-2           5.877e-03   1.376e-03    -2.231    -2.862    -0.631     32.29
   NaSO4-          5.251e-03   3.746e-03    -2.280    -2.426    -0.147      2.97
   CaSO4           1.496e-03   1.626e-03    -2.825    -2.789     0.036      7.42
   MgSO4           1.371e-03   1.620e-03    -2.863    -2.790     0.073     -8.62
   SrSO4           3.160e-05   3.436e-05    -4.500    -4.464     0.036     24.16
   KSO4-           2.634e-05   2.195e-05    -4.579    -4.659    -0.079     13.22
   Mg(SO4)2-2      2.392e-05   7.620e-06    -4.621    -5.118    -0.497     27.97
   HSO4-           4.398e-09   3.217e-09    -8.357    -8.493    -0.136     40.64
   CaHSO4+         3.568e-10   2.610e-10    -9.448    -9.583    -0.136     (0)  
Sr            5.050e-04
   Sr+2            4.726e-04   1.312e-04    -3.325    -3.882    -0.557    -16.75
   SrSO4           3.160e-05   3.436e-05    -4.500    -4.464     0.036     24.16
   SrHCO3+         7.330e-07   5.211e-07    -6.135    -6.283    -0.148     (0)  
   SrCO3           3.617e-08   3.932e-08    -7.442    -7.405     0.036    -14.14
   SrOH+           3.780e-10   2.652e-10    -9.422    -9.576    -0.154     (0)  

------------------------------Saturation indices-------------------------------

  Phase               SI** log IAP   log K(296 K,   1 atm)

  Anhydrite        -0.78     -5.03   -4.26  CaSO4
  Aragonite        -0.15     -8.47   -8.32  CaCO3
  Arcanite         -6.91     -8.81   -1.91  K2SO4
  Calcite          -0.01     -8.47   -8.47  CaCO3
  Celestite        -0.10     -6.74   -6.65  SrSO4
  CO2(g)           -3.34     -4.79   -1.44  CO2
  Dolomite         -0.05    -17.10  -17.05  CaMg(CO3)2
  Epsomite         -3.47     -5.22   -1.75  MgSO4:7H2O
  Gypsum           -0.46     -5.04   -4.58  CaSO4:2H2O
  H2(g)           -41.48    -44.58   -3.10  H2
  H2O(g)           -1.56     -0.00    1.55  H2O
  Halite           -3.03     -1.46    1.57  NaCl
  Hexahydrite      -3.64     -5.21   -1.57  MgSO4:6H2O
  Kieserite        -4.02     -5.19   -1.17  MgSO4:H2O
  Mirabilite       -3.12     -4.44   -1.33  Na2SO4:10H2O
  O2(g)            -1.00     -3.88   -2.88  O2	 Pressure   0.1 atm, phi 1.000
  Strontianite     -0.92    -10.18   -9.27  SrCO3
  Sylvite          -4.56     -3.67    0.89  KCl
  Thenardite       -4.11     -4.40   -0.29  Na2SO4

**For a gas, SI = log10(fugacity). Fugacity = pressure * phi / 1 atm.
  For ideal gases, phi = 1.

------------------
End of simulation.
------------------

------------------------------------
Reading input data for simulation 3.
------------------------------------

	PRINT
	 selected_output false
	 status       false

	Reading data from radial ...
	PRINT 
	 reset false
	 user_print true	
	SOLUTION 4
	 water   1.3963e-03	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476
	SOLUTION 5
	 water   7.2695e-05	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 5
	 equilibrate 5
	 Su_ 5.4363e-04  5.2840e+05   6.6087e-04	
	 Su_ii 7.4371e-06	
	 Su_fes 6.9841e-07	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 5
	 equilibrate 5
	 X 5.8893e-04
	SOLUTION 6
	 water   8.9423e-05	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 6
	 equilibrate 6
	 Su_ 6.6871e-04  5.2840e+05   8.1293e-04	
	 Su_ii 9.1484e-06	
	 Su_fes 8.5911e-07	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 6
	 equilibrate 6
	 X 7.2444e-04
	SOLUTION 7
	 water   1.0615e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 7
	 equilibrate 7
	 Su_ 7.9380e-04  5.2840e+05   9.6500e-04	
	 Su_ii 1.0860e-05	
	 Su_fes 1.0198e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 7
	 equilibrate 7
	 X 8.5995e-04
	SOLUTION 8
	 water   1.2288e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 8
	 equilibrate 8
	 Su_ 9.1889e-04  5.2840e+05   1.1171e-03	
	 Su_ii 1.2571e-05	
	 Su_fes 1.1805e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 8
	 equilibrate 8
	 X 9.9547e-04
	SOLUTION 9
	 water   1.3960e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 9
	 equilibrate 9
	 Su_ 1.0440e-03  5.2840e+05   1.2691e-03	
	 Su_ii 1.4282e-05	
	 Su_fes 1.3412e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 9
	 equilibrate 9
	 X 1.1310e-03
	SOLUTION 10
	 water   1.5633e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 10
	 equilibrate 10
	 Su_ 1.1691e-03  5.2840e+05   1.4212e-03	
	 Su_ii 1.5994e-05	
	 Su_fes 1.5019e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 10
	 equilibrate 10
	 X 1.2665e-03
	SOLUTION 11
	 water   1.7306e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 11
	 equilibrate 11
	 Su_ 1.2942e-03  5.2840e+05   1.5733e-03	
	 Su_ii 1.7705e-05	
	 Su_fes 1.6626e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 11
	 equilibrate 11
	 X 1.4020e-03
	SOLUTION 12
	 water   1.8979e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 12
	 equilibrate 12
	 Su_ 1.4192e-03  5.2840e+05   1.7253e-03	
	 Su_ii 1.9416e-05	
	 Su_fes 1.8233e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 12
	 equilibrate 12
	 X 1.5375e-03
	SOLUTION 13
	 water   2.0651e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 13
	 equilibrate 13
	 Su_ 1.5443e-03  5.2840e+05   1.8774e-03	
	 Su_ii 2.1127e-05	
	 Su_fes 1.9840e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 13
	 equilibrate 13
	 X 1.6730e-03
	SOLUTION 14
	 water   2.2324e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 14
	 equilibrate 14
	 Su_ 1.6694e-03  5.2840e+05   2.0295e-03	
	 Su_ii 2.2839e-05	
	 Su_fes 2.1448e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 14
	 equilibrate 14
	 X 1.8085e-03
	SOLUTION 15
	 water   2.3997e-04	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	
	SURFACE 15
	 equilibrate 15
	 Su_ 1.7945e-03  5.2840e+05   2.1815e-03	
	 Su_ii 2.4550e-05	
	 Su_fes 2.3055e-06	
	 donnan 1.6843e-09 viscosity calc correct  false	
	EXCHANGE 15
	 equilibrate 15
	 X 1.9441e-03
	SOLUTION 16
	 water   5.0266e-03	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476
	SOLUTION 17
	 water   2.0000e-01	
	 pH 7.6
	 pe 14 O2(g) -1.0
	 temp 23
	 Na 240
	 K 1.61
	 Mg 16.9
	 Ca 25.8
	 Sr 0.505
	 Cl 300
	 S(6) 14.1
	 Fe(2) 0.0
	 Alkalinity 0.476	        
	END	
	PHASES 
	 A_Hto
	 Hto = Hto
	 log_k -15
	 A_Na_tr
	 Na_trCl = Na_tr+ + Cl-
	 log_k -14
	 A_Cl_tr
	 NaCl_tr = Na+ + Cl_tr-
	 log_k -14
	 A_Cs
	 CsCl = Cs+ + Cl-
	 log_k -13	
	EQUILIBRIUM_PHASES 17
	A_Hto 0 0	        
	END	
	MIX 3
	           4  6.6932e-04	
	MIX 4
	           5  1.9357e-04	
	MIX 5
	           6  1.5439e-04	
	MIX 6
	           7  1.8625e-04	
	MIX 7
	           8  2.1811e-04	
	MIX 8
	           9  2.4997e-04	
	MIX 9
	          10  2.8183e-04	
	MIX 10
	          11  3.1369e-04	
	MIX 11
	          12  3.4555e-04	
	MIX 12
	          13  3.7741e-04	
	MIX 13
	          14  4.0927e-04	
	MIX 14
	          15  4.4113e-04	
	MIX 15
	          16  7.6509e-04	
	MIX 16
	          17  4.2533e-03	        
	END	  
	TRANSPORT	
	 warnings true	
	 shifts 1120	
	 flow_direction diff
	 cells 1
	 bcond 1 2
	 stagnant 15	
	 timest   1.5429e+03	
	 multi_d true   2.5000e-09  1.5900e-01 0.0 1	
	 interlayer_d true 0.001 0.0 1300	
	 punch_frequency 14
	 punch_cells 17	
	USER_GRAPH 1 Example 21
WARNING: No cell-lengths were read; length = 1 m assumed.
WARNING: No dispersivities were read; disp = 0 assumed.
WARNING: No porosities were read; used the value 1.59e-01 from -multi_D.
	 -chart_title " Hto Diffusion to Outer Cell"	
	 -plot_tsv_file ex21_Hto_rad.tsv	
	 -axis_scale x_axis 0 20	
	 -axis_titles "TIME, IN DAYS" "FLUX, IN MOL/M2/S" "ACCUMULATED MASS, IN MOL"	
	 -plot_concentration_vs time	
	 10 days = total_time / (3600 * 24)	
	 20 a = equi("A_Hto")	
	 30 IF get(1) = 0 AND total_time > 0 THEN put(total_time, 1)	
	 40 dt = get(1)	
	 50 plot_xy days - dt / (2 * 3600 * 24), (a - get(2)) / dt /  8.2988e-03, color = Green, symbol = None	
	 60 put(a, 2)	
	 70 plot_xy days, equi("A_Hto"), y_axis = 2, color = Red, symbol = None	        
	END	

Calculating transport: 1 (mobile) cells, 1120 shifts, 1 mixruns...

	END
