Particle-Body Attachments#
A particle-body attachment ties one cloth or solid particle to a point in a
rigid body’s local frame. Author attachments with
newton.ModelBuilder.add_attachment_particle_body(). They are stored on the
Model and do not require a coupled solver.
SolverVBD applies an attachment whenever it integrates
both endpoints. It solves every attachment as a compliant augmented-Lagrangian
(ALM) row, with the same formulation as the VBD joint rows: a reaction
multiplier carries the attachment force, and a numerical penalty chosen from the
endpoint masses and the particle’s surrounding material helps the iterations
converge. The penalty is chosen like the joint limit rows, so a finite
attachment reaches its spring over several iterations. The penalty affects convergence only, not physical compliance.
A finite stiffness [N/m] converges to a spring with damping [N·s/m], so a
loaded attachment keeps a physical offset. Set stiffness=math.inf to request
a hard point constraint; damping is ignored for hard attachments. Multipliers are
retained across steps, scaled by rigid_avbd_gamma. A finite iteration budget
can leave constraint error, especially for heavy free bodies at large time steps;
more iterations or smaller steps reduce it. Incompatible hard attachments cannot
all be satisfied. Separated initial anchors can cause large correction impulses.
The constraint is translational, similar to the positional part of a ball joint;
a single particle has no orientation, so there is no angular counterpart. Forces
are equal and opposite, including the torque about the body’s center of mass, and
the path is independent of contact, so it stays active without penetration.
Both endpoints must be integrated by the same solver, so
SolverVBD rejects attachments when it is constructed
with integrate_with_external_rigid_solver=True.
When the endpoints of a finite-stiffness attachment belong to two different solvers in a coupled simulation,
SolverCoupledADMM turns the same
model rows into cross-solver interface constraints; see ADMM Coupling.
The two cases are mutually exclusive, so no attachment is applied twice, and a
row whose body or particle is owned by no solver applies no force at all. The
coupler also warns when both endpoints belong to one entry whose solver does not
support attachments. Hard attachments require both endpoints in one VBD entry;
the coupler raises an error for other ownership arrangements.