- C++ Game Development By Example
- Siddharth Shekar
- 300字
- 2021-06-24 14:26:16
Cross product
Cross product is the other vector multiplication form in which the resultant product of the multiplication is another vector. Taking the cross product between and
vectors will result in a third vector that it is perpendicular to both vectors
and
.
If you have two vectors, = (ax, ay, az) and
= (bx, by, bz), then
. is given as follows:
= (ay bz - az by, az bx - ax bz, ax by - ay bx)
The following is a matrix and graphical implementation of the cross product between vectors:

The direction of the resultant normal vector will obey the right-hand rule, where curling the fingers in the right hand from to
will cause the thumb to point in the direction of the resultant normal vector
.
Also note that the order in which you multiply the vectors is important as if you multiply the other way around then the resultant vector will be a point in the opposite direction.
The cross product will become very useful when we want to find the normal of the face of a polygon. For example, finding the normal of the face of a triangle.
Let us find the cross product of vectors = (3, -5, 7) and
= (2, 4 , 1):
C = A × B = (ay bz - az by, az bx - ax bz, , ax by - ay bx)
= (-5 * 1 - 7*4 , 7 * 2 - 3 * 1, 3 * 4 - (-5) * 2 )
= (-5-28, 14 - 3, 12 + 10)
= (-33, 11, 22)
- Augmented Reality with Kinect
- 電腦維護與故障排除傻瓜書(Windows 10適用)
- 計算機應用與維護基礎教程
- Unity 5.x Game Development Blueprints
- 嵌入式系統中的模擬電路設計
- 基于Apache Kylin構建大數據分析平臺
- Machine Learning Solutions
- 單片機原理及應用:基于C51+Proteus仿真
- Blender Game Engine:Beginner's Guide
- FreeSWITCH Cookbook
- Mastering Machine Learning on AWS
- 單片機原理與技能訓練
- Arduino項目案例:游戲開發
- 主板維修實踐技術
- DevOps實戰:VMware管理員運維方法、工具及最佳實踐