Main Content

Virtual Vehicle Composer

Configure, build, and analyze a virtual automotive vehicle

Description

The Virtual Vehicle Composer app enables you to configure and build a virtual vehicle that you can use for system-level performance analysis, including component sizing, fuel economy, drive cycle tracking, software integration testing, and hardware-in-the-loop (HIL) testing. Use the app to quickly enter your vehicle parameter data, build a virtual vehicle model, run test scenarios, and analyze the results.

The virtual vehicle model contains the blocks and reference application subsystems available with Powertrain Blockset™ and Vehicle Dynamics Blockset™. You can use the app to quickly configure the architecture and enter parameter data.

If you have Powertrain Blockset, use the app to:

  • Design tradeoff analysis and component sizing.

  • Configure hybrid-electric vehicle (HEV) architectures.

If you have Vehicle Dynamics Blockset, use the app to:

  • Analyze ride-and-handling effects of standard test maneuvers.

  • Visualize your virtual vehicle in Unreal Engine® simulation environment.

To build, operate, and analyze your virtual vehicle, use Composer tab in the Virtual Vehicle Composer to follow these workflow steps:

Step

Section

Button

Description

1

Configure

Virtual Vehicle data icon

Vehicle Data

Specify the vehicle architecture, dynamics model, chassis, powertrain, and driver. For each selection, enter the vehicle parameter data.

2

Virtual Vehicle scenario icon

Vehicle Scenario and Test

Select the scenario to use to test your virtual vehicle. Options include drive cycle scenarios for longitudinal studies and standard test maneuvers for vehicle dynamics studies.

3

Virtual Vehicle data logging icon

Data Logging Editor

Select the model signal data to log when operating your virtual vehicle. Options include vehicle position, velocity, and acceleration.

4

Build

Virtual Vehicle build icon

Virtual Vehicle

Build your virtual vehicle. When you build, the Virtual Vehicle Composer creates a Simulink® model that contains the vehicle architecture and the data that you specify in the configuration.

5

Operate

Virtual Vehicle operate icon

Run Test Plan

Simulate your model in the scenarios that you specify in step 2.

6

Analyze

Virtual Vehicle analyze icon

Simulation Data Inspector

Use the Simulation Data Inspector to view and inspect the simulation signals that you select in step 3.

Required Products

The Virtual Vehicle Composer requires either of these products:

Vehicle Data

Use the app to quickly enter your virtual vehicle parameter data for the vehicle architecture, vehicle dynamics model, chassis, powertrain, and driver. For each selection, enter the parameter data.

ParameterDescription
Vehicle Architecture

Use the parameters to specify the vehicle type. By default, the parameter is set to Conventional Vehicle. The conventional vehicle architecture has a spark-ignition (SI) internal combustion engine, transmission, chassis, and associated powertrain control algorithms.

If you have Powertrain Blockset, you can specify these model architectures for hybrid electric vehicles (HEVs). The HEV and EV model architectures include an internal combustion engine, chassis, transmission, battery, motor, generator, and associated powertrain control algorithms.

Vehicle Model

Use the parameter setting Longitudinal Vehicle Dynamics to configure a model suitable for fuel economy and energy management analysis.

If you have Vehicle Dynamics Blockset, you can specify Lateral Vehicle Dynamics to configure a model suitable for vehicle handling, stability, and ride comfort analysis.

The virtual vehicle uses the Z-up coordinate system as defined in SAE J670 and ISO 8855. For more information, see Coordinate Systems in Vehicle Dynamics Blockset (Vehicle Dynamics Blockset).

Chassis

Use the Chassis parameters to select the tire, brake type, steering system, and suspension systems for your virtual vehicle.

If you have Powertrain Blockset, you can set Tire to Longitudinal Tire, which implements a tire model suitable for longitudinal vehicle dynamics studies, including fuel economy and energy management analysis.

If you have Vehicle Dynamics Blockset, you can set Tire to Longitudinal Combined Slip Tire, which implements a tire model suitable for lateral vehicle dynamics studies, including vehicle handling, stability, and ride comfort analysis. The model implements longitudinal and lateral behavior of a wheel characterized by the Magic Formula. You can use fitted tire data sets provided by the Global Center for Automotive Performance Simulation (GCAPS).

If you have Vehicle Dynamics Blockset and set Vehicle Model to Lateral Vehicle Dynamics, you can specify Steering System and Suspension parameters.

Powertrain

Select the engine, transmission, drivetrain, differential system, vehicle control unit, and electrical system parameters for your virtual vehicle. The available parameters depend on the product license, vehicle architecture, and vehicle model.

