20.3. User Inputs

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:

  1. 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.

  2. Return to the subtask where you defined the flow and select Material Data. Define the viscosity and density as a function of the species.

    1. Click the PMAT button to enable the PMAT material dependence menu.

    2. 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).

    3. 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).

    4. Select the PMAT button again to disable the PMAT material dependence menu.

    5. Specify a (constant) value for the Average density.

        Average density

      Enter a value that corresponds to the density obtained with the initial bubble radius.

  3. 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.

    1. 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.

    2. 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)

      1. 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.

      2. Select the PMAT button to enable the PMAT material dependence menu.

      3. 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).

      4. Select the PMAT button again to disable the PMAT material dependence menu.

      5. 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.

    3. 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.

  4. 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).

    1. Click fac = … to specify the functional dependence of the zero shear viscosity.

        fac = …

      Make sure that Reciprocal sum is selected.

      1. 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

      2. Click Change field X1 =

          Change field X1 =

        Select the previously defined species (the bubble radius) from the list.

      3. 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 = ….

    2. 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.

    3. Click cprod = … to specify the functional dependence of the source term in the transport equation.

        cprod = …

      Make sure that Product has been selected.

      1. Click f1(…)

          f1(…)

        Select the Arefmanesh function f(X1,X2) = Arefmanesh.

         

        f(X1,X2) = Arefmanesh

      2. Click Change field X1 =

          Change field X1 =

        Select the previously defined species (the bubble radius) from the list.

      3. Click Change field X2 =

          Change field X2 =

        Select the pressure in the list.

      4. 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 = ….

  5. 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.