Some Recent Advances in Energetic Variational Approaches

In this paper, we summarize some recent advances related to the energetic variational approach (EnVarA), a general variational framework of building thermodynamically consistent models for complex fluids, by some examples. Particular focus will be placed on how to model systems involving chemo-mechanical couplings and non-isothermal effects.


Introduction
Complex fluids comprise a large class of soft materials, such as polymeric solutions, liquid crystals, ionic solutions, and fiber suspensions. These are fluids with complicated rheological phenomena, arising from different "elastic" effects, such as the elasticity of deformable particles, interaction between charged ions, and bulk elasticity endowed by polymer molecules [1,2]. Due to their strong nonlinear and non-equilibrium nature, building thermodynamically consistent models for complex fluids has been an interesting and challenging problem. The difficulty arises from complicated coupling and competition of different electro-chemo-mechanic mechanisms, such as long-range interaction and thermal fluctuation, in different spatio-temporal scales.
Motivated by the non-equilibrium thermodynamics, especially the seminal works of Rayleigh [3] and Onsager [4,5], the energetic variational approach (EnVarA) has proven to be a powerful tool in studying numerous complex fluids systems in physics, chemistry, and biochemistry [6,7], including liquid crystals [8,9], viscoelastic fluids [10], multiple-phase flows [11,12], ionic solutions [13], etc. The idea of EnVarA is to describe a complex system by an energy-dissipation law d dt where E total is the sum of the kinetic energy K and the Helmholtz free energy F , is the rate of energy dissipation. The energy-dissipation law (1) can be obtained by combining the first and second laws of thermodynamics for an isothermal and mechanically isolated system [14]. Indeed, the first law of thermodynamics states that where K is the kinetic energy, U is the internal energy,Q is the rate at which heat absorbed from the environment, andẆ is the rate of the external work done by the environment. To analyze heat, one introduces the second law of thermodynamics where T is the absolute temperature, S is the entropy, and ≥ 0 is the rate of entropy production. By subtracting the first law (2) and the second law (3), we obtain an energy-dissipation law (1) for an isothermal ( d dt T = 0) and mechanically isolated (Ẇ = 0) system with F = U − TS being the Helmholtz free energy. So, in this case, the rate of energy dissipation equals the rate of entropy production.
Starting with an energy-dissipation law (1), EnVarA derives the dynamics of the systems through the least action principle (LAP) and the maximum dissipation principle (MDP). The LAP, which states the equation of motion for a Hamiltonian system can be derived by taking variation of the action functional A = T 0 K − F dt with respect to the trajectory x, gives a unique procedure to derive the conservative force in the system. The MDP, variation of the dissipation potential D with respect to x t , i.e., the velocity, derives the dissipation force in the system. In turn, the force balance condition leads to the underlying evolution equation of the system According to the Onsager theory [4,5], the rate of entropy production is quadratic in terms of x t in the linear response regime, and the dissipation potential D = 1 2 in this case. There are other forms of variational principles, such as the general equation for nonequilibrium reversible-irreversible coupling (GENERIC) [1,15,16], Onsager's variational principle [17][18][19][20], and conservation-dissipation formalism [21,22], that have also been helpful in studying complex fluids. Although these variational principles are equivalent to EnVarA in most cases, these approaches are based on the principle of virtual work (PVW), in which the variation is often taken with respect to the state variables directly. The state variables are defined in Eulerian coordinates in many cases, and can be viewed as generalized coordinates in these systems [17].
In contract to other variable principles, the classical EnVarA formulation is rooted in the continuum mechanics [23][24][25] and a Lagrangian formulation of an underlying system. Continuum mechanics is a generalization of Newtonian particle mechanics. In continuum mechanics, it is assumed that there are infinite many particles form a continuum body. The motion of these particles is described by a flow map x(X, t), where X is the Lagrangian coordinate and x is the Eulerian coordinate. More importantly, in the context of continuum mechanics, all dynamics of the employed variables are determined by the flow map x(X, t) and its derivatives (the velocity and the deformation tensor) through their kinematics. The energy-dissipation law, together with the kinematics of the employed variables, describes all the physics and assumptions in the system. It is important to realize that systems derived by the LAP can also be derived by the PVW, but not vice versa. In fact, the discrepancy between the LAP the PVW is of great interest in the mathematical theory of weak solutions and the theory of singularities [8,11].
The purpose of this paper is to provide a brief overview of some recent developments of the energetic variational approach, especially for the systems involving chemomechanical couplings and non-isothermal effects, through examples. We refer interested readers to [6,7] for more details of the classical energetic variational approach. The rest of the paper is organized as follows. In Section 2, we briefly review the EnVarA in continuum mechanics, and show its applications in modeling generalized diffusion, a dilute polymeric fluids, and the kinetic Fokker-Planck equation. The EnVarA formulation for reaction kinetics and its applications in modeling chemo-mechanical systems, such as reaction-diffusion systems, the dynamical boundary conditions, the Boltzmann equation and the reaction/active fluids, are given in Section 3. In Section 4, we discuss the extension of the EnVarA to non-isothermal systems. Some applications of the EnVarA in developing structure-preserving numerical schemes and thermodynamically consistent coarse-grained model are reviewed in Section 5.

