QPMS
Electromagnetic multiple scattering library and toolkit.
Coordinate systems and default conversions

The coordinate system transformations are defined as following:

Equal-dimension coordinate tranforms

Spherical and 3D cartesian coordinates

  • \( x = r \sin \theta \cos \phi \),
  • \( y = r \sin \theta \sin \phi \),
  • \( z = r \cos \theta \).

Polar and 2D cartesian coordinates

  • \( x = r \cos \phi \),
  • \( y = r \sin \phi \).

Lower to higher dimension conversions.

  • The 1D coordinate is identified with the z 3D cartesian coordinate.
  • The 2D cartesian coordinates x, y are identified with the x, y 3D cartesian coordinates.
  • For the sake of consistency, default conversion between 1D and 2D coordinates is not allowed and yields NAN values.

Higher to lower dimension conversions.

Default conversions from higher to lower-dimensional coordinate systems are not allowed. Any projections have to be done explicitly.