symbrim.core.attachment.Hub

class symbrim.core.attachment.Hub(frame: ReferenceFrame, point: Point, axis: str | Vector)

Bases: Attachment

Joint attachment for pin joints.

Explanation

This class is used to define the attachment points of pin joints. It extends symbrim.core.attachment.Attachment by specifying an additional rotation axis property.

Attributes

axis

Rotation axis of the hub.

frame

Reference frame of the attachment.

point

Point of the attachment.

Methods

__init__

from_name

Create a hub based on a name and an axis.

to_valid_joint_arg

Convert the attachment to a massless body.

__init__(frame: ReferenceFrame, point: Point, axis: str | Vector) None
__weakref__

list of weak references to the object (if defined)

property axis: Vector

Rotation axis of the hub.

property frame: ReferenceFrame

Reference frame of the attachment.

classmethod from_name(name: str, axis: str) Hub

Create a hub based on a name and an axis.

property point: Point

Point of the attachment.

to_valid_joint_arg(name: str | None = None) MasslessBody

Convert the attachment to a massless body.

Explanation

This method is used to convert an attachment to a massless body. This is necessary because sympy’s joints framework does not yet support passing only a frame and point to the joint constructor. Therefore, this method may be removed once this functionality is added to sympy.