# How Heat Transfer Indirectly Affects Performance of Algae-Bacteria Raceways

Francesca Casagli, Olivier Bernard

► To cite this version:

Francesca Casagli, Olivier Bernard. How Heat Transfer Indirectly Affects Performance of Algae-Bacteria Raceways. Microorganisms, 2022, 10 (8), pp.1515. 10.3390/microorganisms10081515. hal-03771361

HAL Id: hal-03771361

https://inria.hal.science/hal-03771361v1

Submitted on 8 Sep 2022

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons CC BY 4.0 - Attribution - International License
<figure><img src="image_2.png" /></figure>

Article

# How Heat Transfer Indirectly Affects Performance of Algae-Bacteria Raceways

Francesca Casagli <fnref n="1" />,<fnref n="2" />,* and Olivier Bernard <fnref n="1" />,<fnref n="2" />●

**Abstract:** Oxygenation in wastewater treatment leads to a high energy demand. High-rate algal-bacterial ponds (HRABP) have often been considered an interesting solution to reduce this energy cost, as the oxygen is provided by microalgae during photosynthesis. These complex dynamic processes are subject to solar fluxes and consequently permanent fluctuations in light and temperature. The process efficiency therefore highly depends on the location and the period of the year. In addition, the temperature response can be strongly affected by the process configuration (set-up, water depth). Raised pilot-scale raceways are typically used in experimental campaigns, while raceways lying on the ground are the standard reactor configuration for industrial-scale applications. It is therefore important to assess what the consequences are for the temperature patterns of the different reactor configurations and the water levels. The long-term validated algae-bacteria (ALBA) model was used to represent algae-bacteria dynamics in HRABPs. The model was previously validated over 600 days of outdoor measurements, at two different locations and for the four seasons. However, the first version of the model, like all the existing algae-bacteria models, was not fully predictive, since, to be run, it required the measurement of water temperature. The ALBA model was therefore updated, coupling it with a physical model that predicts the temperature evolution in the HRABP. A heat transfer model was developed, and it was able to accurately predict the temperature during the year (with a standard error of 1.5 °C). The full predictive model, using the temperature predictions, degraded the model's predictive performances by less than 3%. N₂O predictions were affected by ±7%, highlighting the sensitivity of nitrification to temperature. The temperature response for two different process configurations were then compared. The biological process can be subjected to different temperature dynamics, with more extreme temperature events when the raceway does not lie on the ground and for thinner depths. Such a situation is more likely to lead to culture crashes.

**Keywords:** microalgae; bacteria; modelling; wastewater treatment; liquid depth; temperature

## 1. Introduction

In the last decades, microalgae have appeared as a new promising biological resource and received much attention. The market for valuable products derived from microalgae is growing rapidly [1], with applications in fish farming, bio-plastics, the food industry, and cosmetics [2]. Biomass production is mainly carried out in open raceways [3]. These outdoor paddle-wheel-agitated tanks are cheap production systems, and there has been an intense ongoing debate as to whether their actual productivity compared to closed photobioreactors is significantly lower [4]. Microalgae cultivated in raceways in association with bacteria are also considered as an interesting solution to reduce the energy demand for oxygenation in wastewater treatment, since oxygen can be provided by the microalgae during photosynthesis.

<figure><img src="image_3.png" /></figure>

### check for updates

**Citation:** Casagli, F.; Bernard, O. How Heat Transfer Indirectly Affects Performance of Algae-Bacteria Raceways. *Microorganisms* **2022**, *10*, 1515. https://doi.org/10.3390/microorganisms10081515

Academic Editors: Birgitte K. Ahring and Mette Lubeck

Received: 11 May 2022

Accepted: 18 July 2022

Published: 26 July 2022

**Publisher's Note:** MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

<figure><img src="image_4.png" /></figure>

**Copyright:** © 2022 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).

<footnote n="1">¹ Biocore, Inria Centre at Université Côte d'Azur, INRAE, 2004 Route des Lucioles, 06902 Sophia-Antipolis, France; olivier.bernard@inria.fr</footnote>

