added flexibility
This commit is contained in:
20
src/motions/coordinates.h
Normal file
20
src/motions/coordinates.h
Normal file
@@ -0,0 +1,20 @@
|
||||
|
||||
#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
|
||||
Reference in New Issue
Block a user