The cross or outer product a × b of two vectors a and b is defined only whenever both a and b are the vectors in three-dimensional space, that means that they both should have 3 elements. It can be defined as the matrix multiplication of a matrix composed from the elements from a in a specific manner as shown here and in the column vector b.
The MATLAB has a built-in function cross to accomplish this.
>> vec1 = [4 2 5 ];
>> vec2 = [3 6 1 ];
-28 11 18