Skip to content

Thermodynamics and Diffusion in Multiphase-Field Modeling (OpenPhase)

This chapter introduces the thermodynamic and diffusion treatment in OpenPhase for multiphase-field simulations.


1. Governing Equation for Phase Evolution

In the multiphase-field method, each phase ϕα evolves according to

(1)ϕ˙α=β=1βαNMαβN[γ=1γβN(σβγσαγ)Iγ+πηϕαϕβΔg¯αβ].

Here:

  • Mαβ: interface mobility,
  • σαβ: interface energy,
  • Iγ: geometrical function of interface orientation,
  • Δg¯αβ: thermodynamic driving force (see Section 2).

This formulation couples interfacial thermodynamics with kinetics: the interfacial term (surface energy differences) and the thermodynamic driving force (undercooling) together determine how the phase fields evolve.

Where does Δg¯αβ come from?
It stems from compositional undercooling relative to equilibrium, derived in Section 2, and is consistent with the partitioning rules discussed in Sections 3–5.


2. Thermodynamic Driving Force

The thermodynamic driving force between two phases α and β is given by the undercooling:

(2)Δgαβ=ΔSαβΔTαβ,ΔTαβ=mαβΔcαβ=mαβ(cαcαeq),

with:

  • ΔSαβ: entropy difference,
  • mαβ: slope of the liquidus/solidus line,
  • Δcαβ: deviation from equilibrium concentration.

Thus, the driving force is controlled by the undercooling relative to equilibrium.
The equal-undercooling condition is the cornerstone of the partitioning relations used in Section 3 and generalized to multiphase junctions in Section 4.

Engineering note. The quantity mαβ is direction-specific (ordered pair) and its ratio forms the partitioning coefficient Kαβ=mαβ/mβα used explicitly in Sections 4.1–4.2.


3. Partitioning at Interfaces

At an αβ interface, solute concentrations in the phases are determined by:

  1. Mass conservation:

(3)ϕαcα+ϕβcβ=cTotal,
  1. Partitioning condition (equal undercooling):

(4)mαβ(cαc¯αβ)=mβα(cβc¯αβ),

with c¯αβ the intersection point of the tangent slopes.

This system of linear equations yields unique solutions for cα and cβ.
These pairwise relations are consistent with the driving-force definition in Section 2.

Tip. In binaries, this reproduces the classical lever-rule geometry on the phase diagram.
In practice, OpenPhase resolves pairwise partitioning exactly on two-phase interfaces and uses the schemes of Section 4 at multi-junctions.


4. Multiphase Junctions

When more than two phases meet, enforcing all pairwise partitioning conditions from Section 3 makes the system overdetermined.
OpenPhase provides three schemes to resolve this:

4.1 Two-Step Scheme

  1. Compute the total deviation from equilibrium:

(5)ΔcTotal=cTotalαϕαcαeq.
  1. Redistribute solute according to:

(6)cα=cαeq+ΔcTotal[βαϕβ]1βαϕβϕα+Kβαϕβ.

where Kαβ=mαβ/mβα (see Section 2).

Rationale (engineering intuition). Two-Step is a rule-of-mixtures redistribution of the global deviation ΔcTotal, weighted by neighboring phase fractions and partition coefficients.

4.2 Eiken Scheme

Based on [1]:

(7)cα=cTotalβϕβ(cβeqcαeqKαβ)βϕβKαβ.

Rationale. Eiken embeds the slope consistency more directly via Kαβ and generally yields better thermodynamic fidelity than Two-Step, especially when slopes are highly asymmetric.

4.3 Optimization Scheme

Does not rely on pairwise partitioning, but minimizes deviation from equilibrium:

(8)min12αβαmαβ(cαcαeq)2,

subject to global mass conservation:

(9)cTotal=αϕαcα.

Rationale. This enforces a global, consistent solution across all phases. It is the most robust in complex multi-junctions and multicomponent systems.


5. Independent Partitioning of Components

In multicomponent alloys, each component partitions independently:

  • For component i at an αβ interface:

(10)ϕαcαi+ϕβcβi=cTotali,

(11)mαβi(cαic¯αβi)=mβαi(cβic¯αβi).
  • Partition coefficients Kαβi=mαβi/mβαi are component-specific.

This modular treatment means that solutes A, B, C, … are redistributed independently, with coupling only via the underlying thermodynamics (e.g., CALPHAD databases).
This independence is consistent with the diffusion treatment per component in Section 7 and the reference-element constraint in Section 6.


6. Reference Element in OpenPhase

OpenPhase uses a reference element (typically the solvent).

  • The concentrations satisfy:

(12)cref+ici=1,

where cref is the concentration of the reference element and ci are the solute components.

  • The reference element is not explicitly diffused; it is defined implicitly from the other components.

  • This ensures:

    • Mass conservation,
    • Reduction of numerical effort (one fewer diffusion equation),
    • A natural treatment of solvent-based alloys.

This constraint integrates seamlessly with independent partitioning (Section 5) and diffusion (Section 7).


7. Diffusion of Phase Concentrations (Fick’s Law)

Once partitioned, solute evolves by diffusion:

  • Fick’s first law in phase α:

(13)Jαi=Dαicαi,
  • Fick’s second law:

(14)cαit=(Dαicαi).
  • Mixture concentration:

(15)ci(x,t)=αϕα(x,t)cαi(x,t).

