Main Content

Explore Virtual Vehicle Composer

The Virtual Vehicle Composer app automatically builds a virtual vehicle to your specifications and simulates the vehicle in a test plan you create. The app can simulate passenger vehicles and motorcycles with a range of powertrain architectures and varying detail in vehicle dynamics.

Diagram of passenger vehicle plant model.

The app has panes that you can follow for each step of building and testing a virtual vehicle:

  • Setup — Set up the basic vehicle model architecture and data storage locations.

  • Data and Calibration — Choose the components to install in your vehicle and specify parameters.

  • Scenario and Test — Set up a test plan by choosing scenarios to simulate.

  • Logging — Choose signals to log during the simulations.

  • Build — Build the virtual vehicle.

  • Operate — Run the test plan.

  • Analyze — Review and analyze the results. If applicable, view the resulting motion with 3-D animation.

Diagram of Virtual Vehicle Composer workflow.

Note that most of these steps are the same for passenger vehicles and motorcycles, but the options differ significantly in the Setup and the Data and Calibration panes.

Set Up Vehicle Architecture

In the Setup pane, you must first define the type of vehicle to build, the Model template to use, the type of powertrain to install, and the level of vehicle dynamics detail you need. This is done in the Setup pane. You can also set storage locations for model data.

Virtual Vehicle Composer setup pane

The selections you make on the Setup pane:

  • Determine which scenarios you can simulate in your test plan.

  • Cannot be changed once you click Confirm Setup.

For vehicle class, you can choose either a passenger vehicle or a motorcycle. A passenger vehicle is any four-wheeled vehicle designed for light-duty use, such as a passenger car, crossover vehicle, or pickup truck. A motorcycle is a traditional two-wheeled vehicle with a steered front fork.

Vehicle class choices

The Model template you choose determines the source of the physical blocks in your model, either from Simulink® or Simscape™ libraries. The choices depend on the vehicle class. For a passenger vehicle, you can choose either a Simulink or a Simscape template. For a motorcycle, you can only choose a Simscape template.

You can choose from thirteen powertrain architecture options for a passenger vehicle, including a conventional powertrain with an internal combustion engine, five battery-electric variants, and seven hybrid-electric variants. The figure shows an input power-split (IPS) hybrid-electric powertrain.

Powertrain architecture: Hybrid-electric powertrain IPS

Motorcycles have two powertrain options: either a conventional internal combustion engine powertrain or a battery-electric powertrain.

Choose the vehicle dynamics based on the test scenarios you plan to run. For drive cycles, only longitudinal dynamics are necessary. Vehicle handling tests require longitudinal, lateral, and vertical dynamics.

For a passenger vehicle, you can choose longitudinal dynamics only, longitudinal and vertical dynamics, or longitudinal, lateral, and vertical dynamics, as the figure shows.

Vehicle dynamics choices for a passenger vehicle

For a motorcycle, you can choose in-plane dynamics (longitudinal and vertical) or out-of-plane dynamics (longitudinal, lateral, and vertical).

In each case, the directions are referenced to the vehicle, and the corresponding rotational motions are included as degrees of freedom. The right-hand rule applies to rotations.

You also select the storage locations for your vehicle project:

  • Project path

  • Configuration name

  • Custom component catalog

The project path is the folder that contains all the project information. The configuration name is different for each unique vehicle you save.

The custom component catalog points to any custom components you want to access easily. For example, a custom component could be a component from Virtual Vehicle Composer that you have reparameterized or a Simulink model you have created and imported.

Once you make your choices in the Setup pane, the app produces a blank template, as depicted here.

Virtual Vehicle Composer blank model template

In the next step you will select and parameterize the components that will populate the template.

Choose and Parameterize Model Components

On the Data and Calibration pane, select components to populate the model template. A component is a discrete model that can be joined to the larger template. The available component choices depend on your vehicle architecture selections in the Setup pane. Component choices can include:

  • A physical vehicle component, such as a tire

  • A physical vehicle system or subsystem, such as a suspension system

  • A control system in the vehicle, such as an anti-lock braking system

  • A driver model

  • Environmental conditions

The Data and Calibration pane displays choices for each component, most with some key parameters displayed for editing. For example, the figure shows parameters for the Chassis component, such as inertial values and aerodynamic force coefficients.

Data and calibration pane

Specify Test Plan

Assemble the test plan on the Scenario and Test pane. Depending on the Vehicle class and Vehicle dynamics options you select, options can include:

  • Drive cycles, such as the FTP-75 cycle

  • Vehicle handling maneuvers, such as Increasing Steer Angle or Handle Hit

The figure shows an example for Passenger vehicle with longitudinal and vertical vehicle dynamics.

Test plan pane

Select Signals to Log

On the Logging pane, you can specify the list of signals to record during execution of your test plan.

Logging pane

To add individual signals to the list, select a signal and click Select. If you select a node, such as Steering, clicking Select will add all the signals contained in the node to the list.

Build Vehicle Model

After you configure your vehicle and the test plan, you must build the vehicle model. To build the vehicle model, in the Build section of the toolstrip, click Virtual Vehicle.

A new pane appears with the assembled model, including controllers, the driver, and testing conditions.

Virtual Vehicle Composer model completed

Run Test Plan

To run the test simulations, in the Operate section on the toolstrip, click Run Test Plan. The simulations take time to complete. View progress in the MATLAB® Command Window.

Review Results

Once the simulations are complete, to review the results, in the Analyze section of the toolstrip, click Simulation Data Inspector .

Virtual Vehicle Composer data review in Simulation Data Inspector

If your test plan includes more than one test scenario, the Simulation Data Inspector displays the results from the last scenario. To see results from earlier scenarios, load the archived results.

See Also

Related Examples

More About