Hello, Ruixiong
I cloned the code from your repository and ran it for a while.
I did not run long enough to get to the error you are getting, but I encountered a few issues that could potentially explain the behavior.
1) First of all, as the code is set, I got an error because refine factor = 5 (initial refinement level) setting was to 5, while the minimum and maximum refinement levels are 2 and 4 respectively. This combination of settings is not permitted in PRISMS-PF because the refine factor must be somewhere in-between 2 and 4. I increased the maximum refinement to 5 to avoid this runtime error.
2) To minimize errors in the numerical integration we strongly recommend using isotropic elements (i.e. dx=dy=dz). However, you are setting the system subdivisions to 2,2, and 3 in the x-, y- and z-directions, respectively. Since your system size is 50 x 50 x 100, you should have twice the subdivisions in the z-direction than in the x- and y-directions. I changed the subdivisions to:
set Subdivisions X = 1
set Subdivisions Y = 1
set Subdivisions Z = 2
3) Finally, the most important issue is that in ICs_and_BCs.cc you define the order parameter as 0 in the liquid and 1 in the solid, but in the alloy solidification model, the order parameter should be -1 in the liquid and 1 in the solid. I modified the initial conditions accordingly.
With these changes, I ran the code for 20,000 time steps, printing and outputting files every 100 time steps. The simulation did not crash but the solid phase receded instead of growing, and the order parameter continued decreasing after all the solid had disappeared, which leads me to believe there is an error in your implementation of the model. I recommend double checking the equations.
I hope this helps.
Please let me know if you have any questions.
Best,
David