<footnote n="2">² LOV (Laboratoire d'Océanographie de Villefranche), Sorbonne Université, CNRS UMR 7093, 181 Chem. du Lazaret, 06230 Villefranche-sur-Mer, France</footnote>

<footnote>* Correspondence: francesca.casagli@inria.fr</footnote>
The performance of these systems is first determined by the amount of photons received by the microalgae, which triggers the photosynthetic reactions. Temperature is the second factor affecting the growth rate of microalgae [5], and it has received much less attention. In fact, temperature strongly affects system performance, especially in outdoor systems, where it is subject to large fluctuations both during the day and seasonally. Predicting the productivity that a raceway can achieve at a given location and for a certain period of the year is becoming a key issue for retrofitting current wastewater treatment plants, and for including microalgae in the process. For this, on top of a biological model, a model predicting the water temperature is necessary.

It turns out that the process configuration (set-up, water depth) can strongly drive the temperature response. Since many studies at pilot scale consider raised raceways, the question that we target is how far will an up-scaled process made of concrete raceways lying on the ground differ from this behaviour due to a different temperature pattern.

Several models were developed to represent the dynamics of algal-bacterial processes, in particular in the field of wastewater treatment using high-rate algal-bacterial ponds (HRABP) [6–11]. Among these models, the originality of the ALBA model [10,12] is that it relies on an unprecedented validation of more than 623 days, carried out under outdoor conditions at two different locations and for the four seasons. However, until now, none of these HRABP models were fully predictive, as they require knowledge of the water temperature (or of the temperature below the raceway).

The first objective of this work is to propose a heat transfer model to represent the temperature evolution in one of the outdoor pilot raceways used for validating the ALBA model. This pilot scale experimental raceway (3.8 m²), located in northern Italy, was used to process digestate, and six months of records were used to validate the biological model. The raceway was typical of pilot set-ups for investigating and assessing the process performances in realistic conditions.

Several heat transfer models have been proposed for algal raceways. The most popular one was developed by Béchet et al. [13,14]. A simplified model was proposed by Slegers et al. [15]. A combination of these two approaches was then used in Rodríguez-Miranda et al. [16] for a raceway pond. In this paper, we are focusing on a different configuration, where the raceway is not directly in contact with the ground. For this specific configuration, there is no heat transfer model available.

The heat transfer temperature model that we propose was modified from the work of Béchet et al. [13], by adapting it to the specific material and configuration of the reactor. In particular, the temperature dynamics for the raceway material were added, including the exchange with the liquid medium and the environment. This fully predictive version of the ALBA model is therefore able to predict the temperature and the variable volume of the raceway, as well as the dynamics of the process, including microalgae, heterotrophic bacteria, and nitrifying bacteria.

It is important to stress that there are many pilot-scale raceways that are not in direct contact with the ground; thus, their thermal inertia and the associated temperature dynamics differ from the ones at industrial scale. In fact, different reactor configurations are subjected to different heat-transfer contributions and balances, resulting in a different temperature inside the reactor. For instance, when the raceway is lying on the ground, the conduction from the ground mitigates its temperature, while when the reactor is raised up from the ground, the radiation from the ground heats the pond bottom.

With this new fully predictive model version, it became possible to compare the performances of a raised raceway with those of an industrial configuration, where the raceway is made of concrete and lies on the ground. Different water depths were also tested, and they corresponded to different levels of thermal inertia. Algae productivity, nutrient removal rates, and the amount of water lost by evaporation were assessed for these conditions. We show and quantify how the specific reactor design leads to different temperature dynamics, focusing on the extreme temperature values that can be reached in
each configuration, especially in the warmest seasons, given their potential strong impact
on the biological activity.

## 2. Materials and Methods

The HRABP was a pilot-scale polypropylene tank with an operating volume of 0.88 m³ and a total surface of approximately 3.8 m² (see Figure 1). It was installed in the dedicated treatment plant of an intensive piggery farm, located in the north of Italy (Casaletto di Sopra, Cremona, Italy). The monitoring campaign was performed from May to December 2016. The HRABP had two main channels and semi-circular edges. The influent was prepared from the liquid fraction of the digestate from the biogas plant, and by dilution with tap water in order to reduce the influent TAN (total ammoniacal nitrogen) concentration. The influent characteristics were checked once per week, measuring the total suspended solids (TSS), the organic matter (COD total and soluble), phosphates (P – PO₄³⁻), total ammoniacal nitrogen (TAN), total Kjeldahl nitrogen (TKN), and nitrate (NO₃⁻). The effluent characteristics and therefore the reactor remediation efficiency were quantified by measuring: (i) once per week, the total (TSS) and volatile (VSS) suspended solids and the optical density at 680 nm; and (ii) twice per week with spectrophotometric test kits, the total and soluble organic matter (CODT and CODS, respectively), the phosphates (P – PO₄³⁻), and the inorganic nitrogen content (NH₄⁺, NO₂⁻ and NO₃⁻). The HRABP was equipped with pH, temperature, and dissolved oxygen concentration probes. The reactor was also equipped with a contact cylinder (height 0.8 m, diameter 0.44 m, volume 0.12 m³) for bubbling pure CO₂ gas to regulate pH at 7.5. The open pond mixing was ensured by a paddle wheel, which was operated at 20 rpm to obtain an average liquid velocity of 0.2 m s⁻¹. The outflow was from a gravity overflow, setting a maximum liquid depth of 0.2 m and resulting in a variable volume according to the evaporation and rain contribution. An average hydraulic retention time (HRT) of 10 days was set until 11 October 2016; then, the HRT was set to 20 days.

<figure><img src="image_5.png" /><figcaption>**Figure 1.** Pilot-scale HRABP located in a piggery farm in the north of Italy (Casaletto di Sopra, Cremona, Italy).</figcaption></figure>

Increasing the HRT is a typical operational strategy applied in outdoor bio-processes for wastewater remediation, to compensate for the lower temperature reducing microbial growth rates (typically in the coldest seasons, autumn and winter). This adaptation is necessary to match the limitations imposed by the national normative standards concerning nutrient discharge in water bodies. More details about the experimental campaign and the influent characteristics can be found in Casagli et al. [12], in Pizzera et al. [17], and in Supporting Information (SI.8).
Methodology for Computing the System Key Performance Indicators

In order to assess the HRABP performances according to the two reactor configurations and the different liquid depths, the algal biomass productivity (ALG<sub>prod</sub>), the total ammoniacal nitrogen removal rate (TAN<sub>RR</sub>), and the nitrogen-to-algae yield (ALG<sub>N,yield</sub>) were used as key performance indicators and computed as follows:

$$ALG_{prod} = \frac{X_{ALG} \cdot Q_{out} \cdot \phi}{S} \qquad (1)$$

$$TAN_{RR} = \frac{Q_{in} \cdot TAN_{in} - Q_{out} \cdot TAN_{out}}{S} \qquad (2)$$

$$ALG_{N,yield} = \frac{ALG_{prod}}{Q_{in} \cdot TAN_{in}} \qquad (3)$$

where X<sub>ALG</sub> is the algae concentration in the reactor (gCOD m<sup>-3</sup>); S is the reactor surface (m<sup>-2</sup>); φ is the conversion factor from COD to algal dry weight (0.64 gDW gCOD<sup>-1</sup>); TAN<sub>in</sub> and TAN<sub>out</sub> are the ammoniacal nitrogen concentration entering and leaving the system, respectively (gN m<sup>-3</sup>); and Q<sub>in</sub> and Q<sub>out</sub> are the inflow and outflow rate, respectively (m<sup>3</sup> d<sup>-1</sup>).

### 3. Modelling Approach

#### 3.1. The ALBA Model: Brief Recall of the Core Structure

##### 3.1.1. General Overview

The biological ALBA model considers a mixed culture of algae (X<sub>ALG</sub>), heterotrophic bacteria (X<sub>H</sub>), ammonium oxidizing bacteria (X<sub>AOB</sub>), and nitrite oxidizing bacteria (X<sub>NOB</sub>).

The model includes 19 biological processes and involves 17 state variables. The general model structure follows the general mass balance structure [18]:

$$\dot{\xi} = K \cdot \rho(\xi) - \Delta_g(\xi) + \frac{Q_{in}}{V} \cdot \xi_{in} - \frac{Q_{out}}{V} \cdot \xi \qquad (4)$$

where Q<sub>out</sub> = Q<sub>in</sub> + Q<sub>rain</sub> - Q<sub>evap</sub>. ξ is the state variable vector (g m<sup>-3</sup>); ξ<sub>in</sub> is the vector of influent concentrations (g m<sup>-3</sup>); ρ(ξ) is the vector containing the reaction rates (g m<sup>-3</sup>d<sup>-1</sup>); Q<sub>in</sub>, Q<sub>rain</sub>, and Q<sub>evap</sub> are the inflow rate, rain rate, and evaporation rate, respectively (m<sup>3</sup> d<sup>-1</sup>); K is the stoichiometric matrix (the transpose of the Peterson matrix); and V is the liquid volume (m<sup>3</sup>). The flux of gases dissolving or stripping from the liquid medium is denoted as Δ<sub>g</sub>(ξ) (g m<sup>-3</sup> d<sup>-1</sup>).

Hereafter, we recall the main structure of the ALBA model, but we refer the reader to the work of Casagli et al. [10,12] for more details.

##### 3.1.2. General Kinetic Model

The biokinetic rates are based on Liebig's minimum law [19] for limiting substrates (carbon, nitrogen, and phosphorus), meaning that the most limiting nutrient drives the overall kinetics. The general expression describing the structure of the bioprocesses' rates is given by:

$$\rho_j = \mu_{max_j} \cdot f_T \cdot f_{pH} \cdot f_I \cdot \frac{K_n}{K_n + S_n} \cdot \min_i \left( \frac{S_i}{S_i + K_{S_i}} \right) \cdot X_{BM_i} \qquad (5)$$

where X<sub>BM,i</sub> is the biomass associated to the process ρ<sub>j</sub>. The associated maximum specific growth rate is μ<sub>max_j</sub> (d<sup>-1</sup>); f<sub>pH</sub> and f<sub>I</sub> are the functions describing pH and light dependence, respectively. The function f<sub>T</sub> represents the effect of temperature (T<sub>p</sub> being the pond temperature). The inhibition constant for the inhibiting substrate S<sub>n</sub> is K<sub>n</sub>, and K<sub>S_i</sub> is the half-saturation constant for the limiting substrate S<sub>i</sub>.
### 3.1.3. Light Impact

Light is a crucial factor for algal growth, driving a large fraction of the energy and carbon fluxes in the system. The photosynthesis response to irradiance at depth z accounts for the photoinhibition phenomena at high irradiance with the Haldane-type function [20]:

$$f_{opt}(I(z)) = \frac{I(z)}{I(z) + \frac{\mu_{max}}{\alpha} \left( \frac{I(z)}{I_{opt}} - 1 \right)^2} \qquad (6)$$

Light extinction is described by the Lambert–Beer equation:

$$I(I_0, z) = I_0 e^{-\epsilon X_{ALG} z} \qquad (7)$$

Finally, the average growth rate for a given incident light and liquid depth is obtained, integrating the growth rate along the depth:

$$f_I(I_0, h) = \frac{1}{h} \int_0^h f_{opt}(I(I_0, z)) dz \qquad (8)$$

### 3.1.4. Temperature Impact

The temperature $T_p$ in the HRABP is generally not controlled, so it fluctuates within large ranges, driven by the solar heat flux, according to daily and seasonal dynamics. In the full predictive model, temperature is computed with a dedicated model as explained in the next paragraph.

The temperature dependence for algae and bacteria growth is modeled through the cardinal temperature model with inflection (CTMI), which requires three parameters, that is, the cardinal temperatures: $T_{max}$, $T_{min}$, and $T_{opt}$ [21]. The CTMI is zero for $T_p \notin [T_{min}, T_{max}]$, where $T_{min}$ is the temperature below which no growth occurs and $T_{max}$ is the maximum temperature above which no growth occurs. $T_{opt}$ is the temperature at which the growth rate is maximum. For $T_p \in [T_{min}, T_{max}]$, the temperature effect is given by the function $f_{T_p}^1$:

$$f_{T_p}^1 = \frac{(T_p - T_{max}) \cdot (T_p - T_{min})^2}{(T_{opt} - T_{min}) \cdot \Phi(T_p)} \qquad (9)$$

where $\Phi(T_p) = (T_{opt} - T_{min}) \cdot (T_p - T_{opt}) - (T_{opt} - T_{max}) \cdot (T_{opt} + T_{min} - 2T_p)$.

The Arrhenius function was chosen for the decay rates:

$$f_T^2 = \theta^{T_p - 20} \qquad (10)$$

where the parameter $\theta$ describes the decay rate change with temperature.

### 3.1.5. pH Impact

The pH strongly influences system dynamics, since it directly affects the dissociation of the majority of soluble compounds ($S_{IC}$, $S_{NH}$, $S_{NO_2}$, $S_{NO_3}$, $S_{PO_4}$). The influence of pH on algae and bacteria bio-process rates is included through the function proposed by Rosso et al. [21], that is, the cardinal pH model (CPM). The CPM is zero for pH $\notin (pH_{min}, pH_{max})$, where $pH_{min}$ and $pH_{max}$ are the minimum and the maximum pH thresholds, respectively. $pH_{opt}$ is the pH value at which the growth rate is maximum. For pH $\in (pH_{min}, pH_{max})$, the pH effect is described by $f_{pH}$:

$$f_{pH} = \frac{(pH - pH_{max}) \cdot (pH - pH_{min})}{(pH - pH_{min}) \cdot (pH - pH_{max}) - (pH - pH_{opt})^2} \qquad (11)$$

The pH is estimated by the model, resulting from the dynamical balance between the chemical, physical, and biological process interactions, as explained later on.
### 3.1.6. Model Validation with Measured Medium Temperature

The model prediction capability was assessed on two case studies. A 56 m² HRABP located in the south of France, with 1.5 year monitoring of pH, SO₂, SNH, SNO₃, SNO₂, XALG, TSS, and soluble COD, was used to calibrate the model [10].

It was then successfully validated [12] on the case study presented in Section 2, where measured temperature was taken as input. Here, the objective is to predict temperature and to assess the prediction accuracy of the model coupling thermal and biological representations.

### 3.2. Predicting Pond Temperature and Water Level

The universal temperature model for shallow ponds developed by Béchet et al. [13] was adapted to predict the water temperature and the water level of the raceway. The existing radiative transfer model was modified, to deal with the fact that this raceway was suspended above the ground. A heat balance of the raceway material was thus also considered, involving additional heat fluxes (see Figure 2).

<figure><img src="image_6.png" /><figcaption>Figure 2. Heat fluxes considered in the radiative transfer model.</figcaption></figure>

The temperature dynamics in the algal pond results from the following heat balance:

$$ \rho_w V C_{p,w} \frac{dT_p}{dt} = Q_{ra,p} + Q_{ra,s} + Q_{ra,a} + Q_{h,evap} + Q_{conv} + Q_{h,in} + Q_{h,out} + Q_{h,rain} - Q_{conv,cond_w,pp} \quad (12) $$

where Tp is the pond temperature (K); ρw is the density of pond water (kg m⁻³); Cp,w is the specific heat capacity of the pond water (J kg⁻¹ K⁻¹); and V is the pond volume (m³). Qra,p is the radiation from the pond surface (W); Qra,s is the total (direct + diffuse) solar radiation (W); and Qra,a is the radiation from the air of the pond (W). Qh,evap is the evaporation flux (W), Qconv is the convective flux at the pond surface (W); Qh,in is the heat flux associated with the influent water (W); Qh,out is the heat flux associated to the effluent water (W); and Qh,rain is the heat flux related to rain (W).

The additional term, compared to the original model [13], is Qconv,cond_w,pp, the conductive/convective expressions related to the heat exchange between the water in the pond and the material of the HRABP (here, polypropylene (pp)):

$$ Q_{conv,cond_w,pp} = h_{w,pp} \cdot (T_p - T_{pp}) \cdot S \quad (13) $$

where S is the pond surface (m²).
The parameter $h_{w,pp}$ (W m$^{-2}$ K$^{-1}$) is the heat transfer coefficient between the water in the pond (w) and the polypropylene, while $T_{pp}$ (K) is the temperature of the polypropylene.

The HRABP was raised from the ground, as shown in Figure 1. A heat balance on the polypropylene mass of the pond is therefore also carried out:

$$ \rho_{pp} V_{pp} C_{p,pp} \frac{dT_{pp}}{dt} = Q_{conv,cond_w,pp} + Q_{conv,cond_a,pp} + Q_{ra,pp} + Q_{ra,a,pp} + Q_{rad,g} \quad (14) $$

where $Q_{ra,pp}$ is the pond radiation at the bottom of the reactor:

$$ Q_{ra,pp} = -\epsilon_{pp} \cdot \sigma \cdot T_{pp}^4 \cdot S \quad (15) $$

and $Q_{ra,a,pp}$ is the expression describing the air radiation at the bottom of the pond ($T_a$ (K) is the air temperature), on the polypropylene surface:

$$ Q_{ra,a,pp} = \epsilon_{pp} \cdot \epsilon_a \cdot \sigma \cdot T_a^4 \cdot S \quad (16) $$

The conductive/convective flux between air and the material of the pond is $Q_{conv,cond_a,pp}$:

$$ Q_{conv,cond_a,pp} = h_{a,pp} \cdot (T_a - T_{pp}) \cdot S \quad (17) $$

The parameter $h_{a,pp}$ (W m$^{-2}$ K$^{-1}$) is the heat transfer coefficient between the air (a). Finally, $Q_{rad,g}$ is the radiation from the ground to the pond bottom:

$$ Q_{rad,g} = \epsilon_{ground} \cdot \sigma \cdot T_g^4 \cdot S \quad (18) $$

The temperature of the ground was computed from the air temperature, according to the work of Tsilingiridis et al. [22]:

$$ T_g = 1.197 \cdot T_a - 0.7776; \quad (19) $$

The parameters $\epsilon_{ground}$, $\epsilon_{pp}$, and $\epsilon_a$ are the emissivity of the ground, polypropylene, and air, respectively (-); $\sigma$ is the Stefan-Boltzmann constant (W m$^{-2}$K$^{-4}$).

The evaporative and convective heat flux in the liquid medium have a marked effect on the pond temperature prediction, and they were implemented according to the Buckingham theorem, depending on the dimensionless numbers of Sherwood, Schmidt, and Reynolds. The Sherwood and Nusselt numbers were linearly interpolated for Reynolds numbers between 3 × 10$^5$ and 5 × 10$^5$ to ensure model calculations for Reynolds numbers in the transition from laminar to turbulent flow. For the calculation of the evaporative heat flux, a minimum wind speed (4 m s$^{-1}$) was considered, as the equation for evaporative heat flux does not account for evaporation when there is no wind.

### 3.3. Exchanges with the Atmosphere

The CO$_2$, O$_2$ stripping/dissolution and NH$_3$ stripping are also included, quantifying their rates through the $k_L a$ and their diffusion coefficients:

$$ Q_j = k_L a_j \cdot \left( \frac{D_{S_j}}{D_{S_{O_2}}} \right)^2 \cdot (S_{j,sat}(T_p) - S_j) \quad (20) $$

From the evaporation and rain heat fluxes, it is possible to evaluate the water level variation in the pond:

$$ \frac{dh_L}{dt} = -\frac{m_e}{\rho_w} + q_r + \frac{q_i}{S} - \frac{Q_{out}}{S} \quad (21) $$

where $m_e$ is the evaporation rate (Kg s$^{-1}$ m$^{-2}$); $\rho_w$ is the water density (Kg m$^{-3}$); $q_r$ is the rain rate (m$^3$ m$^{-2}$ s$^{-1}$); and $q_i$ is the inflow rate (m$^3$ s$^{-1}$).
### 3.4. Chemical Submodel

The chemical submodel consists of predicting pH ($(H^+)$) ions concentration), but also computing the fraction of the different dissociated compounds that are in equilibrium, depending on the pH. In Appendix B, we recall the principle of the implementation to highlight the temperature dependence of this sub-model, by detailing the set of algebraic equations to be solved.

