#include <VectorOperations.h>
Protected Attributes | |
VisitorExecuteFunc | executeVisitor |
SReal | result |
Result of latest v_dot operation. More... | |
Protected Attributes inherited from sofa::core::behavior::BaseVectorOperations | |
const core::ExecParams * | params |
core::objectmodel::BaseContext * | ctx |
SReal | result |
Public Member Functions | |
VectorOperations (const sofa::core::ExecParams *params, sofa::core::objectmodel::BaseContext *ctx, bool precomputedTraversalOrder=false) | |
void | v_alloc (sofa::core::MultiVecCoordId &v, const core::VecIdProperties &properties={}) override |
Allocate a temporary vector. More... | |
void | v_alloc (sofa::core::MultiVecDerivId &v, const core::VecIdProperties &properties={}) override |
void | v_free (sofa::core::MultiVecCoordId &id, bool interactionForceField=false, bool propagate=false) override |
Free a previously allocated temporary vector. More... | |
void | v_free (sofa::core::MultiVecDerivId &id, bool interactionForceField=false, bool propagate=false) override |
void | v_realloc (sofa::core::MultiVecCoordId &id, bool interactionForceField=false, bool propagate=false, const core::VecIdProperties &properties={}) override |
keep already allocated vectors and allocates others. If interactionForceField, also allocates mechanical states linked by an InteractionForceField More... | |
void | v_realloc (sofa::core::MultiVecDerivId &id, bool interactionForceField=false, bool propagate=false, const core::VecIdProperties &properties={}) override |
void | v_clear (core::MultiVecId v) override |
v=0 More... | |
void | v_eq (core::MultiVecId v, core::ConstMultiVecId a) override |
v=a More... | |
void | v_eq (core::MultiVecId v, core::ConstMultiVecId a, SReal f) override |
v=f*a More... | |
void | v_peq (core::MultiVecId v, core::ConstMultiVecId a, SReal f=1.0) override |
v+=f*a More... | |
void | v_teq (core::MultiVecId v, SReal f) override |
v*=f More... | |
void | v_op (core::MultiVecId v, core::ConstMultiVecId a, core::ConstMultiVecId b, SReal f=1.0) override |
v=a+b*f More... | |
void | v_multiop (const core::behavior::BaseMechanicalState::VMultiOp &o) override |
void | v_dot (core::ConstMultiVecId a, core::ConstMultiVecId b) override |
a dot b ( get result using finish ) More... | |
void | v_norm (core::ConstMultiVecId a, unsigned l) override |
Compute the norm of a vector ( get result using finish ). The type of norm is set by parameter l. Use 0 for the infinite norm. Note that the 2-norm is more efficiently computed using the square root of the dot product. More... | |
void | v_threshold (core::MultiVecId a, SReal threshold) override |
nullify the values below the given threshold More... | |
SReal | finish () override |
void | print (sofa::core::ConstMultiVecId v, std::ostream &out, std::string prefix="", std::string suffix="") override |
size_t | v_size (core::MultiVecId v) override |
Public Member Functions inherited from sofa::core::behavior::BaseVectorOperations | |
BaseVectorOperations (const core::ExecParams *params, core::objectmodel::BaseContext *ctx) | |
virtual | ~BaseVectorOperations () |
|
protected |
|
protected |
Result of latest v_dot operation.
sofa::simulation::common::VectorOperations::VectorOperations | ( | const sofa::core::ExecParams * | params, |
sofa::core::objectmodel::BaseContext * | ctx, | ||
bool | precomputedTraversalOrder = false |
||
) |
|
overridevirtual |
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Allocate a temporary vector.
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
v=0
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
a dot b ( get result using finish )
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
v=a
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
v=f*a
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Free a previously allocated temporary vector.
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Compute the norm of a vector ( get result using finish ). The type of norm is set by parameter l. Use 0 for the infinite norm. Note that the 2-norm is more efficiently computed using the square root of the dot product.
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
v=a+b*f
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
v+=f*a
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
keep already allocated vectors and allocates others. If interactionForceField, also allocates mechanical states linked by an InteractionForceField
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
v*=f
Implements sofa::core::behavior::BaseVectorOperations.
|
overridevirtual |
nullify the values below the given threshold
Implements sofa::core::behavior::BaseVectorOperations.