Skip to content

Commit

Permalink
removed function that should not have been there
Browse files Browse the repository at this point in the history
  • Loading branch information
javierggt committed Sep 7, 2019
1 parent 2971311 commit 5b7541c
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions Quaternion/Quaternion.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,23 +356,6 @@ def _quat2equatorial(self):
return np.moveaxis(np.array([ra, dec, roll]), 0, -1)


def _quat2equatorial_norm(self):
q = np.atleast_2d(self.q)
q2 = q ** 2

# calculate direction cosine matrix elements from $quaternions
xa = q2[..., 0] - q2[..., 1] - q2[..., 2] + q2[..., 3]
xb = 2 * (q[..., 0] * q[..., 1] + q[..., 2] * q[..., 3])
xn = 2 * (q[..., 0] * q[..., 2] - q[..., 1] * q[..., 3])
yn = 2 * (q[..., 1] * q[..., 2] + q[..., 0] * q[..., 3])
zn = q2[..., 3] + q2[..., 2] - q2[..., 0] - q2[..., 1]

# Due to numerical precision this can go negative. Allow *slightly* negative
# values but raise an exception otherwise.
one_minus_xn2 = 1 - xn**2
return one_minus_xn2


# _quat2transform is largely from Enthought's quaternion.rotmat, though this math is
# probably from Hamilton.
# License included for completeness
Expand Down

0 comments on commit 5b7541c

Please sign in to comment.