The strategy for resolving the pH subsystem was inspired by the work of Rosén et al. [23]. The idea is to transform the initial problem of resolution of a set of algebraic equations resulting from mass balance and chemical dissociation into the solution of a differential system (see Appendix B).

## 4. Results and Discussion

### 4.1. Validating the Temperature Model

The heat transfer model was simulated using the nearby meteorological data provided by ARPA Lombardia regional meteo database. The temperature predictions are accurate, as can be seen in Figure 3 and in Table 1. The model tends to slightly overestimate the temperature in the warmest periods and to underestimate it in the coldest ones. The temperature predictions stay precise, with an error standard deviation of 1.6 °C, computed on the difference between the measured and the simulated temperature vectors, and a *p*-value below $10^{-6}$.

<table><caption>**Table 1.** Comparison between simulated variables using temperature measurement and predictions from the full predictive model. (*): for temperature, the comparison is between the measured and simulated temperatures.</caption><thead><tr><th>State Variable</th><th>Err.St.Dev. (av)</th><th>Abs.Rel.Err. (av %)</th><th>Coeff.Var. (-)</th><th>R<sup>2</sup> (-)</th></tr></thead><tbody><tr><td>S<sub>NH</sub></td><td>0.9165</td><td>3.0531</td><td>0.0170</td><td>0.9994</td></tr><tr><td>S<sub>NO<sub>2</sub></sub></td><td>1.7102</td><td>7.7069</td><td>0.1004</td><td>0.9982</td></tr><tr><td>S<sub>NO<sub>3</sub></sub></td><td>1.8548</td><td>1.6769</td><td>0.0087</td><td>0.9997</td></tr><tr><td>X<sub>ALG</sub></td><td>14.6689</td><td>2.5129</td><td>0.0291</td><td>0.9940</td></tr><tr><td>T<sub>SS</sub></td><td>10.3061</td><td>1.7773</td><td>0.0228</td><td>0.9952</td></tr><tr><td>CODs</td><td>0.6988</td><td>0.3022</td><td>0.0023</td><td>0.9998</td></tr><tr><td>S<sub>O<sub>2</sub></sub></td><td>0.4511</td><td>2.8032</td><td>0.0533</td><td>0.9844</td></tr><tr><td>pH</td><td>0.0531</td><td>0.4669</td><td>0.0080</td><td>0.9912</td></tr><tr><td>T*</td><td>1.6178</td><td>7.4652</td><td>0.0774</td><td>0.9632</td></tr></tbody></table>

<figure><img src="image_7.png" /><figcaption>**Figure 3.** *Cont.*</figcaption></figure>
<figure><img src="image_8.png" /><figcaption>**Figure 3.** (a) Temperature predictions (red continuous line) compared with measurements (black dotted line) according to seasons. Absolute prediction error (orange continuous line) is also shown. (b) Temperature predictions vs. measurements (red dots) and histogram of residuals (blue bars).</figcaption></figure>

Model predictions could be further improved by tuning some of the heat transfer model parameters, or by using a dedicated meteorological station providing a more accurate estimation of the environmental conditions at the pond location. In fact, the weather dataset used for running simulations (i.e., air temperature, relative humidity, wind speed, and rain rate) were coming from the meteorological station at a distance of 10 km from where the reactor was located.

## 4.2. Full Predictive ALBA Model

In order to evaluate the overall model prediction capability when the physical and the biological models are coupled, the predicted temperature, instead of the one measured with the probe, was used to simulate the dynamics of the biological process over the 6-month period. The most relevant model state variables are reported in Figures 4–7, and compared with the experimental measurements, their standard deviations, and the error bounds for model predictions.

The accuracy of the heat transfer model results in predictions that are almost unchanged compared to the ones using the measured temperature (see Table 1). When comparing the predicted measurements of the initial model with measured temperature and the new one with predicted temperature, the r² is always larger than 0.98 for 2000 simulated points, and the predicted variables stay within an interval of 3% compared to the values simulated using the measured temperature.
<figure><img src="image_9.png" /><figcaption>**Figure 4.** Full prediction capability of the coupled heat transfer and ALBA models for O₂, compared with simulations using measured temperature (with a zoom in the lower figure). The shaded areas represent the 95% confidence intervals of model predictions.</figcaption></figure>

<figure><img src="image_10.png" /><figcaption>**Figure 5.** Full prediction capability of the coupled heat transfer and ALBA models. Comparison between full predictions (with simulated temperature) and measurements, for nitrite (S<sub>NO₂</sub>) and nitrate (S<sub>NO₃</sub>). Shaded areas on model predictions represent the related 95% confidence intervals.</figcaption></figure>
<figure><img src="image_11.png" /><figcaption>**Figure 6.** Full prediction capability of the coupled heat transfer and ALBA models. Comparison between full predictions (with simulated temperature) and measurements, for ammoniacal nitrogen ($S_{NH_4}$). Shaded areas on model predictions represent the related 95% confidence intervals.</figcaption></figure>

<figure><img src="image_12.png" /><figcaption>**Figure 7.** Full prediction capability of the coupled heat transfer and ALBA models. Comparison between full predictions (with simulated temperature) and measurements, for algal biomass ($X_{ALG}$). Shaded areas on model predictions represent the related 95% confidence intervals.</figcaption></figure>

### 4.3. *Process Configuration and Depth*

The model was then used to evaluate the consequence on two configurations on the process productivity, in terms of algae production or on TAN removal rate.

An alternative HRABP process was considered for comparison purpose. It consisted in a more classic set up of the raceway, with a contact on the ground (see Figure 8). Another heat transfer model (see details in Appendix C) was developed for this configuration [24], also extending the one of Béchet et al. [13]. The full predictive model was adapted to this particular case, and was also validated over more than one year with a HRABP lying on the ground (see details in Appendix A). Water temperature was also accurately forecast [24] (see Appendix D). The connection with the ground strongly increases the thermal inertia, and the objective of the study is to determine how much it impacts the process efficiency.

The study was also carried out considering three different water depths ($h_L$): 0.232 m, 0.116 m and 0.077 m, respectively. The first value is the nominal liquid depth that was applied during the experimental campaign described in Section 2, and for which the model was validated. The two other depth values, which are also typical of industrial scale
raceways, result from the scenario where 2 raceways (respectively 3) are used to treat the same inflow rate. The total volume and HRT for each scenario are the same, but depending on the scenarios (i) one raceway of depth 0.232 m is used, (ii) 2 raceways of the same area but with depth 0.116 m are used and (iii) 3 raceways of depth 0.077 m are operated.

It must be stressed that depth values represent the maximum liquid level reachable in the reactor. In fact, since the liquid depth is an output of the thermal balance, its level profile always oscillates because of the evaporation and rain rate contributions.

<figure><img src="image_13.png" /><figcaption>**Figure 8.** Scheme of the standard HRABP lying on the ground, with the heat fluxes considered in the radiative transfer model.</figcaption></figure>

Looking at the medium temperature ranges in each situation, it turns out that the temperature oscillations when the pond is not connected to the ground is of much larger amplitude. The average number of hours per day when the temperature is higher than 35 °C was computed, according to season (Table 2). This temperature was identified by Bechét et al. [25] as a lethal temperature for many species, with dramatic consequences in terms of viability [26]. In summer, on average 4 h per day a temperature higher than 35 °C can be reached, for the thinnest process raised above the ground. This daily average is reduced to 2 h for the raceway on the ground. It is lower for liquid depth of 0.2 m, but it is still larger than 1 h per day. A closer look at extreme events (see Figure 9) shows that, for the hottest days, the medium stays more than 7 h above the critical threshold, which is likely to lead to the culture crash. A side effect of these high temperature is that evaporation losses are much higher in the raised HRABP, with an average increase by 20%.

<table><caption>**Table 2.** Average number of hours per day where the medium temperature is larger than the critical temperature (35 °C), for the two configurations (RG: raceway lying on the ground, RR: raceway raised above the ground) and for three water depths ($h_L$).</caption><thead><tr><th rowspan="2">h<sub>L</sub><br>[m]</th><th colspan="2">Spring</th><th colspan="2">Summer</th><th colspan="2">Autumn</th></tr><tr><th>RG</th><th>RR</th><th>RG</th><th>RR</th><th>RG</th><th>RR</th></tr></thead><tbody><tr><td>0.232</td><td>0.00</td><td>0.00</td><td>0.19</td><td>1.18</td><td>0</td><td>0</td></tr><tr><td>0.116</td><td>0.33</td><td>1.00</td><td>1.44</td><td>3.21</td><td>0</td><td>0</td></tr><tr><td>0.077</td><td>0.72</td><td>1.33</td><td>2.08</td><td>3.99</td><td>0</td><td>0</td></tr></tbody></table>

Although our biological model cannot predict the impact of these high-temperature events, it is very likely that the ecosystem is degraded during these periods. This type of pilot therefore imposes unfavorable conditions for algal growth during the hottest months, at least under Mediterranean climates.
<figure><img src="image_14.png" /><figcaption>**Figure 9.** Pond temperature predictions (blue line) and simulated temperature higher than 35 °C (red dots), according to the liquid depth tested ($h_L$) and for both the raceway configurations: on the ground (**left column**); raised (**right column**).</figcaption></figure>

4.4. *Ecosystem Composition*

Experimental measurement of the various algal and bacterial biomasses is challenging. In the work of Ibekwe et al. [27], DNA extracts were used to assess the microbial community structure from bacterial 16S rRNA gene analysis (or 18S rRNA for algae) in an algae-bacteria raceway pond. These approaches are intensive and can only be carried out on a very limited number of samples. Above all, they provide an estimate of the number of operational taxonomic units (OTUs), but do not give a picture in terms of biomasses. A validated model such as the ALBA model can estimate the ecosystem composition over time.

Figure 10 presents the ecosystem composition estimated by the model, according to
seasons and to the various tested conditions.

Microalgae dominate the system in all the seasons and raceway configurations. The average proportion of heterotrophic and nitrifying bacteria on the total biomass increases in autumn (7.6–8.8% for heterotrophs and 11.9–13.3% for nitrifiers), for both raceways layouts, but remains marginal compared to algae concentration. The fraction of nitrifiers stays marginal along the various scenarios (1–1.4% in spring, 1.1–2.7 in summer, and 5.3–13.3% in autumn); however, it is worth noting that they are processing more than 70% of the influent ammoniacal nitrogen. Heterotrophic bacteria are higher in concentration in spring and summer (17.8–22.1 and 20.2–37.3 gCOD m⁻³, respectively) for both raceway layouts compared to nitrifiers, while in autumn, these two populations are more balanced. As expected, for lower depths, algae concentration increases, resulting from the fact that algae are favored in light absorption.
<figure><img src="image_15.png" /><figcaption>**Figure 10.** Seasonal average for biomass composition: algae ($X_{ALG}$), ammonium oxidizing bacteria ($X_{AOB}$), nitrite oxidizing bacteria ($X_{NOB}$), heterotrophic bacteria ($X_H$), for the two raceway configurations (RG: raceway on the ground, RR: raceway raised) and according to the three water depths.</figcaption></figure>

In general, the bacterial concentration is only marginally affected by depth. Nitrifying bacteria are indirectly affected by the competition with microalgae for inorganic carbon, and their concentration is thus higher for the higher liquid depths, associated to lower microalgal concentrations. The two raceway configurations do not massively affect the biomass distribution. A model that would more accurately account for the consequences of the extreme temperature events on mortality, according to the different populations, might modify these conclusions. For this, additional experiments to quantify how the high-temperature periods affect bacterial mortality are necessary.

## 4.5. Algal Productivity and Ammonium Removal Rate

Looking at the biological performances for the two different configurations, it turns out that rather similar values for the daily average are obtained (see Figure 11), and the results are first of all influenced by water depth.

Algae productivity ranges between 3.6 and 9.3 (gDW m⁻² d⁻¹), in line with the values recorded in other raceways pond applications [28,29], with a maximum productivity in summer. The rather low considered HRT explains these modest performances, which would have been higher for lower HRT. Algae concentration increases when operating with lower depth, but not in the same order of magnitude: when depth is divided by a factor of 2, algae concentration is increased by 30% in spring and by 110% in summer, explaining why the algal productivity is not eventually enhanced. This is mainly due to: (i) a stronger influence of the evaporation rate at lower water levels; and (ii) a much stronger competition for CO₂ with nitrifiers at higher algal density, reducing the algal growth rate [10]. The competition for inorganic carbon appears, even if pH is regulated at 7.5, due to a strong alkalinity consumption from nitrifying activity. Adding alkalinity in the influent has been shown to be an effective strategy to reduce and avoid this competition. In fact, with this approach, algae have the possibility to grow at their maximum rate, avoiding limiting conditions on inorganic carbon and thus increasing productivity. This is even beneficial for the environment, since inorganic carbon shortage has been shown to be associated with N₂O emission by nitrifiers [30].
<figure><img src="image_16.png" /><figcaption>**Figure 11.** Seasonal average and the associated standard deviation for algal productivity, algae concentration, TAN removal rate, and nitrogen conversion rate, for the two raceway configurations (RG: raceway on the ground, RR: raceway raised) and according to the three water depths.</figcaption></figure>

