MBDyn-1.7.3
|
#include <motor.h>
Classes | |
struct | PrivData |
Public Member Functions | |
Motor (unsigned int uL, const DofOwner *pD, const StructNode *pN1, const StructNode *pN2, const ElectricNode *pV1, const ElectricNode *pV2, const Mat3x3 &Rn, doublereal dG, doublereal dl, DriveCaller *dR, doublereal i0, integer p, const DriveCaller *pM0, const DriveCaller *pM1, flag fOut) | |
virtual | ~Motor (void) |
virtual Electric::Type | GetElectricType (void) const |
virtual unsigned int | iGetNumPrivData (void) const |
virtual unsigned int | iGetPrivDataIdx (const char *s) const |
virtual doublereal | dGetPrivData (unsigned int i) const |
virtual std::ostream & | Restart (std::ostream &out) const |
virtual unsigned int | iGetNumDof (void) const |
virtual DofOrder::Order | GetDofType (unsigned int i) const |
virtual void | WorkSpaceDim (integer *piNumRows, integer *piNumCols) const |
VariableSubMatrixHandler & | AssJac (VariableSubMatrixHandler &WorkMat, doublereal dCoef, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr) |
SubVectorHandler & | AssRes (SubVectorHandler &WorkVec, doublereal dCoef, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr) |
virtual void | SetInitialValue (VectorHandler &X) |
virtual void | SetValue (DataManager *pDM, VectorHandler &X, VectorHandler &XP, SimulationEntity::Hints *h=0) |
virtual void | GetConnectedNodes (std::vector< const Node * > &connectedNodes) const |
Public Member Functions inherited from Elem | |
Elem (unsigned int uL, flag fOut) | |
virtual | ~Elem (void) |
virtual std::ostream & | DescribeDof (std::ostream &out, const char *prefix="", bool bInitial=false) const |
virtual void | DescribeDof (std::vector< std::string > &desc, bool bInitial=false, int i=-1) const |
virtual std::ostream & | DescribeEq (std::ostream &out, const char *prefix="", bool bInitial=false) const |
virtual void | DescribeEq (std::vector< std::string > &desc, bool bInitial=false, int i=-1) const |
virtual void | AssMats (VariableSubMatrixHandler &WorkMatA, VariableSubMatrixHandler &WorkMatB, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr) |
virtual bool | bInverseDynamics (void) const |
void | SetInverseDynamicsFlags (unsigned uIDF) |
unsigned | GetInverseDynamicsFlags (void) const |
bool | bIsErgonomy (void) const |
bool | bIsRightHandSide (void) const |
virtual VariableSubMatrixHandler & | AssJac (VariableSubMatrixHandler &WorkMat, const VectorHandler &XCurr) |
virtual SubVectorHandler & | AssRes (SubVectorHandler &WorkVec, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr, const VectorHandler &XPrimePrimeCurr, InverseDynamics::Order iOrder=InverseDynamics::INVERSE_DYNAMICS) |
virtual int | GetNumConnectedNodes (void) const |
Public Member Functions inherited from WithLabel | |
WithLabel (unsigned int uL=0, const std::string &sN="") | |
virtual | ~WithLabel (void) |
void | PutLabel (unsigned int uL) |
void | PutName (const std::string &sN) |
unsigned int | GetLabel (void) const |
const std::string & | GetName (void) const |
Public Member Functions inherited from SimulationEntity | |
SimulationEntity (void) | |
virtual | ~SimulationEntity (void) |
virtual bool | bIsValidIndex (unsigned int i) const |
virtual DofOrder::Order | GetEqType (unsigned int i) const |
virtual Hint * | ParseHint (DataManager *pDM, const char *s) const |
virtual void | BeforePredict (VectorHandler &, VectorHandler &, VectorHandler &, VectorHandler &) const |
virtual void | AfterPredict (VectorHandler &X, VectorHandler &XP) |
virtual void | Update (const VectorHandler &XCurr, const VectorHandler &XPrimeCurr) |
virtual void | DerivativesUpdate (const VectorHandler &XCurr, const VectorHandler &XPrimeCurr) |
virtual void | Update (const VectorHandler &XCurr, InverseDynamics::Order iOrder) |
virtual void | AfterConvergence (const VectorHandler &X, const VectorHandler &XP) |
virtual void | AfterConvergence (const VectorHandler &X, const VectorHandler &XP, const VectorHandler &XPP) |
virtual std::ostream & | OutputAppend (std::ostream &out) const |
virtual void | ReadInitialState (MBDynParser &HP) |
Public Member Functions inherited from ToBeOutput | |
ToBeOutput (flag fOut=fDefaultOut) | |
virtual | ~ToBeOutput (void) |
virtual void | OutputPrepare (OutputHandler &OH) |
virtual void | Output (OutputHandler &OH) const |
virtual void | Output (OutputHandler &OH, const VectorHandler &X, const VectorHandler &XP) const |
virtual flag | fToBeOutput (void) const |
virtual bool | bToBeOutput (void) const |
virtual void | SetOutputFlag (flag f=flag(1)) |
Public Member Functions inherited from Electric | |
Electric (unsigned int uL, const DofOwner *pDO, flag fOut) | |
virtual | ~Electric (void) |
virtual Elem::Type | GetElemType (void) const |
Public Member Functions inherited from ElemWithDofs | |
ElemWithDofs (unsigned int uL, const DofOwner *pDO, flag fOut) | |
virtual | ~ElemWithDofs (void) |
Public Member Functions inherited from DofOwnerOwner | |
DofOwnerOwner (const DofOwner *pDO) | |
virtual | ~DofOwnerOwner () |
virtual const DofOwner * | pGetDofOwner (void) const |
virtual integer | iGetFirstIndex (void) const |
Private Member Functions | |
doublereal | dGetOmega () const |
doublereal | dGetVoltage () const |
doublereal | dGetOmega (const Vec3 &n) const |
Vec3 | GetAxisOfRotation () const |
doublereal | dGetPhiMechanical () const |
doublereal | dGetPhiElectric (doublereal Phi_m) const |
Private Attributes | |
const StructNode * | pStrNode1 |
const StructNode * | pStrNode2 |
const ElectricNode * | pVoltage1 |
const ElectricNode * | pVoltage2 |
Mat3x3 | Rn |
doublereal | dGain |
doublereal | dL |
DriveOwner | dR |
integer | p |
DriveOwner | M0 |
DriveOwner | M1 |
doublereal | M |
doublereal | i |
doublereal | iP |
doublereal | Phi_m |
doublereal | Phi_e |
Static Private Attributes | |
static const int | iNumPrivData = 12 |
static const struct Motor::PrivData | rgPrivData [iNumPrivData] |
Additional Inherited Members | |
Public Types inherited from Elem | |
enum | Type { UNKNOWN = -1, AIRPROPERTIES = 0, INDUCEDVELOCITY, AUTOMATICSTRUCTURAL, GRAVITY, BODY, JOINT, JOINT_REGULARIZATION, BEAM, PLATE, FORCE, INERTIA, ELECTRICBULK, ELECTRIC, THERMAL, HYDRAULIC, BULK, LOADABLE, DRIVEN, EXTERNAL, AEROMODAL, AERODYNAMIC, GENEL, SOCKETSTREAM_OUTPUT, RTAI_OUTPUT = SOCKETSTREAM_OUTPUT, LASTELEMTYPE } |
Public Types inherited from SimulationEntity | |
typedef std::vector< Hint * > | Hints |
Public Types inherited from ToBeOutput | |
enum | { OUTPUT = 0x1U, OUTPUT_MASK = 0xFU, OUTPUT_PRIVATE = 0x10U, OUTPUT_PRIVATE_MASK = ~OUTPUT_MASK } |
Public Types inherited from Electric | |
enum | Type { UNKNOWN = -1, ACCELEROMETER = 0, DISPLACEMENT, DISCRETECONTROL, MOTOR, LASTELECTRICTYPE } |
Protected Attributes inherited from WithLabel | |
unsigned int | uLabel |
std::string | sName |
Protected Attributes inherited from ToBeOutput | |
flag | fOutput |
Motor::Motor | ( | unsigned int | uL, |
const DofOwner * | pD, | ||
const StructNode * | pN1, | ||
const StructNode * | pN2, | ||
const ElectricNode * | pV1, | ||
const ElectricNode * | pV2, | ||
const Mat3x3 & | Rn, | ||
doublereal | dG, | ||
doublereal | dl, | ||
DriveCaller * | dR, | ||
doublereal | i0, | ||
integer | p, | ||
const DriveCaller * | pM0, | ||
const DriveCaller * | pM1, | ||
flag | fOut | ||
) |
Definition at line 84 of file motor.cc.
References dGain, DriveCaller::dGet(), dGetOmega(), dGetPhiElectric(), dGetPhiMechanical(), dGetVoltage(), grad::fabs(), i, iP, Phi_e, and Phi_m.
|
virtual |
|
virtual |
Implements Elem.
Definition at line 166 of file motor.cc.
References Vec3::Cross(), grad::Cross(), dGain, DriveOwner::dGet(), DriveOwner::dGetP(), dL, dR, grad::fabs(), Mat3x3::GetCol(), StructNode::GetgPCurr(), StructNode::GetRCurr(), StructNode::GetRRef(), StructNode::GetWCurr(), StructNode::GetWRef(), i, DofOwnerOwner::iGetFirstIndex(), StructDispNode::iGetFirstMomentumIndex(), StructDispNode::iGetFirstPositionIndex(), Node::iGetFirstRowIndex(), M, M0, M1, MatCross, Mat3x3::MulTM(), p, Phi_e, pStrNode1, pStrNode2, FullSubMatrixHandler::Put(), FullSubMatrixHandler::PutCoef(), FullSubMatrixHandler::PutColIndex(), FullSubMatrixHandler::PutRowIndex(), FullSubMatrixHandler::PutT(), pVoltage1, pVoltage2, FullSubMatrixHandler::ResizeReset(), Rn, VariableSubMatrixHandler::SetFull(), Mat3x3::Tens(), and WorkSpaceDim().
|
virtual |
Implements Elem.
Definition at line 267 of file motor.cc.
References dGain, DriveOwner::dGet(), dGetOmega(), dGetPhiElectric(), dGetPhiMechanical(), dGetVoltage(), dL, dR, grad::fabs(), Mat3x3::GetCol(), StructNode::GetRCurr(), i, DofOwnerOwner::iGetFirstIndex(), StructDispNode::iGetFirstMomentumIndex(), Node::iGetFirstRowIndex(), iP, M, M0, M1, Phi_e, Phi_m, pStrNode1, pStrNode2, VectorHandler::Put(), VectorHandler::PutCoef(), SubVectorHandler::PutRowIndex(), pVoltage1, pVoltage2, VectorHandler::ResizeReset(), Rn, and WorkSpaceDim().
|
inlineprivate |
Definition at line 326 of file motor.cc.
References GetAxisOfRotation().
Referenced by AssRes(), dGetPrivData(), and Motor().
|
inlineprivate |
Definition at line 318 of file motor.cc.
References StructNode::GetWCurr(), pStrNode1, and pStrNode2.
|
inlineprivate |
|
inlineprivate |
Definition at line 330 of file motor.cc.
References grad::atan2(), Mat3x3::GetCol(), StructNode::GetRCurr(), Mat3x3::MulTV(), pStrNode1, pStrNode2, and Rn.
Referenced by AssRes(), dGetPrivData(), and Motor().
|
virtual |
Reimplemented from SimulationEntity.
Definition at line 397 of file motor.cc.
References DriveOwner::dGet(), dGetOmega(), dGetPhiElectric(), dGetPhiMechanical(), dGetVoltage(), dR, grad::fabs(), i, iP, M, M0, M1, and MBDYN_EXCEPT_ARGS.
|
inlineprivate |
Definition at line 314 of file motor.cc.
References ScalarDifferentialNode::dGetX(), pVoltage1, and pVoltage2.
Referenced by AssRes(), dGetPrivData(), and Motor().
|
inlineprivate |
Definition at line 322 of file motor.cc.
References Mat3x3::GetCol(), StructNode::GetRCurr(), pStrNode1, and Rn.
Referenced by dGetOmega().
|
virtual |
|
virtual |
Reimplemented from Elem.
Definition at line 153 of file motor.cc.
References DofOrder::DIFFERENTIAL.
|
virtual |
|
virtual |
|
virtual |
Reimplemented from SimulationEntity.
Definition at line 381 of file motor.cc.
References iNumPrivData.
|
virtual |
Reimplemented from SimulationEntity.
Definition at line 386 of file motor.cc.
References i, Motor::PrivData::index, iNumPrivData, and rgPrivData.
|
virtual |
Implements Elem.
Definition at line 119 of file motor.cc.
References dGain, dL, dR, WithLabel::GetLabel(), i, M0, M1, p, DriveOwner::pGetDriveCaller(), pStrNode1, pStrNode2, pVoltage1, pVoltage2, DriveCaller::Restart(), and Rn.
|
virtual |
Initialize state vector used in initial assembly. May set internal states of the element. Do not rely on being always called, because initial assembly could be implicitly or explicitly skipped
Reimplemented from DofOwnerOwner.
Definition at line 351 of file motor.cc.
References i, and DofOwnerOwner::iGetFirstIndex().
|
virtual |
Reimplemented from SimulationEntity.
Definition at line 359 of file motor.cc.
References i, DofOwnerOwner::iGetFirstIndex(), and iP.
|
private |
|
private |
|
private |
|
private |
Definition at line 85 of file motor.h.
Referenced by AssJac(), AssRes(), dGetPrivData(), iGetPrivDataIdx(), Motor(), Restart(), SetInitialValue(), and SetValue().
|
staticprivate |
Definition at line 87 of file motor.h.
Referenced by iGetNumPrivData(), and iGetPrivDataIdx().
|
private |
Definition at line 85 of file motor.h.
Referenced by AssRes(), dGetPrivData(), Motor(), and SetValue().
|
private |
Definition at line 85 of file motor.h.
Referenced by AssJac(), AssRes(), and dGetPrivData().
|
private |
|
private |
|
private |
Definition at line 75 of file motor.h.
Referenced by AssJac(), dGetPhiElectric(), and Restart().
|
private |
|
private |
|
private |
Definition at line 66 of file motor.h.
Referenced by AssJac(), AssRes(), dGetOmega(), dGetPhiMechanical(), GetAxisOfRotation(), GetConnectedNodes(), and Restart().
|
private |
Definition at line 67 of file motor.h.
Referenced by AssJac(), AssRes(), dGetOmega(), dGetPhiMechanical(), GetConnectedNodes(), and Restart().
|
private |
Definition at line 68 of file motor.h.
Referenced by AssJac(), AssRes(), dGetVoltage(), GetConnectedNodes(), and Restart().
|
private |
Definition at line 69 of file motor.h.
Referenced by AssJac(), AssRes(), dGetVoltage(), GetConnectedNodes(), and Restart().
|
staticprivate |
Definition at line 69 of file motor.cc.
Referenced by iGetPrivDataIdx().
|
private |
Definition at line 71 of file motor.h.
Referenced by AssJac(), AssRes(), dGetPhiMechanical(), GetAxisOfRotation(), and Restart().