Commit graph

119 commits

Author SHA1 Message Date
Meta Vens
2cb5b588bc Docs: soa-world ABI 16, joint stress, body removal, removal facts
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 23:30:43 +01:00
Meta Vens
99d0d26656 Ymir SoA: removal facts and the retired shape table
BodyRemoved and JointRemoved facts are written by remove_body and destroy_joint into pending arrays and published by the next step in removal order. A removed body's shape goes into a retired table so the End touch facts it caused name its old lane and stable id; the c3 skip of invalid shapes is gone. C# spans Facts.BodiesRemoved and JointsRemoved.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 23:30:43 +01:00
Meta Vens
e1f1449927 Ymir SoA: remove_body, refused while named
Body kind REMOVED, body_generation/body_removed_at, body slot reuse (twin of the joint slot), free_body_slots, remove_body(lane, generation): refused whole while a live attachment or sensor names the body; else wet patches go (ymir_particles_release_body, no Box3D call), joints naming it retire, Box3D destroys it, the lane tombstones. Every per-body loop skips REMOVED; attach, sensors, add_joint and parent refuse a removed lane. Box3DSoaBodyHandle returned by every Add* body helper. A removed body's shape ends a touch only by skipping it here; the next commit names it.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 23:30:43 +01:00
Meta Vens
f2797fa0dd Ymir SoA: joint stress thresholds, constraint lanes and overload facts
Joint desc force_threshold/torque_threshold (+inf = never, NaN or negative refused, +inf handed to Box3D as FLT_MAX), set_joint_thresholds, joint lanes constraint_force/torque xyz (JOINT_FLOAT_LANES 15 -> 21), joint user data lane + 1, and overload facts drained from b3World_GetJointEvents after each step. A threshold is a sensor: nothing is removed on it.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 23:30:42 +01:00
Meta Vens
32578bd109 Ymir SoA: one joint owner for every kind, ABI 16
ymir_soa_retire_joint is the only b3DestroyJoint; destroy_joint takes any live joint kind with the slot's generation. The motor-only gate is gone. Lane state is the tombstone rule: kind REMOVED, bodies -1, every lane 0, generation + 1.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 23:30:42 +01:00
Meta Vens
da5ef233a5 Ymir: NO_PARTICLE_CONTACT phase bit keeps a particle out of the solid contact grid; the solid grid is sized by its members
Bodies and fluid still meet such a particle. The new bit extends YMIR_PHASE_VALID and is refused with FLUID; no ABI bump (lodur:ruling:ymir-new-flag-value-no-abi-bump).
grid_sort takes its mask as a parameter; build_grid sizes grid_mask from the member count; the fluid grid keeps the full table.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 23:15:37 +01:00
Meta Vens
0b87fbe37c Ymir test: skin sieve place bound set from the least claimed mutant, attachment compliance x10
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 21:57:16 +01:00
Meta Vens
32df139679 Ymir test: skin sieve asserts the load arrives, claims the body-contact mutant, and derives the place bound from the shipped noise
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 21:38:54 +01:00
Meta Vens
2e04ba94f5 Ymir test: a skin sheet attached along a bone holds under a fluid pour and a solid drop at 4 substeps
Skin_on_a_bone_holds_under_pour_and_drop: 30 skin particles on a welded capsule, 7x7x7 fluid or 4x4x4 solid load, 3 s at 4 substeps, 60 and 120 Hz.
Stretch bound 0.0346 (shipped 0.0214, Ma and Mc 0.0559), place bound 1.29e-3 (shipped zero reading, Ma and Mc 0.331), nothing inside the bone.
The corner-pinned sheet stays the documented loose-cloth limit (ruling ymir-sheet-sieve-at-budget-substeps). No native change.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 21:24:33 +01:00
Meta Vens
d82da6d1ff Liquid sensors read pooled liquid: sensor_wet_volume, the wet patches whose centre is inside, through the wet index; readings are end-of-step
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 08:24:09 +01:00
Meta Vens
335b66247d Sensor tests: a drop waits on even ticks only, so a wrong frame, radius or pose reads differently; cost line: four sensors over the 2000-drop pour, paired
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 07:43:14 +01:00
Meta Vens
881a209e9a Liquid sensors: spheres fixed in bodies read the liquid volume inside them each step (ABI 15)
create_sensors, remove(SENSOR), free_slots(SENSOR) and sensor lanes; ymir_particles_end writes sensor_liquid_volume before its no-live-particle return. A sensor moves nothing; a world with none steps byte for byte as ABI 14.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 07:41:18 +01:00
Meta Vens
1d2b9d9fdf Tighten DryBound to 2.1e-3 m (shipped 3.839e-5, least mutant 0.1128)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 06:40:28 +01:00
Meta Vens
97640b30b6 Wet friction fix tests: late and removed patches under a resting box, a reused lane, the lowest lane
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 06:38:34 +01:00
Meta Vens
89e401bc20 Wet lookup culled: patches indexed by body, box and centre x
wet_mu no longer scans every wet lane: rederive_wet builds the live body patches sorted by body
then centre x with each body's box and largest radius, so a point outside the body's box is a
constant check and a point inside binary-searches the x window; the lowest lane still wins.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 06:38:25 +01:00
Meta Vens
908a68782b Box3D fork: pin the hook on recycled contacts (ebe346a); re-pin the Wet hashes
The Wet world settles liquid under a box at rest; its recycled contact now takes the patch's
friction (lodur:ruling:wet-friction-on-recycled-contacts). Abi8, Pile and Fluid, which settle
nothing, are unmoved. The fork at 2a43fae reproduces the old Wet hashes.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 06:38:25 +01:00
Meta Vens
078f4b6456 Wet friction tests and docs: box on a wet floor, dry box beside a patch, rope on a wet slope, fluid and elsewhere-patch byte checks
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 06:04:16 +01:00
Meta Vens
23b28cf9e1 Wet friction: wet_mu in particle-body contact and the world's friction hook
Solid particles take the lowest live patch's wet friction under the point (and their own
particle_wet_mu); fluid particles keep their material mu. Body-body contact installs the
fork's per-contact hook, which only lowers the mixed friction. destroy re-derives the wet
lanes when a destroyed solid takes patches, so rederive_wet has three callers.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 06:02:16 +01:00
Meta Vens
c0dde04f01 Box3D fork: pin the contact friction hook (2a43fae)
No caller yet: a world steps as before.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 05:47:03 +01:00
Meta Vens
1212edd3ee Wet settle: claim the nearest-patch fallback, created-lane rollback, lowest-patch merge and remove(WET) topology rule; drop the dead rederive_wet in destroy
Fixes lodur:finding:cut-ymir-fluid-wet.s1 settle-fallback-unclaimed, settle-rollback-created-unclaimed, merge-lowest-patch-unclaimed, destroy-rederive-wet-dead, remove-wet-topology-claimable-by-cost.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 05:21:04 +01:00
Meta Vens
92e446a4f6 Settle binding: Settle, Wet patch lanes, WetVolume per body, wet friction; tests and docs
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 04:38:37 +01:00
Meta Vens
4ddcf7bc9c Settle: wet patch lanes, per-body wet volume, settle command and remove(WET), ABI 14 (native; binding layout only)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 04:26:03 +01:00
Meta Vens
0ccedf22dc Support lanes: destroy clears a drop's name for a destroyed solid; the destroy write, every well particle and all three sheet drops are asserted
Closes lodur:follow_up:ymir-fluid-support-s1-lows (findings destroy-clear-unclaimed, well-fluid-class-thin).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 04:16:34 +01:00
Meta Vens
888117dc5c Support lanes: what each fluid particle touched in the last substep
ABI 13. support_body (the highest body lane touched) and support_particle (the
first listed solid that touches) are cleared to -1 for each live fluid lane
after prediction and written by body_contacts and the fluid-solid contact pass;
create and destroy write -1. Resting on fluid alone reads -1 on both. The step
writes them and no pass reads them: the pins (Abi8, Pile, Fluid) do not move.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 03:50:07 +01:00
Meta Vens
c6365d4d85 Fluid cost line: paired medians, not one difference
Fluid_cost_line ran the scene without fluid once and each viscosity once, so its
increment moved 0.3 ms run to run. Each (n, viscosity) now runs nine interleaved
pairs (the order alternating) and prints the median increment and its
interquartile range. Printed, not asserted. No behaviour change.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 03:18:20 +01:00
Meta Vens
35b0b6d7f9 Fluid cost r2: mutant readings and bounds across twelve bucket orders, memory per lane in Fluid_cost_line, docs
Column mean bound 0.0907 (ruling ymir-column-mean-bound-order-noise): Md claims it; Mk is claimed by KERNEL_REACH (table of 512 buckets so a shared
bucket cannot hide the miss), Mf by floor penetration and through count, Mo by the overflow asserts; Mx and Mu unclaimed. Fluid_cost_line prints
bytes per lane. docs/soa-world.md: two sorts with fluid live, kernel cell, CSR lists under the fluid capacity, fluid-solid contact, cost readings.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 02:45:39 +01:00
Meta Vens
e71c731bd5 Particles: fluid capacity sizes a packed neighbour arena; the per-lane list carve is gone
ymir_particle_capacities and Box3DSoaParticleCapacities gain fluid (last, 0 default); the lists are CSR rows (nbr_start, nbr_count) in an arena of
fluid * 96 entries, 0 bytes without fluid; a batch of fluid past the capacity returns FULL before a lane is taken. No-fluid worlds carve 28 bytes
a lane instead of 388. Hashes unmoved.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 02:44:24 +01:00
Meta Vens
9d19d37c89 Particles: contact grid of the non-fluid lanes, fluid grid at the kernel cell with sorted copies, branchless candidates, fluid-solid contact on the lists
build_grid sorts the non-fluid lanes at 2 rmax; fluid_density rebuilds the tables over every live lane at 4 rfmax, copies position, inverse mass and
phase in sorted order, and walks each fluid row's deduplicated buckets with a branchless distance filter into a row buffer (128). Fluid-solid contact
is a count-and-move pass over the lists after pass B. FluidHashes re-pinned once here: sorted rows and kernel-cell bucket order and the moved contact
change every pair sum. ColumnMean re-derived over twelve bucket orders by lodur:ruling:ymir-column-mean-bound-order-noise (worst 0.0178, Md 0.4625, bound 0.0907).
Abi8Hashes and PileHashes unmoved.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 02:43:58 +01:00
Meta Vens
0fc389db7c Fluid_cost_line at viscosity 0 and 0.01; docs: one grid, rings, lists, overflow lane, XSPH note, cost readings
512 fluid still +3.0 to +3.4 ms against the 1.0 target; per-phase readings in the docs; per-tick lists and cell-sorted copies stay parked.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 02:09:39 +01:00
Meta Vens
f91450a97a ABI 12: fluid_neighbour_overflow in the view; column, floor and pour assert 0; Mr, Md, Mo readings
Mr (rings forced 1) claims KERNEL_REACH (0 vs 2.53e-3) and the floor (0.258); Md (fluid pairs from both rows) claims column mean (0.467 vs 0.0133), floor and the column max; Mo (capacity 8) overflows 597364 / 25823 / 28049 against 0. Existing bounds keep their values (midpoints would rise).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 02:08:13 +01:00
Meta Vens
9963da70b2 Particles: pass A walks its rings as nested loops
The flat offset loop paid three integer divisions per cell (125 cells at equal radii): pass A read 4.9 ms a tick at 512, 2.9 with the loops. Order and hashes unchanged.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 02:08:13 +01:00
Meta Vens
b95b218281 Particles: one grid at 2 rmax, fluid passes walk rings and keep bounded neighbour lists that pass B and XSPH read
build_grid's cell is 2 rmax always; fluid_rings = ceil(2 (rfmax + rmax) / 2 rmax) derives the kernel reach over it. Pass A walks
(2R+1)^3 cells and writes each fluid row's list (96 slots, overflow counted in fluid_overflow); pass B and XSPH read only the lists;
walk_half serves contacts only. Spec order (1) rings, (2) lists is one commit: rings without lists leave pass B blind to 4 r pairs.
FluidHashes re-pinned (pair order and accumulation change); Abi8Hashes and PileHashes unmoved.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 01:58:30 +01:00
Meta Vens
e94977fe0b Particles: emission and held-attachment pins, column max recorded unclaimed, docs; the dead held-attachment loop deleted
Particle_source_rules: create_particles names TOPO_ISOLATED and not TOPO_FULL, destroy_particles names both (M6a, create
runs FULL, now fails without timing); the substep gate regex follows the viscous-material gate. A lone solid particle with
a tether attachment makes no tether lane (0 before, 0 attached, 0 after destroy): destroy_particles' attachment term in
`held` is dead and goes, with 'or attachment' in its comment; the test pins the absence. Column max keeps 1.5 and is
recorded as claiming no mutant (Mc1 lambda halved 1.2116, Mc2 no self term 1.3340 against shipped 1.3440). docs/soa-world.md
Fluid bullet: inverse-mass lambda, XSPH skip, the held-floor claim; Not done: the sheet sieve at 4 substeps.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 01:42:38 +01:00
Meta Vens
7bb53119d7 Tests: the pour at the budget's 4 substeps as readings; Fluid_holds_on_a_solid_floor; FluidHashes re-pinned
Deletes PourSub = 10 and the pour's four count assertions (sheet >= 250, rope >= 30, below >= 300, deep == 0): they
claimed no mutant (finding pour-bounds-knife-edge). The pour now runs at Sub, prints the fluid reading, the same block
flagged solid as the control and the worst sheet edge stretch, and asserts nothing; the sheet sieves at 4 substeps
(question ymir-sheet-sieve-at-budget-substeps). The no-tunnelling claim moves to Fluid_holds_on_a_solid_floor
(penetration <= 0.233 claims Mt1 and Mt2, through <= 18 claims Mt1; finding pour-tunnels-below-10-substeps).
FluidHashes re-pinned at 4 substeps (formula and order changed); Release equals Debug. Abi8Hashes and PileHashes
are not touched.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 01:38:11 +01:00
Meta Vens
3af239e7da Particles: XSPH runs only when a material has viscosity, and walks fluid rows only
ymir_particles_substep gates fluid_viscosity on live_fluid > 0 and a viscous material (one scan of the material lanes a
substep); walk_half takes a required row phase bit and viscosity_pair's walk passes FLUID, so no solid row is walked.
The per-pair c == 0 early-out stays for mixed materials. Addresses finding fluid-cost-5x-target (Soul's probe: skipping
XSPH 4.7 -> 3.7 ms at 512). Shear ratio unchanged 0.7799; M5 and Mv read 1.0000. FluidHashes move with this and are
re-pinned in commit 3.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 01:33:16 +01:00
Meta Vens
217c640c4b Particles: XPBD inverse-mass weighted density lambda and pair split; momentum test gains 100:1 and asserts energy on every row
fluid_density pass A weights the denominator by inverse mass (w_i |sum grad|^2 + sum w_j |grad_j|^2, eps w_i; 0 when
the denominator is 0), pass B moves each end w * corr instead of 2 w/(wi+wj) * corr. Equal masses unchanged, a static
end takes nothing. Energy rise at 30:1 1.108 -> 1.000000 (M9 = the old split). Fixes findings energy-rise-narrowed.
MomentumBound 2.0e-3 and EnergyBound 1e-5 are kept (a re-derived midpoint would loosen both).
Fluid_world_is_byte_deterministic (FluidHashes) and the pour's counts change with the formula and are settled in
commit 3; Abi8Hashes and PileHashes are untouched.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 01:32:16 +01:00
Meta Vens
50f54582c8 Docs and the fluid cost line: soa-world.md Fluid bullet, tests and Not done; Fluid_cost_line prints 512 and 2000 fluid particles on the sheet scene
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 00:37:33 +01:00
Meta Vens
bb35465623 Particles: fluid as a phase bit: unilateral number-density PBF with solids in the estimate, momentum-exact pair split, XSPH
Poly6/Spiky kernels per pair h = 2 (ri + rj), n0 a create-time lattice constant, lambda gathered over the 27 cells, corrections scattered over the contact pass's half-walk (the walk is now shared) and split by inverse mass, XSPH after the velocity update. Grid cell 2 r_max with no live fluid (byte-identical), 2 (r_fmax + r_max) with. Binding: Box3DSoaPhase.Fluid, material viscosity, ParticleDensity and MaterialViscosity lanes, ABI 11 (the lanes are here because the fluid tests read them).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-25 00:37:33 +01:00
Meta Vens
db3fd95eba Particles: isolated-lane derivation for create and fluid destroy; FLUID phase bit refused by distances and attachments
rederive_topology takes a mode: ISOLATED writes the component lane of the lanes a command made or unmade and returns, FULL is the derivation. create_particles always isolates (a new particle holds no constraint); destroy_particles isolates unless a named particle held a live distance or attachment.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-24 23:59:21 +01:00
Meta Vens
cdf79b197d tests: every tether's parent is present on the 32x32 sheet pinned at 20 points (kills the no-parent-gate mutant)
The suite passed with the parent gate removed; the gate fires only in intermediate derivations of the 20-pin build (37 gated
particles over the 20 attaches, none at the end), so the invariant is checked after each attach.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-24 21:47:04 +01:00
Meta Vens
a28318ccbb tests, docs: restore the sheet (5 s, 5%) and attached-end (1e-4 m) bounds, momentum floor comment, islands in soa-world.md
h2's loosened bounds are reverted. Momentum stays at 5e-4 with the measured float32 reason. The corner-group sheet is read at 8 s
(it still rings at 5 s: 1.10% under at 5 s, within 0.2% from 6 s). Docs describe islands, the parent gate, geodesic bounds, the
pair rule and counts, and drop the nearest-only text.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-24 21:43:20 +01:00
Meta Vens
ca237bb0af particles: tether to the nearest point of each particle's two nearest islands (Kim 2012), no static-static pair tethers
Replaces the multi-source one-tether-per-particle derivation. A tether island is a maximal set of tether particles joined by
live distances; each non-tether particle is held to the nearest point of its two nearest islands by rest path, written per
island in lane order behind a parent gate (float ties at rank 2). A pair tether is derived only when a body is among its two
attachments (end_w is 0 at a static end). Tests: two-island derivation (rope, star, 9-rope) and the two-corner-group sheet
(read at 8 s: the sheet rings at 5 s). Pile hashes re-pinned: the pile's tether set changes with the rule; two runs agree.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-24 21:42:47 +01:00
Meta Vens
d95cde3047 docs: nearest-tether derivation, contact walk, bend limit readings at 4/8/32 substeps, TETHER at both ends for heavy holds, mass-ratio drift, test list
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-24 21:08:45 +01:00
Meta Vens
c2f905452c Particles: contact walks half the neighbourhood, one tether per particle to its nearest tether point, contact skips every attached body, large batches do not allocate; behaviour tests for gravity z, proxy rotation, flags, pair tether, refused attach, tie-break
Pair contact finds each pair once (own cell plus 13 forward cells) instead of from both ends: 1.91 -> 1.46 ms on 16 ropes x 48 (native, 4 substeps). Tethers: a multi-source Dijkstra gives each particle one tether to its nearest TETHER attachment (Kim 2012); a pair of tether points keeps its pair tether behind a route of booking lanes. The skip_body lane is gone: held_by scans the attachments on contact. Pile hashes re-pinned (tether lanes and contact sum order changed).
2026-11-24 21:05:56 +01:00
Meta Vens
d9a60f52c1 tests: readings, a filter test that fails without the filter, cost line with and without the sheet, a warmed allocation probe
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-24 20:26:04 +01:00
Meta Vens
f62dea38af docs: the particle graph contract, tests and not-done; name gamecult/step-normal-impulse for fb719c4
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-24 20:21:24 +01:00
Meta Vens
5de7e05814 Particles become a constraint graph: chain surface deleted, phased particle lanes and typed constraint lanes with derived tethers and hard-limit bends (ABI 10)
The chain lanes, chain commands and exports, PARTICLE_PARTICLE attachments, chain-order implicit constraints,
the per-particle contact average and the chain-order tension sweep are gone in the same commit as the graph
that replaces them: the module, its exports, its binding and its tests do not build apart.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-24 20:21:24 +01:00
Meta Vens
9ffc3cc21b docs: the in-substep coupling, the sensors and the fork's callback
Rewrite the particle section for r2: why a post-step correction fails, the substep order, the
sensor definitions, the new tests; drop the split-impulse paragraph and the Not-done lines on
tension, cancel/restore and two-attachment direction; the box3d pin is the substep-callback
commit.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-23 04:27:02 +01:00
Meta Vens
761e4c1568 SoA particle tests: the coupling's behaviour, sensors and release
Chain_holds_a_70kg_body is tightened (speed, stretch and impulse per tick over 1 s to 5 s);
Top_link_tension_reads_the_load runs at 1, 5, 20 and 70 kg; new tests pin momentum and apex
of a throw, the snap, the pendulum and spin, release in the step, the impulse lane equal to
what Box3D applied, friction on a slope, the tethers, the attached end and a world with no
awake body; the cost line prints a 1-body and a 40-body scene.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-23 04:22:17 +01:00
Meta Vens
66179d68b4 SoA particles r2: chains couple to bodies inside Box3D's substep
Delete the post-step coupling (carry, cancel/restore, hard_impulse, k_body and
end_force_scale, add_link_load and tension_diff, ymir_soa_apply_particle_impulses,
ymir_particles_step) and replace it with begin, substep and end. The substep runs in
Box3D's new substep callback (extern/box3d moves to the fork's substep-callback commit),
after the biased solve and before positions integrate: each proxy takes the body's pose
at the substep's start and its solved velocity, every correction is lambda / h^2 and
returns to the body as a velocity change there, and Box3D integrates the body to where
the constraint put it. Particle-body contacts run last in each substep. Link tension is
read by momentum balance from the structural impulses past each link.

The deletion and its replacement share one commit: the step cannot build without both.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-23 04:18:58 +01:00