PhreeqcUsers Discussion Forum

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
 

  • Forum Home
  • Login
  • Register

  • PhreeqcUsers Discussion Forum »
  • USER_PUNCH/USER_GRAPH »
  • BASIC functions »
  • USER_GRAPH with Recirculated Solutions in TRANSPORT
« previous next »
  • Print
Pages: [1]   Go Down

Author Topic: USER_GRAPH with Recirculated Solutions in TRANSPORT  (Read 412 times)

davidblevy

  • Frequent Contributor
  • Posts: 11
USER_GRAPH with Recirculated Solutions in TRANSPORT
« on: March 03, 2021, 05:37:11 PM »
This file recirculates strong HCl through a column of dolomite/calcite/quartz (5 PV at a time). To plot output from the last cell (cell 10) consecutively, I used a separate USER_GRAPH block for each transport step, where the number of PVs from proceeding steps is added to the (STEP_NO.+0.5)/cell_no. Is there an easier way to have a single USER_GRAPH which plots the consecutive PVs from the last cell? This works for me, but I am trying to learn more about USER_GRAPH. Thank you, David.


SOLUTION 0 Pure Water
-units   moles/L

REACTION 1 HCl
HCl 2 #7% HCl
SAVE SOLUTION 0
END

USE SOLUTION 0

SOLUTION 1-10
-water

END

PRINT
-reset   false

END

USER_GRAPH 1
-initial_solutions   false
-chart_title "Dolomite Dissolution/7% HCl/Closed System"
-headings   pH
-axis_titles "Pore Volumes" "pH"
-axis_scale x_axis 0 auto
-axis_scale y_axis -2 11
-start
10 x = (STEP_NO +0.5)/cell_no
20 PLOT_XY x, -LA("H+"), color=Red,symbol=Circle, Symbol_size=6, Line_width=2, y_axis=1
-end

TRANSPORT
-cells   10
-lengths   10*0.00635
-shifts   50
-punch_cells 10

EQUILIBRIUM_PHASES 1-10
Dolomite(ordered)   0.0    10
Calcite      0.0   5
Quartz      0.0   5

COPY cell 10 0

END

USER_GRAPH 1
-initial_solutions   false
-chart_title "Dolomite Dissolution/7% HCl/Closed System"
#-headings   pH
-axis_titles "Pore Volumes" "pH"
-axis_scale x_axis 0 auto
-axis_scale y_axis -2 11
-start
10 x = ((STEP_NO +0.5)/cell_no)+5
20 PLOT_XY x, -LA("H+"), color=Red,symbol=Circle, Symbol_size=6, Line_width=2, y_axis=1
-end

TRANSPORT
-shifts   50   

COPY cell 10 0

END

USER_GRAPH 1
-initial_solutions   false
-chart_title "Dolomite Dissolution/7% HCl/Closed System"
#-headings   pH
-axis_titles "Pore Volumes" "pH"
-axis_scale x_axis 0 20
-axis_scale y_axis -2 11
-start
10 x = ((STEP_NO +0.5)/cell_no)+10
20 PLOT_XY x, -LA("H+"), color=Red,symbol=Circle, Symbol_size=6, Line_width=2, y_axis=1
-end

TRANSPORT
-shifts   50   
END
Logged

dlparkhurst

  • Top Contributor
  • Posts: 2483
Re: USER_GRAPH with Recirculated Solutions in TRANSPORT
« Reply #1 on: March 03, 2021, 07:00:26 PM »
Here is one way to do what I think you want.

In the first TRANSPORT block, define a time step of 0.1 (sec). It is numerically equal to the number of pore volumes per shift (given 10 cells). Then set x = TOTAL_TIME in USER_GRAPH 1. TOTAL_TIME increases monotonically through both TRANSPORT calculations. Eliminate USER_GRAPH 2.

Alternatively, define a realistic time step T, and set x = TOTAL_TIME/T/10 (= PV).
Logged

dlparkhurst

  • Top Contributor
  • Posts: 2483
Re: USER_GRAPH with Recirculated Solutions in TRANSPORT
« Reply #2 on: March 03, 2021, 08:08:00 PM »
I think you need to be careful of a problem. Your REACTION 1 gets added to cell 1 at each TRANSPORT shift. You should probably number it REACTION 100, or some number that does not interfere with your 10 cells.

What should happen in a recirculating system is that calcite and dolomite dissolve to equilibrium. After one pore volume, there should be no change in composition.
Logged

davidblevy

  • Frequent Contributor
  • Posts: 11
Re: USER_GRAPH with Recirculated Solutions in TRANSPORT
« Reply #3 on: March 03, 2021, 08:49:41 PM »
That is a very important point! I really appreciate your helpful suggestions.

David
Logged

  • Print
Pages: [1]   Go Up
« previous next »
  • PhreeqcUsers Discussion Forum »
  • USER_PUNCH/USER_GRAPH »
  • BASIC functions »
  • USER_GRAPH with Recirculated Solutions in TRANSPORT
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines | Terms and Policies
  • XHTML
  • RSS
  • WAP2