| SimMechanics | ![]() |
Representing Body Positions and Orientations
Machines are composed of bodies, which have relative degrees of freedom (DoFs). Bodies have positions, orientations, mass properties, and sets of Body coordinate systems. Joints represent the motions of the bodies.
The full description of a machine's motion includes not only its kinematics, but specification of its observers, who define reference frames (RFs) and coordinate systems (CSs) for measuring the machine motion.
This section summarizes observer coordinate systems, measuring body motion, forms of body rotation, and how SimMechanics represents the state of a machine's motion.
All vectors and tensors (matrices), unless otherwise noted, are Cartesian with three and nine, respectively, spatial components measured by orthogonal or rectangular coordinate axes. This section assumes basic knowledge of vector algebra and analysis. The books of Goldstein [2] and Murray, Li, and Sastry [11] present coordinate transformations, rotations, and rigid body kinematics in detail.
Reference Frames and Coordinate Systems
The reference frame of an observer is an observer's state of motion, which has to be measured by other observers. The Newtonian dynamics of a mechanical system take their simplest form in the special set of inertial RFs, the set of all frames moving at uniform velocities with respect to one another. Within an RF, you can pick any point as a coordinate system origin, then set up Cartesian (orthogonal) axes there.
SimMechanics uses a master inertial RF called World. A CS origin and axis triad are also defined in World. World can mean either the RF or the CS, although in most contexts, the coordinate system is indicated. For SimMechanics, World defines absolute rest and a universal coordinate origin and axes independent of any bodies and grounds in a machine.
Relating Moving Coordinate Systems
Add a second CS, called O, whose origin is translating with respect to the World origin and whose axes are rotating with respect to the World axes.
A vector C represents the origin of O. Its head is at the O origin and its tail at the World origin. The O origin translates as some arbitrary function of time C(t).
The orthogonal unit vectors {u(x), u(y), u(z)} define the coordinate axes of O.
e(x), e(y), e(z)}. The tilt changes with time.
u(x), u(y), u(z)} as a linear combination of the basis {e(x), e(y), e(z)} in terms of nine coefficients:
u(x) = Rxx e(x) + Ryx e(y) + Rzx e(z)
u(y) = Rxy e(x) + Ryy e(y) + Rzy e(z)
u(z) = Rxz e(x) + Ryz e(y) + Rzz e(z)
These are relationships between vectors (not vector components) and are independent of reference frame and coordinate system.
u's with the e's:
ux(x) = Rxx , uy(x) = Ryx , uz(x) = Rzx
ux(y) = Rxy , uy(y) = Ryy , uz(y) = Rzy
ux(z) = Rxz , uy(z) = Ryz , uz(z) = Rzz
The time-dependent R coefficients represent the orientation of the u's with respect to the e's. You can replace the labels (x,y,z) by (1,2,3).
v measured in World are e(i)*v. Represent them by a column vector vWorld. The components of v in O are u(i)*v. Represent them by a column vector vO. The two sets of components are related by the matrix transformation vWorld = R* vO. The coefficients R form a matrix whose columns are the components of the u's in World:
The orthogonality and unit length of the u's guarantee that R is an orthogonal rotation matrix satisfying RRT = RTR = I, the identity matrix. RT is the transpose of R (switch rows and columns). Thus R-1 = RT.
Observing Motion in Different Coordinate Systems
To the two observer CSs, World and O, now add a third point p(t) in arbitrary motion. p could represent a point mass, the center of gravity (CG) of an extended body, or a point fixed in a moving rigid body, for example. The two observers describe the motion of this point in different ways, related to one another by time-dependent World-to-O coordinate transformations.
The motion of p is given by its column vector components in some CS. The components of p as measured in World are a column vector pWorld and, measured in O, are a column vector pO. The two descriptions are related by
Thus the motion as measured by pWorld, when transformed and observed by O as pO, has additional time dependence arising from C(t) and R(t).
Relating Velocities Observed in Different Coordinate Systems
Differentiate once with respect to time the relationship between pWorld and pO. The result relates the velocity of p as measured by O to the velocity as measured in World.
The section The Angular Velocity of a Body from Its Rotation Matrix following explains how to express the third term in a simpler form.
| Understanding Mechanical Concepts | Observing a Translating, Rotating Rigid Body | ![]() |
Learn more about the latest releases of MathWorks products: |
| © 1994-2009 The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |