設有兩向量:A、B
C=A╳B
在MATLAB可用下面的方法實現:
C=cross(A,B) 本法限A、B兩向量為三度空間向量
cross - A and B must have at least one dimension of length 3.
C=A.B
在MATLAB可用下面的方法實現:
C=dot(A,B) 本法A、B長度不限,但是兩者長度必需相同
dot - A and B must be vectors of the same length.