In this repository I'll be implemeting the kinematic bicycle model for the 4-Wheel vehicles with front steering and rear steering in Pyhton class Object. And I'm going to test this model by changing different parameters of the vehicle like the steering angle and speed to see how the model will behave in these cases. For the visualization of the output I'll use ROS simulator "turtlesim".
You can find the dimensions of the car (The distance between CG and front wheel, The distance between CG and back wheel) in the "data.yaml" file in config folder.
You can also find launch file for both front and rear steering cases.
So, Let's start.
Starting with the front steering model We will consider the point to be analyzed on the vehicle is at its center of gravity. Knowing that all point on the vehicle moves about the Instantaneous Center of Rotation ( ICR ).
In the image above you can find the geometry of the model which I relied on to derive all the following equations.
- Steering angle
$\delta$ - Vehicle velocity
$v$ - time of simulation
$t$ -
$l_r$ from yaml file
-
velocity = 5
-
steering angle = 30
$degrees$ -
simulation time = 5
$seconds$ -
Video:
front_without_decay.1.mp4
here I added a new feature to me model where the steering angle is not constant instead it's deacing with time until it gets to zero and the vehicle moves in straight line.
- Video:
front_with_decay.2.mp4
Rear steering is the same like front steering but the difference is that the rear wheels are the moving ones. you can notice that for the same input the front and rear steering mechanisms will behave opposite to each others.
- Steering angle
$\delta$ - Vehicle velocity
$v$ - time of simulation
$t$ -
$l_f$ from yaml file
- velocity = 5
- steering angle = 30
$degrees$ - simulation time = 5
$seconds$
-Video:
rear_without_decay.1.mp4
- Video:
rear_with_decay.1.mp4
That's all, Hope you found this useful. Thank you for reading :)