Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
lbmpy
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pycodegen
lbmpy
Commits
d0b0f1b8
Commit
d0b0f1b8
authored
1 year ago
by
Helen Schottenhamml
Browse files
Options
Downloads
Patches
Plain Diff
Shorten shear wave scenario for nightly tests.
parent
9645d493
No related branches found
No related tags found
1 merge request
!151
Shorten shear wave scenario.
Pipeline
#54860
passed
1 year ago
Stage: pretest
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lbmpy_tests/full_scenarios/shear_wave/scenario_shear_wave.py
+20
-6
20 additions, 6 deletions
lbmpy_tests/full_scenarios/shear_wave/scenario_shear_wave.py
with
20 additions
and
6 deletions
lbmpy_tests/full_scenarios/shear_wave/scenario_shear_wave.py
+
20
−
6
View file @
d0b0f1b8
...
@@ -2,7 +2,11 @@
...
@@ -2,7 +2,11 @@
The cumulant lattice Boltzmann equation in three dimensions: Theory and validation
The cumulant lattice Boltzmann equation in three dimensions: Theory and validation
by Geier, Martin; Schönherr, Martin; Pasquali, Andrea; Krafczyk, Manfred (2015)
by Geier, Martin; Schönherr, Martin; Pasquali, Andrea; Krafczyk, Manfred (2015)
Chapter 5.1
:cite:`geier2015` Chapter 5.1
NOTE: for integration tests, the parameter study is greatly shortened, i.e., the runs are shortened in time and
not all resolutions and viscosities are considered. Nevertheless, all values used by Geier et al. are still in
the setup, only commented, and remain ready to be used (check for comments that start with `NOTE`).
"""
"""
import
numpy
as
np
import
numpy
as
np
import
pytest
import
pytest
...
@@ -124,9 +128,15 @@ def run(l, l_0, u_0, v_0, nu, y_size, lbm_config, lbm_optimisation, config):
...
@@ -124,9 +128,15 @@ def run(l, l_0, u_0, v_0, nu, y_size, lbm_config, lbm_optimisation, config):
np
.
copyto
(
b
[
scenario
.
velocity_data_name
],
initial_vel_arr
[
b
.
global_slice
])
np
.
copyto
(
b
[
scenario
.
velocity_data_name
],
initial_vel_arr
[
b
.
global_slice
])
scenario
.
set_pdf_fields_from_macroscopic_values
()
scenario
.
set_pdf_fields_from_macroscopic_values
()
total_time_steps
=
20000
*
(
l
//
l_0
)
**
2
# NOTE: use those values to limit the runtime in integration tests
initial_time_steps
=
11000
*
(
l
//
l_0
)
**
2
total_time_steps
=
2000
*
(
l
//
l_0
)
**
2
eval_interval
=
1000
*
(
l
//
l_0
)
**
2
initial_time_steps
=
1100
*
(
l
//
l_0
)
**
2
eval_interval
=
100
*
(
l
//
l_0
)
**
2
# NOTE: for simulating the real shear-wave scenario from Geier et al. use the following values
# total_time_steps = 20000 * (l // l_0) ** 2
# initial_time_steps = 11000 * (l // l_0) ** 2
# eval_interval = 1000 * (l // l_0) ** 2
scenario
.
run
(
initial_time_steps
)
scenario
.
run
(
initial_time_steps
)
if
np
.
isnan
(
scenario
.
velocity_slice
()).
any
():
if
np
.
isnan
(
scenario
.
velocity_slice
()).
any
():
print
(
"
Result
"
,
inv_result
)
print
(
"
Result
"
,
inv_result
)
...
@@ -169,8 +179,12 @@ def create_full_parameter_study():
...
@@ -169,8 +179,12 @@ def create_full_parameter_study():
omega
,
omega_f
=
sp
.
symbols
(
"
omega, omega_f
"
)
omega
,
omega_f
=
sp
.
symbols
(
"
omega, omega_f
"
)
ls
=
[
32
*
2
**
i
for
i
in
range
(
0
,
5
)]
# NOTE: use those values to limit the runtime in integration tests
nus
=
[
1e-2
,
1e-3
,
1e-4
,
1e-5
]
ls
=
[
32
]
nus
=
[
1e-5
]
# NOTE: for simulating the real shear-wave scenario from Geier et al. use the following values
# ls = [32 * 2 ** i for i in range(0, 5)]
# nus = [1e-2, 1e-3, 1e-4, 1e-5]
srt_and_trt_methods
=
[
LBMConfig
(
method
=
method
,
srt_and_trt_methods
=
[
LBMConfig
(
method
=
method
,
stencil
=
LBStencil
(
stencil
),
stencil
=
LBStencil
(
stencil
),
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment