Spreadsheet Based Scaling Calculations and Membrane Performance
Spreadsheet Based Scaling Calculations and Membrane Performance
Spreadsheet Based Scaling Calculations and Membrane Performance
UCRL-JC-143230
Spreadsheet Based
Scaling Calculations and
Membrane Performance
Thomas D. Wolfe
CEO
PerLorica Inc.
Grass Valley, California
This document was prepared as an account of work sponsored by an agency of the United States
Government. Neither the United States Government nor the University of California nor any of their
employees, makes any warranty, express or implied, or assumes any legal liability or responsibility for
the accuracy, completeness, or usefulness of any information, apparatus, product, or process disclosed, or
represents that its use would not infringe privately owned rights. Reference herein to any specific
commercial product, process, or service by trade name, trademark, manufacturer, or otherwise, does not
necessarily constitute or imply its endorsement, recommendation, or favoring by the United States
Government or the University of California. The views and opinions of authors expressed herein do not
necessarily state or reflect those of the United States Government or the University of California, and
shall not be used for advertising or product endorsement purposes.
This work was performed under the auspices of the U. S. Department of Energy by the University of
California, Lawrence Livermore National Laboratory under Contract No. W-7405-Eng-48.
This report has been reproduced directly from the best available copy.
OR
Thomas D. Wolfe
CEO
PerLorica Inc.
Grass Valley, California
Abstract
Many membrane element manufacturers provide a computer program to aid buyers in the use
of their elements. However, to date there are few examples of fully integrated public domain
software available for calculating reverse osmosis and nanofiltration system performance. The
Total Flux and Scaling Program (TFSP), written for Excel 97 and above, provides designers and
operators new tools to predict membrane system performance, including scaling and fouling
parameters, for a wide variety of membrane system configurations and feedwaters.
The TFSP development was funded under EPA contract 9C-R193-NTSX. It is freely
downloadable at www.reverseosmosis.com/download/TFSP.zip. TFSP includes detailed
calculations of reverse osmosis and nanofiltration system performance. Of special significance,
the program provides scaling calculations for mineral species not normally addressed in
commercial programs, including aluminum, iron, and phosphate species. In addition, ASTM
calculations for common species such as calcium sulfate (CaSO4.2H2O), BaSO4, SrSO4, SiO2,
and LSI are also provided.
Scaling calculations in commercial membrane design programs are normally limited to the
common minerals and typically follow basic ASTM methods, which are for the most part
graphical approaches adapted to curves. In TFSP, the scaling calculations for the less common
minerals use subsets of the USGS PHREEQE and WATEQ4F databases and use the same
general calculational approach as PHREEQE and WATEQ4F. The activities of ion complexes
are calculated iteratively. Complexes that are unlikely to form in significant concentration were
eliminated to simplify the calculations. The calculation provides the distribution of ions and ion
complexes that is used to calculate an effective ion product Q. The effective ion product is
then compared to temperature adjusted solubility products (Ksps) of solids in order to calculate
a Saturation Index (SI) for each solid of interest. The SI is expressed as a log value (log(Q)
log(Ksp)) where positive values indicate potential scaling conditions. As this is an unprotected
spreadsheet, the methodology is plainly visible to and readily modified by the user.
General Comments
Although most of the major membrane manufacturers provide calculation programs designed for their
specific membranes, the experienced engineer can often be well served by having the calculation
methodology available for easy viewing and/or modification. A spreadsheet-based program therefore
provides a useful tool to the water system engineer. The feedwater to a membrane system is rarely
scaling before it is concentrated by a pass through membrane system. However, scaling becomes
more likely as fluid concentrations increase and it is useful to be able to predict the concentrations of
the various ions at all points in the system, particularly in the concentrate. In addition, it is important to
estimate the effective concentration at the membrane surface, which is always higher than the bulk
fluid concentration due to concentration polarization.
In this spreadsheet we use a combination of iterative and direct calculation methods to first estimate
the performance of a given membrane system, then predict the concentrations of the solution at
various points in the system, and finally compute a scale index for the species of interest.
Program Flow
Since this is a spreadsheet, the data and calculations are organized by type and function onto
different sheets or tabs. Buttons on the sheets provide an alternate means of navigation between
sections.
Where possible, the spreadsheet itself was used to perform the calculations. For example, the
carbonate equilibria in the feedwater are handled in the spreadsheet. In addition, Langelier
Saturation Index (LSI) and ASTM methods for CaSO4, SrSO4, BaSO4, and SiO2 are also handled in
the spreadsheet. However, the more detailed membrane performance and scaling calculations are
General Approach
The general approach used is the same as used by most commercial membrane design programs.
Basically the user needs to guess a design and then a detailed calculation is made. The TFSP
program assists this process by continually displaying and updating an estimated feed pressure and
TDS values for the user in the spreadsheet. This estimated pressure is the seed pressure for the
start of the iterations. Final data display includes calculations for permeate, feed, net feed with
recycle, and concentrate. Interested users can modify the program to display bank by bank data if
they so desire.
The computational approach, although well understood conceptually, is more complicated in practice.
The TFSP program makes one simplification over most commercial programs that greatly helps the
calculation rates in that each vessel is converted to the form of one element, which directly returns
the performance for each bank in the system. TFSP calculates salt flux on an ion-by-ion basis during
each pass through the system and balances carbonates in the concentrate and permeate analyses
while accounting for the free passage of CO2 through the membranes. As an aside, the free
passage of CO2 is responsible for the significantly lower pH in the permeate as compared to the
feedwater in most membrane systems.
Water flux, or more properly the flow rate, is calculated as follows, where Pi is osmotic pressure. The
effective pressure or PNet is the net trans-membrane differential pressure. All values are first
converted to meters, seconds, and atmospheres to make calculations simpler. Even though using a
flow rate based on m3/sec results in small absolute numbers, the precision of the spreadsheet is
more than sufficient to return accurate results. Data can be displayed in a variety of conventional
metric or US units.
A review of some of the simpler membrane transport functions might be useful to understand the
calculation process.
A value, or the water transport value, or simply the water flux, is defined for each membrane type
as water flow through the membrane per unit of membrane area per some pressure unit. For
example:
Equation 1
m3
sec = m
" A" Value = 2
m * atm sec* atm
Note that A value is dependent on pressure, which is of course the effective transmembrane
pressure and the area, thus multiplying by the area and net pressure provides a direct calculation of
the water flow rate through the membrane.
A Salt Flux coefficient, or B value is also generally defined as a salt passage rate or some unit of
mass or volume per unit of membrane area. This reduces to a velocity type factor i.e. m/sec. Note
that the salt passage rate is almost entirely dependent on the concentration difference between both
Equation 2
m
" B" Value =
sec
Both B and A are dependent on temperature and in some cases can be dependent on feed
concentration, pH, and/or applied pressure. The corrections for pH are most important when
considering the selectivity of TFC type membranes for silica transport or rejection. However, for most
applications, a good approximation can be made if only temperature is considered.
Combining the equations for A & B we get the familiar equation used to determine permeate
concentration for each individual ion.
Equation 3
Similarly, using the familiar reverse osmosis transport equations, flow through the membrane at any
point in the system can be expressed as follows:
Equation 4
Thus by combining the above equations for flow and permeate concentration, calculating a realistic
concentration polarization, and calculating a transmembrane pressure which accounts for pressure
losses through the system, we can compute the conditions for each individual element within the
system.
The concentration of each ion in the permeate is found as follows. A variable, "MegDiff" is defined for
each ion first which is the effective difference in concentration of the ion from the membrane surface
to the permeate. This includes a factor for concentration polarization. Note also that the Bvalue is
different for each ion. However, rather than define a separate value for each ion, it is customary to
define a ratio to either sodium or chloride. Typically the ratio varies from 0.1 to 4, corresponding to a
salt flux of 10% to 400% of the chloride rate.
Equation 6
BValue * BCorrectionByIonIon
PermConcIon = MeqDiff Ion *
PNet * AValue + BValue
PermTDS = PermConc(ion)
all ions
PNet is as defined above, i.e. the feed pressure less differential pressure less the osmotic pressure
difference between the average feed stream and permeate. BcorrectionByIon is stored in the
spreadsheet as a function of the membrane type selected. This is the ratio of salt flux for the ion in
question relative to either chloride or sodium. This value is easily modified by the user to provide for
special cases, or to even create new ions and coefficients.
Since the permeate concentration obviously affects the water flux and required pressure and vice
versa, an iterative approach is necessary to solve the system. The general steps are as follows:
a) Acquire a valid water analysis and target feed pH from the user supplied data. Read this
data into the internal variables.
b) Acquire flow and recovery information from the user via a graphic screen.
c) Convert all flow rates to the internal flow scheme - TFSP uses m3/sec as the base flow units.
d) Acquire from the user the suggested array, bank, and vessel layout and save in the internal
variables. Typically, a system with higher recovery needs more banks. For example a 75%
recovery system might specify 6 elements per vessel, 2 banks total in the array, and an
array layout of 16:8. That is 16 vessels feeding 8 vessels in bank 2.
e) Acquire from the user the selected membrane element information. When the user selects
the type of element, the program loads the specific data about the element such as A value,
B value, B values relative to Na or Cl per each ion (dependent on membrane type), area in
m2, differential pressure coefficients and so on. Membrane data is stored on the Membrane
Data sheet. It is freely changeable and allows the user to create new elements as needed.
f) Set up the selected membrane element in the vessel and calculate delta pressure and
concentration polarization coefficients (called the BetaCoef in the code) for the selected
elements. Delta pressure is calculated from a coefficient specific to the membrane
configuration. The TFS program by default utilizes coefficients based on commercial
membranes typical of those elements used for so called pure water applications. These
assume water is the medium processed and assumes normal thickness feed size spacer
materials. The user can adjust these coefficients for special elements as needed. Note that
TFSP uses a simplified approach for this purpose. Given sufficient empirical data and
physical dimensions, it is also quite feasible to calculate DP directly from using more
rigorous techniques. However this requires physical data not usually obtainable from the
manufacturers and the approximation below can be created from the tech data sheets
provided by many manufacturers.
dp = dpCoef *
2
Equation 8
OsmoticPressure(atm) = Pi = RT * [c ]
AllIons
i i
The Calculations for RO (reverse osmosis) and NF (nanofiltration) systems are arranged in
a "Do While Loop" that starts with an assumed applied pressure. From this pressure, flow
rates and concentrations are calculated on a vessel by vessel basis through the system.
The total calculated flow is then compared to the target flow the user provided. If low, then
the pressure is raised proportionally, and if high then the pressure is lowered proportionally.
Once the calculated flow is within the set percentage of the target flow - typically 0.2% to 1%
- then the calculation program terminates and data is returned to the spreadsheet for
display.
i) RO and NF calculations differ in approach to the transport of ions. For reverse osmosis
systems, the permeate anions and cations are balanced equally. That is, any difference in
overall charge in the first pass through the permeate concentration calculation (Equation 8)
is split equally and the permeate concentration adjusted proportionally for each ion. For an
NF system, the anions are assumed to control and the cations are adjusted to balance the
permeate analysis.
Scaling Calculation Methods
ASTM Methods
Calculations for CaSO4, BaSO4, and SrSO4 are taken from ASTM D 4692, Figures 1-3 respectively.2
ASTM D4993 is the source for SiO2 solubility.3 Langelier Saturation Index (LSI) is taken from the
definition of LSI in the literature, which is consistent with data in Stumm and Morgan4 ASTM data was
used for these common scale forming minerals since this the accepted industry method. 5
Calcium Fluoride (CaF2) is computed in a similar manner to the ASTM data except that the Ksp was
taken from the Phreeqe database. The Vant Hoff method is used to correct for different
temperatures.
Equation 11
H 1 1
Van' tHoff Equation = KspT 2 = KspT =25
R T2 298.16
R = GasConst, T2 = deg K of solution, KT =25 = Ksp at 25o C, H = Enthalpy
The ASTM methods are essentially polynomials derived by curve fitting techniques. These provide a
Ksp value as a function of temperature and ionic strength (IS). The corrected Ksp is compared to the
actual ion product for the stream of interest and a percent of solubility or percent of saturation is
defined as follows. This method is also used for calcium fluoride.
pH is the pH of the solution, "pHs" is Langeliers calculated saturation pH. Thus a negative LSI
indicates that CaCO3 should not precipitate from solution.
The values of pK2 and pKSo are the carbonate solubility products and are corrected for
temperature. pK2 is corrected for ionic strength as well. Values were taken from Stumm &
Morgan.4 At 25 deg C, pK2 ~= 10.357, pKSo ~=8.48.
pCa equals -log([Ca]) where [Ca] = calcium activity in moles/liter (activity can be thought of as an
ionic strength-corrected concentration). Activities are computed using the Debye Huckel method.
pALK equals -log([Total Alkalinity]), and Total Alkalinity = [HCO3] + [CO3] + [OH] [H]. [HCO3]
and [CO3] are also corrected for ionic strength.
The value for carbonate (CO3) is computed from [HCO3] and pH.
It should be noted that LSI is not considered useful above an ionic strength of about 0.3. There are
many excellent texts on LSI calculation so it will not be covered in further detail here.
Other Minerals
Less common minerals which are nevertheless of interest to membrane system designers are
handled by the more rigorous aqueous complexation methods typical of the WaterEQ or Phreeqe
programs (WATEQ4F, Plummer et al., 19766, PHREEQE Parkhurst et al., 19807, and Truesdell,
19748). A given solution analysis is first numerically speciated into the various aqueous complexes
that are present using thermodynamic stability constants. The saturation state of the solid is then
calculated from the true solubility product, which is not a function of ionic strength, and the ionic
concentrations determined from the speciation calculation.
After a careful consideration of many possible minerals, it was decided to limit the calculations and
display to the minerals of most interest in the operating temperature and operating pH range of most
membrane systems i.e. 5 to 50 deg C, and pH 4 to 10.
Analcime NaAlSi2O6.H2O
Gibbsite - aluminum hydroxide Al(OH)3
Amorphous Al(OH)3 - aluminum hydroxide Al(OH)3
Fe(OH)3 (amorphous) - Ferric hydroxide Fe(OH)3
Goethite - Ferric hydroxide FeO(OH)
Siderite - Ferrous carbonate FeCO3
Vivianite - Ferrous phosphate Fe3(PO4)2:8H2O
Hydroxyapatite - Calcium hydroxy phosphate Ca5(PO4)3OH
Gypsum (also by ASTM methods) - Calcium sulfate CaSO4.2H2O
Sepiolite (High pH silica foulant) - Mag Silicate Mg4Si6O15(OH)2:6H2O
For example, for ferric iron, we consider the following aqeuous species:
The solution to this set of equations provides the concentrations and activities of all species, including
uncomplexed metal ion activities that are used to compute the ion products for the solids. These ion
products are then compared to known Ksp values for the minerals of interest and a saturation index
(SI) is calculated:
Ion PRODUCT
SI = Log = Log ( IP) Log ( Ksp ) Equation 14
Ksp
For example, Na and SO4 form a complex with one negative charge - i.e. NaSO4. The Log(Ksp) is
calculated for this complex at the solution temperature on the sheet entitled LogKs. The formula for
this complex is created as follows, where represents the activity of the species under consideration.
Activity values are calculated for each complex and each species on the sheet ActCof, and the
"Available" concentration is determined on the sheet entitled "Calc".
Of course many other complexes containing both Na and SO4 are also produced, and the amount
available of each ion is affected by all of the other complexes. Because of this, the solution to the
problem must be obtained iteratively. The Excel built in Solver is convenient for solving this problem.
The program automatically implements a series of VBA commands which sets the Solver up and
then runs it. The Solver continues to be invoked until the system of equations is solved to a degree of
accuracy that is acceptable to the user.
For example, assume we wish to calculate the actual ion product for CaSO4 - 2H2O in the solution to
determine the scaling potential. We calculate the actual and available concentrations as follows.
We then calculate the Log(Ksp) for CaSO4-2H2O in this solution and temperature to be -4.59. The
logarithm of the ion product for CaSO4 based on the concentration available is compared to the
Log(Ksp) to provide an SI.
Thus at this condition, CaSO4 is significantly undersaturated. Since the SI is log based, the percent of
saturation is 10(-0.7) = 0.1995 or about 20%. In this example, the ASTM method, which uses a Ksp
corrected for ionic strength with typical analyses yielded a value of about 21% of saturation. Thus the
ASTM method compares very well and slightly conservatively in this case. As an aside, this points
out the big difference in comparing solubility using percent of saturation values as compared to SIs.
SIs are logs so some confusion is possible when comparing different systems.
Nevertheless, it should be noted that the calculations performed using the ion complex method are
performed for minerals that may actually supersaturate to a very high degree, and thus not cause
problems in many membrane system applications. The aluminum and iron compounds investigated
are almost always present to some degree in surface and ground waters. This program provides the
user a means to effectively determine the optimum pH conditions to minimize potential fouling from
these compounds. However, the user should note that iron and aluminum compounds are usually
present in the amorphous condition and the fouling or non-fouling tendencies of the compounds may
be greatly dependent on the presence or absence of organic or biological components in the
feedwaters, The organic and biological components may act either to solublize or precipitate them,
depending on the water conditions and nature of the organics present.
Carbonate Equilibrium
The calculation of the appropriate carbonate and pH distribution is an important part of this program.
Note that membrane systems readily pass carbon dioxide (CO2) while carbonate (CO3--) is strongly
rejected. Thus the permeate side of the membrane is enriched with carbon dioxide while the
feed/concentrate side of the membrane is enriched with carbonate and bicarbonate. The net effect of
this separation is to lower the pH of the permeate while the concentrate pH rises. The TFSP program
effectively models this behavior. For applications in which a membrane system precedes a
deionization (DI) system, the additional carbon dioxide can pose a load on the anion resins. The
TFSP program can help the user to evaluate the use of acid versus scale inhibitor or softening resins
as the pretreatment step.
[ HCO3 ]
Total Inorganic Carbon = TIC =
MoleFraction HCO3
e) Knowing the Total Inorganic Carbon (TIC), we then calculate the CO2 and CO3 values from
pH and K1 and K2 as follows. The values are in moles/liter.
1
(H + )2 H+ Equation 19
[CO3 ] = TIC * +1+
K1 * K 2 K 2
1
( K1) 2 K1 * K 2
[CO2 ] = TIC * +
+1 + + 2
H ( H )
f) For the treated feed - i.e. the feed with the pH adjusted, we have already computed the
Total Inorganic Carbon (TIC) and thus the new carbonate distribution can be readily
calculated from the equations above. The amount of acid required is easily computed from
the change in bicarbonate concentration from the user-supplied feed water to the treated
feed water composition.
Computing the likelihood of scale formation using the TFSP is a straightforward matter. Today, the
membrane designer has a wide variety of scale prevention techniques and products available that
potentially allow a system to operate at supersaturated conditions. The original scale inhibitor of
choice in membrane systems was sodium hexametaphosphate or SHMP. This has the advantage of
being relatively nontoxic, cheap, easily soluble in water, and reasonably effective with carbonates
and sulfates. Unfortunately, it also begins to hydrolyze immediately upon dissolution so the active life
of the material is poor and this has led to many inadvertent failures in RO systems over the years.
Phosphonate or polymer-based scale inhibitors with superior performance and no degradation in
solution have come to replace SHMP in most applications.
Threshold
Dispersion
Crystal Distortion
Threshold inhibitors are typically represented by the phosphonates, such as AMP and related
compounds. Threshold inhibitors are believed to function by absorption onto specific areas of a
crystal that is just beginning to grow, retarding or preventing its growth. Thus the crystal can
never grow large nor connect with other crystals that are in solution or are already precipitated
on the membrane. Typical doses are in the order of 15 - 25 ppm in the concentrate at maximum
effectiveness.
Crystal distortion mechanisms are similar to threshold inhibitors except that they work by
distorting the crystal during growth. Photomicrographs of crystal distorters at work are
particularly striking, showing round or irregular crystals. The prototypical crystal distorter is a
long-used scale inhibitor known as polyacrylic acid (PAA) polymer.
Dispersants are useful with both crystal distorters and threshold agents. These are typified by
carboxylic acid polymers such as polymaleic acid (PMA) or phosphonobutane tricarboxylic acid
(PBTC).9 Since threshold agents may produce very small, microscopic crystals, if any at all, a
dispersant is warranted for optimum fouling control.
Iron and aluminum compounds are considered in the TFSP calculations. Normally very insoluble
relative to compounds such as calcium sulfate, they are usually only present in low concentrations
anyway. However, the presence of iron can decrease the effectiveness of a threshold or distorter
agent by reacting or complexing with the agent, thus hindering its ability to prevent scale . Scale
inhibitor doses for threshold agents in particular must be increased in the presence of iron. With high
iron concentrations, increased inhibitor dose combined with a dispersant type agent can effectively
prevent scale formation even in under severe conditions.
The presence of iron or aluminum compounds above their solubility limits thus is not limiting but
suggests that additional scale inhibitor may be required. Many commercial programs already
The Total Flux and Scaling Program (TFSP), written for Excel 97 and above, provides designers
operators, and educators new tools to predict membrane system performance, including scaling
and fouling parameters, for a wide variety of membrane system configurations and feedwaters.
Of special significance, the program provides scaling calculations for mineral species not
normally addressed in commercial programs, including aluminum, iron, and phosphate species.
In addition, ASTM calculations for common predicted species such as calcium sulfate
(CaSO4.2H2O), BaSO4, SrSO4, SiO2, and LSI are also provided. The spreadsheet is fully
transparent, allowing the operator to manually change all aspects of the program.
The TFSP development was funded under EPA contract 9C-R193-NTSX and is freely downloadable
at www.reverseosmosis.com/download/TFSP.zip, or by contacting Thomas Speth at
[email protected]. Mention of trade names or commercial products in this article and
spreadsheet does not constitute endorsement or recommendation for use by the U.S. Government.
This work was in part performed under the auspices of the U.S. Department of Energy by the
University of California, Lawrence Livermore National Laboratory under contract No. W-7405-
Eng-48.
References
1
Castellan, GW, (1964) Physical Chemistry, Addison-Wesley Publishing, p 263ff.
2
ASTM. (1993) Section VI - Water-Treatment Materials: Section D 4692 - 87 "Standard Practice
For Calculation Of Sulfate Scaling Salts (Caso4, Srso4, Baso4) For Reverse Osmosis". In
Annual Book of ASTM Standards, Vol. 11.02, pp. 868-871.
3
ASTM. (1993) Section VI - Water-Treatment Materials: Section D 4993 - 89 "Standard practice for
Calculation and Adjustment of Silica (SiO2) for Reverse Osmosis".
4
Stumm W., Morgan J, 1976, Aquatic Chemistry, Wiley and Sons.
5
ASTM. (1993) Section VI - Water-Treatment Materials: Section D 3739 - 88 "Standard practice for
Ccalculation and Adjustment of the Langelier Saturation Index for Reverse Osmosis".
6
Plummer L. N., Jones B. F., and Truesdell A. H., (1976) WATEQF - A Fortran IV version of
WATEQ, a Computer Program For Calculating Chemical Equilibrium Of Natural Waters, United
States Geological Survey, Report Number Wat. Res. Inv. 76-13.
7
Parkhurst D. L., Thorstenson D. C., and Plummer L. N., (1980) PHREEQE- A Computer
Program For Geochemical Calculations, United States Geological Survey.
8
Truesdell, A.H., and Jones, B.F., (1974), WATEQ, A Computer Program For Calculating
Chemical Equilbria of Natural Waters U.S.G.S. J. Res., 2, 233-248.