Introduction

Microbial fuel cells (MFCs) are bioelectrochemical devices designed for direct electricity production from organic matter. The main difference with respect to a conventional fuel cell is that the MFC anode benefits from the biocatalytic activity of exoelectricigenic bacteria, which transfer electrons derived from the oxidation of organic matter to the anode. Similar to fuel cells, the released electrons flow through the external electrical circuit while protons migrate to the cathode to reduce oxygen and form water [1].

Owing to the broad selectivity of microbial enzymes and mixed microbial communities capable of oxidizing a wide range of organic molecules, MFCs can be used for energy recovery from diluted organic wastes such as wastewater [24]. Such novel technology perfectly fits future scenarios of renewable energy production, where a significant part of the energy comes from renewable sources to sustain increased energy demands [2]. Recent advances in the understanding of MFC microbiology and improved reactor design have led to orders-of-magnitude increase in MFC volumetric power density. Yet, volumetric performance should be further improved to enable commercial applications of microbial electrochemical technologies (METs). Model-based reactor design as well as advanced monitoring and control strategies play an important role in these efforts with mathematical models representing an important tool for portraying process dynamics, understanding fundamental properties of MFCs, and developing software sensors for advanced process control strategies [5].

Several existing MFC dynamic models are able to adequately describe relatively slow dynamics of biomass growth and carbon source consumption. Some models consider a single microbial population [69], while others were expanded to describe mixed microbial populations required for degrading complex carbon sources such as wastewater [10, 11] and to enable calculation of pH gradients in anodophilic biofilms [12]. In another approach, electrochemical biofilms were described as a one-dimensional conductive matrix [13]. More complex models are able to describe the evolution in time and space of several key variables, such as current, charge, voltage, power output and consumption of substrates (carbon sources) for several microbial populations [14]. However, the high complexity of some models makes them unsuitable for developing software sensors or model-based control oriented strategies for the MFCs.

Recent experiments demonstrated significant charge storage capacity of bioelectrochemical biofilms [15]. Furthermore, MFC operation with pulse-width modulated or intermittent connection of the external resistance [1618] demonstrated that internal capacitance of anodic biofilms leads to complex non-linear behavior, which combines fast, i.e., with time constants in the order of milliseconds, charge/discharge dynamics with much slower dynamics of microbial biofilm growth and decay, with time constants in the order of hours to days. While an electrical equivalent circuit (EC) model is able to describe fast electrical dynamics of the anodic biofilm [17], this simplified approach does not allow for describing biomass growth and substrate consumption dynamics resulting in a very limited predictive capacity of the EC model. On the other hand, such biomass-related dynamics can be well described by a bioelectrochemical model. Taking that into account, this study presents a combined bioelectrochemical–electrical (CBE) model of an MFC obtained by merging fundamental equations based on mass and electron balances with equations describing an equivalent electrical circuit. Accordingly, the CBE model describes both fast (ms) and slow (h and days) MFC dynamics.

Materials and methods

MFC design and operation

Experiments were conducted in a membrane-less air–cathode MFC with an anodic compartment volume of 50 mL. The MFC housed two 10 cm × 5 cm carbon felt anodes with a total thickness of 10 mm (SGL Canada, Kitchener, ON, Canada) and two cathodes (one on each side) made of a 10 cm × 5 cm manganese-based catalyzed carbon E4 cathode (Electric Fuel Ltd, Bet Shemesh, Israel). The electrodes were separated by a nylon cloth. Liquid mixing was provided by an external recirculation loop. Temperature was kept constant at 25 °C by a flow-through heater in the external recirculation loop. Acetate was used as the sole source of carbon. The desired input acetate concentration was obtained by changing the infusion rate of an acetate stock solution. Hydraulic retention time was kept at 6–7 h and the influent acetate concentration was varied from 900 to 1800 mg L−1. A more detailed description of the experimental setup can be found elsewhere [16].

Throughout the tests, the MFC was operated using pulse-width modulated connection of the external resistor (R-PWM mode). Such operation involved connecting the external resistor (R ext) to MFC terminals with an electronic switch (IRF540, International Rectifier, El Sequndo, CA, USA). The switch was computer-controlled using a Labjack U3-LV data acquisition board (LabJack Corp., Lakewood, CO, USA). The data acquisition board was also used to record MFC voltage at a maximum rate of 22,500 scans/s. More details are provided elsewhere [16].