EnVarA in Continuum Mechanics
As mentioned in the introduction, the classical energetic variational approaches are variational principles for continuum mechanics [7], and the variable x in (4) should be understood as the flow map x(X, t) from a reference domain Ω 0 to a physical domain Ω t .
Here X ∈ Ω 0 is the Lagrangian coordinate and x ∈ Ω t is the Eulerian coordinate. For a fixed X, x(X, t) describes a trajectory of a particle (or a material point) labeled by X, while for a fixed t, x(X, t) is a diffeomorphism from Ω 0 to Ω t (see Figure 1 for an illustration). An important feature of a continuum mechanical system is that the evolution of physical variables, such as the density function, are determined by the evolution of the flow map x(X, t) through kinematics. All the kinematic transport information of these variables is carried by the deformation tensor F. For a given flow map x(X, t), the deformation tensor A direct computation shows thatF satisfies a transport equation [7] F t + u · ∇F = ∇uF.
Without ambiguity, we will not distinguish F andF throughout this paper. Due to the conservation of mass, Ω t ρ(x, t)dx = Ω 0 ρ 0 (X)dX, the kinematics of a density function ρ(x, t) can be written as in Lagrangian coordinates, where ρ 0 (X) is the initial density. The kinematics (6) is equivalent to the continuity equation ρ t + ∇ · (ρu) = 0 in Eulerian coordinates. For a scalar variable that is purely transported by the flow map, the kinematics is given by in Eulerian coordinates. For a nematic liquid crystal that consists of rod-like molecule, the kinematics of the nematic order parameter d ∈ R d can be written as

Generalized Diffusion
One of the simplest classes of mechanical processes is generalized diffusion. Generalized diffusion is concerned with a conserved quantity ρ(x, t) satisfying the kinematics where u is the average velocity. In the framework of EnVarA, a generalized diffusion can be described an energy-dissipation law where ω(ρ) is the free energy density, η(ρ) > 0 is the friction coefficient. Due to the kinematics (7), the free energy can be reformulated as a functional of x(X, t) in Lagrangian coordinates. A direct computation shows that where δx is the test function satisfying δx · n = 0 with n being the outer normal of Ω in Eulerian coordinates (Here we will not distinguishδx(x(X, t), t) = δx(X, t) and δx(X, t) without ambiguity). Pushing forward to Eulerian coordinates, we have which indicates that δA δx where µ = δF δρ is the chemical potential. In the notion of the principle of virtual work [24], one can obtain (9) by using the relation δρ = ∇ · (ρδx) For the dissipation part, since D = 1 2 η(ρ)|u| 2 dx, it is easy to compute that δD δu = η(ρ)u. As a consequence, we have the force balance equation Combining the force balance Equation (10) with the kinematics (7), one can obtain a generalized diffusion equation It is worth mentioning that the above derivation is rather formal. A certain analysis is needed to show the existence of the flow map x(X, t). We refer interested readers to [26,27] for some related discussions. Many classical models can be viewed as generalized diffusions with different forms of the free energy F [ρ] and the dissipation. For example, the porous medium equation (PME) ρ = ∆ρ m can be obtained by taking F [ρ] = 1 m−1 ρ m dx and η(ρ) = ρ, the Cahn-Hilliard equations ϕ t = ∆(−∆ϕ + f (ϕ)) can be obtained by taking F [ϕ] = f (ϕ) + 1 2 |∇ϕ| 2 dx and η(ϕ) = ϕ 2 [28], and the Poisson-Nernst-Planck (PNP) equations for ion transport can be obtained from the energy-dissipation law along with the Poisson equation ∇( ∇φ) = n − p [13]. Another interesting example of generalized diffusions is the nonlinear Fokker-Planck equation associated with a random process It is well known that different definitions of stochastic integrals can lead to different diffusion equations. For the stochastic process (13), Itô calculus leads to a diffusion equation which corresponds to the energy-dissipation law [29]. Meanwhile, the Stratonovich integral yields which corresponds to the energy-dissipation law if a = 1 2 σ 2 ∇ψ. In both cases, the condition a = 1 2 σ 2 ∇ψ, known as the fluctuationdissipation theorem in statistical physics [30], is crucial for the existence of the energydissipation law, as well as the existence of an equilibrium state [7].
In the case that η(ρ) = ρ, generalized diffusions can be viewed as Wasserstein gradient flows in space of all probability densities having finite second moments P 2 (Ω) [31]. Formally, the Wasserstein gradient flow can be defined as a continuous time limit (τ → 0) of the semi-discrete scheme, known as the JKO scheme, where P 2 (Ω) = {ρ : Ω → [0, ∞) | Ω ρdx = 0, Ω |x| 2 ρ(x)dx < ∞} and W 2 (ρ, ρ k ) is the Wasserstein distance between ρ and ρ k . The Wasserstein distance between two probability densities ρ 1 and ρ 2 can be computed through a Benamou-Brenier formulation [32] W 2 (ρ 1 , ρ 2 ) = arg min is the admissible set. The Wasserstein gradient flows are Eulerian descriptions to generalized diffusions [33]. Other choices of dissipation can define other metrics in the space of probability measures [34,35]. Within (15), the JKO scheme can be roughly approximated as under a constant velocity assumption, where The scheme (17) can be viewed as an implicit Euler discretization to the flow map Equation (10) in (t k , t k+1 ). Mathematically, it is interesting to establish the equivalence or discrepancy between (14) and (17).

Micro-Macro Model for Polymeric Fluids
One successful application of EnVarA is building thermodynamically consistent micromacro models for many complex fluids [36,37]. Compared with the macroscopic continuum mechanics approach, micro-macro models couple the macroscopic hydrodynamic equations with a microscopic kinetic theory, which describes the origin of the macroscopic stress tensor [38,39].
In the simplest micro-macro models of complex fluids, the polymer molecules are modeled as an elastic dumbbell consisting of two "beads" joined by a one-dimensional spring [36,37]. The microscopic configuration of an elastic dumbbell is described by an end-to-end vector between the two beads, q ∈ R d . Let f (x, q, t) be the number density distribution function of finding a molecule with end-to-end vector q at position x ∈ Ω at time t. To build a micro-macro model by EnVarA, in addition to the macroscopic flow map x(X, t) at the physical space, one also needs to introduce a flow map at the configurational space, denoted by q(X, Q, t), where Q are Lagrangian coordinates in the configurational space. For a given q(X, Q, t), the microscopic velocity V (x, q, t) can be defined as Due to the conservation of mass, the density distribution function f (x, q, t) satisfies which leads to the kinematics in Eulerian coordinates.
In the framework of EnVarA, the micro-macro system can be modeled through an energy-dissipation law where ρ is the constant density of the fluid, λ p > 0 is a constant that represents the polymer density, k B is the Boltzmann constant, T is the absolute temperature, η s > 0 is the solvent viscosity, the constant ζ is related to the polymer relaxation time, Ψ = Ψ(q) is the microscopic elastic potential of the polymer molecules. For Hookean and FENE models, the elastic potential Ψ(q) is given by Ψ(q) = 1 2 H|q| 2 and Ψ(q) = − where H > 0 is the elastic constant and Q 0 is the maximum dumbbell extension in FENE models. The second term of the dissipation accounts for the micro-macro coupling with V being the macroscopic induced velocity. According to the Cauchy-Born rule, q = FQ due to the macroscopic flow, which indicates From the energy-dissipation law (21), one can derive the dynamics of the system by performing EnVarA in both micro-and macro scales. First, we look at the dynamics at the macroscopic scale. Due to the "separation of scale" [7], the second term in the dissipation (21) vanishes when deriving the macroscopic force balance. Since det F = 1, the action functional can be written as in Lagrangian coordinates, where f 0 (X, Q) is the initial number distribution function, and f (x, FQ, t) = f 0 (X, Q) due to det F = 1. By applying the LAP, i.e., taking the variation of A(x) with respect to x, we obtain (23) in Eulerian coordinates. Indeed, consider a perturbation x = x + y, where y(X, t) = y(x(X, t), t) satisfyingỹ · n = 0. Then Pushing forward to Eulerian coordinates, we have which leads to (23). For the dissipation part, the MDP, i.e., taking the variation of D with respect to x t , leads to where p is the Lagrangian multiplier for the incompressible condition ∇ · u = 0. Hence, the macroscopic force balance results in the momentum equation where is the induced stress from the configuration space, representing the microscopic contributions to the macroscopic level. On the microscopic scale, similar to the generalized diffusions discussed in the last subsection, by taking variations with respect to q(X, Q, t) and V (X, Q, t), we obtain Combining with Equation (20), we obtain the equation on the microscopic scale: In summary, the final micro-macro system reads as follows: subject to a suitable boundary condition.

Kinetic Fokker-Planck Equation
Using a similar micro-macro approach, one can also formulate the kinetic Fokker-Planck equation into an EnVarA formulation. The kinetic Fokker-Planck equation, given by describes the evolution of the probability density function f (x, v, t) of a system of particles that satisfies a Langevin dynamics where W t is the standard Wiener process and Φ(x) is the potential function. Due to the fluctuation-dissipation theorem (FDT), σ = 2k B Tγ, which ensures that the system admits an energy-dissipation law and can reach an equilibrium state [40]. The total energy of the system can be defined by Then the kinetic Fokker-Planck equation can be written as two parts [41] Indeed, a direct computation shows that d dt where the last equality follows the fact that ∇ x · v = 0 and ∇ v · (∇Φ) = 0. Hence, f t = L C f conserves the total energy. In the meantime, Here, we need σ 2 = 2k B Tγ to obtain the quadratic form. σ = 2k B Tγ is known as the fluctuation-dissipation theorem [30]. This calculation also reveals the connection between the fluctuation-dissipation theorem and linear response theorem. Similar to the micro-macro approach for polymeric fluids introduced in a previous subsection, one can treat v as a microscopic variable, and x as a macroscopic variable; the micro-macro coupling is imposed through x t = v. Due to the conservation property, the probability density f (x, v, t) satisfies the kinematics where U can be decomposed as Here U C (x) is a conserve velocity. In other words, the equation d dt In other word, we can obtain U C (x) by applying the least action principle at the macroscopic scale. The dissipative velocity U D (v) can be obtained through the energy-dissipation law A standard variational procedure results in Here 1 2 f |v| 2 plays a role of the internal energy in the macroscopic scale. The EnVarA formulation to the kinetic Fokker-Planck equation may open a new door for both theoretical and numerical study of these types of equations.

