Bicycle Model
Implement a single track 3DOF rigid vehicle body to calculate longitudinal, lateral, and yaw motion
Libraries:
Automated Driving Toolbox /
Driving Scenario and Sensor Modeling
Vehicle Dynamics Blockset /
Vehicle Body
Description
The Bicycle Model block implements a rigid twoaxle single track vehicle body model to calculate longitudinal, lateral, and yaw motion. The block accounts for body mass, aerodynamic drag, and weight distribution between the axles due to acceleration and steering. There are two types of Bicycle Model blocks.
Block  Implementation 

Bicycle Model  Velocity Input 

Bicycle Model  Force Input 

To calculate the normal forces on the front and rear axles, the block uses rigidbody vehicle motion, suspension system forces, and wind and drag forces. The block resolves the force and moment components on the rigid vehicle body frame.
Ports
Input
WhlAngF — Wheel angle
scalar
Front wheel angle, in rad.
FxF — Force Input: Total longitudinal force on the front axle
scalar
Longitudinal force on the front axle,
Fx_{F}, along
vehiclefixed x
axis, in N.
Bicycle Model  Force Input block input port.
FxR — Force Input: Total longitudinal force on the rear axle
scalar
Longitudinal force on the rear axle,
Fx_{R}, along
vehiclefixed x
axis, in N.
Bicycle Model  Force Input block input port.
xdotin — Velocity Input: Longitudinal velocity
scalar
Vehicle CG velocity along vehiclefixed xaxis, in m/s.
Bicycle Model  Velocity Input block input port.
Output
Info — Bus signal
bus
Bus signal containing these block values.
Signal  Description  Value  Units  

InertFrm  Cg  Disp  X  Vehicle CG displacement along the earthfixed Xaxis  Computed  m  
Y  Vehicle CG displacement along the earthfixed Yaxis  Computed  m  
Z  Vehicle CG displacement along the earthfixed Zaxis  0  m  
Vel  Xdot  Vehicle CG velocity along the earthfixed Xaxis  Computed  m/s  
Ydot  Vehicle CG velocity along the earthfixed Yaxis  Computed  m/s  
Zdot  Vehicle CG velocity along the earthfixed Zaxis  0  m/s  
Ang  phi  Rotation of the vehiclefixed frame about the earthfixed Xaxis (roll)  0  rad  
theta  Rotation of the vehiclefixed frame about the earthfixed Yaxis (pitch)  0  rad  
psi  Rotation of the vehiclefixed frame about the earthfixed Zaxis (yaw)  Computed  rad  
FrntAxl  Disp  X  Front wheel displacement along the earthfixed Xaxis  Computed  m  
Y  Front wheel displacement along the earthfixed Yaxis  Computed  m  
Z  Front wheel displacement along the earthfixed Zaxis  0  m  
Vel  Xdot  Front wheel velocity along the earthfixed Xaxis  Computed  m/s  
Ydot  Front wheel velocity along the earthfixed Yaxis  Computed  m/s  
Zdot  Front wheel velocity along the earthfixed Zaxis  0  m/s  
RearAxl  Disp  X  Rear wheel displacement along the earthfixed Xaxis  Computed  m  
Y  Rear wheel displacement along the earthfixed Yaxis  Computed  m  
Z  Rear wheel displacement along the earthfixed Zaxis  0  m  
Vel  Xdot  Rear wheel velocity along the earthfixed Xaxis  Computed  m/s  
Ydot  Rear wheel velocity along the earthfixed Yaxis  Computed  m/s  
Zdot  Rear wheel velocity along the earthfixed Zaxis  0  m/s  
Hitch  Disp  X  Hitch offset from axle plane along the earthfixed Xaxis  Computed  m  
Y  Hitch offset from center plane along the earthfixed Yaxis  Computed  m  
Z  Hitch offset from axle plane along the earthfixed Zaxis  Computed  m  
Vel  Xdot  Hitch offset velocity from axle plane along the earthfixed Xaxis  Computed  m  
Ydot  Hitch offset velocity from center plane along the earthfixed Yaxis  Computed  m  
Zdot  Hitch offset velocity from axle plane along the earthfixed Zaxis  Computed  m  
Geom  Disp  X  Vehicle chassis offset from axle plane along the earthfixed Xaxis  Computed  m  
Y  Vehicle chassis offset from center plane along the earthfixed Yaxis  Computed  m  
Z  Vehicle chassis offset from axle plane along the earthfixed Zaxis  Computed  m  
Vel  Xdot  Vehicle chassis offset velocity along the earthfixed Xaxis  Computed  m/s  
Ydot  Vehicle chassis offset velocity along the earthfixed Yaxis  Computed  m/s  
Zdot  Vehicle chassis offset velocity along the earthfixed Zaxis  Computed  m/s  
BdyFrm  Cg  Vel  xdot  Vehicle CG velocity along the vehiclefixed xaxis  Computed  m/s  
ydot  Vehicle CG velocity along the vehiclefixed yaxis  Computed  m/s  
zdot  Vehicle CG velocity along the vehiclefixed zaxis  0  m/s  
Ang  Beta  Body slip angle, β
$$\beta =\frac{{V}_{y}}{{V}_{x}}$$
 Computed  rad  
