On a Robust and Efficient Numerical Scheme for the Simulation of Stationary 3-Component Systems with Non-Negative Species-Concentration with an Application to the Cu Deposition from a Cu-(β-alanine)-Electrolyte

Three-component systems of diffusion–reaction equations play a central role in the modelling and simulation of chemical processes in engineering, electro-chemistry, physical chemistry, biology, population dynamics, etc. A major question in the simulation of three-component systems is how to guarantee non-negative species distributions in the model and how to calculate them effectively. Current numerical methods to enforce non-negative species distributions tend to be cost-intensive in terms of computation time and they are not robust for big rate constants of the considered reaction. In this article, a method, as a combination of homotopy methods, modern augmented Lagrangian methods, and adaptive FEMs is outlined to obtain a robust and efficient method to simulate diffusion–reaction models with non-negative concentrations. Although in this paper the convergence analysis is not described rigorously, multiple numerical examples as well as an application to elctro-deposition from an aqueous Cu2+-(β-alanine) electrolyte are presented.


Introduction
Diffusion-reaction equations play a central role in the modelling and simulation of chemical processes, as the corresponding system describes the transport of multiple species w.r.t. diffusion and a single reaction. The modelling of processes in the interior of lithium-ion batteries, complexation of metals during electro-plating, the electrical potentials in neurons, diffusion in sensors, etc., are major examples for the usage of three-component systems.
While the classical models in the literature of the speciation and modelling of metalions, cf. [1][2][3][4][5][6], are not considering non-negative species-concentrations, this paper aims at a model respecting non-negative species distributions in a simple case and their numerical treatment in a more general setting. This is motivated by the fact that negative species concentrations are unphysical and may and will most likely lead to false conclusions from simulated data.
The numerical strategy, which is discussed in this article, is based on the reformulation, as discussed in Section 2, of the model equations into a constrained minimization problem in which the positive concentrations are part of the model formulation. The respective mathematical model that is used in this article is an optimization problem of the obstacle type, which is well known in physics and numerics c.f. [11][12][13].
In this article let Ω ⊂ R d , for d ∈ {1, 2}, be an open, bounded, connected domain with Lipschitz boundary. Furthermore, let the boundary ∂Ω, be split into a Dirichlet boundary ∅ ≠ Γ D ⊆ ∂Ω and a Neumann boundary Γ N ⊂ ∂Ω, such that Γ D and Γ N are relative open w.r.t. the restriction topology, Γ D ∩ Γ N = ∅ and for the topological completion of Γ N ∪ Γ D one assumes the identity Γ N ∪ Γ D = ∂Ω.
During this article, reactions in the following form will be considered: As is known, cf. [1][2][3][4]7], the concentrations of the species A, B, C are formulated, in the stationary case, as a system of ODEs, for d = 1, and a system of partial differential equations in multiple space dimensions, i.e., for d > 1, which is for f A , f B , f C ∈ L 2 (Ω), for g A,D , g B,D , g C,D ∈ L ∞ (Γ D ), and for g A,N , g B,N , g C,N ∈ L ∞ (Γ N ), given through the following system of equations in Ω, Note that, by L 2 (Ω), in this article, the Hilbert space of square integrable functions is denoted, with scalar product (•, •) L 2 (Ω) ∶ L 2 (Ω) × L 2 (Ω) → R and induced norm • L 2 (Ω) ∶ L 2 (Ω) → R, c.f. [36,40]. Furthermore, the Banach spaces L p (Ω) with associated norms • L p (Ω) , will be considered. As can be seen, the straight-forward formulation given by the Equation (2a)-(2e) does not contain a condition of the non-negativity of the concentrations c S , with S ∈ {A, B, C}. This missing formulation of non-negative species distributions will actually lead to unphysical behavior in the computation results. Hence in the following section, the usual approach to reinforce non-negative species distributions will be discussed.

Reinforcing Non-Negative Species Distributions
Assuming the system above has a unique solution, one obtains that the solution of the system (2a)-(2e) can be identified, for p S = ∇c S , with the solution of the following minimization problem: Find (c S,LS , p S,LS ) S∈{A,B,C} ∈ X, such that where X is a Banach space, which will be defined later, and the non-linear least-squares functional LS (v S , q S ) S∈{A,B,C} is given through the following identity: For the last terms of the least squares functional above, one has to note that the space L ∞ (Ω) is continuously embedded into the space L 2 (Ω) and, hence, the evaluation of the terms c S − g S,D 2 L 2 (Γ D ) and ∇c S ⋅ ν Γ N − g S,N 2 L 2 (Γ D ) are formally correct and simplify the calculations needed to implement a corresponding solver.
In the following, the space X has to be fixed. The space X is defined s.t. the non-linear functional LS (v S , q S ) S∈{A,B,C} is well defined, for each element (v S , q S ) S∈{A,B,C} ∈ X.
The reformulation discussed in this article is to introduce the positivity of c A , c B , c C as side condition, cf. [11,41].
where the non-linear least-squares functional LS (v S , q S ) S∈{A,B,C} is the same as in (3).

