geometric/internal.py
def d_ncross(a, b):
    """
    Return the gradient of the norm of the cross product w/r.t. a
    """
    ncross = np.linalg.norm(np.cross(a, b))
    term1 = a * np.dot(b, b)
    term2 = -b * np.dot(a, b)
    answer = (term1+term2)/ncross
    return answer

    Return the gradient of the norm of the cross product w/r.t. a
    
Return the gradient of the norm of the cross product w/r.t. a
Return the gradient of the norm of the cross product w / r . t . a
def d_ncross(a, b):
    ncross = np.linalg.norm(np.cross(a, b))
    term1 = a * np.dot(b, b)
    term2 = -b * np.dot(a, b)
    answer = (term1+term2)/ncross
    return answer
def d_ncross ( a , b ) : ncross = np . linalg . norm ( np . cross ( a , b ) ) term1 = a * np . dot ( b , b ) term2 = - b * np . dot ( a , b ) answer = ( term1 + term2 ) / ncross return answer
Return the gradient of the norm of the cross product w/r.t.
Return the gradient of the norm of the cross product w / r . t .
"""
    Return the gradient of the norm of the cross product w/r.t. a
    """
a
b