cpp/motions/coordinates.h

24 lines
404 B
C
Raw Permalink Normal View History

2024-08-23 16:33:38 +00:00
//
// Created by dominik on 8/22/24.
//
#ifndef COORDINATES_H
#define COORDINATES_H
struct SphericalPos {
double cos_theta;
double phi;
};
struct CartesianPos {
double x;
double y;
double z;
};
SphericalPos rotate(const SphericalPos&, double, double);
CartesianPos spherical_to_xyz(const SphericalPos&);
SphericalPos xyz_to_spherical(const CartesianPos&);
#endif //COORDINATES_H