The TAN removal rate follows a similar trend, also driven by the inorganic carbon competition in the HRABP. In this case, since most of the ammonium is removed by the nitrifiers, reducing depth decreases the nitrogen flux treated by nitrifiers in similar proportion (the volumetric TAN removal rate being much less affected). The consequence is that the influent nitrogen to algae conversion rate considerably increases when reducing the liquid depth, since a higher proportion of nitrogen is processed by algae.

The similarity between the process on the ground and the one that is raised shows that mainly average temperature matters, and the daily average values do not significantly differ. However, looking closer at the standard deviation, it turns out that the predicted productivity varies widely. Temperature with thinner systems fluctuates strongly, leading to both variation in growth rate and in algal concentration. The large changes in concentration are also due to evaporation for the lowest depth. This explains why the standard deviation of algae concentration is more than 4 times higher at lower depth compared to its nominal value in summer. This is much less marked for the other seasons, when a factor only 2 is involved.

Keeping in mind that thinner system, and the raised process experiment with higher temperature ranges, with frequent excursions above the critical temperature, it is clear that reducing depth at constant HRT does not improve the process efficiency, and there is a risk of process crash due to high cell mortality.

A model to better represent the mortality at high temperature must be included in the biological model to propose a more accurate vision of the underlying processes.

## 4.6. *Choice of the Most Efficient Solutions*

The different system configurations, in terms of overall productivity and TAN removal rate, were compared (Figure 12). Reducing the depth by a factor 2 or 3 doubles or triples the number of raceways needed to process the same flux. The average TAN removal, installing
two or three raceways, increases only by 3.4% in spring, 3.7 and 4.8% in summer, and 2.6 and 4.5% in autumn, respectively, for the raceway lying on the ground. Looking at the raceway configuration that is raised up, comparable low gains in TAN removal rate are reached in all the seasons (3.1 and 3.4% in spring, 3.3 and 4.2% in summer, and 2.7 and 4.8% in autumn, respectively). The moderate increase in total TAN removal rate is most probably not compensated by the higher capital and operational costs.

On the contrary, if the objective is algae production, then using two or three raceways instead of one increases the total biomass production by 21.4 and 30.3% in spring, 64.3 and 94.0% in summer, and 80.7 and 132% in autumn, respectively, for the raceway lying on the ground. For the raceway configuration that is raised up, the percentage of increased algae productivity is in the same range (18.2 and 27.6% in spring, 57.7 and 91.9% in summer, and 69.1 and 113.9% in autumn, respectively). This strong production enhancement probably justifies that three raceways with lower depth are used.

<figure><img src="image_17.png" /><figcaption>**Figure 12.** Seasonal average total algal production (gDW d⁻¹) and total TAN removal rate (gN d⁻¹) for the two raceway configurations (RG: raceway on the ground, RR: raceway raised), and depending on the number of raceways to process the same inflow rate (with the same HRT). Scenario with one, two, or three raceways are associated to depths $h_L$ of 0.232, 0.116, and 0.077 m, respectively.</figcaption></figure>

**5. Conclusions**

The fully predictive model for simulating outdoor algae-bacteria processes includes a biological, a chemical, and a thermal submodel. The biological predictions, when temperature is also forecast, were revealed to be very accurate. Temperature dynamics follow seasonal variability according to reactor configurations and liquid depth, playing an important role in the biological and chemical submodels.

For lower depths or for raceways not directly lying on the ground, the resulting overwarming does not significantly alter productivity, since the daily average temperature is only marginally affected. However, when the model predicts a large deviation of temperatures during the warmest seasons, it means that algae are exposed to lethal conditions, and there is a strong risk of culture crash.

This work definitely motivates a model-based thermal design strategy in order to reduce the duration of extreme-temperature events and their dramatic consequences on the process integrity.
**Author Contributions:** F.C. Investigation: conducting research and investigation process, specifically mathematical model implementation and experimental data elaboration. Methodology: implementation of the ALBA model, temperature and pH submodel; running simulations. Model calibration and validation. Data curation: experimental data and simulation results elaboration, application of statistical computation, results interpretation and graphs realization. Writing: manuscript original draft and editing. Software: Matlab R2019b. O.B. Conceptualization: formulation and evolution of comprehensive research goals and objectives. Supervision: review and editing of the ALBA model, Temperature and pH submodel code, funding acquisition. Writing: manuscript review and editing. All authors have read and agreed to the published version of the manuscript.

**Funding:** This research was funded by ADEME Biomsa project.

**Data Availability Statement:** Data supporting the reported results can be found in the Appendices A–I.

**Acknowledgments:** The authors acknowledge the support of the ADEME Biomsa project.

**Conflicts of Interest:** The authors declare no conflict of interest.

## Nomenclature

<table><tr><td>ALBA</td><td>Algae-bacteria model</td></tr><tr><td>COD</td><td>Chemical oxygen demand</td></tr><tr><td>DW</td><td>Dry weight</td></tr><tr><td>HRABP</td><td>High-rate algae bacteria pond</td></tr><tr><td>HRT</td><td>Hydraulic retention time</td></tr><tr><td>RG</td><td>Raceway ground</td></tr><tr><td>RR</td><td>Raceway raised</td></tr><tr><td>S<sub>NH</sub></td><td>Ammoniacal nitrogen concentration</td></tr><tr><td>S<sub>NO<sub>2</sub></sub></td><td>Nitrite concentration</td></tr><tr><td>S<sub>NO<sub>3</sub></sub></td><td>Nitrate concentration</td></tr><tr><td>S<sub>O<sub>2</sub></sub></td><td>Dissolved oxygen concentration</td></tr><tr><td>TA</td><td>Total alkalinity</td></tr><tr><td>TAN</td><td>Total ammoniacal nitrogen</td></tr><tr><td>TSS</td><td>Total suspended solids</td></tr><tr><td>VSS</td><td>Volatile suspended solids</td></tr><tr><td>X<sub>ALG</sub></td><td>Algal biomass concentration</td></tr><tr><td>X<sub>AOB</sub></td><td>Ammonium-oxidizing bacteria concentration</td></tr><tr><td>X<sub>H</sub></td><td>Heterotrophic bacteria concentration</td></tr><tr><td>X<sub>NOB</sub></td><td>Nitrite-oxidizing bacteria concentration</td></tr></table>

## Appendix A. Description of the Second Case Study in Narbonne (France)

The HRABP is located at INRAE, Narbonne, southern France (latitude: 43.15656, longitude: 2.994438), with a total surface area of 56 m² and a channel length of 15 m (see Figure A1). The pond was realized in concrete and placed on the ground over a base of concrete (thickness 0.2 m). The HRABP was mixed with a paddle wheel, operated to obtain a water linear velocity of 0.2 m s⁻¹, and an additional mixing pump that was located at the opposite side of the paddle wheel (operated at the flow rate of 182 m³ d⁻¹). The raceway was operated in continuous mode, from 15 May 2018 to 01 August 2019. The influent flow rate was set to obtain a hydraulic retention time (HRT) of 5 days along the whole experimental period, except from one month (29 August–29 September 2018), during which different HRT values (ranging from 2 to 10 days) were tested. The outflow was implemented by gravity overflow, resulting in a variable liquid depth (min 0.257 m, max 0.368 m), measured with an ultrasonic distance sensor (Siemens, SITRANS Probe 7ML5221-1BB11). The HRABP was also equipped with online dissolved oxygen (METTLER TOLEDO, InPro 6850i), and temperature and pH (METTLER TOLEDO, InPro4260(i)/SG/425) probes. The incident light (expressed as photosynthetically active radiation, PAR) was continuously measured at the reactor surface, using a PAR meter (SKYE Instruments, PAR 2625).
<figure><img src="image_18.png" /><figcaption>**Figure A1.** Demonstrative scale raceway with a surface of 56 m², located in the south of France.</figcaption></figure>

All the online measurements were collected every five minutes, using the dedicated SILEX-LBE acquisition system (INRAE-LBE, France). The air temperature, wind speed, and relative humidity data, necessary for determining the pond temperature through the model, were acquired from the nearest weather station (Béziers, France, latitude: 43.3235, longitude: 3.3539), located approximately 30 km from the pond. The local rainfall rate was recorded on site.

More details on the experimental protocol can be found in [10].

## Appendix B. Modelling pH and Dissociation States

The chemical submodel consists in predicting pH ($(H^+)$) ions concentration), but also computing the fraction of the different dissociated compounds that are in equilibrium, depending on the pH. Here, we recall the principle of the implementation to highlight the temperature dependence of this submodel.

This sub-module includes three ingredients:

### i. The mass balance equations

These are the mass balance equations for the state variables corresponding to the total sum of chemicals that dissociate in the water. The set of mass balances is represented in Table A1.

As an example, the total concentration of $NH_3$ and $NH_4^+$ in the model corresponding to the state variable $\frac{S_{NH}}{14}$ leads to the following mass balance equation:

$$ \frac{S_{NH}}{14} - NH_3 - NH_4^+ = 0 $$

Note that these equations also account for the change in unit between the state variables and the chemical model (which should be in mol m⁻³).

