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

Class representing a manifold with different coordinate systems and metrics. More...

#include <geometry.h>

Inheritance diagram for Manifold:
KerrManifold SchwManifold

Public Member Functions

 Manifold ()
 Constructor.
 
virtual ~Manifold ()
 Destructor.
 
CoordinateConversiongetConversion (int i, int j)
 Get a coordinate conversion. More...
 
MetricgetMetric (int i)
 Get a metric. More...
 
Point convertPointTo (Point p, int system)
 Convert a point to another coordinate system. More...
 
vector4 convertVectorTo (vector4 v, Point p, int system)
 Convert a vector to another coordinate system. More...
 
virtual int recommendCoordSystem (Point p)
 Get the best coordinate system to use at a point. More...
 

Protected Attributes

int nCoordSystems
 
CoordinateConversion *** conversions
 
Metric ** metrics
 

Detailed Description

Class representing a manifold with different coordinate systems and metrics.

This class represents a manifold with multiple coordinate systems, conversions between them and a metric, which can be expressed in either of the systems.

Member Function Documentation

Point Manifold::convertPointTo ( Point  p,
int  system 
)

Convert a point to another coordinate system.

Parameters
pThe point to be converted
systemThe target coordinate system
Returns
Converted point
vector4 Manifold::convertVectorTo ( vector4  v,
Point  p,
int  system 
)

Convert a vector to another coordinate system.

Parameters
vThe vector to be converted
pThe point at which the vector is defined
systemThe target coordinate system
Returns
Converted vector
CoordinateConversion * Manifold::getConversion ( int  i,
int  j 
)

Get a coordinate conversion.

Parameters
iNumber of the source coordinate system
jNumber of the target coordinate system
Returns
Pointer to the conversion object
Metric * Manifold::getMetric ( int  i)

Get a metric.

Parameters
iNumber of the coordinate system
Returns
Pointer to the metric expressed in the chosen system
int Manifold::recommendCoordSystem ( Point  p)
virtual

Get the best coordinate system to use at a point.

Parameters
pThe point
Returns
The recommended coordinate system to be used

Reimplemented in KerrManifold, and SchwManifold.


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