!*YAPFI macro
!*-----------

SET_NUMBER_OF_THREADS
32!Number of threads /1/



MANDATORY_DATA
c_fe_bcc_fcc_liq_demo!GES file / ANALYTICAL [<analytic init file>]
1790!(Initial) Temperature [K] /1000.0000/
!Pressure [Pa] /100000.00/
n!Element C substitutional /YES/
!Element FE substitutional /YES/
!Initially homogeneous composition /YES/
0.006!Initial mole fraction of element C
0.994!Initial mole fraction of element FE
!*Enter state of phases, 1:Entered, 2: Suspended
!State of phase (LIQUID) /1/
!State of phase (BCC_A2) /1/
!State of phase (FCC_A1) /1/
2!Dimensionality /1/
16!Nr of grid points in dimension #1 /10/
16!Nr of grid points in dimension #2 /10/
0.0114688!Domain width [m] in dimension #1 /1.0000000/
0.0114688!Domain width [m] in dimension #2 /1.0000000/
!Periodic boundary in dimension #1 /NO/
!Periodic boundary in dimension #2 /NO/
!*Grid type. 1:Linear, 2:Geometric, 3: Double geometric, 4: Read from file
!Grid type in dimension #1 /1/
!Grid type in dimension #2 /1/
!*Info: Initial time is always zero
1120!Simulation time [s] /1.0000000/
!Maximum timestep [s] /6.0000000/
!Minimum timestep [s] /0.10000000E-09/
!Initial timestep [s] /0.10000000E-09/
!Save interval /1/
1!Minimum elapsed time between saves [f(time)], [s] /1.0/


ANISOTROPIC_SURFACE_ENERGY
y!Allow anisotropic surface energy /NO/
1e-10!abs(\Delta\phi)_min (A negative value disables the use of this parameter) /0.10000000E-13/


