## Documentation Center |

On this page… |
---|

To represent a solid using the `Revolution` or `General
Extrusion` shapes, you must provide the cross-section
coordinates for that solid. For example, to represent a beam with
a trapezoidal cross-section, you must provide the coordinates for
that trapezoid. You must enter these coordinates according to a set
of rules that ensure SimMechanics™ properly represents the cross-section
shape.

The Solid block accepts the cross-section coordinates as an M×2 matrix. This matrix contains M rows, each with the coordinates of a cross-section point. Enter the coordinates sequentially: SimMechanics connects adjacent coordinate pairs with a straight line to represent the complete cross-section shape.

The figure shows the cross-section of a trapezoidal beam. SimMechanics connects
adjacent points with straight lines, so you need to provide only four
points. The figure labels these points A, B, C, and D. Specify the
coordinates for these points in the order [A; B; C; and D]. Using
the point coordinates in the figure, the MATLAB^{®} matrix for the
trapezoid cross-section is:

trapezoid = [X_A, Y_A; X_B, Y_B; X_C, Y_C; X_D, Y_D]

SimMechanics automatically connects the first and last points of a coordinate matrix. This ensures that every cross-section path is closed. For example, in the trapezoid cross-section, SimMechanics automatically connects point D to point A. The result is a closed trapezoid path that SimMechanics can extrude.

You can enter the MATLAB matrix directly in the **Cross-Section** parameter
of the Solid block. The figure shows an example. You can replace the
X and Y coordinates with the numerical values directly, or you can
define their values elsewhere, e.g., a subsystem mask or the model
workspace.

Any boundary path separates the dense and hollow regions of a cross-section. The dense region is to the left of the path, and the hollow region is to its right. The figure illustrates how a cross-section path divides dense and hollow regions.

Always enter the cross-section coordinates so that the dense
region is to the left of the arrow connecting one coordinate pair
to the next. For example, to represent the trapezoidal cross-section
in the figure, enter the coordinates in the order `[A B C
D]`. This matrix specifies that the dense region is to the
left of the arrows connecting A to B, B to C, C to D, and D to A.

A cross-section need not be dense. You can specify a hollow cross-section. One example is the cross-section of a box beam. This cross-section has a rectangular shape with a dense area at the periphery, and a hole at the center. The figure shows that cross-section.

As with dense cross-sections, you specify a hollow cross-section as a single path. To do this, you must cut the cross-section across its dense region. By cutting the cross-section, you can merge the inner and outer paths into a single path. The figure shows the cut box beam cross-section.

The cut connects the first and last cross-section coordinate pairs. As with dense cross-sections, you must specify the coordinate pairs so that the dense region is to the left of the path. A counterclockwise order satisfies this requirement for the outer portion of the path. A clockwise order satisfies this requirement for the inner portion of the path. Always specify all coordinates as a single path—not as two paths. You do this by connecting the inner and outer portions of the path through the cut.

The figure shows the order that you specify the cross-section
coordinates in. The cut joins the last outer path point to the first
inner path point. You specify the outer path in a counterclockwise
order: `[A, B, C, D, E]`. You specify the inner path
in a clockwise order: `[F, G, H, I, j]`. The entire
coordinate matrix is `[A, B, C, D, E, F, G, H, I, J]`. SimMechanics automatically
closes the path by connecting the last point that you specify (J)
to the first point (A).

To connect the outer path to the inner path through the cut, you must repeat the first point of each path. For the outer path, you repeat point A (labeled E). For the inner path, you repeat point F (labeled J). Omitting these points distorts the cross-section that you specify. The figure shows the cross-section that results if you omit point E. As before, SimMechanics automatically closes the path by connecting the last point that you specify (J) to the first point (A).

The coordinate matrix must define a path that does not self-intersect. If the path intersects itself at any point, SimMechanics issues an error and the model does not simulate. Path intersection is a common error source in hollow cross-sections. The figure shows a self-intersecting path.

Was this topic helpful?