Driver

The parameter setting Longitudinal Driver implements a longitudinal speed-tracking controller.

If you have Vehicle Dynamics Blockset you can set Driver to Predictive Driver to track longitudinal velocity and a lateral reference displacement.

Environment

The parameter setting Standard Ambient implements an ambient environment model.

Vehicle Scenario and Test

Select the scenario to use to test your virtual vehicle.

If you set Scenario to Drive Cycle, you can use:

  • Drive cycles from predefined sources. By default, the block includes the FTP–75 drive cycle. To install additional drive cycles from a support package, see Install Drive Cycle Data. The support package has drive cycles that include the gear shift schedules, for example JC08 and CUEDC.

  • Workspace variables that define your own drive cycles.

  • .mat, .xls, .xlsx, or .txt files.

  • Wide open throttle (WOT) parameters, including initial and nominal reference speed, deceleration start time, and final reference speed.

If you have Vehicle Dynamics Blockset and set Vehicle Model to Lateral Vehicle Dynamics, you can select maneuvers for vehicle handling, stability, and ride analysis. Maneuvers include:

  • Double Lane Change

  • Increasing Steer

  • Constant Radius

If you want to run your virtual vehicle in the Unreal Engine 3D simulation environment, set Simulation 3D to Enable. For hardware requirements, see Unreal Engine Simulation Environment Requirements and Limitations (Vehicle Dynamics Blockset).

Data Logging Editor

Select the model signal data to log when operating your virtual vehicle. Options include vehicle position, velocity, and acceleration. By default, the app lists frequently-used signals.

Virtual Vehicle

Build your virtual vehicle. When you build, the Virtual Vehicle Composer creates a Simulink model that contains the specified vehicle architecture and data.

Run Test Plan

Simulate your model in the scenario that you specified in Vehicle Scenario and Test.

Simulation Data Inspector

Use the Simulation Data Inspector to view and inspect the simulation signals.

If you run your virtual vehicle through more than one test scenario, the Simulation Data Inspector displays the results from the last simulation. To see results from previous simulations, load the archived results.

Virtual Vehicle Composer app

Open the Virtual Vehicle Composer App

  • MATLAB® Toolstrip: On the Apps tab, under Automotive, click the app icon.

  • MATLAB Command Window: Enter virtualVehicleComposer.

Parameters

Architecture and Model

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Conventional Vehicle

Model architecture for a vehicle with a spark-ignition (SI) internal combustion engine, transmission, and associated powertrain control algorithms.

Electric Vehicle

Model architecture for an electric vehicle (EV) with a motor-generator, battery, direct-drive transmission, and associated powertrain control algorithms.

Hybrid Electric IPS

 

Model architecture for a input power split (IPS) hybrid electric vehicle (HEV) with an internal combustion engine, transmission, battery, motor, generator, and associated powertrain control algorithms.

Hybrid Electric MM

 

Model architecture for a multimode HEV with an internal combustion engine, transmission, battery, motor, generator, and associated powertrain control algorithms.

Hybrid Electric P0

 

Model architecture for a HEV P0 with an internal combustion engine, transmission, battery, motor, generator, and associated powertrain control algorithms.

Hybrid Electric P1

 

Model architecture for a HEV P1 with an internal combustion engine, transmission, battery, motor, generator, and associated powertrain control algorithms.

Hybrid Electric P2

 

Model architecture for a HEV P2 with an internal combustion engine, transmission, battery, motor, generator, and associated powertrain control algorithms.

Hybrid Electric P3

 

Model architecture for a HEV P3 with an internal combustion engine, transmission, battery, motor, generator, and associated powertrain control algorithms.

Hybrid Electric P4

 

Model architecture for a HEV P4 with an internal combustion engine, transmission, battery, motor, generator, and associated powertrain control algorithms.

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Longitudinal Vehicle Dynamics

Model suitable for fuel economy and energy management analysis.

Lateral Vehicle Dynamics

 

Model suitable for vehicle handling, stability, and ride comfort analysis.

Chassis

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Longitudinal Tire

Tire model suitable for longitudinal vehicle dynamics studies, including fuel economy and energy management analysis.

Longitudinal Combined Slip Tire

 

Tire models suitable for lateral vehicle dynamics studies, including vehicle handling, stability, and ride comfort analysis.

Tire model implements the longitudinal and lateral behavior of a wheel characterized by the Magic Formula. You can use fitted tire data sets provided by the Global Center for Automotive Performance Simulation (GCAPS) for tires, including:

  • Light passenger car 205/60R15

  • Mid-size passenger car 235/45R18

  • Performance car 225/40R19

  • SUV 265/50R20

  • Light truck 275/65R18

  • Commercial truck 295/75R22.5

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Disc

