Validate physical fine_cfg before surface_link_velocity
The blocked actuated path called the helper with an unvalidated fine config (nq=0), so receiver*nq+dir collapsed distinct writers and the unique-writer guard fired. Validate after wall-aware sanitization, as the dense path does before assign_surface; the test's fine_cfg helper too. Unique-writer guard unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
1a274817cd
commit
5c37d75dc4
@@ -134,6 +134,7 @@ class FixedPatchStepper:
|
||||
b = self.fine_boundary
|
||||
self._actuated = any(obj.surface_actuation is not None for obj in b.objects)
|
||||
if self._actuated:
|
||||
fine_cfg.validate() # derives nq etc.; the unique-writer key needs them
|
||||
fluid_idx, dirs, _, body_id, rx, ry, _, _ = b.curved_host
|
||||
self._fine_tables["surface_velocity"], _ = surface_link_velocity(
|
||||
b.objects, fine_cfg, b.flags, fluid_idx, dirs, body_id, rx, ry)
|
||||
|
||||
@@ -74,6 +74,7 @@ def fine_cfg(mode, patch):
|
||||
if mode == "slot_reservoir":
|
||||
cfg = replace(cfg, y_wall_bc="bounce_back", top_wall_bc="velocity",
|
||||
wall_slot_width=0, wall_normal_velocity=0.0, velocity=0.0)
|
||||
cfg.validate() # as the stepper does before surface_link_velocity
|
||||
return cfg
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user