Challenge

Project 1

OBJECTIVES-

The main objective development of a forward energy-based fuel consumption model of a conventional vehicle.The main goal of this project is to get familiar with the modeling process, writing scripts in Matlab, modeling in Simulink, analyzing data and generating plots

1) Modify the “Project1_ProcessingFile.m” as per the desired plots and required calculations.
2) Write a project report that contains the following:

a. Tabulate the fuel economy numbers (kmpl) for UDDS and HWFET cycle. This forms the baseline numbers for comparing with the future hybrid version.
b. Plot the time trace for engine, transmission input, transmission output and wheel speed on one plot.
c. Plot engine torque, engine power, fuel rate and fuel consumption using subplots.
d. Plot accelerator and brake pedal, gear command, vehicle desired and actual speed, vehicle distance using subplots.
e. Plot the engine operating points on the engine fuel map.
f. Write down appropriate brief comments on each of these plots, describing the vehicle behavior throughout the drive cycle.
g. Generate the plots for both drive cycles

conventional vehicle:
conventional vehicle use an internal combustion engine fuelled by gasline or diesel,to power the wheel.in this the heat engine uses the principle of heat release through combustion of fuel with an oxidizer in a combustion chamber to create expanding gases which pushes against a piston creating force and torque output.

In the internal combustion (IC) engines,chemical engines,chemical energy of fuel is converted in to the heat energy to produce useful mechanical work.mostly uses fossil fuel like petroleum(petrol and diesel).

The most comman type of engine are 4 strock reciprocating engines.The internal combustion or conventional vehicle is operated basedon the idel thermodynamic cycle such as otto cycle, diesel cycle, over expanded cycle and etc.


Energy and performance of the vehicle:
In this system,the power is supplied from the powertrain to wheel to operate the vehicle .In other words,the power coming from the powertrain dictates the power demand on the wheel (as per performance viz,acceleration,speed and etc.is determined by it).

In this type of vehicle the powertrain consists of an engine connected to the wheels through the transmission and differential,therfore the power/energy is transimission to the wheels.

CONVENTIONAL POWERTRAIN EFFICIENCY:-
=> The engine generates power by converting chemical energy stored in the liqued fuel into mechanical energy by the into mechanical energy by the process of combustion.This process of energy conversion also has an efficiency `eta_(e)` and the energy inputs is in the form of fuel consumption
=> for a conventional IC engine vehicle the wheel power is supplied by the engine through the trabnsimission drivetrain efficency
=> Instantanous fuel consumption is given as
`M_(f)=frac{P_(w)}{eta_(e)eta_(t)Q_(LHV)}`
where,
Mf=mass flow rate [kg]
Pe=power of engine
Pt=power transmission
`eta_(e)`=efficiency of transmission
`eta_(t)`=efficiency of engine
QLHV=lower heat value/the calorific value

The internal combustion engines consume the power even if the vehicle is in idle position,to overcome the engine drag loss and keep it spinning this is the idling fuel consumption and know as idling process.The fuel consumption is not only depending on the power requirement at the wheels,the engine consume the power to run the different components of the vehicle.

system dynamics:
The system dynamics deals with the modeling domain system through the use of a unfied approach based on an ordinary differential and algebraic equation describing the static and dynamic effects.
Generally each system has three variables those are efforts,flow and power.
1.Efforts:It is generalized force variable[Ex.Torque,force,voltage,heating value and etc.]
2.Flow:It is the generalized flow/velocity variables[Ex.velocity,mass flow rate and ect.]
3.power:It is the product of the effort and flow variable.It is interchangeable between the energy domains.
Energy based models-Element model:
To model the internal physical properties of the element and the losses,there are two kinds of approaches,those are map based model models and analytical models.

1.map based models:
Elements are modelsed using maps,which characterize the relationship between the input & output and output 7 losses etc.
2.analytical models:
Elements are ,modeled using phisical equations thaT Represent the internal dyanamics

