SlideShare a Scribd company logo
Multi-phase-field simulations
with OpenPhase
Marvin Tegeler, Johannes Görler, Alexander Monas, Oleg Shchyglo and Ingo Steinbach
Interdisciplinary Centre for Advanced Materials Simulation, Ruhr-Universität Bochum, Bochum, Germany
2
Coarsening
Diffusion
Large
Deformation
Plasticity
Damage
Flow
OpenPhase Toolbox
• Physics-based microstructure
simulation framework.
• 100 man-years of research
and development since 2009
• Code is based on the multi-
phase field multi-component
PF-model
• Object oriented code written
in C++
• Modular structure allowing for
easy extension by addition of
new modules
3
Coarsening
Diffusion
Large
Deformation
Plasticity
Damage
Flow
OpenPhase Toolbox
• Simulation of coarsening and
ripening.
• Minimization of interfacial
energy leads to a realistic
grains size distribution:
• Examples:
• Tempering of steels.
• Coarsening of carbides.
4
Coarsening
Diffusion
Large
Deformation
Plasticity
Damage
Flow
OpenPhase Toolbox
• Simulation of multi-
component diffusion fluxes.
• Data from thermodynamic
and kinetic databases.
Supported interfaces to
.
• Examples:
• Segregation profiles
after solidification.
• Diffusion controlled
transformations.
g
5
OpenPhase Toolbox
g
• Simulation of deformations
up to several hundred
percents.
• Examples:
• Hot rolling of steels.
• Virtual tensile tests.
Coarsening
Diffusion
Large
Deformation
Plasticity
Damage
Flow
6
Coarsening
Diffusion
Large
Deformation
Plasticity
Damage
Flow
OpenPhase Toolbox
• Simulation of plastic
deformation.
• Reduction of elastic stresses
by plastic deformation. Full
implementation of a crystal
plasticity model.
• Examples:
• Creep deformation in Ni-
base superalloys
• Martensite in metals.
g
7
Coarsening
Diffusion
Large
Deformation
Plasticity
Damage
Flow
OpenPhase Toolbox
• Simulation of the effect of
mesoscopic damage in the
microstructure.
• Reduction of stiffness and
yield strength depending on
plastic strain.
• Examples:
• Virtual tensile tests.
• Simulation of creep
deformation.
8
Coarsening
Diffusion
Large
Deformation
Plasticity
Damage
Flow
OpenPhase Toolbox
• Simulation of liquid flow.
• Solving Lattice-Boltzmann
method under consideration
of solid grains.
g
9
Introduction to the Multiphase Field Method
The Multiphase Field Method
 A tool for the simulation of
microstructure evolution
 A set of continuous scalar functions
 1 in bulk, 0 when phase does not exist.
 Description of regions of different
properties (crystallographic structure,
orientations, etc)
 Motion of interfaces between regions
10
Introduction to the Multiphase Field Method

 compact 27-point stencil
 N = Number of active phase fields in a
grid point
 Active phase fields or
11
Overview
• Mg-Al alloy solidification
• OpenPhase Tutorial
• Parallelization
12
Mg-Al Microstructure and Thermodynamics
 Mg-Al alloys microstructure consist
of α-phase (HCP-Mg dendrites)
surrounded by closed shell Mg17Al12
β-phase
 properties as corrosion resistance
depend on the microstructure
Goal:
 Modeling as cast microstructures
using the phase field model
200µm
13
Experimental as-cast Mg-Al Microstructure
0.3 K/s 1.0 K/s 25 K/s
1 mm
(a): furnace control (b): air cooling (c): water cooling
14
Nucleation Modeling
 Create a list of virtual particles, that satisfies a given
nucleation density
 At every time step plant nuclei by creating a phase field
with value zero at the corresponding grid point, if the
parent phase is correct
 Compute driving force , if remove
the corresponding virtual particle from the list, otherwise
remove phase field.
15
Initial temperature: 875 K
Cooling rate: 10 K/s
Initial concentration: 5 at. % Al
System size: 200x200x200 μm
Grid spacing: 1.0 um
Solidification of MgAl
16
Temperature Curves Simulation
17
Effect of cooling rate on solidification microstructure
5 K/s
15 K/s
25 K/s
200µm
Mg-5at.%Al
α-Mg
β-Mg
18
α- and β-phase nucleation during solidification
α-Mg
β-Mg
 Primary α-phase dendrites fill
most of the volume.
 Secondary β-phase fills
interdendritic region.
19
Evolution of microstructure during solidification
α-Mg
β-Mg
100µm
300³ µm = 27 mio cells
one week calculation
time on 96 cores
20
100µm
Evolution of microstructure during solidification
100µm
21
3D Secondary β-phase Nucleation and Growth Modeling
α
β
100µm
22
3D Secondary β-phase Nucleation and Growth Modeling
20µm
23
α
α
β
20µm
Rapid coverage of α-liquid-interface with β-phase
 β-phase covers the α-liquid-interface
 Further β-phase growth depletes enclosed melt
 Nucleation of tertiary α-phase is neccessary for complete
solidification
Monas A et al.; “Divorced Eutectic Solidification of Mg-Al Alloys”, JOM (2015)
24
Mg-Al β-phase formation: experiment vs simulation
100µm 5µm
SEM-image of Mg-5%Al microstructure and enlarged view on the eutectic region.
dark: α-phase, bright: β-phase
Se-Jong Kim, Chang Dong Yim, KIMS, Korea
25
Tutorial
OpenPhase can be downloaded at
http://www.openphase.de/upload/content/OpenPhase.V0.9.1.zip
The tutorial will use the SolidificationMgAl example.
In order to compile the OpenPhase library just run 'make' in the main directory.
To compile an example call ‘make’ in the corresponding directory.
26
Load Modules
int main(int argc, char *argv[])
{
Settings OPSettings;
OPSettings.Initialize();
OPSettings.ReadInput();
PhaseField Phi(OPSettings);
DoubleObstacle DO(OPSettings);
InterfaceMobility Mu(OPSttings);
InterfaceEnergy Sigma(OPSettings);
InterfaceEnergySolidLiquid IE(OPSettings);
EquilibriumPartitionDiffusion DF(OPSettings);
Composition Cx(OPSettings);
Temperature Tx(OPSettings);
DrivingForce dG(OPSettings);
BoundaryConditions BC(OPSettings);
Nucleation Nuc(OPSettings);
27
ProjectInput.opi
28
Load Modules
dG.ReadInput();
Cx.ReadInput();
DF.ReadInput();
Tx.ReadInput();
BC.ReadInput();
Nuc.ReadInput();
Mu.ReadInput();
Sigma.ReadInput();
IE.ReadInput();
int id = Initializations::Single(Phi, 0, BC, OPSettings);
Phi.FieldsStatistics[id].State= Liquid;
DF.SetInitialComposition(Phi, Cx);
Tx.SetInitial(BC, Phi, 0);
29
ProjectInput.opi
30
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
31
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Generates nucleation sites with a random size distribution the
first time this function is called.
32
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Plant nuclei at the generated sites.
Add storage for a phase field with value zero.
33
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Calculate interface stiffness
34
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Calculate interface mobility
35
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Calculate the sum of phase fields belonging to the same thermodynamic
phase in each grid point.
36
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Calculate the double obstacle potential for αβ-interfaces
37
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Calculate driving force
38
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
The correct phase field profile across the interface can only be obtained if the
driving force is constant across the interface and varies only along the
interface.
Therefore we calculate an average driving force , that is constant along
the normal direction of the interface.
39
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt)}
The correct phase field profile across the interface can only be obtained if the
driving force is constant across the interface and varies only along the
interface.
Therefore we calculate an average driving force , that is constant along
the normal direction of the interface.
The average is calculated in two steps
with
40
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Check driving force of nuclei. Sucessfully planted nuclei are removed from
the list of nucleation sites.
41
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Compute interface fields for the chemical driving force
42
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Limit interface fields , so that the phase fields stay within bounds [0,1].
43
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Solve diffusion equation for the phase concentrations
44
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Compute the phase field update
45
Work Loop
for(int tStep = OPSettings.tStart + 1; tStep <
OPSettings.nSteps + 1; tStep++)
{
Nuc.GenerateNucleationSites(Phi, Tx);
Nuc.PlantNuclei(Phi, tStep);
Sigma.CalculateHex(Phi);
Mu.CalculateHex(Phi, Tx);
DF.SetPhaseFractions(Phi);
DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu);
DF.GetDrivingForce(Phi, Cx, Tx, dG);
dG.Average(Phi, BC);
Nuc.CheckNuclei(Phi, Sigma, dG, tStep);
dG.MergePhaseFieldIncrements(Phi, Sigma, Mu);
Phi.NormalizeIncrements(BC, dt);
DF.Solve(Phi, Cx, Tx, BC, dt);
Phi.MergeIncrements(BC, dt);
Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt);
}
Compute temperature update
46
OpenPhase Solutions GmbH
• A company has been founded that offers support
• Focused on industry
• GUI is in development
• Creation of ProjectInput.opi
• Creation of the .cpp file
• Sanity check on input values
• GUI will be commercial software
• OpenPhase will stay free
Johannes Görler
Matthias Stratmann
47
Parallelization
MPI-Parallelization
48
Parallelization
Thread (OpenMP)
 Simultaneous execution of
