diff --git a/lbmpy/methods/cumulantbased/cumulant_simplifications.py b/lbmpy/methods/cumulantbased/cumulant_simplifications.py index 9e9312a8fa1aea2718aada3c9daa4a73e3c7e87b..a0e0b2ad6ed5473d3401b1cb6d772f3cb5ee3bea 100644 --- a/lbmpy/methods/cumulantbased/cumulant_simplifications.py +++ b/lbmpy/methods/cumulantbased/cumulant_simplifications.py @@ -16,11 +16,8 @@ def insert_logs(ac, **kwargs): def insert_log_products(ac, **kwargs): def callback(asm): rhs = asm.rhs - if isinstance(rhs, sp.log): + if rhs.find(sp.log): return True - if isinstance(rhs, sp.Mul): - if any(isinstance(arg, sp.log) for arg in rhs.args): - return True return False return insert_subexpressions(ac, callback, **kwargs)