Brake model converts the brake cylinder pressure into a braking force.

Drum

Brake model converts the applied force and brake geometry into a net braking torque.
Mapped

Brake model is a function of the wheel speed and applied brake pressure.

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Bang Bang ABS

Anti-lock braking system (ABS) feedback controller that switches between two states to regulate wheel slip. The bang-bang control minimizes the error between the actual slip and the desired slip. For the desired slip, the controller uses the slip value at which the mu-slip curve reaches a peak value. This desired slip value is optimal for minimum braking distance.

Open Loop

Open loop brake control. The controller sets the brake pressure command to a reference brake pressure based on the brake command.

Five-State ABS

Five-state ABS controller that uses logic-switching based on wheel deceleration and vehicle acceleration to control the braking pressure at each wheel.

Consider using five-state ABS control to prevent wheel lock-up, decrease braking distance, or maintain yaw stability during the maneuver. The default ABS parameters are set to work on roads that have a constant friction coefficient scaling factor of 0.6.

If you have Vehicle Dynamics Blockset and set Vehicle Model to Lateral Vehicle Dynamics, you can specify these parameters.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Mapped

 

Mapped rack-and-pinion steering model.

Kinematic

 

Kinematic model for ideal rack-and-pinion steering. Gears convert the steering rotation into linear motion.

Dynamic

 

Dynamic model for ideal rack-and-pinion steering. Gears convert the steering rotation into linear motion.

If you have Vehicle Dynamics Blockset and set Vehicle Model to Lateral Vehicle Dynamics, you can specify these parameters.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Kinematics and Compliance Independent Suspension

 

Kinematics and compliance (K & C) test suspension characteristics measured from simulated or actual laboratory suspension tests.

MacPherson Front Suspension Solid Axle Rear Suspension

 

Independent MacPherson suspension for multiple axles with multiple tracks per axle.

Powertrain

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Simple Engine

Simplified engine model using a maximum torque verses engine speed table, two scalar fuel mass properties, and one scalar engine efficiency parameter to estimate engine torque and fuel flow.

Selecting Simple Engine sets the Engine Control Unit parameter to Simple ECU.

CI Engine

 

Compression-ignition (CI) engine from intake to the exhaust port.

Selecting CI Engine sets the Engine Control Unit parameter to CI Engine Controller.

CI Mapped Engine

Mapped CI engine model using power, air mass flow, fuel flow, exhaust temperature, efficiency, and emission performance lookup tables.

Selecting CI Mapped Engine sets the Engine Control Unit parameter to CI Engine Controller.

SI Engine

 

Spark-ignition (SI) engine from intake to exhaust port.

Selecting SI Engine sets the Engine Control Unit parameter to SI Engine Controller.

SI Mapped Engine

Mapped SI engine model using power, air mass flow, fuel flow, exhaust temperature, efficiency, and emission performance lookup tables.

Selecting SI Mapped Engine sets the Engine Control Unit parameter to SI Engine Controller.

SI DL Engine

 

Deep learning SI engine.

Available if you have the Deep Learning Toolbox™ and Statistics and Machine Learning Toolbox™ licenses. Use this setting to generate a dynamic deep learning SI engine model to use for powertrain control, diagnostic, and estimator algorithm design.

Selecting SI DL Engine sets the Engine Control Unit parameter to SI Engine Controller.

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Ideal Fixed Gear Transmission

Idealized fixed-gear transmission without a clutch or synchronization. Use this setting to model the overall gear ratio and power loss when you do not need a detailed transmission model.

Automated Manual Transmission

 

Ideal automated transmission (AMT). An AMT is a manual transmission with additional actuators and an electronic control unit (ECU) to regulate clutch and gear selection based on commands from a controller. Specify the number of gears as an integer vector with corresponding gear ratios, inertias, viscous damping, and efficiency factors. The clutch and synchronization engagement rates are linear and adjustable.

Automatic Transmission with Torque Converter

 

Automatic transmission with a torque converter.

No Transmission

 

No transmission.

Dependencies

To enable this parameter, set Vehicle Architecture to any of these:

  • Conventional Vehicle

  • Hybrid Electric Vehicle P0

  • Hybrid Electric Vehicle P1

  • Hybrid Electric Vehicle P2

  • Hybrid Electric Vehicle P3

  • Hybrid Electric Vehicle P4

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Driver Pass Through

No transmission control optimization.

PRNDL Controller

