Main Content

simscape.multibody.WorldFrame class

Package: simscape.multibody
Superclasses: simscape.multibody.Component

Construct world frame

Description

Use an object of the simscape.multibody.WorldFrame class to construct a world frame. In a simscape.multibody.Multibody object, the world frame is the global reference frame that is fixed and impervious to any applied forces and moments.

The WorldFrame object has one frame whose axes are orthogonal and arranged based on the right-hand rule. The frame has a corresponding connector called W. Directly connecting another object to the W connector makes that object motionless. A Multibody object may have multiple WorldFrame objects, but all the WorldFrame objects refer to the same world frame.

Class Attributes

Sealed
true
ConstructOnLoad
true
RestrictsSubclassing
true

For information on class attributes, see Class Attributes.

Creation

Description

wf = simscape.multibody.WorldFrame constructs a world frame.

Examples

collapse all

  1. Use a simscape.multibody.WorldFrame object to create a world frame.

    world = simscape.multibody.WorldFrame;
  2. Add the WorldFrame object to a simscape.multibody.Multibody object.

    First, use a Multibody object to construct a multibody system. Then, add the WorldFrame object to the multibody system by using the addComponent method.

    mb = simscape.multibody.Multibody;
    addComponent(mb,"World",world);
    
  3. Use a simscape.multibody.Solid object to construct a solid with default values. Then, add the Solid object to the multibody system.

    solid = simscape.multibody.Solid;
    addComponent(mb,"Solid",solid);
  4. Connect the Solid object to the world frame by using the connect method.

    connect(mb,"World/W","Solid/R")

Version History

Introduced in R2022a