Different types of efficiencies:
*Mechanical efficiency:
It is the ratio of brake power(B.P) to the indicated power (I.P).
*Overall efficiency:
It is the ratio of work obtained at the crankshaft in a given time to the energy supplied by the fuel during same time .
*Indicated thermal efficency:
It is the ratio of the heat equivalent to one kw-hr to the heat in the fuel per I.P hr.
*Brake thermal efficiency:
It is the ratio of the heat equivalent to one kw-hr to the heat in the fuel per b.p hr.
*volumetric efficiency efficiency:
It is the ratio of the actual volume of charge adimitted during the suction strock at N.T.P to the swept volume of the position.

MATLAB PROGRAM-

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Skill-Lync -> Hybrid Drives Development
% Project 1 - Conventional Vehicle Model
% By - Ullekh Gambhira 

% Description:

%% Initialization File
% Initialization file for loading the variables for the Conventional vehicle simulation model

%% Vehicle Parameters
M = 1500;       % Vehicle weight [kg]
Cr = 0.015;     % Rolling resistance coefficient
Rw = 0.35;      % Rolling radius [m]
Cd = 0.33;      % Drag coefficient
Af = 2;         % Frontal area [m2]
rhoa = 1.225;   % Air density [kg/m3]
Vwind = 0;      % Wind velocity [kmph]
g = 9.81;       % Gravitational acceleration [m/s2]
theta = 0;      % Slope [deg]
myu_road_tire = 1; % Coefficient of friction between tire - road interface

%% Powertrain Parameters 
FDR = 3.73;                         % Final Drive Ratio / Diff Ratio
DiffEff = 0.99;                     % Differential efficiency (assumed independent of operating conditions)

NumGear = 4;                        % Number of gears in transmission
TransGear = [1:NumGear];            % Transmission Gears
TransRatio = [3.06, 1.62, 1, 0.7];  % Corresponding Transmission ratios
TransEff = 0.90;                    % Transmission efficiency (assumed independent of operating conditions)

TC_SR = [0, .5, .6, .7, .8, .87, .92, .94, .96, .97, 1];   % Torque Converter Speed Ratio (Matlab default) -> TurbSpd/PumpSpd  
TC_TR = [2.232, 1.5462, 1.4058, 1.2746, 1.1528, 1.0732, 1.0192, 1, 1, 1, 1];   % Torque Converter Torque Ratio (Matlab default) -> TurbTrq/PumpTrq
TC_Cf = 1e-4 * [.72558, .66322, .63463, .59042, .51331, .4144, .29287, .22444, .12186, .04386, 0]; % Torque Converter Capacity Factor (Matlab default) -> PumpTrq/PumpSpd^2 [Nm/rpm^2]

load Vehicle_Data/Engine_data_1_9L_Saturn_95kW
load Vehicle_Data/Trans_Shift_map

%% Driver Parameters
Kp = 10;                    % P gain for driver PI model
Ki = 1;                     % I gain for driver PI model
Drive_Cycle_Select = 2;     % Drive cycle selection

% Drive cycle values in m/s

if Drive_Cycle_Select == 1
    load DriveCycles/UDDS;
    
elseif Drive_Cycle_Select == 2
    load DriveCycles/HWFET;
    
elseif Drive_Cycle_Select == 3
    load DriveCycles/FTP;
    
elseif Drive_Cycle_Select == 4
    load DriveCycles/US06;
    
elseif Drive_Cycle_Select == 5
    load DriveCycles/NEDC;
    
elseif Drive_Cycle_Select == 6
    load DriveCycles/WLTP;
 
end

time_end = cyc_time(end);
vel_end = cyc_vel(end);

* The above MATLAB program is used to load the requried variables to run the simulink and from post processing.

* The drive cycle selection also done here,before run the simulink vehicle model run this initialization script.

* The program developed has the capability to simulate the vehicle on differentn rive cycle like UDDS,HWFET,FTP,NEDC and ect.

The simulink model:

In this project, a typical midsize car with a 1.9L engine and a 4-speed automatic transmission is considered. Data is taken from ADVISOR data base developed by NREL, USA. Transmission shift map and controller is taken from Matlab/Simulink example database.

>>Vehicle model:

>>Driver model-

The driver block is a basic Pl controller that generates accelerator and brake pedal outputs to match the desired & actual vehicle speed.The feedback loop is connected to this driver block form the powertrain block.The feedback loop is used to optimize the vehicle speed and other perameters.

scope block graphs for driver model:

for UDDS drive cycle

for HWFET drive cycle

>>Controller model:

The controller block is main component of the vehicle model,it has 3 electronic control units engine control unit,Transmission control unit and brake control unit.All 3 electronic control unit are connected to single scope,to visualize and understand the performance of the controller model.

scope block graphs for controller model:

For UDDs drive cycle

For HWFET drive cycle

>>Engine control unit

In this engine control unit,used 2 look up tables to input the maximum and minimum torque values.The input for the look up tables are fed through the Engspd goto block,the engine speed also given to ideal control speed to integrate from this to meet the output of the engine required torque.The engine control unit has a subsystem called ideal speed controller

scope block graphs for transmission control unit:

for UDDS drive cycle

for HWFET drive cycle

>>Trasmission control unit

The Transmission control unit fed with the 2 inputs (acceleration and the velocity).in the transmission control unit the shift logic is used for controlling the gear as in ther ascending ans decending order wrt time,speed and distance.

>>Brake control unit model

The brake control unit fed with an input of brake data.In this brake control unit,the brake torque is calucated.

>>Powertrain model

The powertrain is the model that encompasses every components that converts the power from the engine into mechanical movement.this powertrain model has engine ,Transmission,differantial,wheels,vehicle dynamics blocks.from this powertrain block a feedback loop is connected to the driver block to chek the different parameters performance and to optimize the vehicle movement,the scope block is connected after the engine block to chek the output from the engine is connectyed to the transimission block.

The below scope block is connected after the engine block in the powertrain model,

for UDDS drive cycle

for HWFET drive cycle

>>Engine block-

In this engine block the map based models are to model the fuel consuption of the engine.it is based on maximum torque and minimum torqueof the controller.In this model L have used the look up tables to input the Torque data,and the mim torque,max torque and the engtrqReq block is connected to the dyanamic saturation input block and the output from the dyanamic saturation block is connected to engtrq block(the output of the engine block)and to 2d look up table (2D look up table get fed the inputs from the dyanamic saturation block and the min torque data).The output from the 2d look up table is connected to the saturation block to get the engine fuel rate,and then connected to integrator block to get the fuel consumption.

scope block graphs for engine model:

for UDDS drive cycle

for HWFET drive cycle

>>Transmission model

The transmission block takes the input from the engine block (engine torque),the gear selector from controller for transmission of gear ratio,the gear ration is multiplied by the transmission input torque.the output from the torque converter block is connected to the product block to get the transmission out torque

scope block graphs for Transmission model:

for UDDS drive cycle

for HWFET drive cycle

>>Torque converter

scope block graphs for Transmission model:

for UDDS drive cycle

for HWFET drive cycle

>>Differential model

In this differential model,the input are fed with the output block of the transmission model (Transouttrq).This input is multipues with the differential ratio, the differential ratio,the differential ratio get multiplied with output and input torque to get the axle torque.The differential ratio and the transmission torque are greater than the axle torque.

>>wheels model

For the wheel model the input is axle torque and brake torque the axle torque is the differential model output and the brake torque control unit.these inputs are suntracted and the outtput is get multipliedwith rolling radius to get the force .The rolling radius and velocity are multipulied to get the wheel speed

>>vehicle dyanamics model

The vehicle dynamics model takes the tractive force as an input.The vehicle dyanamices dictates the vehicle speed based on the trcative force and road load.The below equation is used for calucating the road load the equation is

`M_(eq)frac{dVveh}{dt}=frac{etatlambda}{Rw}*Tm-(frac{1}{2}*rhoa*Af*Cd(Vveh+Vw)^2+Cr*Mgcostheta+Mgsintheta`

where,

`rhoa`=Air density`[frac{kg}{m^3}]`

Af=Frontal area `[m^2]`

Cd=drag coefficient

`V_(veh)`=velocity of vehicle`[frac{m}{s}]`

`V_(w)`=velocity of wind (or) Head wind`[frac{m}{s}]`

Cr=rolling resistsnce coefficent

M=Mass [kg]

g=gravitational force

`theta`=-angel (or) grade

He output from the road load is connected to an add block another inputs for add block is tractive force,The mass and sum of tactive force force & road load is connected to the divide block to get acceleration ,the divide block is connected to interegrtor block to get vehicle speed,.The integrator is connected to one more integrtor block to know the vehicle distance.The output velocity is connected to the driver block as an inuput.