AngVel  p  Vehicle angular velocity about the vehiclefixed xaxis (roll rate)  0  rad/s  
q  Vehicle angular velocity about the vehiclefixed yaxis (pitch rate)  0  rad/s  
r  Vehicle angular velocity about the vehiclefixed zaxis (yaw rate)  Computed  rad/s  
Acc  ax  Vehicle CG acceleration along the vehiclefixed xaxis  Computed  gn  
ay  Vehicle CG acceleration along the vehiclefixed yaxis  Computed  gn  
az  Vehicle CG acceleration along the vehiclefixed zaxis  0  gn  
xddot  Vehicle CG acceleration along the vehiclefixed xaxis  Computed  m/s^2  
yddot  Vehicle CG acceleration along the vehiclefixed yaxis  Computed  m/s^2  
zddot  Vehicle CG acceleration along the vehiclefixed zaxis  0  m/s^2  
AngAcc  pdot  Vehicle angular acceleration about the vehiclefixed xaxis  0  rad/s  
qdot  Vehicle angular acceleration about the vehiclefixed yaxis  0  rad/s  
rdot  Vehicle angular acceleration about the vehiclefixed zaxis  Computed  rad/s  
DCM  Direction cosine matrix  Computed  rad  
Forces  Body  Fx  Net force on vehicle CG along the vehiclefixed xaxis  Computed  N  
Fy  Net force on vehicle CG along the vehiclefixed yaxis  Computed  N  
Fz  Net force on vehicle CG along the vehiclefixed zaxis  0  N  
Ext  Fx  External force on vehicle CG along the vehiclefixed xaxis  Computed  N  
Fy  External force on vehicle CG along the vehiclefixed yaxis  Computed  N  
Fz  External force on vehicle CG along the vehiclefixed zaxis  0  N  
Hitch  Fx  Hitch force applied to body at the hitch location along the vehiclefixed xaxis  Input  N  
Fy  Hitch force applied to body at the hitch location along the vehiclefixed yaxis  Input  N  
Fz  Hitch force applied to body at the hitch location along the vehiclefixed zaxis  Input  N  
FrntAxl  Fx  Longitudinal force on front wheel, along the vehiclefixed xaxis  Computed  N  
Fy  Lateral force on front wheel along the vehiclefixed yaxis  Computed  N  
Fz  Normal force on front wheel, along the vehiclefixed zaxis  Computed  N  
RearAxl  Fx  Longitudinal force on rear wheel, along the vehiclefixed xaxis  Computed  N  
Fy  Lateral force on rear wheel along the vehiclefixed yaxis  Computed  N  
Fz  Normal force on rear wheel, along the vehiclefixed zaxis  Computed  N  
Tires  FrntTire  Fx  Front tire force, along the vehiclefixed xaxis  Computed  N  
Fy  Front tire force, along the vehiclefixed yaxis  Computed  N  
Fz  Front tire force, along the vehiclefixed zaxis  Computed  N  
RearTire  Fx Fx  Rear tire force, along the vehiclefixed xaxis  Computed  N  
Fy  Rear tire force, along the vehiclefixed yaxis  Computed  N  
Fz  Rear tire force, along the vehiclefixed zaxis  Computed  N  
Drag  Fx  Drag force on vehicle CG along the vehiclefixed xaxis  Computed  N  
Fy  Drag force on vehicle CG along the vehiclefixed yaxis  Computed  N  
Fz  Drag force on vehicle CG along the vehiclefixed zaxis  Computed  N  
Grvty  Fx  Gravity force on vehicle CG along the vehiclefixed xaxis  Computed  N  
Fy  Gravity force on vehicle CG along the vehiclefixed yaxis  Computed  N  
Fz  Gravity force on vehicle CG along the vehiclefixed zaxis  Computed  N  
Moments  Body  Mx  Body moment on vehicle CG about the vehiclefixed xaxis  0  N·m  
My  Body moment on vehicle CG about the vehiclefixed yaxis  Computed  N·m  
Mz  Body moment on vehicle CG about the vehiclefixed zaxis  0  N·m  
Drag  Mx  Drag moment on vehicle CG about the vehiclefixed xaxis  0  N·m  
My  Drag moment on vehicle CG about the vehiclefixed yaxis  Computed  N·m  
Mz  Drag moment on vehicle CG about the vehiclefixed zaxis  0  N·m  
Ext  Mx  External moment on vehicle CG about the vehiclefixed xaxis  0  N·m  
My  External moment on vehicle CG about the vehiclefixed yaxis  Computed  N·m  
Mz  External moment on vehicle CG about the vehiclefixed zaxis  0  N·m  
Hitch  Mx  Hitch moment at the hitch location about vehiclefixed xaxis  0  N·m  
My  Hitch moment at the hitch location about vehiclefixed yaxis  Computed  N·m  
Mz  Hitch moment at the hitch location about vehiclefixed zaxis  0  N·m  
FrntAxl  Disp  x  Front wheel displacement along the vehiclefixed xaxis  Computed  m  
y  Front wheel displacement along the vehiclefixed yaxis  Computed  m  
z  Front wheel displacement along the vehiclefixed zaxis  Computed  m  
Vel  xdot  Front wheel velocity along the vehiclefixed xaxis  Computed  m/s  
ydot  Front wheel velocity along the vehiclefixed yaxis  Computed  m/s  
zdot  Front wheel velocity along the vehiclefixed zaxis  0  m/s  
Steer  WhlAngFL  Front left wheel steering angle  Computed  rad  
WhlAngFR  Front right wheel steering angle  Computed  rad  
RearAxl  Disp  x  Rear wheel displacement along the vehiclefixed xaxis  Computed  m  
y  Rear wheel displacement along the vehiclefixed yaxis  Computed  m  
z  Rear wheel displacement along the vehiclefixed zaxis  Computed  m  
Vel  xdot  Rear wheel velocity along the vehiclefixed xaxis  Computed  m/s  
ydot  Rear wheel velocity along the vehiclefixed yaxis  Computed  m/s  
zdot  Rear wheel velocity along the vehiclefixed zaxis  0  m/s  
Steer  WhlAngRL  Rear left wheel steering angle  Computed  rad  
WhlAngRR  Rear right wheel steering angle  Computed  rad  
Hitch  Disp  x  Hitch offset from axle plane along the vehiclefixed xaxis  Input  m  
y  Hitch offset from center plane along the vehiclefixed yaxis  Input  m  
z  Hitch offset from axle plane along the earthfixed zaxis  Input  m  
Vel  xdot  Hitch offset velocity along the vehiclefixed xaxis  Computed  m/s  
ydot  Hitch offset velocity along the vehiclefixed yaxis  Computed  m/s  
zdot  Hitch offset velocity along the vehiclefixed zaxis  Computed  m/s  
Pwr  Ext  Applied external power  Computed  W  
Hitch  Power loss due to hitch  Computed  W  
Drag  Power loss due to drag  Computed  W  
Geom  Disp  x  Vehicle chassis offset from axle plane along the vehiclefixed xaxis  Input  m  
y  Vehicle chassis offset from center plane along the vehiclefixed yaxis  Input  m  
z  Vehicle chassis offset from axle plane along the earthfixed zaxis  Input  m  
Vel  xdot  Vehicle chassis offset velocity along the vehiclefixed xaxis  Computed  m/s  
ydot  Vehicle chassis offset velocity along the vehiclefixed yaxis  Computed  m/s  
zdot  Vehicle chassis offset velocity along the vehiclefixed zaxis  0  m/s  
Ang  Beta  Body slip angle, β
$$\beta =\frac{{V}_{y}}{{V}_{x}}$$
 Computed  rad 
