Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Markus Holzer
lbmpy
Commits
a73d91e4
Commit
a73d91e4
authored
Aug 15, 2021
by
Markus Holzer
Browse files
Fix implizit force model
parent
fa8a9939
Pipeline
#33746
failed with stages
in 15 minutes and 38 seconds
Changes
3
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
lbmpy/methods/centeredcumulant/force_model.py
View file @
a73d91e4
from
lbmpy.forcemodels
import
AbstractForceModel
from
lbmpy.forcemodels
import
AbstractForceModel
,
default_velocity_shift
# =========================== Centered Cumulant Force Model ==========================================================
...
...
@@ -22,3 +22,6 @@ class CenteredCumulantForceModel(AbstractForceModel):
def
__call__
(
self
,
lb_method
):
raise
Exception
(
'This force model does not provide a forcing term.'
)
def
equilibrium_velocity_shift
(
self
,
density
):
return
default_velocity_shift
(
density
,
self
.
symbolic_force_vector
)
lbmpy/methods/momentbased/entropic_eq_srt.py
View file @
a73d91e4
...
...
@@ -10,6 +10,7 @@ class EntropicEquilibriumSRT(AbstractLbMethod):
"""Equilibrium from 'Minimal entropic kinetic models for hydrodynamics'
Ansumali, S. ; Karlin, I. V; Öttinger, H. C, (2003)
"""
def
__init__
(
self
,
stencil
,
relaxation_rate
,
force_model
,
conserved_quantity_calculation
):
super
(
EntropicEquilibriumSRT
,
self
).
__init__
(
stencil
)
...
...
@@ -91,7 +92,4 @@ def create_srt_entropic(stencil, relaxation_rate, force_model, compressible):
raise
NotImplementedError
(
"entropic-srt only implemented for compressible models"
)
density_velocity_computation
=
DensityVelocityComputation
(
stencil
,
compressible
,
force_model
)
return
EntropicEquilibriumSRT
(
stencil
,
relaxation_rate
,
force_model
,
density_velocity_computation
)
lbmpy_tests/centeredcumulant/test_periodic_pipe_flow.ipynb
View file @
a73d91e4
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment