## Introduction: How to Model a Motorcycle Rear Suspension in Matlab

Open matlab and start a new script or live script.

## Supplies

A computer with Matlab.

## Step 1: Define the Variables to Be Used in the Model.

- Clear and Clc at the beginning of the code will help the program run multiple times without giving errors.
- Define the spring stiffness: K = 85000 N/m
- Define the damping value: b = 4000 Ns/m
- Define the total mass of the vehicle with a rider: m = 296.65 kg

## Step 2: Define State Space Matrices

For this example the state space equations are representing a basic mass/spring/damper system. The matrices must be defined in order for matlab to build the transfer function. Once the matrices are defined, the ss2tf function can be used to produce a transfer function for this system. This system can then be subjected to a step input function in order to monitor the response.

## Step 3: Step Function Input

The step input command can be used to simulate an input of a certain height. For example, lets say that a motorcycle hits a speed bump (Typically 80 mm or 0.08 m). This can be set as the input amplitude using the opt command and stepDataOptions as shown. Once this is done, simulate the system response using the step command as shown.

## Step 4: Plot the Response to Step Input

Now use the plot commands to plot the system response to the input. This will allow you to gather certain key system characteristics that would affect the rider, such as the max deflection the rider will experience and the settling time.

## Step 5: Gather Characteristic Info Through Command

The system characteristics can also be gathered using the stepinfo command on matlab. This will provide the MPO, settling time, peak values, etc.

## Step 6: Modify Model for Different Motorcycles

This model can be used with multiple motorcycles by simply changing the spring constant, damping value, and the mass. Most motorcycles have a similar suspension type in the rear, but verify the same setup before using the model for other bikes.

## Comments