Signal  Description  Value  Units  

PwrInfo  PwrTrnsfrd  PwrFxExt  Externally applied longitudinal force power  Computed  W  
PwrFyExt  Externally applied lateral force power  Computed  W  
PwrMzExt  Externally applied roll moment power  Computed  W  
PwrFwFx  Longitudinal force applied at the front axle power  Computed  W  
PwrFwFy  Lateral force applied at the front axle power  Computed  W  
PwrFwRx  Longitudinal force applied at the rear axle power  Computed  W  
PwrFwRy  Lateral force applied at the rear axle power  Computed  W  
PwrNotTrnsfrd  PwrFxDrag  Longitudinal drag force power  Computed  W  
PwrFyDrag  Lateral drag force power  Computed  W  
PwrMzDrag  Drag pitch moment power  Computed  W  
PwrStored  PwrStoredGrvty  Rate change in gravitational potential energy  Computed  W  
PwrStoredxdot  Rate of change of longitudinal kinetic energy  Computed  W  
PwrStoredydot  Rate of change of lateral kinetic energy  Computed  W  
PwrStoredr  Rate of change of rotational yaw kinetic energy  Computed  W 
xdot — Vehicle body longitudinal velocity
scalar
Vehicle CG velocity along vehiclefixed x
axis, in
m/s.
ydot — Vehicle body lateral velocity
scalar
Vehicle CG velocity along vehiclefixed y
axis, in
m/s.
psi — Yaw
scalar
Rotation of the vehiclefixed frame about earthfixed
Z
axis (yaw), in rad..
r — Yaw rate
scalar
Vehicle angular velocity, r
, about the
vehiclefixed z
axis (yaw rate), in rad/s.
Parameters
Number of wheels on front axle, NF — Front wheel count
2
(default)  scalar
Number of wheels on front axle, N_{F}. The value is dimensionless.
Number of wheels on rear axle, NR — Rear wheel count
2
(default)  scalar
Number of wheels on rear axle, N_{R}. The value is dimensionless.
Vehicle mass, m — Vehicle mass
2000
(default)  scalar
Vehicle mass, m, in kg.
Longitudinal distance from center of mass to front axle, a — Front axle distance
1.4
(default)  scalar
Horizontal distance a from the vehicle CG to the front wheel axle, in m.
Longitudinal distance from center of mass to rear axle, b — Rear axle distance
1.6
(default)  scalar
Horizontal distance b from the vehicle CG to the rear wheel axle, in m.
Vertical distance from center of mass to axle plane, h — Height
0.35
(default)  scalar
Height of vehicle CG above the axles, h, in m.
Initial inertial frame longitudinal position, X_o — Position
0
(default)  scalar
Initial vehicle CG displacement along earthfixed Xaxis, in m.
Initial longitudinal velocity, xdot_o — Velocity
0
(default)  scalar
Initial vehicle CG velocity along vehiclefixed xaxis, in m/s.
Front tire corner stiffness, Cy_f — Stiffness
12e3
(default)  scalar
Front tire corner stiffness, Cy_{f}, in N/rad.
Rear tire corner stiffness, Cy_r — Stiffness
11e3
(default)  scalar
Rear tire corner stiffness, Cy_{r}, in N/rad.
Initial inertial frame lateral displacement, Y_o — Position
0
(default)  scalar
Initial vehicle CG displacement along earthfixed Yaxis, in m.
Initial lateral velocity, ydot_o — Velocity
0
(default)  scalar
Initial vehicle CG velocity along vehiclefixed yaxis, in m/s.
Yaw polar inertia, Izz — Inertia
4000
(default)  scalar
Yaw polar inertia, in kg*m^2.
Initial yaw angle, psi_o — Psi rotation
0
(default)  scalar
Rotation of the vehiclefixed frame about earthfixed Zaxis (yaw), in rad.
Initial yaw rate, r_o — Yaw rate
0
(default)  scalar
Vehicle angular velocity about the vehiclefixed zaxis (yaw rate), in rad/s.
Longitudinal drag area, Af — Effective vehicle crosssectional area
2
(default)  scalar
Effective vehicle crosssectional area, A_{f}, to calculate the aerodynamic drag force on the vehicle, in m^{2}.
Longitudinal drag coefficient, Cd — Air drag coefficient
.3
(default)  scalar
Air drag coefficient, C_{d}. The value is dimensionless.
Longitudinal lift coefficient, Cl — Air lift coefficient
.1
(default)  scalar
Air lift coefficient, C_{l}. The value is dimensionless.
Longitudinal drag pitch moment, Cpm — Pitch drag
.1
(default)  scalar
Longitudinal drag pitch moment coefficient, C_{pm}. The value is dimensionless.
Relative wind angle vector, beta_w — Wind angle
[0:0.01:0.3]
(default)  vector
Relative wind angle vector, β_{w}, in rad.
Side force coefficient vector, Cs — Side force coefficient
[0:0.03:0.9]
(default)  vector
Side force coefficient vector coefficient, C_{s}. The value is dimensionless.
Yaw moment coefficient vector, Cym — Yaw moment drag
[0:0.01:0.3]
(default)  vector
Yaw moment coefficient vector, C_{ym}. The value is dimensionless.
Absolute pressure, Pabs — Pressure
101325
(default)  scalar
 scalar