sequences of instruction
 Shared address space
Process (MPI)
 Instance of a program
 Own address space
 Message Passing
All cores should be
used efficiently
49
Parallelization
 Active phase fields or
 Dynamic storage for active phase field
 Contributions to the evolution equation only by
active phase fields
 Locally and temporally different number of active
phase fields
 Number of operations in each grid point can be
different and can change over time.
50
Parallelization
• OpenPhase uses stencil operations
• Domain decomposition to divide the work onto multiple processes
51
Parallelization
Use a domain decomposition to divide the work onto multiple processes.
52
Parallelization
The wide halo avoids communication at the expense of additional work.
This is used to limit us to one communication step per time step.
53
Load-balancing by Graph-partitioning
Over-decomposition
 Division of the domain into many more sub-domains
(blocks) than processes.
 Assignment of these sub-domains to processes
 Goal: minimize communication and load-imbalance.
54
Load-balancing by Graph-partitioning
Assignment of sub-
domains to processes.
 Simultaneous
minimization of imbalance
and communication
 Graph-partitioning
problem with vertex
weights
 Coloring of the graph with
minimal edge cut
 Constrainted sum of the
vertex weights with the
same color
Block ↔ Vertex
Communication ↔ Edge
Load ↔ Weight
Problem:
No accurate current polynomial algorithm
55
Load-balancing by Graph-partitioning
Greedy Graph-Partitioner
1. Start with color n = 1
2. Choose an uncolored vertex that
increases the edge cut the least
3. Color it with color n
4. If the sum of vertex weights with
color n is larger than set
n = n+1
5. If there are any uncolored vertices,
go to 2
56
Load-balancing by Graph-partitioning
Greedy Graph-Partitioner
1. Start with color n = 1
2. Choose an uncolored vertex that
increases the edge cut the least
3. Color it with color n
4. If the sum of vertex weights with
color n is larger than set
n = n+1
5. If there are any uncolored vertices,
go to 2
57
Load-balancing by Graph-partitioning
Graph Partitioning
 The Greedy Graph-Partitioner fulfills
 Because the last vertex added to each color fulfills
 Total work on process i.
 Average work .
 Maximum work among blocks.
Reducing limits the maximum load-imbalance.
This can be achieved by splitting blocks into smaller blocks.
58
Load-balancing by Graph-partitioning
Splitting Blocks, however, creates additional work
After splitting the most costly block the inequality becomes
59
Load-balancing by Graph-partitioning
Repeated splitting of the largest block gives
Allowing the same block to be split multiple times gives
Problem: The cost of splitting is unknown.
60
Load-balancing by Graph-partitioning
Problem: The cost of splitting is unknown.
 Self-Profiling in order to approximate the cost.
 Measure time for computations on each block.
 Fit parameters in a cost function
 that maps the number of phase fields in
each grid point to the computation time.
 This information is also used to determine the
optimal cutting plane.
61
Load-balancing by Graph-partitioning
62
Load-balancing by Graph-partitioning
63
Load-balancing by Graph-partitioning
Load-imbalance
Tolerance
Maximum Block
Maximum Process
Wall Time
64
Load-balancing by Graph-partitioning
Load-imbalance
Tolerance
Maximum Block
Maximum Process
Wall Time
65
Load-balancing by Graph-partitioning
Weak-Scaling Benchmark
Pure MPI
 96x48x48 grid
points per
core.
 2 particles per
core
 Gaussian
distribution
66
Load-balancing by Graph-partitioning
Weak-Scaling Benchmark
Hybrid
MPI+OpenMP
 96x48x48 grid
points per
core.
 2 particles per
core
 Gaussian
distribution
67
Load-balancing by Graph-partitioning
Hybrid-Parallelism reduces the
number of MPI-processes.
The number of blocks is reduced,
the blocks become larger.
Less overhead is created by the
wide halo.
A large number of threads loses
efficiency.
Only one thread per process
participates in communication.
Threads created on different sockets
can have slow memory access.
The best performance was seen with 6 or 12 threads per process.
68
Load-balancing using Phase Field
Load-balancing aims at simulatenous
reduction of idle time and communication.
Sub-domains need to
have the same
amount of work.
Surface between
sub-domains should
be minimized.
Idle time Communication
With an appropriate driving force the
multiphase field method can achieve this.
69
Load-balancing using Phase Field
 Domain decompostion with one sub-domain per process .
 Each process is associated with a phase field .
 The associated sub-domain is determined by the phase field .
 Balancing of the work between adjacent domains and by a driving force
that drives the interface into the direction of the higher computational load.
 An isotropic interface energy reduces the surface area between domains.
70
Load-balancing using Phase Field
Application to the Phase Field Method
 Two instances of phase field
 Simulation
 Load-balancing
 Using Wide Halo
71
Load-balancing using Phase Field
Application to the Phase Field Method
 Two instances of phase field
 Simulation
 Load-balancing
 Using Wide Halo
 Both on the same rectangular sub-
domain
 Interior points of the sub-domains can
overlap.
72
Load-balancing using Phase Field
Comparison with the previous load-
balancing scheme.
73
Load-balancing using Phase Field
Convergence of load-balance
 96 MPI processes
 20% Tolerance
74
Load-balancing using Phase Field
Convergence of load-balance
 96 MPI processes
 5% Tolerance
75
Load-balancing using Phase Field
Application to the Phase Field Method
 Two instances of phase field
 Simulation
 Load-balancing
 Using Wide Halo
 Both on the same rectangular sub-
domain , in which is the majority
phase.
 Interior points of the sub-domains can
overlap.
76
Load-balancing using Phase Field
Applied to Molecular Dynamics
 Cell-based molecular dynamics
 Lennard-Jones potential
 Start with a simple domain decomposition
 Colors indicate processes
 The phase fields are only updated with a probability of
With the maximum load among processes 𝜔 𝑚𝑎𝑥, the number of processes 𝑁 𝑝 and the
average time for load-balancing 𝑇𝐿𝐵.
77
Load-balancing using Phase Field
78
Two Spheres Move Over Periodic Boundary
79
Load-balancing using Phase Field
80
Summary
 OpenPhase is a flexible multi-phase-field framework,
that can handle an arbitrary number of phase fields
for a variety of applications
 MPI and OpenMP parallelization allow an efficient
usage of computational resources.
81
Summary
 OpenPhase is a flexible multi-phase-field framework,
that can handle an arbitrary number of phase fields
for a variety of applications
 MPI and OpenMP parallelization allow an efficient
usage of computational resources.
Thank you!

More Related Content

What's hot

