Development and Application of a Hydrogeochemical Model for the Groundwater Treatment Process in Waterworks

: Drinking water quality is one of the most important factors affecting human health. The task of the waterworks is to purify raw water into drinking water. The quality of drinking water depends on two major factors: the raw water quality, and the treatment measures that are applied in the waterworks. Since the raw water quality develops over time, it must be determined whether the treatment measures currently used are also suitable when the raw water quality changes. For this reason, a hydrogeochemical model relevant to the drinking water quality during the treatment process was developed. By comparing the modeled results with the measured values, with the exception of chloride and sodium, all other relevant water quality parameters were consistent with one another. Therefore, the model proved to be plausible. This was also supported by the results of mass balance. The model can be used to forecast the development of drinking water quality, and can be applied as a tool to optimize the treatment measures if the raw water conditions change in the future.


Introduction
Water is essential for the survival of all living beings. Water, as one of the most important raw materials, is used for food preparation and other domestic purposes. A large proportion of the water in tap water systems comes from groundwater. Groundwater is an essential part of water resources and a crucial source for agricultural, industrial, and domestic water use [1]. It is estimated that global groundwater provides 50% of the current drinking water [2]. In recent years, with the continuous growth of the global population, the amount of groundwater exploitation has increased year by year, and the problem of groundwater pollution caused by human activities has become more serious [3,4].
The task of water treatment in urban waterworks is to remove impurities in the water through necessary treatment methods to make it meet the water quality requirements for drinking water. The conventional treatment process is mainly composed of flocculation, sedimentation or clarification, filtration, and disinfection, as used by most of the waterworks in the world [5]. The water treatment effect has relatively high requirements for the raw water quality of the water source. When the water source is groundwater, the constituents of raw water used by the waterworks are influenced significantly by the groundwater geochemistry in the catchment. In particular, excessive use of chemical fertilizers causes rainwater carrying a large amount of ammonium and nitrate in the soil layer to seep into the groundwater aquifers, causing pollution. When the groundwater pumped from the According to Hansen [11], the Fuhrberger Feld is essentially made up of quaternary sands, gravel, and interposed boulder marl or loam, which is interposed locally with thin layers of silt. The thickness of the Quaternary series averages 25 m, narrowing to just a few meters at the southern margin. The pre-Quaternary sequence of layers consists of  According to Hansen [11], the Fuhrberger Feld is essentially made up of quaternary sands, gravel, and interposed boulder marl or loam, which is interposed locally with thin layers of silt. The thickness of the Quaternary series averages 25 m, narrowing to just a few meters at the southern margin. The pre-Quaternary sequence of layers consists of tertiary clays, clay marls, and very silty fine sands, which overlay Cretaceous clay, clay marls, and marls. The aquifer base is partly formed by practically impermeable Tertiary and Cretaceous rocks, and partly by Elster Age boulder clay.
The unconfined aquifer of the Fuhrberger Feld consists of 20 to 35 m thick, wellpermeable loose Quaternary sediments. The average thickness of the Quaternary loose sediments is 25 m, and decreases to just a few meters at the southern edge [12]. A common groundwater body is formed in the sands and gravels of the Quaternary loose sediments. The aquifer base is formed by almost impermeable chalk clays and boulder clays or marls locally scaled at the base. The groundwater flows generally in a northerly direction towards the Aller, and locally towards Wietze and Wulbeck and the streams and ditches tributary to them. The average groundwater level gradient is about one per thousand. The groundwater level is 1-2 meters in most of the catchment area. The distances only increase to several meters in the area of the lowering funnels of the production wells and in the morphologically more structured southern geest areas.
The permeability coefficients for the Fuhrberg area are determined by pumping tests. The upper Fuhrberg series with finer grains has a lower permeability coefficient of 5 × 10 −4 m s −1 compared to the value of 1 × 10 −3 to 2.5 × 10 −3 m s −1 for the lower series. According to the DIN 18130 standard [13], the sediments are classified as highly permeable. The mean distance velocity in the upper Fuhrberg series is around 100 m a −1 , while for the lower series it is around 200 m a −1 [12].

Development of Groundwater Quality
The solid structure of the aquifer contains sulfide components [14][15][16]. Sulfur occurs in the sediment in the form of disulfides such as pyrite or marcasite [17][18][19]. In addition to the iron disulfide phases, organically bound carbon (C org ) in the form of detrital lignite or dissolved organic carbon is observed in groundwater aquifers [20][21][22]. These reductive phases are assumed to react with the nitrate in the groundwater recharge [17,23]. Since the substance inputs in coniferous forest areas and agricultural areas are different, two developments in groundwater quality are separated according to land use in the following subsections.

Development of Groundwater Quality under Agricultural Land
Fertilization mainly adds ammonium and nitrate to agricultural land [24]. Under aerobic conditions, ammonium is oxidized to nitrate in the soil zone. The plants absorb most of the nitrate. Only a small amount of mobile nitrate is carried into the groundwater space with the seepage water from the soil zone. The newly formed groundwater first reaches the oxidized zone where, due to the large input of nitrate, there are no longer any iron disulfide phases. Then, it goes into the iron disulfide mining zone. There, the nitrate introduced with the formation of groundwater is reduced to molecular nitrogen by iron disulfide, and at the same time iron disulfide is oxidized to sulfate and Fe(II). After passing through the iron disulfide degradation zone, nitrate is completely degraded, and groundwater enters the reduced zone. Here, sulfate is reduced to disulfide ions. The resulting disulfide ions react with Fe(II) ions to form iron disulfide again [25,26]. At the end of the flow section, the newly formed groundwater flows into the extraction well.

