public void reset(int solutionSize) { solution.reshape(solutionSize, 1); converged = false; iterations = 0; activeSet.clear(); }
public void reset(int solutionSize) { solution.reshape(solutionSize, 1); converged = false; iterations = 0; activeSet.clear(); }
private void computeJacobianTransposed(DenseMatrix64F jacobianTransposedToPack, DenseMatrix64F jacobian) { jacobianTransposedToPack.reshape(numberOfDoF, numberOfConstraints); CommonOps.transpose(jacobian, jacobianTransposedToPack); }
private void computeSubspaceSpatialVelocity(DenseMatrix64F subspaceSpatialVelocityToPack, DenseMatrix64F spatialVelocity) { subspaceSpatialVelocityToPack.reshape(numberOfConstraints, 1); CommonOps.mult(selectionMatrix, spatialVelocity, subspaceSpatialVelocityToPack); }
@Override public DenseMatrix64F newInstance() { DenseMatrix64F denseMatrix64F = new DenseMatrix64F(1); denseMatrix64F.reshape(0, 0); return denseMatrix64F; } };
public void setSelectionMatrixForFullConstraint() { numberOfConstraints = maximumNumberOfConstraints; this.selectionMatrix.reshape(numberOfConstraints, numberOfConstraints); CommonOps.setIdentity(selectionMatrix); }
private void computeJacobianTransposed(DenseMatrix64F jacobianTransposedToPack, DenseMatrix64F jacobian) { jacobianTransposedToPack.reshape(numberOfDoF, numberOfConstraints); CommonOps.transpose(jacobian, jacobianTransposedToPack); }
/** * Returns the algebraic error vector. error = A*U*x. length = number * of observations */ public void computeErrorVector( DenseMatrix64F A , DenseMatrix64F errors ) { errors.reshape(A.numRows,1); CommonOps.mult(A,vectorT,errors); }
public void setSelectionMatrixForFullConstraint() { numberOfConstraints = maximumNumberOfConstraints; this.selectionMatrix.reshape(numberOfConstraints, numberOfConstraints); CommonOps.setIdentity(selectionMatrix); }
private void computeJacobianTimesJacobianTransposed(DenseMatrix64F resultToPack, DenseMatrix64F jacobian) { resultToPack.reshape(numberOfConstraints, numberOfConstraints); CommonOps.multOuter(jacobian, resultToPack); }
@Override public boolean setA(DenseMatrix64F A) { if( !super.setA(A)) return false; Q.reshape(A.numRows, A.numRows); decomposition.getQ(Q, false); return true; }
public DenseMatrix64F constrainResult(DenseMatrix64F xBar) { x.reshape(xBar.getNumRows(), 1); CommonOps.mult(q, xBar, x); CommonOps.addEquals(x, jPlusp); return x; }
public void setSelectionMatrix(DenseMatrix64F selectionMatrix) { numberOfConstraints = selectionMatrix.getNumRows(); this.selectionMatrix.reshape(numberOfConstraints, selectionMatrix.getNumCols()); this.selectionMatrix.set(selectionMatrix); }
public SimpleMovingAverageFilteredYoVariable(String name, int windowSize, DoubleYoVariable yoVariableToFilter, YoVariableRegistry registry) { super(name, registry); this.yoVariableToFilter = yoVariableToFilter; this.windowSize = new IntegerYoVariable(name + "WindowSize", registry); this.windowSize.set(windowSize); previousUpdateValues.reshape(windowSize, 1); CommonOps.fill(previousUpdateValues, 0.0); }
public void getAndReshape(DenseMatrix64F matrixToPack) { matrixToPack.reshape(getNumberOfRows(), getNumberOfColumns()); get(matrixToPack); }
public void getAndReshape(DenseMatrix64F matrixToPack) { matrixToPack.reshape(getNumberOfRows(), getNumberOfColumns()); get(matrixToPack); }
@Override public boolean decompose(DenseMatrix64F orig) { if( alg.inputModified() ) { work.reshape(orig.numRows,orig.numCols); work.set(orig); return alg.decompose(work); } else { return alg.decompose(orig); } }
private static void getPositionLine(double t, DenseMatrix64F lineToPack) { lineToPack.reshape(1, coefficients); lineToPack.set(0, 3, 1.0); double tpow = t; lineToPack.set(0, 2, tpow); tpow *= t; lineToPack.set(0, 1, tpow); tpow *= t; lineToPack.set(0, 0, tpow); }
public void compute() { dynamicallyConsistentNullspaceCalculator.compute(); centerOfMassJacobian.reset(); DenseMatrix64F centerOfMassJacobianMatrix = centerOfMassJacobian.getJacobianMatrix(); DenseMatrix64F sNsBar = dynamicallyConsistentNullspaceCalculator.getSNsBar(); constrainedCenterOfMassJacobian.reshape(centerOfMassJacobianMatrix.getNumRows(), sNsBar.getNumCols()); CommonOps.mult(centerOfMassJacobianMatrix, sNsBar, constrainedCenterOfMassJacobian); }
public void queueQuaternion(Quaternion quaternion) { quaternions.reshape(quaternions.getNumRows() + 1, 4, true); int lastIndex = quaternions.getNumRows() - 1; quaternions.set(lastIndex, 0, quaternion.getX()); quaternions.set(lastIndex, 1, quaternion.getY()); quaternions.set(lastIndex, 2, quaternion.getZ()); quaternions.set(lastIndex, 3, quaternion.getS()); }