<table><caption>**Table A1.** pH submodel algebraic equation system: mass balances and dissociation equilibrium.</caption><thead><tr><th>Description</th><th>Expression (mol m<sup>-3</sup>)</th><th>K<sub>A</sub> (mol L<sup>-1</sup>)</th></tr></thead><tbody><tr><td>Ammoniacal nitrogen</td><td></td><td></td></tr><tr><td>(1) Mass balance</td><td>S<sub>NH</sub>/14 - NH<sub>3</sub> - NH<sub>4</sub><sup>+</sup> = 0</td><td></td></tr><tr><td>(2) Dissociation</td><td>NH<sub>4</sub><sup>+</sup> - S<sub>NH</sub>/14 / (1 + S<sub>NH</sub>/14 / (K<sub>A</sub>NH<sub>4</sub>/H<sup>+</sup>)) = 0</td><td>K<sub>A,NH<sub>4</sub><sup>+</sup></sub> = 5.62 &times; 10<sup>-10</sup></td></tr><tr><td>NH<sub>4</sub><sup>+</sup> &rightleftharpoons; NH<sub>3</sub> + H<sup>+</sup></td><td></td><td></td></tr></tbody></table>
<table><caption>**Table A1. Cont.**</caption><thead><tr><th>Description</th><th>Expression (mol m<sup>-3</sup>)</th><th>K<sub>A</sub> (mol L<sup>-1</sup>)</th></tr></thead><tbody><tr><td colspan="3"><strong>Nitrogen oxides</strong></td></tr><tr><td>(3) Mass balance</td><td>S<sub>NO₂</sub>/14 - NO₂<sup>-</sup> - HNO₂ = 0</td><td></td></tr><tr><td>(4) Dissociation</td><td>HNO₂ - S<sub>NO₂</sub>/14 / (1 + S<sub>NO₂</sub>/14 / H<sup>+</sup>) = 0</td><td>K<sub>A,HNO₂</sub> = 4.47 × 10<sup>-04</sup></td></tr><tr><td>(5) Mass balance</td><td>S<sub>NO₃</sub>/14 - NO₃<sup>-</sup> - HNO₃ = 0</td><td></td></tr><tr><td>(6) Dissociation</td><td>HNO₃ - S<sub>NO₃</sub>/14 / (1 + S<sub>NO₃</sub>/14 / H<sup>+</sup>) = 0</td><td>K<sub>A,HNO₃</sub> = 4.37 × 10</td></tr><tr><td colspan="3"><strong>Inorganic carbon</strong></td></tr><tr><td>(7) Mass balance</td><td>S<sub>IC</sub>/12 - CO₂ - HCO₃<sup>-</sup> - CO₃²⁻ = 0</td><td></td></tr><tr><td>(8) Dissociation</td><td>CO₂ - S<sub>IC</sub>/12 / (1 + S<sub>IC</sub>/12 / H<sup>+</sup>) = 0</td><td>K<sub>A,H₂CO₃</sub> = 4.27 × 10<sup>-07</sup></td></tr><tr><td>(9) Dissociation</td><td>HCO₃<sup>-</sup> - S<sub>IC</sub>/12 / (1 + S<sub>IC</sub>/12 / H<sup>+</sup>) = 0</td><td>K<sub>A,HCO₃</sub> = 4.68 × 10<sup>-11</sup></td></tr><tr><td colspan="3"><strong>Orthophosphates</strong></td></tr><tr><td>(10) Mass balance</td><td>S<sub>PO₄</sub>/31 - H₃PO₄ - H₂PO₄<sup>-</sup> - HPO₄²⁻ - PO₄³⁻ = 0</td><td></td></tr><tr><td>(11) Dissociation</td><td>H₃PO₄ - S<sub>PO₄</sub>/31 / (1 + S<sub>PO₄</sub>/31 / H<sup>+</sup>) = 0</td><td>K<sub>A,H₃PO₄</sub> = 7.24 × 10<sup>-03</sup></td></tr><tr><td>(12) Dissociation</td><td>H₂PO₄<sup>-</sup> - S<sub>PO₄</sub>/31 / (1 + S<sub>PO₄</sub>/31 / H<sup>+</sup>) = 0</td><td>K<sub>A,H₂PO₄</sub> = 6.17 × 10<sup>-08</sup></td></tr><tr><td>(13) Dissociation</td><td>HPO₄²⁻ - S<sub>PO₄</sub>/31 / (1 + S<sub>PO₄</sub>/31 / H<sup>+</sup>) = 0</td><td>K<sub>A,HPO₄</sub> = 2.14 × 10<sup>-13</sup></td></tr><tr><td>(14) Dissociation</td><td>H₂O ⇌ OH⁻ + H⁺ OH⁻ - K<sub>a</sub>H<sub>2</sub>O<sup>3</sup>/H<sup>+</sup></td><td>K<sub>A,HPO₄</sub> = 1.00 × 10<sup>-14</sup></td></tr><tr><td>(15) Charge balance</td><td>H⁺ + NH₄⁺ + Δ<sub>CAT,AN</sub> - OH⁻ - NO₂<sup>-</sup> - NO₃<sup>-</sup> - HCO₃<sup>-</sup> - 2CO₃²⁻ - H₂PO₄<sup>-</sup> - 2HPO₄²⁻ - 3PO₄³⁻ = 0</td><td></td></tr></tbody></table>

## ii. Dissociation equations

These are the dissociation equations representing the affinity constants. They are rewritten in a form where only the ion concentration (here, $H^+$) together with the total amount of the element appears (represented by one of the model state variables). For example, for the dissociation constant associated with the chemical equilibrium $NH₄⁺ ⇌ NH₃ + H⁺$:

$$NH₄⁺ = \frac{S_{NH}/14}{1 + \frac{K_{a,NH₄} 10³}{H⁺}}$$

The temperature influence on the acidity constants is accounted for using the van't Hoff equation:

$$ln \frac{K_{a,T_p}}{K_{a,T_{ref}}} = \frac{\Delta H}{R} \left( \frac{1}{T_{ref}} - \frac{1}{T_p + 273.15} \right) \quad (A1)$$

where $T_{ref}$ is the standard temperature (i.e., 298.15 K) for which the value of the equilibrium coefficient ($K_{a,T_{ref}}$, (mol L⁻¹)) is known, $K_{a,T_p}$ (mol L⁻¹) is the equilibrium coefficient at $T_p$, R is the gas law constant (J K⁻¹ mol⁻¹) and ΔH is the heat of reaction at standard temperature and pressure (J mol⁻¹).

## iii. Electroneutrality

This refers to the ionic balance equation representing the electroneutrality of the medium, accounting for all the ions that are affected by the reactions, and for those of
constant concentration (denoted $\Delta_{CAT,AN}$) whose concentrations are not modified by any biochemical reaction. The considered electroneutrality equation is:

$$H^+ + NH_4^+ = OH^- + NO_2^- + NO_3^- + HCO_3^- + 2CO_3^{2-} + H_2PO_4^- + 2HPO_4^{2-} + 3PO_4^{3-} - \Delta_{CAT,AN} \quad (A2)$$

Equation (A2) for the charge balance provides the equation in which only the unknown ($H^+$) appears. It can be rewritten accounting for the dependence of the dissociated fractions from the $H^+$ ions and from the total amount of compounds.

$$H^+ + NH_4^+(H^+, S_{NH}) + \Delta_{CAT,AN} - OH^-(H^+) - NO_2^-(H^+, S_{NO_2}) - NO_3^-(H^+, S_{NO_3}) - HCO_3^-(H^+, S_{IC}) - 2CO_3^{2-}(H^+, S_{IC}) - H_2PO_4^-(H^+, S_{PO_4}) - 2HPO_4^{2-}(H^+, S_{PO_4}) - 3PO_4^{3-}(H^+, S_{PO_4}) = 0 \quad (A3)$$

which can be summarized as

$$H^+ = \Phi_{\text{pH}}(H^+, S_{PO_4}, S_{NO_2}, S_{NO_3}, S_{NH}, S_{IC}) \quad (A4)$$

The physical root of this equation can be solved by an algebraic solver to determine $H^+$.

Finally, in the ALBA model, there are 15 unknowns ($NH_3$, $NH_4^+$, $NO_2^-$, $HNO_2$, $NO_3^-$, $HNO_3$, $CO_2$, $HCO_3^-$, $CO_3^{2-}$, $H_3PO_4$, $H_2PO_4^-$, $HPO_4^{2-}$, $PO_4^{3-}$, $OH^-$, and $H^+$) that must be determined from the 5 mass balances derived from the state variables ($S_{PO_4}$, $S_{NO_2}$, $S_{NO_3}$, $S_{NH}$ and $S_{IC}$), the 9 equations for the dissociation, and the charge equation, leading to an algebraic equation.

In the last stage, the idea is to transform this algebraic problem into the solution of a differential system, in line with [23]. We compute the variable $\hat{H}^+$, which is an estimate of $H^+$ as the solution of:

$$\frac{d\hat{H}^+}{dt} = \hat{K}(\Phi_{\text{pH}}(\hat{H}^+, S_{PO_4}, S_{NO_2}, S_{NO_3}, S_{NH}, S_{IC}) - \hat{H}^+)$$

where $\hat{K}$ is a constant tuning the rate for solving the pH equation. Note that, for its equilibrium, $\hat{H}^+$ automatically satisfies Equation (A4).