Development of Groundwater Quality under Coniferous Forest Areas
According to Hansen [11], the newly formed groundwater under coniferous forest areas is practically anaerobic and nitrate-free. However, it is possible that when there is a lot of new formation, a small amount of nitrate and molecular O 2 gets into the seepage water. Due to the low input of oxidizing agent(s), there is no completely oxidized zone. In the iron disulfide depletion zone and the reduced zone, the same reactions take place as in the groundwater under agricultural land. At the end of the flow section, the groundwater also flows into the extraction well.
The groundwater flows through various stream tubes into the production wells. If reduced, iron-rich groundwater from the reduction zone mixes with the oxidized, nitratebearing groundwater from the oxidized zone, and well clogging may occur as a result of the precipitation of iron(III) hydroxide/hydrated oxide. The newly formed groundwater under agricultural land is mixed with the groundwater newly formed under coniferous forest areas in wells and pumped as raw water.
According to Hansen [11], the quality development of the pumped raw water from well 4 as the water intake of the Fuhrberg waterworks has been shown.

The Water Treatment Processes of the Fuhrberg Waterworks
The first process of the raw water treatment at the Fuhrberg waterworks is cascade aeration in the aeration chamber ( Figure 2a). The raw water stored in the mixing tower is fed into the aeration chamber. The water is enriched with O 2 to oxidize the iron and manganese in the downstream treatment reactors. This removes free CO 2 from the water. agent is added to weigh the flakes, because the metal hydroxide sludge formed during flocculation does not sediment well due to its high water content [27]. H2O2 as an oxidizing agent, polyaluminum chloride (PAC) as a flocculant, and polyacrylamide as a flocculant are added to the water through the metering devices. In this way, the dissolved iron compounds together with the humic substances are completely oxidized in a short time, and are converted into a separable floccule. The floccule is held back in the accelerator and drawn off at regular intervals. The water cleaned by flocculation is delivered to the following treatment stage.
The third process of the raw water treatment is filtration through quartz gravel (Figure 2c). After adding milk of lime and potassium permanganate (KMnO4), the water from the accelerator is filtered through an open gravel filter. The milk of lime is used to raise the pH and the KMnO4 to oxidize the remaining flocculant. During filtration, iron residues and small amounts of humic substances are first removed from the water. The oxidation of ammonium and manganese then takes place with the help of microorganisms. The used quartz gravel is exchanged at regular intervals. Over time, elevated levels of manganese would lead to undesirable deposits in water tanks and the distribution network. After the addition of caustic soda (NaOH) to adjust the lime-carbonic acid balance, the cleaned water is temporarily stored in large drinking water tanks, and then delivered from the machine house to Hanover and the surrounding communities via powerful centrifugal pumps.

Data
The modeling was based on the measured parameters of the raw water and drinking water from the Fuhrberg waterworks. Eighteen indicator parameters of water samples were analyzed according to the Drinking Water Ordinance of Germany [28]. pH values and temperature were measured using an acidity meter. Acid capacity up to 4.3 and base capacity up to 8.2 were determined by titration using acid or base to the appropriate pH value. Concentrations of Ca, Mg, phosphate, ammonium, nitrate, sulfate, chloride, Cl, Na, and K were measured by ion chromatography (IC). Inductively coupled plasma mass spectrometry (ICP-MS) was used to measure Fe, Mn, and Al. The organic carbon content (TOC) was calculated by subtracting the total inorganic carbon (TIC) from the total carbon (TC).
To determine the changes in water quality caused by treatment, the measured raw water quality was compared with the measured drinking water quality. Moreover, to protect human health from negative influences caused by organic and inorganic contamination of drinking water, the quality of drinking water is regulated by the Drinking Water Ordinance [28]. In this context, the guidelines and limit values for health-related parameters are specified in the Drinking Water Ordinance.
There are seven sets of data on raw water and drinking water from Fuhrberg waterworks from 2020 to 2021. In order to facilitate comparison with the limit values of the Drinking Water Ordinance, the measured raw water and drinking water data were averaged. In Table 1, there is no change in the mean temperature during the treatment. The average conductivity at 25 °C increases from 514 µS/cm in the raw water to 540 µS/cm in The second process of the raw water treatment is flocculation in the accelerator (Figure 2b). The water, already enriched with O 2 , is fed into the accelerator from the aeration chamber. Due to the formation of iron(II)-humic substance complexes, the humic substances present in the raw water can complicate the iron oxidation and, thus, the flocculation of the iron. For this reason, the use of hydrogen peroxide (H 2 O 2 ) is necessary to accelerate iron oxidation. The flocculant is used to overcome the electrostatic repulsive forces and allow the interfering materials to agglomerate. In addition, a flocculation agent is added to weigh the flakes, because the metal hydroxide sludge formed during flocculation does not sediment well due to its high water content [27]. H 2 O 2 as an oxidizing agent, polyaluminum chloride (PAC) as a flocculant, and polyacrylamide as a flocculant are added to the water through the metering devices. In this way, the dissolved iron compounds together with the humic substances are completely oxidized in a short time, and are converted into a separable floccule. The floccule is held back in the accelerator and drawn off at regular intervals. The water cleaned by flocculation is delivered to the following treatment stage.
The third process of the raw water treatment is filtration through quartz gravel ( Figure 2c). After adding milk of lime and potassium permanganate (KMnO 4 ), the water from the accelerator is filtered through an open gravel filter. The milk of lime is used to raise the pH and the KMnO 4 to oxidize the remaining flocculant. During filtration, iron residues and small amounts of humic substances are first removed from the water. The oxidation of ammonium and manganese then takes place with the help of microorganisms. The used quartz gravel is exchanged at regular intervals. Over time, elevated levels of manganese would lead to undesirable deposits in water tanks and the distribution network. After the addition of caustic soda (NaOH) to adjust the lime-carbonic acid balance, the cleaned water is temporarily stored in large drinking water tanks, and then deliv-ered from the machine house to Hanover and the surrounding communities via powerful centrifugal pumps.

