CarSim Roads PDF
CarSim Roads PDF
Ground Geometry.............................................................................................. 2
Road Geometry.................................................................................................. 2
Horizontal Geometry: Station S and Lateral coordinate L ............................ 3
Elevation..................................................................................................... 4
Vehicle-Road Axis System ........................................................................ 10
Coordinate System Conversions ................................................................ 11
Summary of Road Screens ............................................................................... 12
Horizontal Geometry, Possibly with Other Properties ................................ 12
Elevation................................................................................................... 12
Friction ..................................................................................................... 13
Animation ................................................................................................. 13
Importing 3D Road Data: Round-Off Error................................................ 13
Road: 3D Surface Screen ................................................................................. 14
Road Horizontal Geometry Screens ................................................................. 17
About Road Tables with X-Y Coordinates ................................................. 17
Road: X-Y Coordinates of Centerline ........................................................ 18
Road: X-Y-Z Coordinates of Centerline..................................................... 19
Road: X-Y-Z Coordinates of Edges ........................................................... 19
Road: Segment Builder Screen......................................................................... 21
Main Controls on the Screen...................................................................... 22
Spreadsheet Controls ................................................................................. 23
Road Elevation Screens ................................................................................... 27
Road: Centerline Elevation Screen............................................................. 27
Road: Off-Center Elevation Map Screen.................................................... 27
Road: Off-Center Elevation Map, Variable Width...................................... 27
Road Friction Screens ...................................................................................... 30
Road: Animator Surface Shapes Screen ........................................................... 31
Discussion................................................................................................. 31
User Settings ............................................................................................. 32
Road: Animator Repeated Object..................................................................... 37
Discussion................................................................................................. 37
User Settings ............................................................................................. 37
Surface: Roughness Profiles Screen ................................................................. 39
Math Model Treatment of Profiles ............................................................. 39
Profile Measurement ................................................................................. 41
User Settings ............................................................................................. 41
References....................................................................................................... 42
The major forces that move a vehicle with tires are the forces generated between the tire and
ground. The BikeSim, CarSim, and TruckSim vehicle models account for a potentially uneven 3D
surface with variable friction.
The VS math models support two methods for defining 3D surfaces with variable friction
properties:
1. Ground properties are defined with 2D tables of elevation and friction based on grids of
global X and Y coordinates.
2. Road properties are defined using a 3D reference line, which in turn defines a road-based
coordinate system such that elevation and friction data are concentrated in the region of
interest (i.e., on or near the road).
In addition to the 3D surface defined either with a grid of X-Y coordinates or with a road
reference line, the VS models support a contribution to elevation based on surface roughness
profile data that can be specified using the Surface: Roughness Profiles screen.
All of the libraries related to the ground and road surface can be accessed in the VS browser (e.g.,
carsim.exe) using the Libraries menu in the submenu Ground and Roads.
Ground Geometry
A 3D ground can be defined without a road reference line. This option is convenient for handling
flat surfaces, off-road conditions, and urban environments with many road intersections. Two
screens are used to define the surface properties.
2. Ground: Elevation Map, X-Y Grid defines vertical elevation Z as a function of global
X and Y coordinates. The screen has a table that can be set to one of many interpolation
methods, including constant, coefficient, linear, spline, and 2D interpolation. The root
keyword is Z_GROUND.
3. Ground: Friction Map, X-Y Grid defines tire/ground friction as a function of global X
and Y coordinates. The screen has a table that can be set to one of many interpolation
methods, including constant, coefficient, linear, spline, 2D interpolation, and an equation
provided at runtime. The root keyword is MU_GROUND.
Besides defining a 2D configurable function, both of these screens also set the parameter
OPT_ROAD = 0, indicating to the VS solver that the surface is not defined with the road model.
The elevation and friction maps use standard table controls described in the VehicleSim Browser
Reference Manual.
Road Geometry
The VehicleSim road model defines the geometry and friction of the ground relative to a 3D
reference line, to allow detailed information to be concentrated in the region of interest (i.e., on or
near the road).
The VS browser uses the road datasets to automatically generate animator shapes to allow
visualization of the ground geometry and its relationship with vehicle motions in animations.
S4
X, Y
X4 , Y4
L
S
S3
S1 = S path
S2
X3, Y3
X1, Y1
X2 , Y2
(X i - X i-1) + (Y i - Y i-1)
2 2
Si = Si–1 + {i>1} (1)
This definition of station is deliberately simple — straight lines connect points as viewed from a
satellite in space. Effects of elevation change and curvature are not included, meaning that S from
this definition is slightly less than the distance alone the curved path (the curved black line in the
figure). This simplified definition of S is used to provide a connection between multiple
properties of the road surface (elevation, banking, friction, etc.). Station is also used to control
inputs such as target speed and lateral position.
Although the calculation of station is based on straight-line segments, the reference line between
the points is indeed curved, as indicated in Figure 1. At station values between the original data
points, there can be an offset between the straight connecting line and the curved path. Internally,
the VS solver programs generate tables of X vs. S and Y vs. S and use spline interpolation to
calculate X and Y as continuous functions of S for points on the curved reference line. The spline
functions also provide ∂X/∂S and ∂Y/∂S as functions of S.
The second road coordinate is L, the lateral distance from a point perpendicular to the road
reference line (see the red circle in Figure 1). As is the case with station, L is defined in a
horizontal plane, as if viewed from space by a satellite. Lateral position is used to specify a target
path for the closed-loop steering controller and for specifying elevation changes as described in
the next section.
Elevation
Starting with the horizontal reference, elevation at an arbitrary location on the road (Zroad) is
summed from a contribution from the reference line, defined as a function Zref of S, and two off-
center contributions defined using Zmap, a function of S, L, and an ID number.
Zroad = Zref (S) + Zmap (L, S, 1) + Zmap (L, S, 2) (2)
Configurable Functions
VS solver programs represent many potentially nonlinear relationships between two or three
variables with configurable functions of the form f(Xcol, Xrow, id) where Xcol and Xrow are
independent variables and id is an integer used to identify a specific dataset. Most options for a
configurable function involve tabular data provided in a spreadsheet form with columns and rows
of numbers. For example, for the function Zmap, the first row contains values of L (the Xcol
variable) associated with each column. If there are Ncol values of L provided, then each row has
Ncol +1 numbers — a value of S (the Xrow variable) followed by corresponding values of elevation
for each combination of L and S.
If there is only one independent variable (e.g, the function Zref depends only on S), then each row
in the table has just two numbers: the independent variable Xrow and a corresponding value of the
dependent variable.
In most cases, configurable functions that allow two independent variables can also be used with
data for only one variable, with simpler datasets and faster calculation times. Further, most
functions can also be configured to skip the nonlinear calculations completely. These options are
specified at runtime by keywords used in the simulation input data file to identify parameters and
tables associated with vehicle properties and test conditions. Configurable functions are described
in detail in the VS Solvers Reference Manual.
Figure 2 illustrates the method implied by Eq. (2) for building a 3D road surface from tabular
data. Images in the left side of the figure show screens from the VS browser used to enter and/or
visualize tabular data. Images on the right-hand side (generated from the VS Visualizer) show the
road geometry as it is built from each component.
Increasing S
Increasing S
Increasing S
Increasing S Increasing S
Figure 2. The 3D road description is built from configurable functions that are typically tabular.
First, a set of X-Y coordinates is provided (see the upper-left part of Figure 2). In this example,
the road turns to the left, then to the right, and then to the left to resume the original direction. As
mentioned earlier, the road model generates values of S corresponding to each pair of X and Y
coordinates, and uses internal spline interpolation methods to calculate X and Y coordinates for
the road reference line for any value of S. The method was used to generate the continuously
curving reference line shown in the upper-right portion of the figure. If this were the only
description of the road, the reference line could be used to generate paths for driver controllers
and to make shapes for animations, but the ground would be flat and level.
Banking of turns involves changes in elevation away from the reference line. The middle-left part
of the figure shows a 3D map of elevation in terms of S and L. The geometry here is simple; there
are three banking angles for the three curves, separated with linear transitions. The road shown in
the middle-right part of the figure shows the effect of taking the Zmap shape and distorting it to
follow the curved path, with S and L defined from the curved reference line.
The lower-left part of the figure shows a screen for setting Zref as a function of S, with the road
dropping 10 m in elevation about halfway through the second curve. In this case, the configurable
function was set to use spline interpolation within the range of data provided, with flat-line
extrapolation. The view of the road in the lower-right part of the figure shows the combined result
of the horizontal curve geometry, the off-center elevation due to banking, and the 10-m dip in the
middle of the section.
Configurable functions can also be used to account for variations in road width along the road.
Internally, this is accomplished by an option where the function Zmap is set to calculate the
elevation component in terms of S and an intermediate variable associated with each column of
data. (The variable is simply the column number, which has values 1, 2, …). A separate table
defines L for each column as a function of S, using linear interpolation. For example, values of
elevation provided in column 2 of a table of input data can correspond to values of L that in turn
depend on S. This option can greatly reduce the amount of data needed to define simple
geometric features that are not parallel or perpendicular to the reference line. For example, Figure
3 shows rounded curbs at the edges of a road and in the median. (The geometry of the curbs can
be seen in the figure from the shapes of the shadows cast by the vehicles.) The curbs follow the
road edge as the road changes width due to lanes merging.
Coordinate Transformations
The S-L-Z coordinate system is convenient for specifying road geometry and features. However,
most physics models and visualization software (including VS models and animators) require
locations and directions to be specified in a global X-Y-Z Cartesian system. Given that both
systems use the same global Z coordinate, the challenge is to convert from X-Y coordinates to S-L
(where vertical geometry is described), and from S-L to X-Y.
Figure 4 shows a curved section of road with the original data points shown as yellow circles on
the reference line. The points are connected with straight lines shown in light blue, and the curved
reference line is shown in black. A point of interest is shown with another yellow circle.
Lanes merge
Figure 3. Variable-width tables simplify the descriptions of roadside curbs where lanes merge.
L: lines of constant S
Point of interest:
X, Y, S, L
Reference line
(curved), L = 0
constant S that is perpendicular (lines of constant S are shown with red arrows in the figure). In
the VS road model, the directions of the lines of constant S are defined at each of the original data
points (yellow circles in the figure) by bisecting the angles between the connecting line segments.
For values of station between two of the original points, the direction changes linearly from one
end of the segment to the other.
Transforming from S-L to X-Y is accomplished with a direct sequence of calculations (no iteration
is required). As mentioned earlier, internally generated tables are used to calculate X and Y on the
reference line. The X and Y coordinates of the point of interest are then calculated taking into
account the known value of L and the partial derivatives ∂X/∂L and ∂Y/∂L.
Going from X-Y coordinates to S-L involves similar calculations if the segment of road
perpendicular to the point of interest is known. Given directions of the lines of constant S, the
coordinates of an original point (yellow circle on the reference line in Figure 4), and direction of
the connecting line segment, the values of S and L can be calculated. If the value calculated for S
is within the segment used for the calculations, then the calculation is complete. However, if the
calculated value of S is not within the assumed segment, then the segment containing the
calculated value of S is found by searching the table, and the process is repeated. In VS programs
that are running a simulation that advances through time in steps, the segment used at the
previous simulation time is used for the initial calculation at each new time. If the point of interest
has not moved much in the simulation time step (typically 0.001 sec), then the calculation is
successful on the first try. If not, it is usually because the point of interest on the vehicle is now
perpendicular to the reference line in an adjacent segment. In this case, the calculation is likely to
be successful on the second try. However, there are conditions where the calculation methods
simply cannot find an answer. This can happen if the vehicle model has become numerically
unstable and moved a very large distance. It can also happen when the point of interest is far from
the reference line on the inside of curve, near the curve center.
Converting from X-Y to S-L coordinates can also be complicated because there might be many
solutions of S-L coordinates that would be valid for a point of interest. Figure 5 shows an aerial
view of a racetrack reference line (blue) and a red point of interest (red circle). Any of the points
labeled A, B, etc. on the reference line are connected to the point with a line perpendicular to the
reference and are therefore valid locations for determining S and L. (In this case, point A is
probably the correct location on the road.)
When VS configurable functions use table interpolation methods, they keep track internally of the
index into the tables between function calls. For example, suppose that the point of interest shown
in Figure 5 is for a point of contact for the left-front tire of an automotive vehicle. When the S-L
coordinates were calculated the previous time step, the point was very close to point A, and that
location would be the starting point for performing new calculations.
A
Point of interest
C
I
E
D
G
F H
Figure 5. Multiple locations on a reference line might provide valid S-L coordinates for a point of
interest.
If you set up an event to change paths during a run, it is a good idea to also set the station state
variable (keyword = SV_STA_ROAD) to a value that is close to where the vehicle will be located
on the path when it is activated. For example, suppose the path shown in Figure 5 is activated
during a run and the vehicle will enter near point A. The path station at point A is 2012 m, the
path station at point C is 1243 m, and the current value of the state variable SV_STA_ROAD is
956 m. It is likely that the solver will either determine that the location on the path is point A (S =
1243), or that it will fail to find a value and stop the run. To provide a clean transition, the parsfile
loaded when the event is triggered should not only load the new reference path dataset, it should
also set SV_STA_ROAD to a value near 2000 to enable the solver to properly locate the vehicle
position in the new road.
Slope Calculations
Mapping data from S-L coordinates to global X-Y coordinates involves “bending” a grid around
the specified reference line. This can be seen in Figure 4: the lines of constant S converge going
upward toward the center of the curve and diverge going downward. The bending preserves the
longitudinal spacing between data points at the reference line, where L = 0. However, when L is
not zero and the reference line is curved, then longitudinal distance is stretched if L locates the
point further from the center of the curve, and compressed if L locates the point closer to the
center of the curve. This distortion means that ∂Z/∂S must take into account the ratio of the
curvature at L divided by the curvature at the reference line.
If the Zmap function is configured for a variable-width road, then the derivative ∂L/∂S is also taken
into account.
The VS road model produces slope at points of interest by scaling ∂Z/∂S and ∂Z/∂L (for variable-
width roads), and then resolving the slopes into the directions of the global X and Y axes using the
corresponding values of ∂X/∂S, ∂Y/∂S, ∂X/∂L, and ∂Y/∂L.
Most of the motion variables defined in the standards make use of the following axis systems.
· Earth-fixed (XE, YE, ZE) — this system is fixed in the inertial reference frame. ZE
points up, in the direction opposite of gravity. XE and YE define the ground plane
that is level—perpendicular to gravity. The earth coordinate system is used to define
global coordinates for points in the vehicle that locate the sprung mass, wheel
centers, and other parts in a multibody model. The orientations of XE and YE within
the ground plane are arbitrary.
· Vehicle (XV, YV, ZV) — this system is fixed in the sprung mass of the vehicle. X V
points forward, YV points to the left, and ZV points up. For vehicles that are
essentially symmetric laterally, YV should be perpendicular to the plane of symmetry.
· Intermediate (X, Y, Z) — this is the system used to define major vehicle motion
variables. Longitudinal velocity and acceleration are defined using the X-axis
direction; lateral velocity and acceleration are defined using the Y-axis direction.
These directions are completely defined by the direction of gravity (Z = ZE) and the
vehicle yaw angle.
· Tire (XT, YT, ZT) — a tire system exists for each tire and is used to define variables
related to the contact of the tire with the ground. These directions are defined based
on two direction vectors: the direction of the wheel spin axis (YW) and a direction
perpendicular to a road plane, which is a local representation of the road surface in
the region of the tire contact patch.
In addition to the above axis systems, VS vehicle models include a Road axis system (XR, YR,
ZR) for defining vehicle motion variables in the same way the Intermediate system is used.
Instead of the main reference being gravity and a ground plane, the reference is the road normal,
ZR, which is perpendicular to the road surface. The point on the road surface used to determine
the direction of ZR is selected such that the ZR axis passes through a designated point on the
vehicle sprung mass. The method for locating the corresponding point on the road is described in
a following subsection. The XR axis is perpendicular to ZR and YV, and YR is perpendicular to XR
and ZR. For example, Figure 6 shows both the ZE and ZR axes for a vehicle navigating a turn on a
banked circular track. As the vehicle turns to its left, it rolls to the right (relative to the road
normal), although the SAE/ISO roll angle is to the left due to the banking of the road. Thus, roll
angle in the road axis system not only differs from the roll angle in the intermediate axis system
— the two angles don’t even have the same sign.
In VS models, the road normal is defined using only the first two of the three components of
overall elevation shown in equation 2. The slope from function Zref is combined with the slope
from Zmap using the first dataset (ID =1). The second Zmap is not used in this definition. This
allows you to distinguish road design features (banking, grades) from bumps, curbs, and other
features that are not wanted in the definition of the road normal.
Figure 6. Comparison of Earth “up” and road normal for defining vehicle roll.
located. In most examples, the start of a road is arbitrarily given X-Y-Z coordinates of (0, 0, 0), to
simplify viewing of plots and to reduce any possibilities of round-off error.
Elevation
Three screens are available for specifying elevation independently of the horizontal geometry.
They are available for use if the information was not already embedded in a horizontal geometry
dataset from one of the four libraries listed above.
1. Road: Centerline Elevation. Use this screen to specify the elevation of the reference
line (Zrl) for the road whose horizontal geometry is defined with a dataset from the
library Road: X-Y Coordinates of Centerline.
2. Road: Off-Center Elevation Map, S-L Grid. Use this screen to specify the off-center
elevation changes (dZ1 or dZ2) as functions of S-L coordinates when a grid of S-L
coordinates is sufficient.
3. Road: Off-Center Elevation Map, Variable Width. Use this screen to specify the off-
center elevation changes (dZ1 or dZ2) as functions of S-L coordinates for roads whose
widths vary or have elevation changes that are not necessarily parallel or perpendicular to
the reference line of the road.
Friction
Two screens are available for specifying friction as a function of road S and L coordinates.
1. Road: Friction Map, S-L Grid. Use this screen to specify the tire/road friction as a
function of S-L coordinates for roads when a rectangular grid of S-L coordinates is
sufficient.
2. Road: Friction Map, Variable Width. Use this screen to specify the tire/road friction as
a function of S-L coordinates for roads whose widths vary or have frictional changes that
are not necessarily parallel or perpendicular to the reference line of the road.
Animation
Two screens are available for using road geometry to send information to the animator.
1. Road: Animator Surface Shapes. Use this screen to generate shape files that will help
visualize the 3D road surface in the animator. This screen also specifies how 2D textures
are mapped over the shapes.
2. Road: Animator Repeated Object. This screen allows an animator object (tree, traffic
cone, etc.) to be repeated in locations specified by either S-L or X-Y coordinates. If S-L
coordinates are used, the screen transforms the information into the global X-Y
coordinates required by the animator.
The VS solvers echo tabular data with a precision that can be set at runtime. The default precision
uses 10 significant digits. Prior to May 2010, VS solvers wrote tabular data with only 6
significant digits (this is the default format in C programs). Be careful about copying tabular data
from echo files, especially if they were generated with older versions. If global coordinates are
used for road data, it is possible that the values were rounded off in printing, with a loss of
information.
10
11
2 6
4 12
7 13
5
14
Each of these library screens specifies the horizontal geometry of the road, establishing the
link between X-Y and S-L coordinates. Each provides a different combination of additional
properties, to simplify the use of common forms of road data that are sometimes available.
The last column in the table identifies the links on this screen that are typically not needed,
because the information is already included in the selected horizontal geometry dataset.
Each library listed in the table is described in depth in following sections.
3 Link to a Road: Centerline Elevation dataset. This specifies the overall vertical geometry
of the road reference line defined by the horizontal geometry 2 with a configurable
function that can be set to a constant or coefficient, or use 1D interpolation involving a table
of elevation values linked to station. The root keyword for the table is ROAD_ZS.
If the horizontal geometry link 2 points to a dataset in which the elevation is specified,
then this link is typically not used (Table 1).
4 Link to Road: Off-Center Elevation Map or Road: Off-Center Elevation Map, Variable
Width dataset (see details in a following section, page 27). This link specifies the primary
3D off-center elevation with a configurable function (dZ1 in equation 2 on page 3). Of the
two libraries, the former supports a constant, a linear coefficient, a 1D interpolation
involving only S, or a 2D interpolation involving S and L; the latter library supports 2D
variable-width interpolation. The root keyword for all cases is ROAD_DZ with the
component index identified as 1 with the keyword IROAD.
If the horizontal geometry link 2 points to a dataset in which the banking is specified, then
this link is typically not used (Table 1).
5 Link Road: Off-Center Elevation Map or Road: Off-Center Elevation Map, Variable
Width dataset. This link specifies the second 3D off-center elevation with a configurable
function (dZ2 in equation 2 on page 12).
The root keyword for all cases is ROAD_DZ with the component index identified as 2 with
the keyword IROAD.
A dataset linked here will not conflict with any other elevation data that might be included
with the horizontal geometry dataset.
6 Link to a Road: Friction Map or Road: Friction, Variable Width dataset. This specifies
friction as a function of longitudinal and lateral position on the road with a configurable
function. Of the two libraries, the former supports a constant, a linear coefficient, a 1D
Note Shadows are handled with the SurfAnim program with moving shapes
that are translucent and are positioned slightly above the ground surface.
The VS Visualizer, introduced in 2011, supports true shadows cast by
one 3D object on another surface. When VS Visualizer is used, the
shadow shape and DZ_SHADOW parameter are ignored.
11 Links to miscellaneous animation data. You can use these links to add features to the road
that do not depend on geometry, such as houses, trees, etc. You can also link to the Road:
Animator Repeated Object (page 38) to add multiple copies of an object using global or
road coordinates, as described in a following section.
12 Positions of road reference camera tracking points for preview animations. The VS solvers
for all VehicleSim vehicle models calculate output variables associated with two tracking
points: one leading the vehicle and one following the vehicle. The variables have names
such as X_CamF, Y_CamF, X_CamR, etc. and are used to set up tracking camera views for
the animator.
13 View with Animator button. Click to view the 3D surface as defined by the links on this
screen plus the animator shape settings. The view of the road is controlled by the link 14
immediately under the button.
14 Link to an Animator: Camera Setup dataset. This defines the simulated camera point of
view if you view the road by clicking the button View with Animator 13 .
X, Y, and Z coordinates are treated as global coordinates from an inertial reference frame in the
VS math models. There are no requirements about where the origin of the X-Y-Z system is
located. In most examples, the start of a road is arbitrarily given X-Y-Z coordinates of (0, 0, 0), to
simplify viewing of plots and also to reduce any possibilities of round-off error.
2
1
3
1 3
2 4 5
Note The browser uses the information on this screen to automatically create
the tables of X-Y coordinates, elevation, and off-center elevation that are
used by the VS solvers. It is instructive to click the Parsfile button (in
the VS button bar at the top of the window) to view the Parsfile and see
the tables that are created. (It’s OK to view the file, but don’t edit it.)
1 Drop-down list to specify the information plotted on the screen. Options include plotting the
horizontal (X-Y) data as shown in Figure 10 in the graphic area, the elevation (S-Z) data, the
off-center elevation data, or a 3D graph of the X-Y-Z data.
2 Drop-down list to specify which table will be used for the reference line of the road. Options
are Upper table and Lower table, referring to their location on the screen. The selected
table will have the lateral coordinate of L=0 at all points along the road.
3 Loop option box (keyword = OPT_ROAD_LOOP). When this box is checked, the first and
last row in the tables must have identical X, Y, and Z values, and the VS solvers treat the
road descriptions as looping.
4 Starting station (keyword = SPATH). This defines the station for the first row in the
reference line table.
5 Upper table for the X-Y-Z coordinates of either the left or right edge of the road.
6 Lower table for the X-Y-Z coordinates of either the left or right edge of the road.
2 5
9
3 6 8 10
1
4 7 11
12
13
When using this screen the horizontal (X-Y) coordinates of the centerline cannot be disabled, as
they determine the station values of each segment upon which all of the other features are based.
Note The browser uses the information on this screen to automatically create
the tables of X-Y coordinates, elevation, off-center elevation, and friction
that are used by the VS solvers. It is instructive to click the Parsfile
button (in the VS button bar at the top of the window) to view the
Parsfile and see the tables that are created. (It’s OK to view the file, but
don’t edit it.)
Note This screen can be used to specify simple banking of the road as it goes
around turns. You can still use the second of the two Road: Off-Center
Elevation Map 4 links in Figure 7 (page 14) to specify other 3D
features of the road.
7 Checkbox to write friction table. When this box is unchecked, the VS solvers are not sent
any frictional coefficient data for the road from this screen. Additionally, the columns
pertaining to the road friction are hidden in the spreadsheet.
8 Coordinate fields for starting station. These fields can be used to specify the coordinates for
the first rows of the tables generated for the road using this screen. If not specified, the
starting coordinates default to (0, 0, 0).
9 Starting station (keyword = SPATH). This defines the station for the beginning of the road. If
not specified, a default value of 0 is used in the math model.
10 Length of track. This field displays the calculated length of the road constructed.
11 Banking width. If the road is banked, this field specifies width of the part of the road that
should be banked. Beyond this width, the terrain is flat. If nothing is specified, the banking
of the road continues indefinitely.
12 A plot of the data. Depending on the pull-down control setting 1 , this plot may contain the
horizontal (X-Y) data, the elevation (S-Z) data, or be hidden to allow more room for the
spreadsheet.
13 Set table size controls. These controls resize the table to the specified number of rows.
Spreadsheet Controls
Each row in the spreadsheet defines a segment of the road, with each cell specifying a property of
the segment. The spreadsheet has too many columns to view all at once, so the screen includes
scroll bars and the controls described in the previous section for hiding columns. For example,
Figure 11 shows the screen appearance with a plot of the horizontal geometry, while Figure 12
shows the same dataset with an extended view of the editor, scrolled horizontally to show the
columns not visible in Figure 11.
Horizontal Data
The first six columns in the spreadsheet (visible in Figure 11) specify the horizontal information
about the segments. These columns are visible only when the View X,Y columns box 3 is
checked. However, the information they contain is always used, even when not visible.
14 Direction. Options include Left, Ahead, and Right. If either Left or Right is selected, then
the segment is a piece of a circle continuing from the end point of the previous segment and
curving in the specified direction. If Ahead is selected, then the segment is a straight line
extending continuously from the end point of the previous segment.
15 Size. This column specifies the segment size either by the arc length (meters) or the central
angle (degrees), based on the choice of units set in the next column 16 . If the segment
direction 14 is Ahead, then the units are meters, and this value is the length of the straight
section.
16 Units for the segment size specified in the preceding column 15 : m or deg. If the segment is
a straight line, then this is automatically set to m.
17 Radius or curvature. If the segment is curved, then this column specifies the radius or the
curvature (inverse radius) of the segment. The choice of radius (m) or curvature (1/m) is set
in the next column 18 . If the segment is a straight line, then the curvature is automatically
set to 0.
18 Units for the segment curvature: m or 1/m. This pull-down control specifies the units for the
curvature information from the preceding column 17 . If the segment is a straight line
(curvature = 0), then the only allowable option is 1/m.
19 Number of coordinate points that are introduced automatically in the X-Y-S table for this
segment. The VS use cubic splines to connect points, which do not exactly match a circular
arc. Increasing the number of points brings the curved path from the spline fit closer to a true
circular arc, at the expense of making the table bigger.
Figure 12. The Road: Segment Builder Screen with the extended editor.
Station Data
The next two columns (visible in Figure 12) provide calculated station values for information.
These values are not used directly by the VS solvers. These columns are visible only when the
View segment station values box 4 is checked.
20 Last station value of the segment, calculated by connecting all points with straight lines as
shown in Figure 1 (page 3). This is the definition of station used to define other properties of
the road (elevation, banking, and friction).
21 Last station value of the segment, calculated by connecting all points using true arc lengths.
This value is usually a little higher than the value shown in the preceding column 20 and
should not be used for looking at other tables that depend on station. It is provided as a
reference for comparison with external data.
Elevation Data
The next five columns specify the vertical information about the segments. These columns are
visible only when the Write elevation table box 5 is checked. If the box is not checked, then
no information is provided to the math model about centerline elevation changes in the road.
Figure 13 shows the geometry of the elevation changes for the first two segments in a road.
Figure 13. Conceptual drawing of the elevation description of the Road: Segment Builder
Screen.
22 Elevation transition distance. This value specifies the transitional distance for the elevation
at the end of the current segment and the beginning of the next segment where a smooth
curve will be automatically drawn to connect the two segments. A conceptual drawing of
this is shown in Figure 13 in which the value of this field would be the value T1.
If the road loops, the transition distance for the final segment of the road applies to the first
and last segments. However, if the road does not loop, the last segment has no ending
transitional distance, and any value specified for the last segment is ignored.
23 Start Z value. This field describes the beginning Z coordinate of the segment.
The value of this field specifies the elevation after the transitional period. If the road does
not loop, however, the first segment will begin at this elevation without any transitional
period.
The value of this field can specify the elevation using either an absolute Z coordinate or a
relative Z coordinate, depending on the selection of column 24 . A relative Z coordinate
adds the value of this field to the elevation at the end of the previous segment (before the
transitional period). For the first segment, both absolute and relative starting Z coordinates
behave the same.
24 Convention used to specify start Z value 23 : absolute or relative.
25 End Z value. This field describes the Z coordinate at the end of the segment. Usually, this
value occurs at a station distance equal to the final station value of the segment minus the
transition distance 9 of the segment. If the road does not loop, the value for the last row
specifies the elevation of the last point in the road. Depending on the selection of column
26 , this value may specify an absolute Z coordinate, a Z coordinate relative to the segment’s
starting Z coordinate, or a percent grade of the segment.
26 End Z value type. This field specifies the type of data in column 25 and may be an absolute
coordinate, a value relative to the start of the segment, or a percent grade for the segment.
Banking Data
Two columns specify banking information about the segments. These columns are visible only
when the Write banking table box 6 is checked. If the box is not checked, then no information
is provided to the math model about banking changes in the road.
27 Banking percentage column. This column specifies the cross-slope of the segment. If the
segment is curving either left or right, positive values of banking will make the road bank
into the turn. If the segment is straight, positive values of banking will cause the road to
slope down to the left.
28 Banking transition distance. This column specifies the distance at the end of one segment
and the beginning of the next segment that will be used for linearly transitioning one
banking amount to another. Since the transition distance is applied to both the end of one
segment and the beginning of the next, the actual distance in which the banking is
transitioning is twice the value of this column. If the road loops, the final transition distance
applies to the first and last segments. However, if the road does not loop, the last segment
has no ending transitional distance, and any value specified is ignored.
Friction Data
Two columns specify friction information about the segments. These columns are visible only
when the Write friction table box 7 is checked. If the box is not checked, then no information
is provided about friction in the road.
Coefficients of friction always have positive values. The math models allow a value of zero to be
specified, for special applications such as kinematic and compliance (K&C) test rigs where tire
forces are disabled through the use of bearing plates. If you enter a negative value, MU_ROAD will
be set to MU_REF_X (the tire reference coefficient) for the longitudinal direction and MU_REF_Y
for the lateral direction. By using a negative value, you force the math model to use the tire data
directly without scaling for friction.
29 Mu left. This column specifies the coefficient of friction to be applied to all lateral values to
the left of the centerline for this segment.
30 Mu right. This column specifies the coefficient of friction to be applied to all lateral values
to the right of the centerline for this segment.
Discussion
With the variable width elevation map, the lateral position of the columns of values can also
change as a function of station. This allows the user to define, for instance, a road that narrows or
widens. Other examples where this could be used include defining a road with ruts that wander
laterally, or adding a bump in the road that is not perpendicular to the design line. Figure 14a
shows a top view of how the elevation points may be sampled with a rectangular fixed-width
map, and Figure 14b shows a variable-width map.
User Settings
Figure 16 shows the screen for specifying variable-width maps of off-center elevation.
Figure 16. The Road: Off-Center Elevation Map, Variable Width screen.
1 Plot showing a top view of the lateral position of the edges versus station.
2 Table of lateral position of each edge versus station. The first column in the table is the
independent variable station S. Subsequent columns define the lateral positions of the edges
at the given station value.
3 Pull-down control to specify the method of interpolation for the elevation. Options are 2D
linear interpolation & extrapolation or 2D step interpolation, flat-line extrapolation.
4 Plot showing elevation versus station.
5 Table of elevation of each edge versus station. The first column in the table is the
independent variable station. Subsequent columns define the elevations of the edges at the
given station value.
Discussion
This screen is used to control a road shape generator that will make up to twenty-five 3D shape
files. Each shape is a rectangular “lane” that follows the reference line of the road as defined with
links from the screen Road: 3D Surface (Figure 7, page 14). The lane will curve as needed to
follow the road reference line and is described using the S-L road coordinates.
The visual representation of the lane in the animator is composed of rectangles whose dimensions
are specified on this screen. The smaller rectangles are defined to show finer detail in the 3D
geometry of the road. The rectangles can be connected or alternated to create stripes and grids.
The datasets associated with this screen are not used directly by the VS solvers, nor are they used
by the surface animator. They are used by the road shape generator that is run automatically by
the Road: 3D Surface screen to create OBJ shape files. If textures are used, then a corresponding
material MTL file and one or more 2D image files can be used to add photographs, textures, or
other forms of 2D images mapped over the 3D road surface. If the image is smaller than the area
of the lane, it is “tiled” as needed to cover the lane. The image tiles are mapped over the
rectangles that define the lane, to give the effect of a “skin” covering the 3D road shape.
The OBJ and MTL file formats, originally developed by Wavefront, are described and discussed
in the SurfAnim Reference Manual. If you are interested in adding new custom textures to the
road shapes, then please refer to the sections in that manual that describe the format of the MTL
file.
User Settings
1 Pathname for MTL material file that defines materials that can be used to define road
surfaces for the animator. As described in the SurfAnim Reference Manual, the animator
supports Wavefront OBJ files that in turn reference MTL material files that define one or
more materials. The materials are defined in terms of their lighting properties and optionally
textures defined in 2D image files stored in familiar formats such as BMP, JPG, etc.
According to the OBJ specification, the pathname for the MTL file should be defined
relative to the folder containing the OBJ files. The OBJ files are all created in the folder for
the 3D road datasets (Roads\3D_Road). The material file installed in the basic CarSim
installation is located in the folder Roads\Material. To locate this relative to the
Roads\3D_Road folder, it is specified as ../Material/Road.mtl
2 Checkbox to mirror texture images. The 2D images used as “tiles” to build the texture of the
road surface can be repeated exactly as they are originally shown, or mirrored to maintain
continuity. Images that are designed to be used as textures usually appear best with the
mirror option not checked; images that are not carefully designed will often look better with
the mirror option checked.
3 Optimization threshold. When displaying very detailed shapes, the animation may run
slowly on some computers if the longitudinal interval is small or the lateral number of
divisions is large. In order to reduce the size of the files, the shape generator can look for flat
areas to simplify, if there is insignificant loss of detail. If the vertices between two adjacent
rectangles can be removed and cause less error than this optimization threshold, the
rectangles will be combined to improve performance.
If you specify zero or a negative value, then no optimization is done, and all rectangles are
generated.
4 Color of each lane. Color is specified with RGB numbers separated by a space or with the
adjacent color control that displays the current color.
5 Color button for each lane. Color for the lanes can be chosen by clicking this button, which
will cause a pop-up to appear (Figure 18).
In this pop-up, the color of each lane can be selected by selecting the lane and then clicking
on the color field in the lower left-hand corner. When you are done, click OK.
6 Material for each lane. Each drop-down list can be used to specify that the lane has no
texture, or that it has a texture as defined in an associated material MTL file. The MTL file
is specified at the top of the screen 1 .
10 Lower lateral limit for each lane. This determines the lateral definition of the shape.
Depending on the selection of 11 , this can be specified in units of meters or by the off-
center elevation edge number. If edge is selected in 11 , the first link of the two Road: Off-
Center Elevation Map or Road: Off-Center Elevation Map, Variable Width links 4 in
Figure 7 (page 14) is used to determine the lateral limit of this edge of the lane. The number
in the field is interpreted as the column number in the off-center elevation screen. For
instance, a value of 3 would indicate that this edge should follow the lateral position of the
column labeled 3 on the appropriate off-center elevation screen. This is most often used with
variable width roads to have the animation shape widen and narrow with the road.
11 Units for the lower lateral limit. This determines units in which the lower lateral limit will be
interpreted. Options are meters or edge. Generally, units of edge are only used with variable
width roads to cause the shapes to widen or narrow with the road. In this case, edge refers to
the column number in the off-center elevation dataset. Please note that if no dataset is linked
to in the first of the two links 4 in Figure 7 (page 14), the edge is not defined, and the lane
will not appear in the animator.
12 Upper lateral limit for each lane. This determines the lateral definition of the shape.
Depending on the selection of 13 , this can be specified in units of meters or by the off-
center elevation edge number. If edge is selected in 13 , the first link of the two Road: Off-
Center Elevation Map or Road: Off-Center Elevation Map, Variable Width links 4 in
Figure 7 (page 14) is used to determine the lateral limit of this edge of the lane. The number
in the field is interpreted as the column number in the off-center elevation screen. For
instance, a value of 3 would indicate that this edge should follow the lateral position of the
column labeled 3 on the appropriate off-center elevation screen. This is most often used with
variable width roads to have the animation shape widen and narrow with the road.
13 Units for the upper lateral limit. This determines units in which the upper lateral limit will be
interpreted. Options are meters or edge. Generally, units of edge are only used with variable
width roads to cause the shapes to widen or narrow with the road. In this case, edge refers to
the column number in the off-center elevation dataset. Please note that if no dataset is linked
to in the first of the two links 4 in Figure 7 (page 14), the edge is not defined, and the lane
will not appear in the animator.
14 Lateral number of divisions. Each lane shape is made up of a series of rectangles. Normally,
a single rectangle can be used to cover the lateral extents of the lane. If the lane has
significant transverse elevation changes, this field allows you to add extra sub-divisions to
add more detail in the geometry (Figure 21). However, more sub-divisions means the shape
files will be larger, take longer to load, and may slow down the animator.
If not specified, a single rectangle will be sized to match the lane width.
Figure 23. The Road: Animator Surface Shapes screen scrolled to the right.
19 Longitudinal interval. A rectangle is defined at each interval going over the longitudinal
range of the lane. If the road is straight and flat, the interval can be as large as the range
covered. For roads with curves or vertical changes, the interval should be short enough to
show the surface shape (Figure 24). However, a smaller interval means the shape files are
larger and take longer to load. A smaller interval can also slow down the animator. If not
specified, a default value of 2 meters is used.
every third, and so on. This option is included to make it efficient to generate checkerboard
or stripe patterns.
Discussion
Road geometry is defined using a coordinate system relative to the road design line (typically the
centerline): station (S) is the distance along that line, and lateral distance (L) is the distance
perpendicular to the design line. On the other hand, the animator requires all objects to be located
using global X-Y-Z coordinates. The purpose of this screen is to allow a common type of object
such as a traffic cone or roadside tree to be copied many times and located using either road S-L
coordinates or global X-Y coordinates.
By itself, the information on this screen is not sufficient to define the locations of the repeated
object. However, when combined with the horizontal and vertical geometry in linked datasets
from the Roads: 3D Surface screen, there is enough information to transform the coordinates.
The transformations are done by the same routines used in the VS solvers when the Roads: 3D
Surface screen is visible. Because the transformation depends on several datasets, including the
one defined with this screen, the transformations should be updated whenever a change is made to
any of the linked datasets, including this one.
User Settings
1 Link to an animator object or group. This object or group will be shown by the animator
at every location defined in the table 5 .
3 Plot of the locations of the repeated object. The plot shows the contents of the table 5
graphically. If the S-L coordinates are selected in the drop-down list 4 , lateral position
appears on the vertical axis and station on the horizontal axis. When applied by the
animator, the line of zero lateral position will follow the road design path as it curves
through 3D space. If the X-Y coordinates are selected in the drop-down list 4 , the Y
coordinate appears on the vertical axis and the X coordinate on the horizontal axis. The
plot is scaled automatically to fill the available space.
Since adding objects such as trees may be done better visually than by coordinates of
points, this plot has a unique set of controls. These controls are listed below and can be
accessed by right mouse button clicking on the plot.
1. Add Point. Ctrl + left mouse button.
2. Select Point. Left mouse button on point.
3. Move Nearest Point. Left mouse button on empty area of graph.
4. Move Selected Point. Left mouse button drag selected point.
5. Delete Selected Point. Delete or Backspace.
4 Drop-down list for specifying the type of coordinates. Options are S-L coordinates or X-Y
coordinates.
5 Table of locations. Each row in this table will result in a copy being shown of the animator
object or group 1 . Each row has two numbers: either S and L or X and Y depending on the
selection of the drop-down list 4 . The conversion of these values to global XYZ values is
done from the Roads: 3D Surface screen, using the horizontal and vertical geometry
datasets that are also linked to that screen.
The values are shown and edited using the same spreadsheet or text field used for other
tables, as described in the VehicleSim Browser Reference Manual, and the same buttons and
controls are provided under the data.
where Zt is the global Z coordinate where a tire contacts the ground, Zfixed is the ground elevation
defined as a fixed function of global X and Y coordinates (possibly using an internal
transformation to road S and L coordinates), dZrp is an elevation contribution from a roughness
profile that follows the vehicle, and Std is the distance travelled by the axle associated with the
tire.
Along with the incremental elevation Zt, the profile slope is added to the slope of the 3D surface,
in direction XT (X coordinate of the Tire axis system).
Profile Measurement
Roughness profiles are measured by many highway agencies to evaluate the conditions of
existing roads. Instrumented vehicles travel over the road to measure the pavement elevation in
the left- and right-hand wheel tracks. The measurements are typically limited in bandwidth to
include spatial frequencies (the inverse of wavelength, with units of cycle/m) that affect rigid-
body vehicle dynamics in the range of 0.5 – 50 Hz at typical speeds. Vertical resolution is
typically better than 0.5 mm, with sampling intervals of a few centimeters.
High-speed profiling devices usually do not have an accurate static reference for elevation; they
obtain a reference elevation of each profiling measuring instrument by doubly-integrating a
vertical accelerometer signal (with high-pass filtering to eliminate signal bias).
For more information about road profile measurement technology, see The Little Book of
Profiling. (The Little Book was written in 1996 to provide an overview of road profiling
technology for users of profiling instruments and the data obtained.) The PDF file for The Little
Book is in the Help menu of the CarSim and TruckSim browsers, and can be obtained via the
Internet at:
http://deepblue.lib.umich.edu/handle/2027.42/21605
User Settings
1 Pull-down control to specify the table interpolation. Options are as follows: constant; linear
interpolation & looping; and linear interpolation, flat-line extrapolation. If linear
interpolation, flat-line extrapolation is chosen, the button Make Looped Profiles 4 is
active; otherwise, it is not.
2 Table for the roughness profile for wheels on the left side of the vehicle. The first column is
the independent variable distance, and the second column specifies the elevation to be added
to the road surface.
3 Table for the roughness profile for wheels on the right side of the vehicle. The first column
is the independent variable, distance, and the second column specifies the elevation to be
added to the road surface.
4 Make Looped Profiles button. Use this button to modify a table which was not originally
designed to loop, into one which is continuous, using a cosine taper filter. This button is
only active when the table type 1 is set to linear interpolation, flat-line extrapolation.
When pressed the following pop-up window appears.
This pop-up allows you to specify the percentage of each side that will be used to make the
table continuous. The filter smoothly attenuates the beginning and ending portions of the
table and adds them together. After the Calculate Looped Profiles button is clicked, the
filter will be applied, and the table will loop.
This button is dimmed if the profile is already looped.
References
1. SAE International Surface Vehicle Recommended Practice, “Vehicle Dynamics
Terminology,” SAE Standard J670, Rev. 2008-01-24.
2. International Organization for Standardization, “Road vehicles — Vehicle dynamics and
road-holding ability — Vocabulary,” ISO Standard 8855, Rev. 2010 (pending, to replace
1991).