MercuryDPM  Beta
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Matrix3D Class Reference

Implementation of a 3D matrix. More...

#include <Matrix.h>

Public Member Functions

 Matrix3D ()
 default constructor More...
 
 Matrix3D (const Mdouble xx, const Mdouble xy, const Mdouble xz, const Mdouble yx, const Mdouble yy, const Mdouble yz, const Mdouble zx, const Mdouble zy, const Mdouble zz)
 Alternative constructor, which let you define all elements. More...
 
void setZero ()
 Sets all elements to zero. More...
 
double trace () const
 Mean of the diagonal elements. More...
 
Matrix3D operator+ (const Matrix3D &A) const
 Matrix addition. More...
 
Matrix3D operator- (const Matrix3D &A) const
 Matrix subtraction. More...
 
Matrix3D operator+ (const Mdouble a) const
 Scalar addition. More...
 
Matrix3D operator- (const Mdouble a) const
 Scalar subtraction. More...
 
Matrix3D operator* (const Mdouble a) const
 Scalar multiplication. More...
 
Vec3D operator* (const Vec3D &a) const
 Vector multiplication. More...
 
Matrix3D operator* (const Matrix3D &a) const
 Matrix multiplication. More...
 
Matrix3D operator/ (const Mdouble a) const
 Scalar division. More...
 
Matrix3Doperator+= (const Matrix3D &A)
 Matrix addition. More...
 
Matrix3Doperator-= (const Matrix3D &A)
 Matrix substraction. More...
 
Matrix3Doperator/= (const Mdouble a)
 Scalar division. More...
 

Static Public Member Functions

static Matrix3D square (const Matrix3D &A)
 Calculates the pointwise square. More...
 
static Matrix3D sqrt (const Matrix3D &A)
 Calculates the pointwise square root. More...
 
static Matrix3D dyadic (const Vec3D &a, const Vec3D &b)
 Calculates the dyadic product of a two Vec3D: \(a \otimes b\). More...
 
static Matrix3D cross (const Vec3D &a, const Matrix3D &b)
 'Special' cross product; CP of vector with each column of a matrix More...
 

Public Attributes

Mdouble XX
 all nine matrix elements More...
 
Mdouble XY
 
Mdouble XZ
 
Mdouble YX
 
Mdouble YY
 
Mdouble YZ
 
Mdouble ZX
 
Mdouble ZY
 
Mdouble ZZ
 

Friends

std::ostream & operator<< (std::ostream &os, const Matrix3D &A)
 Add elements to ostream. More...
 
std::istream & operator>> (std::istream &is, Matrix3D &A)
 Add elements to istream. More...
 

Detailed Description

Implementation of a 3D matrix.

Definition at line 36 of file Matrix.h.

Constructor & Destructor Documentation

Matrix3D::Matrix3D ( )

default constructor

default constructor, which is empty (i.e., only creates the object)

Definition at line 32 of file Matrix.cc.

Referenced by cross(), dyadic(), operator*(), operator+(), operator-(), operator/(), sqrt(), and square().

33 {
34 }
Matrix3D::Matrix3D ( const Mdouble  xx,
const Mdouble  xy,
const Mdouble  xz,
const Mdouble  yx,
const Mdouble  yy,
const Mdouble  yz,
const Mdouble  zx,
const Mdouble  zy,
const Mdouble  zz 
)

Alternative constructor, which let you define all elements.

Alternative constructor. Let's you specify ALL 9 elements of the 3x3 matrix.

Parameters
[in][all]xx/xy/xz /yx/yy/yz /zx/zy/zz are all nine elements (left-to-right, top-to-bottom) of the 3D matrix.

Definition at line 42 of file Matrix.cc.

References XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

