Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
KiT-RT
KiT-RT
Commits
6adbe7cc
Commit
6adbe7cc
authored
Jul 09, 2020
by
steffen.schotthoefer
Browse files
added MN linesource test case
parent
62955d62
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
code/tests/input/linesource_MN.cfg
0 → 100644
View file @
6adbe7cc
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Linesource Benchmarking File MN %
% Author <Steffen Schotthöfer> %
% Date 01.07.2020 %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% ---- File specifications ----
OUTPUT_DIR = ../../result
OUTPUT_FILE = rtsn_test_linesource_MN
LOG_DIR = ../../result/logs
MESH_FILE = linesource.su2
% ---- Solver specifications ----
CFL_NUMBER = 0.5
TIME_FINAL = 0.3
PROBLEM = LINESOURCE
SOLVER = MN_SOLVER
MAX_MOMENT_SOLVER = 2
ENTROPY_FUNCTIONAL = QUADRATIC
ENTROPY_OPTIMIZER = NEWTON
%
% ---- Boundary Conditions ----
BC_DIRICHLET = ( void )
QUAD_TYPE = GAUSS_LEGENDRE_TENSORIZED
QUAD_ORDER = 2
code/tests/input/linesource_MN_reference.vtk
0 → 100644
View file @
6adbe7cc
This diff is collapsed.
Click to expand it.
code/tests/input/linesource_PN.cfg
View file @
6adbe7cc
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Linesource Benchmarking File PN %
% Author <Steffen Schotthöfer> %
% Date 01.07.2020 %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% ---- File specifications ----
% ---- File specifications ----
OUTPUT_DIR = ../../result
OUTPUT_DIR = ../../result
OUTPUT_FILE = rtsn_test_linesource_PN
OUTPUT_FILE = rtsn_test_linesource_PN
...
...
code/tests/input/linesource.cfg
→
code/tests/input/linesource
_SN
.cfg
View file @
6adbe7cc
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Linesource Benchmarking File MN %
% Author <Steffen Schotthöfer> %
% Date 01.07.2020 %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% ---- File specifications ----
% ---- File specifications ----
OUTPUT_DIR = ../../result
OUTPUT_DIR = ../../result
OUTPUT_FILE = rtsn_test_linesource
OUTPUT_FILE = rtsn_test_linesource
...
...
code/tests/test_cases.cpp
View file @
6adbe7cc
...
@@ -81,3 +81,21 @@ TEST_CASE( "linesource_PN", "[testcases]" ) {
...
@@ -81,3 +81,21 @@ TEST_CASE( "linesource_PN", "[testcases]" ) {
REQUIRE
(
std
::
fabs
(
test
[
i
]
-
reference
[
i
]
)
<
eps
);
REQUIRE
(
std
::
fabs
(
test
[
i
]
-
reference
[
i
]
)
<
eps
);
}
}
}
}
TEST_CASE
(
"linesource_MN"
,
"[testcases]"
)
{
char
config_file_name
[
MAX_STRING_SIZE
]
=
"../tests/input/linesource_MN.cfg"
;
Config
*
config
=
new
Config
(
config_file_name
);
Solver
*
solver
=
Solver
::
Create
(
config
);
solver
->
Solve
();
solver
->
Save
();
auto
test
=
readVTKFile
(
"../result/rtsn_test_linesource_PN.vtk"
);
auto
reference
=
readVTKFile
(
"../tests/input/linesource_MN_reference.vtk"
);
double
eps
=
1e-3
;
REQUIRE
(
test
.
size
()
==
reference
.
size
()
);
for
(
unsigned
i
=
0
;
i
<
test
.
size
();
++
i
)
{
REQUIRE
(
std
::
fabs
(
test
[
i
]
-
reference
[
i
]
)
<
eps
);
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment