Skip to content
Snippets Groups Projects

Corrected gallilean correction

Merged Markus Holzer requested to merge holzer/lbmpy:Cumulant into master
Viewing commit cfa6f059
Show latest version
1 file
+ 8
0
Preferences
Compare changes
@@ -25,6 +25,14 @@ def add_smagorinsky_model(collision_rule, smagorinsky_constant, omega_output_fie
tau_0 = sp.Symbol("tau_0_")
second_order_neq_moments = sp.Symbol("Pi")
rho = method.zeroth_order_equilibrium_moment_symbol if method.conserved_quantity_computation.compressible else 1
symbols = set()
for eq in collision_rule:
symbols.add(eq.lhs)
if sp.Symbol('rho') not in symbols and sp.Symbol('m_00') in symbols:
collision_rule.subexpressions += [Assignment(sp.Symbol('rho'), sp.Symbol('m_00'))]
adapted_omega = sp.Symbol("smagorinsky_omega")
collision_rule = collision_rule.new_with_substitutions({omega_s: adapted_omega})