This ensures solute conservation during diffusion and phase transformation.
During interface motion, the partitioning schemes (Section 4) determine instantaneous interfacial split, while Fickian diffusion relaxes gradients within phases.


8. Antitrapping Flux

Why it is needed

The diffuse interface used in simulations is much thicker than in reality.
When the interface moves, this can cause artificial solute trapping—a numerical artifact that would otherwise corrupt the physically correct partitioning from Sections 3–5.

Correction

An antitrapping flux is added:

(16)Ji=αϕαDαicαi+Jati,

with

(17)Jati=aWϕαtn^(cαicβi).
  • a: numerical constant,
  • W: interface width,
  • n^: interface normal,
  • (cαicβi): solute contrast.

This term counteracts non-physical solute storage in the diffuse interface and vanishes in the sharp-interface limit. It works in tandem with Fickian diffusion (Section 7) to maintain correct solute transport.


9. Engineering Takeaway

  • OpenPhase enforces thermodynamic consistency via partitioning schemes (Sections 3–4).
  • Each component is partitioned independently (Section 5), with one reference element determined implicitly (Section 6).
  • Diffusion transports solute within each phase (Section 7), and antitrapping flux corrects artifacts from diffuse interfaces (Section 8).
  • Engineers can select the partitioning scheme depending on the balance between accuracy and computational cost (Section 9).

Together, these features allow OpenPhase to realistically simulate solidification, precipitation, grain growth, and phase transformations in engineering alloys.


10. Implementation in OpenPhase

To make practical use of the concepts described above, OpenPhase provides a set of classes and interfaces that handle thermodynamic data, diffusion, and partitioning.

If expanding the User Driving Force example, the following additional objects are needed:

cpp
    Composition                      Cx(OPSettings,InputFile);
    ThermodynamicPropertiesEQP       TP(OPSettings,InputFile);
    DiffusionProperties              DP(OPSettings,InputFile);
    ThermodynamicInterfaceLPD        TQ(OPSettings,InputFile);
    ThermokineticInterface           TK(OPSettings,InputFile);
    ChemicalDiffusion                DF(OPSettings,InputFile);
    EquilibriumPartitioning          EQP(OPSettings,InputFile);
  • Composition is a storage class that stores total and phase compositions.
  • ThermodynamicPropertiesEQP and DiffusionProperties store the relevant data for thermodynamics such as slopes, equilibrium concentrations, and diffusion coefficients.
  • ThermodynamicInterfaceLPD reads thermodynamic data from a linearized phase diagram stored in an OPID file (see OPID Format).
  • ThermokineticInterface reads kinetic data in Arrhenius form from an OPID file.
  • ChemicalDiffusion handles diffusion and the antitrapping flux (see Section 8).
  • EquilibriumPartitioning handles the calculation of phase concentrations and the thermodynamic driving force (see Section 2 and Section 3).

10.1 Timeloop Expansion

The timeloop from the UserDrivingForce example can be expanded as follows:

cpp
        IP.Set(Phi, Tx, BC);
        DO.CalculatePhaseFieldIncrements(Phi, IP, dG);

        TP.CheckRange(Phi,Cx,Tx);

        TQ.SetEquilibriumData(Phi,Cx,Tx,TP);
        EQP.CalculatePhaseConcentrations(Phi,Cx,Tx,TP,BC);

        TK.SetDiffusionData(Phi,Cx,Tx,DP);

        TP.CalculateDrivingForce(Phi,IP,Cx,Tx,dG);
        dG.Average(Phi, BC);
        dG.MergePhaseFieldIncrements(Phi, IP);

        Phi.NormalizeIncrements(BC, RTC.dt);

        DF.Solve(Phi,Cx,Tx,DP,TP,BC,RTC.dt);

        Phi.MergeIncrements(BC, RTC.dt);

10.2 Step-by-Step Explanation

  • TP.CheckRange(Phi,Cx,Tx)
    Checks if thermodynamic data needs to be updated because temperature or composition changed significantly.

    • Thresholds are defined in the OPI file:
      • $MDev for mole fraction changes,
      • $TDev for temperature changes,
      • under the section @ThermodynamicPropertiesEQP.
  • TQ.SetEquilibriumData(Phi,Cx,Tx,TP)
    Sets the equilibrium phase concentrations for the current total composition and temperature in each grid point.

  • EQP.CalculatePhaseConcentrations(Phi,Cx,Tx,TP,BC)
    Calculates the phase concentrations using one of the partitioning schemes (see Section 4).

  • TK.SetDiffusionData(Phi,Cx,Tx,DP)
    Obtains diffusion coefficients from the thermokinetic interface.

  • TP.CalculateDrivingForce(Phi,IP,Cx,Tx,dG)
    Calculates the thermodynamic contribution to the driving force using the governing equation introduced in Section 1.

  • Phi.NormalizeIncrements(BC, RTC.dt)
    Normalizes the phase-field increments to ensure stability and consistency.

  • DF.Solve(Phi,Cx,Tx,DP,TP,BC,RTC.dt)
    Solves the diffusion equation, including the antitrapping flux correction (see Section 8) if activated in the OPI file.

  • Phi.MergeIncrements(BC, RTC.dt)
    Final update of the phase fields with the computed increments.


See also

References

[1] J. Eiken et al. (2006). Multiphase-field approach for multicomponent alloys with extrapolation scheme for numerical application. Physical Review E, 73, 066122. DOI: 10.1103/PhysRevE.73.066122

Released under the GNU GPLv3 License.