Analytical methods, inoculum and media composition

Acetate concentration in the anodic liquid was analyzed on an Agilent 6890 gas chromatograph (Wilmington, DE, USA) equipped with a flame ionization detector. Method details are provided in Tartakovsky et al. [19].

The MFC was inoculated with 5 mL of anaerobic sludge with a volatile suspended solids (VSS) content of approximately 40–50 g L−1 (Lassonde Inc, Rougemont, QC, Canada) and 20 mL of effluent from an operating MFC.

The nutrients solution was composed of (in g L−1): yeast extract (0.8), NH4Cl (18.7), KCl (148.1), K2HPO4 (64.0), and KH2PO4 (40.7) and sodium acetate. The concentration of sodium acetate in the nutrients solution varied between 10 and 40 g L−1 (as CH3COO) in order to obtain the desired organic load. 1 mL of a trace elements stock solution was added to 1 L of deionized water, which was fed to the MFC. The stock solution composition is provided in Pinto et al. [20]. The anodic liquid solution conductivity was 16–18 mS cm−1.

Numerical methods and calculations

Matlab R2012a (Mathworks, Natick, MA, USA) was used for all “off-line” calculations. Parameter estimation was performed using the fminsearch subroutine of the Matlab Optimization Toolbox and the model equations were solved using a variable order integration method for stiff differential equations (ode15s). “On-line” estimations of the equivalent circuit model parameters were carried out according to the algorithm described by Coronado et al. [17]. A brief description of this algorithm is provided in the "Appendix".

For the purpose of sensitivity analysis, a general form of a dynamic model was considered. This model was defined by its state equation

$$\frac{{{\text{d}}x}}{{{\text{d}}t}} = f\left( {t,x,u,\theta } \right),$$
(1)

and its output equation

$$y(t) = g\left( {t,x,u,\theta } \right),$$
(2)

where t is the time, x is the vector of state variables, u is the input vector, y is the output vector and θ is the parameter vector. In order to find parameters with the highest influence on the model outputs, normalized sensitivity functions of the outputs with respect to each parameter (\(\bar{s}\)) were calculated as described in Kravaris et al. [21]:

$$\frac{\text{d}}{{{\text{d}}t}}\left( {\frac{\partial x}{{\partial \bar{\theta }}}} \right) = \frac{\partial f}{\partial x}\left( {\frac{\partial x}{{\partial \bar{\theta }}}} \right) + \frac{\partial f}{\partial \bar{\theta } },$$
(3)
$$\frac{{\partial \bar{y}}}{{\partial \bar{\theta }}} = \frac{{{\text{d}}\bar{y}}}{{{\text{d}}y}}\left[ {\frac{\partial g}{\partial x}\left( {\frac{\partial x}{{\partial \bar{\theta }}}} \right) + \frac{\partial g}{\partial \bar{\theta } }} \right].$$
(4)

The correlation between the sensitivity functions calculated for the selected parameters was evaluated with the Pearson’s linear correlation coefficient obtained with the corr function in Matlab’s Statistics Toolbox. The magnitude of the effect of any parameter on a given output was calculated as the norm of its normalized sensitivity function \(\left\| {\bar{s}} \right\|\), where \(\bar{s} = {{\partial \bar{y}} \mathord{\left/ {\vphantom {{\partial \bar{y}} {\partial \bar{\theta }}}} \right. \kern-0pt} {\partial \bar{\theta }}}\). The ellipses of confidence and the corresponding confidence intervals were calculated by means of the covariance matrix obtained as the inverse of the Fisher information matrix F and expressed as:

$$F = \bar{S}^{T} \varSigma \bar{S},$$
(5)

where \(\bar{S} = \left[ {\bar{s}_{1} , \ldots ,\bar{s}_{\text{p}} } \right]\) is the sensitivity matrix for each output and Σ is the matrix containing the scaling factors \({1 \mathord{\left/ {\vphantom {1 {\sigma^{2} }}} \right. \kern-0pt} {\sigma^{2} }}\) for each output. Here, \(\sigma^{2}\) is the mean squared error (MSE) of each model output.

The objective function used for the model parameter estimation was formed by summing the MSE of each output as follows:

$$F_{\text{obj}} = \sum\limits_{i} {\left[ {\frac{1}{{N_{i} }}\sum\limits_{j = 1}^{N} {\left( {\bar{y}_{i,j}^{\exp } - \bar{y}_{i,j}^{\text{sim}} } \right)}^{2} } \right]} ,$$
(6)

where \(\bar{y}_{i,j}^{ \exp }\) and \(\bar{y}_{i,j}^{\text{sim}}\) are the normalized experimental and model (simulated) outputs at the jth sampling time; i is the model output index, and N is the number of measurements.

Results and discussion

Model formulation

As previously mentioned, the CBE model was obtained by merging equations describing microbial, carbon source and electron balances of the bioelectrochemical model developed by Pinto et al. [11] with equations describing the equivalent electrical circuit of an MFC [16]. Because the CBE model is largely based on the bioelectrochemical model of Pinto et al. [11], it inherits its features and assumptions. Consequently, the model accounts for electricigenic (X e, attached) and methanogenic (X m, attached or suspended) microbial communities, which are modeled by a two-phase growth-washout model [22] with multiplicative Monod growth kinetics. Acetate (S) is considered as the sole carbon source. Other assumptions are the following: (1) the CBE material balances only describe the anodic compartment assuming a non-limiting cathode reaction rate; (2) the extracellular electron transfer mechanism from the carbon source to the anode is assumed via nanowires or direct contact with the anode; (3) the intracellular charge transfer mechanism is assumed to involve the oxidized (M ox) and reduced (M red) forms of an intracellular mediator (e.g. NADH/NAD+) with a constant mediator pool (M tot) per microorganism. Furthermore, reactor material balances are simplified by assuming: (4) ideal carbon source mixing within the anode compartment; (5) absence of carbon source and microbial gradients within the anodic biofilm; (6) negligible gas transport through the cathode; and, (7) constant temperature and pH.

The concept of the CBE model is presented in Fig. 1. Similar to the EC model, internal resistance (R 1) represents the electrolyte ohmic resistance, while a resistor/capacitor circuit is included to describe the internal capacitance (C) and the activation losses (R 2). Accordingly, MFC internal resistance (R int) is defined as

$$R_{\text{int}} \, = \, R_{1} \, + \, R_{2} .$$
(7)

Based on the assumptions described above, MFC mass balances are given by the following equations:

$$\frac{{{\text{d}}S}}{{{\text{d}}t}} = - q_{\text{e}} X_{\text{e}} - q_{\text{m}} X_{\text{m}} + \frac{{F_{\text{in}} }}{V}(S_{\text{in}} - S) ,$$
(8)
$$\frac{{{\text{d}}X_{e} }}{{{\text{d}}t}} = \mu_{\text{e}} X_{\text{e}} - K_{\text{de}} X_{\text{e}} - \alpha \frac{{F_{\text{in}} }}{V}X_{\text{e}} ,$$
(9)
$$\frac{{{\text{d}}X_{\text{m}} }}{{{\text{d}}t}} = \mu_{\text{m}} X_{\text{m}} - K_{\text{dm}} X_{\text{m}} - \alpha \frac{{F_{\text{in}} }}{V}X_{\text{m}} ,$$
(10)
$$\frac{{{\text{d}}M_{\text{ox}} }}{{{\text{d}}t}} = - Yq_{\text{e}} + \gamma \frac{{I_{\text{cell}} }}{\text{mF}}\frac{1}{{VX_{\text{e}} }} ,$$
(11)

where F in is the flow rate to MFC (L day−1), V is the anodic compartment volume (L), S in is the influent carbon source concentration (mg L−1), I cell is the MFC current (A), α is the biomass retention parameter. Other notations are provided in Table 1.

Fig. 1
figure 1

Schematic diagram of the CBE model

Table 1 CBE model parameters

The kinetic dependencies are defined as follows:

