geometric/internal.py
def d_cross(a, b):
    """
    Given two vectors a and b, return the gradient of the cross product axb w/r.t. a.
    (Note that the answer is independent of a.)
    Derivative is on the first axis.
    """
    d_cross = np.zeros((3, 3), dtype=float)
    for i in range(3):
        ei = np.zeros(3, dtype=float)
        ei[i] = 1.0
        d_cross[i] = np.cross(ei, b)
    return d_cross

    Given two vectors a and b, return the gradient of the cross product axb w/r.t. a.
    (Note that the answer is independent of a.)
    Derivative is on the first axis.
    
Given two vectors a and b, return the gradient of the cross product axb w/r.t. a.
(Note that the answer is independent of a.)
Derivative is on the first axis.
Given two vectors a and b return the gradient of the cross product axb w / r . t . a . ( Note that the answer is independent of a . ) Derivative is on the first axis .
def d_cross(a, b):
    d_cross = np.zeros((3, 3), dtype=float)
    for i in range(3):
        ei = np.zeros(3, dtype=float)
        ei[i] = 1.0
        d_cross[i] = np.cross(ei, b)
    return d_cross
def d_cross ( a , b ) : d_cross = np . zeros ( ( 3 , 3 ) , dtype = float ) for i in range ( 3 ) : ei = np . zeros ( 3 , dtype = float ) ei [ i ] = 1.0 d_cross [ i ] = np . cross ( ei , b ) return d_cross
Given two vectors a and b, return the gradient of the cross product axb w/r.t.
Given two vectors a and b return the gradient of the cross product axb w / r . t .
"""
    Given two vectors a and b, return the gradient of the cross product axb w/r.t. a.
    (Note that the answer is independent of a.)
    Derivative is on the first axis.
    """
a
b