Numerical Scheme
This section is devoted to the construction of a robust numerical scheme to approximate a solution to (4). This section provides an outline of the numerical scheme and ommites the proof of convergence. In contrast to [5,42] no finite-difference scheme will be discussed, but a finite-element discretization, which allows for us to employ augmented Lagrangian methods, cf. [25,26], on the continuous level of the model.
In this section, a numerical scheme for a generalized problem in the form (3) will be discussed, by adding additional reaction terms γ S c S . The respective generalized leastsquares functional is given through In contrast to the usual numerical schemes, as described above, the current augmented Lagrangian methods work on the continuous level of the problem. Applying the algorithms given in [26] and in [25] to (4) yields the following Algorithm 1:
The augmented Lagrangian algorithm leaves the unrestrained minimization problems (5) to approximate. As a first step, (5) will be discretized. The essential key to discretize (5) is the discretization of the space X. In this paper a conforming discretization of X was chosen, by choosing a finite-dimensional subspace X h ⊂ X. The choice of X h will be discussed in the following.
Let T , in the respective dimension, be at first, an arbitrary fixed triangulation of Ω. The index h of the finite dimensional space X h refers to the diameter of T , which is in one space dimension the maximal length of an interval T ∈ T and in two, the length of the longest edge in the set of edges E.
For d = 1, the discrete (finite dimensional) space X h ⊂ X is constructed by the lowest order conforming discretization S 1 (T ) ⊂ W k,p (Ω), where S 1 (T ) is the space of affine splines that is defined by cf. [43]. Hence, in this paper, the discrete space S 1 (T ) ×6 =∶ X h ⊂ X is used as discretization. For d = 2, the vector space affine splines S 1 (T ), defined analogous as before as are used as a conforming discretization of W k,p (Ω), cf. [27,28,30], and the Raviart-Thomas elements given by as discretization of H(div, Ω). Hence, in this paper, the lowest order discretization X h ⊂ X, will be discussed, which is given by This leaves the following discrete problem to solve or to approximate: As a fundamental step of the numerical scheme, a linearization of (8) is introduced. For this, a few calculations are necessary. First, remark that, in contrast to the non-linear functional LS (v S,C , q S,RT ) , the functional LS α (v S,C , q S,RT ), µ is, for α > 0, not differentiable. The non-differentiability lies in the evaluation of the function µ − v S,C + . Hence, for the linearization of µ − v S,C + , one has to use a different notion of differentiability than the common Fréchet-differential. Therefore for the linearization of µ − v S,C + in this article, the convex subdifferential ∂ cvx as defined, c.f. [44], was used. For a convex function f ∶ Y → R, for a Banach space Y, its topological dual Y * , and the dual pairing ⟨•, •⟩ Y * ,Y , cf. [40], in a point y 0 ∈ Y is given through As it is commonly known, the subdifferential ∂ cvx µ S − c S (•) + is for almost all x 0 ∈ Ω and all S ∈ {A, B, C}, given through Furthermore, for c A,h , c B,h ∈ S 1 (T ) and arbitrary fixed v A,h , v B,h , the following Taylor approximation is considered An additional approximation of c S,h , for S ∈ {A, B}, is made through In the notation above, the map, Π 0 ∶ L 2 (Ω) → P 0 (T ) denotes the orthogonal L 2projection onto the space of piecewise constant functions, which is given through: i.e., for all f ∈ L 2 (Ω), the image of Π 0 f is given as the solution of the following minimization problem, cf. [30]: Furthermore, for f ∈ H 1 (Ω), due to the Poincaré inequality, cf. [40] or [30], there exists a constant 0 < c, such that where the equality results from the pythagorean theorem, [40].
The identities (9), (10), and (12) inspire the following quasi-Newton scheme given, for a starting value x 0 ∈ X h , through the iterative solution of the following minimization problem: Find c where furthermore for a subset B ⊂ Ω, the map χ B ∶ Ω → [0, 1] is given by As it can directly be seen, the inclusion χ A (n−1) (x) ⊆ ∂ cvx µ S − c S (•) + (x) holds true. As it is commonly known, cf. [17,45,46] Newton and quasi-Newton schemes tend to be unstable. One strategy, as described in [46], is to use stabilized quasi-Newton methods based on a coupling of a quasi-Newton method with a subgradient scheme, on a not linearised problem. Another option, which is used and implemented for the numerical examples, as discussed in the Sections 4 and 5, are homotopy methods, cf. [31,32], which is a scheme for the solution (13), based on the iterative transformation of a system with known solution into the non-linear system associated to (13). The homotopy methodology is probably the easiest way to stabilize the numerical strategy and increase the robustness.

Remark 2.
The strategy refereed to as quasi-Newtonian scheme is in fact a disturbed variant of a 'normal' quasi-Newtonian scheme. The difference between the 'normal' quasi-Newtonian scheme and the quasi-Newtonian scheme discussed in this paper is the application of the projections Π 0 . The sequence that is generated by the corresponding quasi-Newtonian scheme is denoted by y (k) .
Some notations are needed to describe the used transformation. First, let, for M ∈ N, the following discretisation of the interval [0, 1] be given through 0 = t 1 ≤ . . . ≤ t j ≤ . . . ≤ t M = 1. Subsequently, a homotopy method is given by the solution, for 1 ≤ j ≤ N, by computing the following Algorithm 2:
and break if and for all (v S,h , q S,h ) S∈{A,B,C} ∈ X h , the linear functional LS α (v S,h , q S,h ) S∈{A,B,C} ; T , n, j is given by S2: If (14) converges for n → ∞, go to S3 else refine the decomposition 0 ≤ t 0 ≤ . . . ≤ t M = 1, set j = 0 and go to S1. S3: If t j = 1 break the loop, else set j = j + 1 and go to S1.
The usage of the homotopy-algorithm, as described above, yields a cost-intensive numerical scheme. Hence, the usage of adaptive schemes for (5) is the best choice at hand to treat the iterate problems. Adaptive schemes in the homotopy steps are possible, but not implemented for this paper.
Adaptive FEM is used as the last step of the numerical scheme. As described in [24,47,48] the adaptive scheme is given through the following Algorithm 3:

Algorithm 3: AFEM-loop
Input : Initial regular triangulation T 0 , system parameters, set j = 0. Output : Fine mesh T , approximate limit of the solutions to (13), estimation of the error. The adaptive FEM algorithm is given by the following steps: S1: Solve: Take the limit of the solutions iterated problems (13), approximated through Algorithm 2. S2: Estimate: Estimate the error of the current discrete problem on each element T ∈ T j with an estimator η. S3: Break: If the triangulation is fine enough or the estimated error is lower than a given Tolerance, then break the condition. S4: Mark: Mark the elements of the triangulation T ∈ T j with the highest estimated local errors. S5: Refine: Refine all marked elements and additonal elements, such that the result T j+1 is again a regular triangulation. S6: Set j = j + 1 and go to S1: At the end of the section, a few remarks have to be made: Remark and Definition 1 (Used setup of the AFEM-Algorithm for this paper). Note that: (i) In S2 of Algorithm 3, an estimator is evaluated on each element T ∈ T j , which has to be defined.
Assuming that for the exact solution (u LS,S , p LS,S ) S∈{A,B,C} ∈ X of (3), the equality LS (u LS,S , p LS,S ) S∈{A,B,C} = 0 (15) holds true. In this paper, the estimator σ ∶ T → R ≥0 and the discrete solution of the discrete solution from S1: of Algorithm 3, for α = 0 and µ ≡ 0, is defined as LS,S ) ∈ X of (5), in the iteration j ∈ N, for given α j and µ (j) , one cannot expect the identity to hold true, since a solution of (5) is in general not a solution to a system of non-linear equations. Hence, the usage of LS,S,h T , p LS,S,h ) S∈{A,B,C} of the discrete problem of S 1 of Algorithm 3, is not practical. In the spirit of the usage of adaptive schems an estimator τ, basing on ρ, is used, which gives an estimation on the local changes w.r.t. the elements T ∈ T of the evaluation of ρ. For the definition of a practical estimator let for an arbitrary fixed T ∈ T the element patch T (T) be given through Afterwards, the new estimator σ is given through: (iii) A common strategy, used for the marking is the so-called Dörfler marking, cf. [49]. In this strategy, a set M is chosen for which, τ 2 ∈ {η 2 , σ 2 , ρ 2 }, for a given bulk parameter θ ∈ [0, 1] the inequality holds true. (iv) Note that the Dörfler marking implies for θ = 1 a simple uniform marking scheme.
(v) As discussed in [50,51], one can usually prove convergence of the adaptive scheme by using, as in this article, the least-squares functional as error estimator, but cannot expect optimal convergence rates as discussed in [24] or [47]. Hence, another error estimator has to be derived for which optimal convergence rates are provable.
With the remark and definition above, the numerical scheme is completed. The numerical validation will be made in Section 4, the numerical scheme will be validated.

Remarks on Existence and Convergence Theory to the Numerical Scheme
This subsection is devoted to a first discussion of some fundamental convergence and existence properties of the algorithm and the underlying optimization methods. The discussion in this section is incomplete, but it gives an important first glance at the theoretical background of the algorithm.

