Skip to content
Snippets Groups Projects
Commit 6e094b46 authored by Markus Holzer's avatar Markus Holzer
Browse files

Finished Casson model

parent 47accc55
No related branches found
No related tags found
1 merge request!118Cassons
Source diff could not be displayed: it is too large. Options to address this: view the blob.
......@@ -226,11 +226,10 @@ class LBMConfig:
set to Smagorinsky constant to activate turbulence model, ``omega_output_field`` can be set to
write out adapted relaxation rates. If set to `True`, 0.12 is used as default smagorinsky constant.
"""
cassons: Union[dict, bool] = False
cassons: CassonsParameters = False
"""
Adds the Cassons model according to https://doi.org/10.1007/s10955-005-8415-x
Set either to True, to obtain model with standard parameters or pass a dictionary containing
`yield_stress`, `omega_min` and `omega_max`
The parameters are set with the ``CassonsParameters`` dataclass.
"""
fluctuating: dict = False
"""
......@@ -656,11 +655,7 @@ def create_lb_collision_rule(lb_method=None, lbm_config=None, lbm_optimisation=N
collision_rule.simplification_hints['split_groups'][0].append(sp.Symbol("smagorinsky_omega"))
elif lbm_config.cassons:
if isinstance(lbm_config.cassons, CassonsParameters):
parameters = lbm_config.cassons
else:
parameters = CassonsParameters()
collision_rule = add_cassons_model(collision_rule, parameter=parameters,
collision_rule = add_cassons_model(collision_rule, parameter=lbm_config.cassons,
omega_output_field=lbm_config.omega_output_field)
if lbm_config.output:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment