首页 > 代码库 > 向量叉乘 Cross product

向量叉乘 Cross product

参考:Wiki Cross product

技术分享

 技术分享

技术分享

Coordinate notation

The standard basis vectors i, j, and k satisfy the following equalities in a right hand coordinate system:

技术分享

which imply, by the anticommutativity of the cross product, that

技术分享

The definition of the cross product also implies that

技术分享

These equalities, together with the distributivity and linearity of the cross product (but both do not follow easily from the definition given above), are sufficient to determine the cross product of any two vectors u and v. Each vector can be defined as the sum of three orthogonal components parallel to the standard basis vectors:

技术分享

Their cross product u × v can be expanded using distributivity:

技术分享

This can be interpreted as the decomposition of u × v into the sum of nine simpler cross products involving vectors aligned with i, j, or k. Each one of these nine cross products operates on two vectors that are easy to handle as they are either parallel or orthogonal to each other. From this decomposition, by using the above-mentioned equalities and collecting similar terms, we obtain:

技术分享

meaning that the three scalar components of the resulting vector s = s1i + s2j + s3k = u × v are

技术分享

 

Using column vectors, we can represent the same result as follows:

技术分享

 

Matrix notation[edit]


Use of Sarrus‘s rule to find the cross product of u and v

The cross product can also be expressed as the formal[note 1] determinant:

技术分享

技术分享

向量叉乘 Cross product