When using the foaming model, you must first define a flow with material data, boundary conditions, and so forth. The steps for defining a foam model are listed below:
In the sub-task menu, select Define species.
Define species
Define a species that will actually play the role of the bubble radius. When prompted, assign a name as needed.
Return to the subtask where you defined the flow and select Material Data. Define the viscosity and density as a function of the species.
Click the PMAT button to enable the PMAT material dependence menu.
Select the viscosity law.
Modify fac
Select the zero shear viscosity (fac) and confirm its value.
In the Functional dependence of fac menu, select reciprocal sum and create a new function.
reciprocal sum
create a new function
You can now return to the previous menu. The function will be defined later in the setup (see below).
Select the density and confirm its value.
Modification of density
In the Functional dependence of density menu, select reciprocal sum and create a new function
reciprocal sum
create a new function
You can now return to the previous menu. The function will be defined later in the setup (see below).
Select the PMAT button again to disable the PMAT material dependence menu.
Specify a (constant) value for the Average density.
Average density
Enter a value that corresponds to the density obtained with the initial bubble radius.
In the menu of the task, select Create a sub-task.
Create a sub-task
Choose the sub-task Transport of species.
Transport of species
Choose the previously defined species and confirm the selection.
Specify the domain of the sub-task.
Domain of the sub-task
It is expected to be the entire domain where the flow is defined.
Specify the Material data for the transport equation
Material data
Several items have to be filled for defining the transport equation for the species (the bubble radius)
Click Average concentration for specifying the initial value of the species (bubble radius);
Average concentration
Enter a value and confirm. Preferably, this value should match the value provided as a boundary condition at the inlet.
Select the PMAT button to enable the PMAT material dependence menu.
Select Concentration source per unit volume to specify the source term that will drive the foaming.
Concentration source per unit volume
Select Modification of cprod in order to define the source term:
Modification of cprod
Enter a unit value and confirm the entry.
In the Functional dependence of cprod menu, select product and create a new function.
product
create a new function
You can now return to the previous menu. The function will be defined later in the setup (see below).
Select the PMAT button again to disable the PMAT material dependence menu.
Select Diffusivity and set its new value to zero.
Diffusivity
Select Modify diffusivity and set its new value to zero.
Modify diffusivity
Enter a zero value and confirm the setting.
Specify the boundary conditions for the transport equation by clicking Concentration boundary conditions.
Concentration boundary conditions
By default, a generic information of the type Mass fraction imposed along… appears for all boundaries. The boundary conditions have to be specified in accordance with the foaming flow simulation. More specifically, the Mass fraction (to be understood as the species in the present context) must be imposed at the inlet, while insulated conditions will be selected for the other boundaries.
For the inlet, select Mass fraction imposed along…
Mass fraction imposed along…
Then select the option Mass fraction imposed
Mass fraction imposed
Enter the value at the inlet and confirm.
For the other boundaries, also select Mass fraction imposed along…
Mass fraction imposed along…
Then select the Insulated boundary option.
Insulated boundary
Repeat the same procedure for the other sides.
Finally, you need to successively specify the several functional dependences created previously for the viscosity, the density and the source term in the transport equation for the species. For this, click the LSPM button. A menu opens with three entries, successively for the viscosity factor (fac), the density and the source term (cprod).
Click fac = … to specify the functional dependence of the zero shear viscosity.
fac = …
Make sure that Reciprocal sum is selected.
Click f1(…)
f1(…)
Select the polynomial function f(X1) = a+b*X1+c*X1**2+d*X1**3+e**X1**4
f(X1) = a+b*X1+c*X1**2+d*X1**3+e**X1**4
Click Change field X1 =
Change field X1 =
Select the previously defined species (the bubble radius) from the list.
Modify the parameters of the polynomial expression, setting the values accordingly:
Modify parameter a = ….
Modify parameter b = ….
Modify parameter c = ….
Modify parameter d = ….
Modify parameter e = ….
Click density = … to specify the functional dependence of the density.
density = …
Make sure that Reciprocal sum has been selected.
Repeat the procedure for the visocisty.
Click cprod = … to specify the functional dependence of the source term in the transport equation.
cprod = …
Make sure that Product has been selected.
Click f1(…)
f1(…)
Select the Arefmanesh function f(X1,X2) = Arefmanesh.
f(X1,X2) = Arefmanesh
Click Change field X1 =
Change field X1 =
Select the previously defined species (the bubble radius) from the list.
Click Change field X2 =
Change field X2 =
Select the pressure in the list.
Modify the parameters of the Arefmanesh function, setting the values accordingly:
Modify parameter a = ….
Modify parameter b = ….
Modify parameter c = ….
Modify parameter d = ….
Modify parameter e = ….
The model defined for the simulation of a foaming process involves many non-linearities. Appropriate convergence strategies can be enabled for facilitating the calculation. For this, in the menu for the sub-task, click Numerical parameters
Numerical parameters
Several options can be activated. In particular, select Enable evolution on moving boundaries if the simulation involves a free surface (as it most likely will).
Enable evolution on moving boundaries
Select Enable convergence strategy for rheology/slip if the fluid model involves rheological non-linearities, such as shear thinning.
Enable convergence strategy for rheology/slip
Select Enable convergence strategy for foaming as this is certainly relevant in the present context
Enable convergence strategy for foaming
These numerical selections can also be performed at the very end of the setup.