scope block graphs for vehical dyanamics:

for UDDS drive cycle

For HWFET drive cycle

Once the simulink vehicle model simulation was done some data will be sent to the MATLAB workspace with thw help of 'To worspac block'.The data from the simulink model is helps to plot the different parameters of the conventional vehicle in MATLAB.

The below modified program is used to plot the following parameters for both UDDS and HWFET drive cycles.

1.Trans input,Trans output and wheel speed

2.Engine torque,engine power,engine fuel rate and engine fuel consumption

3.fuel economy vs fuel consumption.

4.Accleration,brake pedal and gear command with respect to time

5.Gear command with respect to vehicle speed and distance

6.Engine fuel consumption map [g/s]

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Skill-Lync -> Hybrid Drives Development
% Project 1 - Conventional Vehicle Model
% By - Ullekh Gambhira 

% Description:
% The following file is to used with the Initialization file and Simulink
% results for post-processing of the data.
% The file is incomplete, has some examples of how the data is imported
% into a readable format, data analysis and plotting examples.
% Based on the project task, use commands in a similar format as given
% below, to analyse the data and generate required plots.
% You can change variable names if desired

%% Post-Processing File
%  File for post-processing the Conventional vehicle simulation model data

%% Renaming variables
Time = out.tout;
Acc_Pdl = out.Acc_Pdl;          % Accelerator pedal [%]
Brk_Pdl = out.Brk_Pdl;          % Brake pedal [%]
Gear_Cmd = out.Gear_Cmd;        % Transmission gear
Trans_In_Spd = out.Trans_In_Spd*30/pi;  % Transmission input speed [rpm]
Trans_Out_Spd = out.Trans_Out_Spd*30/pi;% Transmission output speed [rpm]
Eng_Trq = out.Eng_Trq;          % Engine brake torque [Nm]
Eng_Spd = out.Eng_Spd*30/pi;    % Engine speed [rpm]
Eng_Fuel_Consump = out.Eng_Fuel_Consumption;    % Engine fuel consumption [g]
Veh_Dist = out.veh_dist/1000;   % Distance traveled by vehicle [km]
Veh_Spd = out.veh_spd*18/5;     % Vehicle speed [kmph]
wheel_speed = out.wh_speed;     % wheel speed [kmph]
Eng_Fuel_Rate = out.Eng_Fuel_Rate;% Engine fuel rate [%]

%% Data Analysis
Eng_Pwr = Eng_Spd*pi/30*Eng_Trq/1000;   % Engine brake power [kW]
rho_petrol = 0.7197;                    % Density of petrol [kg/L]
kmpl = (Veh_Dist(end)/(Eng_Fuel_Consump(end)/1000/rho_petrol));    % Fuel economy [kmpl] 


%% Plotting vehicle characteristics time trace transmission IN/OUT and wheel speed

figure(1)
hold on
grid on
plot(Time, Trans_In_Spd, 'linewidth', 1, 'Color', 'black');
plot(Time, Trans_Out_Spd, 'linewidth', 1, 'Color', 'red');
plot(Time,wheel_speed,'b')
xlabel('Time [s]')
ylabel('speed [rpm]')
xlim([0,Time(end)]);
ylim([0,6000]);
legend('Trans Input','Trans output','wheel speed')

%% Plotting vehicle characteristics time trace transmission Engine speed,Engine Torque,Engine power,Engine fuel rate and Engine fuel consumption
% Data conversion from Double Time series

Eng_Spd = Eng_Spd.Data(:,1);
Eng_trq = Eng_Trq.Data(:,1);
Eng_pwr = Eng_Pwr.Data(:,1);
Eng_fuel_rate = Eng_Fuel_Rate.Data(:,1);
Eng_fuel_consumption = Eng_Fuel_Consump.Data(:,1);
Veh_spd =  Veh_Spd.Data(:,1);
Veh_dist = Veh_Dist.Data(:,1);


% Plotting Engine speed,Engine Torque,Engine power,Engine fuel rate andEngine fuel consumption wrt Time

figure(2)
subplot(2,2,1)
plot(Time,Eng_trq,'linewidth',1,'color','b')
xlabel('Time [s]')
ylabel('Torque [Nm]')
legend('Engine Torque')