Computational Performance of Phase Field Calculations using a Matrix-Free (Su...
Computational Performance of Phase Field Calculations using a Matrix-Free (Su...Computational Performance of Phase Field Calculations using a Matrix-Free (Su...
Computational Performance of Phase Field Calculations using a Matrix-Free (Su...
Stephen DeWitt
 
Basics of DFT+U
Basics of DFT+U Basics of DFT+U
Basics of DFT+U
Burak Himmetoglu
 
Introduction to DFT Part 1
Introduction to DFT Part 1 Introduction to DFT Part 1
Introduction to DFT Part 1
Mariana M. Odashima
 
Software tools for calculating materials properties in high-throughput (pymat...
Software tools for calculating materials properties in high-throughput (pymat...Software tools for calculating materials properties in high-throughput (pymat...
Software tools for calculating materials properties in high-throughput (pymat...
Anubhav Jain
 
Computational materials design with high-throughput and machine learning methods
Computational materials design with high-throughput and machine learning methodsComputational materials design with high-throughput and machine learning methods
Computational materials design with high-throughput and machine learning methods
Anubhav Jain
 
Approximations in DFT
Approximations in DFTApproximations in DFT
Approximations in DFT
Claudio Attaccalite
 
Magnetocaloric effect and magnetic field-induced martensitic transformation i...
Magnetocaloric effect and magnetic field-induced martensitic transformation i...Magnetocaloric effect and magnetic field-induced martensitic transformation i...
Magnetocaloric effect and magnetic field-induced martensitic transformation i...
Universidad de Oviedo
 
BoltzTrap webinar116_David_J_Singh.pdf
BoltzTrap webinar116_David_J_Singh.pdfBoltzTrap webinar116_David_J_Singh.pdf
BoltzTrap webinar116_David_J_Singh.pdf
DrSanjaySingh13
 
Superconductivity
Superconductivity Superconductivity
Superconductivity
Tamojit Das
 
Ab initio md
Ab initio mdAb initio md
Ab initio md
yudhaarman
 
NANO266 - Lecture 13 - Ab initio molecular dyanmics
NANO266 - Lecture 13 - Ab initio molecular dyanmicsNANO266 - Lecture 13 - Ab initio molecular dyanmics
NANO266 - Lecture 13 - Ab initio molecular dyanmics
University of California, San Diego
 
Metalurji termodinamigi eylul 2011
Metalurji termodinamigi eylul 2011Metalurji termodinamigi eylul 2011
Metalurji termodinamigi eylul 2011
s_talas
 
Review paper (PPT) on Graphene.pptx
Review paper (PPT) on Graphene.pptxReview paper (PPT) on Graphene.pptx
Review paper (PPT) on Graphene.pptx
SHIVCHARAN KUMAR
 
Density functional theory (DFT) and the concepts of the augmented-plane-wave ...
Density functional theory (DFT) and the concepts of the augmented-plane-wave ...Density functional theory (DFT) and the concepts of the augmented-plane-wave ...
Density functional theory (DFT) and the concepts of the augmented-plane-wave ...
ABDERRAHMANE REGGAD
 
Dft presentation
Dft presentationDft presentation
Dft presentation
Saibalendu Sarkar
 
Graphene
GrapheneGraphene
Density Functional Theory
Density Functional TheoryDensity Functional Theory
Density Functional Theory
krishslide
 
Perovskite solar cells
Perovskite solar cells Perovskite solar cells
Perovskite solar cells
kidist w.
 
Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)
Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)
Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)
Syed Ali Afzal
 
Presentation bi2 s3+son
Presentation bi2 s3+sonPresentation bi2 s3+son
Presentation bi2 s3+son
ABDERRAHMANE REGGAD
 

What's hot (20)

Computational Performance of Phase Field Calculations using a Matrix-Free (Su...
Computational Performance of Phase Field Calculations using a Matrix-Free (Su...Computational Performance of Phase Field Calculations using a Matrix-Free (Su...
Computational Performance of Phase Field Calculations using a Matrix-Free (Su...
 
Basics of DFT+U
Basics of DFT+U Basics of DFT+U
Basics of DFT+U
 
Introduction to DFT Part 1
Introduction to DFT Part 1 Introduction to DFT Part 1
Introduction to DFT Part 1
 
Software tools for calculating materials properties in high-throughput (pymat...
Software tools for calculating materials properties in high-throughput (pymat...Software tools for calculating materials properties in high-throughput (pymat...
Software tools for calculating materials properties in high-throughput (pymat...
 
Computational materials design with high-throughput and machine learning methods
Computational materials design with high-throughput and machine learning methodsComputational materials design with high-throughput and machine learning methods
Computational materials design with high-throughput and machine learning methods
 
Approximations in DFT
Approximations in DFTApproximations in DFT
Approximations in DFT
 
Magnetocaloric effect and magnetic field-induced martensitic transformation i...
Magnetocaloric effect and magnetic field-induced martensitic transformation i...Magnetocaloric effect and magnetic field-induced martensitic transformation i...
Magnetocaloric effect and magnetic field-induced martensitic transformation i...
 
BoltzTrap webinar116_David_J_Singh.pdf
BoltzTrap webinar116_David_J_Singh.pdfBoltzTrap webinar116_David_J_Singh.pdf
BoltzTrap webinar116_David_J_Singh.pdf
 
Superconductivity
Superconductivity Superconductivity
Superconductivity
 
Ab initio md
Ab initio mdAb initio md
Ab initio md
 
NANO266 - Lecture 13 - Ab initio molecular dyanmics
NANO266 - Lecture 13 - Ab initio molecular dyanmicsNANO266 - Lecture 13 - Ab initio molecular dyanmics
NANO266 - Lecture 13 - Ab initio molecular dyanmics
 
Metalurji termodinamigi eylul 2011
Metalurji termodinamigi eylul 2011Metalurji termodinamigi eylul 2011
Metalurji termodinamigi eylul 2011
 
Review paper (PPT) on Graphene.pptx
Review paper (PPT) on Graphene.pptxReview paper (PPT) on Graphene.pptx
Review paper (PPT) on Graphene.pptx
 
Density functional theory (DFT) and the concepts of the augmented-plane-wave ...
Density functional theory (DFT) and the concepts of the augmented-plane-wave ...Density functional theory (DFT) and the concepts of the augmented-plane-wave ...
Density functional theory (DFT) and the concepts of the augmented-plane-wave ...
 
Dft presentation
Dft presentationDft presentation
Dft presentation
 
Graphene
GrapheneGraphene
Graphene
 
Density Functional Theory
Density Functional TheoryDensity Functional Theory
Density Functional Theory
 
Perovskite solar cells
Perovskite solar cells Perovskite solar cells
Perovskite solar cells
 
Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)
Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)
Characterization of Single crystal KNN Ceramics (K0.5Na0.5NbO3)
 
Presentation bi2 s3+son
Presentation bi2 s3+sonPresentation bi2 s3+son
Presentation bi2 s3+son
 

Similar to Multi-phase-field simulations with OpenPhase

How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...
How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...
How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...
aimsnist
 
20091029%20 l edit%20by%20cwchang%20(for%20std)
20091029%20 l edit%20by%20cwchang%20(for%20std)20091029%20 l edit%20by%20cwchang%20(for%20std)
20091029%20 l edit%20by%20cwchang%20(for%20std)
ashishkkr
 
summer report final
summer report finalsummer report final
summer report final
Pradeep Kalra
 
Optimization for the fabrication of ternary halide perovskite solar cells via...
Optimization for the fabrication of ternary halide perovskite solar cells via...Optimization for the fabrication of ternary halide perovskite solar cells via...
Optimization for the fabrication of ternary halide perovskite solar cells via...
CHUN-HAO KUNG
 
Avinash_PPT
Avinash_PPTAvinash_PPT
Avinash_PPT
avinash gorde
 
Understanding and predicting CO2 properties - Presentation by Richard Graham ...
Understanding and predicting CO2 properties - Presentation by Richard Graham ...Understanding and predicting CO2 properties - Presentation by Richard Graham ...
Understanding and predicting CO2 properties - Presentation by Richard Graham ...
UK Carbon Capture and Storage Research Centre
 
2.6 latifs 17 dramix pisos sobre pilotes
2.6 latifs 17 dramix pisos sobre pilotes 2.6 latifs 17 dramix pisos sobre pilotes
2.6 latifs 17 dramix pisos sobre pilotes
Latifs Chile
 
Numerical and analytical studies of single and multiphase starting jets and p...
Numerical and analytical studies of single and multiphase starting jets and p...Numerical and analytical studies of single and multiphase starting jets and p...
Numerical and analytical studies of single and multiphase starting jets and p...
Ruo-Qian (Roger) Wang
 
Self-Balancing Multimemetic Algorithms in Dynamic Scale-Free Networks
Self-Balancing Multimemetic Algorithms in Dynamic Scale-Free NetworksSelf-Balancing Multimemetic Algorithms in Dynamic Scale-Free Networks
Self-Balancing Multimemetic Algorithms in Dynamic Scale-Free Networks
Rafael Nogueras
 
INNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATION
INNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATIONINNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATION
INNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATION
ref-iqhub
 
CIOMIN
CIOMINCIOMIN
ALEA:Fine-grain Energy Profiling with Basic Block sampling
ALEA:Fine-grain Energy Profiling with Basic Block samplingALEA:Fine-grain Energy Profiling with Basic Block sampling
ALEA:Fine-grain Energy Profiling with Basic Block sampling
Lev Mukhanov
 
Product & technology portfolio of gridworld
Product & technology portfolio of gridworldProduct & technology portfolio of gridworld
Product & technology portfolio of gridworld
linkedin admin
 
Unconventional Reservoirs Flow modelling challenges
Unconventional Reservoirs Flow modelling challengesUnconventional Reservoirs Flow modelling challenges
Unconventional Reservoirs Flow modelling challenges
Sistema FIEB
 
Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021
Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021
Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021
Rajmohan Muthaiah
 
Molecular Simulation to build models for enzyme induced fit
Molecular Simulation to build models for enzyme induced fit Molecular Simulation to build models for enzyme induced fit
Molecular Simulation to build models for enzyme induced fit
MinSung Kim
 
Heterojunction silicon based solar cells
Heterojunction silicon based solar cellsHeterojunction silicon based solar cells
Heterojunction silicon based solar cells
dinomasch
 
1stSymposiumTALK_Closed_Conduit-Paul_Ghamry
1stSymposiumTALK_Closed_Conduit-Paul_Ghamry1stSymposiumTALK_Closed_Conduit-Paul_Ghamry
1stSymposiumTALK_Closed_Conduit-Paul_Ghamry
Samuel Sunday PAUL, Ph. D., P.Eng.
 
Module PHY6002 Inorganic Semiconductor Nanostructures Lectur.docx
Module PHY6002 Inorganic Semiconductor Nanostructures Lectur.docxModule PHY6002 Inorganic Semiconductor Nanostructures Lectur.docx
Module PHY6002 Inorganic Semiconductor Nanostructures Lectur.docx
moirarandell
 
Process design and analysis of dual phase membanes
Process design and analysis of dual phase membanesProcess design and analysis of dual phase membanes
Process design and analysis of dual phase membanes
RahulA
 

Similar to Multi-phase-field simulations with OpenPhase (20)

How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...
How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...
How to Leverage Artificial Intelligence to Accelerate Data Collection and Ana...
 
20091029%20 l edit%20by%20cwchang%20(for%20std)
20091029%20 l edit%20by%20cwchang%20(for%20std)20091029%20 l edit%20by%20cwchang%20(for%20std)
20091029%20 l edit%20by%20cwchang%20(for%20std)
 
summer report final
summer report finalsummer report final
summer report final
 
Optimization for the fabrication of ternary halide perovskite solar cells via...
Optimization for the fabrication of ternary halide perovskite solar cells via...Optimization for the fabrication of ternary halide perovskite solar cells via...
Optimization for the fabrication of ternary halide perovskite solar cells via...
 
Avinash_PPT
Avinash_PPTAvinash_PPT
Avinash_PPT
 
Understanding and predicting CO2 properties - Presentation by Richard Graham ...
Understanding and predicting CO2 properties - Presentation by Richard Graham ...Understanding and predicting CO2 properties - Presentation by Richard Graham ...
Understanding and predicting CO2 properties - Presentation by Richard Graham ...
 
2.6 latifs 17 dramix pisos sobre pilotes
2.6 latifs 17 dramix pisos sobre pilotes 2.6 latifs 17 dramix pisos sobre pilotes
2.6 latifs 17 dramix pisos sobre pilotes
 
Numerical and analytical studies of single and multiphase starting jets and p...
Numerical and analytical studies of single and multiphase starting jets and p...Numerical and analytical studies of single and multiphase starting jets and p...
Numerical and analytical studies of single and multiphase starting jets and p...
 
Self-Balancing Multimemetic Algorithms in Dynamic Scale-Free Networks
Self-Balancing Multimemetic Algorithms in Dynamic Scale-Free NetworksSelf-Balancing Multimemetic Algorithms in Dynamic Scale-Free Networks
Self-Balancing Multimemetic Algorithms in Dynamic Scale-Free Networks
 
INNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATION
INNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATIONINNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATION
INNOVATIVE EDFM TECHNOLOGY FOR REFRACTURING SIMULATION
 
CIOMIN
CIOMINCIOMIN
CIOMIN
 
ALEA:Fine-grain Energy Profiling with Basic Block sampling
ALEA:Fine-grain Energy Profiling with Basic Block samplingALEA:Fine-grain Energy Profiling with Basic Block sampling
ALEA:Fine-grain Energy Profiling with Basic Block sampling
 
Product & technology portfolio of gridworld
Product & technology portfolio of gridworldProduct & technology portfolio of gridworld
Product & technology portfolio of gridworld
 
Unconventional Reservoirs Flow modelling challenges
Unconventional Reservoirs Flow modelling challengesUnconventional Reservoirs Flow modelling challenges
Unconventional Reservoirs Flow modelling challenges
 
Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021
Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021
Ph d defense_rajmohan_muthaiah_University_of_oklahoma_07_28_2021
 
Molecular Simulation to build models for enzyme induced fit
Molecular Simulation to build models for enzyme induced fit Molecular Simulation to build models for enzyme induced fit
Molecular Simulation to build models for enzyme induced fit
 
Heterojunction silicon based solar cells
Heterojunction silicon based solar cellsHeterojunction silicon based solar cells
Heterojunction silicon based solar cells
 
1stSymposiumTALK_Closed_Conduit-Paul_Ghamry
1stSymposiumTALK_Closed_Conduit-Paul_Ghamry1stSymposiumTALK_Closed_Conduit-Paul_Ghamry
1stSymposiumTALK_Closed_Conduit-Paul_Ghamry
 
Module PHY6002 Inorganic Semiconductor Nanostructures Lectur.docx
Module PHY6002 Inorganic Semiconductor Nanostructures Lectur.docxModule PHY6002 Inorganic Semiconductor Nanostructures Lectur.docx
Module PHY6002 Inorganic Semiconductor Nanostructures Lectur.docx
 
Process design and analysis of dual phase membanes
Process design and analysis of dual phase membanesProcess design and analysis of dual phase membanes
Process design and analysis of dual phase membanes
 

More from PFHub PFHub

Pf
PfPf
C hi mad_phasefieldworkshop(1)
C hi mad_phasefieldworkshop(1)C hi mad_phasefieldworkshop(1)
C hi mad_phasefieldworkshop(1)
PFHub PFHub
 
AI for Science Grand Challenges
AI for Science Grand ChallengesAI for Science Grand Challenges
AI for Science Grand Challenges
PFHub PFHub
 
Cobalt-based Superalloys Development in CHiMaD
Cobalt-based Superalloys Development in CHiMaDCobalt-based Superalloys Development in CHiMaD
Cobalt-based Superalloys Development in CHiMaD
PFHub PFHub
 
Microstructural Analysis and Machine Learning
Microstructural Analysis and Machine LearningMicrostructural Analysis and Machine Learning
Microstructural Analysis and Machine Learning
PFHub PFHub
 
Using phase field simulations to assist with experiments and experimental data
Using phase field simulations to assist with experiments and experimental dataUsing phase field simulations to assist with experiments and experimental data
Using phase field simulations to assist with experiments and experimental data
PFHub PFHub
 
Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...
Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...
Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...
PFHub PFHub
 
UNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICS
UNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICSUNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICS
UNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICS
PFHub PFHub
 
Implementing a neural network potential for exascale molecular dynamics
Implementing a neural network potential for exascale molecular dynamicsImplementing a neural network potential for exascale molecular dynamics
Implementing a neural network potential for exascale molecular dynamics
PFHub PFHub
 
Community-Driven Benchmark Problems for Phase Field Modeling
Community-Driven Benchmark Problems for Phase Field ModelingCommunity-Driven Benchmark Problems for Phase Field Modeling
Community-Driven Benchmark Problems for Phase Field Modeling
PFHub PFHub
 
Phase-field modeling of crystal nucleation: Comparison with simulations and e...
Phase-field modeling of crystal nucleation: Comparison with simulations and e...Phase-field modeling of crystal nucleation: Comparison with simulations and e...
Phase-field modeling of crystal nucleation: Comparison with simulations and e...
PFHub PFHub
 
Nucleation III: Phase-field crystal modeling of nucleation process
Nucleation III: Phase-field crystal modeling of nucleation processNucleation III: Phase-field crystal modeling of nucleation process
Nucleation III: Phase-field crystal modeling of nucleation process
PFHub PFHub
 
Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...
Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...
Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...
PFHub PFHub
 
Phase-field modeling of crystal nucleation I: Fundamentals and methods
Phase-field modeling of crystal nucleation I: Fundamentals and methodsPhase-field modeling of crystal nucleation I: Fundamentals and methods
Phase-field modeling of crystal nucleation I: Fundamentals and methods
PFHub PFHub
 
Benchmark 6 Update
Benchmark 6 UpdateBenchmark 6 Update
Benchmark 6 Update
PFHub PFHub
 
Educating Researchers Using the CHiMaD Benchmark Problems
Educating Researchers Using the CHiMaD Benchmark ProblemsEducating Researchers Using the CHiMaD Benchmark Problems
Educating Researchers Using the CHiMaD Benchmark Problems
PFHub PFHub
 
Phase-field modeling of crystal nucleation II: Comparison with simulations an...
Phase-field modeling of crystal nucleation II: Comparison with simulations an...Phase-field modeling of crystal nucleation II: Comparison with simulations an...
Phase-field modeling of crystal nucleation II: Comparison with simulations an...
PFHub PFHub
 
Update on Benchmark 7
Update on Benchmark 7Update on Benchmark 7
Update on Benchmark 7
PFHub PFHub
 
Theoretical and Applied Phase-Field: Glimpses of the activities in India
Theoretical and Applied Phase-Field: Glimpses of the activities in IndiaTheoretical and Applied Phase-Field: Glimpses of the activities in India
Theoretical and Applied Phase-Field: Glimpses of the activities in India
PFHub PFHub
 

More from PFHub PFHub (19)

Pf
PfPf
Pf
 
C hi mad_phasefieldworkshop(1)
C hi mad_phasefieldworkshop(1)C hi mad_phasefieldworkshop(1)
C hi mad_phasefieldworkshop(1)
 
AI for Science Grand Challenges
AI for Science Grand ChallengesAI for Science Grand Challenges
AI for Science Grand Challenges
 
Cobalt-based Superalloys Development in CHiMaD
Cobalt-based Superalloys Development in CHiMaDCobalt-based Superalloys Development in CHiMaD
Cobalt-based Superalloys Development in CHiMaD
 
Microstructural Analysis and Machine Learning
Microstructural Analysis and Machine LearningMicrostructural Analysis and Machine Learning
Microstructural Analysis and Machine Learning
 
Using phase field simulations to assist with experiments and experimental data
Using phase field simulations to assist with experiments and experimental dataUsing phase field simulations to assist with experiments and experimental data
Using phase field simulations to assist with experiments and experimental data
 
Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...
Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...
Uncertainty Propagation in CALPHAD-reinforced Elastochemical Phase-field Mode...
 
UNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICS
UNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICSUNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICS
UNCERTAINTY QUANTIFICATION OF PHASE EQUILIBRIA AND THERMODYNAMICS
 
Implementing a neural network potential for exascale molecular dynamics
Implementing a neural network potential for exascale molecular dynamicsImplementing a neural network potential for exascale molecular dynamics
Implementing a neural network potential for exascale molecular dynamics
 
Community-Driven Benchmark Problems for Phase Field Modeling
Community-Driven Benchmark Problems for Phase Field ModelingCommunity-Driven Benchmark Problems for Phase Field Modeling
Community-Driven Benchmark Problems for Phase Field Modeling
 
Phase-field modeling of crystal nucleation: Comparison with simulations and e...
Phase-field modeling of crystal nucleation: Comparison with simulations and e...Phase-field modeling of crystal nucleation: Comparison with simulations and e...
Phase-field modeling of crystal nucleation: Comparison with simulations and e...
 
Nucleation III: Phase-field crystal modeling of nucleation process
Nucleation III: Phase-field crystal modeling of nucleation processNucleation III: Phase-field crystal modeling of nucleation process
Nucleation III: Phase-field crystal modeling of nucleation process
 
Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...
Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...
Using an Explicit Nucleation Model in PRISIMS-PF to Predict Precipate Microst...
 
Phase-field modeling of crystal nucleation I: Fundamentals and methods
Phase-field modeling of crystal nucleation I: Fundamentals and methodsPhase-field modeling of crystal nucleation I: Fundamentals and methods
Phase-field modeling of crystal nucleation I: Fundamentals and methods
 
Benchmark 6 Update
Benchmark 6 UpdateBenchmark 6 Update
Benchmark 6 Update
 
Educating Researchers Using the CHiMaD Benchmark Problems
Educating Researchers Using the CHiMaD Benchmark ProblemsEducating Researchers Using the CHiMaD Benchmark Problems
Educating Researchers Using the CHiMaD Benchmark Problems
 
Phase-field modeling of crystal nucleation II: Comparison with simulations an...
Phase-field modeling of crystal nucleation II: Comparison with simulations an...Phase-field modeling of crystal nucleation II: Comparison with simulations an...
Phase-field modeling of crystal nucleation II: Comparison with simulations an...
 
Update on Benchmark 7
Update on Benchmark 7Update on Benchmark 7
Update on Benchmark 7
 
Theoretical and Applied Phase-Field: Glimpses of the activities in India
Theoretical and Applied Phase-Field: Glimpses of the activities in IndiaTheoretical and Applied Phase-Field: Glimpses of the activities in India
Theoretical and Applied Phase-Field: Glimpses of the activities in India
 

Recently uploaded

The binding of cosmological structures by massless topological defects
The binding of cosmological structures by massless topological defectsThe binding of cosmological structures by massless topological defects
The binding of cosmological structures by massless topological defects
Sérgio Sacani
 
molar-distalization in orthodontics-seminar.pptx
molar-distalization in orthodontics-seminar.pptxmolar-distalization in orthodontics-seminar.pptx
molar-distalization in orthodontics-seminar.pptx
Anagha Prasad
 
20240520 Planning a Circuit Simulator in JavaScript.pptx
20240520 Planning a Circuit Simulator in JavaScript.pptx20240520 Planning a Circuit Simulator in JavaScript.pptx
20240520 Planning a Circuit Simulator in JavaScript.pptx
Sharon Liu
 
Sharlene Leurig - Enabling Onsite Water Use with Net Zero Water
Sharlene Leurig - Enabling Onsite Water Use with Net Zero WaterSharlene Leurig - Enabling Onsite Water Use with Net Zero Water
Sharlene Leurig - Enabling Onsite Water Use with Net Zero Water
Texas Alliance of Groundwater Districts
 
Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...
Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...
Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...
University of Maribor
 
bordetella pertussis.................................ppt
bordetella pertussis.................................pptbordetella pertussis.................................ppt
bordetella pertussis.................................ppt
kejapriya1
 
Describing and Interpreting an Immersive Learning Case with the Immersion Cub...
Describing and Interpreting an Immersive Learning Case with the Immersion Cub...Describing and Interpreting an Immersive Learning Case with the Immersion Cub...
Describing and Interpreting an Immersive Learning Case with the Immersion Cub...
Leonel Morgado
 
Thornton ESPP slides UK WW Network 4_6_24.pdf
Thornton ESPP slides UK WW Network 4_6_24.pdfThornton ESPP slides UK WW Network 4_6_24.pdf
Thornton ESPP slides UK WW Network 4_6_24.pdf
European Sustainable Phosphorus Platform
 
Eukaryotic Transcription Presentation.pptx
Eukaryotic Transcription Presentation.pptxEukaryotic Transcription Presentation.pptx
Eukaryotic Transcription Presentation.pptx
RitabrataSarkar3
 
Micronuclei test.M.sc.zoology.fisheries.
Micronuclei test.M.sc.zoology.fisheries.Micronuclei test.M.sc.zoology.fisheries.
Micronuclei test.M.sc.zoology.fisheries.
Aditi Bajpai
 
Randomised Optimisation Algorithms in DAPHNE
Randomised Optimisation Algorithms in DAPHNERandomised Optimisation Algorithms in DAPHNE
Randomised Optimisation Algorithms in DAPHNE
University of Maribor
 
The debris of the ‘last major merger’ is dynamically young
The debris of the ‘last major merger’ is dynamically youngThe debris of the ‘last major merger’ is dynamically young
The debris of the ‘last major merger’ is dynamically young
Sérgio Sacani
 
SAR of Medicinal Chemistry 1st by dk.pdf
SAR of Medicinal Chemistry 1st by dk.pdfSAR of Medicinal Chemistry 1st by dk.pdf
SAR of Medicinal Chemistry 1st by dk.pdf
KrushnaDarade1
 
在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样
在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样
在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样
vluwdy49
 
3D Hybrid PIC simulation of the plasma expansion (ISSS-14)
3D Hybrid PIC simulation of the plasma expansion (ISSS-14)3D Hybrid PIC simulation of the plasma expansion (ISSS-14)
3D Hybrid PIC simulation of the plasma expansion (ISSS-14)
David Osipyan
 
waterlessdyeingtechnolgyusing carbon dioxide chemicalspdf
waterlessdyeingtechnolgyusing carbon dioxide chemicalspdfwaterlessdyeingtechnolgyusing carbon dioxide chemicalspdf
waterlessdyeingtechnolgyusing carbon dioxide chemicalspdf
LengamoLAppostilic
 
mô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốt
mô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốtmô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốt
mô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốt
HongcNguyn6
 
THEMATIC APPERCEPTION TEST(TAT) cognitive abilities, creativity, and critic...
THEMATIC  APPERCEPTION  TEST(TAT) cognitive abilities, creativity, and critic...THEMATIC  APPERCEPTION  TEST(TAT) cognitive abilities, creativity, and critic...
THEMATIC APPERCEPTION TEST(TAT) cognitive abilities, creativity, and critic...
Abdul Wali Khan University Mardan,kP,Pakistan
 
Applied Science: Thermodynamics, Laws & Methodology.pdf
Applied Science: Thermodynamics, Laws & Methodology.pdfApplied Science: Thermodynamics, Laws & Methodology.pdf
Applied Science: Thermodynamics, Laws & Methodology.pdf
University of Hertfordshire
 
Medical Orthopedic PowerPoint Templates.pptx
Medical Orthopedic PowerPoint Templates.pptxMedical Orthopedic PowerPoint Templates.pptx
Medical Orthopedic PowerPoint Templates.pptx
terusbelajar5
 

Recently uploaded (20)

The binding of cosmological structures by massless topological defects
The binding of cosmological structures by massless topological defectsThe binding of cosmological structures by massless topological defects
The binding of cosmological structures by massless topological defects
 
molar-distalization in orthodontics-seminar.pptx
molar-distalization in orthodontics-seminar.pptxmolar-distalization in orthodontics-seminar.pptx
molar-distalization in orthodontics-seminar.pptx
 
20240520 Planning a Circuit Simulator in JavaScript.pptx
20240520 Planning a Circuit Simulator in JavaScript.pptx20240520 Planning a Circuit Simulator in JavaScript.pptx
20240520 Planning a Circuit Simulator in JavaScript.pptx
 
Sharlene Leurig - Enabling Onsite Water Use with Net Zero Water
Sharlene Leurig - Enabling Onsite Water Use with Net Zero WaterSharlene Leurig - Enabling Onsite Water Use with Net Zero Water
Sharlene Leurig - Enabling Onsite Water Use with Net Zero Water
 
Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...
Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...
Remote Sensing and Computational, Evolutionary, Supercomputing, and Intellige...
 
bordetella pertussis.................................ppt
bordetella pertussis.................................pptbordetella pertussis.................................ppt
bordetella pertussis.................................ppt
 
Describing and Interpreting an Immersive Learning Case with the Immersion Cub...
Describing and Interpreting an Immersive Learning Case with the Immersion Cub...Describing and Interpreting an Immersive Learning Case with the Immersion Cub...
Describing and Interpreting an Immersive Learning Case with the Immersion Cub...
 
Thornton ESPP slides UK WW Network 4_6_24.pdf
Thornton ESPP slides UK WW Network 4_6_24.pdfThornton ESPP slides UK WW Network 4_6_24.pdf
Thornton ESPP slides UK WW Network 4_6_24.pdf
 
Eukaryotic Transcription Presentation.pptx
Eukaryotic Transcription Presentation.pptxEukaryotic Transcription Presentation.pptx
Eukaryotic Transcription Presentation.pptx
 
Micronuclei test.M.sc.zoology.fisheries.
Micronuclei test.M.sc.zoology.fisheries.Micronuclei test.M.sc.zoology.fisheries.
Micronuclei test.M.sc.zoology.fisheries.
 
Randomised Optimisation Algorithms in DAPHNE
Randomised Optimisation Algorithms in DAPHNERandomised Optimisation Algorithms in DAPHNE
Randomised Optimisation Algorithms in DAPHNE
 
The debris of the ‘last major merger’ is dynamically young
The debris of the ‘last major merger’ is dynamically youngThe debris of the ‘last major merger’ is dynamically young
The debris of the ‘last major merger’ is dynamically young
 
SAR of Medicinal Chemistry 1st by dk.pdf
SAR of Medicinal Chemistry 1st by dk.pdfSAR of Medicinal Chemistry 1st by dk.pdf
SAR of Medicinal Chemistry 1st by dk.pdf
 
在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样
在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样
在线办理(salfor毕业证书)索尔福德大学毕业证毕业完成信一模一样
 
3D Hybrid PIC simulation of the plasma expansion (ISSS-14)
3D Hybrid PIC simulation of the plasma expansion (ISSS-14)3D Hybrid PIC simulation of the plasma expansion (ISSS-14)
3D Hybrid PIC simulation of the plasma expansion (ISSS-14)
 
waterlessdyeingtechnolgyusing carbon dioxide chemicalspdf
waterlessdyeingtechnolgyusing carbon dioxide chemicalspdfwaterlessdyeingtechnolgyusing carbon dioxide chemicalspdf
waterlessdyeingtechnolgyusing carbon dioxide chemicalspdf
 
mô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốt
mô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốtmô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốt
mô tả các thí nghiệm về đánh giá tác động dòng khí hóa sau đốt
 
THEMATIC APPERCEPTION TEST(TAT) cognitive abilities, creativity, and critic...
THEMATIC  APPERCEPTION  TEST(TAT) cognitive abilities, creativity, and critic...THEMATIC  APPERCEPTION  TEST(TAT) cognitive abilities, creativity, and critic...
THEMATIC APPERCEPTION TEST(TAT) cognitive abilities, creativity, and critic...
 
Applied Science: Thermodynamics, Laws & Methodology.pdf
Applied Science: Thermodynamics, Laws & Methodology.pdfApplied Science: Thermodynamics, Laws & Methodology.pdf
Applied Science: Thermodynamics, Laws & Methodology.pdf
 
Medical Orthopedic PowerPoint Templates.pptx
Medical Orthopedic PowerPoint Templates.pptxMedical Orthopedic PowerPoint Templates.pptx
Medical Orthopedic PowerPoint Templates.pptx
 

Multi-phase-field simulations with OpenPhase

  • 1. Multi-phase-field simulations with OpenPhase Marvin Tegeler, Johannes Görler, Alexander Monas, Oleg Shchyglo and Ingo Steinbach Interdisciplinary Centre for Advanced Materials Simulation, Ruhr-Universität Bochum, Bochum, Germany
  • 2. 2 Coarsening Diffusion Large Deformation Plasticity Damage Flow OpenPhase Toolbox • Physics-based microstructure simulation framework. • 100 man-years of research and development since 2009 • Code is based on the multi- phase field multi-component PF-model • Object oriented code written in C++ • Modular structure allowing for easy extension by addition of new modules
  • 3. 3 Coarsening Diffusion Large Deformation Plasticity Damage Flow OpenPhase Toolbox • Simulation of coarsening and ripening. • Minimization of interfacial energy leads to a realistic grains size distribution: • Examples: • Tempering of steels. • Coarsening of carbides.
  • 4. 4 Coarsening Diffusion Large Deformation Plasticity Damage Flow OpenPhase Toolbox • Simulation of multi- component diffusion fluxes. • Data from thermodynamic and kinetic databases. Supported interfaces to . • Examples: • Segregation profiles after solidification. • Diffusion controlled transformations. g
  • 5. 5 OpenPhase Toolbox g • Simulation of deformations up to several hundred percents. • Examples: • Hot rolling of steels. • Virtual tensile tests. Coarsening Diffusion Large Deformation Plasticity Damage Flow
  • 6. 6 Coarsening Diffusion Large Deformation Plasticity Damage Flow OpenPhase Toolbox • Simulation of plastic deformation. • Reduction of elastic stresses by plastic deformation. Full implementation of a crystal plasticity model. • Examples: • Creep deformation in Ni- base superalloys • Martensite in metals. g
  • 7. 7 Coarsening Diffusion Large Deformation Plasticity Damage Flow OpenPhase Toolbox • Simulation of the effect of mesoscopic damage in the microstructure. • Reduction of stiffness and yield strength depending on plastic strain. • Examples: • Virtual tensile tests. • Simulation of creep deformation.
  • 8. 8 Coarsening Diffusion Large Deformation Plasticity Damage Flow OpenPhase Toolbox • Simulation of liquid flow. • Solving Lattice-Boltzmann method under consideration of solid grains. g
  • 9. 9 Introduction to the Multiphase Field Method The Multiphase Field Method  A tool for the simulation of microstructure evolution  A set of continuous scalar functions  1 in bulk, 0 when phase does not exist.  Description of regions of different properties (crystallographic structure, orientations, etc)  Motion of interfaces between regions
  • 10. 10 Introduction to the Multiphase Field Method   compact 27-point stencil  N = Number of active phase fields in a grid point  Active phase fields or
  • 11. 11 Overview • Mg-Al alloy solidification • OpenPhase Tutorial • Parallelization
  • 12. 12 Mg-Al Microstructure and Thermodynamics  Mg-Al alloys microstructure consist of α-phase (HCP-Mg dendrites) surrounded by closed shell Mg17Al12 β-phase  properties as corrosion resistance depend on the microstructure Goal:  Modeling as cast microstructures using the phase field model 200µm
  • 13. 13 Experimental as-cast Mg-Al Microstructure 0.3 K/s 1.0 K/s 25 K/s 1 mm (a): furnace control (b): air cooling (c): water cooling
  • 14. 14 Nucleation Modeling  Create a list of virtual particles, that satisfies a given nucleation density  At every time step plant nuclei by creating a phase field with value zero at the corresponding grid point, if the parent phase is correct  Compute driving force , if remove the corresponding virtual particle from the list, otherwise remove phase field.
  • 15. 15 Initial temperature: 875 K Cooling rate: 10 K/s Initial concentration: 5 at. % Al System size: 200x200x200 μm Grid spacing: 1.0 um Solidification of MgAl
  • 17. 17 Effect of cooling rate on solidification microstructure 5 K/s 15 K/s 25 K/s 200µm Mg-5at.%Al α-Mg β-Mg
  • 18. 18 α- and β-phase nucleation during solidification α-Mg β-Mg  Primary α-phase dendrites fill most of the volume.  Secondary β-phase fills interdendritic region.
  • 19. 19 Evolution of microstructure during solidification α-Mg β-Mg 100µm 300³ µm = 27 mio cells one week calculation time on 96 cores
  • 20. 20 100µm Evolution of microstructure during solidification 100µm
  • 21. 21 3D Secondary β-phase Nucleation and Growth Modeling α β 100µm
  • 22. 22 3D Secondary β-phase Nucleation and Growth Modeling 20µm
  • 23. 23 α α β 20µm Rapid coverage of α-liquid-interface with β-phase  β-phase covers the α-liquid-interface  Further β-phase growth depletes enclosed melt  Nucleation of tertiary α-phase is neccessary for complete solidification Monas A et al.; “Divorced Eutectic Solidification of Mg-Al Alloys”, JOM (2015)
  • 24. 24 Mg-Al β-phase formation: experiment vs simulation 100µm 5µm SEM-image of Mg-5%Al microstructure and enlarged view on the eutectic region. dark: α-phase, bright: β-phase Se-Jong Kim, Chang Dong Yim, KIMS, Korea
  • 25. 25 Tutorial OpenPhase can be downloaded at http://www.openphase.de/upload/content/OpenPhase.V0.9.1.zip The tutorial will use the SolidificationMgAl example. In order to compile the OpenPhase library just run 'make' in the main directory. To compile an example call ‘make’ in the corresponding directory.
  • 26. 26 Load Modules int main(int argc, char *argv[]) { Settings OPSettings; OPSettings.Initialize(); OPSettings.ReadInput(); PhaseField Phi(OPSettings); DoubleObstacle DO(OPSettings); InterfaceMobility Mu(OPSttings); InterfaceEnergy Sigma(OPSettings); InterfaceEnergySolidLiquid IE(OPSettings); EquilibriumPartitionDiffusion DF(OPSettings); Composition Cx(OPSettings); Temperature Tx(OPSettings); DrivingForce dG(OPSettings); BoundaryConditions BC(OPSettings); Nucleation Nuc(OPSettings);
  • 28. 28 Load Modules dG.ReadInput(); Cx.ReadInput(); DF.ReadInput(); Tx.ReadInput(); BC.ReadInput(); Nuc.ReadInput(); Mu.ReadInput(); Sigma.ReadInput(); IE.ReadInput(); int id = Initializations::Single(Phi, 0, BC, OPSettings); Phi.FieldsStatistics[id].State= Liquid; DF.SetInitialComposition(Phi, Cx); Tx.SetInitial(BC, Phi, 0);
  • 30. 30 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); }
  • 31. 31 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Generates nucleation sites with a random size distribution the first time this function is called.
  • 32. 32 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Plant nuclei at the generated sites. Add storage for a phase field with value zero.
  • 33. 33 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Calculate interface stiffness
  • 34. 34 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Calculate interface mobility
  • 35. 35 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Calculate the sum of phase fields belonging to the same thermodynamic phase in each grid point.
  • 36. 36 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Calculate the double obstacle potential for αβ-interfaces
  • 37. 37 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Calculate driving force
  • 38. 38 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } The correct phase field profile across the interface can only be obtained if the driving force is constant across the interface and varies only along the interface. Therefore we calculate an average driving force , that is constant along the normal direction of the interface.
  • 39. 39 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt)} The correct phase field profile across the interface can only be obtained if the driving force is constant across the interface and varies only along the interface. Therefore we calculate an average driving force , that is constant along the normal direction of the interface. The average is calculated in two steps with
  • 40. 40 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Check driving force of nuclei. Sucessfully planted nuclei are removed from the list of nucleation sites.
  • 41. 41 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Compute interface fields for the chemical driving force
  • 42. 42 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Limit interface fields , so that the phase fields stay within bounds [0,1].
  • 43. 43 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Solve diffusion equation for the phase concentrations
  • 44. 44 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Compute the phase field update
  • 45. 45 Work Loop for(int tStep = OPSettings.tStart + 1; tStep < OPSettings.nSteps + 1; tStep++) { Nuc.GenerateNucleationSites(Phi, Tx); Nuc.PlantNuclei(Phi, tStep); Sigma.CalculateHex(Phi); Mu.CalculateHex(Phi, Tx); DF.SetPhaseFractions(Phi); DO.CalculatePhaseFieldIncrements(Phi, Sigma, Mu); DF.GetDrivingForce(Phi, Cx, Tx, dG); dG.Average(Phi, BC); Nuc.CheckNuclei(Phi, Sigma, dG, tStep); dG.MergePhaseFieldIncrements(Phi, Sigma, Mu); Phi.NormalizeIncrements(BC, dt); DF.Solve(Phi, Cx, Tx, BC, dt); Phi.MergeIncrements(BC, dt); Tx.Set(BC, Phi, 6.2e8, 1.773e6, 0, dt); } Compute temperature update
  • 46. 46 OpenPhase Solutions GmbH • A company has been founded that offers support • Focused on industry • GUI is in development • Creation of ProjectInput.opi • Creation of the .cpp file • Sanity check on input values • GUI will be commercial software • OpenPhase will stay free Johannes Görler Matthias Stratmann
  • 48. 48 Parallelization Thread (OpenMP)  Simultaneous execution of sequences of instruction  Shared address space Process (MPI)  Instance of a program  Own address space  Message Passing All cores should be used efficiently
  • 49. 49 Parallelization  Active phase fields or  Dynamic storage for active phase field  Contributions to the evolution equation only by active phase fields  Locally and temporally different number of active phase fields  Number of operations in each grid point can be different and can change over time.
  • 50. 50 Parallelization • OpenPhase uses stencil operations • Domain decomposition to divide the work onto multiple processes
  • 51. 51 Parallelization Use a domain decomposition to divide the work onto multiple processes.
  • 52. 52 Parallelization The wide halo avoids communication at the expense of additional work. This is used to limit us to one communication step per time step.
  • 53. 53 Load-balancing by Graph-partitioning Over-decomposition  Division of the domain into many more sub-domains (blocks) than processes.  Assignment of these sub-domains to processes  Goal: minimize communication and load-imbalance.
  • 54. 54 Load-balancing by Graph-partitioning Assignment of sub- domains to processes.  Simultaneous minimization of imbalance and communication  Graph-partitioning problem with vertex weights  Coloring of the graph with minimal edge cut  Constrainted sum of the vertex weights with the same color Block ↔ Vertex Communication ↔ Edge Load ↔ Weight Problem: No accurate current polynomial algorithm
  • 55. 55 Load-balancing by Graph-partitioning Greedy Graph-Partitioner 1. Start with color n = 1 2. Choose an uncolored vertex that increases the edge cut the least 3. Color it with color n 4. If the sum of vertex weights with color n is larger than set n = n+1 5. If there are any uncolored vertices, go to 2
  • 56. 56 Load-balancing by Graph-partitioning Greedy Graph-Partitioner 1. Start with color n = 1 2. Choose an uncolored vertex that increases the edge cut the least 3. Color it with color n 4. If the sum of vertex weights with color n is larger than set n = n+1 5. If there are any uncolored vertices, go to 2
  • 57. 57 Load-balancing by Graph-partitioning Graph Partitioning  The Greedy Graph-Partitioner fulfills  Because the last vertex added to each color fulfills  Total work on process i.  Average work .  Maximum work among blocks. Reducing limits the maximum load-imbalance. This can be achieved by splitting blocks into smaller blocks.
  • 58. 58 Load-balancing by Graph-partitioning Splitting Blocks, however, creates additional work After splitting the most costly block the inequality becomes
  • 59. 59 Load-balancing by Graph-partitioning Repeated splitting of the largest block gives Allowing the same block to be split multiple times gives Problem: The cost of splitting is unknown.
  • 60. 60 Load-balancing by Graph-partitioning Problem: The cost of splitting is unknown.  Self-Profiling in order to approximate the cost.  Measure time for computations on each block.  Fit parameters in a cost function  that maps the number of phase fields in each grid point to the computation time.  This information is also used to determine the optimal cutting plane.
  • 65. 65 Load-balancing by Graph-partitioning Weak-Scaling Benchmark Pure MPI  96x48x48 grid points per core.  2 particles per core  Gaussian distribution
  • 66. 66 Load-balancing by Graph-partitioning Weak-Scaling Benchmark Hybrid MPI+OpenMP  96x48x48 grid points per core.  2 particles per core  Gaussian distribution
  • 67. 67 Load-balancing by Graph-partitioning Hybrid-Parallelism reduces the number of MPI-processes. The number of blocks is reduced, the blocks become larger. Less overhead is created by the wide halo. A large number of threads loses efficiency. Only one thread per process participates in communication. Threads created on different sockets can have slow memory access. The best performance was seen with 6 or 12 threads per process.
  • 68. 68 Load-balancing using Phase Field Load-balancing aims at simulatenous reduction of idle time and communication. Sub-domains need to have the same amount of work. Surface between sub-domains should be minimized. Idle time Communication With an appropriate driving force the multiphase field method can achieve this.
  • 69. 69 Load-balancing using Phase Field  Domain decompostion with one sub-domain per process .  Each process is associated with a phase field .  The associated sub-domain is determined by the phase field .  Balancing of the work between adjacent domains and by a driving force that drives the interface into the direction of the higher computational load.  An isotropic interface energy reduces the surface area between domains.
  • 70. 70 Load-balancing using Phase Field Application to the Phase Field Method  Two instances of phase field  Simulation  Load-balancing  Using Wide Halo
  • 71. 71 Load-balancing using Phase Field Application to the Phase Field Method  Two instances of phase field  Simulation  Load-balancing  Using Wide Halo  Both on the same rectangular sub- domain  Interior points of the sub-domains can overlap.
  • 72. 72 Load-balancing using Phase Field Comparison with the previous load- balancing scheme.
  • 73. 73 Load-balancing using Phase Field Convergence of load-balance  96 MPI processes  20% Tolerance
  • 74. 74 Load-balancing using Phase Field Convergence of load-balance  96 MPI processes  5% Tolerance
  • 75. 75 Load-balancing using Phase Field Application to the Phase Field Method  Two instances of phase field  Simulation  Load-balancing  Using Wide Halo  Both on the same rectangular sub- domain , in which is the majority phase.  Interior points of the sub-domains can overlap.
  • 76. 76 Load-balancing using Phase Field Applied to Molecular Dynamics  Cell-based molecular dynamics  Lennard-Jones potential  Start with a simple domain decomposition  Colors indicate processes  The phase fields are only updated with a probability of With the maximum load among processes 𝜔 𝑚𝑎𝑥, the number of processes 𝑁 𝑝 and the average time for load-balancing 𝑇𝐿𝐵.
  • 78. 78 Two Spheres Move Over Periodic Boundary
  • 80. 80 Summary  OpenPhase is a flexible multi-phase-field framework, that can handle an arbitrary number of phase fields for a variety of applications  MPI and OpenMP parallelization allow an efficient usage of computational resources.
  • 81. 81 Summary  OpenPhase is a flexible multi-phase-field framework, that can handle an arbitrary number of phase fields for a variety of applications  MPI and OpenMP parallelization allow an efficient usage of computational resources. Thank you!