NumCpp  2.18.0
A Templatized Header Only C++ Implementation of the Python NumPy Library
Loading...
Searching...
No Matches
sph2cart.hpp
Go to the documentation of this file.
1
28#pragma once
29
32
34{
41 [[nodiscard]] inline Cartesian sph2cart(const reference_frames::AER& aer) noexcept
42 {
43 const auto rCosEl = aer.range * std::cos(aer.el);
44 const auto x = rCosEl * std::cos(aer.az);
45 const auto y = rCosEl * std::sin(aer.az);
46 const auto z = aer.range * std::sin(aer.el);
47 return Cartesian{ x, y, z };
48 }
49} // namespace nc::coordinates::transforms
Cartensian coordinates.
Definition Cartesian.hpp:44
Az, El, Range coordinates.
Definition AER.hpp:43
Definition AERtoECEF.hpp:38
Cartesian sph2cart(const reference_frames::AER &aer) noexcept
Converts spherical coordinates to cartesian coordinates.
Definition sph2cart.hpp:41