$$\mu_{\text{e}} = \mu_{\text{max,e}} \left( {\frac{S}{{K_{\text{S,e}} + S}}} \right)\left( {\frac{{M_{\text{ox}} }}{{K_{\text{M}} + M_{\text{ox}} }}} \right) ,$$
(12)
$$q_{\text{e}} = q_{\text{max,e}} \left( {\frac{S}{{K_{\text{S,e}} + S}}} \right)\left( {\frac{{M_{\text{ox}} }}{{K_{\text{M}} + M_{\text{ox}} }}} \right) ,$$
(13)
$$\mu_{\text{m}} = \mu_{\text{max,m}} \left( {\frac{S}{{K_{\text{S,m}} + S}}} \right) ,$$
(14)
$$q_{\text{m}} = q_{\text{max,m}} \left( {\frac{S}{{K_{\text{S,m}} + S}}} \right) ,$$
(15)

where the biomass retention parameter is defined as

$$\alpha = \frac{1}{2}\left[ {1 + \tanh \left[ {K_{\text{x}} \left( {X_{\text{e}} + X_{\text{m}} - X_{ \hbox{max} } } \right)} \right]} \right]$$
(16)

Also, the mediator balance is given by

$$M_{\text{tot}} \, = \, M_{\text{ox}} \, + \, M_{\text{red}}$$
(17)

Also, the following dynamic equation can be used to describe the voltage (V c) at the internal capacitor C:

$$\frac{{{\text{d}}V_{\text{c}} }}{{{\text{d}}t}} = \frac{{I_{\text{cell}} - V_{\text{c}} /R_{2} }}{C} .$$
(18)

The electrochemical balance is given by

$$I_{\text{cell}} = \frac{{E_{\text{oc}} - \eta_{\text{conc}} - V_{\text{c}} }}{{R_{\text{ext}} + R_{\text{int1}} }}\left( {\frac{{M_{\text{red}} }}{{\varepsilon_{\text{i}} + M_{\text{red}} }}} \right) ,$$
(19)

where concentration losses are defined as

$$\it \eta_{\text{conc}} = \frac{RT}{\text{mF}}\log \left( {\frac{{M_{\text{tot}} }}{{M_{\text{red}} }}} \right)$$
(20)

The following empirical expressions were derived based on previously obtained experimental results [11, 16, 18] and are used to describe the dependence of the internal resistances (R 1 and R 2), the internal capacitance (C), and the open circuit voltage (E oc) on the anodic biofilm density:

$$R_{1} = R_{\text{min1}} + \left( {R_{ \hbox{max} } - R_{\text{min1}} } \right)e^{{ - K_{\text{r}} X_{\text{e}} }} ,$$
(21)
$$R_{ 2} = R_{\text{min2}} + \left( {R_{ \hbox{max} } - R_{\text{min2}} } \right)e^{{ - K_{\text{r}} X_{\text{e}} }} ,$$
(22)
$$C = C_{ \hbox{min} } + \left( {C_{ \hbox{max} } - C_{ \hbox{min} } } \right)e^{{ - \frac{1}{{K_{\text{r}} X_{\text{e}} }}}} ,$$
(23)
$$E_{\text{oc}} = E_{ \hbox{min} } + \left( {E_{ \hbox{max} } - E_{ \hbox{min} } } \right)e^{{ - \frac{1}{{K_{\text{r}} X_{\text{e}} }}}}$$
(24)

Output electrical voltage (V cell) and power (P cell) are given by the following expressions:

$$V_{\text{cell}} \, = \, I_{\text{cell}} \, R_{\text{ext}} ,$$
(25)
$$P_{\text{cell}} \, = \, V^2_{\text{cell}} \, /R_{\text{ext}} .$$
(26)

Finally, the rate of methane production (Q) by methanogenic microorganisms is assumed to be proportional to the substrate consumption rate by this trophic group:

$$Q \, = \, Y_{{{\text{CH}}_{ 4} }} \, q_{\text{m}} \, X_{\text{m}} \, V .$$
(27)

The proposed CBE model is capable of describing both fast and slow MFC dynamics. Notably, the model can be used for two distinctly different types of simulations. A conventional, “off-line” modeling approach is described by Eqs. (727). This approach can be used to predict MFC output voltage, carbon source effluent concentration, and the distribution of microbial populations under various operating conditions. This application of the model requires prior knowledge of model parameters listed in Table 1. Since the CBE model shares the microbial kinetics and material balances with the bioelectrochemical model of Pinto et al. [11], the two models predict the same long-term dynamics in the absence of fast external resistance variations.

