Skip to content

Commit

Permalink
For loop over list comprehension to assemble rhs
Browse files Browse the repository at this point in the history
  • Loading branch information
hkjeldsberg committed Nov 10, 2023
1 parent 43542d6 commit b60eb59
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/oasismove/NSfracStepMove.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,8 @@
mesh_velocity_solve(**vars())
t0.stop()

b0 = dict((ui, assemble(v * f[i] * dx)) for i, ui in enumerate(u_components))
for i, ui in enumerate(u_components):
b0[ui] = assemble(v * f[i] * dx)
A_cache.update_t(t)

while udiff[0] > max_error and inner_iter < num_iter and compute_velocity_and_pressure:
Expand Down

0 comments on commit b60eb59

Please sign in to comment.