Skip to content

Commit a5da1a0

Browse files
fangjianfangjian
authored andcommitted
add two test cases
1 parent 10d4a49 commit a5da1a0

File tree

16 files changed

+1268
-25
lines changed

16 files changed

+1268
-25
lines changed

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ if (${BUILD_TESTING})
172172
include(CTest)
173173
message(STATUS "MPI INCL ALSO FOUND: ${MPI_INCLUDE_PATH}")
174174
message(STATUS "MPI EXEC: ${MPIEXEC_EXECUTABLE}")
175-
#dd_test(NAME TGV2D COMMAND ${MPIEXEC_EXECUTABLE} -n 4 ${CMAKE_INSTALL_PREFIX}/bin/astr run ./datin/input.tgv2d WORKING_DIRECTORY ${test_dir}/TGV2D)
176-
#et_tests_properties(TGV2D PROPERTIES LABELS "nondim")
175+
add_test(NAME SOD COMMAND ${MPIEXEC_EXECUTABLE} -n 2 ${CMAKE_INSTALL_PREFIX}/bin/astr run ./datin/input.sod WORKING_DIRECTORY ${test_dir}/sod)
176+
set_tests_properties(SOD PROPERTIES LABELS "nondim")
177177
add_test(NAME Shuosher COMMAND ${MPIEXEC_EXECUTABLE} -n 2 ${CMAKE_INSTALL_PREFIX}/bin/astr run ./datin/input.shuosher WORKING_DIRECTORY ${test_dir}/Shuosher)
178178
set_tests_properties(Shuosher PROPERTIES LABELS "nondim")
179179
add_test(NAME VT COMMAND ${MPIEXEC_EXECUTABLE} -n 8 ${osub} ${CMAKE_INSTALL_PREFIX}/bin/astr run ./datin/input.2dvort WORKING_DIRECTORY ${test_dir}/VT)

examples/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ add_subdirectory(Taylor_Green_Vortex_2D)
44
add_subdirectory(Channel)
55
add_subdirectory(Rayleigh–Taylor-Instability)
66
add_subdirectory(Shuosher)
7+
add_subdirectory(sod)
8+
add_subdirectory(Riemann2D)
79
add_subdirectory(Vortex_Transport)
810
add_subdirectory(MixingLayer)
911
add_subdirectory(SWLBI)
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
install(DIRECTORY DESTINATION ${CMAKE_INSTALL_PREFIX}/examples/Lid-Driven-Cavity)
2+
install(DIRECTORY datin DESTINATION ${CMAKE_INSTALL_PREFIX}/examples/Lid-Driven-Cavity)
3+
4+
# If testing active add test for Lid-Driven-Cavity case
5+
if (${BUILD_TESTING})
6+
set(case_dir "${test_dir}/Lid-Driven-Cavity")
7+
file(MAKE_DIRECTORY ${case_dir})
8+
file(COPY datin DESTINATION ${case_dir})
9+
endif()

examples/Riemann2D/CMakeLists.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
install(DIRECTORY DESTINATION ${CMAKE_INSTALL_PREFIX}/examples/Riemann2D)
2+
install(DIRECTORY datin DESTINATION ${CMAKE_INSTALL_PREFIX}/examples/Riemann2D)
3+
4+
# If testing active add test for Riemann2D case
5+
if (${BUILD_TESTING})
6+
set(case_dir "${test_dir}/Riemann2D")
7+
file(MAKE_DIRECTORY ${case_dir})
8+
file(COPY datin DESTINATION ${case_dir})
9+
endif()

examples/Riemann2D/datin/controller

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
############################################################
2+
# control file for ASTR code #
3+
############################################################
4+
5+
# lwsequ,lwslic,lavg,lcracon
6+
f, f, f, f
7+
8+
# maxstep,feqchkpt,feqwsequ,feqslice,feqlist,feqavg
9+
8000, 1000, 1000, 50, 1, 50
10+
11+
# deltat
12+
1.d-4
13+
14+
# The controller file will be read during a simulation,
15+
# everytime after dumping checkpoint.
16+
17+
#+---------------+-----------------------------------------+
18+
#| lwsequ | to output flowfield sequence |
19+
#| lwslic | to output flowfield at given i/j/k cut |
20+
#| | , slice.dat will be required to define |
21+
#| | i/j/k position |
22+
#| lavg | to calculate statistics and also output |
23+
#| | meanflow, 2order and 3order files. |
24+
#+---------------+-----------------------------------------+
25+
#| maxstep | the max step to run. |
26+
#| feqchkpt | frequency of writing checkpoint |
27+
#| feqwsequ | frequency of writing flowfield sequence |
28+
#| feqslice | frequency of writing slices |
29+
#| feqlist | frequency of listing log |
30+
#| feqavg | frequency of averaging flowfield |
31+
#| feqchkpt | frequency of outputting checkpoint |
32+
#+---------------+-----------------------------------------+
33+
#| deltat | the time step |
34+
#+---------------+-----------------------------------------+
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
########################################################################
2+
# input file of ASTR code #
3+
########################################################################
4+
5+
# flowtype : The type of flow problem
6+
riem2d
7+
8+
# im,jm,km : The size of grid.
9+
400,400,0
10+
11+
# lihomo,ljhomo,lkhomo : The homogeneous directions
12+
f,f,t
13+
14+
# nondimen,diffterm,lfilter,lreadgrid,lfftz,limmbou,ltimrpt,lcomb : Parameters
15+
t,f,f,f,f,f,t,f
16+
17+
# lrestar : start mode
18+
f
19+
20+
# alfa_filter, kcutoff : Filter parameters
21+
0.49d0, 48
22+
23+
# ref_t,reynolds,mach : Reference variables
24+
273.15d0, 3000.d0, 10.d0
25+
26+
# conschm,difschm,rkscheme,odetype : Numerical scheme
27+
543e, 643e, rk3, rk3
28+
29+
# recon_schem, lchardecomp,bfacmpld : Parameters for upwind-biased scheme
30+
3, t, 0.7d0, 0.01d0
31+
32+
# num_species : number of species
33+
0
34+
35+
# turbmode,iomode : turbulence model
36+
none,h
37+
38+
# bctype : Boundary condition definition
39+
0
40+
0
41+
0
42+
0
43+
1
44+
1
45+
46+
# ninit : Initial method
47+
0
48+
49+
# spg_imin,spg_imax,spg_jmin,spg_jmax,spg_kmin,spg_kmax : Sponge layer range
50+
0, 0, 0, 0, 0, 0
51+
52+
# gridfile
53+
./datin/grid.h5
54+
55+
56+
########################################################################
57+
# bctype #
58+
# 1 : periodic bc, nothing will be done. #
59+
# 41 : isothermal wall, wall temperature input. #
60+
########################################################################

0 commit comments

Comments
 (0)