## Appendix C. Heat Transfer Model for the Narbonne Case Study (Recall)

Similarly to the heat transfer model presented in this paper, the first heat balance for this system connected to the ground considers the temperature dynamics in the reactor, accounting for the heat exchanges with the concrete mass:

$$\rho_w V C_{p,w} \frac{dT_p}{dt} = Q_{ra,p} + Q_{ra,s} + Q_{ra,a} + Q_{h,\text{evap}} + Q_{\text{conv}} + Q_{h,in} + Q_{h,out} + Q_{h,\text{rain}} - Q_{\text{conv,cond}_w,\text{co}} \quad (A5)$$

where $T_p$ is the medium temperature (K); $\rho_w$ is the density of the water (kg m⁻³); $C_{pw}$ is the specific heat capacity of the water (J kg⁻¹ K⁻¹); and $V$ is the water volume (m³). $Q_{ra,p}$ is the radiation from the reactor surface (W); $Q_{ra,s}$ is the total (direct + diffuse) solar radiation (W); and $Q_{ra,a}$ is the radiation from the air to the water (W). $Q_{h,\text{evap}}$ is the evaporation flux (W), $Q_{\text{conv}}$ is the convective flux at the water surface (W); $Q_{h,in}$ (resp. $Q_{h,out}$) is the heat flux associated with the influent (resp. effluent) water (W) and $Q_{h,\text{rain}}$ is the heat flux related to rain (W). The term $Q_{\text{conv,cond}_w,\text{co}}$ is the conductive/convective flow related to the heat exchange between water and concrete:

$$Q_{\text{conv,cond}_w,\text{co}} = h_{w,\text{co}} \cdot (T_p - T_{\text{co}}) \cdot S \quad (A6)$$

The parameter $h_{w,co}$ (W m⁻² K⁻¹) is the heat transfer coefficient between the water (w) and the concrete; $T_{\text{co}}$ (K) is the temperature of the concrete and $Q_{\text{cond}}$ is the conductive flux with the ground at the reactor bottom (W).
The differential equation describing the temperature dynamics of the concrete is:

$$ \rho_{co} V_{co} C_{p,co} \frac{dT_{co}}{dt} = Q_{conv,cond_{w,co}} + Q_{cond} \quad (A7) $$

The conductive heat flux ($Q_{cond}$) has a minor impact on the total heat balance [13]; therefore, a linear soil temperature profile was assumed for the sake of simplicity. It was also assumed that the ground temperature was approximately equal to the annual average air temperature at a depth of 3.5 meters.

The evaporative and convective heat flux have a strong effect on the temperature prediction, and they were implemented according to the Buckingham theorem, depending on the dimensionless numbers of Sherwood, Schmidt, and Reynolds. The Sherwood and Nusselt numbers were linearly interpolated for Reynolds numbers between 3 × 10⁵ and 5 × 10⁵ to ensure model calculations for Reynolds numbers in the transition from laminar to turbulent flow.

More details can be found on this heat transfer model in [24].

## Appendix D. Temperature Prediction Efficiency for the HRABP Lying on the Ground

<figure><img src="image_19.png" /><figcaption>Figure A2. Heat transfer model validation over one year of experimental measurements for the HRABP located in Narbonne (F). (a) measured and simulated temperature. (b) correlation with measurements and distribution of error residuals.</figcaption></figure>
In general, the fully predictive ALBA model was able to simulate the main measured variables in the HRABP with a very good level of accuracy, very close to the ones obtained running the model with the measured temperature [24].

## Appendix E. Temperature Dynamics

<figure><img src="image_20.png" /><figcaption>**Figure A3.** Temperature dynamics for the raceway on the ground with the nominal depth (top), depth divided by 2 (middle), and depth divided by 3 (bottom). Simulations are from May to November 2016.</figcaption></figure>
<figure><img src="image_21.png" /><figcaption>**Figure A4.** Temperature dynamics for the suspended raceway with the nominal depth (**top**), depth divided by 2 (**middle**), and depth divided by 3 (**bottom**). Simulations are from May to November 2016.</figcaption></figure>
Appendix F. Microalgal Productivity

<figure><img src="image_22.png" /><figcaption>**Figure A5.** Algal productivity (in gDW/m²/d) for the concrete raceway with the nominal depth (top), depth divided by 2 (middle), and depth divided by 3 (bottom). Simulations are from May to November 2016.</figcaption></figure>
<figure><img src="image_23.png" /><figcaption>**Figure A6.** Algal productivity (in gDW/m²/d) for the suspended raceway with the nominal depth (top), depth divided by 2 (middle), and depth divided by 3. (bottom). Simulations are from May to November 2016.</figcaption></figure>
<figure><img src="image_24.png" /><figcaption>Appendix G. Microalgal Concentration</figcaption></figure>

**Figure A7.** Algal concentration (in COD/m³) for the concrete raceway with the nominal depth (top), depth divided by 2 (middle), and depth divided by 3 (bottom). Simulations are from May to November 2016.
<figure><img src="image_25.png" /><figcaption>**Figure A8.** Algal concentration (in COD/m³) for the suspended raceway with the nominal depth (top), depth divided by 2 (middle), and depth divided by 3 (bottom). Simulations are from May to November 2016.</figcaption></figure>

## Appendix H. Experimental Campaign on a Pilot-Scale Raceway Located in the Northern Italy

The HRABP was a pilot-scale polypropylene tank with an operating volume of 0.88 m³ and a total surface of approximately 3.8 m². The raceway pond had two main channels and semi-circular edges. The HRABP was installed in the dedicated WWTP of an intensive piggery farm, breeding more than 20,000 pigs, located in the north of Italy (Casaletto di Sopra, Cremona, Italy). In this farm, the excess sludge from the treatment of the piggery wastewater was co-digested in a biogas plant, together with several other agricultural wastes (chopped corn and barley, poultry manure, and olive pomace) to maximize the
energy recovery. The monitoring campaign was performed from May to December 2016. The HRABP influent was prepared starting from the liquid fraction of the digestate, obtained by centrifugation (hereafter indicated as centrate), and by dilution with tap water in order to reduce the influent TAN (total ammoniacal nitrogen) concentration (a dilution factor of 5 was applied until 17 September 2016, then it was reduced to 3 until the end of the experimentation). In the HRABP, the mixing was ensured by a paddle wheel, which was operated at 20 rpm to obtain an average liquid velocity of 0.2 m s⁻¹. In addition, the reactor was equipped with a contact cylinder (height 0.8 m, diameter 0.44 m, volume 0.12 m³) for bubbling pure CO₂ gas (belonging from a sump connected to it and activated as a function of the pH set-point value imposed). The influent flowrate was set to achieve an average HRT of 10 days until 11 October 2016. Afterwards, the HRT was increased to 20 days (until 06 December 2016), in order to compensate for the marked temperature reduction occurring during the cold season. A polyethylene shading net was applied in the period between 30 July 2016 and 24 August 2016, to decrease the incident radiation and the potential light inhibition. Since it negatively affected algae growth (see Figure A9a), it was eventually removed [17]. The influent characteristics were routinely monitored by measuring the organic matter content (total and soluble COD), the main inorganic nitrogen compounds (TAN and nitrate, N − NO₃⁻), the total Kjeldahl nitrogen (TKN), the orthophosphate (P − PO₄³⁻), and the TSS concentrations once a week (see also Table A2 for a summary of average values measured during the monitoring campaign). The mixed liquor in the HRABP was monitored twice a week, and the analyses were performed by spectrophotometric test kits on: TAN, nitrite (N − NO₂⁻), nitrate (N − NO₃⁻), phosphate (P − PO₄³⁻), and COD (total and soluble fractions). Optical density at 680 nm (to provide an estimate of the chlorophyll-a content), TSS, and volatile suspended solids (VSS) were measured once a week, according to standard methods. Algal cell counts were performed through microscopic observations (Optika Microscopes, B350) using a Bürker chamber (HBG, Precicolor). The weather dataset, including irradiance, air temperature, relative humidity, wind speed, and precipitation were retrieved from the ARPA Lombardia regional meteo database.

<table><caption>**Table A2.** Average influent characteristics and number of experimental samples (n). (*): The alkalinity measurements were done on the undiluted centrate, while all the other measurements reported in this table were executed on the diluted centrate.</caption><thead><tr><th>Measurements</th><th>Sample.</th><th>Unit</th><th>Mean ± St.Dev.</th><th>n</th></tr></thead><tbody><tr><td>COD<sub>T</sub></td><td>Unfiltered</td><td>mgCOD L<sup>-1</sup></td><td>514 ± 190</td><td>15</td></tr><tr><td>COD<sub>S</sub></td><td>Filtered (0.45 µm)</td><td>mgCOD L<sup>-1</sup></td><td>381 ± 114</td><td>18</td></tr><tr><td>TSS</td><td>Unfiltered</td><td>mgTSS L<sup>-1</sup></td><td>122 ± 78</td><td>17</td></tr><tr><td>VSS/TSS</td><td>Unfiltered</td><td>—</td><td>87 ± 7</td><td>14</td></tr><tr><td>TAN</td><td>Filtered (0.45 µm)</td><td>mgN L<sup>-1</sup></td><td>310 ± 91</td><td>30</td></tr><tr><td>TAN/TKN</td><td>Filtered (0.45 µm)</td><td>—</td><td>0.85 ± 0.1</td><td>9</td></tr><tr><td>N-NO<sub>3</sub><sup>-</sup></td><td>Filtered (0.45 µm)</td><td>mgN L<sup>-1</sup></td><td>12 ± 5</td><td>13</td></tr><tr><td>P-PO<sub>4</sub><sup>3-</sup></td><td>Filtered (0.45 µm)</td><td>mgP L<sup>-1</sup></td><td>14 ± 4</td><td>18</td></tr><tr><td>Turbidity</td><td>Unfiltered</td><td>FAU</td><td>93 ± 39</td><td>16</td></tr><tr><td>Alkalinity *</td><td>Filtered (0.45 µm)</td><td>mgCaCO<sub>3</sub> L<sup>-1</sup></td><td>6330 ± 696</td><td>10</td></tr></tbody></table>
# Appendix I. Ecosystem Composition during the Experimental Campaign

