LOST 0.0.1
LOST: Open-source Star Tracker
Loading...
Searching...
No Matches
lost::Vec3 Class Reference

Three dimensional vector with decimaling point components. More...

#include <attitude-utils.hpp>

Public Member Functions

 Vec3 ()
 Vec3 (decimal x, decimal y, decimal z)
decimal Magnitude () const
decimal MagnitudeSq () const
 The square of the magnitude.
Vec3 Normalize () const
 Create a vector pointing in the same direction with magnitude 1.
decimal operator* (const Vec3 &) const
 Dot product.
Vec3 operator* (const decimal &) const
 Vector-Scalar multiplication.
Vec3 operator* (const Mat3 &) const
 Vector-matrix multiplication, where the vector is transposed.
Vec3 operator- (const Vec3 &) const
 Usual vector subtraction.
Vec3 operator+ (const Vec3 &) const
Vec3 CrossProduct (const Vec3 &) const
 Usual vector cross product.
Mat3 OuterProduct (const Vec3 &) const
 The outer product of two vectors.

Public Attributes

decimal x
decimal y
decimal z

Friends

std::ostream & operator<< (std::ostream &output, const Vec3 &vec)

Detailed Description

Three dimensional vector with decimaling point components.

Definition at line 36 of file attitude-utils.hpp.

Constructor & Destructor Documentation

◆ Vec3() [1/2]

lost::Vec3::Vec3 ( )
inline

Definition at line 42 of file attitude-utils.hpp.

Here is the caller graph for this function:

◆ Vec3() [2/2]

lost::Vec3::Vec3 ( decimal x,
decimal y,
decimal z )
inline

Definition at line 43 of file attitude-utils.hpp.

Member Function Documentation

◆ CrossProduct()

Vec3 lost::Vec3::CrossProduct ( const Vec3 & other) const

Usual vector cross product.

Definition at line 245 of file attitude-utils.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Magnitude()

decimal lost::Vec3::Magnitude ( ) const

Definition at line 194 of file attitude-utils.cpp.

Here is the caller graph for this function:

◆ MagnitudeSq()

decimal lost::Vec3::MagnitudeSq ( ) const

The square of the magnitude.

Definition at line 185 of file attitude-utils.cpp.

Here is the caller graph for this function:

◆ Normalize()

Vec3 lost::Vec3::Normalize ( ) const

Create a vector pointing in the same direction with magnitude 1.

Definition at line 203 of file attitude-utils.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator*() [1/3]

Vec3 lost::Vec3::operator* ( const decimal & other) const

Vector-Scalar multiplication.

Definition at line 221 of file attitude-utils.cpp.

Here is the call graph for this function:

◆ operator*() [2/3]

Vec3 lost::Vec3::operator* ( const Mat3 & other) const

Vector-matrix multiplication, where the vector is transposed.

Definition at line 263 of file attitude-utils.cpp.

Here is the call graph for this function:

◆ operator*() [3/3]

decimal lost::Vec3::operator* ( const Vec3 & other) const

Dot product.

Definition at line 211 of file attitude-utils.cpp.

Here is the call graph for this function:

◆ operator+()

Vec3 lost::Vec3::operator+ ( const Vec3 & other) const

Definition at line 240 of file attitude-utils.cpp.

Here is the call graph for this function:

◆ operator-()

Vec3 lost::Vec3::operator- ( const Vec3 & other) const

Usual vector subtraction.

Definition at line 236 of file attitude-utils.cpp.

Here is the call graph for this function:

◆ OuterProduct()

Mat3 lost::Vec3::OuterProduct ( const Vec3 & other) const

The outer product of two vectors.

Definition at line 254 of file attitude-utils.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator<<

std::ostream & operator<< ( std::ostream & output,
const Vec3 & vec )
friend

Definition at line 179 of file attitude-utils.cpp.

Member Data Documentation

◆ x

decimal lost::Vec3::x

Definition at line 38 of file attitude-utils.hpp.

◆ y

decimal lost::Vec3::y

Definition at line 39 of file attitude-utils.hpp.

◆ z

decimal lost::Vec3::z

Definition at line 40 of file attitude-utils.hpp.


The documentation for this class was generated from the following files: