Public Member Functions | Public Attributes | List of all members
Extensive Class Reference

Extensive variables. More...

#include <extensive.hpp>

Inheritance diagram for Extensive:
Inheritance graph
[legend]
Collaboration diagram for Extensive:
Collaboration graph
[legend]

Public Member Functions

Extensiveoperator= (const Extensive &origin)
 Assignment operator. More...
 
 Extensive (const Extensive &other)
 copy constructor More...
 
Extensiveoperator-= (const Extensive &diff)
 Self difference operator. More...
 
Extensiveoperator+= (const Extensive &diff)
 Self addition operator. More...
 
Extensiveoperator*= (const double scalar)
 Self multiplication by scalar. More...
 
 Extensive (void)
 Null constructor.
 
 Extensive (tvector const &Tracers)
 constructor for extensive with a tracer list. All tracers start with zero. More...
 
size_t getChunkSize (void) const
 Returns the size of array needed to store all data. More...
 
vector< double > serialize (void) const
 Convert an object to an array of numbers. More...
 
void unserialize (const vector< double > &data)
 Convert an array of numbers to an object. More...
 
- Public Member Functions inherited from Serializable
virtual ~Serializable (void)
 Class destructor.
 

Public Attributes

double mass
 rest mass times gamma
 
double energy
 energy, in relativity it is = rho*h*gamma^2-P-rho
 
Vector2D momentum
 momentum, in relativity it is = rho*h*gamma*v
 
tvector tracers
 tracers
 

Detailed Description

Extensive variables.

Definition at line 18 of file extensive.hpp.

Constructor & Destructor Documentation

◆ Extensive() [1/2]

Extensive::Extensive ( const Extensive other)

copy constructor

Parameters
otherSource from which to copy data

Definition at line 4 of file extensive.cpp.

◆ Extensive() [2/2]

Extensive::Extensive ( tvector const &  Tracers)
explicit

constructor for extensive with a tracer list. All tracers start with zero.

Parameters
TracersThe tracers

Definition at line 16 of file extensive.cpp.

Member Function Documentation

◆ getChunkSize()

size_t Extensive::getChunkSize ( void  ) const
virtual

Returns the size of array needed to store all data.

Returns
Size of array

Implements Serializable.

Definition at line 116 of file extensive.cpp.

Here is the caller graph for this function:

◆ operator*=()

Extensive & Extensive::operator*= ( const double  scalar)

Self multiplication by scalar.

Parameters
scalarThe scalar to multiply
Returns
Reference to self

Definition at line 98 of file extensive.cpp.

◆ operator+=()

Extensive & Extensive::operator+= ( const Extensive diff)

Self addition operator.

Parameters
diffAddition
Returns
Reference to self

Definition at line 58 of file extensive.cpp.

◆ operator-=()

Extensive & Extensive::operator-= ( const Extensive diff)

Self difference operator.

Parameters
diffDifference
Returns
Reference to self

Definition at line 26 of file extensive.cpp.

◆ operator=()

Extensive & Extensive::operator= ( const Extensive origin)

Assignment operator.

Parameters
originOriginal extensives variables
Returns
Copy

Definition at line 38 of file extensive.cpp.

◆ serialize()

vector< double > Extensive::serialize ( void  ) const
virtual

Convert an object to an array of numbers.

Returns
Array of numbers

Implements Serializable.

Definition at line 121 of file extensive.cpp.

Here is the call graph for this function:

◆ unserialize()

void Extensive::unserialize ( const vector< double > &  data)
virtual

Convert an array of numbers to an object.

Parameters
dataList of numbers

Implements Serializable.

Definition at line 140 of file extensive.cpp.

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

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