<figure><img src="image_26.png" /></figure>

**Figure A9.** Ecosystem composition during the experimental campaign carried out in the north of Italy: (a) expressed in concentration (gCOD m⁻³); (b) expressed in percentage (%). Algae are reported on the left axis, while heterotrophic and nitrifying bacteria are on the right axis, in both figures (a,b). Simulations are from May to November 2016.

## References

1. Rumin, J.; Nicolau, E.; Gonçalves de Oliveira Junior, R.; Fuentes-Grünewald, C.; Picot, L. Analysis of scientific research driving microalgae market opportunities in Europe. *Mar. Drugs* **2020**, *18*, 264. [CrossRef]

2. Koller, M.; Muhr, A.; Braunegg, G. Microalgae as versatile cellular factories for valued products. *Algal Res.* **2014**, *6*, 52–63. [CrossRef]

3. Milledge, J.J. Commercial application of microalgae other than as biofuels: A brief review. *Rev. Environ. Sci. Bio/Technol.* **2011**, *10*, 31–41. [CrossRef]

4. Benemann, J. Microalgae for biofuels and animal feeds. *Energies* **2013**, *6*, 5869–5886. [CrossRef]

5. Ras, M.; Steyer, J.P.; Bernard, O. Temperature effect on microalgae: A crucial factor for outdoor production. *Rev. Environ. Sci. Bio/Technol.* **2013**, *12*, 153–164. [CrossRef]

6. Reichert, P.; Borchardt, D.; Henze, M.; Rauch, W.; Shanahan, P.; Somlyódy, L.; Vanrolleghem, P. River water quality model no. 1 (RWQM1): II. Biochemical process equations. *Water Sci. Technol.* **2001**, *43*, 11–30. [CrossRef] [PubMed]

7. Wolf, G.; Picioreanu, C.; van Loosdrecht, M.C. Kinetic modeling of phototrophic biofilms: The PHOBIA model. *Biotechnol. Bioeng.* **2007**, *97*, 1064–1079. [CrossRef]

8. Arashiro, L.T.; Rada-Ariza, A.M.; Wang, M.; Van Der Steen, P.; Ergas, S.J. Modelling shortcut nitrogen removal from wastewater using an algal-bacterial consortium. *Water Sci. Technol.* **2017**, *75*, 782–792. [CrossRef]

9. Solimeno, A.; Gómez-Serrano, C.; Acién, F.G. BIO_ALGAE 2: Improved model of microalgae and bacteria consortia for wastewater treatment. *Environ. Sci. Pollut. Res.* **2019**, *26*, 25855–25868. [CrossRef]

10. Casagli, F.; Zuccaro, G.; Bernard, O.; Steyer, J.P.; Ficara, E. ALBA: A comprehensive growth model to optimize algae-bacteria wastewater treatment in raceway ponds. *Water Res.* **2021**, *190*, 116734. [CrossRef] [PubMed]

11. Sánchez-Zurano, A.; Rodríguez-Miranda, E.; Guzmán, J.L.; Acién-Fernández, F.G.; Fernández-Sevilla, J.M.; Molina Grima, E. Abaco: A new model of microalgae-bacteria consortia for biological treatment of wastewaters. *Appl. Sci.* **2021**, *11*, 998. [CrossRef]

12. Casagli, F.; Rossi, S.; Steyer, J.P.; Bernard, O.; Ficara, E. Balancing microalgae and nitrifiers for wastewater treatment: Can inorganic carbon limitation cause an environmental threat? *Environ. Sci. Technol.* **2021**, *55*, 3940–3955. [CrossRef]
13. Béchet, Q.; Shilton, A.; Park, J.B.; Craggs, R.J.; Guieysse, B. Universal temperature model for shallow algal ponds provides improved accuracy. *Environ. Sci. Technol.* **2011**, *45*, 3702–3709. [CrossRef] [PubMed]

14. Béchet, Q.; Sialve, B.; Steyer, J.P.; Shilton, A.; Guieysse, B. Comparative assessment of evaporation models in algal ponds. *Algal Res.* **2018**, *35*, 283–291. [CrossRef]

15. Slegers, P.; Lösing, M.; Wijffels, R.; Van Straten, G.; Van Boxtel, A. Scenario evaluation of open pond microalgae production. *Algal Res.* **2013**, *2*, 358–368. [CrossRef]

16. Rodríguez-Miranda, E.; Acién, F.G.; Guzmán, J.L.; Berenguel, M.; Visioli, A. A new model to analyze the temperature effect on the microalgae performance at large scale raceway reactors. *Biotechnol. Bioeng.* **2021**, *118*, 877–889. [CrossRef]

17. Pizzera, A.; Scaglione, D.; Bellucci, M.; Marazzi, F.; Mezzanotte, V.; Parati, K.; Ficara, E. Digestate treatment with algae-bacteria consortia: A field pilot-scale experimentation in a sub-optimal climate area. *Bioresour. Technol.* **2019**, *274*, 232–243. [CrossRef] [PubMed]

18. Bastin, G.; Dochain, D. *On-Line Estimation and Adaptive Control of Bioreactors*; Elsevier: New York, NY, USA, 1990.

19. De Baar, H. von Liebig's law of the minimum and plankton ecology (1899–1991). *Prog. Oceanogr.* **1994**, *33*, 347–386. [CrossRef]

20. Bernard, O.; Rémond, B. Validation of a simple model accounting for light and temperature effect on microalgal growth. *Bioresour. Technol.* **2012**, *123*, 520–527. [CrossRef] [PubMed]

21. Rosso, L.; Lobry, J.; Bajard, S.; Flandrois, J.P. Convenient model to describe the combined effects of temperature and pH on microbial growth. *Appl. Environ. Microbiol.* **1995**, *61*, 610–616. [CrossRef]

22. Tsilingiridis, G.; Papakostas, K. Investigating the relationship between air and ground temperature variations in shallow depths in northern Greece. *Energy* **2014**, *73*, 1007–1016. [CrossRef]

23. Rosén, C.; Jeppsson, U. *Aspects on ADM1 Implementation within the BSM2 Framework*; Department of Industrial Electrical Engineering and Automation, Lund University: Lund, Sweden, 2006.

24. Casagli, F.; Bernard, O. A fully predictive framework to simulate biotechnological processes affected by meteorology: Application to algae-bacteria systems. *J. Clean. Prod.* Under revision.

25. Béchet, Q.; Shilton, A.; Guieysse, B. Maximizing productivity and reducing environmental impacts of full-scale algal production through optimization of open pond depth and hydraulic retention time. *Environ. Sci. Technol.* **2016**, *50*, 4102–4110. [CrossRef] [PubMed]

26. Béchet, Q.; Laviale, M.; Arsapin, N.; Bonnefond, H.; Bernard, O. Modeling the impact of high temperatures on microalgal viability and photosynthetic activity. *Biotechnol. Biofuels* **2017**, *10*, 1–11. [CrossRef] [PubMed]

27. Ibekwe, A.M.; Murinda, S.E.; Murry, M.A.; Schwartz, G.; Lundquist, T. Microbial community structures in high rate algae ponds for bioconversion of agricultural wastes from livestock industry for feed production. *Sci. Total Environ.* **2017**, *580*, 1185–1196. [CrossRef]

28. Zurano, A.S.; Cárdenas, J.G.; Serrano, C.G.; Amaral, M.M.; Acién-Fernández, F.; Sevilla, J.F.; Grima, E.M. Year-long assessment of a pilot-scale thin-layer reactor for microalgae wastewater treatment. Variation in the microalgae-bacteria consortium and the impact of environmental conditions. *Algal Res.* **2020**, *50*, 101983. [CrossRef]

29. Morillas-España, A.; Lafarga, T.; Sánchez-Zurano, A.; Acién-Fernández, F.G.; Rodríguez-Miranda, E.; Gómez-Serrano, C.; González-López, C.V. Year-long evaluation of microalgae production in wastewater using pilot-scale raceway photobioreactors: Assessment of biomass productivity and nutrient recovery capacity. *Algal Res.* **2021**, *60*, 102500. [CrossRef]

30. Mellbye, B.L.; Giguere, A.; Chaplen, F.; Bottomley, P.J.; Sayavedra-Soto, L.A. Steady-state growth under inorganic carbon limitation conditions increases energy consumption for maintenance and enhances nitrous oxide production in Nitrosomonas europaea. *Appl. Environ. Microbiol.* **2016**, *82*, 3310–3318. [CrossRef]