Skip to content

Commit

Permalink
fix: incorrect indexing for FDI grad constraints
Browse files Browse the repository at this point in the history
  • Loading branch information
Lachlan Grose committed Oct 7, 2021
1 parent a7664d2 commit d6b8280
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ def add_gradient_constraints(self, w=1.):
# normalise constraint vector and scale element matrix by this
norm = np.linalg.norm(points[:,3:6],axis=1)
points[:,3:6]/=norm[:,None]
T/=norm[:,None,None]
T/=norm[inside,None,None]
# calculate two orthogonal vectors to constraint (strike and dip vector)
strike_vector, dip_vector = get_vectors(points[inside, 3:6])
A = np.einsum('ij,ijk->ik', strike_vector.T, T)
Expand Down

0 comments on commit d6b8280

Please sign in to comment.