---
url: /dyad/stable/stdlib/MultibodyComponents/examples/tests.RevolutePendulumRef.md
description: >-
  Dyad tests.RevolutePendulumRef docs.  A pendulum using a Revolute joint with
  axis [0, 0, 1], used as a reference to verify the Spherical joint: a spherical
  pendulum started in a ...
---

# `tests.RevolutePendulumRef` {#tests.RevolutePendulumRef}

# Revolute Pendulum (reference for Spherical joint tests) {#Revolute-Pendulum-reference-for-Spherical-joint-tests}

A pendulum using a Revolute joint with axis \[0, 0, 1], used as a reference to verify the Spherical joint: a spherical pendulum started in a vertical plane with zero angular velocity stays in that plane and must follow the same trajectory as this revolute pendulum with matching initial deflection. The geometry (rod, body) matches `SphericalPendulumQuatJoint` and `SphericalPendulumConstraint`.

## Usage {#Usage}

`MultibodyComponents.tests.RevolutePendulumRef()`

## Behavior {#Behavior}

## Source {#Source}

```dyad
"""
# Revolute Pendulum (reference for Spherical joint tests)

A pendulum using a Revolute joint with axis [0, 0, 1], used as a reference
to verify the Spherical joint: a spherical pendulum started in a vertical
plane with zero angular velocity stays in that plane and must follow the
same trajectory as this revolute pendulum with matching initial deflection.
The geometry (rod, body) matches `SphericalPendulumQuatJoint` and
`SphericalPendulumConstraint`.
"""
example component RevolutePendulumRef
  world = MultibodyComponents.World() {}
  joint = MultibodyComponents.Revolute(n = [0, 0, 1]) {}
  rod = MultibodyComponents.FixedTranslation(r = [1.0, 0, 0]) {}
  body = MultibodyComponents.Body(m = 1) {}
relations
  connect(world.frame_b, joint.frame_a) {}
  connect(joint.frame_b, rod.frame_a) {}
  connect(rod.frame_b, body.frame_a) {}
end
```

```dyad
"""
# Revolute Pendulum (reference for Spherical joint tests)

A pendulum using a Revolute joint with axis [0, 0, 1], used as a reference
to verify the Spherical joint: a spherical pendulum started in a vertical
plane with zero angular velocity stays in that plane and must follow the
same trajectory as this revolute pendulum with matching initial deflection.
The geometry (rod, body) matches `SphericalPendulumQuatJoint` and
`SphericalPendulumConstraint`.
"""
example component RevolutePendulumRef
  world = MultibodyComponents.World() {}
  joint = MultibodyComponents.Revolute(n = [0, 0, 1]) {}
  rod = MultibodyComponents.FixedTranslation(r = [1.0, 0, 0]) {}
  body = MultibodyComponents.Body(m = 1) {}
relations
  connect(world.frame_b, joint.frame_a) {}
  connect(joint.frame_b, rod.frame_a) {}
  connect(rod.frame_b, body.frame_a) {}
metadata {}
end
```

## Test Cases {#Test-Cases}

No test cases defined.

## Related {#Related}

* Examples

* Experiments

* Analyses