Notes on the Existence Theory
In this section, some theoretical notes on the existence theory will be given. While the existence theory in one space dimension, thanks to the ODE theory and, in particular, thanks to the theorem of Picard-Lindelölf, cf. [35], and for linear PDEs is well known, cf. [33], the existence theory for nonlinear PDEs is, in most of the cases, not known, cf. [34]. The following discussion only tangents the cases known in literature.

Remark 3 (The 1d-case).
In this remark, a the 1d case will be discussed.
(i) The system of second order ODEs, as given by (2a)-(2e), can equivalently reformulated into a System of first order ODEs, which are uniquely solvable due to the theorem of Picard-Lindelölf, cf. [35]. (ii) The assertion in (i) gives directly the solvability of (3)-(5), due to the fact that in the derivation of the least squares functional exactly the needed first order reformulation was used, which was needed for the assertion.
After the remark above on ODE theory, a further remark on the linear PDE theory will by given: Remark 4 (The linear 2d-case). In this remark, the discussion of linear variants of (2a)-(2e) will be treated. i.e., during this remark k 1 = 0 is assumed. In this case the continuous space X can be extended to X = H 1 (Ω) × H(div, Ω) 3 , which makes the theory reasonable easier since in this case X is an Hilbert space.
(i) First, similar as in [52], the case of minimal assumptions to the problem formulation will be discussed. Essentially one assumes 0 < D A , D B , D C and the injectivity of the linear operator . For this, one assumes that k 2 , γ A , γ B and γ C are assumed to be chosen in a way that 0 is no eigenvalue of L. Indeed, the injectivity, i.e., there is no 0-Eigenvalue of the corresponding operator, assumption together with the assumption of the existence of solutions for given f A , f B , f C ∈ L 2 (Ω), gives the unique solvability due to Fredholm's alternative, cf. [53]. The results above directly apply to the PDE equation that is given by and one obtains unique solvability of (19a)-(19h). The corresponding Operator is denoted by This solvabllity of (19a)-(19h) directly implies the unique solvability of (3). (ii) Note that in (i) only necessary conditions for the unique solvability are discussed. Some sufficient conditions can be obtained by the decoupling of the PDE. Where in fact the sufficient conditions for the unique solvability can be obtained by sufficient conditions to scalar Diffusion reaction equations, cf. [33,54]. (iii) By some standard calculations, as given in e.g., [19,28], one obtains that x * ∈ X solves (3) if the first order optimality in form of the Euler-Lagrange equations is fulfilled, which is given by the following equation: Find x * ∈ X such that for all y ∈ X the following equation holds true: Note that, due to the unique solvability of (3) and the problem equivalence described above, one obtains the unique solvability of (20). (iv) From the unique solvability of (3), c.f. (i) and (iii), it directly follows, cf. theorem 3.6 on page 120 in [30], that the bilinear form a(•, •) ∶ X × X → R is elliptic. (v) From the ellipticity of the bilinear form a, cf. (iv), one directly obtains the unique solvability of (4).

Notes on the Convergence Theory
In this section, a few notes on the convergence theory will be made. Although a proof of convergence of the solutions to the discretisation of (5), will be given in this section, the convergence analysis will be incomplete. For the rest of the necessary convergence theorems, some notes on what to be shown will be given.
First, some remarks on the quasi-Newtonian scheme, as given by the iterative solution of (13) and the Homotopy loop will be made. The remark below gives a sketch of the proof of convergence of the discussed quasi-Newtonian scheme. A mathematical rigorous proof has to be given in a future paper.

