Commit 24239a5f authored by itischler's avatar itischler
Browse files

fixed getter issue of the second momentum

parent 1b59eef1
Pipeline #33244 failed with stages
in 11 minutes and 56 seconds
......@@ -227,9 +227,12 @@ class DensityVelocityComputation(AbstractConservedQuantityComputation):
main_assignments.extend([Assignment(lhs, sum(d[i] * pdf for d, pdf in zip(self._stencil, pdfs)))
for i, lhs in enumerate(moment1_output_symbol)])
if 'moment2' in output_quantity_names_to_symbols:
for p_i in self._symbolsOrder2:
main_assignments.append(Assignment(p_i, eqs[p_i]))
del eqs[p_i]
moment2_output_symbol = output_quantity_names_to_symbols['moment2']
if isinstance(moment2_output_symbol, Field):
moment2_output_symbol = moment2_output_symbol.center_vector
for i, p in enumerate(moment2_output_symbol):
main_assignments.append(Assignment(p, eqs[self._symbolsOrder2[i]]))
del eqs[self._symbolsOrder2[i]]
ac = ac.copy(main_assignments, [Assignment(a, b) for a, b in eqs.items()])
return ac.new_without_unused_subexpressions()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment