vector operation
Section 1: zero vector
The concept of 1. zero vector
For any vector x, if x+y=x, then x is called zero vector. For example, the 3D zero vector is [0000]. The zero vector is very special because it is the only vector with zero size and the only vector without direction.
Part II: Negative Vector
The concept of 1. negative vector
For vector x, if x+(-x)=0, then -x is a negative vector.
2. Negative vector algorithm
If this rule applies to 2D, 3D and 4D, then
-[x y]=[-x y]
-[x y z] = [-x -y -z]
-[w x y z] = [-w -x -y -z]
3. Geometric interpretation of negative vectors
A negative vector means that you will get a vector equal in size and opposite in direction to the original vector.
Section 3: Modulus of Vector
The concept of 1. vector module
The so-called vector module is the size or length of the pointing quantity.
2. Vector modular operation
In linear algebra, the modulus of a vector is usually represented by two vertical lines on both sides of the vector, such as ||| v ||| |, which represents the modulus of the vector V. The formula for calculating the modulus of the vector is as follows:
For 2D, the 3D vectors are as follows
Section 4: Operation of Scalar and Vector
1. algorithm
Scalar and vector can not be added or subtracted, but they can be multiplied. As for the division of scalar and vector, it can be regarded as multiplication by reciprocal.
For 2D, the 3D vectors are as follows
2. Geometric interpretation
Multiplying a vector by a scalar or dividing it by a scalar is equivalent to scaling the length of the vector by a factor k.
Section 5: Standardized Vector
1. The concept of normalized vector
The so-called standardized vector is the unit vector, that is, the vector with the length of 1. Sometimes called normal.
2. Algorithm
For any non-zero vector v, the unit vector n in the same direction as v can be calculated. This process is called "standardization" of vectors. To standardize a vector, just divide it by its size (modulus).
Section 6: Addition and subtraction of vectors
1. Preconditions of vector addition and subtraction
If the dimensions of the two vectors are the same, you can add and subtract, and the dimension of the resulting vector is the same as the original vector.
2. Algorithm
The addition of vectors is equal to the addition of components of two vectors, and the subtraction of vectors is equal to adding a negative vector.
3. Geometric interpretation
The addition and subtraction of vectors leads to the triangle rule, that is, the ends of vectors will be connected to get the result of addition, as follows
Section 7: Distance Formula
Derivation of 1. distance formula
Through the triangle principle above, we can find that the third vector can be obtained by adding and subtracting two vectors. We reverse this process. If we know the distance between two points, how to find the distance can be achieved by subtracting the vector.
2. Operation formula
In 3D, two points A and B are known. Find the distance d between two points? We can regard two points A and B as vectors, then b-a is vector D, and then we can calculate the modulus of vector D as the distance between two points.
After finding the vector d, the modulus of d is the distance between two points.
Section 8: Point multiplication of vectors
1. Basic concepts
Scalars can be multiplied by vectors, and vectors can also be multiplied by vectors. This is called dot multiplication, also called inner product. Scalar multiplication with vector cannot be written, vector multiplication with vector must be written, and vector multiplication with dot has higher priority than vector addition and subtraction. Note: the result of vector point multiplication is scalar.
2. Algorithm
Note: the result of vector point multiplication is scalar, not vector.
Applied to 2D, 3D is
a b = axbx? +? Abby
a b = axbx? +? ayby+? azbz
3. Geometric interpretation
The point multiplication of vectors describes the similarity of two vectors, that is, the size of the included angle between the two vectors.
The set operation method of vector point multiplication is as follows. The result of vector point multiplication is related to cos function. When two vectors are perpendicular, the result of vector point multiplication is 0.
Section 9: Projection of Vector
1. Basic concepts
Given two vectors V and N, V can be decomposed into two components, one perpendicular to the vector N and the other parallel to the vector N. The vector parallel to the vector N is called the projection on the vector N. ..
2. The solution of projection
Because the vector n is parallel to the projection vector, you can find the unit vector of the vector n and multiply it by the module of the projection to get the projection vector, as follows
Then we can find the projected module. We can calculate the modulus of projection according to the cosine formula of trigonometric function.
The projection vector can be obtained by replacing the module of the projection.
3. The solution of vertical vector
According to the triangle rule, the vertical vector can be easily found.
Section 10: Cross multiplication of vectors
1. Basic concepts
The cross product of two vectors is a vector, which is perpendicular to the original two vectors. The cross product of vectors can only be used for 3D vectors.
2. Mathematical operation formula
3. Geometric operation formula
The length of the result vector of vector cross product is related to the included angle between the two vectors, which is a sine function relationship. If vectors A and B are parallel, the result of cross product is 0, because sin0 is 0.
4. Judgment of vector crossing direction
The direction of the result vector is judged by the right-hand rule. Stretch out your right hand, and the four fingers bend in the same order as the vector cross, so the thumb is the direction of the result vector after the cross. As shown in the following figure axb, the bending direction of the four fingers of the right hand is from A to B, and the upward direction of the thumb is the direction of the cross product result vector.