a,b | In simplest usage, a and b are two 2- or 3-element vectors. They can also be arrays of vectors (i.e. two-dimensional matrices). If a is an array and 'b' is a vector, cross(a,b) returns an array whose elements are the cross products of each vector in a with the vector b . The b is an array and a is a single vector, cross(a,b) returns an array whose elements are the cross products of a with each vector in b . a and b can both be arrays if they have the same shape. In this case, cross(a,b) returns cross(a[0],b[0]), cross(a[1], b[1]), ... |
axisa/b | If a is an array, it can have vectors laid out across the most quickly varying axis, the slowest varying axis, or something in between. axisa tells cross() how the vectors are laid out in a . By default, it takes the value of the most slowly varying axis. axisb works the same with input b . If the output of cross() is going to be an array, the output vectors can be laid out different array axes; axisc tells cross how to lay out the vectors in its output array. By default, axisc indicates the most slowly varying axis. |
axis | A convenience parameter that sets axisa , axisb , and axisc all to the same value if desired. If axis and any of the other parameters are present in the call, the value of axis will override the other values. |