harmonica.TriaxialEllipsoid#

class harmonica.TriaxialEllipsoid(a, b, c, yaw, pitch, roll, center, *, density=None, susceptibility=None, remanent_mag=None)[source]#

Triaxial ellipsoid with arbitrary orientation.

Define a triaxial ellipsoid whose semi-axes lengths are a > b > c.

Parameters:
a, b, cfloat

Semi-axis lengths of the ellipsoid. Must satisfy the condition: a > b > c.

yawfloat

Rotation angle about the upward axis, in degrees.

pitchfloat

Rotation angle about the northing axis (after yaw rotation), in degrees. A positive pitch angle lifts the side of the ellipsoid pointing in easting direction.

rollfloat

Rotation angle about the easting axis (after yaw and pitch rotation), in degrees.

centertuple of float

Coordinates of the center of the ellipsoid in the following order: easting, northing, upward.

densityfloat or None, optional

Density of the ellipsoid in \(kg/m^3\).

susceptibilityfloat, (3, 3) array or None, optional

Magnetic susceptibility of the ellipsoid in SI units. A single float represents isotropic susceptibility in the body. A (3, 3) array represents the susceptibility tensor to account for anisotropy. If None, zero susceptibility will be assigned to the ellipsoid.

remanent_mag(3,) array or None, optional

Remanent magnetization vector of the ellipsoid in A/m units. Its components are defined in the easting-northing-upward coordinate system and should be passed in that order. If None, no remanent magnetization will be assigned to the ellipsoid.

Notes

The three semi-axes a, b, and c are defined parallel to the easting, northing and upward directions, respectively, before applying any rotation.

Rotations directed by yaw and roll are applied using the right-hand rule across their respective axes. Pitch rotations are carried out in the opposite direction, so a positive pitch lifts the side of the ellipsoid pointing in the easting direction.

Attributes:
a

Length of the first semiaxis.

b

Length of the second semiaxis.

c

Length of the third semiaxis.

density

Density of the ellipsoid in \(kg/m^3\).

remanent_mag

Remanent magnetization of the ellipsoid in A/m.

rotation_matrix

Create a rotation matrix for the ellipsoid.

susceptibility

Magnetic susceptibility of the ellipsoid in SI units.

Attributes#

TriaxialEllipsoid.a#

Length of the first semiaxis.

TriaxialEllipsoid.b#

Length of the second semiaxis.

TriaxialEllipsoid.c#

Length of the third semiaxis.

TriaxialEllipsoid.density#

Density of the ellipsoid in \(kg/m^3\).

TriaxialEllipsoid.remanent_mag#

Remanent magnetization of the ellipsoid in A/m.

TriaxialEllipsoid.rotation_matrix#

Create a rotation matrix for the ellipsoid.

Use this matrix to rotate from the local coordinate system (centered in the ellipsoid center) in to the global coordinate system (easting, northing, upward).

Returns:
rotation_matrix(3, 3) array

Rotation matrix that transforms coordinates from the local ellipsoid-aligned coordinate system to the global coordinate system.

Notes

Generate the rotation matrix from Tait-Bryan intrinsic angles: yaw, pitch, and roll. The rotations are applied in the following order: (ZŶX). Yaw (Z) and roll (X) rotations are done using the right-hand rule. Rotations for the pitch (Ŷ) are carried out in the opposite direction, so positive pitch lifts the easting axis.

TriaxialEllipsoid.susceptibility#

Magnetic susceptibility of the ellipsoid in SI units.

TriaxialEllipsoid.yaw#
TriaxialEllipsoid.pitch#
TriaxialEllipsoid.roll#