How to Setup a Solidification and Melting Problem in Ansys Fluent
Introduction
Hello everybody, today we are going to look into an example where we simulate the mold filling process using the Volume of Fluid (VOF) model. We will further examine the solidification of the molten liquid after it has completed the filling process. The geometry is a cast, as you can see over here.
Simulation Setup
We will be using the VOF model with air and molten liquid as two phases, along with the solidification and melting modeling approach. The liquid will be pushed inside the cast from the bottom at a temperature greater than the melting point of the metal. We have a symmetry boundary condition, which is why we are only simulating half of this cast. The cooling of the cast will take place via a wall boundary condition where we will impose a heat transfer coefficient. There are two outlets at the top for the gas to escape as the liquid comes in. Once the liquid level reaches the top, we will change the heat transfer coefficient to accelerate the solidification process.
Mesh Setup
This is how the mesh looks like:
- Polyhedral mesh
- Symmetry planes
- Inlet at the bottom
- Outlet at the top
First, let's take a look at the mesh metrics. The mesh texture is like a grid on the side, and the built-in mesh media shows a life volume increase estimated to be about 0.23. The ratio here is 0 to 3, which is safe for high prone tempered areas.
Material Properties
We have come up with two models:
- Gaan Abovesmith Led Meter
- Printer Lead Muscle
For material parameters, you can specify four points for the temperature-density relationship. Similarly, change the specific heat capacity (CP) and thermal conductivity to piecewise linear with four points each. The viscosity of the liquid is 0.0143 Pascal seconds. The solidus temperature is 1080°C, and the liquidus temperature is 1190°C. For air, we will use the ideal gas method with default values. Since air will not solidify, specify zero value for both solidus and liquidus temperatures.
Solidification and Melting Model Activation
Activate the solidification and melting model and specify a Vachyzone parameter. Use the VOF method by pressing 'C' and 'm'. Set the surface tension to 0.1 Newton per meter and activate the surface tension force modeling with wall adhesion to help set the contact angle.
Boundary Conditions
Inlet
Change the inlet from mixture to air. We don't expect any air to come in, so the mass flow rate is zero. For the metal, specify a mass flow rate of 0.0041, or specify a transient profile such as:
- If the flow time is below 1 second, this will be the mass flow rate.
- If the flow time is below 10 seconds, this will be the mass flow rate.
- If the flow time is above 10 seconds, the mass flow rate will be set to zero.
The mass flow rate ramps up from 0 seconds to 1 second, stays constant until 10 seconds, and then goes down to zero.
Outlet
Set the outlet as if it's open to the atmosphere, with gauge pressure set to zero for both outlets. The thermal boundary condition is set such that if there is a return flow, it will be at a very high temperature. Set the backflow temperature to 1200°C.
Walls
Set a wall boundary condition for stationary walls. The metal and air contact angle is 30 degrees. In Ansys Fluent, the contact angle is measured inside the phase listed in the left column, which is the metal in this case. Set the heat flux to zero, meaning the walls will be adiabatic at t = 0.
Command Setup
Use commands based on TUI language to effectively set up and run the simulation without stopping:
- Activate execute command and create a new command to set boundary conditions.
- Set the command to activate when the flow timer hits 2 seconds, changing from adiabatic to convective boundary condition.
- Add a new command to set the heat transfer coefficient to 60 at t = 2 seconds.
- Add another command to set the environment temperature (T infinity) to 30°C.
- Disable the command that sets the heat transfer coefficient to 60 to keep it constant.
- Add a command to increase the heat transfer coefficient at 10 seconds to accelerate solidification.
Solution Methods
Go to solution methods and activate the Pratt phase gradient for polyhedral cells and non-iterative time advance. Change the neighborhood correction to 3. Activate the solution, select the conservative approach, and apply the settings.
Hello everybody, today we are going to look into an example where we simulate the mold filling process using VOF. We will further look at the solidification of this molten liquid after it has completed the filling process. The geometry is as you can see over here a cast.
The geometry, as you can see over here, is a cast. We will be using the VOF model where we will have air and the molten liquid as two phases. We will be using the solidification and melting modeling approach.
The liquid will be pushed inside the cast from the bottom at a temperature greater than the melting point of the metal. We have a symmetry boundary condition, which is why we are only simulating half of this cast.
The cooling of the cast will take place by a wall boundary condition where we will impose a heat transfer coefficient. There are two outlets at the top for the gas to escape as the liquid comes in.
And once the liquid level reaches the top, we will change the heat transfer coefficient so that the solidification process can be accelerated. Let's take a look at the setup process. This is how the mesh looks like. We are using a polyhedral mesh. These are the symmetry planes. This is the inlet.
And at the top, we have the outlet. So first, let's take a look at the mesh metrics. We are in one mesh texture, which is like a grid on the side. The built-in mesh metrics are as follows: * Mesh size: 0.23 * Ratio: 0 to 3 * For high-temperature areas, this is safe.
Now, let's look at the material properties. We have come up with two models. The first is a Gaan-Abovesmith LED meter. The other is a Printer Lead Muscle, from which you can choose. Here, we would evaluate "잡" as "다음에沒 물" interested in. Let's look at the material features.
For example, you have two material parameters: the weight profile. As soon as you select that, these options will come up. We will specify four points. As the temperature increases, the density changes. Similarly, we will also change the CP to piecewise linear, four points.
Similarly, edit the thermal conductivity to piecewise linear, again four points. The viscosity of the liquid is 0.0143 Pascal second. The pure solvent melting heat. The solidus temperature is 1080, and the liquidus temperature is 1190 degrees centigrade. The air will be using the ideal gas method.
We will use the default values. As a best practice, since air is not going to solidify, we will specify zero value for solidus and zero value for liquidus temperature. Now, let's go and activate our solidification melting model.
Then activate the solidification melting model, specify a Vachyzone parameter. Then navigate the turbulence method by pressing C and m. We will manage it by pressing T. The slow beta is optimized. The self-heating time was fine.
Set it to 0.1 Newton per meter, and we are also going to activate the surface tension force modeling with wall addition, which will help us activate the contact angle. Double click the inlet, change it from mixture to air at the inlet.
We don't expect any air to come in, so the mass flow rate is zero for the metal. We have a specified mass flow rate of 0.0041 but can also specify a transient profile such as an expression for the inlet profile if the flow time is below one second, this will be the mass flow rate.
If the flow time is below 10 seconds, this will be the mass flow rate of the inlet profile. If the flow time is below it and if the flow time is above 10 seconds, then the mass flow rate will be set to zero using this equation.
So the mass flow rate now will ramp up as we go from 0 seconds to one second; it will stay constant till 10 seconds and it will go down to 0 at the end of 10 seconds. For the outlet, we will specify the outlet as open to the atmosphere, so the gauge pressure is set to zero for both outlets.
And also, the thermal boundary condition is set such that if there is a return flow, it will be at a very high temperature. Let's set the backflow temperature to 1200 degrees centigrade. Go to metal VOF, set the volume fraction to zero. So that's only coming back in.
Similarly, for the inlet, let's set the thermal condition to 1200 degrees centigrade. Let's go to the walls. Let's look at the walls. These are all the walls. We'll set a wall boundary condition. It's a stationary wall. The metal and air contact angle is 30 degrees.
In ANSYS Fluent, the contact angle is measured inside the phase, which is listed in the left column. So in this case, this is the metal, and so the metal-to-air is the contact angle inside the metal, and that is 30 degrees. Go to thermal, set the heat flux to zero.
That means the walls will be adiabatic at t is equal to zero. Now, what we can do is we can set the wall boundary conditions and keep on changing them as the solution runs. To do that, we'll be using commands.
These commands are based on TUI language, and I will show you how to use them to effectively set up your simulation and run the simulation without stopping. Activate the execute command.
Double click, create new, and write: define only condition set value valve mixture thermal PC yes convection In one go, this should be able to set up the boundary conditions.
Now, let's go to execute commands, set up a new command, paste it, and set it to activate when the flow timer hits two seconds. So that means my boundary condition will be set to zero. Then we set it to activate when the flow timer hits two seconds.
So that means my boundary condition will change from adiabatic to convective boundary condition at flow time two. Change from adiabatic to convective boundary condition at flow time two. I'll set the boundary condition back to clear flux. This case that is equal to zero.
Now, I will add one more command. So I discussed various options in real-time heat transfer coefficient to 60. It's important to have the spellings correct. So now the heat transfer coefficient those are înt and then O our controllerinhas C is an empty room.
Now, the heat transfer coefficient those are înt and so on. We set up vacuum in the will be set to 60 at t is equal to 2 seconds. We will add a new command where we will set the t infinity that is the heat will be lost to the environment at a certain temperature that temperature is to be set.
So if I just copy this, paste it over here, go back to wall condition, you should see the free stream temperature change to say 30. I'm going to change it back to heat flux now. Click OK. So now we have the first command is we are activating convective heat transfer coefficient.
The second is we are setting a convective heat transfer coefficient. And the third one is we are setting the t infinity. Now, as the solution continues, we want to increase the heat transfer coefficient further so that we can accelerate the solidification procedure.
Otherwise, it will take a very long time for the solidification to complete. So we are going to set a new command, the disable command 2, which sets the heat transfer coefficient to 60. That means the transfer coefficient keeps on constant at 60. We are just disabling these commands.
We are not changing the heat transfer coefficient at this point. So if you test it, you can see command 2 becomes inactive. Finally, we will add command 5, where no time goes all the way up to 10 seconds, and then we will increase the heat transfer coefficient and click OK.
So that is how we are going to control the whole process at different flow times. Every command will be executed at the specified flow time, and we don't have to come back and check and stop the simulation or start the simulation.
The complete simulation will go through, and we will have a full solidification-melting profile at the end of the simulation. Now we will go and set up our methods.
We will go to solution methods and activate the Prantl phase gradient for polyhedral cell and non-iterative time advance as well at the same time. We will change the neighborhood correction to 3. Once we activate the solution, we will see we will see that the solution is still active.
Non-iterative time at one will do option and activate hybrid meter. And we will select the conservative approach and click Apply. The next step is to set up the initial conditions. We will go to initial conditions and set up the initial temperature and pressure.
We will set the initial temperature to be 293 Kelvin and the initial pressure to be 1 atmosphere. Once we have set up the initial conditions, we will go to the solver settings and set up the time step size and the number of iterations per time step.
We will set the time step size to be 0.001 seconds and the number of iterations per time step to be 5. Now we are ready to run the simulation. We will go to run and click on run. The simulation will start, and we can monitor the progress by looking at the console output.
Once the simulation is complete, we will go to the post-processing tools and visualize the results. We can look at the velocity fields, the pressure fields, and the temperature fields. We can also look at the volume fraction of the liquid and the solid phases.
By analyzing the results, we can understand the mold filling process and the solidification process. We can optimize the process by changing the geometry, the material properties, and the boundary conditions. Thank you for your attention.