Skip to content

Commit

Permalink
[physics] Fix MacCormack advection
Browse files Browse the repository at this point in the history
  • Loading branch information
holl- committed Nov 25, 2024
1 parent d7f7c82 commit e0c0b7d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion phi/physics/advect.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ def mac_cormack(field: Field,
Returns:
Advected field of type `type(field)`
"""
v0 = resample(velocity, to=field).values
v0 = sample(velocity, field.geometry, at=field.sampled_at, boundary=field.boundary)
points_bwd = integrator(field, velocity, -dt, v0=v0)
points_fwd = integrator(field, velocity, dt, v0=v0)
# --- forward+backward semi-Lagrangian advection ---
Expand Down

0 comments on commit e0c0b7d

Please sign in to comment.