21 #ifdef DtUSE_UTILITIES_NAMESPACE
22 namespace DtUSE_UTILITIES_NAMESPACE
55 inline DtVectorT<T>(
const T& x,
const T& y,
const T& z);
67 inline void setToZero();
70 inline void get(T& x, T& y, T& z)
const;
76 inline void setAll(
const T&x,
const T&y,
const T&z);
81 inline const T& x()
const;
83 inline void setX(
const T& x);
87 inline const T& y()
const;
89 inline void setY(
const T& y);
93 inline const T& z()
const;
95 inline void setZ(
const T& z);
99 inline T& operator[](
int ind);
102 inline T operator[](
int ind)
const;
123 inline double magnitudeSquared()
const;
126 inline void normalize();
129 inline bool isNormalized()
const;
133 inline bool magnitudeIsZero()
const;
138 inline bool magnitudeIsZero(
double tolerance)
const;
141 inline std::ostream &printDataToStream(std::ostream &str)
const;
148 inline operator T* ();
149 inline operator const T* ()
const;
168 inline DtVector32(
const float& x,
const float& y,
const float& z);
184 #ifdef DtEXPLICIT_VECTOR_CONVERSION
201 bool approxEq(
const DtVector32& v,
const double& tolerance)
const;
230 inline DtVector64(
const double& x,
const double& y,
const double& z);
246 #ifdef DtIMPLICIT_VECTOR_CONVERSION
263 bool approxEq(
const DtVector64& v,
const double& tolerance)
const;
298 #define DtSetVec(v, x, y, z) v[DtX]=x;v[DtY]=y;v[DtZ]=z;
458 template <
typename T> std::ostream & operator << (std::ostream &str, const DtVectorT<T> &vec)
460 vec.printDataToStream(str);
467 #include "vlVector.inl"
470 #ifdef DtUSE_UTILITIES_NAMESPACE
double DtDistance(const DtVector &p1, const DtVector &p2)
const bool operator==(const DtU128 &lhs, const DtU128 &rhs)
DtVector DtLerpVector(DtVector va, DtVector vb, double t)
Initialize to all zeros.
double DtDistSqr(const DtVector &p1, const DtVector &p2)
void DtVecInit(DtVector &v)
Contains the DtString class declaration.
DtVector operator+(const DtVector &v1, const DtVector &v2)
implements v1 + v2
void DtVV_Product(const DtVector &a, const DtVector &b, DtDcm &ans)
double DtVecBoxProd(const DtVector &v1, const DtVector &v2, const DtVector &v3)
sweep v1 to v2 to v3
DtVector32 & DtVectorRef32
Definition: vlVector.h:289
DtVectors represent vectors in 3-d space, X, Y, Z.
Definition: vlVector.h:49
double DtVecCosProd(const DtVector &v1, const DtVector &v2)
result = -vec
Definition: vlVector.h:33
DtVector & DtVectorRef
Definition: vlVector.h:288
DtVector64 DtVector32To64(const DtVector32 &v32)
Convert between DtVector64 and DtVector32.
void DtVecSub(const DtVector &v1, const DtVector &v2, DtVector &result)
DtThreeIndex DtLevi_Civita
const DtVector & DtConstVector
Definition: vlVector.h:286
This file defines math constants and methods which may be useful in simulations.
Network-order 64-bit IEEE-754 floating-point quantity.
Definition: vlNetTypes.h:173
A Network Byte Order layout using 64 bit floats for DtVector.
Definition: vlVector.h:445
DtVector64 DtVector
Definition: vlVector.h:285
Definition: vlVector.h:224
Definition: vlVector.h:31
void DtVecCopy(const DtVector &from, DtVector &to)
double DtHeadingFromAToB(const DtVector &a, const DtVector &b)
Expects UTM coordinates.
Definition: vlVector.h:162
const DtVector32 & DtConstVector32
Definition: vlVector.h:287
#define DT_DLL_MATRIX
Definition: vlMachineTypes.h:107
DtVector32 DtVector64To32(const DtVector64 &v32)
DtVector DtVelocityFromAToB(const DtVector &a, const DtVector &b, double time)
DtVelocityFromAToB() Returns velocity you would need to be traveling at to get from point A to point ...
void DtVecDump(const char *str, const DtVector &v)
double DtVecInfNorm(const DtVector &v1)
void DtVecDcmMul(const DtVector &v, const DtDcm &m, DtVector &result)
Multiplies a vector by a matrix and stores the result.
double(* DtThreeIndexPtr)[3][3]
Definition: vlVector.h:292
DtVectorOffset
A simple enumeration to represent Vector Offsets.
Definition: vlVector.h:29
Definition: vlVector.h:32
DtVector operator-(const DtVector &v1, const DtVector &v2)
implemented v1 - v2
double DtVecDotProd(const DtVector &v1, const DtVector &v2)
void DtVecNeg(const DtVector &v1, DtVector &result)
void DtVecNormalize(const DtVector &v, DtVector &result)
DtDcms are used to represent orientation for an object.
Definition: vlDcm.h:39
void DtVecAdd(const DtVector &v1, const DtVector &v2, DtVector &result)
const bool operator!=(const DtU128 &lhs, const DtU128 &rhs)
void DtVecScale(const DtVector &v, double scale_factor, DtVector &result)
Network-order 32-bit IEEE-754 floating-point quantity.
Definition: vlNetTypes.h:147
Instances of DtString are used to represent strings.
Definition: vlString.h:29
double DtThreeIndex[3][3][3]
Definition: vlVector.h:291
int DtVecCheck(const DtVector &v)
void DtVecCrossProd(const DtVector &v1, const DtVector &v2, DtVector &result)
This file contains typedefs for machine dependant types.
A Network Byte Order layout using 32 bit floats for DtVector.
Definition: vlVector.h:430