public class SegmentedPlanarCoupling extends RigidBodyCoupling
BILATERAL, LINEAR, ROTARY, useNewDerivatives| Constructor and Description | 
|---|
| SegmentedPlanarCoupling() | 
| SegmentedPlanarCoupling(double[] segs) | 
| Modifier and Type | Method and Description | 
|---|---|
| Plane | closestPlane(Point3d p)Returns the plane closest to a specified point in the D coordinate frame. | 
| void | getConstraintInfo(maspack.spatialmotion.RigidBodyCoupling.ConstraintInfo[] info,
                 RigidTransform3d TGD,
                 RigidTransform3d TCD,
                 RigidTransform3d XERR,
                 boolean setEngaged)Computes the constraint frame G and the associated constraint information. | 
| java.util.ArrayList<Plane> | getPlanes()Returns a list of the planes in frame D. | 
| java.util.ArrayList<Point3d> | getSegmentPoints()Returns a list of points describing the piecewise linear curve in the D
 frame x-z plane which defines the plane segments. | 
| void | initializeConstraintInfo(maspack.spatialmotion.RigidBodyCoupling.ConstraintInfo[] info) | 
| boolean | isUnilateral() | 
| int | maxUnilaterals()Returns the maximum number of unilateral constraints associated with this
 coupling. | 
| int | numBilaterals()Returns the number of bilateral constraints associated with this coupling. | 
| int | numPlanes()Returns the number of planar segments associated with this coupling. | 
| void | projectToConstraint(RigidTransform3d TGD,
                   RigidTransform3d TCD)Computes the frame G on the constraint surface which is closest to a given
 frame C. | 
| void | scaleDistance(double s) | 
| void | setSegments(double[] segs)Sets the plane segments associated with this SegmentedPlanarCoupling. | 
| void | setUnilateral(boolean unilateral) | 
| void | transformGeometry(GeometryTransformer gt,
                 RigidTransform3d TFW,
                 RigidTransform3d TDW)Transforms the geometry of this coupling, in response to an affine
 transform X applied in world coordinates. | 
findNearestAngle, getAuxState, getBilateralConstraints, getBilateralForceG, getBilateralImpulses, getBreakAccel, getBreakSpeed, getCompliance, getConstraint, getConstraintInfo, getContactDistance, getDamping, getInitialAuxState, getUnilateralConstraints, getUnilateralForceG, getUnilateralImpulses, maxConstraints, numUnilaterals, printConstraintInfo, setAuxState, setBilateralImpulses, setBreakAccel, setBreakSpeed, setCompliance, setContactDistance, setDamping, setDistanceAndZeroDerivative, setDistancesAndZeroDerivatives, setUnilateralImpulses, skipAuxState, updateBodyStates, updateConstraintsFromC, updateUnilateralConstraints, zeroImpulsespublic SegmentedPlanarCoupling()
public SegmentedPlanarCoupling(double[] segs)
public java.util.ArrayList<Point3d> getSegmentPoints()
public java.util.ArrayList<Plane> getPlanes()
public int numPlanes()
public void setUnilateral(boolean unilateral)
public boolean isUnilateral()
public void setSegments(double[] segs)
segs - x-z coordinate pairs defining the segmentspublic Plane closestPlane(Point3d p)
p - point to find nearest plane topublic int maxUnilaterals()
RigidBodyCouplingmaxUnilaterals in class RigidBodyCouplingpublic int numBilaterals()
RigidBodyCouplingnumBilaterals in class RigidBodyCouplingpublic void projectToConstraint(RigidTransform3d TGD, RigidTransform3d TCD)
RigidBodyCouplingprojectToConstraint in class RigidBodyCouplingTGD - returns the transform from G to DTCD - transform from frame C to Dpublic void initializeConstraintInfo(maspack.spatialmotion.RigidBodyCoupling.ConstraintInfo[] info)
initializeConstraintInfo in class RigidBodyCouplingpublic void getConstraintInfo(maspack.spatialmotion.RigidBodyCoupling.ConstraintInfo[] info,
                              RigidTransform3d TGD,
                              RigidTransform3d TCD,
                              RigidTransform3d XERR,
                              boolean setEngaged)
RigidBodyCoupling
 Information for each constraint wrench is returned through an array of
 ConstraintInfo objects supplied by the argument info. This
 array should have a fixed number of elements equal to the number of
 bilateral constraints plus the maximum number of unilateral constraints.
 Bilateral constraints appear first, followed by the unilateral
 constraints. Constraint wrenches and their derivatives (with respect to
 frame G) are set within the fields wrenchC and
 dotWrenchC, repsectively. Distances to set within the
 distance; each of these should be the dot product of the
 wrench with the linearization of the constraint error TCG. For computing
 wrench derivatives, this method may use myVelBA, which
 gives the current velocity of B with repsect to A, in coordinate frame D.
 
 Information only needs to be returned for constraints which are 
 potentially active, or engaged. Constraints which are
 engaged have their ConstraintInfo.engaged field set to a
 non-zero value. Bilateral constraints are always engaged, and
 their ConstraintInfo.engaged field is automatically 
 set to 1 by the system. For unilateral constraints, the determination
 of whether or not the constraint is engaged, and the setting of
 the engaged field, should be done
 by this method if the argument setEngaged is 
 true. Otherwise, if setEngaged is 
 false, the method should take the engaged settings as given.
 
 Constraints which are engaged are those which
 are returned by the calls getBilateralConstraints or getUnilateralConstraints.
getConstraintInfo in class RigidBodyCouplinginfo - used to return information for each possible constraint wrenchesTGD - returns the transform from G to DTCD - transform from operation frame C to DXERR - TODOsetEngaged - if true, this method should determine
 if the constraint is engaged.public void scaleDistance(double s)
scaleDistance in class RigidBodyCouplingpublic void transformGeometry(GeometryTransformer gt, RigidTransform3d TFW, RigidTransform3d TDW)
RigidBodyCouplingX.M = P RaGiven these arguments, a point p of the coupling defined with respect to frame D would transform according to
p' = TDW.R^T Ra^T X.M TDW.R pwhich is equivalent to transforming p to world coordinates (using TDW), applying X, and then transforming back to D using the modified TDW produced by applying X.
transformGeometry in class RigidBodyCouplinggt - transformer implementing the transformationTFW - current transform from C to worldTDW - current transform from D to world