Data
The modeling was based on the measured parameters of the raw water and drinking water from the Fuhrberg waterworks. Eighteen indicator parameters of water samples were analyzed according to the Drinking Water Ordinance of Germany [28]. pH values and temperature were measured using an acidity meter. Acid capacity up to 4.3 and base capacity up to 8.2 were determined by titration using acid or base to the appropriate pH value. Concentrations of Ca, Mg, phosphate, ammonium, nitrate, sulfate, chloride, Cl, Na, and K were measured by ion chromatography (IC). Inductively coupled plasma mass spectrometry (ICP-MS) was used to measure Fe, Mn, and Al. The organic carbon content (TOC) was calculated by subtracting the total inorganic carbon (TIC) from the total carbon (TC).
To determine the changes in water quality caused by treatment, the measured raw water quality was compared with the measured drinking water quality. Moreover, to protect human health from negative influences caused by organic and inorganic contamination of drinking water, the quality of drinking water is regulated by the Drinking Water Ordinance [28]. In this context, the guidelines and limit values for health-related parameters are specified in the Drinking Water Ordinance.
There are seven sets of data on raw water and drinking water from Fuhrberg waterworks from 2020 to 2021. In order to facilitate comparison with the limit values of the Drinking Water Ordinance, the measured raw water and drinking water data were averaged. In Table 1, there is no change in the mean temperature during the treatment. The average conductivity at 25 • C increases from 514 µS/cm in the raw water to 540 µS/cm in the drinking water, and is lower than the specified limit of 2500 µS/cm at 20 • C. The mean pH value increases from 6.64 to 7.73 as a result of the treatment. Compared to the pH range of 6.5 to 9.5 regulated by the Drinking Water Ordinance, the pH value is shifted from the very weakly acidic range to a pH-neutral-weakly basic range as a result of the treatment. The acid capacity up to pH 4.3 (AC 4.3 ) is an approximate value for the hydrogen carbonate (HCO 3 − ) concentration. As a result of the processing, the mean value of AC 4.3 increases from 1.9 to 2.2 mmol/L. The base capacity up to pH 8.2 (BC 8.2 ) is an approximation for the dissolved carbon dioxide (CO 2(aq) ) concentration; it drops from 1.24 to 0.07 mmol/L. This means that the partially dissolved CO 2(aq) is degassed. The average concentration of calcium increases from 61 mg/L in raw water to 76 mg/L in drinking water. The average magnesium concentration also increases by 0.1 mg/L. These increases in the concentrations of calcium and magnesium in drinking water can be achieved by dosing the milk of lime. This means that the added milk of lime contains not only calcium, but also magnesium. The treatment reduces the concentrations of iron, manganese, and ammonium to below the limit of quantification. As a result, complete deferrization, demanganization, and removal of ammonium during the treatment process are verified. Compared to raw water, the phosphate concentration in drinking water drops to values below the limit of quantification. The most probable cause is that the phosphates are adsorbed during flocculation due to the surface complexation of the iron(III) hydroxide/hydrated oxide formed, and are then precipitated. The nitrate concentration increases from a value below the limit of quantification to 2.7 mg/L. The increase in nitrate concentration is caused by the oxidation of ammonium and polyacrylamide. Despite this, the nitrate concentration is much lower than the limit value of 50 mg/L. The measured values for the aluminum concentrations in the raw water are not known. The aluminum concentrations in drinking water are below the limit of quantification. This means that the aluminum in the polyaluminum chloride is completely converted into aluminum(III) hydroxide and precipitated. This does not affect the quality of the drinking water. The concentrations of sulfate, chloride, sodium, and potassium increase due to the addition of the appropriate chemicals ( Figure 3). The mean concentration of silicon drops from 7.9 to 7.7 mg/L. The average concentration of total organic carbon decreases from 9.7 mg/L in raw water to 5.1 mg/L in drinking water. This demonstrates good removal of humic substances from the water. Table 1. Mean values of the various parameters for raw water and drinking water at the Fuhrberg waterworks with the specified limit values in the Drinking Water Ordinance. The parameters shown in gray are not taken into account in the modeling. When comparing the measured raw water quality with the measured drinking water quality, the measured concentrations of the parameters in the drinking water comply with the strict limit values of the Drinking Water Ordinance, or are significantly below them. This indicates that the treatment at the Fuhrberg waterworks is being carried out successfully at present.