In addition to off-line predictions the “on-line” version of the model could be used, where the simulations are carried out concurrently with the experiment and empirical Eqs. (2124) are replaced by R int, C, and E ocv estimations obtained in real time, e.g. using an estimation procedure proposed by Coronado et al. [17] as described in "Appendix". This procedure can be applied to the existing measurements or in real-time. The two approaches to utilizing the model are illustrated in Fig. 2.

Fig. 2
figure 2

Structure for the “off-line” and “on-line” CBE model implementations. The inputs are F in (flow rate), S in (influent substrate concentration), and R ext, (external resistance). The outputs are S out (effluent carbon source concentration) and V cell (voltage). The “on-line” model uses instant estimations of the electrical variables such as open circuit voltage (E ocv), capacitance (C), and internal resistance (R int)

Sensitivity analysis

The sensitivity analysis was carried out to reduce the number of model parameters requiring identification. First, the norm of the sensitivity profiles (Eq. 4) for all parameters was computed and arranged from highest to the lowest values. The highest norm indicates the highest impact of the parameter on the selected output. Second, because of the limited number of measurable state variables, the confidence intervals obtained from the Fisher information matrix (Eq. 5), were used to select parameters that can be estimated with an acceptable accuracy.

The influence of all model parameters on the model outputs was evaluated (results not shown) and four parameters (Y, µ max,e, K r and K x) with the highest impact were selected for parameter identification. The magnitude of the effect of Y, µ max,e, K r, and K x on the model outputs (expressed as the norm of the sensitivity function in Eq. 4) was, respectively, 2.7, 11.5, 0.27 and 1.7 for the output substrate concentration profile and 40.9, 72.1, 597.9 and 11.8 for the output voltage profile. Accordingly, µ max,e showed the highest effect on the output substrate concentration while K r had the greatest impact on voltage output.

Figure 3 shows the sensitivity profiles corresponding to these four parameters (Y, µ max,e, K r and K x). The profiles were obtained using the same inputs (influent acetate concentration and flow rate profiles) as those used in the experimental data for parameter estimation. Thus, the input flow rate (F in) was maintained so that the hydraulic retention time within the MFC was about 7.5 h and the input substrate concentration was subjected to step-wise changes as depicted in Fig. 3. Also, the external resistance (R ext) was set to 12 Ω and controlled using the R-PWM mode of operation.

Fig. 3
figure 3

a - The influent substrate concentration, S in, profile and sensitivity profiles corresponding to b - the effluent carbon source concentration, S out, and c - the output voltage, V cell, for the parameters Y, µ max,e, K r and K x

It should also be mentioned that in all simulations the profile for the methanogenic microorganisms (X m) remained negligible, probably due to the operational conditions favoring growth of the electricigenic bacteria [23]. Accordingly, all the parameters related to the methanogenic population showed little effect on the outputs. Their values were taken from previous experiments where methane production was measurable [11]. Any other parameters remaining were not considered because either they presented negligible effects on the outputs or their values could be assumed (e.g. physical constants) or experimentally measured and did not need to be re-estimated.

Parameter estimation

To estimate model parameters, the difference between model outputs and the corresponding experimentally measured values (acetate concentrations and MFC voltage) was minimized according to Eq. (6). First, parameters of the “off-line” model described in Fig. 2 were estimated. Only four parameters, suggested by the sensitivity analysis shown in “Sensitivity analysis” were estimated.

The estimated values of Y, µ max,e, K r and K x were 41.25, 1.87, 0.031 and 0.00077, respectively (units are indicated in Table 1). To visualize the estimation accuracy and the correlations between the estimated parameters, the 95 % confidence ellipses were calculated. All the parameters had low correlations as it can be observed by the ellipses being parallel to the axis, except for the set of parameters µ max,e − K x (Fig. 4). The lowest Pearson’s correlation coefficient was −0.06 for Y − K r and the highest correlation corresponds to µ max,e − K x, at 0.86. The highest correlation can be observed by the ellipse being at a certain angle with respect to the axis. The Fisher information matrix (Eq. 5) was invertible with the lowest and highest eigenvalues being 100 and 2.5 × 10−6, respectively.

Fig. 4
figure 4

