Open this model

Electric Vehicle with Active Damping

This demonstration shows the effects of measurement error and mechanical resonance on the performance of an Electric Vehicle (EV) system. A possible controls solution to mitigate the observed issue is proposed and the overall system performance is compared before and after the method is added.

Note that this model contains model initializations in the Initializations tab of the Simulations Parameter window, which can be accessed from the Simulation menu.

Vehicle modeling in PLECS

A front-wheel drive EV model has been developed in PLECS using components from the control and mechanical modeling domains. The EV implementation is based on two slip-based wheel models, as described in the demo model Two-Wheel Vehicle with Driving Profile.

The EV is propelled by a wye-connected permanent magnet synchronous machine (PMSM) attached to a single-speed gearbox. The damping and stiffness properties of the half-shafts connecting the gearbox and differential to the front wheels of the EV are incorporated in the system model.

Power electronic system

An ideal DC voltage source is used to model a battery pack supplying energy to the vehicle. The battery is connected to the DC-side of a two-level voltage source inverter that drives the PMSM.

A basic torque controller is implemented to convert the torque demand to current setpoints in the rotor reference frame (DQ). The current setpoints along with measured αβ currents, rotor position, and the DC voltage are fed into a digital synchronous frame regulator. The regulator generates a voltage setpoint that is transformed into the alpha-beta reference frame. A space vector modulator is then used to translate this voltage setpoint into switching signals for the two-level converter.

System non-idealities

A sudden step change in the motor torque leads to an oscillation of the motor inertia. This windup effect occurs due to excitation of a natural frequency of the powertrain, which is given by:

f0 =  
 Ks 
2 π G  Jm
where Ks correspond to the stiffness coefficient of the shaft, Jm corresponds to the rotor inertia of the motor, and G corresponds to the gear ratio. The inertia of the wheel/vehicle system is neglected because it is assumed to be significantly larger than the motor inertia.

When modeling electric drives it is often assumed that all measurements are ideal and accurate. However, in reality some amount of offset and gain errors will be present in all sensors. It can be shown that gain errors of the current measurement can lead to torque oscillation at twice the fundamental frequency of the phase currents. This causes a torque ripple, which can excite the natural frequency of the mechanical system as described above and reduce vehicle driveability.

Simulation

Windup and measurement error effects

Run the simulation with the model as provided to view the windup effects caused by a step change in motor torque during startup, and the sustained oscillation excited by the steady-state current sensor error. The vehicle is initially at rest on a steep slope. A torque demand of 100 Nm is applied to accelerate the vehicle up the slope. As can be seen in the above figure, the rotor speed increases quickly from standstill to 790 rpm. The rotor then proceeds to reverse its motion with a maximum speed of 230 rpm in the opposite direction.

In the simulation, a gain error in the measurement of two of the phase currents has been modeled, where one phase current is overestimated by 5% and the other is underestimated by 5%. As in the figure above, this leads to a low frequency oscillation of the generated motor torque, which translates to a low frequency oscillation in the motor speed. The peak-to-peak amplitude of the low frequency motor speed oscillation is 80% of the average motor speed. Save the trace of the scope and label it as "Undamped @ v0".

Mechanical damping

One possible solution to reducing the windup effect would be to change the natural frequency and damping factor of the rotor shaft. This can be achieved by adding an additional inertia onto the rotating shaft. However, this is not a practical approach as it would require increasing the weight and cost of the overall vehicle, and would adversely affect its performance.

Active damping

A more realistic solution to minimize drivetrain oscillations, is to actively control the torque demand on the PMSM. With this method, the rotor speed is measured and fed into an outer speed control loop. This outer control loop consists of a digital PI controller with an anti-windup mechanism that generates a correction torque from the measured rotor speed. This correction torque, along with the torque demand of the driver, is used to modify the torque setpoint that is fed into the torque controller.

Enable the active damping method by changing the value of the "Active Damping Enable" gain block to 1. Rerun the simulation. As shown in the figure above, the outer speed control loop adjusts the torque demand signal that is fed into the torque controller. This results in a significant reduction in the windup effects that occur without any damping.

Additionally, the low frequency oscillation of the motor speed that arises due to the measurement error of the current sensor is also actively damped by the outer speed control loop. As can be seen in the figure above, the feedback of the motor speed results in a low frequency adjustment in the steady-state torque demand setpoint. This translates to a reduction in the amplitude of the peak-to-peak low frequency speed oscillation of the motor to 7.5% of the average motor speed at steady state. Save the trace of the scope and label this as "Damped @ v0".

Low speed versus high speed effects

The maximum steady-state powertrain oscillation (due to current sensor error) occurs when the motor torque excites the natural frequency (f0) of the system. A deviation away from the speed at which this occurs reduces the steady-state speed oscillation. For the system at hand, the vehicle speed (v0) at which the powertrain oscillates at f0 is 2 km/h. Next we will observe the effect on the motor speed oscillation when the steady-state vehicle speed is doubled (2v0).

Change the "Viscous friction coefficient" of the road load to 1500. Rerun the simulation once with the active damping disabled (label this "Undamped @ 2v0") and once with the active damping enabled (label this "Damped @ 2v0").

In the figure above, the red trace corresponds to an undamped vehicle moving at a steady-state speed (v0) that excites f0 of the powertrain system, while the orange trace is for a vehicle moving at 2v0. The magnitude of the peak-to-peak steady-state oscillation (as a ratio of the average motor speed) is significantly reduced for a vehicle moving at 2v0 (80% vs 13%).

The simple active damping algorithm implemented is able to reduce these oscillations. In the figure above, the blue trace corresponds to a damped vehicle moving at v0, while the green trace is for a vehicle moving at 2v0. The algorithm reduces motor speed oscillation to 7.5% for the vehicle moving at v0, while the oscillation is reduced to 5% for the vehicle moving at 2v0.

References

M. Menne, "Drehschwingungen im Antriebsstrang von Elektrostraßenfahrzeugen", Aachen University of Technology, 2001.