Challenge

Final Project: Design of an Electric Vehicle

Create a MATLAB model of an electric car that uses a battery and a DC motor. Choose suitable blocks from the Powertrain block set. Prepare a report about your model including the following:

Objectives:

1. System-level configurations

2. Model parameters

3. Results

4. Conclusion

Aim:

To create a MATLAB model of an electric car that uses a battery, DC motor, and suitable blocks from the powertrain blocks.

Objectives:

  • To make a most simple and low run-time vehicle model using individual components models
  • To check out performance parameters like Speed, SOC, Current, etc with various drive cycles
  • To play with: Motor Power, Vehicle body (Rolling resistance,air drag, Weight), inputSimulink model for Electric Car :
  • Vehicle body:
  • Represents a two-axle vehicle body in longitudinal motion. The block accounts for body mass, aerodynamic drag, road incline, and weight distribution between axles due to acceleration and road profile. The vehicle can have the same or a different number of wheels on each axle. Optionally include pitch and suspension dynamics or additional variable mass and inertia. The vehicle does not move vertically relative to the ground.Connection H is the mechanical translational conserving port associated with the horizontal motion of the vehicle body. The resulting traction motion developed by tires should be connected to this port. Connections V, NF, and NR are physical signal output ports for vehicle velocity and front and rear normal wheel forces, respectively. Wheel forces are considered positive if acting downwards. Connections W and beta are physical signal input ports corresponding to headwind speed and road inclination angle, respectively. If variable mass is modeled, the physical signal input ports CG and M are exposed. CG accepts a two- element vector representing the x and y distance offsets from vehicle CG to additional load mass CG. M represents the additional mass. If both variable mass and pitch dynamics are included, the physical signal port J accepts the inertia of the additional mass about its own CG.

    The velocity of the vehicle os taken out from the 'V' port of the vehicle body.

    Gradeability is given through Beta port and it is connected to a PS constant block where we can change the values

    Wind velocity can be given through the W port and it is also connected to PS constant block

Battery:

The battery system contains a battery having a nominal voltage of 80V,a controlled current source, ammeter,rate transition block, gain blocks, discrete-time integrator, and subtract block.

  • Battery:

This block models a battery. If you select Infinite for the Battery charge capacity parameter, the block models the battery as a series of internal resistance and a constant voltage source. If you select Finite for the Battery charge capacity parameter, the block models the battery as a series of internal resistance plus a charge-dependent voltage source defined by:

V = Vnom⋅SOC1−β⋅(1−SOC)Vnom⋅SOC1-β⋅(1-SOC)

where SOC is the state of charge and Vnom is the nominal voltage. Coefficient ββ is calculated to satisfy a user-defined data point [AH1,V1].

State of charge of a battery can be calculated as :

Here we are using an 80V,50Ah battery.

As the vehicle accelerates the battery gets discharged and when braking it gets charged because of a regenerative battery

Power converter:

In this block there are two controlled voltage sources.

Controlled voltage source 1 receives the acceleration command from the driver controller.And a corresponding voltage is given to the controlled PWM voltage.

Also the controlled coltage source 2 receives the deceleration command from the driver controller.And this voltage is given to Brake input of H-bridge.

REV terminal of the H-bridge is connected to the reference terminal which provides the regenerative braking.

And according to the instructions given by the driver controller the controlled output voltage is outputted.

  • Controlled PWM voltage:

This block creates a Pulse-Width Modulated (PWM) voltage across the PWM and REF ports. The output voltage is zero when the pulse is low, and is equal to the Output voltage amplitude parameter when high. Duty cycle is set by the input value. Right-click the block and select Simscape->Block choices to switch between electrical +ref/-ref ports and PS input u to specify the input value.At time zero, the pulse is initialized as high unless the duty cycle is set to zero or the Pulse delay time is greater than zero.The Simulation mode can be set to PWM or Averaged. In PWM mode, the output is a PWM signal. In Averaged mode, the output is constant with value equal to the averaged PWM signal.

The specified values are shown below:

H-Bridge:

This block represents an H-bridge motor drive. The block can be driven by the Controlled PWM Voltage block in PWM or Averaged mode. In PWM mode, the motor is powered if the PWM port voltage is above the Enable threshold voltage. In Averaged mode, the PWM port voltage divided by the PWM signal amplitude parameter defines the ratio of the on-time to the PWM period. Using this ratio and assumptions about the load, the block applies an average voltage to the load that achieves the correct average load current. The Simulation mode parameter value must be the same for the Controlled PWM Voltage and H-Bridge blocks.If the REV port voltage is greater than the Reverse threshold voltage, then the output voltage polarity is reversed. If the BRK port voltage is greater than the Braking threshold voltage, then the output terminals are short circuited via one bridge arm in series with the parallel combination of a second bridge arm and a freewheeling diode. Voltages at ports PWM, REV and BRK are defined relative to the REF port.If exposing the power supply connections, the block only supports PWM mode.

The regenerative braking option is enabled

The simulation time is averaged otherwise simulation takes more time

The output voltage amplitude is 300V

Driver controller:

A parametric longitudinal speed tracking controller for generating normalized acceleration and braking commands based on reference and feedback velocities.Use the external actions to input signals that can disable, hold, or override the closed-loop commands determined by the block. The block uses this priority for the input commands: disable, hold, override.

Longitudinal driver simply gives acceleration and deceleration commands according the drive cycle data.

The velocity data extracted from the drive cycle is given here as a velocity reference.

The velocity from the vehicle body is taken and it is fedback to this block.

The gain 3.6 is nothing but converting velocity in m/s to km/hr.

Here we can give the gradeability as well through a constant block.

Energy consumed and distance calculation:

The drive cycle plot:

  1. The voltage plot:

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.