PDF

Frozen Inclusion
Introduction
This benchmark example simulates phase change in porous media. The model studies the melting process of an ice inclusion within a porous medium, and it demonstrates how to couple Darcy’s Law and the Heat Transfer in Porous Media interfaces including phase change. It is one of the test cases from the INTERFROST project — a comparison project for coupled thermo-hydraulic systems with respect to climate change in permafrost regions (see Ref. 2).
Model Definition
The model setup is shown in Figure 1. A flow channel 3 meters in length and 1 meter in width contains a squared ice inclusion of 33.3 cm in length, centered at the coordinates x = 1 m and y = 0.5 m.
Figure 1: Model geometry, initial temperature distribution, and boundary conditions.
The initial temperature of the ice inclusion is Tini = −5°C. The temperature in the porous channel is Tinw = +5°C. The fluid flow is driven by a hydraulic head gradient of ΔH = 3% over the length of the channel.
The initial pressure and velocity field are computed from a steady state flow simulation for a uniformly distributed temperature and permeability (as if the ice inclusion was not present). Considering the symmetry of the benchmark test model, only the lower half of the domain is modeled.
The following simplifications have been made in the INTERFROST benchmark and therefore are also assumed in this example: No thermal dispersion is included in the heat transfer equation, and water density and dynamic viscosity are considered constant with respect to the temperature (see Table 1).
Model equations
The Porous Medium feature in Darcy’s Law interface includes an option to define a user-defined storage Sp (SI unit: 1/Pa) which in this case is defined as
(1)
where Sw is the water saturation, εp is the porosity, and β the effective compressibility; which is a combined value of water, ice, and solid matrix compressibility. For simplicity, gravity is neglected. The variable Qm is a mass source which represents the additional liquid water due to the melting of the ice inclusion:
(2).
here ρi and ρw are the ice and liquid water densities. The liquid water saturation Sw depends on the phase change as:
(3)
here, Sw, res it the residual liquid water saturation and θ2 is a smooth step function defined in the Phase Change Material node. The step function θ2(T) is zero for temperatures below the melting temperature Tpc, and it equals 1 for temperatures above Tpc.
In the INTERFROST benchmark it is assumed that the mushy ice zone extends from 0°C to -1°C. Therefore, Tpc is set to -0.5°C and the transition interval of θ2 is defined as 1K to represent this.
The heat transfer in the porous medium is described by the following equation:
(4)
here (ρC)eq is the equivalent value of density ρ (kg/m3) and heat capacity C at constant pressure (J/kg·K), keq is the effective thermal conductivity (W/m·K), T is the temperature (K), and Q is a heat source (W/m3). The variable Cw is the effective fluid’s heat capacity at constant pressure.
Model data
The benchmark example describes the ice-to-water phase change of an ice inclusion within a porous channel. The values for thermal properties of water, ice, and solid matrix are presented in Table 1.
A latent heat of melting, L= 334 kJ/kg is used. Additional physical parameters used in the example are summarized in Table 2.
μw
1.793·10-3 Pa·s
ε
β
10-8  Pa-1
Swres
Ω
kint
1.3·10-10 m2
Results and Discussion
The simulation is run for 56 hours which is the time until the frozen inclusion is completely melted and the cooler temperatures have been convected out of the channel. However, it is also interesting to display the effect of the molten inclusion on the pressure and temperature distribution; Figure 2 shows the pressure distribution after 9 hours of simulated time when there is still some ice present. As gravity has been neglected, only the pressure effects of the ice inclusion are shown.]
Figure 2: Pressure distribution after 9 hours when there is still some ice present in the model domain.
The temperature field is shown at the same time (after 9 hours) in Figure 3 and the liquid water saturation in Figure 4. Both figures indicate the ice inclusion and its influence on the temperature field. The low temperatures are convected in the downstream part of the domain.
Figure 3: Surface plot showing the temperature distribution after 9 hours.
Figure 4: Surface plot showing the liquid water saturation after 9 hours. Effectively the areas with liquid water appear in blue whereas the areas of ice appear in white.
The plots below have been used as performance measures in the INTERFROST benchmark, and therefore are also included here:
The evolution of the minimum of the simulated temperature field as a function of time is shown in Figure 5..
Figure 5: The minimum temperature in the model domain as a function of time.
Figure 6 shows the time evolution of the total heat flux exiting the system at the downstream boundary.
Figure 6: Total heat flux exiting the system via the outflow boundary as a function of time.
Figure 7 displays the evolution of the total liquid water volume in the domain as a function of time.
Figure 7: Total liquid water volume in the domain as a function of time.
Notes About the COMSOL Implementation
A residual liquid phase is present in soils even for temperatures significantly below 0°C. To make sure that this residual water is not subject to phase change in the model and that it is not convected, it is considered as a second immobile solid (in addition to the solid matrix). According to Ref. 1, the residual saturation Sw, res is set to 0.05.
References
1. C. Grenier and others, “Groundwater flow and heat transport for systems undergoing freeze-thaw: Intercomparison of numerical simulators for 2D test cases,” Advances in Water Resources, vol. 114, pp. 196–218, 2018.
2. https://wiki.lsce.ipsl.fr/interfrost/doku.php?id=test_cases:five
Application Library path: Subsurface_Flow_Module/Heat_Transfer/frozen_inclusion
Modeling Instructions
From the File menu, choose New.
New
In the New window, click  Model Wizard.
Model Wizard
1
In the Model Wizard window, click  2D.
2
In the Select Physics tree, select Fluid Flow>Porous Media and Subsurface Flow>Darcy’s Law (dl).
3
4
In the Select Physics tree, select Heat Transfer>Porous Media>Heat Transfer in Porous Media (ht).
5
6
Click  Study.
7
In the Select Study tree, select General Studies>Stationary.
8
Global Definitions
Parameters 1
1
In the Model Builder window, under Global Definitions click Parameters 1.
The parameters defining the material properties of the solid matrix, water, and ice have to be declared. They are available in a file and you can import them as follows:
2
In the Settings window for Parameters, locate the Parameters section.
3
Click  Load from File.
4
Geometry 1
Now, the model domain is drawn as two rectangles, one representing the porous domain, the other the frozen inclusion within the porous domain. Create the geometry as follows and note that due to symmetry only half of the model domain is drawn.
Rectangle 1 (r1)
1
In the Geometry toolbar, click  Rectangle.
2
In the Settings window for Rectangle, locate the Size and Shape section.
3
In the Width text field, type 3.
4
In the Height text field, type 0.5.
Rectangle 2 (r2)
1
In the Geometry toolbar, click  Rectangle.
2
In the Settings window for Rectangle, locate the Size and Shape section.
3
In the Width text field, type 0.333.
4
In the Height text field, type 0.333/2.
5
Locate the Position section. From the Base list, choose Center.
6
In the x text field, type 1.
7
In the y text field, type 0.5-0.333/4.
8
In the Geometry toolbar, click  Build All.
Materials
Define the materials in the next step. Introduce them as empty material nodes, first. As soon as the physics has been defined, the material node menu will show you which properties are needed for the simulation. You can then just fill in the values defined in the Parameters list.
Solid Matrix
1
In the Model Builder window, under Component 1 (comp1) right-click Materials and choose Blank Material.
2
In the Settings window for Material, type Solid Matrix in the Label text field.
Water
1
Right-click Materials and choose Blank Material.
2
In the Settings window for Material, type Water in the Label text field.
Ice
1
Right-click Materials and choose Blank Material.
2
In the Settings window for Material, type Ice in the Label text field.
Porous Material 1 (pmat1)
1
Right-click Materials and choose More Materials>Porous Material.
2
In the Settings window for Porous Material, locate the Geometric Entity Selection section.
3
From the Selection list, choose All domains.
4
Locate the Phase-Specific Properties section. Click  Add Required Phase Nodes.
Fluid 1 (pmat1.fluid1)
1
In the Model Builder window, click Fluid 1 (pmat1.fluid1).
2
In the Settings window for Fluid, locate the Fluid Properties section.
3
From the Material list, choose Water (mat2).
Solid 1 (pmat1.solid1)
1
In the Model Builder window, click Solid 1 (pmat1.solid1).
2
In the Settings window for Solid, locate the Solid Properties section.
3
From the Material list, choose Solid Matrix (mat1).
4
In the θs text field, type 1-epsilon_p.
Immobile Fluid 1 (pmat1.imfluid1)
1
In the Model Builder window, right-click Porous Material 1 (pmat1) and choose Immobile Fluid.
2
In the Settings window for Immobile Fluid, locate the Immobile Fluid Properties section.
3
From the Material list, choose Water (mat2).
4
In the θimf text field, type epsilon_p*Sw_res.
Heat Transfer in Porous Media (ht)
Continue with setting up the physics. Since some heat transfer variables are needed to define the saturation variables as explained in the Model Definition section, start with Heat Transfer in Porous Media (ht).
1
In the Model Builder window, under Component 1 (comp1) click Heat Transfer in Porous Media (ht).
2
In the Settings window for Heat Transfer in Porous Media, locate the Physical Model section.
3
In the Tref text field, type T_initial_w.
Porous Matrix 1
1
In the Model Builder window, under Component 1 (comp1)>Heat Transfer in Porous Media (ht)>Porous Medium 1 click Porous Matrix 1.
2
In the Settings window for Porous Matrix, locate the Matrix Properties section.
3
From the Define list, choose Solid phase properties, because the properties of a pure solid material are given.
With the following steps you define the residual liquid water volume as product of porosity and predefined residual water saturation.
Porous Medium 1
In the Model Builder window, click Porous Medium 1.
Immobile Fluids 1
In the Physics toolbar, click  Attributes and choose Immobile Fluids.
Fluid 1
1
In the Model Builder window, click Fluid 1.
2
In the Settings window for Fluid, locate the Model Input section.
3
From the pA list, choose Absolute pressure (dl).
4
Locate the Heat Convection section. From the u list, choose Darcy’s velocity field (dl/porous1).
Phase Change Material 1
In the Physics toolbar, click  Attributes and choose Phase Change Material.
Phase Change Material 1
1
In the Model Builder window, expand the Component 1 (comp1)>Heat Transfer in Porous Media (ht)>Porous Medium 1>Fluid 1 node, then click Phase Change Material 1.
2
In the Settings window for Phase Change Material, click to expand the Sketch section.
Inflate the sketch to visualize which material you have to choose for which temperatures. In this case, material 1 should be ice, material 2 water. You will use the function θ2 later when you define the water saturation as a function of phase change.
3
Locate the Phase Change section. In the Tpc,12 text field, type T_pc.
4
In the ΔT12 text field, type 1[K].
5
In the L12 text field, type L.
6
Locate the Phase 1 section. From the Material, phase 1 list, choose Ice (mat3).
7
Locate the Phase 2 section. From the Material, phase 2 list, choose Water (mat2).
Initial Values 1
1
In the Model Builder window, under Component 1 (comp1)>Heat Transfer in Porous Media (ht) click Initial Values 1.
2
In the Settings window for Initial Values, locate the Initial Values section.
3
In the T text field, type T_initial_w.
Initial Values 2
1
In the Physics toolbar, click  Domains and choose Initial Values.
2
3
In the Settings window for Initial Values, locate the Initial Values section.
4
In the T text field, type T_initial_i.
Temperature 1
1
In the Physics toolbar, click  Boundaries and choose Temperature.
2
3
In the Settings window for Temperature, locate the Temperature section.
4
In the T0 text field, type T_initial_w.
Outflow 1
1
In the Physics toolbar, click  Boundaries and choose Outflow.
2
Symmetry 1
1
In the Physics toolbar, click  Boundaries and choose Symmetry.
2
Definitions (comp1)
For Darcy’s Law the water saturation and the permeability have to be defined as temperature-dependent variables. More precisely they depend on θ2 which is the fraction of water due to phase change.
Variables 1
1
In the Model Builder window, expand the Component 1 (comp1)>Definitions node.
2
Right-click Component 1 (comp1)>Definitions and choose Variables.
3
In the Settings window for Variables, locate the Variables section.
4
Darcy’s Law (dl)
1
In the Model Builder window, under Component 1 (comp1) click Darcy’s Law (dl).
2
In the Settings window for Darcy’s Law, click to expand the Discretization section.
3
From the Pressure list, choose Linear.
Change the shape function to linear to reduce the computational time and increase numerical stability.
Porous Medium 1
1
In the Model Builder window, under Component 1 (comp1)>Darcy’s Law (dl) click Porous Medium 1.
2
In the Settings window for Porous Medium, locate the Porous Medium section.
3
From the Storage model list, choose User defined. In the Sp text field, type Sw*epsilon_p*beta.
Porous Matrix 1
1
In the Model Builder window, click Porous Matrix 1.
2
In the Settings window for Porous Matrix, locate the Matrix Properties section.
3
From the εp list, choose User defined. In the associated text field, type epsilon_p*Sw.
Mass Source 1
1
In the Physics toolbar, click  Domains and choose Mass Source.
The mass source accounts for the addition of water during melting as described in the Model Definition section.
2
In the Settings window for Mass Source, locate the Domain Selection section.
3
From the Selection list, choose All domains.
4
Locate the Mass Source section. In the Qm text field, type dl.epsilon*(rho_i-rho_w)*d(Sw,t). Remember that dl.epsilon was defined as epsilon_p*Sw to represent only the pore space that is filled with water.
The flow is driven by an imposed gradient of the hydraulic head. This is defined as a parameter and could be varied in a parametric sweep in future simulations (as it was done in the INTERFROST project, see References).
Hydraulic Head 1
1
In the Physics toolbar, click  Boundaries and choose Hydraulic Head.
2
3
In the Settings window for Hydraulic Head, locate the Hydraulic Head section.
4
In the H0 text field, type delta_H_dLx*3[m].
Hydraulic Head 2
1
In the Physics toolbar, click  Boundaries and choose Hydraulic Head.
2
Symmetry 1
1
In the Physics toolbar, click  Boundaries and choose Symmetry.
2
Materials
Having defined the physics, now fill in the empty expressions in the Materials node.
Porous Material 1 (pmat1)
1
In the Model Builder window, under Component 1 (comp1)>Materials click Porous Material 1 (pmat1).
2
In the Settings window for Porous Material, locate the Homogenized Properties section.
3
Solid Matrix (mat1)
1
In the Model Builder window, click Solid Matrix (mat1).
2
In the Settings window for Material, locate the Material Contents section.
3
Water (mat2)
1
In the Model Builder window, click Water (mat2).
2
In the Settings window for Material, locate the Material Contents section.
3
Ice (mat3)
1
In the Model Builder window, click Ice (mat3).
2
In the Settings window for Material, locate the Material Contents section.
3
Mesh 1
When generating the mesh, note that it should be fine enough to capture strong gradients within the phase change region. In this case, a maximum element size of 5 mm is enforced in the domain of the frozen inclusion.
Free Triangular 1
1
In the Mesh toolbar, click  Free Triangular.
2
In the Settings window for Free Triangular, locate the Domain Selection section.
3
From the Geometric entity level list, choose Domain.
4
Size 1
1
Right-click Free Triangular 1 and choose Size.
2
In the Settings window for Size, locate the Element Size section.
3
Click the Custom button.
4
Locate the Element Size Parameters section. Select the Maximum element size check box.
5
6
Click  Build Selected.
Free Triangular 2
In the Mesh toolbar, click  Free Triangular.
Size
1
In the Model Builder window, click Size.
2
In the Settings window for Size, locate the Element Size section.
3
From the Predefined list, choose Extra fine.
Free Triangular 2
In the Model Builder window, right-click Free Triangular 2 and choose Build All.
Study 1
Step 1: Stationary
1
In the Model Builder window, under Study 1 click Step 1: Stationary.
The initial pressure and velocity field results from a steady state flow simulation which is performed in this first step.
2
In the Settings window for Stationary, locate the Physics and Variables Selection section.
3
In the table, clear the Solve for check box for Heat Transfer in Porous Media (ht).
4
In the Home toolbar, click  Compute.
Time Dependent
Now add the time dependent study step. To ensure that the phase change is represented properly, the time steps have to be chosen small enough to catch the increase of temperature as soon as the ice has totally melted. This is done by defining the output times accordingly and by forcing the time step to be smaller than the output intervals.
1
In the Study toolbar, click  Study Steps and choose Time Dependent>Time Dependent.
2
In the Settings window for Time Dependent, locate the Study Settings section.
3
From the Time unit list, choose h.
4
In the Output times text field, type range(0,5,60)[min] range(1.5,0.5,18) range(18.1,0.05,22) range(22.5,0.5,28) range(29,1,56).
5
From the Tolerance list, choose User controlled.
6
In the Relative tolerance text field, type 0.005.
Solution 1 (sol1)
1
In the Study toolbar, click  Show Default Solver.
2
In the Model Builder window, expand the Solution 1 (sol1) node, then click Time-Dependent Solver 1.
3
In the Settings window for Time-Dependent Solver, click to expand the Time Stepping section.
4
From the Steps taken by solver list, choose Strict This ensures that the time step cannot be bigger than the output intervals. However, it can still be smaller if necessary.
5
Select the Initial step check box.
6
Step 2: Time Dependent
In the Model Builder window, under Study 1 right-click Step 2: Time Dependent and choose Compute Selected Step.
Results
The default plot shows the pressure distribution and velocity field at the final time. To see the pressure and velocity field for the full model domain at an earlier time, when there is still some ice present (see Figure 2), follow the steps below. First, create the full dataset from the simplified symmetric model domain.
Mirror 2D 1
1
In the Model Builder window, expand the Results>Datasets node.
2
Right-click Results>Datasets and choose More 2D Datasets>Mirror 2D.
3
In the Settings window for Mirror 2D, locate the Axis Data section.
4
In row Point 1, set Y to 0.5.
5
In row Point 2, set X to 3.
6
In row Point 2, set Y to 0.5.
7
Click to expand the Advanced section. Select the Remove elements on the symmetry axis check box.
Pressure (dl)
1
In the Model Builder window, under Results click Pressure (dl).
2
In the Settings window for 2D Plot Group, locate the Data section.
3
From the Dataset list, choose Mirror 2D 1.
4
From the Time (h) list, choose 9.
Streamline 1
1
In the Model Builder window, expand the Pressure (dl) node, then click Streamline 1.
2
In the Settings window for Streamline, locate the Streamline Positioning section.
3
From the Positioning list, choose Magnitude controlled.
4
In the Density text field, type 10.
5
In the Pressure (dl) toolbar, click  Plot.
Temperature
Add the surface plot of the temperature field as shown in Figure 3.
1
In the Home toolbar, click  Add Plot Group and choose 2D Plot Group.
2
In the Settings window for 2D Plot Group, type Temperature in the Label text field.
3
Locate the Data section. From the Dataset list, choose Mirror 2D 1.
4
From the Time (h) list, choose 9.
Surface 1
1
Right-click Temperature and choose Surface.
2
In the Settings window for Surface, locate the Expression section.
3
In the Expression text field, type T.
4
From the Unit list, choose degC.
5
In the Temperature toolbar, click  Plot.
Liquid Water Saturation
To reproduce the plot of the liquid water saturation (Figure 4), follow the instructions below.
1
In the Home toolbar, click  Add Plot Group and choose 2D Plot Group.
2
In the Settings window for 2D Plot Group, type Liquid Water Saturation in the Label text field.
3
Locate the Data section. From the Dataset list, choose Mirror 2D 1.
4
From the Time (h) list, choose 9.
Contour 1
1
Right-click Liquid Water Saturation and choose Contour.
2
In the Settings window for Contour, locate the Expression section.
3
In the Expression text field, type Sw.
4
Locate the Levels section. From the Entry method list, choose Levels.
5
In the Levels text field, type 0.05 0.5 1.
6
Locate the Coloring and Style section. From the Contour type list, choose Filled.
7
From the Color table list, choose JupiterAuroraBorealis.
8
From the Color table transformation list, choose Reverse.
9
In the Liquid Water Saturation toolbar, click  Plot.
Surface Minimum 1
To reproduce the next plots the resulting data has to be further evaluated. Follow the instructions below to derive the minimum temperature as a function of time.
1
In the Results toolbar, click  More Derived Values and choose Minimum>Surface Minimum.
2
In the Settings window for Surface Minimum, locate the Selection section.
3
From the Selection list, choose All domains.
4
Click Replace Expression in the upper-right corner of the Expressions section. From the menu, choose Component 1 (comp1)>Heat Transfer in Porous Media>Temperature>T - Temperature - K.
5
Locate the Expressions section. In the table, enter the following settings:
6
Click  Evaluate.
Table
1
Go to the Table window.
2
Click Table Graph in the window toolbar.
Results
Minimum Temperature
1
In the Model Builder window, under Results click 1D Plot Group 4.
2
In the Settings window for 1D Plot Group, type Minimum Temperature in the Label text field.
Line Integration 1
Following the next steps you will derive and plot the total heat flux exiting the system via the downstream boundary as a function of time.
1
In the Results toolbar, click  More Derived Values and choose Integration>Line Integration.
2
3
In the Settings window for Line Integration, click Replace Expression in the upper-right corner of the Expressions section. From the menu, choose Component 1 (comp1)>Heat Transfer in Porous Media>Boundary fluxes>ht.ntflux - Normal total heat flux - W/m².
4
Locate the Expressions section. In the table, enter the following settings:
As the model is a 2D approximation of the thawing process and due to symmetry only half the domain was modeled, the heat flux value has to be multiplied by the thickness of the model, dl.d, and by a factor of 2 to get the correct value.
5
Clicknext to  Evaluate, then choose New Table.
Table
1
Go to the Table window.
2
Click Table Graph in the window toolbar.
Results
Total Heat Flux
1
In the Model Builder window, under Results click 1D Plot Group 5.
2
In the Settings window for 1D Plot Group, type Total Heat Flux in the Label text field.
Surface Integration 2
The final plot, the evolution of total liquid water volume in the domain as shown in Figure 7 can be produced as follows.
1
In the Results toolbar, click  More Derived Values and choose Integration>Surface Integration.
2
In the Settings window for Surface Integration, locate the Selection section.
3
From the Selection list, choose All domains.
4
Locate the Expressions section. Click  Clear Table.
5
Sw*epsilon_p gives the pore space filled with water, dl.d is the thickness of the model and the factor of 2 is due to symmetry.
6
Clicknext to  Evaluate, then choose New Table.
Table
1
Go to the Table window.
2
Click Table Graph in the window toolbar.
Results
Total Liquid Water Volume
1
In the Model Builder window, under Results click 1D Plot Group 6.
2
In the Settings window for 1D Plot Group, type Total Liquid Water Volume in the Label text field.
Compare your results with those presented in Figure 7.