Welcome to ROSMASTER R2 repository
14.3. 4WD
14.3. Kinematic analysis of 4WD carts
14.3. Kinematic analysis of 4WD carts14.3.1. Limitations14.3.2 Kinematic modeling14.3.3. Kinematic Analysis
14.3.1. Limitations
This section will analyze the kinematic equations of a four-wheeled vehicle from the kinematic aspects of the four-wheeled vehicle, due to the existence of structural errors in the real car, in the process of movement will be resistance and friction and other factors, more complex, for simplicity, here is only limited to the four-wheeled vehicle is in an ideal state to do the analysis.
14.3.2 Kinematic modeling
The four-wheel drive vehicle is abstracted as the following model, in which W represents the interval between the center points of the left and right motors; L represents the interval between the center points of the front and rear motors; motors M1, M2, M3 and M4 represent the four drive motors of the vehicle; V represents the linear speed (forward and backward speed) of the vehicle, and ω represents the angular speed (rotational speed) of the vehicle.
Ideally it is by controlling the linear velocity V and angular velocity ω, which translates into controlling the four motors, thus controlling the four-drive cart motion.

14.3.3. Kinematic Analysis
Let V~m1~, V~m2~, V~m3~, V~m4~ be the speed values of the motors M1, M2, M3, M4, that is, the rotational speed of the wheels, V~x~ is the linear speed of the cart, V~x~ is positive for forward, V~x~ is negative for backward, V~z~ is the angular speed of the cart, V~z~ is positive for left, V~z~ is negative for right, A is half of the distance W of the left and right motor center of the cart A=$\frac{W}{2}$, B is half of the distance L of the front and back motor center of the cart B=$$$$. A is half of the distance W A=$\frac{W}{2}$, B is half of the distance L between the front and rear motor centers of the cart B=$\frac{L}{2}$.
When the trolley moves forward or backward
V~m1~=V~x~
V~m2~=V~x~
V~m3~=V~x~
V~m4~=V~x~
When the cart is rotating around the geometric center point
V~m1~=-V~z~*(A+B)
V~m2~=-V~z~*(A+B)
V~m3~=V~z~*(A+B)
V~m4~=V~z~*(A+B)
According to the above equation, we can get
V~m1~=V~x~-V~z~*(A+B)
V~m2~=V~x~-V~z~*(A+B)
V~m3~=V~x~+V~z~*(A+B)
V~m4~=V~x~+V~z~*(A+B)