Voxelyze
|
Defines a solid link between two adjacent voxels and holds its current state. More...
#include <VX_Link.h>
Public Types | |
enum | linkAxis { X_AXIS = 0, Y_AXIS = 1, Z_AXIS = 2 } |
Defines an axis (X, Y, or Z) More... | |
Public Member Functions | |
CVX_Link (CVX_Voxel *voxel1, CVX_Voxel *voxel2, CVX_MaterialLink *material) | |
Constructs a link object between two adjacent voxels that represents a solid material connection. The order of voxel1 and voxel2 is unimportant, but the specified linkDirection is interpreted as the originating from voxel1 and pointing to voxel2. A CVX_LinkMaterial representing the desired combination of the two voxel materials must be precomputed and passed as a parameter as well. | |
void | reset () |
Resets all current state information about this link to the initial value. | |
CVX_Voxel * | voxel (bool positiveEnd) const |
Returns a pointer to one of the two voxels that compose this link. | |
Vec3D | force (bool positiveEnd) const |
Returns the current force acting on a voxel due to the position and orientation of the other. | |
Vec3D | moment (bool positiveEnd) const |
Returns the current moment acting on a voxel due to the position and orientation of the other. | |
float | axialStrain () const |
returns the current overall axial strain (unitless) between the two voxels. | |
float | axialStrain (bool positiveEnd) const |
Returns the current calculated axial strain of the half of the link contained in the specified voxel. | |
float | axialStress () const |
returns the current overall true axial stress (MPa) between the two voxels. | |
bool | isSmallAngle () const |
Returns true if this link is currently operating with a small angle assumption. | |
bool | isYielded () const |
Returns true if the stress on this bond has ever exceeded its yield stress. | |
bool | isFailed () const |
Returns true if the stress on this bond has ever exceeded its failure stress. | |
float | strainEnergy () const |
Calculates and return the strain energy of this link according to current forces and moments. (units: Joules, or Kg m^2 / s^2) | |
float | axialStiffness () |
Calculates and returns the current linear axial stiffness of this link at it's current strain. | |
void | updateForces () |
Called every timestep to calculate the forces and moments acting between the two constituent voxels in their current relative positions and orientations. | |
void | updateRestLength () |
Updates the rest length of this voxel. Call this every timestep where the nominal size of either voxel may have changed, due to actuation or thermal expansion. | |
void | updateTransverseInfo () |
Updates information about this voxel pertaining to volumetric deformations. Call this every timestep if the poisson's ratio of the link material is non-zero. | |
Friends | |
class | CVoxelyze |
class | CVX_LinearSolver |
class | CVXS_SimGLView |
Defines a solid link between two adjacent voxels and holds its current state.
A CVX_Link calculates the force and moments between two voxels given their relative positions and orientations.
A 12 degree of freedom beam element is utilized to physically model the connection. Pure tension/compression, pure torsion, and slender beam equations are used. Small angle approximations are applied in appropriate scenarios to accelerate computation.
The force and moment for either voxel can be queried, as well as the current axial stress and strain of the link. If voxels are changing size (under thermal or other actuation) then updateRestLength() must be called every timestep. Likewise if the poissons ratio of either voxel is non-zero updateTransverseInfo() must be called likewise.
Information pertaining to one voxel or the other is indicated by the boolean parameter "positiveEnd". If positiveEnd is true, information will be returned for the voxel with the most positive coordinate in the original (undeformed) lattice.
enum CVX_Link::linkAxis |
CVX_Link::CVX_Link | ( | CVX_Voxel * | voxel1, |
CVX_Voxel * | voxel2, | ||
CVX_MaterialLink * | material | ||
) |
Constructs a link object between two adjacent voxels that represents a solid material connection. The order of voxel1 and voxel2 is unimportant, but the specified linkDirection is interpreted as the originating from voxel1 and pointing to voxel2. A CVX_LinkMaterial representing the desired combination of the two voxel materials must be precomputed and passed as a parameter as well.
[in] | voxel1 | One voxel |
[in] | voxel2 | The other voxel |
[in] | material | The material properties for this link. |
float CVX_Link::axialStrain | ( | bool | positiveEnd | ) | const |
Returns the current calculated axial strain of the half of the link contained in the specified voxel.
[in] | positiveEnd | Specifies which voxel information is desired about. |
Vec3D CVX_Link::force | ( | bool | positiveEnd | ) | const [inline] |
Returns the current force acting on a voxel due to the position and orientation of the other.
[in] | positiveEnd | Specifies which voxel information is desired about. |
Vec3D CVX_Link::moment | ( | bool | positiveEnd | ) | const [inline] |
Returns the current moment acting on a voxel due to the position and orientation of the other.
[in] | positiveEnd | Specifies which voxel information is desired about. |
CVX_Voxel* CVX_Link::voxel | ( | bool | positiveEnd | ) | const [inline] |
Returns a pointer to one of the two voxels that compose this link.
[in] | positiveEnd | Specifies which voxel is desired. |