gpt4 book ai didi

us.ihmc.robotics.screwTheory.Wrench.getLinearPartX()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-26 06:19:05 27 4
gpt4 key购买 nike

本文整理了Java中us.ihmc.robotics.screwTheory.Wrench.getLinearPartX()方法的一些代码示例,展示了Wrench.getLinearPartX()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Wrench.getLinearPartX()方法的具体详情如下:
包路径:us.ihmc.robotics.screwTheory.Wrench
类名称:Wrench
方法名:getLinearPartX

Wrench.getLinearPartX介绍

暂无

代码示例

代码示例来源:origin: us.ihmc/IHMCRoboticsToolkit

@Override
public void getTauMatrix(DenseMatrix64F matrix)
{
 matrix.set(0, 0, successorWrench.getAngularPartY());
 matrix.set(1, 0, successorWrench.getLinearPartX());
 matrix.set(2, 0, successorWrench.getLinearPartZ());
}

代码示例来源:origin: us.ihmc/IHMCRoboticsToolkit

public void getWrench(Wrench wrenchToPack)
{
 wrenchToPack.setToZero(successorWrench.getBodyFrame(), successorWrench.getExpressedInFrame());
 wrenchToPack.setAngularPartY(successorWrench.getAngularPartY());
 wrenchToPack.setLinearPartX(successorWrench.getLinearPartX());
 wrenchToPack.setLinearPartZ(successorWrench.getLinearPartZ());
}

代码示例来源:origin: us.ihmc/IHMCRoboticsToolkit

protected void getYoValuesFromWrench()
{
 linearPart.set(wrench.getExpressedInFrame(), wrench.getLinearPartX(), wrench.getLinearPartY(), wrench.getLinearPartZ());
 angularPart.set(wrench.getExpressedInFrame(), wrench.getAngularPartX(), wrench.getAngularPartY(), wrench.getAngularPartZ());
}

代码示例来源:origin: us.ihmc/SensorProcessing

public void update(Wrench sensorWrench)
{
 sensorWrench.changeFrame(world);
 yoSensorForce.set(sensorWrench.getExpressedInFrame(), sensorWrench.getLinearPartX(), sensorWrench.getLinearPartY(), sensorWrench.getLinearPartZ());
 yoSensorTorque.set(sensorWrench.getExpressedInFrame(), sensorWrench.getAngularPartX(), sensorWrench.getAngularPartY(), sensorWrench.getAngularPartZ());
 if (addSimulatedSensorNoise.getBooleanValue())
 {
   double amp = 0.1;
   double bias = 0.25;
      yoSensorForce.add(amp*2.0*(Math.random()-0.5)+bias, amp*2.0*(Math.random()-0.5)+bias, amp*2.0*(Math.random()-0.5)+bias);
   yoSensorTorque.add(amp*2.0*(Math.random()-0.5)+bias, amp*2.0*(Math.random()-0.5)+bias, amp*2.0*(Math.random()-0.5)+bias);
 }
 
 updateSensorPosition();
 updateCenterOfMass();
 yoSensorToDistalCoMvectorInWorld.sub(distalCoMInWorld, yoSensorPositionInWorld);
 distalMassWrench.setToZero(world);
 distalMassWrench.setUsingArm(world, distalMassForceInWorld.getFrameTuple().getVector(), yoSensorToDistalCoMvectorInWorld.getFrameTuple().getVector());
 yoSensorForceFromDistalMass.set(distalMassWrench.getExpressedInFrame(), distalMassWrench.getLinearPartX(), distalMassWrench.getLinearPartY(), distalMassWrench.getLinearPartZ());
 yoSensorTorqueFromDistalMass.set(distalMassWrench.getExpressedInFrame(), distalMassWrench.getAngularPartX(), distalMassWrench.getAngularPartY(), distalMassWrench.getAngularPartZ());
 yoSensorForceMassCompensated.sub(yoSensorForce, yoSensorForceFromDistalMass);
 yoSensorTorqueMassCompensated.sub(yoSensorTorque, yoSensorTorqueFromDistalMass);
}

代码示例来源:origin: us.ihmc/IHMCRoboticsToolkit

public void setWrench(Wrench jointWrench)
{
 successorWrench.getBodyFrame().checkReferenceFrameMatch(jointWrench.getBodyFrame());
 successorWrench.getExpressedInFrame().checkReferenceFrameMatch(jointWrench.getExpressedInFrame());
 successorWrench.setAngularPartY(jointWrench.getAngularPartY());
 successorWrench.setLinearPartX(jointWrench.getLinearPartX());
 successorWrench.setLinearPartZ(jointWrench.getLinearPartZ());
}

代码示例来源:origin: us.ihmc/IHMCRoboticsToolkit

@Override
public void setTorqueFromWrench(Wrench jointWrench)
{
 jointWrench.getBodyFrame().checkReferenceFrameMatch(successor.getBodyFixedFrame());
 jointWrench.setToZero(successor.getBodyFixedFrame(), successorWrench.getExpressedInFrame());
 jointWrench.setAngularPartY(successorWrench.getAngularPartY());
 jointWrench.setLinearPartX(successorWrench.getLinearPartX());
 jointWrench.setLinearPartZ(successorWrench.getLinearPartZ());
 jointWrench.changeFrame(successor.getBodyFixedFrame());
}

代码示例来源:origin: us.ihmc/CommonWalkingControlModules

public void control(SpatialAccelerationVector handSpatialAccelerationVector, Wrench toolWrench)
{
 if (!hasBeenInitialized)
 {
   update();
   initialize();
 }
 update();
 toolAcceleration.set(handSpatialAccelerationVector);
 toolAcceleration.changeFrameNoRelativeMotion(toolJoint.getFrameAfterJoint());
 // TODO: Take relative acceleration between uTorsoCoM and elevator in account
 toolAcceleration.changeBaseFrameNoRelativeAcceleration(elevatorFrame);
 toolAcceleration.changeBodyFrameNoRelativeAcceleration(toolJoint.getFrameAfterJoint());
 toolJoint.setDesiredAcceleration(toolAcceleration);
 inverseDynamicsCalculator.compute();
 inverseDynamicsCalculator.getJointWrench(toolJoint, toolWrench);
 toolWrench.negate();
 toolWrench.changeFrame(handFixedFrame);
 toolWrench.changeBodyFrameAttachedToSameBody(handFixedFrame);
 // Visualization
 temporaryVector.setIncludingFrame(handFixedFrame, toolWrench.getLinearPartX(), toolWrench.getLinearPartY(), toolWrench.getLinearPartZ());
 temporaryVector.changeFrame(ReferenceFrame.getWorldFrame());
 temporaryVector.scale(0.01);
 objectForceInWorld.set(temporaryVector);
}

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com