In this chapter, we will use the first example problem EX01(2D) in THMC benchmarks
to demonstrate an end-to-end workflow for running a 2D vertical unsaturated flow simulation. Simulation process is shown on Figure 2.0
Figure 2.0 Simulation Process
Get the THMC software: 1.2.2 How to get THMC software
Install THMC: 1.2.3 How to install THMC software
All datas are organized in a folder structure as following, and the root folder name is the project name, we need to create a project for the simulation. Steps as following:
└─THMC/
├─ Project/
│ ├─ Project_1/
│ │ ├─ Mesh/
│ │ ├─ Solver/
│ │ │ └─ HGC4.3 (or HGC5.3)/
│ │ │ ├─ Output/
│ │ │ │ ├─ Original/
│ │ │ │ ├─ Flow/
│ │ │ │ ...
│ │ │ ├─ SIM.inp
│ │ │ └─ SIM.dm
│ │ └─ Project.xml
│ ├─ Project_2/
│ ...
Parameter | Value |
---|---|
Project Name | EX01 |
Model | THMC2D |
Table 2.1 Project Parameters
Project
\ New
.
Figure 2.1 Create a new project
In the Project Name
text field, enter "2DEX01".
Since it is a 2D numerical simulation, select THMC2D
in Model
, then click Confirm
.
Figure 2.2 Set project name and model
Before we start to create the mesh for this example, we have to create a solution in the Geometry Mesh GUI
. Steps as following:
The Geometry Mesh
module
Figure 2.3 Click on The Geometry Mesh icon
Geometry Mesh GUI
File
\ New or Open Solution
.
Figure 2.4 Create a new solution
New or Open Solution
window, enter the solution name and click Create New
.
Figure 2.5 Set project name and model
Parameter | Value |
---|---|
Plane | ZX |
Shape | Square |
W | 50 |
H | 200 |
Table 2.2 Geometry Parameters
Before creating the mesh for our simulation, we have to create a single rectangular domain geometry for the mesh. Steps as following:
Square
icon located on the left side toolbar of the Geometry Mesh GUI.
Figure 2.6 Click on the square tool
Rectangular
enter W=50 and H=200, click on the Preview
. The geometry will be displayed on the screen.
Figure 2.7 Create a rectangular domain
Create
button, a rectangular domain 50 by 200 will be actually created.
Figure 2.8 The rectangular domain
After creating the domain, we are going to create the actual mesh in the domain. We want to split the Z-direction of the domain into 40 segments, so there will be 40 elements in the resulted mesh. Steps as following:
Parameter | Value |
---|---|
Mesh | Quadrilateral |
BG1 Nodes Count | 41 |
Table 2.2 Mesh Parameters
Mesh Generator
icon on the upper toolbar on the Geometry GUI
, then click it.
Figure 2.9 Mesh Generatior Icon
Quadrilateral
button. Then the window will close automatically, and there will be a surface that fills the domain we just created.
Figure 2.10 Mesh Generator
Figure 2.11 A surface in the domain
Geometry GUI
, find the first node GEO(d1, n4)
of the tree structure. Expand on the node, find the first child node domain1
to expand its child nodes, there will be 4 Edge
and 4 BG
under it.
Figure 2.12 Expand the child nodes under domain1
BG1
node, when you click on the node, two ends of the corresponding BG1
will be selected on the filled domain. We can find that 'BG1' is a Z-direction edge on the domain. In order to split the domain into 40 elements, we need to split the two ends (nodes) on the edge into 41 nodes.
Figure 2.13 BG1 on the domain
BG1
node, a menu will be displayed. On the menu, find the text field next to Set Nodes Count
, enter 41
then click on Set Nodes Count
.
Figure 2.14 Set nodes count for BG1
Mesh Generator
and click it to open the mesh generation tool. Then click the Quadrilateral
button again. The window will close automatically, and there will be the final mesh with 40 elements that fills the domain.
Figure 2.15 The final mesh
Module | Condition | Type | Group/Domain |
---|---|---|---|
Flow |
Initial Condition | Point | Hydrological_Initial_0 |
Flow |
Initial Condition | Point | Hydrological_Initial_-90 |
Flow |
Initial Condition | Point | Hydrological_Initial_-97 |
Table 2.3 Initial Condition Parameters
After obtaining the final mesh, we will create multiple groups of geometry objects for future assignments of initial and boundary conditions.
For instance, in this example problem, there are three distinct geometry groups within the mesh we just created for setting initial conditions: the top, the bottom, and the remaining mesh.
Create Group
icon on the left toolbar on the Geometry GUI
, then click it. In Benchmark problem 1 for the initial condition, since different values were input for the top, bottom, and the rest of the area of interest, we will specify initial conditions for each of these three parts separately.
Figure 2.16 The mesh generation tool
Module | Boundary | Type | Group/Domain |
---|---|---|---|
Flow |
Variable | Edge | Hydrological_Variable |
Module | Boundary | Type | Group/Domain |
---|---|---|---|
Flow |
Dirichlet | Point | Hydrological_Dirichlet_right |
Follow Parameter Wizard to input parameters.
Module | Condition | Group/Domain | Value |
---|---|---|---|
Flow |
Initial Condition | Hydrological_Initial_0 | 0 |
Flow |
Initial Condition | Hydrological_Initial_-90 | -90 |
Flow |
Initial Condition | Hydrological_Initial_-97 | -97 |
Module | Boundary | Group/Domain | Ponding Depth(cm) | Minimum Pressure Head(cm) | 0 day | 10 day | 10.001 day | 1.0E38 day |
---|---|---|---|---|---|---|---|---|
Flow |
Variable | Hydrological_Variable | 0 | -90 | 5 | 5 | -5 | -5 |
Module | Boundary | Group/Domain | 0 day | 1.0E38 day |
---|---|---|---|---|
Flow |
Dirichlet | Hydrological_Dirichlet | 0 | 0 |