grid on
subplot(2,2,2)
plot(Time,Eng_pwr,'linewidth',1,'color','r')
xlabel('Time [s]')
ylabel('power [kw]')
legend('Engine power')

grid on
subplot(2,2,3)
plot(Time,Eng_fuel_rate,'linewidth',1,'color','g')
xlabel('Time [s]')
ylabel('Fuel_Rate [%]')
legend('Engine Fuel Rate')

grid on
subplot(2,2,4)
plot(Time,Eng_fuel_consumption,'linewidth',1,'color','k')
xlabel('Time [s]')
ylabel('fuel consumption ')
legend('Engine Fuel consumption')
grid on

%plotting Eng fuel consumption vs Engine Fuel Rate

figure(3)
plot(Eng_fuel_consumption,Eng_fuel_rate,'color','r')
xlabel('Fuel consumption')
ylabel('Fuel Rate [%]')
title('Fuel economy vs Fuel Consumption')
grid on

%% plotting Acceleration pedal,Brake pedal and gear command wrt time
figure(4)
subplot(2,1,1)
hold on
plot(Time, Acc_Pdl, 'linewidth', 1, 'Color', 'black');
plot(Time, Brk_Pdl, 'linewidth', 1, 'Color', 'red');
xlabel('Time [s]')
ylabel('Pedal [%]')
xlim([0, Time(end)]);
grid on
legend('Accel','Brake');
title('Acceleration & Brake pedal wrt Time')

subplot(2,1,2)
plot(Time, Gear_Cmd, 'linewidth', 1, 'Color', 'black');
xlim([0, Time(end)]);
xlabel('Time [s]');
ylabel('Gear');
grid on
title('Gear command wrt Time')

% plotting gear command vehicle desired with actual speed

figure(5)
subplot(2,1,1)
plot(Veh_spd, Gear_Cmd, 'linewidth', 1, 'Color', 'black');
xlabel('speed [rpm]');
ylabel('Gear');
grid on
title('gear command wrt vehicle speed')

subplot(2,1,2)
plot(Veh_dist, Gear_Cmd, 'linewidth', 1, 'Color', 'black');
xlabel('Distance [Kmpl]');
ylabel('Gear');
grid on
title('Gear command wrt distance')

%% Plotting engine operating points on engine fuel map
figure('Name','Engine Operating Points');
hold on
grid on
title('Engine Operating Points','fontsize',12);
p1=plot(Eng_map_spd*30/pi,Eng_max_trq,'linewidth',2,'color','r');
p2=line([Eng_map_spd(end)*30/pi Eng_map_spd(end)*30/pi],[0 Eng_max_trq(end)]);
set(p2,'linewidth',1,'linestyle','--','color','k');
p3=line([Eng_map_spd(1)*30/pi Eng_map_spd(1)*30/pi],[0 Eng_max_trq(1)]);
set(p3,'linewidth',1,'linestyle','--','color','k');
[c,h] = contour(Eng_map_spd'*30/pi,Eng_map_trq,Eng_fuel_map');
clabel(c,h);
xlabel('Engine Speed [rpm]');
ylabel('Engine Torque [Nm]');
title('Engine Fuel Consumption Map [g/s]');
legend([p1 p3],{'Max Curve','Operating Points'});
axis([Eng_map_spd(1)*30/pi Eng_map_spd(end)*30/pi 0 Eng_map_trq(end)]);






Plot for UDDS and HWFET Drive cycle

1.plotting thr vehicle characteristics time trace,transmission IN/OUT and wheel speed

For UDDS drive cycle:

for HWFET drive cycle

2.1.plotting thr vehicle characteristics time trace to engine torque,engine power,engine fuel rate and engine fuel consumption:

for UDDS drive cycle

for HWFET drive cycle

3.plotting the fuel economy vs fuel consumption

for UDDS drive cycle

for HWFET drive cycle

4.1.plotting the Acclelerator pedal,Break pedal and Gear command with respect to time

For UDDS drive cycle

For HWFET drive cycle

5.plotting the Gear command with respect to vehicle speed and distance

For UDDS drive cycle

For HWFET drive cycle

6.plotting the engine fuel consumption map

For UDDS drive cycle

for HWFET drive cycle

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.