'Returns the cross product of this Vector with another Vector or
Dyadic instance.
The cross product is a Vector, if \'other\' is a Vector. If \'other\'
is a Dyadic, this returns a Dyadic instance.
Parameters
other: Vector/Dyadic
The Vector or Dyadic we are crossing with.
Examples
>>> from sympy.vector import CoordSys3D
>>> C = CoordSys3D(\'C\')
>>> C.i.cross(C.j)
C.k
>>> C.i ^ C.i
0
>>> v = 3*C.i + 4*C.j + 5*C.k
>>> v ^ C.i
5*C.j + (-4)*C.k
>>> d = C.i.outer(C.i)
>>> C.j.cross(d)
(-1)*(C.k|C.i)'

def cross(self, other):

    if isinstance(other, Dyadic):
        if isinstance(self, VectorZero):
            return Dyadic.zero
        outdyad = Dyadic.zero
        for (k, v) in other.components.items():
            cross_product = self.cross(k.args[0])
            outer = cross_product.outer(k.args[1])
            outdyad += (v * outer)
        return outdyad
    elif (not isinstance(other, Vector)):
        raise TypeError((str(other) + '    is    not    a    vector'))
    elif (isinstance(self, VectorZero) or isinstance(other, VectorZero)):
        return Vector.zero
    outvec = Vector.zero
    for (system, vect) in other.separate().items():
        tempm = [[system.i, system.j, system.k], [(self & system.i), (self & system.j), (self & system.k)], [(vect & system.i), (vect & system.j), (vect & system.k)]]
        outvec += det(Matrix(tempm))
    return outvec