PHASE_FIELD_DATA
!Use phase-field variables /YES/
12!Total nr of phase-field variables /2/
!File containing initial phase-field variable values
!*Associate phases with phase-field variables
!*Phase indices:
!*1:BCC_A2
!*2:FCC_A1
!*3:LIQUID
2!Index of associated phase of phase-field variable # 1
1!Index of associated phase of phase-field variable # 2
repeat 3!Index of associated phase of phase-field variable # 3
!*Enter g_1
!*Shorthand notations:
!*gs11=\sum_iG_{mi}(\phi_i^3(10-15\phi_i+6\phi_i^2))
!*gs12=\sum_iG_{mi}\phi_i
!*variable GXX correspond to Gm of phase
gs11!Gm expression for g_1
!*Enter g_2
!*Shorthand notations:
!*gs21=8\sum_i\phi_i^2(1-\phi_i)^2
!*gs22=0.626\sum_i(\frac{\tanh(2)^2-1}{\tanh(2)^2}\log[1-\tanh(2)^2(2\phi_i-1)^2]-(2\phi_i-1)^2)
!*gs23=10.67(0.25-0.5\sum\phi_i^2+0.25(\sum\phi_i^2)^2+0.5\sum_i\sum_{j>i}\phi_i^2\phi_j^2
!*keyword symmetric may precede the expression for g_2
0.5*15*gs23!Gm expression for g_2
!*Enter epsilon_ij expressions
2*1.875e-9*(1.0+0.02*cos(4*(acos(dp01dz1/((dp01dz1*(1.0+eps))^2+(dp01dz2*(1.0+eps))^2+eps)^0.5)*(dp01dz2/(eps+dp01dz2^2)^0.5)+3.141592653589793*(1.0-(dp01dz2/(eps+dp01dz2^2)^0.5))-0.785398163397448)))^2! 1-2
repeat 2*1.875e-9
(50*5e-9*1e-4)/(R*T*200e-9**2)!Enter phase-field mobility expression


INITIAL_SINGLE_PHASE
y!Set whole domain to consist of a single phase /NO/
2!Enter corresponding phase-field variable index


INITIAL_PRECIPITATE
1!Enter corresponding phase-field variable index
!*Options:
!*1.Spherical precipitate
!*2.Segment/triangle/tetrahedron precipitate at origin
!*3.Arbitrary segment/triangular/tetrahedron precipitate
!*4.Cuboid precipitate (segment/square/cube)
!*5.Diamond precipitate (segment/diamond/octagon)
!*Only #1 obeys periodic boundary conditions
1!Precipitate option
!*Enter center point coordinates
0.0057344!r0 spatial dimension #1
0.0057344!r0 spatial dimension #2
16e-5!Enter precipitate radius
!*Enter precipitate composition (mole fraction)
0.001!Element C
0.999!Element FE
20!Relative grid fineness around precipitate (only relevant with adaptive meshing) /0/


NUMERICAL_SETTINGS
!Degree of implicity /1.0000000/
!Relative error tolerance /0.50000000E-01/
!Absolute error tolerance /0.10000000E-07/
!Jacobian perturbation parameter /0.10000000E-02/
!Clean Jacobian /NO/
!Minimum mole fraction /0.10000000E-14/
!Minimum mobility /0.10000000E-39/
!Maximum temperature /6000.0000/
!Maximum timestep change factor /2.0000000/
!Enforce a maximum \Delta T per time-step /NO/
!Temporally piece-wise locally constant coefficients /YES/
y!Enable linearized time-steps /NO/
y!Assume a maximum width of interfaces /NO/
16e-6!Enter width of interface [m]
!Set non-active phase-field variables away from interfaces to zero /YES/



ADAPTIVE_MESHING
y!Use adaptive meshing /NO/
!Initial allocation factor (>=1) /1.0000000/
n!Adapt mesh based on composition gradients /YES/
!Adapt mesh based on phase-field variable gradients /YES/
0.01!Max phase-field variable Delta /0.10000000/
0.001!Min phase-field variable Delta /0.10000000E-01/
n!Adapt mesh based on temperature gradients /YES/
1!Domain size integer aspect ratio, 1st spatial dimension
1!Domain size integer aspect ratio, 2nd spatial dimension
1!Input integer (1) or real valued (2) parameters /1/
4!Initial depth (>0)
3!Minimum depth (>0)
11!Maximum depth (>0)
y!Base interval to adapt mesh on cumulative change /NO/
n!Use cumulative change of mole-fractions (Y/N)
y!Use cumulative change of phase-field variables (Y/N)
0.2!Maximum cumulative change of phase-field variables
n!Use cumulative change in temperature (Y/N)


FLUCTUATING_PHI
!*A user supplied function is multiplied with a random number -1<x<1
!*and added to all dg/dphi derivatives every time-step
y!Enable adding fluctuations to dg/dphi /NO/
p01*p02*40.0!Fluctuation function


RANDOM_NUMBER_SETTINGS
y!Use a single seed for the pseudorandom number generator /NO/
1!Enter integer seed (1 digit) (<0 for internal vector) /1/


SOLVER
!*Solvers:
!*1.Jacobian solver
!*2.Implicit solver
1!Choose solver /1/


MATRIX_SOLVER
!*Matrix solvers
!*1.QMR
!*2.BiConjugate Gradient
!*3.PARDISO
1!Matrix solver /1/


NON_ISOTHERMAL_SIMULATION
!NON-ISOTHERMAL SIMULATION /YES/
!Spatially non-isothermal simulation /NO/
1790!Initial temperature /1790.0000/
!*Temperature will vary with time piece-wise linearly
!*Enter time-temperature pairs
!*Exit by giving a time <0
1120!time
1650!temperature
-1!time





NUCLEATION
y!Enable nucleation /NO/
!Nucleation check time interval (>= 0) [s] /0.0000000/
184!Minimum time until first check for nucleation (>= 0) [s] /0.0000000/
y!Log nucleation events on file /NO/
y!Save state after nucleation event /NO/
!Maximum nr of nuclei per check (<=0 means no maximum) /-1/
!Minimize time-step after nucleation event /YES/
!*Nucleation schemes:
!*1.Fixed coordinate
!*2.Interface nucleation (also homogeneous)
!*-----------------------
2!Nucleation scheme
24!Maximum number of precipitates /1/
y!Fixed nuclei composition /NO/
0.0084!Nucleus C mole fraction
0.9916!Nucleus FE mole fraction
3!Index of associated phase-field variable
1e-10!Critical non-dimensional (Dm/RT) driving force (>0) /0.10000000E-02/
n!Enter nuclei at points of maximum driving force /NO/
12e-4!Distance to disallow nucleation from existing phase region [m] (<0 disables) /-1.0000000/
!Interface phi threshold value (>=0.0) (0 yields homogeneous nucleation) /0.10000000/
1e-4!Enter precipitate radius
10!Relative grid fineness around precipitate (only relevant with adaptive meshing) /0/
!Reactivate nuclei /NO/
n!Add another nucleation scheme/site


PHI_SWITCHING
y!Automatic switching of phase-field variables /NO/
26!Max nr of grains (including nucleation) (>0)
!*Options for assigning initial grain numbers of grid points:
!*1.Read for each grid point from file
!*2.Read for each grid point from memory
!*3.Assign by initial phase-field variable
3!Enter option for assigning initial grain numbers /1/
!*Phase sets:
!*1.BCC_A2
!*2.LIQUID
!*3.FCC_A1
!*Options for assigning phase sets to grains:
!*1.Read for each grain from file
!*2.Enter for each grain interactively
!*3.Assign by initial phase-field variable
!*(require that option #3 was chosen for initial grain numbers)
3!Enter option for assigning phase sets to grains
!Set composition of grains /NO/


SET_SCREEN_OUTPUT
2!Screen output. 1=Normal, 2=Minimal, 3=Less than minimal, 4=Almost nothing /2/


