## Materials and Methods
### Disinfection Strategy  
Under normal operation, the water previously treated in the different processes of organic matter elimination enters the disinfection phase by combining the diluted chlorine gas and the water to be treated in two large tanks. The retention time required for disinfection is a delay time that makes feedback control a difficult task. The disinfection strategy is based on covering the basic demand of chlorine in the first tank, that is, the needs for chlorine demand are met as a result of the consumption of certain existing organic and inorganic matter. Then, in the second tank, the necessary chlorine is added, that is, free chlorine, to cover losses (by chemical reactions, not leakages) by its transportation. In the same way, the added chlorine needs to reach a certain level to comply with the legal regulations in the effluent (see references above for regulations), with a maximum value of 1.0 mg/L for a good taste and a minimum of 0.2 mg/L to ensure the death of pathogens, bacteria, and viruses. Currently the concentration values required at the exit of the DWTP are usually between 0.8 and 1.2 mg/L of free chlorine.  
As shown in Figure 4, the dosing stages to be carried out in the first tank (tank 1) would be between zones 1 and 3. The water to be treated would come into contact with the chlorine in the first tank (zone 1) to react quickly with inorganic matter such as Fe\({}^{++}\), Mn\({}^{++}\), H\({}_{2}\)S, or organic matter. Once the initial demand for chlorine has been satisfied as dosing continues, the creation of monochloroamines, dichloroamines, and trichloroamines (zone 2) begins due to the combination of free chlorine with ammonium or its derivatives. In drinking water, monochloroamines are deliberately formed by the reaction of chlorine in an aqueous solution with the added ammonium ion or non-dissociated ammonia in water [12]. In zone 2, total chlorine is a combination of free chlorine and its different organic compounds, and its disinfection effectiveness is limited when total chlorine is only formed by free chlorine. If the dosage continues increasing (zone 3) when all the nitrogen-derived species have oxidized, the reaction reaches a breakpoint of special importance in the chlorination process because beyond this breakpoint the entire dosage will be fully effective in terms of disinfection.  
From the beginning of zone 4, all the dosed chlorine becomes residual free chlorine, becoming the ideal point of entry to the tank 2. Specifically, the disinfection strategy that is followed in the DWTP is to raise the outlet from tank 1 to 0.2 ppm to ensure that tank 2 operates only with free chlorine.  
\begin{table}
\begin{tabular}{c c c c} \hline \hline
**Parameter (Unities)** & **Llobregat River Intake** & **Mixing Chamber \({}^{*}\)** & **Chlorination Tank Outlet \({}^{**}\)** \\ \hline Turbidity (NTU) & 100 & 0.2 & 0.2 \\ Ammonium & 0.25 & 0.02 & 0 \\ concentration (ppm) & 0 & 2 *** & 1.2 \\ DH (0–14) & 7.8 & 7.3 & 7.3 \\ Temperature (\({}^{\circ}\)C) & 20 & 20 & 20 \\ Conductivity (\(\mu\)S/cm) & 1200 & 900 & 900 \\ \hline \hline \end{tabular}  
* Chlorination tank inlet; ** to distribution network; *** this value is due to dosage at the mixing chamber.  
\end{table}
Table 1: Parameters of water at different sampling points in the DWTP.