Controller that optimizes forward, reverse, neutral, park, and N-speed gear shift scheduling for fuel economy.

Dependencies

To enable this parameter, set Vehicle Architecture to any of these:

  • Conventional Vehicle

  • Hybrid Electric Vehicle P0

  • Hybrid Electric Vehicle P1

  • Hybrid Electric Vehicle P2

  • Hybrid Electric Vehicle P3

  • Hybrid Electric Vehicle P4

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

One Actuator Input

Use One Actuator Input to configure the drivetrain for:

  • Front Wheel Drive

  • Rear Wheel Drive

  • All Wheel Drive

Two Actuator Inputs AWD

 

To enable this parameter, set Vehicle Architecture to Hybrid Electric Vehicle P4.

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Open Differential

Differential as a planetary bevel gear train. The block matches the driveshaft bevel gear to the crown (ring) bevel gear. You can specify:

  • Carrier-to-driveshaft ratio

  • Crown wheel location

  • Viscous and damping coefficients for the axles and carrier

Active Differential

 

Active differential that accounts for the power transfer from the transmission to the axles. The model implements the active differential as an open differential coupled to either a spur or a planetary differential gear set.

Limited Slip Differential

Differential as a planetary bevel gear train. The block matches the driveshaft bevel gear to the crown (ring) bevel gear. You can specify:

  • Carrier-to-driveshaft ratio

  • Crown wheel location

  • Viscous and damping coefficients for the axles and carrier

  • Type of slip coupling

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Electrical System Settings

Powertrain Blockset

Vehicle Dynamics Blockset

Vehicle Architecture

Description

Electrical System 1EM BEV Battery

 Electric Vehicle

  • Mapped motor and drive electronics operating in torque-control mode.

  • Lithium ion battery model based off of discharge characteristics taken at different temperatures.

Electrical System 1EM BEV Ideal Voltage Source

Electric Vehicle

  • Mapped motor and drive electronics operating in torque-control mode.

  • Ideal voltage source battery model.

Electrical System 2EM HEV

 
  • Hybrid Electric Vehicle IPS

  • Hybrid Electric Vehicle MM

  • Two mapped motors and drive electronics operating in torque-control mode.

  • Lithium ion battery model based off of discharge characteristics taken at different temperatures.

Electrical System 1EM HEV

 
  • Hybrid Electric Vehicle P0

  • Hybrid Electric Vehicle P1

  • Hybrid Electric Vehicle P2

  • Hybrid Electric Vehicle P3

  • Hybrid Electric Vehicle P4

  • Two mapped motors and drive electronics operating in torque-control mode.

  • Lithium ion battery model with DC-DC conversion.

Use the Electrical Machine parameters to specify a mapped motor and drive electronics operating in torque-control mode.

Use the Energy Storage parameters to specify a datasheet battery model for a lithium-ion battery.

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Vehicle Architecture

Description

EV 1EM

Electric VehicleControls the motor with torque arbitration and power management. Implements regenerative braking.
HEVIPS RuleBased

 Hybrid Electric Vehicle IPS

Controls the motor, generator, and engine through a set of rules and decision logic implemented in Stateflow®.

HEVMM RuleBased

 Hybrid Electric Vehicle MM

HEVP0 Optimal

 Hybrid Electric Vehicle P4

Implements an equivalent consumption minimization strategy (ECMS) to control the energy management of hybrid electric vehicles (HEVs). The strategy optimizes the torque split between the engine and motor to minimize energy consumption while maintaining the battery state of charge (SOC).

HEVP1 Optimal

 Hybrid Electric Vehicle P4

HEVP2 Optimal

 

Hybrid Electric Vehicle P4

HEVP3 Optimal

 

Hybrid Electric Vehicle P4

HEVP4 Optimal

 

Hybrid Electric Vehicle P4

If you have Vehicle Dynamics Blockset you can set Driver to Predictive Driver to track longitudinal velocity and a lateral reference displacement.

These parameters depend on the product license. This table summarizes the parameters available with Powertrain Blockset or Vehicle Dynamics Blockset.

Setting

Powertrain Blockset

Vehicle Dynamics Blockset

Description

Longitudinal Driver

Implements a longitudinal speed-tracking controller.

Predictive Driver

 

Track longitudinal velocity and a lateral reference displacement.

Available when you set Vehicle Model to Lateral Vehicle Dynamics.

The parameter setting Standard Ambient implements an ambient environment model.

Programmatic Use

expand all

Entering the command virtualVehicleComposer opens a new session of the app, enabling you to configure, build, and analyze your virtual vehicle.

Version History

Introduced in R2022a