95 % ellipses of confidence for the CBE “off-line” model (a) and for the “on-line” model (b)

With a 95 % confidence level, the intervals of confidence were 4.3, 4.1, 0.2 and 25.7 % for Y, µ max,e, K r and K x, respectively, i.e., the accuracy of K x estimation was the lowest. Also, the sensitivity analysis shows that K x has low impact on the effluent acetate concentration (Fig. 3b) and the MFC voltage (Fig. 3c). Therefore, such large confidence interval is acceptable considering the low impact of K x on the model outputs and the complex microbial dynamics. The intervals of confidence estimated for Y, µ max,e were similar to 0.9 and 3.0 % values estimated by Pinto et al. [11] using voltage measurements obtained during first 20 days of operation (MFC startup).

Parameters included in the empirical Eqs. (2124) were selected based on the results of the on-line parameter estimation procedure described in "Appendix". Notably, the on-line estimations of E oc were significantly lower than the values estimated during polarization tests (results not shown). This difference can be attributed to higher acetate concentrations in polarization tests, in which E oc values were acquired after 30 min of MFC operation in the open circuit mode. The absence of microbial electricigenic activity during this period led to acetate accumulation and, accordingly, in carbon source non-limiting conditions resulting in higher E oc estimations. Consequently, parameters E max and E min in Eq. (24) were set to 0.4 and 0.01 V, respectively. Parameters R max, R min1 and R min2 in Eqs. (21) and (22) were set to 2000, 1.17 and 5.13 Ω, respectively. Finally, parameters C max and C min in Eq. (23) were set to 0.95 and 0.01 F, respectively, based on the estimated capacitance values obtained during MFC startup and operation [24]. All other parameters were adapted from Pinto et al. [11], as indicated in Table 1.

Figure 5 compares model outputs with the corresponding measurements. Effluent acetate concentrations were accurately described by the model at all influent concentrations (Fig. 5a). MFC output voltage was observed to depend on the influent acetate concentration (organic load) with voltage drops during low load operation (days 30–35 and 57–59, Fig. 5b). The model slightly underestimated the output voltage at the highest influent concentration (days 43–50) and overestimated voltage recovery after the second period of MFC operation at low organic load (days 59–63, Fig. 5b). Nevertheless, effluent acetate and voltage trends were correctly described with MSE values of 0.035 and 0.14 for the effluent acetate concentration and the output voltage experimental profiles, respectively. Concerning the microbial population, the profile of the concentration for the electricigenic bacteria (dotted line in Fig. 5B) showed a population decrease during the low influent concentration while attaining a plateau during substrate replete conditions. The profile for the methanogenic microorganisms remained negligible during the duration of the simulation, probably due to operational conditions favoring growth of the electricigenic bacteria [23]. Additionally, the model provided an adequate description of the short-term output voltage during pulse-width modulated connection of R ext, as shown in Fig. 5c. The concentration of oxidized mediator increased during the short-term closed circuit period and decreased otherwise. This behavior is understandable since during open circuit operation the concentration change of the oxidized form of the intracellular mediator indicates an accumulation of charge within the electricigenic bacteria (biofilm) in the anodic compartment.

Fig. 5
figure 5

A comparison of acetate (a) and MFC voltage (b) experimental values with the calculated profiles obtained using the “off-line” model. Fast-changing concentration of M ox (dotted line) and the corresponding V cell profile are shown for day 48.0 (c)

In addition to estimating parameters of the “off-line” model, two parameters (Y and µ max,e) were estimated to demonstrate the “on-line” mode of CBE model application, as described in Fig. 2. The “on-line” model requires values of R int, E ocv, and C to be estimated based on the output voltage measurements, e.g. during R-PWM operation. Following the estimation procedure described above, Y and µ max,e values were estimated to be 41.18 mg M mg S−1 and 3.59 day−1, respectively. Figure 4 shows the corresponding 95 % confidence ellipse for these two parameters. In this case the two parameters were non-correlated with the Pearson’s correlation coefficient being close to zero, thus the ellipse of confidence was almost parallel to the horizontal axis. Also, with a 95 % confidence level, the intervals of confidence for Y and µ max,e were 10.8 and 0.43 %, respectively.

