GR Engine
A physics engine in curved space-time
 All Classes Files Functions Variables
Public Member Functions | Static Public Member Functions | List of all members
Point Class Reference

A point on a manifold. More...

#include <geometry.h>

Public Member Functions

 Point ()
 Default constructor - initializes the point with an invalid coordinate system.
 
 Point (int cS, double x0=0.0, double x1=0.0, double x2=0.0, double x3=0.0)
 Constructor. More...
 
 Point (int cS, double tx[])
 Constructor. More...
 
 Point (int cS, vector4 v)
 Constructor. More...
 
 Point (const Point &)
 Copy constructor.
 
 ~Point ()
 Destructor.
 
double & operator[] (int i)
 Index operator. More...
 
int getCoordSystem ()
 Function returning the coordinate system.
 
vector4 toVector4 ()
 Conversion to vector4.
 
bool operator== (Point)
 
bool operator!= (Point)
 

Static Public Member Functions

static void setGlobalManifold (Manifold *_m)
 Static method setting the global manifold variable.
 

Detailed Description

A point on a manifold.

The class defines a point on the manifold using 4 coordinates and the number of the coordinate system being used. This allows for two points from different coordinate systems to be compared.

Constructor & Destructor Documentation

Point::Point ( int  cS,
double  x0 = 0.0,
double  x1 = 0.0,
double  x2 = 0.0,
double  x3 = 0.0 
)

Constructor.

Parameters
cSCoordinate system being used
x0First coordinate
x1Second coordinate
x2Third coordinate
x3Fourth coordinate
Point::Point ( int  cS,
double  tx[] 
)

Constructor.

Parameters
cSCoordinate system being used
txArray of coordinates
Point::Point ( int  cS,
vector4  v 
)

Constructor.

Parameters
cSCoordinate system being used
vA vector4 containing the coordinates

Member Function Documentation

double & Point::operator[] ( int  i)

Index operator.

Parameters
iNumber of the coordinate to retrieve
Returns
Reference to the coordinate, which allows for modification

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