bfieldtools.sphtools.sphvec2cart¶
-
bfieldtools.sphtools.
sphvec2cart
(sp, vec)¶ Transforms cartesian vector to spherical coordinates.
- Parameters
- sp: Nx3 array
spherical coordinates [r, theta, phi]
- vec: Nx3 array
vector in spherical coordinates [e_r, e_theta, e_phi]
- Returns
- svec: Nx3 array
vector in cartesian coordinates [e_x, e_y, e_z]