43 {
44  XX = xx;
45  XY = xy;
46  XZ = xz;
47  YX = yx;
48  YY = yy;
49  YZ = yz;
50  ZX = zx;
51  ZY = zy;
52  ZZ = zz;
53 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42

Member Function Documentation

Matrix3D Matrix3D::cross ( const Vec3D a,
const Matrix3D B 
)
static

'Special' cross product; CP of vector with each column of a matrix

Returns a matrix, who's columns are the inner product of a given vector with the corresponding columns of a given matrix

Parameters
[in]avector
[in]Bmatrix
Returns
Resulting matrix

Definition at line 299 of file Matrix.cc.

References Matrix3D(), Vec3D::X, XX, XY, XZ, Vec3D::Y, YX, YY, YZ, Vec3D::Z, ZX, ZY, and ZZ.

300 {
301  return Matrix3D(
302  a.Y * B.ZX - a.Z * B.YX, a.Y * B.ZY - a.Z * B.YY, a.Y * B.ZZ - a.Z * B.YZ,
303  a.Z * B.XX - a.X * B.ZX, a.Z * B.XY - a.X * B.ZY, a.Z * B.XZ - a.X * B.ZZ,
304  a.X * B.YX - a.Y * B.XX, a.X * B.YY - a.Y * B.XY, a.X * B.YZ - a.Y * B.XZ);
305 }
Mdouble XY
Definition: Matrix.h:42
Mdouble X
the vector components
Definition: Vector.h:52
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble Y
Definition: Vector.h:52
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Mdouble Z
Definition: Vector.h:52
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D Matrix3D::dyadic ( const Vec3D a,
const Vec3D b 
)
static

Calculates the dyadic product of a two Vec3D: \(a \otimes b\).

Dyadic product of two vectors

Parameters
[in]afirst vector
[in]bsecond vector
Returns
Resulting matrix

Definition at line 285 of file Matrix.cc.

References Matrix3D(), Vec3D::X, Vec3D::Y, and Vec3D::Z.

286 {
287  return Matrix3D(a.X * b.X, a.X * b.Y, a.X * b.Z,
288  a.Y * b.X, a.Y * b.Y, a.Y * b.Z,
289  a.Z * b.X, a.Z * b.Y, a.Z * b.Z);
290 }
Mdouble X
the vector components
Definition: Vector.h:52
Mdouble Y
Definition: Vector.h:52
Mdouble Z
Definition: Vector.h:52
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D Matrix3D::operator* ( const Mdouble  a) const

Scalar multiplication.

Multiplication with scalar

Parameters
[in]aScalar to be multiplied with
Returns
resulting matrix

Definition at line 127 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

128 {
129  return Matrix3D(XX * a, XY * a, XZ * a,
130  YX * a, YY * a, YZ * a,
131  ZX * a, ZY * a, ZZ * a);
132 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Vec3D Matrix3D::operator* ( const Vec3D a) const

Vector multiplication.

Multiplication with vector

Parameters
[in]aVector to be multiplied with
Returns
Resulting vector

Definition at line 139 of file Matrix.cc.

References Vec3D::X, XX, XY, XZ, Vec3D::Y, YX, YY, YZ, Vec3D::Z, ZX, ZY, and ZZ.

140 {
141  return Vec3D(XX * a.X + XY * a.Y + XZ * a.Z,
142  YX * a.X + YY * a.Y + YZ * a.Z,
143  ZX * a.X + ZY * a.Y + ZZ * a.Z);
144 }
Mdouble XY
Definition: Matrix.h:42
Mdouble X
the vector components
Definition: Vector.h:52
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble Y
Definition: Vector.h:52
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Implementation of a 3D vector (by Vitaliy).
Definition: Vector.h:45
Mdouble Z
Definition: Vector.h:52
Matrix3D Matrix3D::operator* ( const Matrix3D a) const

Matrix multiplication.

Definition at line 146 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

147 {
148  return Matrix3D(XX * a.XX + XY * a.YX + XZ * a.ZX,
149  YX * a.XX + YY * a.YX + YZ * a.ZX,
150  ZX * a.XX + ZY * a.YX + ZZ * a.ZX,
151  XX * a.XY + XY * a.YY + XZ * a.ZY,
152  YX * a.XY + YY * a.YY + YZ * a.ZY,
153  ZX * a.XY + ZY * a.YY + ZZ * a.ZY,
154  XX * a.XZ + XY * a.YZ + XZ * a.ZZ,
155  YX * a.XZ + YY * a.YZ + YZ * a.ZZ,
156  ZX * a.XZ + ZY * a.YZ + ZZ * a.ZZ
157  );
158 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D Matrix3D::operator+ ( const Matrix3D A) const

Matrix addition.

Addition of this matrix with given one

Parameters
[in]AMatrix to be added
Returns
resulting matrix

Definition at line 78 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

79 {
80  return Matrix3D(XX + A.XX, XY + A.XY, XZ + A.XZ,
81  YX + A.YX, YY + A.YY, YZ + A.YZ,
82  ZX + A.ZX, ZY + A.ZY, ZZ + A.ZZ);
83 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D Matrix3D::operator+ ( const Mdouble  a) const

Scalar addition.

Addition of scalar

Parameters
[in]aScalar to be added
Returns
resulting matrix

Definition at line 103 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

104 {
105  return Matrix3D(XX + a, XY + a, XZ + a,
106  YX + a, YY + a, YZ + a,
107  ZX + a, ZY + a, ZZ + a);
108 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D & Matrix3D::operator+= ( const Matrix3D A)

Matrix addition.

Adds all elements of a given matrix to its own

Parameters
[in]A3D matrix to be added
Returns
(reference to) resulting (this) matrix

Definition at line 203 of file Matrix.cc.

References XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

204 {
205  XX += A.XX;
206  XY += A.XY;
207  XZ += A.XZ;
208  YX += A.YX;
209  YY += A.YY;
210  YZ += A.YZ;
211  ZX += A.ZX;
212  ZY += A.ZY;
213  ZZ += A.ZZ;
214  return *this;
215 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D Matrix3D::operator- ( const Matrix3D A) const

Matrix subtraction.

Substraction of given matrix from this one

Parameters
[in]AMatrix to be substracted
Returns
resulting matrix

Definition at line 91 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

92 {
93  return Matrix3D(XX - A.XX, XY - A.XY, XZ - A.XZ,
94  YX - A.YX, YY - A.YY, YZ - A.YZ,
95  ZX - A.ZX, ZY - A.ZY, ZZ - A.ZZ);
96 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D Matrix3D::operator- ( const Mdouble  a) const

Scalar subtraction.

Substraction of scalar

Parameters
[in]aScalar to be substracted
Returns
resulting matrix

Definition at line 115 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

116 {
117  return Matrix3D(XX - a, XY - a, XZ - a,
118  YX - a, YY - a, YZ - a,
119  ZX - a, ZY - a, ZZ - a);
120 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D & Matrix3D::operator-= ( const Matrix3D A)

Matrix substraction.

Substract all elements of a given matrix from its own

Parameters
[in]A3D matrix to be substracted
Returns
(reference to) resulting (this) matrix

Definition at line 222 of file Matrix.cc.

References XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

223 {
224  XX -= A.XX;
225  XY -= A.XY;
226  XZ -= A.XZ;
227  YX -= A.YX;
228  YY -= A.YY;
229  YZ -= A.YZ;
230  ZX -= A.ZX;
231  ZY -= A.ZY;
232  ZZ -= A.ZZ;
233  return *this;
234 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D Matrix3D::operator/ ( const Mdouble  a) const

Scalar division.

Division by a scalar

Parameters
[in]ascalar to be divided by
Returns
resulting matrix

Definition at line 165 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

166 {
167  return Matrix3D(XX / a, XY / a, XZ / a,
168  YX / a, YY / a, YZ / a,
169  ZX / a, ZY / a, ZZ / a);
170 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D & Matrix3D::operator/= ( const Mdouble  a)

Scalar division.

Division by a scalar

Parameters
[in]ascalar to be divided by
Returns
(reference to) resulting (this) matrix

Definition at line 241 of file Matrix.cc.

References XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

242 {
243  XX /= a;
244  XY /= a;
245  XZ /= a;
246  YX /= a;
247  YY /= a;
248  YZ /= a;
249  ZX /= a;
250  ZY /= a;
251  ZZ /= a;
252  return *this;
253 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
void Matrix3D::setZero ( )

Sets all elements to zero.

Sets all elements to zero.

Definition at line 58 of file Matrix.cc.

References XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

59 {
60  XX = XY = XZ = YX = YY = YZ = ZX = ZY = ZZ = 0.0;
61 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D Matrix3D::sqrt ( const Matrix3D A)
static

Calculates the pointwise square root.

Takes the square root of all the elements in given matrix

Parameters
[in]AMatrix to be pointwise square rooted
Returns
Resulting matrix

Definition at line 272 of file Matrix.cc.

References Matrix3D(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

273 {
274  return Matrix3D(std::sqrt(A.XX), std::sqrt(A.XY), std::sqrt(A.XZ),
275  std::sqrt(A.YX), std::sqrt(A.YY), std::sqrt(A.YZ),
276  std::sqrt(A.ZX), std::sqrt(A.ZY), std::sqrt(A.ZZ));
277 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Matrix3D Matrix3D::square ( const Matrix3D A)
static

Calculates the pointwise square.

Squares all the elements in given matrix

Parameters
[in]AMatrix to be pointwise squared
Returns
Resulting matrix

Definition at line 260 of file Matrix.cc.

References Matrix3D(), mathsFunc::square(), XX, XY, XZ, YX, YY, YZ, ZX, ZY, and ZZ.

261 {
265 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
T square(T val)
squares a number
Definition: ExtendedMath.h:91
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
Matrix3D()
default constructor
Definition: Matrix.cc:32
Mdouble Matrix3D::trace ( ) const

Mean of the diagonal elements.

Returns the sum of the diagonal elements of the maxtrix, divided by the total number of diagonal elements.

Returns
resulting scalar

Definition at line 68 of file Matrix.cc.

References XX, YY, and ZZ.

69 {
70  return (XX + YY + ZZ) / 3;
71 }
Mdouble ZZ
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const Matrix3D A 
)
friend

Add elements to ostream.

Adds all elements of a matrix to an ostream

Parameters
[out]osoutput stream
[in]A3D matrix
Returns
output stream with matrix elements added

Definition at line 178 of file Matrix.cc.

179 {
180  os << A.XX << ' ' << A.XY << ' ' << A.XZ << ' '
181  << A.YX << ' ' << A.YY << ' ' << A.YZ << ' '
182  << A.ZX << ' ' << A.ZY << ' ' << A.ZZ;
183  return os;
184 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42
std::istream& operator>> ( std::istream &  is,
Matrix3D A 
)
friend

Add elements to istream.

Reads the elements of a matrix from an istream

Parameters
[in,out]isinput stream
[out]A3D matrix
Returns
is input stream after the read operation.

Definition at line 192 of file Matrix.cc.

193 {
194  is >> A.XX >> A.XY >> A.XZ >> A.YX >> A.YY >> A.YZ >> A.ZX >> A.ZY >> A.ZZ;
195  return is;
196 }
Mdouble XY
Definition: Matrix.h:42
Mdouble ZY
Definition: Matrix.h:42
Mdouble XZ
Definition: Matrix.h:42
Mdouble ZX
Definition: Matrix.h:42
Mdouble ZZ
Definition: Matrix.h:42
Mdouble YZ
Definition: Matrix.h:42
Mdouble YX
Definition: Matrix.h:42
Mdouble XX
all nine matrix elements
Definition: Matrix.h:42
Mdouble YY
Definition: Matrix.h:42

Member Data Documentation

Mdouble Matrix3D::XX

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