Week 7 Challenge
Load the vehicle parameters. Complete the vehicle model by modelling the remaining equations. Set simulation stop time to 598 sec.
The output should be the vehicle velocity.
Answer:-
VEHICLE MODEL IN MATLAB SIMULINK:
Vehicle model here is nothing but the equations of forces which comes under vehicle dynamics i.e when vehicle moves from its rest position. For motorized vehicles, such as automobiles, aircraft, and watercraft, vehicle dynamics is the study of vehicle motion, e.g., how a vehicle's forward movement changes in response to driver inputs, propulsion system outputs, ambient conditions, air/surface/water conditions, etc. Below image shows the force acting on a vehicle.
Where
- Ftr-tractive force;
- Fa-aerodynamic drag resistance force;
- Fg-gradient resistance force;
- Fr-rolling resistance force;
- Fi-inertial resistance force
Tractive force is the force applied/produced by the vehicle powertrain. We will now see the equations of three main forces (aero, rolling and gradient) and will implement this using matlab Fcn block.
Aero dynamic drag: Aerodynamic Drag is a force which the oncoming air applies on a moving body. It is the resistance offered by the air to the movement of the body. So, when a car is moving; it displaces the air. However, it affects the car’s speed and performance. Technically, it is the aerodynamic drag or the friction offered by the air to a vehicle.

Rolling resistance force: Rolling resistance is the combination of forces that work against the forward motion of your vehicle. The weight of the vehicle, gravity and inertia, the amount of friction between the tires and the road surface, and air drag all play a part. When you coast in your car or on a bike, rolling resistance is what slows you down. The more rolling resistance, the more power it takes to propel a vehicle.

Gradient/uphill/climbing force: When the vehicle travels uphill, a component of its weight works in a direction opposite to its motion. If some energy is not supplied to overcome this backward force, then the vehicle would slow down, stall and roll backwards.

Force of acceleration: The acceleration force refers to the vehicle’s resistance to speed variations. This force holds you back when you increase your speed and also moves you forward when you slow down. In other words, it means that you consume energy to accelerate up to a certain speed but can recover part of that energy when you decelerate, allowing you to drive a certain distance without consuming fuel. In equations it is simply written as:
F=m*a (where m is the mass of object(vehicle) and a is acceleration)
Matlab Model:-

Driver Block:-

Vehicle Model:-

Parmaters:-
%Parameters for total force
Veh_m=1000;
g=9.81;
Veh_roll_coeff=0.015;
air_den=1.25;
drag_coeff=0.33;
front_area=2.8151;
Result:-

Conclusion:-
Here we have simulated the the driver and vehicle model. We have prepared the mathematical model for the various forces acting on a vehicle. Also the PID controller has been simulated for the desired output velocity. Actual velocity has been compared with the drive source which is a FTP drive cycle.