Aqion

Aqion is a hydrochemistry software tool. It bridges the gap between scientific software (such like PhreeqC ) and the calculation/handling of "simple" water-related tasks in daily routine practice. The software aqion is free for private users, education and companies.

Motivation & history
First. Most of the hydrochemical software is designed for experts and scientists. In order to flatten the steep learning curve aqion provides an introduction to fundamental water-related topics in form of a "chemical pocket calculator".

Second. The program mediates between two terminological concepts: The calculations are performed in the "scientific realm" of thermodynamics (activities, speciation, log K values, ionic strength, etc.). Then, the output is translated into the "language" of common use: molar and mass concentrations, alkalinity, buffer capacities, water hardness, conductivity and others.

History. Version 1.0 was released in January 2012 (after a half-year test run in 2011). The project is active with 1-2 updates per month.

Features

 * Validates aqueous solutions (charge balance error, parameter adjustment)
 * Calculates physico-chemical parameters: alkalinity, buffer capacities (ANC, BNC), water hardness, ionic strength
 * Calculates aqueous speciation and complexation
 * Calculates pH of solutions after addition of chemicals (acids, bases, salts)
 * Calculates the calcite-carbonate system (closed/open system, Langelier Saturation Index)
 * Calculates mineral dissolution, precipitation, and saturation indices
 * Calculates mixing of two waters
 * Calculates reduction-oxidation (redox) reactions
 * Plots titration curves

Fields of application

 * Water analysis and water quality
 * Geochemical modeling (in simplest form)
 * Education

Limits of application

 * only inorganic species (no organic chemistry)
 * only equilibrium thermodynamics (no chemical kinetics)
 * only aqueous solutions with ionic strength ≤ 0.7 mol/L (no brines)

Basic algorithm & numerical solver
There are two fundamental approaches in hydrochemistry: Law of mass action (LMA) and Gibbs energy minimization (GEM). The program aqion belongs to the category LMA approach. In a nutshell: A system of NB independent basis components j (i.e. primary species), that combines to form NS secondary species i, is represented by a set of mass-action and mass-balance equations:

(1)      mass action law:         $$\{i\} \,=\, K_i \, \prod_{j=1}^{N_B} \,\{j\}^{\nu_{i,j}} $$        with i = 1 ... NS

(2)      mass balance law:         $$[j]_{TOT} \,=\, [j] + \sum_{i=1}^{N_S}\, \nu_{i,j} \,[i] $$        with j = 1 ... NB

where Ki is the equilibrium constant of formation of the secondary species i, and &nu;i,j represents the stoichiometric coefficient of basis species j in secondary species i (the values of &nu;j,i can be positive or negative). Here, activities ai are symbolized by curly brackets {i} while concentrations ci by rectangular brackets [i]. Both quantities are related by the

(3)      activity correction:         $$\{i\} \,=\, \gamma_{i} \, [i] $$

with &gamma;i as the activity coefficient calculated by the Debye–Hückel equation and/or Davies equation. Inserting Eq.(1) into Eq.(2) yields a nonlinear polynomial function fj for the j-th basis species:

(4)      $$f_j (c_1,c_2,...,c_{N_B}) \,=\, [j]_{TOT} - [j] - \sum^{N_S}_{i=1} \frac{\nu_{i,j}}{\gamma_i}\, K_i\, \prod^{N_B}_{k=1} \{k\}^{\nu_{i,k}} \,=\,0 $$

which is the objective function of the Newton–Raphson method.

To solve Eq.(4) aqion adopts the numerical solver from the open-source software PhreeqC. The equilibrium constants Ki are taken from the thermodynamic database wateq4f.

Examples, test & verification
The software aqion is shipped with a set of example solutions (input waters) and a tutorial how to attack typical water-related problems (online-manual with about 40 examples). More examples and exercises for testing and re-run can be found in classical textbooks of hydrochemistry.

The program was verified by benchmark tests of specific industry standards.