Modeling
Before the modeling, the relevant hydrogeochemical processes of all treatment stages should be presented. First, the path of the water through the treatment is shown. The path of the water begins after the raw water mixing tower, where the raw water from the various production wells is mixed. It ends in the intermediate drinking water tank. On the way, the raw water flows step by step through the treatment reactors-first into the aeration chamber, then into the accelerator, then into the gravel filter, and then-after the lime-carbonic acid balance has been established-into the intermediate tank. The water quality develops as a result of the hydrogeochemical processes taking place in the connected reactors. The material flow model is spatially divided by these reactors, but it is neither spatially nor temporally scaled. The water enters the aeration chamber first. In practice, iron removal occurs in the accelerator, while nitrification and demanganization take place in the gravel filter ( Figure 3). However, because the material flow model developed here is a thermodynamic equilibrium model that does not contain any kinetically described reactions, all of the corresponding phases react up to the state of equilibrium in each reactor. For this reason, iron, manganese, and ammonium dissolved in the raw water are already completely oxidized by the sufficient oxygen in the aeration chamber. Gas-exchange equilibria must be taken into account at all processing stages. The entire processing building is characterized as a closed system; thus, gas-exchange equilibria only occur between the water and air within the treatment building.  Based on this model, a material flow model based on chemical-thermodynamic laws was developed. The information and data presented above were organized, simplified, summarized, and then used as input files for modeling with the PHREEQC computer program. During the modeling, the wateq4f.dat database was used. If some of the related data are not available, corresponding assumptions should be made in the modeling.

First Model Construction Stage: Raw Water
Because the measured values of raw water and drinking water from the time period 2020 to 2021 are very similar, the measured values of raw water in February are shown here as an example.

•
Raw water input data: The raw water input data come from the specified chemical analyzes of the raw water sample. One liter (PHREEQC standard input) of water with a measured pH of 6.61 and a temperature of 9.5 °C contains oxygen (O2), anions of Cl − , PO4 3− , SiO4 4− , and SO4 2− ,  Based on this model, a material flow model based on chemical-thermodynamic laws was developed. The information and data presented above were organized, simplified, summarized, and then used as input files for modeling with the PHREEQC computer program. During the modeling, the wateq4f.dat database was used. If some of the related data are not available, corresponding assumptions should be made in the modeling.

First Model Construction Stage: Raw Water
Because the measured values of raw water and drinking water from the time period 2020 to 2021 are very similar, the measured values of raw water in February are shown here as an example.

