Skip to content
Snippets Groups Projects
Commit bb6af879 authored by Alexandru Fikl's avatar Alexandru Fikl Committed by Andreas Klöckner
Browse files

flatten product in DerivativeBinder.map_product

parent b3d904b0
No related branches found
No related tags found
No related merge requests found
...@@ -324,11 +324,11 @@ class DerivativeBinder(IdentityMapper): ...@@ -324,11 +324,11 @@ class DerivativeBinder(IdentityMapper):
result = new_result result = new_result
from pymbolic.primitives import flattened_sum from pymbolic.primitives import flattened_product, flattened_sum
return flattened_sum([ return flattened_sum([
type(expr)(tuple([ flattened_product([
self.rec(prod_term) for prod_term in prod_term_list self.rec(prod_term) for prod_term in prod_term_list
])) ])
for prod_term_list in result for prod_term_list in result
]) ])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment