Specialisation for a cartesian point of dimension 3. More...
#include <cartesian_point.hpp>
Public Member Functions | |
CartesianPoint (const T &value=T()) | |
Default constructor - sets all elements to the same value. | |
CartesianPoint (const ecl::linear_algebra::Matrix< T, 3, 1 > &vec) | |
Initialises with the specified eigen style vector. | |
CartesianPoint (const T &x_i, const T &y_i, const T &z_i) | |
Initialises the point with the specified values. | |
ecl::linear_algebra::CommaInitializer < ecl::linear_algebra::Matrix < T, 3, 1 > > | operator<< (const T &value) |
ecl::linear_algebra::Matrix< T, 3, 1 > & | positionVector () |
Representation of the position vector in eigen vector format. | |
const ecl::linear_algebra::Matrix< T, 3, 1 > & | positionVector () const |
Representation of the position vector in const eigen vector format. | |
unsigned int | size () |
Size/dimension of the cartesian point. | |
const T & | x () const |
Returns a constant reference to the x co-ordinate. | |
T | x () |
Returns a copy of the x co-ordinate. | |
void | x (const T &value) |
Sets the x-coordinate. | |
const T & | y () const |
Returns a constant reference to the y co-ordinate. | |
T | y () |
Returns a copy of the y co-ordinate. | |
void | y (const T &value) |
Sets the y-coordinate. | |
const T & | z () const |
Returns a constant reference to the z co-ordinate. | |
T | z () |
Returns a copy of the z co-ordinate. | |
void | z (const T &value) |
Sets the z-coordinate. | |
virtual | ~CartesianPoint () |
Private Attributes | |
ecl::linear_algebra::Matrix< T, 3, 1 > | elements |
Friends | |
template<typename OutputStream , typename Type > | |
OutputStream & | operator<< (OutputStream &ostream, const CartesianPoint< Type, 3 > &point) |
Specialisation for a cartesian point of dimension 3.
It introduces handles to x(), y(), z() for convenience, whilst still permitting a vector representation of the underlying storage container via the positionVector() method.
T | : the underlying element type. |
Definition at line 144 of file cartesian_point.hpp.
ecl::CartesianPoint< T, 3 >::CartesianPoint | ( | const T & | value = T() | ) | [inline] |
Default constructor - sets all elements to the same value.
Definition at line 149 of file cartesian_point.hpp.
ecl::CartesianPoint< T, 3 >::CartesianPoint | ( | const ecl::linear_algebra::Matrix< T, 3, 1 > & | vec | ) | [inline] |
Initialises with the specified eigen style vector.
vec | : input three dimensional eigen style vector. |
Definition at line 155 of file cartesian_point.hpp.
ecl::CartesianPoint< T, 3 >::CartesianPoint | ( | const T & | x_i, |
const T & | y_i, | ||
const T & | z_i | ||
) | [inline] |
Initialises the point with the specified values.
x_i | : x co-ordinate. |
y_i | : y co-ordinate. |
z_i | : z co-ordinate. |
Definition at line 163 of file cartesian_point.hpp.
virtual ecl::CartesianPoint< T, 3 >::~CartesianPoint | ( | ) | [inline, virtual] |
Definition at line 167 of file cartesian_point.hpp.
ecl::linear_algebra::CommaInitializer< ecl::linear_algebra::Matrix<T,3,1> > ecl::CartesianPoint< T, 3 >::operator<< | ( | const T & | value | ) | [inline] |
Provides a comma initialisation facility. This initiates the comma initialiser with an iterator to the underlying elements and then leaves the initialiser to do the rest.
CartesianPoint<double,3> point; // At this point it is initialised with default values.
point << 1.0,2.0,3.0;
value | : the first of three points to enter. |
Definition at line 185 of file cartesian_point.hpp.
ecl::linear_algebra::Matrix<T,3,1>& ecl::CartesianPoint< T, 3 >::positionVector | ( | ) | [inline] |
Representation of the position vector in eigen vector format.
Converts representation to an eigen vector reference - oft necessary in mathematics calculations.
Definition at line 196 of file cartesian_point.hpp.
const ecl::linear_algebra::Matrix<T,3,1>& ecl::CartesianPoint< T, 3 >::positionVector | ( | ) | const [inline] |
Representation of the position vector in const eigen vector format.
Converts representation to a const eigen vector reference - oft necessary in mathematics calculations.
Definition at line 205 of file cartesian_point.hpp.
unsigned int ecl::CartesianPoint< T, 3 >::size | ( | ) | [inline] |
Size/dimension of the cartesian point.
Size/dimension of the cartesian point.
Definition at line 214 of file cartesian_point.hpp.
const T& ecl::CartesianPoint< T, 3 >::x | ( | ) | const [inline] |
Returns a constant reference to the x co-ordinate.
Definition at line 221 of file cartesian_point.hpp.
T ecl::CartesianPoint< T, 3 >::x | ( | ) | [inline] |
Returns a copy of the x co-ordinate.
Definition at line 239 of file cartesian_point.hpp.
void ecl::CartesianPoint< T, 3 >::x | ( | const T & | value | ) | [inline] |
Sets the x-coordinate.
Definition at line 253 of file cartesian_point.hpp.
const T& ecl::CartesianPoint< T, 3 >::y | ( | ) | const [inline] |
Returns a constant reference to the y co-ordinate.
Definition at line 227 of file cartesian_point.hpp.
T ecl::CartesianPoint< T, 3 >::y | ( | ) | [inline] |
Returns a copy of the y co-ordinate.
Definition at line 245 of file cartesian_point.hpp.
void ecl::CartesianPoint< T, 3 >::y | ( | const T & | value | ) | [inline] |
Sets the y-coordinate.
Definition at line 254 of file cartesian_point.hpp.
const T& ecl::CartesianPoint< T, 3 >::z | ( | ) | const [inline] |
Returns a constant reference to the z co-ordinate.
Definition at line 233 of file cartesian_point.hpp.
T ecl::CartesianPoint< T, 3 >::z | ( | ) | [inline] |
Returns a copy of the z co-ordinate.
Definition at line 251 of file cartesian_point.hpp.
void ecl::CartesianPoint< T, 3 >::z | ( | const T & | value | ) | [inline] |
Sets the z-coordinate.
Definition at line 255 of file cartesian_point.hpp.
OutputStream& operator<< | ( | OutputStream & | ostream, |
const CartesianPoint< Type, 3 > & | point | ||
) | [friend] |
Insertion operator for sending the point to an output stream. This is raw, and has no formatting.
ostream | : the output stream. |
point | : the point to be inserted. |
Definition at line 279 of file cartesian_point.hpp.
ecl::linear_algebra::Matrix<T,3,1> ecl::CartesianPoint< T, 3 >::elements [private] |
Definition at line 261 of file cartesian_point.hpp.