NuSiF-Solver/EnhancedSolver/2D-seq
2024-07-27 02:19:56 +02:00
..
src EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
vis_files EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
backstep.par EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
canal.par EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
config.mk EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
dcavity.par EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
include_CLANG.mk Review particle tracer. Refactor. 2024-03-05 21:24:45 +01:00
include_GCC.mk Integrate sequential enhanced solver 2024-02-15 09:44:06 +01:00
include_ICC.mk Integrate sequential enhanced solver 2024-02-15 09:44:06 +01:00
karman.par EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
Makefile EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
README.md Integrate sequential enhanced solver 2024-02-15 09:44:06 +01:00
residual.plot EnhancedSolver port complete 2024-07-27 02:19:56 +02:00
surface.plot Integrate sequential enhanced solver 2024-02-15 09:44:06 +01:00
vector.plot Integrate sequential enhanced solver 2024-02-15 09:44:06 +01:00

C source skeleton

Build

  1. Configure the toolchain and additional options in config.mk:
# Supported: GCC, CLANG, ICC
TAG ?= GCC
ENABLE_OPENMP ?= false

OPTIONS +=  -DARRAY_ALIGNMENT=64
#OPTIONS +=  -DVERBOSE
#OPTIONS +=  -DVERBOSE_AFFINITY
#OPTIONS +=  -DVERBOSE_DATASIZE
#OPTIONS +=  -DVERBOSE_TIMER

The verbosity options enable detailed output about solver, affinity settings, allocation sizes and timer resolution. For debugging you may want to set the VERBOSE option:

# Supported: GCC, CLANG, ICC
TAG ?= GCC
ENABLE_OPENMP ?= false

OPTIONS +=  -DARRAY_ALIGNMENT=64
OPTIONS +=  -DVERBOSE
#OPTIONS +=  -DVERBOSE_AFFINITY
#OPTIONS +=  -DVERBOSE_DATASIZE
#OPTIONS +=  -DVERBOSE_TIMER
`

2. Build with:

make


You can build multiple toolchains in the same directory, but notice that the Makefile is only acting on the one currently set.
Intermediate build results are located in the `<TOOLCHAIN>` directory.

To output the executed commands use:

make Q=


3. Clean up with:

make clean

to clean intermediate build results.

make distclean

to clean intermediate build results and binary.

4. (Optional) Generate assembler:

make asm

The assembler files will also be located in the `<TOOLCHAIN>` directory.

## Usage

You have to provide a parameter file describing the problem you want to solve:

./exe-CLANG dcavity.par


Examples are given in in dcavity (a lid driven cavity test case) and canal (simulating a empty canal).

You can plot the resulting velocity and pressure fields using gnuplot:

gnuplot vector.plot

and for the pressure:

gnuplot surface.plot