CO2SYS | |
Author: | Ernie Lewis and Doug Wallace |
Released: | 1998 |
Programming Language: | QBasic, MATLAB, Python, Microsoft Excel |
Language: | English |
Website: | https://cdiac.ess-dive.lbl.gov/ftp/co2sys/https://pyco2sys.readthedocs.io/en/latest/https://ecology.wa.gov/Research-Data/Data-resources/Models-spreadsheets/Modeling-the-environment/Models-tools-for-TMDLs |
CO2SYS is a family of software programs that calculate chemical equilibria for aquatic inorganic carbon species and parameters. Their core function is to use any two of the four central inorganic carbon system parameters (pH, alkalinity, dissolved inorganic carbon, and partial pressure of carbon dioxide) to calculate various chemical properties of the system. These programs are widely used by oceanographers and limnologists to understand and predict chemical equilibria in natural waters.[1]
Chemical equilibria in marine and freshwater systems were calculated according to various conventions for most of the 20th century, which led to discrepancies among laboratories' calculations and limited scientific reproducibility.[2] CO2SYS was first published by Ernie Lewis and Doug Wallace in 1998 as a DOS-interface program written in QBasic. Subsequent developments have included several MATLAB implementations, two Microsoft Excel templates,[3] [4] a Python package "PyCO2SYS", and an R package inspired by CO2SYS, "seacarb".[5] Development of the various CO2SYS programs continues as of 2021 with the addition of more chemical equilibrium parameters and compatibility with a wider range of environments, e.g. anoxic waters.[6]
The aquatic inorganic carbon system is composed of the various ionic, dissolved, solid, and/or gaseous forms of carbon dioxide in water. These species include dissolved carbon dioxide, carbonic acid, bicarbonate anion, carbonate anion, calcium carbonate, magnesium carbonate, and others. The relative amounts of each species in a body of water depends on physical variables including temperature and salinity, as well as chemical variables like pH and gas partial pressure. Variables like alkalinity and dissolved (or total) inorganic carbon further define a mass and charge balance that constrains the total state of the system.[7] [8]
Given any two of the four central inorganic carbon system parameters (pH, alkalinity, dissolved inorganic carbon, partial pressure of carbon dioxide) the remainder may be derived by solving a system of equations that adhere to the principles of chemical thermodynamics.