Acoustic FDTD Solver
Public Member Functions | Public Attributes | List of all members
SpherePosition Class Reference

Denote a point in the spherical coordinate. More...

#include <SpherePosition.hpp>

Public Member Functions

 SpherePosition (double a, double t, double p)
 SpherePosition (double t, double p)
 Create a vector of unit length with the given angles.
CartPosition toCart ()
 Convert to the Cartesian coordinate.

Public Attributes

double r
 radial distance, $ r \ge 0 $.
double theta
 (rad) angle with respect to +Z axis, $ 0 \le \theta \le \pi $.
double phi
 (rad) angle with respect to +X axis on the XY plane, $ 0 \le \phi < 2\pi $.

Detailed Description

Denote a point in the spherical coordinate.

Constructor & Destructor Documentation

SpherePosition::SpherePosition ( double  a,
double  t,
double  p 
)
Parameters
aradial distance, $ r \ge 0 $.
ttheta (rad) angle with respect to +Z axis, $ 0 \le \theta \le \pi $.
pphi (rad) angle with respect to +X axis on the XY plane, $ 0 \le \phi < 2\pi $.
SpherePosition::SpherePosition ( double  t,
double  p 
)

Create a vector of unit length with the given angles.

Member Function Documentation

CartPosition SpherePosition::toCart ( )

Convert to the Cartesian coordinate.

Member Data Documentation

double SpherePosition::phi

(rad) angle with respect to +X axis on the XY plane, $ 0 \le \phi < 2\pi $.

double SpherePosition::r

radial distance, $ r \ge 0 $.

double SpherePosition::theta

(rad) angle with respect to +Z axis, $ 0 \le \theta \le \pi $.


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