Remark 5. (i) First note that the least squares functional LS
Recall that the Notion of Fréchet derivatives yields that for given x ∈ X and for all 0 < ε, there exists a 0 < δ, such that This yields that there exists a constant 0 < c, such that for a solution x (n) h ∈ X of (13) the following estimate holds true, if the initial value x 0 ∈ X h is sufficiently close to the exact solution to (8): As discussed in Remark 2, a direct application of a classical quasi-Newtonian scheme to (8) yields a convergent sequence (y n ) ⊂ X h , if the initial value y 0 is sufficiently close to the solution x * h ∈ X h to (8) and it follows with inequality (21), the convergence of x h ⊂ X h and the inequality (21), indicate that there exists a constant c 1 > 0, such that for initial values y (0) sufficiently close to the solution x * h of (8) and the initial value x (0) h are sufficiently close to the limit of the quasi-Newtonian scheme, the following inequality holds true: It directly follows (ii) The discussion (i) indicates that the quasi-Newtonian scheme described by the iterative solution by (13) has the same issue with stability as classical quasi-Newtonian schemes, cf. [17]. To stabilize the quasi-Newtonian scheme, it was coupled to a homotopy method, cf. [32]. As already discussed, the idea of the method is to solve for a continuous function T , n and a decomposition 0 = t 0 < . . . < t j < . . . < t M to solve the minimization problem that is given by: As a solution step, the quasi-Newtonian scheme (13) can be used. For j = 0, an initial value x 0 for the algorithm is given through x 0 and for j > 0 the x is given as an initial value for the quasi-Newtonian scheme.
In the following lemma, a theoretical statement will be proven, which will be essential for the proof of a simple convergence result for solutions of (8).
For the proof of the following Lemma, recall the Γ-convergence. As defined in [36][37][38][39], a sequence of nonlinear functionals F n ∶ X → R is said to Γ-converge to a functional F ∶ X → R if the following two conditions are fulfilled: (i) For every sequence (x n ) ⊂ X, with x = lim n→∞ x n , the following inequality holds true: (ii) For every x ∈ X, there exists a sequence (x n ) ⊂ X with x = lim n→∞ x n , such that the following inequality holds true: Lemma 1. Let T n be a sequence of tirangulations with h n ↓ 0, where h n denotes the diameter of T n , which fulfills 0 = lim n→∞ h n , as well as that T n+1 is a refinement of T n , i.e., the set of nodes N n of T n is included in the set of nodes N n+1 of T n+1 , i.e., N n ⊂ N n+1 , then the sequence F n ∶ X → R given through, Γ-converges to F ∶= LS α j (x, λ (j) ). In the notation above, δ n is given through the following definition: Proof. To prove the Γ-convergence of the sequence (F n ), the assertions (24) and (25) have to be proven.
(i) ad (24): for the proof of this claim one needs to distinguish two cases. However, first, let x ∈ X and x (k) ⊂ X with x = lim k→∞ x (k) be arbitrary fixed.
(a) First, assume that up to finitely many n ∈ N one has ¬(x n ∈ X h n ). From the definition of F n it follows then that, up to finitely many n ∈ N, the lowest accumulation point of the sequence F n (x n ) = +∞. Hence, one obtains the following inequality: The inequality above shows the assertion for this case.
For the second case, assume that there are infinitely many n ∈ N, such that x n ∈ X h n . Subsequently, there exists a subsequence (x n l ) ⊂ (x n ) with Because of the continuity of F and the definition of F n , it follows: The equalities above yield that the claim for the second case holds true.
The discussion of the two cases above proves the claim. (ii) ad (25): first, note that, for all n ∈ N, one has a continuous embedding [19,[27][28][29]. Similarly, one has a continuous embedding RT 0 (T ) ↪ H(div, Ω) furthermore ⋃ n→∞ RT 0 (T ) is a dense subset of H(div, Ω), c.f. [19,[27][28][29]. From the definitions of X h and X, it follows with the both densities, where ⋃ n→∞ X h n is a dense subset of X. From the assumptions on the sequence T n and the density of ⋃ n→∞ it follows that there exist, for all x ∈ X, a sequence with x n ∈ X h n s.t. x = lim n→∞ x n . Furthermore, it follows from the continuity of F and the definitions above: The equalities above prove the statement.
From (i) and (ii), the claim of the Lemma follows by definition.

Corollary 1.
Let T n be a sequence of triangulations fulfilling N n ⊂ N n+1 and h n ↓ 0 as n → ∞, then the following two statements hold true: (i) Let (y (n) ) h n ⊂ X, be the sequence of minimizers of (8) generated by the usage of X h n as discrete subspace X h n ⊂ X in the problem formulation of (4), then every accumulation point of (y h n ⊂ X be the sequence of limits of the sequences that are generated by the solution of (13) on the triangulations T n , then every accumulation point of the sequence x (n) h n is a minimizer of (4).
Proof. Let the sequences T n , (y (n) ) h n ⊂ X, x (n) h n ⊂ X be given, as stated in the corollary. (i) A common result in the context of Γ-convergence, c.f. in [36][37][38][39], is that if G n ∶ X → R Γconverges to G ∶ X → R then every accumulation point of the sequence of minimizers (x n ) n∈N , i.e., x n minimizes G n , is a minimizer of G.
Applying this theoretical result to the setup of Lemma 1, one obtains the statement in the corollary. (ii) The statement of the lemma directly follows by (i) and by (22). Remark 6. (i) The convergence proof above is a first result underlining the plausibillity of the described discretization of (5). But first note that from the proof of convergence above no rates of convergence can be obtained. From the classical theory, cf. [19,[27][28][29], convergence to a certain rate seems to be a valid hypothesis, at least for the linear cases of the PDE (2a)-(2e), cf. [14,15,19]. (ii) Note that convergence of the sequence of limits (13), will only be obtained if one accumulation point of x h k exists, this is fulfilled if (5) is uniquely solvable.
With this result, this section will be concluded. For future discussions, the following discussions have to be made:

1.
The stability and the convergence of the augmented Lagrangian Algorithm 1 is proven in [25,26], to prove stability and the convergence of Algorithm 1 for the case that is considered in this article the assumptions of the corresponding theorem in [25] have to be verified.

2.
The convergence of the quasi-Newtonian scheme (13) has to be discussed in a much more rigorous way than done in Remark 5.

3.
Convergence to a certain rate has to be verified for the discretization of (5).

4.
As known to the authors, the existence theory, as described in Section 3.1.1, is for the problem (2a)-(2e) incomplete. A careful study of sufficient and necessary condition has to be made.

Numerical Examples and Validation of the Software
In this section, multiple numerical experiments are treated to validate the robustness and the functionality of the numerical scheme. In all three subsections, the numerical examples that are given through the parameters in the Tables 1-3 and let Γ D = ∂Ω and g A,D = g B,D = g C,D ≡ 1. Afterwards, the functions f A , f B , f C ∈ L 2 (Ω) are given through As breaking conditions for the simulations, in this subsection, the fulfillment of the following conditions were set: 1.
The number of nodes in the current mesh increases 10, 000 nodes. 3.
More than 100,000 iterations of the augmented Lagrangian algorithm were performed. Before the numerical examples are discussed, note that the exact error is given through: Simulating the unrestrained problem (3), for the the given RHS, as defined above, for the parameters that are defined in the Tables 1-3, with the reduced numerical scheme, see Remark 1, one obtains approximations of the defined exact solution (27). For a number of 10, 000 DoFs, one obtains the results that are shown in Figure 1, which were simulated for the parameters defined in Table 1. Because no visible difference to the other experiments can be seen, Figure 1 will be the only given pictures of approximate solutions to (3) in this section.
Furthermore, note that, for the simulations, the following setup was chosen: For all simulations of the 'classical' concentration-profiles, with no restrictions on the positivity of the concentrations, the reduced method, as described in Remark 1, was used. Furthermore, in all cases of simulations of (3), the estimtor η was used. For the adaptive refinement of (5), the practical error estimator σ was used for all approximations of solutions of (5). Furthermore, for all adaptive refinement Dörfler marking, cf. Remark 1, was used as marking strategy with common bulk parameter θ = 0.5.
The first example that will be discussed in the following in more detail is given by the parameters in Table 1. As mentioned before, Figure 1 provides the simulations with a minimum number of 10 4 nodes in the AFEM loop as breaking-condition.
By the evaluation of the error estimators for this example, cf. Figure 2, one can observe convergence of the estimators, except for the practical estimator σ for the uniform refinement. As expected, the rest of the estimators are parallel, from which the equivalence of estimators can be formulated as a conjecture.  (3), for the parameters that are given in Table 1. In Figure 3, some iterations of the augmented Lagrangian scheme with uniform refinement are shown. The augmented Lagrangian scheme needed 85 steps to obtain non-negative species distributions. The augmented Lagrangian scheme converges to set a non-negative species distributions for this example, as shown in the subfigures (a), (d), (g).
Furthermore, as predicted in Remark 1, the localized evaluation of the least-squares functional, which is given by the estimator η, does not converge to zero in all examples. In this case, for the uniform refinement, the practical error estimator converges lim h↓0 σ = 0.
Additionally, this example also shows the convergence of the multipliers µ A , µ B , and µ C as well, which also seems to converge.
The parameter α grows exponentially over the iterations of the augmented Lagrangian algorithm, as shown in the Figure 4.
In Figure 5, the development of the augmented Lagrangian algorithm is shown, applying the adaptive algorithm in each iteration of (5). The augmented Lagrangian algorithm takes, like for uniform mesh refinement, 85 iterations to guarantee non-negative species distributions, as can be seen in this case. Just observing the discrete solutions c A,h , cf. Figure 5a, c B,h (d), and c C,h (g), and the Lagrangian multipliers µ A (b), µ B (e), and µ C (h), one obtains the same result as for the uniform refinement. The limit of the solutions seems to be identical, but the interesting aspect is the estimators, which are given in the subfigures (c), (f), and (i). The practical errors σ seem to converge to a value b ≠ 0, as well as the estimators η do, as expected to a value a ≠ 0.  Table 1 and uniform mesh refinement. The development of the parameter α for the augmented Lagrangian algorithm with adaptive mesh refinement is similar to the development of the augmented Lagrangian algorithm with uniform mesh refinement. No further pictures are given due to the fact that no differences are visible between the developments of α with uniform or adaptive mesh refinement.
The second example that is discussed in this section is given by the parameters shown in Table 2. In Figure 6, the convergence graphs for the approximation of the solution (3), for the given parameters, are shown. In this setting, the evaluation of the least squares functional η for uniform and adaptive refinement are shown, as well as the exact error for uniform and adaptive refinement and the practical error σ again for uniform and adaptive refinement are given. The corresponding graphs are, at most, parallel and show the same behavior and indicate convergence of the numerical scheme for the simulation, as can be seen in Figure 6. The graph indicates that the estimators could be equivalent for the simulation.   Table 1 and adaptive mesh refinement. Figure 6. Developement of the error estimators for the uniform and adaptive mesh refinement, for the approximation of (3) with the parameters given in Table 2.
Applying the augmented Lagrangian Algorithm 1 onto (4) with the parameters that are given in Table 2 and applying uniform refinement on the mesh, T one obtains, after 89 iterations of the augmented Lagrangian scheme, non-negative species distributions, as seen in Figure 7.
The estimator η converges not to 0 in each iteration of the augmented Lagrangian method, as expected, but the practical estimator does converge to 0 in each iteration, as can be seen in Figure 7.  Table 2 and uniform mesh refinement.
In Figure 8, the application of the augmented Lagrangian algorithm is shown for multiple iterations with the application of adaptive mesh refinement, as described above. The algorithm needed, as for treating the iterate problems with uniform refinement, 89 iterations.
As it can be seen, the algorithm outputs non-negative species distributions. In principle, equivalent results in the output can be seen in Figure 7. However, the principal behavior of the practical error estimator differs while using adaptive schemes from the same methodology but using uniform mesh refinement. The estimator η, cf. remark and Definition 1, converges, but not to 0, as expected, while the convergence of the practical error σ seem to also be given, as can be seen in Figure 8c,f,i.  Table 2 and adaptive mesh refinement.
The developments of the parameter α during the augmented Lagrangian algorithm are for the adaptive and uniform refinement identical for linear reaction terms and they are very similar to the development for the pure diffusive case given in Figure 4.
The third example that is discussed in this section is given by the parameters in Table 3. The discrete solutions to (3) w.r.t. the parameters above are close to identical to the discrete solution given in Figure 1, as discussed previously. In fact no differences are visible. Hence, the corresponding figure will not be displayed in this paper.
The evaluation of the error estimators, which are defined in remark and Definition 1, cf. Figure 9, are yielding that the numerical scheme converges for both the uniform and adaptive refinement scheme. Furthermore, it is shown in Figure 9 that the localized evaluation of the non-linear least-squares functional, as beforehand η, seems to be equivalent to the exact error for uniform and adaptive refinement. Furthermore, up to a value of approximately 10 4 DoF, the corresponding practical estimators σ are decreasing for uniform and adaptive refinement. At this stage, the convergence of the numerical schemes is given from a practical viewpoint. Figure 9. Development of the error estimators for the uniform and adaptive mesh refinement, for the approximation of (3) with parameters given in Table 3.
Applying the augmented Lagrangian algorithm, cf. Algorithm 1, to (4) with the parameters that are given in the Table 3 and applying uniform refinement, one obtains non-negative species distributions after 89 iterations of the augmented Lagrangian scheme, c.f. Figure 3. Furthermore, it is observable that the practical error estimator η, cf. definition and Remark 1, converges, but not to 0 in each setting. Furthermore, it is observable that the practical σ, cf. definition and Remark 1, converges to zero for each iteration.
Applying the augmented Lagrangian algorithm to (4) with the parameters that are given in Table 3 and applying adaptive mesh refinement to the iterative defined problem (5), one obtains the results given in Figure 10. The iterates converge to a species distributions with non-negative species concentrations, as seen in the corresponding figure. After 89 iterations, non-negative species distributions are obtained. Furthermore, it is visible that the estimator η, cf. remark and Definition 1, that is based on the piecewise evaluation of the corresponding least-squares functional converges, but not to 0. In contrast to the setting shown in Figure 11, the practical error σ, cf. remark and Definition 1, one obtains convergence, but not to 0, as beforehand.  Table 3 and uniform mesh refinement.  Table 3 and adaptive mesh refinement.
The developments of the parameter α during the augmented Lagrangian algorithm for the adaptive and uniform refinement are identical for the full reaction terms and they are very similar to the development for the pure diffusive case, as given in Figure 4, also in this case, a figure is not given in this paper.
As a remaining part of the discussions to the 1d examples, a comparison of the CPU running times of the different examples will be discussed. One observes that, for the given examples, the number of iterations of the augmented Lagrangian algorithm do not differ between uniform and adaptive mesh refinement, as seen in Table 4. However, one sees, in Table 4, that the usage of the adaptive algorithm is far more efficient than the usage of the uniform refinement. Especially for the nonlinear system of ODEs, as described by the parameter set given in Table 3, a massive reduction of computation time was obtained. Table 4. Overview of number of iterations of the augmented Lagrangian Algorithm 1 and CPU times for the different parameter sets and uniform resp. adaptive mesh refinement.

Parameter Set
Type of Refinement Number of Iterations CPU-Time Table 1 Uniform 85 4.3157e + 04 s Table 1 Adaptive 85 1.0347e + 04 s Table 2 Uniform 89 5.0281e + 04 s Table 2 Adaptive 89 9.9426e + 03 s Table 3 Uniform 89 2.0356e + 05 s Table 3 Adaptive 89 4.7214e + 04 s All together, one can conclude that the numerical scheme works for the given scheme and examples. Because of the fact that no rigorous proofs are done in this paper, the convergence remains as conjecture, based on the numerical results in this section.

Examples in 2d
In this section, two examples will be discussed for the parameter sets that are given in the Tables 1 and 2. For the treatment of the augmented Lagrangian algorithms, the same parameters were used as before. Furthermore, in every numerical example in this section, the estimators η and σ from remark and Definition 1 were used. Furthermore, note that the refinement algorithms that were implemented in [55] were used to treat the examples of the adaptive scheme.
For the numerical examples in 2d, similar breaking conditions on the algorithms were set: 1.
The breaking condition from S3 in Algorithm 1 is fulfilled with a tolerance ε ∶= 10 −4 .

2.
The number of nodes in the current mesh increases 1000 nodes.

3.
More than 100,000 iterations of the augmented Lagrangian algorithm were performed.
In contrast to the examples in 1d, a lower number of nodes was used as breaking condition for the refinement algorithm.

Examples on a Convex Domain
Similar to Section 4.1, non-trivial examples will be discussed in this section. First, let Ω =]0, 2[ 2 be given, as well as Γ D = ∂Ω. In this section, an exact solution of (3) will be fixed. As done before, the concentrations c A , c B , c C will be given as: This yields the RHS for the Dirichlet condition as g S,A ≡ 1 2 , for S ∈ {A, B, C}, and the RHS f A , f B , f C ∈ L 2 (Ω) are given through: Before the discussion of the examples is done, note that the exact error for the problems above is given by The first example that is discussed in this section is given by the parameters that are defined in Table 1. When simulating the problem (3) with uniform refinement, one obtains the species concentration that is displayed in Figure 12. Furthermore, note that, for the adaptive scheme, one obtains close to identical figures, hence it will be omitted in this article.  Table 1 and adaptive mesh refinement in 2d.
When evaluating the error estimators as well as the exact error, c.f. Figure 13, one obtains that the exact error, the estimator η given by the localized evaluation of the corresponding least-squares functional as well as the practical error estimator σ can be considered to be parallel for both refinement schemes. As can be seen, the adaptive scheme gives no prior advantage besides a better estimator η, which was used in the adaptive scheme. Figure 13. Developement of the error estimators for the uniform and adaptive mesh refinement, for the approximation of (3) with the parameters given in Table 1, in 2d.
When evaluating the augmented Lagrangian scheme, cf. Algorithm 1, one sees that the scheme converges after 166 iterations, cf. Figure 14, to species distributions with non-negative concentrations. One already obtains a state with small negativities after 316 iterations, as seen in Figure 14. Furthermore, one can see that the estimator η in each iteration does not converge to 0. However, in contrast to the examples in Section 4.1, the practical error seems to converge to 0.  The second example that is discussed in this section is given by the parameters that were defined in Table 2. When simulating the corresponding example (3) one obtains an analogous Figure 12, which are not displayed in this article, since no major difference to Figure 12 is visible.
When evaluating the augmented Lagrangian scheme for the example that is given by the set of parameters defined in Table 2 with adaptive mesh refinement, one obtains non-negative species distributions after 188 iterations, cf. Figure 15, although the history given in the figure indicates states close to the approximated solution after 1161 iterations of the augmented Lagrangian schemes.
Furthermore, let the RHSs f A , f B , f C ∈ Ł 2 (Ω) be given, as follows: The first example that is discussed in this subsection is given for the parameters defined in Table 1.
When calculating an approximate solution to the minimization problem (3), one obtains discrete solutions in the form, as shown in Figure 16, for uniform mesh refinement. Because of the fact that the approximate solution w.r.t. adaptive mesh refinement only gives small differences to the displayed figure, it is not shown in this paper.  Table 1.
When evaluating the estimators η and σ, as defined in definition and Remark 1, for the approximation of (3) for adaptive and uniform mesh refinement, one obtains that the estimators η and σ are restricted parallel to the refinement type, cf. Figure 17. Furthermore, one sees, as expected, that the estimators for adaptive refinement are steeper in the log log plot given in Figure 17, which indicates the expected increase of efficiency obtained by adaptive schemes. Figure 17. Developement of the error estimators for the uniform and adaptive mesh refinement, for the approximation of (3) with parameters that are given in Table 1 on the L-shaped domain.
When comparing the triangulation generated by uniform refinement, cf. left image in Figure 18, and the triangulation, cf. right image in Figure 18, one observes that, while the uniform triangluation has a homogeneous distribution of triangles, in the adaptively generated mesh, the triangles accumulate in the non-convex vertex. This behavior is commonly known in the literature, cf. [27,30]. The evaluation of the augmented Lagrangian algorithm, cf. Figure 19, with the use of adaptive refinement with estimator η yields that 188 iterations of the augmented Lagrangian algorithm are needed to guarantee non-negative species distributions.
The second example that is given in this section is, as before, given by the parameters that are defined in Table 2. When simulating the minimization problem (3), approximately one obtains an approximation of the form, as shown in Figure 20, which was obtained by simulation under uniform refinement. Because there are no visible differences between the picture generated under uniform refinement and generated under adaptive refinement, only the approximate solution under the usage of adaptive mesh-refinement will be given in this paper.    Table 2.
After the evaluation of the error estimators η and σ, as defined in remark and Definition 1, one obtains that the practical error σ and the classical error estimator η are parallel in both cases, uniform and adaptive refinement. Furthermore, one obtains that all error-terms converge to zero. Furthermore, it can be seen that the given error estimators that were induced by adaptive refinement seem to converge with a higher rate, since the corresponding graphs in the log log plot shown in Figure 21 are steeper than the graphs associated to uniform refinement. Figure 21. Developement of the error estimators for the uniform and adaptive mesh refinement, for the approximation of (3) with parameters that are given in Table 2 on the L-shaped domain. Similar to the previous example, one sees, in Figure 22, a uniform triangulation of the L-shaped domain in Figure 22 on the left side and right side one generated by the adaptive algorithm. The triangulation that is generated by the AFEM-loop is dominantly refined in the neighbourhood of the non-convex vertex. This clearly coincides with the theory about singular solutions to elliptic PDEs, cf. [33] and their treatment, cf. [27,30]. When applying the augmented Lagrangian algorithm to problem (4) and applying the adaptive scheme to treat the iterate problem (5), one needs 35,057 iterations to guarantee non-negative species distributions, but it is also clear that a close fit to non-negative species distributions are already obtained after 17,528 iterations, cf. Figure 23.  A (a,d,g), c B (b,e,h) and c C (c,f,i) in the 1st, 141st, and 283th iteration of the augmented Lagrangian algorithm with adaptive mesh refinement, w.r.t. the parameters given in Table 2.
As last point of the discussion of the numerical experiments in 2d, the evaluation of the CPU running time has to be discussed. Table 5 presents the results discussed in the following.
First, note that the number of iterations as well as the computation time reduce by using adaptive schemes. The reduction of computation time is for the the convex square domain is somehow remarkable, since the gain of efficiency, when using adaptive schemes, for convex domains is, in comparison to uniform refinement, rather low. The observed reduction of CPU time can be explained by the reduction of iterations in the augmented Lagrangian scheme, cf. Algorithm 1. However, the gain of efficiency, when using adaptive schemes to non-convex domains is remarkable, since a reduction of over 50,000 iterations of the augmented Lagrangian algorithm to under 300 is an extreme gain of efficiency. Table 5. An overview of number of iterations of the augmented Lagrangian Algorithm 1 and CPU running times for the different parameter sets and uniform resp. adaptive mesh refinement.

Parameter Set
Type of Refinement Geomety Number of Iterations CPU-Time Table 1 Square Uniform 280 730.5068 s Table 1 Square Adaptive 166 615.8496 s Table 1 L-Shaped Uniform 53, 639 3.1204e + 05 s Table 1 L-Shaped Adaptive 188 662.2452 s Table 2 Square Uniform 287 881.2332 s Table 2 Square Adaptive 181 645.7126 s Table 2 L-Shaped Uniform 53, 553 3.1554e + 05 s Table 2 L-Shaped Adaptive 283 742.0187 s Remark 7. Note that the high number of needed iterations of the augmented Lagrangian algorithm for the L-shaped domain results of the singularity at the non-convex vertex of the geometry, which is a common result for non-convex domains. The adaptive scheme refines dominantly at the nonconvex vertex of the geometry, which enhances the approximation in a way such that the augmented Lagrangian algorithm becomes enhanced, as can be seen in Figure 18.
When summarizing the results from this Section 4.2, it can been seen that the augmented Lagrangian scheme is more cost intensive than its correspondence in 1d. Furthermore, it can be seen in Section 4.2.1 that the practical estimator σ, as defined in the remark and Definition 1, behaves differently than in 1d under adaptive refinement, where it converges to zero, which justifies the use of the practical error. Additionally, one can observe, cf. Table 5, that a massive gain of efficiency can be made by using adaptive schemes in the discretization of (5).

Comparison to Other Methods
This section is devoted to the comparison of the augmented Lagrangian method, as described in this paper, with the classical augmented Lagrangian regime as described in [20,22] and the Primal-Dual Active-Set Strategy, as described in [23].

Theoretical Setup for the Classical Augmented Lagrangian Scheme and the Primal-Dual Active-Set Strategy
This section is devoted to description of the theoretical setup for the application of the classical augmented Lagrangian scheme [20,22] and the classical Primal-Dual Active-Set Strategy, c.f. [23].
The classical approaches to treat (4) is to discretize the optimization problem (4) and then use an optimization algorithm for the solution, as discussed in [14][15][16]19]. For an arbitrary fixed triangulation T with diameter 0 < h and for the usage of the discretization X h of X, as defined in Section 3, one obtains the following discrete optimization problem: Find x h = c S,h , p S,h S∈{A,B,C} ∈ X h such that the following equality holds true The classical approaches use the fact that X h is a finite dimensional subspace of X and, thus, (33) is an finite dimensional optimization problem, for which a lot of theory is known, i.e., for the approximation of solutions (33), the augmented Lagrangian schemes can directly be applied, as described in [20,22].
In contrast to augmented Lagrangian methods, the Primal-Dual Active-Set Strategy, as in the form described in [23], cannot be indirectly applied to (33). For the application of Primal-Dual Active-Set Strategies, in this paper it is assumed that the operator in the ODE, resp. PDE, is linear, (2a)-(2e), is linear, i.e., the equality k 1 = 0 is assumed. In this case, one obtains, by using a basis of X h , and using the Euler Lagrange Equation (20), one obtains a minimization problem of the following form: Find x v h ∈ R d , such that the following equation holds true In the problem above, (33) and v v S,h is the coefficient vector of v h ∈ S 1 (T ). Furthermore, for all y ∈ R d h , the equality

Description Classical Augmented Lagrangian Regime
This section is devoted to the description of the use of the classical augmented Lagrangian algorithm to the problem (33).
The classical augmented Lagrangian scheme is given through the following Algorithm 4, cf. [20,22].

Algorithm 4: Classical augmented Lagrangian method
Input : Define a starting values x (0),s h , λ (0) , α 0 and define j ∶= 0. Output : Approximate solution x h to (33) and approximate Lagrangian function λ h . The classical augmented Lagrangian algorithm is given through the following steps. S1: Approximate a solution to the following optimization problem.
S,h , p j S,h S∈{A,B,C} ∈ X h such that the following equation holds true: and use x S4: Set j ∶= j + 1 and go to S1.
The experimental setup needs to be described before the numerical experiments will be discussed in detail.
First, note that, for all simulations discussed with Algorithm 4, the parameter α j was for all j ∈ N given as α j = 1. For the comparison of the algorithm on different meshes, the algorithm was coupled with a loop of uniform refinements. The global Algorithm 5 is given through the following:

S2:
If T has more than N nodes then break the loop. S3: Define the mesh T +1 as uniform red refinement of the triangulation T . For a definition of the uniform red refinement see [27].
The statement of the algorithm above finishes the description of the used classical augmented Lagrangian scheme.

Description of the Primal-Dual Active-Set Strategy
This subsection is devoted to the explicit description of the Primal-Dual Active-Set Strategy that is considered in this article.
As discussed before for a basis {b 1 , . . . , b n h }, a basis of X h the problem (33) can be equivalently reformulated to (34).
The corresponding representation of X h , see (7) Applying the Primal-Dual Active-Set Strategy, cf. [23] as a method to approximate solutions to (34), together with the notation above, one obtains the following Algorithm 6.

Algorithm 6: Primal-Dual Active-Set Strategy
Input : Define a starting values x (0),s h , λ (0) , α 0 and define k ∶= 0. Output : Approximate solution x h to (33) and approximate Lagrangian function λ h . With the notation above the Primal-Dual Active-Set Strategy for this problem type S1: Define the inactive set I k and active set A k as follows: S2: Solve the following system of linear equations S3: Stop the algorithm, or set k ∶= k + 1 and return to S1. Before the actual comparison between the Primal-Dual Active-Set Strategy and the augmented Lagrangian method will be made, some additional remarks on the coupling between refinement and Algorithm 6 have to be made: For the comparison of the algorithm on different meshes, the algorithm was coupled with a loop of uniform refinements. The global Algorithm 7 is given through the following:

S2:
If T has more than N nodes then break the loop. S3: Define the mesh T +1 as uniform red refinement of the triangulation T . For a definition of the uniform red refinement see [27]. S4: Define x (0),s h ∶= x h and λ (0) ∶= λ .
The statement of the algorithm above finishes the description of the Primal-Dual Active-Set Strategy.

Comparrison of the Different Mehtods
This section is devoted to the explicit comparison of the different numerical schemes. However, before the actual comparison is undertaken the general setup of the experiments have to be stated.
First, note that the parameters of the mathematical problems to approximate in this section are given in the Tables 2 and 3. The corresponding RHS are the same as in the respective examples above. Furthermore, in the 2d experiments, the geometry considered is the L-Shaped domain.
Furthermore, for every method, the initial mesh T 0 for the refinement scheme was always the same in the respective dimension. Furthermore, note that refinement loops are broken if the mesh has 10,000 nodes in one space dimension and 1000 nodes in two space dimensions.
The loops of the respective augmented Lagrangian algorithms are broken if the relative error is bounded by the tolerance ε = 1e − 4.
First, note that there is no visual remarkable difference between the outputs of the algorithms. Hence, in this algorithm only the CPU times of the algorithms will be compared. Table 6 assembles the actual data for the comparrison.
In the context of the described algorithms, one would expect that the Primal-Dual Active-Set Strategy is the most inefficient in terms of needed RAM space during the computation due to the fact that the system of Equation (36a)-(36c) contain more variables than the other optimization-problems, since the augmented Lagrangian methods treat the multiplier λ as constant and not as a variable. Table 6. Comparison of the augmented Lagrangian scheme discussed in this paper with adaptive mesh refinement (AALA), the classical augmented Lagrangian algorithm (CALA), and the Primal-Dual Active-Set Strategy (PDAS), for different space dimensions and parameter sets.

Parameter Set
Dimension CPU Time AALA

CPU Time CALA CPU Time PDAS
cf. Table 2  1d 9.9426e + 03 s 8.8871e + 03 s 4.1808e + 03 s cf. Table 2 2d 742.0187 s 4.4895e + 04 s 1.1331e + 04 s cf. Table 3 1d 4.7214e + 04 s 2.0356e + 05 s -In one space dimension and for the parameters given in Table 2, the Primal-Dual Active-Set Strategy is the most efficient, while the two augmented Lagrangian schemes need approximately the same CPU time, as seen in Table 6. In contrast to that the augmented Lagrangian algorithm that is introduced in this paper is more efficient for non-convex domains and nonlinear problems than the other algorithms.

Modelling the Stationary Species Transport in the Diffusion-Boundary Layer during the Metal Deposition from a Cu 2+ Electrolyte
This section is devoted to the derivation a model, see Section 5.1, for the metal deposition from a Cu-electrolyte, taking the complexation with β-alanine (β-ala) in the diffusion-boundary layer into account. In Section 5.2, the numerical strategy, which is discussed in this article, will be applied to the model.

Theoretical Model
In this section, an abstract model for the static metal deposition in galvanic cells will be discussed. As a model that is falling into the discussed model types, the static metal deposition with speciation in a single diffusion boundary layer will be studied, c.f. [1][2][3].
A few remarks on the physical setting will be made before the model will be discussed in detail. In an electrolyte, a metal M, in this case Cu, and a ligand L, in this case β-ala, is assumed, with the reaction Furthermore, in the bath, there is an anode and a cathode, where, at the cathode, the metal is deposited. In the global setting, there is a transport of Cu-ions from the anode, with anodic current density j A , to the cathode, with cathodic current density j C . In this model, one assumes that j C = j A .
For the model, assume that there exists a laminar boundary layer at the cathode, which includes the diffusion boundary layer with thickness of δ x = 10 −4 m. Furthermore, assume that, outside the diffusion boundary layer, the concentration c Cu 2+ of Cu 2+ , the concentration c Cu 2+ of c β−ala and c Cu−β−ala are constant. Furthermore, the concentration the bath is set by c b S = 0.5 mol , for each S ∈ {Cu 2+ , β − ala, Cu(β − ala)}. Furthermore, let the only deposited species at the cathode, at position x = 0, be the Cu-ions and the species distribution in the diffusion boundary layer geometrically only be dependant on the distance to the cathode and the concentrations in the diffusion-boundary layer can be described by the diffusion-reaction problem (4), with diffusion coefficients and reaction rate constants, as given in Table 7, and let no further reactive force be given.
When translating the assumptions above into boundary-data one obtains for all S ∈ {Cu, β − ala, Cu − (β − ala)} the identity c S (δ x ) = c b S . At the cathode for the species S ∈ {S ∈ {β − ala, Cu − (β − ala)}, the identities d dx c S = 0 will be used and d dx c Cu = j D Cu zF , where F is Faraday's constant and z = 2 is the valency of the copper-ions Cu 2+ . The absence of reactive forces is modeled by defining the functions For the diffusion coefficients cf. to supplementary matrerial of [4] and for the kinetic parameters, cf. [3].

Simulation
In this section, the simulations according to the model above will be discussed. Assuming concentrations of c b S = 0.5 mol m 3 , for S ∈ {Cu, β − ala, Cu − β − ala} in the bath and a current density of j = 0.6 A m 2 on the cathode, one obtains the concentration profile shown in Figure 24 by evaluating the classical model 3, with the numerical scheme described for the treatment of (5) under the reduction described in Remark 1. As seen in the figure, one obtains a concentration of −0.4 mol , which can be considered to be unphysical.  Table 7.
When applying the augmented Lagrangian method with adaptive meshrefinement on (4), cf. Figure 25, one obtains that 75 iterations of the augmented Lagrangian algorithm were needed to evaluate non-negative concentrations. As seen in the corresponding figures, not only the behavior of c Cu 2+ , but, as directly seen, the behavior of c β−ala , in the close area of the cathode the concentration of c β−ala increases. Furthermore, it can be seen that the augmented Lagrangian algorithm needs 75 steps for the simulation of non-negative species concentrations.

Remark 9.
During the application of the numerical scheme that is described in Section 3, one observes that the adaptive scheme converges relative fast for the respective model 4 given through the parameters that are defined in Table 7 and the given boundary conditions, while the quasi-Newtonian part of the numerical scheme based on the uniform refinement does not converge, unless a high number of homotopy steps > 10 6 is used.
In summary, the numerical methodology that is derived in this article is applicable to practical relevant settings, and the adaptive scheme has a major part on the efficiency of the described.

Discussion and Conclusions
Although, in this article, the rigorous mathematical proofs are not done, in Section 4 various numerical examples are discussed, which show convergence. Hence, the convergence of all included algorithms can be stated as a founded conjecture. Although some mathematical considerations are made in this paper, some rigorous mathematical work still has to be done. In detail, the following formal proofs have to be made in some future work: (i) There exist, at least locally, a unique solution to (3) and (4). (ii) The iterated minimization problems (5) are, at least locally, uniquely solvable and the sequence of solutions (u (n) S , p (n) S ) S∈{A,B,C} ∈ X, generated by the augmented Lagrangian method, converges to the solution (u S , p S ) S∈{A,B,C} ∈ X of (4). (iii) For a triangulation T , with low enough diameter 0 < h and a stable starting point of the quasi-Newton scheme described by solutions of (13), every iterate problem of (13) is uniquely solvable. (iv) The quasi-Newton method given by the iterative solution x (n) h of (13) converges in X h . i.e., there exists a x h ∈ X h , such that x h = lim n→∞ x (n) h .
(v) For h ↓ 0 the limits described in (iv) converge against the solution of (5). (vi) The adaptive scheme that is described in Algorithm 3 converges.
Furthermore, the numerical experiments show that the application of the practical error σ, as defined in Definition and Remark 1, can be used in two space dimensions. In addition, the behavior seems to indicate the needed norm equivalences in two space dimensions. Furthermore, in one space dimension, it can be seen that the practical error estimator is not sufficient for the required norm equivalence, but the numerical examples nevertheless show good results, which allow the use as above.
Although the numerical schemes are still cost intensive, they converge and, hence, give physical behavior for three compound systems. In addition, as to be seen in Section 5, in this article, a numerical scheme was introduced that is able to treat the high rate constants given in real-world problems, cf. supplement to [4]. Hence, the numerical scheme can be used in most relevant settings when considering three-component systems.
Furthermore, note that the algorithm that is described in this section seems, due to the discussions for the numerical examples, to be especially efficient for nonlinear and non-convex geometries. Especially, the efficiency for those two cases makes the algorithm interesting for further applications.
The model that is presented in the Section 5 gives a first glance at the process of metal deposition, but one has to expect that the model is improvable. Firstly, the assumption of the existence of a uniform laminar boundary layer on any complex geometry is questionable since fluid dynamics tend to be strongly geometry dependant, cf. [56]. Furthermore in galvanic processes H 2 development at the cathode can be expected, which questions the existence of a laminar boundary layer in many cases. Although the concentration gradients in a galvanic bath can be assumed to be low in some cases, the species-transport in the bath, as described in [1][2][3], cannot necessarily be neglected. Furthermore, the processes in the bath can be described by a multi physics coupling of fluid dynamics, diffusion, reactions, and electro-magnetics. Furthermore, as seen in [3], the reaction kinetics that were discussed in this article are not complete. Hence, a further discussion of this type of model needs to be done.
As is well known, most of the real world processes do not reduce to static problems, but, nevertheless, important limiting factors can be obtained from static laws. Furthermore, from a technical numerical perspective, time-dependent laws can be approximately treated as systems of static laws, c.f. [57] or [58]. Hence, this article gives a good first foundation for further discussions and investigations.

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

Abbreviations
The following abbreviations are used in this manuscript: