README.md 2.27 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
Quality tetrahedral mesh generation with HXT : reproducible benchmark
=====================================================================

This repository contains information to help you reproduce the result in the paper entitled

 > Quality tetrahedral mesh generation with HXT


In this paper, three programs are tested and compared: Gmsh, TetGen and HXT.
Those software are not supplied in this repository, but you get simply download
them as follow:

 * Gmsh and HXT: download Gmsh's Gitlab repository [here](https://gitlab.onelab.info/gmsh/gmsh).
 * TetGen: download [here](http://wias-berlin.de/software/index.jsp?id=TetGen)

You also need a C and C++ compiler: GCC 9.3.0 is the compiler used in the paper.


## Compilation

To compile **Gmsh**, create a build directory, open a terminal in the build
directory and simply modify `GMSH_DIR` to point to where the top-level gmsh
directory is located:

    cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_FLAGS="-march=native" -DCMAKE_CXX_FLAGS="-march=native" GMSH_DIR
    make -j
    export GMSH=$(PWD)/gmsh

To compile **HXT's tetrahedral mesh generator**, create another build
directory, open a terminal in that directory and again, adapt these command:

    cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_FLAGS="-march=native" -DCMAKE_CXX_FLAGS="-march=native" PATH_TO_GMSH/contrib/hxt/tetMesh
    export HXTTETMESH=$(PWD)/tetMesh_CLI

To compile **TetGen**, simply enter the command

    make
    export TETGEN=$(PWD)/tetgen

in TetGen's top-level directory

verify that all program works correctly by asking them to show the help:

    $GSMH -h
    $HXTTETMESH -h
    $TETGEN -h


## Create STL files for TetGen

Open each \*.msh in the *meshes* directory with gmsh and export the mesh to the stl format with the same basename.


## Running the performance benchmark

Once the STL files are created, the 3 programs are compiled correctly and the
environment variables `$GSMH`, `$HXTTETMESH` and `$TETGEN` are set, simply go
in this directory and launch the benchmarks with the commands:

    bash gmsh_bench.sh
    bash hxt_bench.sh "1 2 4 8" # adapt to the nbr. of threads to be tested
    bash hxt_reprod_bench.sh "1 2 4 8" # same
    bash tetgen_bench.sh


## Running the mesh quality benchmarks

The mesh quality benchmark procedure is explained in qualities/README.md