Figure 6 compares the measured values of voltage and acetate concentration with the corresponding outputs of the “on-line” model. As expected, the “on-line” model provided a better fit of the experimental data points, with MSE values of 0.008 and 0.005 for acetate and voltage estimations, respectively (Fig. 6a, b). As compared to the “off-line” model, the output voltage estimations were particularly improved (Figs. 5b, 6b), while the acetate estimations were comparable between the two models. Overall, the “on-line” model proved to be more accurate, in particular, at high values of the influent acetate concentration.

Fig. 6
figure 6

A comparison of acetate (a) and MFC voltage (b) experimental values with the calculated profiles obtained using the “on-line” model. Fast dynamics of MFC voltage during R-PWM operation is given for day 48.0 (c)

Anode capacitance impact on MFC performance

In several recent studies, internal MFC capacitance was exploited to develop novel power management methods [25, 26]. In one approach, by periodically disconnecting the MFC from an electrical load, energy was internally stored and then released to enable a power output burst [16, 18]. This approach can be used to resolve the problem of mismatch between the external and internal resistances. Significant power losses occur when the internal and external electrical resistances do not match [27]. Furthermore, MFC operation at external resistances below the internal resistance may lead to near permanent loss of performance, including voltage reversal [28]. A more traditional approach to overcome these power losses uses a real-time optimization method which seeks an external resistance that maximizes the power output [29]. On the other hand, recent efforts in on-line power output optimization demonstrated that the stability issue can be addressed by MFC operation with periodic connection/disconnection of the external resistance, R ext, [16]. In one study, stable power output was observed at various organic loads during MFC operation with pulse-width modulated R ext connection [16]. Thus, this approach overcomes significant power losses during perturbations in the input substrate concentration.

Figure 7 uses the CBE “off-line” model to compare different power management approaches. In this simulation, MFC is assumed to be initially operated at a constant influent carbon source concentration followed by a concentration decrease of 50 %. The three approaches for the operation of the external resistance include using: (1) the perturbation-observation (P/O) algorithm that searches for the optimal R *ext resulting in maximum power output; (2) a fixed external resistance, and (3) an R-PWM operation with a duty cycle of 95 % (the average power output per cycle is shown). The value of the duty cycle was manually selected such that the power produced with a frequency of operation of 100 Hz was as high as possible. The P/O algorithm was simulated following the same operational conditions as in [29] with a perturbation of 2 Ω every 1 min.

Fig. 7
figure 7

MFC power output estimated for three modes of operation (optimal R *ext calculated using perturbation/observation algorithm, fixed R ext, and R-PWM operation at a duty cycle of 95 %). A 50 % decrease in the influent concentration was imposed at t = 2 h

Clearly, keeping a constant external resistance results in a severe drop in the power produced once the influent carbon source concentration decreases. The P/O algorithm closely follows changes in R int by adjusting the external resistance thus avoiding such a sharp drop in the MFC power output. Notice that while during the R-PWM operation the R ext value remains unchanged at all organic loads, the R-PWM operation with a duty cycle of 95 % shows a performance closer to the power output obtained by the P/O algorithm. Meanwhile, R ext value is the same as in the simulation with the fixed resistor value (Fig. 7). These simulation results agree with the experimental comparison of R-PWM and fixed resistor MFC operation described in [18].

Conclusion

This work presents a combined bioelectrochemical–electrical (CBE) model that takes into consideration the internal capacitance and the nonlinear dynamics of MFCs populated with electricigenic and methanogenic populations. Two approaches for model application were considered. In one approach, model-based simulations required all parameters of the model to be known apriori (e.g. estimated based on the existing experimental results). This “off-line” approach enables a variety of applications such as reactor design, optimization of operating conditions, etc. An alternative approach requires MFC output voltage to be known or measured in real time thus enabling on-line estimation of certain electrical parameters of the model (E OC, C and R int). While in this approach the model can be only applied to the existing data set or used to accompany an actual process, it provides a better fit, while predicting process variables not measurable in real time, such as effluent carbon source concentration. Both approaches showed acceptable accuracy when describing both fast and slow dynamic behavior, while also being able to adequately predict the output substrate concentration. Since on-line measurements of the output substrate concentration are typically unavailable, the CBE model presents a step forward in developing software sensors for on-line MFC monitoring as well as for developing model-based process control strategies.