•
Raw water input data: The raw water input data come from the specified chemical analyzes of the raw water sample. One liter (PHREEQC standard input) of water with a measured pH of 6.61 and a temperature of 9.5 • C contains oxygen (O 2 ), anions of Cl − , PO 4 3− , SiO 4 4− , and SO 4 2− , cations of NH 4 + , Na + , K + , Ca 2+ , Mg 2+ , Fe 2+ , and Mn 2+ , and TIC (total inorganic carbon).
• Titration of the acid and base capacity AC 4.3 /BC 8.2 of the raw water: The pH value of the raw water is around 6.6. In order to determine the buffer capacity of the raw water, the raw water is titrated in the laboratory using acid or base to the appropriate pH value based on the standard (DIN 38409-7 (H7) [29].  (1): The dissolved CO 2(aq) that is formed must be expelled with the air by stirring during the titration in order to establish equilibrium. This titration is therefore carried out in an open system according to the DIN 38409-7 (H7) standard [29].
This titration process is modeled in the open system with the computer program PHREEQC. The balance of CO 2 between the water and the air must be taken into account in the modeled titration. The applied CO 2 partial pressure is 10 −3.5 atmosphere, as specified in a general atmosphere. The calculated acid consumption is 1.905 mmol/L, which seems similar to the measured acid capacity from 1.9 mmol/L to pH 4.3. BC 8.2 is an approximate measure of the concentration of dissolved CO 2(aq) . The pH of the raw water is titrated from about 6.6 to 8.2 by adding sodium hydroxide (NaOH) solution. BC 8.2 can be determined from the base consumption. The titration mainly detects dissolved CO 2(aq) Equation (2): When determining BC 8.2 , contact of the raw water with the air should be avoided, since the base consumption can be falsified by the exchange of CO 2 with the atmosphere. This means that if the CO 2 concentration in equilibrium with the air falls below the pH value of 8.2 shortly before the pH value is reached, CO 2 can penetrate from the air into the water. This titration takes place in a closed system according to the DIN 38409-7 (H7) standard [29].
Because the system is closed, gas exchange can be neglected in the model. The BC 8.2 calculated by PHREEQC is 1.253 mmol/L, and is slightly larger than the measured BC 8.
The TIC concentration is calculated as follows: Based on the measured AC 4.3 of 1.9 mmol/L and BC 8.2 of 1.2 mmol/L for raw water, the TIC concentration for raw water is 3.05 mmol/L. AC 4.3 of 1.905 mmol/L and BC 8.2 of 1.253 mmol/L are calculated using PHREEQC. A corrected TIC concentration of 3.108 mmol/L is thus determined and used for further modeling.

Second Model Construction Stage: Ventilation Chamber
The raw water is first added to the aeration chamber. All relevant geochemical reactions to changes in water quality are taken into account in the model. They contain not only gas-exchange, but also solid-phase equilibria.

•
The adjustment of gas-exchange equilibria: First, the balances of O 2 and CO 2 between the water and air of the treatment building must be considered. Since the measured value of the O 2 content inside the treatment building is not available, an O 2 content of 21 vol.% (pO 2(g) = 10 −0.678 atm) is assumed to be used in PHREEQC. The CO 2 content of the soil air in the aquifer is higher than in the atmosphere; this leads to a high concentration of dissolved CO 2 (or TIC concentration) in the raw water. For this reason, it is assumed that the dissolved CO 2(aq) from the water is released into the air of the treatment building. However, no rising bubbles are observed in the water of the accelerator on site, and the CO 2 balance within the water is neglected in the modeling. As CO 2 has a higher density than O 2 , the enrichment processes of CO 2 content take place on the water surface. The onsite-measured CO 2 content in the air of the processing building is 0.13 vol.% (pCO 2(g) = 10 −2.9 atm). Measurements on the water surface cannot be carried out. One can only measure the CO 2 level about a meter above the water surface. Therefore, the measured value is necessarily smaller than the actual value. A larger partial pressure of 10 −2.7 atm is used in the model. Gas-exchange equilibria are modeled in the same way in all processing reactors (i.e., aeration chamber, accelerator, and gravel filter).

•
Iron removal, manganese removal, and nitrification: In the model, iron removal, manganese removal, and nitrification take place in the aeration chamber without taking the kinetics into account. Because there is no information on the resulting solid phases of iron, it is assumed that either amorphous iron hydroxide or goethite can be precipitated as a secondary solid phase at supersaturation. Therefore, one scenario for amorphous iron hydroxide and another for goethite is calculated in the model.
log_k → → −119.077 In the model, it is necessary to define all potential secondary phases in the model through the EQUILIBRIUM_PHASES function. In addition to some phases such as anhydrite, CH 4(g) , clinoenstatite, cristobalite, diopside, and dolomite (d) , which are by no means formed under the conditions of raw water treatment, the other phases in the database wateq4f.dat from PHREEQC are assumed to be potential secondary phases, which can be formed when the raw water quality changes. They are divided into five parts: secondary phases of calcium and magnesium should be considered due to lime-carbonic acid balance; secondary phases of iron and manganese (redox) should be taken into consideration; the iron phases hematite, maghemite, and magnetite are not formed for kinetic reasons, and are taken from the input file. To be able to precipitate birnessite (δ-MnO 2 ) as a secondary phase in the modeling, the manganese dioxide phase nsutite has to be taken from the input file; this means that it is not considered as a potential secondary phase. Secondary phases of aluminum, sodium, chloride, and potassium should be added due to the addition of the reactants; secondary phases of silicon should also be counted. The secondary silicon phases chalcedony, quartz, silica gel, and SiO 2(a) are not considered because they are not part of the model. The solid solution of carbonate phases also needs to be considered as a potential secondary phase. Most likely, the mixed crystal of calcite and magnesite originates from the composition of raw water. In the model, all components (calcite and magnesite) are defined by an ideal solid solution. Thus, the activity of the various components in the SOLID_SOLUTIONS function is neglected. The saturation index (=log k/log ion activity product) and the pool of all potential secondary phases in the dimension (mol) are given as zero.
Surface complexation is considered due to the formation of amorphous iron hydroxide (or goethite). The effects of the surface complexations of amorphous iron hydroxide and goethite are different. In the modeling, only the surface complexation of amorphous iron hydroxide is calculated using the SURFACE function. The PHREEQC database containing thermodynamic data for the SURFACE function, named "Hfo" (hydrous ferric oxide), was derived from the work of Dzombak and Morel [30]. Two types of adsorption sites are defined in the input data: weak adsorption sites (Hfo_wOH), and strong adsorption sites (Hfo_sOH). The specifications for the surface complexation of amorphous iron hydroxide are given in the PHREEQC manual.
The model has 0.1 mol Hfo_wOH and 0.001 mol Hfo_sOH per mol of Fe as effective sites with a surface area of 1 × e 5 m 2 /mol Fe [10]. The functions used-SOLUTION, SOLID_SOLUTIONS, EQUILIBRIUM_PHASES, and SURFACE-are saved for further use.

Third Model Construction Stage: Accelerator
The newly formed precipitates (amorphous iron hydroxide or goethite; birnessite) are sent with water from the aeration chamber to the downstream reactor "accelerator". For this reason, the saved SOLUTION 2, SOLID_SOLUTIONS 2, EQUILIBRIUM_PHASES 2, and SURFACE 2 functions continue to be used by the USE function.
The To perform the flocculation successfully, polyaluminum chloride is added to the water. PAC is made from aluminum hydrate, hydrochloric acid, and aluminum sulfate. Therefore, aluminum, chloride, and sulfate are present in certain ratios in the PAC products. In the Fuhrberg waterworks, the PAC product with the chemical formula Al(OH) 3 ·0.8 AlCl 3 ·0.1 Al 2 (SO 4 ) 3 has a molar mass of 219 g/mol. The amount of flocculant added in the Fuhrberg waterworks is 20-25 g/m 3 ( Figure 3); the mean value of 22 g/m 3 is used here. In the model, 0.1 mmol PAC is added to 1 L of water using the REACTION function.
The chemical formula of polyacrylamide is C 3 O 1 H 5 N 1 . In the model, n = 1 is assumed, and a molar mass of 71 g/mol of polyacrylamide is calculated. The prescribed dosage of polyacrylamide in the waterworks is from 0.4 to 0.5 g/m 3 ( Figure 3); the mean value of 0.45 g/m 3 is used here. In the model, 0.0063 mmol polyacrylamide is added to 1 L of water in the model using the REACTION function. It is assumed that the complete oxidation of the polyacrylamide can lead to an increase in the TIC and nitrate concentration in the water.
The change in the physical parameter temperature is also taken into account. The measured temperature of the raw water is 9.5 • C, while the temperature of the drinking water is 9.8 • C. The temperature increase of 0.3 • C is gradually entered at each processing stage by the REACTION_TEMPERATURE function.

Fourth Model Construction Stage: Gravel Filter
The resulting flakes (amorphous iron hydroxide or goethite; birnessite and gibbsite) are retained in the accelerator. Only the treated water is supplied to the next reactor "gravel filter" by the functions SAVE and USE.

•
Adjusting the pH value by dosing milk of lime and potassium permanganate: Calcite normally occurs with a low magnesium content of up to 4 mol% [31]. During the burning of lime, magnesium-containing calcite is decomposed into calcium oxide as well as magnesium oxide and CO 2 . The resulting calcium oxide and magnesium oxide are dissolved in the water to produce the milk of lime. Therefore, the ratio between calcium and magnesium in the milk of lime is equal to the ratio in the naturally occurring magnesium-containing calcite. Since there is no measured value for the ratio between calcium and magnesium, different ratios are assumed in the model. First, a milk of lime with 96 mol% calcium and 4 mol% magnesium is used. This results in a milk of lime formula of Ca 0.96 Mg 0.04 (OH) 2 with a molar mass of 73.4 g/mol. The amount of milk of lime dosed in the Fuhrberg waterworks is 30-33 g/m 3 ( Figure 3); a mean value of 31.5 g/m 3 is used in the model, and 0.43 mmol Ca 0.96 Mg 0.04 (OH) 2 is added to PHREEQC as input data.
The milk of lime with 98 mol% calcium and 2 mol% magnesium is also calculated as a different scenario. The result is evaluated in 0.15-0.2 g/m 3 of KMnO 4 (Figure 3) dosed into the water. The mean value 0.175 g/m 3 (0.0011 mmol/L) is used in the model.
The defined functions SOLID_SOLUTIONS, EQUILIBRIUM_PHASES, and SURFACE in the "ventilation chamber" model construction stage are adopted unchanged in the "gravel filter" model construction stage.

Fifth Model Construction Stage: Drinking Water in the Lime-Carbonic Acid Balance
The precipitation formed (birnessite) is retained in the gravel filter. Only the water is passed on from the gravel filter through the SAVE and USE functions.

•
Adjusting the lime carbonic acid balance by dosing caustic soda: The final treatment stage is the adjustment of the lime-carbonic acid balance by dosing NaOH. The dose of NaOH used in practice is 12-15 g/m 3 (Figure 3). The mean value 13 g/m 3 (0.325 mmol/L) is used in the model. So far, the modeling of the raw water treatment processes has been completed.

•
Titration of the acid and base capacity AC 4.3 /BC 8.2 of the modeled drinking water: The modeled drinking water is titrated with HCl and NaOH to compare the modeled AC 4.3 and the modeled BC 8.2 with the measured values of the drinking water. To titrate the pH value of the modeled drinking water up to 4.3, 2.185 mmol/L HCl is consumed. In order to increase the pH value of the modeled drinking water to 8.2, 0.097 mmol/L NaOH is used.

•
Titration of the acid and base capacity AC 4.3 /BC 8.2 of the measured drinking water: From the chemical analysis of the drinking water, the composition of the drinking water is constructed as input data. The used TIC concentration (C(+4)) in the in-put data is 2.23 mmol/L, which is calculated from the measured AC 4.3 of 2.2 mmol/L and BC 8.2 of 0.08 mmol/L. The corrected values of the measured AC 4.3 and the measured BC 8.2 can be determined by titration with HCl and titration with sodium hydroxide solution, respectively. The corrected AC 4.3 of 2.191 mmol/L is smaller than the measured AC 4.3 of 2.2 mmol/L, and the corrected BC 8.2 of 0.092 mmol/L is larger than the measured BC 8.2 of 0.08 mmol/L.

Comparison of the Modeled Parameters with the Measured Parameters
The difference (∆ = modeled value of the parameter − a measured value of the parameter) is compared to the process characteristic value. The concentrations of the parameters relevant to drinking water quality are intended to ensure that the specific process characteristics used in the analysis process are at least suitable. In the ordinance for the amendment of the Drinking Water Ordinance [28], a precision of 10% of the corresponding limit value is specified for the analysis method for all parameters relevant to drinking water quality (iron, manganese, chloride, etc.). In Table 2, 10% of the measured value for all parameters is assumed as the precision of the analysis method in the error analysis. On this basis, an assessment is made as to whether the modeled parameter agrees sufficiently with the measured parameter.

Lime-Carbonic Acid Balance-Relevant Parameters
A comparison of the modeled parameters belonging to the group lime-carbonic acid balance with the measured parameters is presented (Figure 4). The modeled pH values and AC 4.3 agree sufficiently with the measured values. The maximum deviation between the modeled and measured values of pH is −0.06, while the maximum deviation of AC 4.3 is 0.06 mmol/L. The deviations of both parameters are smaller than the corresponding precision of the analytical method for pH and AC 4.3 . For BC 8.2 , the deviation is between −0.01 and 0.02 mmol/L. The modeled BC 8.2 concentrations are in the middle range of the measured values over the entire period. For this reason, it is assumed that the modeled BC 8.2 agrees reasonably well with the measured values, although the maximum deviation is slightly greater than the corresponding precision. The modeled calcium concentrations are slightly lower than the measured values, with the highest difference of −0.13 mmol/L over the entire period. However, the difference is still smaller than the precision of the calcium concentration at 0.19 mmol/L. This means that the calculated calcium concentration agrees sufficiently with the measured value. In contrast, the calculated magnesium concentrations are slightly higher than the measured values, with a maximum deviation of 0.03 mmol/L. The maximum deviation slightly exceeds the precision of the analysis method for a magnesium concentration of 0.02 mmol/L. It is assumed, although the measured and modeled magnesium concentrations do not overlap optimally, that the modeled and measured sum of the alkaline earth metal concentrations (i.e., calcium and magnesium) agree sufficiently with one another.

Redox Parameters
Measured and modeled concentrations of iron, manganese, and phosphate, as well as ammonium, are below the analytical limit of quantification over the entire period ( Figure 5). The phosphate is treated as a redox parameter because it is precipitated due to surface complexation with formed amorphous ferric hydroxide. The modeled nitrate concentrations are in the middle range of the measured values for almost the entire period.

Reactants-Relevant Parameters
The measured aluminum concentrations as well as the modeled values of drinking water are always below the analytical limit ( Figure 6). The modeled sulfate concentrations are consistent with the measured values over the entire period because the deviations are no greater than 0.05 mmol/L, and are less than the precision of the analysis method for sulfate concentrations of 0.1 mmol/L. The modeled chloride and sodium concentrations are above the range of the measured values over the entire period. The difference is between 0.15 and 0.21 mmol/L for chloride concentration, and between 0.20 and 0.28 mmol/L for sodium concentration. This is significantly greater than the precision of the analysis method for a chloride concentration of 0.12 mmol/L and for a sodium concentration of 0.11 mmol/L. The modeled potassium concentrations agree with the measured values over the entire period.

Mass Balance
In Figure 7, the water flows from top to bottom in the connected reactors. The reactant on the left is added to the water. Gases and solids on the right are removed from the water as reaction products. In order to set up the mass balance in the modeling, the parameters TIC, calcium, magnesium, iron, phosphate, manganese, ammonium, sulfate, chloride, sodium, and potassium relevant to the water treatment process are used for calculations.  The concentration of the parameters in the downstream reactor (C) equals the concentration in incoming water (influent) from the upstream reactor plus the input from adding the reactant to the water, minus the output from the reaction product removed from the water: The mass balance of the TIC concentration is shown as an example (Figure 7). The TIC concentration in raw water is 3.109 mmol/L. In the aeration chamber, 1.652 mmol/L CO 2 is released from the water into the air. The remaining TIC concentration in the water corresponds to 1.457 mmol/L. Then, 0.0063 mmol/L polyacrylamide (C 3 O 1 H 5 N 1 ) is added to the water in the accelerator, and 0.322 mmol/L CO 2 is released. This makes the TIC concentration in the water 1.154 mmol/L. The modeled TIC concentration in the accelerator is 1.155 mmol/L. The small difference between them is the rounding error, and is neglected. Then, 0.854 mmol/L of CO 2 is dissolved in the water of the gravel filter, causing the TIC concentration in the water in the gravel filter to rise to 2.009 mmol/L, which is 0.001 mmol/L higher than the calculated value of 2.008 mmol/L for the TIC concentration in the water in the gravel filter. After adding 0.269 mmol/L CO 2 and precipitating 0.053 mmol/L calcite and 0.001 mmol/L magnesite, the TIC concentration of 2.223 mmol/L in the drinking water can be calculated.
The current status of the water treatment processing can be seen from the mass balance. This means that it is determined which mass flows are added to the water (e.g., NaOH) and which mass flows are removed from the water (e.g., amorphous iron hydroxide or goethite). The modeled amount of formed solids is a total of 717 tons per year (t/a), including 363 t/a Fe(OH) 3(a) , 23 t/a δ-MnO 2 , 23 t/a Al(OH) 3 , and 23 t/a Ca(x)Mg(1−x)CO 3 . The released CO 2 is 590 t/a. All of these modeled values use the average value of the peak output of 43,200 m 3 /day in the Fuhrberg waterworks.

Superiority of the Hydrogeochemical Model for the Water Treatment
By comparing the modeled results with the measured values, it can be proven that, except for chloride and sodium, all other relevant modeled and measured parameters for drinking water quality are sufficiently consistent with one another. The mass balance also confirms that the measured parameters correspond with the modeled values ( Figure 7). The model is thus marked as plausible, and can be used as a tool to optimize the treatment measures if the raw water conditions change in the future. The water treatment measures at the Fuhrberg waterworks are conventional-the same as applied by most of the waterworks in the world. Although the hydrogeochemical model is constituted based on the data from the Fuhrberg waterworks, with minor modification of the PHREEQC input file-such as the added amount of reactants-the model can also be used in waterworks with similar chemical composition of their raw water and similar water treatment processes.

Further Development Possibilities of the Model
The trace elements arsenic and uranium, which are released from the oxidation of pyrite in groundwater aquifers, are treated worldwide as problematic water constituents [25,[32][33][34]. Under special conditions, the concentrations of arsenic and uranium in groundwater can be greatly increased and become a threat to human health. In order to further develop the model, the behavior of uranium and arsenic in modeled raw water treatment should be taken into account.
Furthermore, kinetic aspects should be considered and integrated into the model. Microflora and isotopic composition can also influence the process; these parameters should be taken into account as further development possibilities for the model. This allows the actual treatment processes to be better understood. If the chemical data analyzed in the intermediate stages of raw water treatment are also known, the modeled parameters can be compared with the measured values after each treatment stage. This further confirms the plausibility of the model and improves the validity of the model.

Limitation of this Work
The modeled chloride and sodium concentrations are higher than the corresponding measured values. The probable reason for this is that other substances are mixed into the polyaluminum chloride. This reduces the proportion of aluminum chloride in the mixture. The information about the amount of polyaluminum chloride used from the waterworks (20-25 g/m 3 ) is for the mixture of polyaluminum chloride with other additional substances, but not for pure polyaluminum chloride. When developing the model, the amount of polyaluminum chloride added to the water can be reduced. The reason for the excessively high modeled sodium concentration is not yet known. In reality, diluted NaOH is normally used. It may be that the information about the dosage of NaOH from the waterworks (12-15 g/m 3 ) is for diluted NaOH, and not for pure NaOH. Therefore, the concentration of NaOH in one liter of water should be reduced in the modeling.

Conclusions
The object of study of this work is the quality of "water for human consumption" (drinking water). This depends on both the raw water quality and the treatment measures. Since the raw water quality develops over time, it must be determined whether the treatment measures currently used are also suitable if the raw water quality changes. For this reason, it is necessary to investigate the hydrogeochemical processes relevant to the drinking water quality during the purification of the raw water into drinking water.
In the case of the Fuhrberg waterworks, the water flows out of the raw water mixing tower and then flows step by step through the reactors used for the treatment-first into the aeration chamber, then into the accelerator and the gravel filter, and then-after the setting of the lime-carbonic acid balance-into the intermediate tank. All hydrogeochemical processes that take place in the respective reactor are identified and quantified. These include, among other things, the adjustment of the gas-exchange balance between the air (O 2 and CO 2 partial pressure), iron removal, manganese removal, and nitrification by oxidation with atmospheric O 2 ; flocculation by dosing H 2 O 2 , flocculants, and flocculation aids; adjusting the pH value by dosing milk of lime and KMnO 4 ; and the setting of the lime-carbonic acid balance by dosing NaOH in front of the intermediate tank. This treatment process can be quantitatively and qualitatively reproduced using chemical-thermodynamic modeling with the computer program PHREEQC.
From the data and information for drinking water from the Fuhrberg waterworks, the target function of the model can be presented with a time resolution. The target function represents the parameters that are relevant to the drinking water quality and are interdependent (i.e., physical parameters, lime-carbonic acid balance, redox, reactants), along with their measured values. The chemical composition of the drinking water calculated with PHREEQC is compared with the measured values. This proves that, apart from chloride and sodium, all other relevant modeled and measured parameters for the drinking water quality agree sufficiently with one another. The model is thus marked as plausible, and can be used as a tool to optimize the treatment measures if the raw water conditions change in the future.
Author Contributions: R.Y. and F.X. contributed to all aspects of this work. R.Y. and J.Z. conducted data analysis and modeling. R.Y. and F.X. wrote the main manuscript text. A.C. gave some useful suggestions for this work. All authors have read and agreed to the published version of the manuscript.