Object

Base Object

template<typename T>
class Object

Subclassed by sbody::Disk< T >, sbody::Particle< T >

Public Functions

inline Object(const Metric<T> &metric)

Construct a new Object object.

Parameters:

metric –

virtual bool hit(const bounded_vector<T, 8> &current, const bounded_vector<T, 8> &last) const = 0
Parameters:
  • current –

  • last –

Returns:

bool

virtual T dopplerFactor(const boost::numeric::ublas::bounded_vector<T, 8> &photon, TimeSystem photon_time) const = 0

\[z=\frac{E_\mathrm{obj}}{E_\mathrm{obs}}-1\]
where
\[E_\mathrm{obj}=-g_{\mu\nu}u_\mathrm{ph}^\mu u_\mathrm{obj}^\nu\]
For the distant observer, the equation is the same. With the tetrad velocity \(u_\mathrm{obs}=(1,0,0,0)\) and metric
\[\begin{split} g_\mathrm{obs}= \begin{pmatrix} -1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 1 \end{pmatrix}, \end{split}\]
the energy of the photon can be simplified to
\[ E_\mathrm{obs}=u_\mathrm{ph}^0. \]

Parameters:
  • photon – 8 dimensional information of photon

  • photon_time –

Returns:

T

Particle

template<typename T>
class Particle : public sbody::Object<T>

Subclassed by sbody::Hotspot< T >, sbody::Star< T >

Public Functions

inline Particle(const Metric<T> &metric, TimeSystem time, DynamicalSystem coordinate, T absolute_accuracy, T relative_accuracy, bool fixed = false)

Construct a new star object.

Parameters:
  • metric –

  • radius – radius

  • fixed – whether the position of the star is fixed

inline bool hit(const boost::numeric::ublas::bounded_vector<T, 8> &current, const boost::numeric::ublas::bounded_vector<T, 8> &last) const override

Check if the star hit by the photon.

Parameters:
  • current –

  • last –

Returns:

bool

inline virtual T dopplerFactor(const boost::numeric::ublas::bounded_vector<T, 8> &photon, TimeSystem photon_time) const override

Return the Doppler factor \(g=1/(1+z)=E_\text{obs}/E_\text{emit}\).

Parameters:
  • photon –

  • photon_time –

Returns:

T

Star

template<typename T>
class Star : public sbody::Particle<T>

Disk

template<typename T>
class Disk : public sbody::Object<T>

Subclassed by sbody::NovikovThorneDisk< T >

Novikov-Thorne Disk

template<typename T>
class NovikovThorneDisk : public sbody::Disk<T>