-
Notifications
You must be signed in to change notification settings - Fork 324
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add consistency test for reading Gmsh binary
input msh file.
- Loading branch information
Showing
6 changed files
with
102 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
INCLUDE(test_macros) | ||
INCLUDE_DIRECTORIES(${CMAKE_BINARY_DIR}/fem/src) | ||
|
||
CONFIGURE_FILE(case.sif case.sif COPYONLY) | ||
|
||
file(COPY ELMERSOLVER_STARTINFO binary.msh DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/") | ||
|
||
ADD_ELMER_TEST(ElmerGridConvertGmshBinary LABELS quick) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
case.sif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// Gmsh project created on Sat Dec 21 08:30:08 2024 | ||
SetFactory("OpenCASCADE"); | ||
//+ | ||
Box(1) = {0, 0, 0, 20, 20, 20}; | ||
//+ | ||
Physical Surface("side", 13) = {6}; | ||
//+ | ||
Physical Surface("top", 14) = {4}; | ||
//+ | ||
Physical Surface("other", 15) = {1, 5, 2, 3}; | ||
//+ | ||
Physical Volume("body1", 16) = {1}; |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
! Consistency test for workflow where Gmsh binary file is converted with ElmerGrid | ||
! | ||
! R.B. 21.12.2024 | ||
|
||
Header | ||
CHECK KEYWORDS Warn | ||
Mesh DB "." "mesh" | ||
Include Path "" | ||
Results Directory "" | ||
End | ||
|
||
Simulation | ||
Max Output Level = 5 | ||
Coordinate System = "Cartesian" | ||
Simulation Type = "Steady State" | ||
Steady State Max Iterations = 1 | ||
Output Intervals = 0 | ||
|
||
Post File = case.vtu | ||
End | ||
|
||
Constants | ||
Gravity(4) = 0 -1 0 9.82 | ||
Stefan Boltzmann = 5.67e-08 | ||
End | ||
|
||
Body 1 | ||
Name = "Body" | ||
Body Force = 1 | ||
Equation = 1 | ||
Material = 1 | ||
End | ||
|
||
Equation 1 | ||
Name = "Equations" | ||
Active Solvers(1) = 2 | ||
End | ||
|
||
Solver 1 | ||
Equation = "CheckMesh" | ||
Procedure = "MeshChecksum" "MeshChecksum" | ||
Reference Values(8) = 2667 584640 1160 1051425 164832 92 222847 10438.792297017142 | ||
End | ||
|
||
Solver 2 | ||
Equation = "Heat Equation" | ||
Variable = "Temperature" | ||
Procedure = "HeatSolve" "HeatSolver" | ||
|
||
Linear System Solver = "Iterative" | ||
Linear System Iterative Method = "BiCGStab" | ||
Linear System Max Iterations = 1000 | ||
Linear System Convergence Tolerance = 1.0e-08 | ||
Linear System Abort Not Converged = True | ||
Linear System Preconditioning = "ILU0" | ||
Linear System Residual Output = 0 | ||
Nonlinear System Max Iterations = 1 | ||
End | ||
|
||
Material 1 | ||
Name = "Material" | ||
Density = 1 | ||
Heat Conductivity = 1 | ||
End | ||
|
||
Body Force 1 | ||
Name = "BodyForce" | ||
Heat Source = 1 | ||
End | ||
|
||
Boundary Condition 1 | ||
Name = "Constraint" | ||
Target Boundaries(1) = 1 | ||
Temperature = 0 | ||
End | ||
|
||
Solver 1 :: Reference Norm = 1.0 | ||
Solver 2 :: Reference Norm = 1.44365965E+02 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
include(test_macros) | ||
execute_process(COMMAND ${ELMERGRID_BIN} 14 2 binary.msh -autoclean -out mesh) | ||
RUN_ELMER_TEST() |