Skip to content
LIBRARY
AbsoluteAngles.md

AbsoluteAngles

Measures absolute Euler/Cardan angles of a frame relative to the world.

Computes the three rotation angles of frame_a for the given axis sequence (default: [1,2,3] = XYZ). This is a sensor: no forces or torques are exerted.

Usage

MultibodyComponents.AbsoluteAngles()

Parameters:

NameDescriptionUnitsDefault value
sequence[1, 2, 3]

Connectors

  • frame_a - Frame3D is the fundamental 3D connector used for 6DOF motion. Most components have one or several Frame

connectors that can be connected together (Frame3D)

  • angle_1 - This connector represents a real signal as an output from a component (RealOutput)

  • angle_2 - This connector represents a real signal as an output from a component (RealOutput)

  • angle_3 - This connector represents a real signal as an output from a component (RealOutput)

Variables

NameDescriptionUnits
anglesrad

Behavior

Dict{MIME{Symbol("text/plain")}, String} with 1 entry: MIME type text/plain => "Error displaying result"

Source

dyad
"""
Measures absolute Euler/Cardan angles of a frame relative to the world.

Computes the three rotation angles of `frame_a` for the given axis
`sequence` (default: [1,2,3] = XYZ).
This is a sensor: no forces or torques are exerted.
"""
component AbsoluteAngles
  frame_a = Frame3D() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": -50, "y1": 450, "x2": 50, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
  angle_1 = RealOutput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 960, "y1": 100, "x2": 1060, "y2": 200, "rot": 0}
      },
      "tags": []
    }
  }
  angle_2 = RealOutput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 960, "y1": 450, "x2": 1060, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
  angle_3 = RealOutput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 960, "y1": 780, "x2": 1060, "y2": 880, "rot": 0}
      },
      "tags": []
    }
  }
  structural parameter sequence::Integer[3] = [1, 2, 3]
  variable angles::Angle[3]
relations
  # Sensor exerts no forces or torques
  frame_a.f = [0, 0, 0]
  frame_a.tau = [0, 0, 0]
  # Extract angles from absolute orientation
  angles = axes_rotationangles(frame_a.R, sequence)
  [angle_1, angle_2, angle_3] = angles
metadata {
  "Dyad": {
    "icons": {"default": "dyad://MultibodyComponents/OneFrameSensor.svg"},
    "labels": [
      {
        "label": "$(instance)",
        "x": 500,
        "y": 150,
        "rot": 0,
        "attrs": {"font-size": "140"}
      },
      {"label": "abs ang", "x": 500, "y": 680, "rot": 0}
    ]
  }
}
end
Flattened Source
dyad
"""
Measures absolute Euler/Cardan angles of a frame relative to the world.

Computes the three rotation angles of `frame_a` for the given axis
`sequence` (default: [1,2,3] = XYZ).
This is a sensor: no forces or torques are exerted.
"""
component AbsoluteAngles
  frame_a = Frame3D() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": -50, "y1": 450, "x2": 50, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
  angle_1 = RealOutput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 960, "y1": 100, "x2": 1060, "y2": 200, "rot": 0}
      },
      "tags": []
    }
  }
  angle_2 = RealOutput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 960, "y1": 450, "x2": 1060, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
  angle_3 = RealOutput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 960, "y1": 780, "x2": 1060, "y2": 880, "rot": 0}
      },
      "tags": []
    }
  }
  structural parameter sequence::Integer[3] = [1, 2, 3]
  variable angles::Angle[3]
relations
  # Sensor exerts no forces or torques
  frame_a.f = [0, 0, 0]
  frame_a.tau = [0, 0, 0]
  # Extract angles from absolute orientation
  angles = axes_rotationangles(frame_a.R, sequence)
  [angle_1, angle_2, angle_3] = angles
metadata {
  "Dyad": {
    "icons": {"default": "dyad://MultibodyComponents/OneFrameSensor.svg"},
    "labels": [
      {
        "label": "$(instance)",
        "x": 500,
        "y": 150,
        "rot": 0,
        "attrs": {"font-size": "140"}
      },
      {"label": "abs ang", "x": 500, "y": 680, "rot": 0}
    ]
  }
}
end


Test Cases

No test cases defined.