CG
Version 25
|
Public Member Functions | |
TestRigidBody () | |
~TestRigidBody () | |
int | getErrors (int &numErr, aString *&errorNames, RealArray &err) |
int | getExactForcing (const real t, RealArray &f, RealArray &g, RealArray &A11, RealArray &A12, RealArray &A21, RealArray &A22) |
Compute the exact solution. | |
int | getExactSolution (const real t, RealArray &xe, RealArray &ve, RealArray &we) |
Compute the exact solution. | |
void | getForce (real t, RealArray &f, RealArray &g, RealArray &A11, RealArray &A12, RealArray &A21, RealArray &A22, RealArray &xCM, RealArray &vCM) |
int | initialConditions () |
int | solve (GenericGraphicsInterface &gi) |
int | output (TestProblemEnum testProblem, const int step) |
Public Attributes | |
RigidBodyMotion::TimeSteppingMethodEnum | method |
real | cfl |
real | tFinal |
real | tPlot |
real | t |
real | dt |
real | dt0 |
int | orderOfAccuracy |
real | mass |
RealArray | mI |
int | numberOfDimensions |
RealArray | xCM0 |
RealArray | vCM0 |
RealArray | f0 |
RealArray | g0 |
RealArray | w0 |
RealArray | e0 |
int | debug |
int | plotOption |
int | plotBody |
bool | saveMatlabFile |
bool | addedMass |
int | component |
real | cf1 |
real | cf2 |
real | cf3 |
real | cfq1 |
real | cfq2 |
real | cfq3 |
int | freeRotationAxis |
int | m1 |
int | m2 |
int | m3 |
real | lambda |
real | gravity |
real | dragCoeff |
RigidBodyMotion | body |
aString | testName |
TestRigidBody::TestRigidBody | ( | ) |
References addedMass, cf1, cf2, cf3, cfl, cfq1, cfq2, cfq3, component, debug, dragCoeff, dt, dt0, e0, f0, freeRotationAxis, g0, gravity, lambda, RigidBodyMotion::leapFrogTrapezoidal, mass, method, mI, numberOfDimensions, orderOfAccuracy, plotBody, plotOption, saveMatlabFile, t, tFinal, tPlot, vCM0, w0, and xCM0.
TestRigidBody::~TestRigidBody | ( | ) |
int TestRigidBody::getErrors | ( | int & | numErr, |
aString *& | errorNames, | ||
RealArray & | err | ||
) |
References body, e, freeRotation1, freeRotation2, freeRotation3, RigidBodyMotion::getAxesOfInertia(), RigidBodyMotion::getCoordinates(), getExactSolution(), j, R, t, testProblem, and xe.
Referenced by main().
int TestRigidBody::getExactForcing | ( | const real | t, |
RealArray & | f, | ||
RealArray & | g, | ||
RealArray & | A11, | ||
RealArray & | A12, | ||
RealArray & | A21, | ||
RealArray & | A22 | ||
) |
Compute the exact solution.
References getExactSolution(), getForce(), and xe.
Referenced by solve().
int TestRigidBody::getExactSolution | ( | const real | t, |
RealArray & | xe, | ||
RealArray & | ve, | ||
RealArray & | we | ||
) |
Compute the exact solution.
References body, cf1, cf2, cf3, cfq1, cfq2, cfq3, component, constantW0Acceleration, constantW1Acceleration, constantW2Acceleration, constantX0Acceleration, constantX1Acceleration, constantX2Acceleration, dragCoeff, exponentialV, f0, fallingSphere, freeRotation1, freeRotation2, freeRotation3, g0, generalMotion, RigidBodyMotion::getExactSolution(), gravity, lambda, m1, m2, m3, mass, mI, n, OV_ABORT(), scale, sinX0Acceleration, sinX1Acceleration, sinX2Acceleration, t, testProblem, trigonometricMotion, vCM0, w0, xCM0, and xe.
Referenced by getErrors(), getExactForcing(), and output().
void TestRigidBody::getForce | ( | real | t, |
RealArray & | f, | ||
RealArray & | g, | ||
RealArray & | A11, | ||
RealArray & | A12, | ||
RealArray & | A21, | ||
RealArray & | A22, | ||
RealArray & | xCM, | ||
RealArray & | vCM | ||
) |
References addedMass, cf1, cf2, cf3, cfq1, cfq2, cfq3, component, constantW0Acceleration, constantW1Acceleration, constantW2Acceleration, constantX0Acceleration, constantX1Acceleration, constantX2Acceleration, dragCoeff, exponentialV, f, fallingSphere, freeRotation1, freeRotation2, freeRotation3, generalMotion, gravity, i, j, lambda, mass, sinX0Acceleration, sinX1Acceleration, sinX2Acceleration, testProblem, trigonometricMotion, and z.
Referenced by getExactForcing(), initialConditions(), and solve().
int TestRigidBody::initialConditions | ( | ) |
References assert(), body, cfl, component, constantW0Acceleration, constantW1Acceleration, constantW2Acceleration, constantX0Acceleration, constantX1Acceleration, constantX2Acceleration, dt, dt0, e0, exponentialV, f0, fallingSphere, freeRotation1, freeRotation2, freeRotation3, freeRotationAxis, g0, generalMotion, RigidBodyMotion::getExactSolution(), getForce(), m1, m2, m3, mass, mI, numberOfDimensions, OV_ABORT(), printF(), RigidBodyMotion::setInitialConditions(), RigidBodyMotion::setProperties(), RigidBodyMotion::setTwilightZone(), sinX0Acceleration, sinX1Acceleration, sinX2Acceleration, t, testName, testProblem, trigonometricMotion, RigidBodyMotion::trigonometricTwilightZone, vCM0, w0, and xCM0.
Referenced by solve().
int TestRigidBody::output | ( | TestProblemEnum | testProblem, |
const int | step | ||
) |
References body, constantW0Acceleration, constantW1Acceleration, constantW2Acceleration, constantX0Acceleration, constantX1Acceleration, constantX2Acceleration, debug, e, exponentialV, fallingSphere, freeRotation1, freeRotation2, freeRotation3, freeRotationAxis, generalMotion, RigidBodyMotion::getAxesOfInertia(), RigidBodyMotion::getCoordinates(), getExactSolution(), j, OV_ABORT(), printF(), sinX0Acceleration, sinX1Acceleration, sinX2Acceleration, t, testName, trigonometricMotion, and xe.
Referenced by solve().
int TestRigidBody::solve | ( | GenericGraphicsInterface & | gi | ) |
References addedMass, assert(), axis, body, RigidBodyMotion::correct(), dt, e, f, RigidBodyMotion::getAngularVelocities(), RigidBodyMotion::getAxesOfInertia(), getExactForcing(), getForce(), RigidBodyMotion::getVelocity(), i, RigidBodyMotion::includeAddedMass(), initialConditions(), RigidBodyMotion::integrate(), j, method, numberOfDimensions, orderOfAccuracy, output(), plotBody, plotOption, printF(), r, RigidBodyMotion::reset(), saveMatlabFile, RigidBodyMotion::setPastTimeForcing(), RigidBodyMotion::setTimeSteppingMethod(), side, t, testProblem, tFinal, tPlot, vCM0, and xCM0.
Referenced by main().
bool TestRigidBody::addedMass |
Referenced by getForce(), main(), solve(), and TestRigidBody().
RigidBodyMotion TestRigidBody::body |
Referenced by getErrors(), getExactSolution(), initialConditions(), main(), output(), and solve().
real TestRigidBody::cf1 |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
real TestRigidBody::cf2 |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
real TestRigidBody::cf3 |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
real TestRigidBody::cfl |
Referenced by initialConditions(), main(), and TestRigidBody().
real TestRigidBody::cfq1 |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
real TestRigidBody::cfq2 |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
real TestRigidBody::cfq3 |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
int TestRigidBody::component |
Referenced by getExactSolution(), getForce(), initialConditions(), and TestRigidBody().
int TestRigidBody::debug |
Referenced by main(), output(), and TestRigidBody().
real TestRigidBody::dragCoeff |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
real TestRigidBody::dt |
Referenced by initialConditions(), solve(), and TestRigidBody().
real TestRigidBody::dt0 |
Referenced by initialConditions(), main(), and TestRigidBody().
RealArray TestRigidBody::e0 |
Referenced by initialConditions(), and TestRigidBody().
RealArray TestRigidBody::f0 |
Referenced by getExactSolution(), initialConditions(), and TestRigidBody().
int TestRigidBody::freeRotationAxis |
Referenced by initialConditions(), main(), output(), and TestRigidBody().
RealArray TestRigidBody::g0 |
Referenced by getExactSolution(), initialConditions(), and TestRigidBody().
real TestRigidBody::gravity |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
real TestRigidBody::lambda |
Referenced by getExactSolution(), getForce(), and TestRigidBody().
int TestRigidBody::m1 |
Referenced by getExactSolution(), and initialConditions().
int TestRigidBody::m2 |
Referenced by getExactSolution(), and initialConditions().
int TestRigidBody::m3 |
Referenced by getExactSolution(), and initialConditions().
real TestRigidBody::mass |
Referenced by getExactSolution(), getForce(), initialConditions(), main(), and TestRigidBody().
RigidBodyMotion::TimeSteppingMethodEnum TestRigidBody::method |
Referenced by main(), solve(), and TestRigidBody().
RealArray TestRigidBody::mI |
Referenced by getExactSolution(), initialConditions(), and TestRigidBody().
int TestRigidBody::numberOfDimensions |
Referenced by initialConditions(), solve(), and TestRigidBody().
int TestRigidBody::orderOfAccuracy |
Referenced by main(), solve(), and TestRigidBody().
int TestRigidBody::plotBody |
Referenced by main(), solve(), and TestRigidBody().
int TestRigidBody::plotOption |
Referenced by main(), solve(), and TestRigidBody().
bool TestRigidBody::saveMatlabFile |
Referenced by main(), solve(), and TestRigidBody().
real TestRigidBody::t |
Referenced by getErrors(), getExactSolution(), initialConditions(), output(), solve(), and TestRigidBody().
aString TestRigidBody::testName |
Referenced by initialConditions(), main(), and output().
real TestRigidBody::tFinal |
Referenced by main(), solve(), and TestRigidBody().
real TestRigidBody::tPlot |
Referenced by main(), solve(), and TestRigidBody().
RealArray TestRigidBody::vCM0 |
Referenced by getExactSolution(), initialConditions(), solve(), and TestRigidBody().
RealArray TestRigidBody::w0 |
Referenced by getExactSolution(), initialConditions(), and TestRigidBody().
RealArray TestRigidBody::xCM0 |
Referenced by getExactSolution(), initialConditions(), solve(), and TestRigidBody().