Environmental absolute pressure, P_{abs}, in Pa.
Air temperature, Tair — Temperature
273
(default)  scalar
Environmental absolute temperature, T, in K.
Gravitational acceleration, g — Gravity
9.81
(default)  scalar
Gravitational acceleration, g, in m/s^2.
Nominal friction scaling factor, mu — Friction scale factor
1
(default)  scalar
Nominal friction scale factor, μ. The value is dimensionless.
Longitudinal velocity tolerance, xdot_tol — Tolerance
.01
(default)  scalar
Longitudinal velocity tolerance, in m/s.
Nominal normal force, Fznom — Normal force
5000
(default)  scalar
Nominal normal force, in N.
Geometric longitudinal offset from axle plane, longOff — Longitudinal offset
0
(default)  scalar
Vehicle chassis offset from axle plane along bodyfixed xaxis, in m. When you use the 3D visualization engine, consider using the offset to locate the chassis independent of the vehicle CG.
Geometric lateral offset from center plane, latOff — Lateral offset
0
(default)  scalar
Vehicle chassis offset from center plane along bodyfixed yaxis, in m. When you use the 3D visualization engine, consider using the offset to locate the chassis independent of the vehicle CG.
Geometric vertical offset from axle plane, vertOff — Vertical offset
0
(default)  scalar
Vehicle chassis offset from axle plane along bodyfixed zaxis, in m. When you use the 3D visualization engine, consider using the offset to locate the chassis independent of the vehicle CG.
References
[1] Gillespie, Thomas. Fundamentals of Vehicle Dynamics. Warrendale, PA: Society of Automotive Engineers (SAE), 1992.
Extended Capabilities
C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.
Version History
Introduced in R2018a
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
 América Latina (Español)
 Canada (English)
 United States (English)
Europe
 Belgium (English)
 Denmark (English)
 Deutschland (Deutsch)
 España (Español)
 Finland (English)
 France (Français)
 Ireland (English)
 Italia (Italiano)
 Luxembourg (English)
 Netherlands (English)
 Norway (English)
 Österreich (Deutsch)
 Portugal (English)
 Sweden (English)
 Switzerland
 United Kingdom (English)