Merge pull request #3 from omartin2010/patch-1

Mistake in returning a 3x3 of zeros in MatrixLog3

In NP, you either pass a tuple or a single integer (not multiple integers like MATLAB).
This commit is contained in:
Jarvis Schultz 2018-04-30 08:26:36 -05:00 committed by GitHub
commit 76cda23be3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -144,7 +144,7 @@ Output:
[-1.20919958, 1.20919958, 0]] [-1.20919958, 1.20919958, 0]]
''' '''
if NearZero(np.linalg.norm(R - np.eye(3))): if NearZero(np.linalg.norm(R - np.eye(3))):
return np.zeros(3,3) return np.zeros((3,3))
elif NearZero(np.trace(R) + 1): elif NearZero(np.trace(R) + 1):
if not NearZero(1 + R[2][2]): if not NearZero(1 + R[2][2]):
omg = (1.0 / sqrt(2 * (1 + R[2][2]))) \ omg = (1.0 / sqrt(2 * (1 + R[2][2]))) \