chaosmagpy.coordinate_utils.spherical_to_cartesian

chaosmagpy.coordinate_utils.spherical_to_cartesian(radius, theta, phi)[source]

Convert spherical to cartesian coordinates.

Parameters
radiusfloat or ndarray, shape (…)

Radius.

thetafloat or ndarray, shape (…)

Colatitude in degrees.

phifloat or ndarray, shape (…)

Longitude in degrees.

Returns
x, y, zfloat or ndarray, shape(…)

Cartesian coordinates.