EnVarA for Chemical Reactions
Chemical reactions play important roles in many physical, chemical, and biological processes [42]. The fundamental "law" for chemical reaction kinetics is the law of mass action (LMA), which is discovered by Waage and Guldberg, and H. van't Hoff independently in the 19th century. A reversible chemical reaction system with N species {X 1 , X 2 , . . . X N } and M reactions can often be represented by where α l i and β l i are constant coefficients. Let c = (c 1 , c 2 , . . . , c N ) T be concentrations of all species. Then c satisfies the reaction kinetics where r l (c) is the reaction rate for the l-th chemical reaction, and σ il = β l i − α l i is the stoichiometric coefficients. From (38), it is noticed that d dt (e · c) = e · σr(c(t), t) = 0, for e ∈ Ker(σ T ). (39) In turn, one can define N-rank(σ) linearly independent conserved quantities for the reaction network.
The classical LMA states that the reaction rate is directly proportional to the product of the reactant concentrations, i.e., in which k + l and k − l are the forward and backward reaction constants for the l-th reaction. The LMA was designed for the ideal gas of a perfect gas of non-interacting point particles without charge or diameter. To generalize the LMA to more complicated systems, it is important to establish a thermodynamics basis of this empirical law.
Since 1950s, there has been a large amount of work aiming to build an Onsager-type variational theory for systems involving chemical reactions [1,[43][44][45][46][47][48][49][50][51][52].The key idea is to build on analogies between continuum mechanics and reaction kinetics [1,52,53]. Inspired by these prior works, in a recent paper [54], the authors extended the EnVarA formulation to a system that involves chemical reactions. By introducing the reaction trajectory R ∈ R M , which accounts for the "number" of forward chemical reactions that has occurred by time t, the reaction kinetics can be reformulated in terms of R. The reaction trajectory R, which is known as the internal state variable in [43], is analogous to the flow map x(X, t) in mechanical systems [55]. The relation between species concentration c ∈ R N + and the reaction trajectory R is given by c = c 0 + σR, where c 0 is the initial concentration, and σ ∈ R N×M is the stoichiometric matrix with σ il = β l i − α l i . The reaction rate r, defined as ∂ t R, is the reaction velocity [52]. Within the reaction trajectory, we can describe the chemical kinetics of a reaction network by an energy-dissipation law in terms of R and ∂ t R: where D chem [R, ∂ t R] is the rate of energy dissipation due to the chemical reaction. Unlike mechanical processes, chemical reactions are usually far from equilibrium. The linear response assumption may be not valid unless at the last stage of chemical reactions [1,56]. As a consequence, D chem is not quadratic in terms of ∂ t R in general. For a general nonlinear dissipation the reaction rate can be derived as [54,57]: which is the "force balance" equation for the chemical part [54,57]. It is often assumed that Γ l (R, ∂ t R) = Γ l (R l , ∂ t R l ). Equation (43) specifies the reaction rate of the l-th chemical reaction. In this formulation, the free energy determines the chemical equilibrium, while the dissipation functional D chem [R, ∂ t R] determines the reaction rate. It is worth mentioning that the variational principle (43) can be applied to other systems with non-quadratic dissipations, such as the systems studied in [58,59]. The classical LMA can be obtained by taking where c ∞ is an equilibrium of the reaction kinetics system that satisfies the detailed balance condition, i.e., r l ( Similar to the cases in [58,59], near a chemical equilibrium, ∂ t R l is very small, and the dissipation of the LMA can be well approximated as a classical Onsager quadratic form of ∂ t R l .
As an illustration, we consider a single chemical reaction in which σ = (−α 1 , −α 2 , β 3 ) T . According to the previous discussion, the variational approach produces where From (46), we can obtain the law of mass actioṅ where The energetic variational formulation of chemical reactions opens a new door to model a general chemo-mechanical system in a unified variational way. One of the simplest chemo-mechanical systems is reaction-diffusion type system. For a reaction-diffusion system, the concentration of each species c i satisfies the kinematics: where u i is the average velocity of each species due to its own diffusion, R ∈ R M represents various reaction trajectories involved in the system, with σ ∈ R N×M being the stoichiometric matrix as defined earlier. Then the reaction-diffusion equation can be modeled through the energy-dissipation law [54]: We can employ EnVarA to obtain equations for the reaction and diffusion parts, respectively, i.e., to obtain the "force balance equation" of the chemical and mechanical subsystems, which leads to One special reaction-diffusion system is a one-species system, in which the concentration or density ρ satisfies the kinematics where u is the average velocity that describes the diffusion of the species, and R is the reaction trajectory that describes the birth and death process. We can model this type system by an energy-dissipation law These systems are related to the unbalanced optimal transport in machine learning [60][61][62][63][64]. Different systems can be derived by choosing the free energy and the dissipation differently, including the Kantorovich-Fisher-Rao gradient flows [65].

Dynamical Boundary Condition
For a better description of short-range interactions between the material and the boundary, PDE systems with dynamical boundary conditions have drawn lots of attention recently [66,67]. These type of systems have a wide application in studying moving contact lines [68], batteries [69], the integrate-and-fire model for neuron networks [70], and sticky Brownian motion [71], etc.
Consider a bounded domain Ω, and denote the densities in Ω as ρ and the density on Γ = ∂Ω as σ. In the models with dynamical boundary conditions, the conservation of total mass indicates that Hence, ρ and σ satisfy the kinematics in Eulerian coordinates where ν is the outer normal of Ω and R is the reaction trajectory for the chemical reaction ρ − − − − σ that represents the density exchange between the bulk and surface. In general, a system with a dynamical boundary condition can be modeled through an energy-dissipation law where F b (ρ) and F s (σ) are free energies in the bulk and surface, respectively. The standard variational procedures lead to the force balance equations for the mechanical and chemical parts where µ s (σ) − µ b (ρ) is the affinity of the bulk-surface reaction. Different choices of the free energy and the dissipation lead to different systems. A typical example is the Cahn-Hilliard equation with dynamic boundary condition, which can be derived by taking Here the linear response assumption is used for the bulk-surface exchange. The final equation can be written as [67], subject to a suitable initial condition. In the limit γ → 0, the model is reduced to the model proposed in [66], while limit γ → ∞ corresponds to the model in [72].

Boltzmann Equation
Another application of the EnVarA formulation for reaction kinetics is to reformulate the Boltzmann equation of ideal gas into a variational form, which was also explored in some previous works [73,74]. The key point is to view the collisions between particles as generalized chemical reactions. From a historical perspective, Maxwell and Boltzmann used an analogue of the law of mass action for collisions and discovered the principle of detailed balance [75].
Consider a Boltzmann equation where f (x, v, t) is the density for particles at the point x, having velocity v at time t, Q( f , f ) is the collision term that can be written as Here is the transition probability for two particles with velocity v and v * before a collision to have velocities v and v * after the collision. The collisions can be viewed as generalized chemical reactions. Since collisions conserve mass, momentum, and kinetic energy, Moreover, due to the conservation of momentum and kinetic energy one can assume that w(v, v * |v .v * ) only depends on v − v * and ω ∈ S 2 , where ω is a parameter that determines v and v * , i.e., For given v and v * , a fixed ω defines a "chemical reaction" with is the collision kernel. At the Maxwellians, f f * − f f * vanishes identically, so the system satisfies the detailed balance condition. Like the kinetic Fokker-Planck equation, the kinematics of f (x, v, t) can be written as the sum of the conservative and dissipative parts, i.e., where L C f = −∇ x · (v f ) and L D f = Q( f , f ). The total energy of the system can be defined as For the conservative part, For the dissipative part, a direct computation shows that Here, Q( f , f )|v| 2 dv = 0 and Q( f , f )dv = 0 are used. We can reformulate the energy-dissipation law of the Boltzmann Equation (68) in terms of reaction trajectories R(v, v * , ω), by imposing the kinematics The dissipation can be written in terms of R and ∂ t R, i.e., Notice that By a variational procedure, we can obtain which leads to It is worth mentioning that − ln f − ln f * + ln f + ln f * is the affinity of the chemical reaction (64). Indeed, the chemical potential associated with v can be computed as where 1 2 |v| 2 plays the role of the internal energy. Due to the conservation of the kinetic energy, we have |v| 2 + |v * | 2 = |v | 2 + |v * | 2 , which indicates that the affinity of the collision equals to −µ − µ * + µ + µ * = − ln f − ln f * + ln f + ln f * .

Reactive Fluids
Reactive and active fluids, which are systems involving coupling and competition between chemical reactions and various types of mechanical processes, have drawn lots of attention recently [76][77][78][79][80][81].
A simple example of reactive complex fluids is wormlike micellar (WLM) solutions, also known as "living polymer". These are polymeric fluids that consist of long, cylindrical aggregates of self-assembled surfactants that can break and reform reversibly [82]. During the last couple of decades, a number of mathematical models have been proposed for wormlike micellar solutions [82][83][84][85][86]. The reptation-reaction model, proposed by Cates [82], is one of the first models that accounts for the reversible breaking and reforming of micellar chains. The Cates' model assumes that a chain can break with a fixed probability per unit time per unit length anywhere along its length. Let c(L) be the number density of chains of length L, and the governing equation of c(L) can be formulated aṡ where k 1 and k 2 are rate constants for the breakage and recombination, respectively. It can be shown that the steady state (ċ(L) = 0) is given by c eq (L) = (2k 1 /k 2 ) exp(−L/L), wherē L is a constant that satisfies 2L 2 = ∞ 0 Lc(L)dL k 2 /k 1 . Inspired by Cates' seminal work, a two-species model for wormlike micellar solutions was proposed in [86], known as the Vasquez-Cook-McKinley (VCM) model. Although the VCM model was derived from a highly simplified discrete version of Cates' model [87], it can capture the key rheological properties of wormlike micellar solutions [86,88,89]. However, due to the assumption that the breakage rate depends on the velocity gradient explicitly, the VCM model may not be thermodynamically consistent [87]. Using the generalized bracket approach [1], a thermodynamically consistent revision to the VCM model was proposed in [87,90], known as the GCB (Germann-Cook-Beris) model. They also extended such a model to a three species cases. Using the GENERIC framework [15,16], Grmela et al. also extended the VCM model into a three-species thermodynamically consistent model [84].
In a recent work [91], the authors developed a thermodynamically consistent twospecies micro-macro model for wormlike micellar solutions, which incorporates a breakage and combination process of polymer chains into the classical micro-macro dumbbell model of polymeric fluids in the general framework of EnVarA. The model assumes that there exists only two species in the system. A molecule of species A can break into two molecules of species B, and two molecules of species B can reform species A. A polymer molecule of both species can be modeled as an elastic dumbbell consisting of two "beads" joined by a one-dimensional spring [37]. The microscopic configuration is described by an end-to-end vector q ∈ R d . Let ψ α (x, q, t) (α = A, B) be the number density distribution function of finding a molecule with end-to-end vector q at position x ∈ Ω at time t for species α.
In general, the breakage and combination processes can be regarded as chemical reactions where q and q are end-to-end vectors of species B, and q is an end-to-end of species A (see Figure 2a for illustration). We can denote the forward and backward reaction rates of (75) by W + (q, q ; q ) and W − (q, q ; q ), respectively. The kinematics of ψ A and ψ B can be written as where u α and V α are effective macroscopic and microscopic velocities. Different models can be obtained by choosing W + (q, q ; q ) and W − (q, q ; q ) differently. In the simplest case, one can take W ± (q, q ; q ) = 0 if and only if q = q = q , which corresponds to the case that an A molecule at position x with end-to-end vector q can only break into two B molecules with the same end-to-end vector, and the combination process can only happen between two B molecules at the same position x with the same end-to-end vector, as illustrated in Figure 2b, with α = 1. Within this assumption, one can have a detailed balance condition for each x and q, and the kinematics can reduce to where R(x, q, t) is the reaction trajectory for the breakage and combination for given q and x. Within the above kinematics assumptions, the overall system can be modeled by an energy-dissipation law where ψ α (x, q, t) is the number density distributions of each species, U i (q) is the spring potential associated with each species, u is the macroscopic velocity satisfying the incompressible condition ∇ · u = 0, the constant ρ > 0 is the density of the macroscopic flow, V α is the average microscopic velocity of each species in the configuration space, λ > 0 is the constant that represents the ratio between the kinetic energy and the elastic energy, and ξ α > 0 is a constant related to the relaxation time of each species. By taking Γ(R, R t ) = R t ln R t k 2 (q)ψ 2 B + 1 , the final micro-macro system can be derived as (see [91] for details) where and the stress tensor τ is given by with n α (x, t) = ψ α (x, q, t)dq being the number density of each species. The breakage and combination process indeed created an active stress in the macroscopic momentum equation. The global existence of the class solution near the global equilibrium of this model is given in [92]. The underlying variational structure (78) plays a crucial role in the theoretical analysis.

EnVarA for Non-Isothermal Systems
The above EnVarA framework works for isothermal cases, in which the whole system can be well-described by a single energy-dissipation law (1). However, in non-isothermal cases, one cannot obtain a single energy-dissipation law from the first and second laws of thermodynamics. Motivated by the classical treatments of temperature in rational mechanics [14,43], some recent work [93][94][95][96] extended EnVarA to non-isothermal cases.
To model a non-isothermal system, the extended EnVarA approach starts with a suitable form of the non-isothermal Helmholtz free energy density Ψ(ζ, ϑ), where ϑ(x, t) is the absolute temperature and ζ represents all the mechanical variables in the system, such as the density ρ(x, t) and the deformation tensor F, which are determined by the flow map x(X, t). The non-isothermal Helmholtz free energy density Ψ(ζ, ϑ) needs to be concave with respect to the temperature ϑ, i.e., Ψ ϑϑ < 0 [14].
According to the basic thermodynamical relations [14,97], the entropy density s = s(ζ, ϑ) is defined by while the internal energy density e(ζ, ϑ) is defined by Since Ψ θθ < 0, s is a monotonically increasing function of ϑ, which indicates that ϑ can be represented as a function of ζ and s, i.e., As a consequence, the internal energy density e can be reformulated as a function of ζ and s by using (84). Without ambiguity, we denoteê(ζ, s(ζ, ϑ)) = e(ζ, ϑ). According to the chain rule, it is straightforward to show and As in isothermal systems, it is crucial to specify the kinematics of the mechanical variable ζ as well as the kinematics of the temperature ϑ in non-isothermal systems. Different kinematic relations lead to different dynamics. To illustrate the idea, in the following, we only consider a simple case, with the mechanical variable being a density function ρ only, which satisfies the kinematics ρ t + ∇ · (ρu) = 0. For the temperature ϑ, we assume that i.e., the temperature is purely transported along the trajectory. Moreover, we focus on cases where the kinetic energy K = 0 throughout this section. Although the whole system is no longer determined by the energy-dissipation law (1), we can still define the total energy E total = Ψ(ρ, ϑ)dx as well as the dissipation potential D ≥ 0, and derive the force balance Equation (4) for the mechanical part of the system by using the LAP and MDP. To simplify the calculations, we assume that D = 1 2 η(ρ)|u| 2 dx throughout this section, although other forms of the dissipation can be handled in a similar manner. By applying the LAP and the MDP, we can obtain the force balance equation for the mechanical part, i.e., equation for the flow map x(X, t). The computation procedure is almost the same as that in Section 2.1. Indeed, a direct computation shows that Pushing forward to the Eulerian coordinates, we have which indicates that δA δx = −ρ∇µ − s∇ϑ. Then the force balance equation for the mechanical part can be written as To determine the equation for temperature ϑ or entropy s, we need to use both the first and second laws of thermodynamics. The first law of the thermodynamics can be written as where V is an arbitrary control volume, Σ stands for the specific work done to the system, and q is the absorbed heat flux. According to (85) and (86), it is easy to compute that where the kinematic assumption on the entropy s is used. Here, q ϑ is the entropy flux defined by the Clausius-Duham relation, and * ≥ 0 is the density of the entropy production. Comparing (90) with (89), we obtain that Recall (88). We have On the other hand, by the Fourier law, we have where k 3 ≥ 0. Hence, the density of the entropy production is * = which is consistent with the second law of thermodynamics.
The final system can be written as For ideal gas models, it is often assumed that Then s(ρ, ϑ) = −(k 1 ρ ln ρ − k 2 ρ(ln ϑ + 1)), e(ρ, ϑ) = k 2 ρϑ, ρu = −k 1 ∇(ρϑ). (98) In this case, the non-isothermal system (96) can be simplified as where the last equation follows (90). One can derive a different system by imposing a different kinematics assumption on the temperature and the entropy. For instance, we can assume that the temperature ϑ is independent of the flow map x(X, t) during the purely mechanics processes, which leads to a simple kinematics ∂ t ϑ = 0. The force balance Equation (88) becomes η(ρ)u = −ρ∇µ. In this case, the kinematics of the entropy becomes Again, * is the density of the entropy production, and q ϑ is the entropy flux defined by Clausius-Duhem relation. Following the same procedure, one can show that the entropy production is same as in (95). We refer the interested reader to [98] for a detailed derivation.
The formulations (91) and (100) are the differential version of the entropy balance equation [52,99] d dt introduced by Prigogine in [100] as a modern formulation of the second law of thermodynamics (See 3.4 in [52]). For mechanical processes, S = V s(x, t)dx is the entropy in the control volume V, d e dt S = ∂V J e dS is the entropy change due to the exchange of matter and energy with J e being the entropy flux [52], while d i dt S = V * dx ≥ 0 is the entropy change due to irreversible process, i.e., the entropy production. The Clausius-Duhem relation specifies J e = q ϑ . For systems involving chemical reactions, since the system is not determined by the flow map x(X, t) alone, it is natural to assume that the temperature also depends on the reaction trajectory R [43]. The remaining derivation is almost same as for the mechanical system.

Coarse-Graining and Numerical Realization
In this section, we briefly review some applications of the EnVarA in developing structure-preserving numerical schemes [28,57,101] and thermodynamically consistent coarse-grained models [91].
One of the fundamental questions in developing numerical schemes is how to preserve the properties of the original systems as much as possible. Different mathematical representations of physical principles can lead to different structure-preserving methods [102]. For dissipative systems modeled by the EnVarA, the most important structures are the underlying variational structures and the kinematic constraints of physical variables, such as positivity and the conservation property of a mass density, and the conservation of current for a charged system.
In [28], the authors introduced a numerical framework called the discrete energetic variational approach to preserve the energetic variational structure in the semi-discrete level. The approach first seeks a finite dimensional realization to a continuous energy-dissipation law, given by d dt where Ξ(t) = (Ξ 1 (t), Ξ 2 (t), . . . , Ξ K (t)) ∈ R K is the discrete state variable, E h (Ξ) is the discrete total energy that is the sum of the discrete kinetic energy K h (Ξ, Ξ ) and the discrete free energy F h (Ξ), and h (Ξ(t), Ξ (t)) = 2D h is the discrete energy dissipation. The discrete energy-dissipation (102) law can be obtained by introducing a suitable spatial discretization to the original system by Eulerian [103], Lagrangian [28,101], or particle approximations [104]. From the discrete energy-dissipation law (102), one can obtain an ODE system of Ξ(t), given by by the energetic variational approach. Here, A h (Ξ(t)) = )dt is the discrete action functional. In the case that K h = 0 and D h (Ξ(t), Ξ (t)) is a quadratic function of Ξ , the ODE system of Ξ(t) can be written as where M(Ξ(t)) is a K × K matrix. The discrete energetic variational approach follows the idea of "discretize-then-variation", which has been used to study both Hamiltonian and dissipative systems [18,[105][106][107][108][109][110]. An advantage of this Ritz-type variational approach is that the resulting system inherits the variational structure from the continuous level, which enables us to apply these variational temporal discretizations [111][112][113]. For example, an implicit Euler discretization to Equation (104) could be reformulated as where S h ad is the admissible set of Ξ and M n * = M(Ξ * ) is the numerical mobility that is independent with Ξ n+1 . The scheme is also known as the minimizing movement scheme [114,115]. Although in general, the optimization problem (105) is non-convex in a non-convex admissible set S h ad , one can use some line search-based optimization method to update Ξ n+1 ∈ S h ad such that F h (Ξ n+1 ) ≤ F h (Ξ n ). The existence of a minimizer of J n (Ξ) that decreases the total energy and the convergence of the numerical scheme at the discrete level can be proved under suitable conditions on F h (Ξ) [101,112,116]. A smaller τ can be chosen such that the optimization problem can be solved by some standard optimization method.
Similarly, the BDF2 scheme or a modified Crank-Nicolson scheme can also be reformulated as a minimization problem due to the variational structure in the semi-discrete level [113,117]. Other temporal discretization techniques, such as convex splitting [118][119][120][121], invariant energy quadratization (IEQ) [122,123], scalar auxiliary variable (SAV) [124,125], the discrete variational derivative method [105,126], and the strong stability-preserving (SSP) time discretizations [127] can also be applied to the semi-discrete system. In some applications, if the goal is to compute equilibrium states and the phase diagram, one can use some optimization method, such as the L-BFGS, to minimize the discrete free energy F h (Ξ) directly. Using the approach, we studied various confined liquid crystal systems [103,[128][129][130].
The idea of "approximation-then-variation" can also be used to develop a dynamic coarse-grained model from a detailed multiscale model [18]. Similar to numerical approximations, the aim of coarse-graining is to reduce the degrees of freedom of the original system but preserve the properties of the original systems as much as possible. Closure approximation is one typical approach to develop coarse-grained models. The idea of closure approximation in to use the evolution equation of moments to represent the evolution of the probability density in the original Fokker-Planck type equations.
In [91], the authors studied maximum closure approximations to the micro-macro model of a wormlike micellar solution (79) by using "closure-then-variation". The idea is to apply the closure approximation to the energy dissipation law first. Let A and B be the second moment of ψ A and ψ B , and n α be the number density of species α. By applying the energetic variational approach in the coarse-grained level, we can obtain a thermodynamically consistent closure model for both mechanical and chemical parts of the system. In more detail, within the assumption that A = n A A and B = n B B, the free energy, obtained by the maximum entropy closure, can be reformulated in terms of number density n A and n B , and the conformation tensor of two species A and B, given by We impose the kinematics for the number density to account for the macroscopic breakage and reforming procedure: ∂ t n A + ∇ · (n A u) = −R n , ∂ t n B + ∇ · (n B u) = 2R n , where R n is the macroscopic reaction trajectory. The dissipation of the moment closure system consists of three parts: the viscosity of the macroscopic flow, the evolution of the conformation tensors, and the reaction on the number density, which can be formulated as * = ν|∇u| 2 + tr where d• dt = ∂ t • +(u · ∇) • −(∇u) • − • (∇u) T is the kinematic transport of the conformation tensor, M A (n A , A) and M B (n B , B) are mobility matrices. D chem (R n , ∂ t R n ) is the dissipation for breakage and reforming at the macroscopic scale. A typical choice of D chem (R n , ∂ t R n ) is D chem (R n , ∂ t R n ) = ∂ t R n ln ∂ t R n η n (R n ) + 1 .
The choice of η n (R n ) determines the macroscopic reaction rate in the closure system. By taking 1/η n (R n ) = k 2 (B)n 2 B exp(tr(τ B )/n B )/ det(H B B) with k 2 (B) = k 2 n d/2 B /(2 d (π) d/2 (det(B)) 1/2 , and applying the energetic variational approach, we can obtain the final moment closure system ρ(∂ t u + (u · ∇)u) + ∇p = η∆u + λ∇ · (H A A + H B B − (n A + n B )I), ∇ · u = 0, ∂ t n A + ∇ · (n A u) = −k neq 1 n A + k neq 2 n 2 B , ∂ t n B + ∇ · (n B u) = 2k . One can view (110) as a dynamics restricted in the sub-manifold formed by quasi-equilibrium states, in which A = n A A and B = n B B. It is clear that the fluctuations on the number density n A and n B will create an active stress tensor in the macroscopic momentum equation. The resulting closure system is similar to the VCM [86] and GCB models [87]. Numerical simulations in [91] show that the momentum closure model can capture the key rheological features of wormlike micellar solutions as the VCM and GCB models.

Conclusions
In this paper, we briefly review some recent advances related to the energetic variational approaches, by examples. The general framework of EnVarA provides a thermodynamically consistent description to a complicated chemo-mechanical system involving couplings and competitions, such as the energetics vs. kinematics, the macroscopic hydrodynamics vs. micro-structures, the reversible vs. irreversible, the mechanics vs. chemistry, and the deterministic vs. stochastic. It is a powerful tool to study multiscale and multi-physics problem arising in physics, chemistry, and biology. The current review only sketches the underlying variational structure of several complex fluid models with chemo-mechanical coupling and non-isothermal effects; all these models require lots of investigation, both theoretically and numerically.