Skip to content

[Feature]: Define Joint Spline behaviour outside of its bounds#2908

Description

@MegMll

馃殌 Feature

The joint spline, is so far only defined between its bounds $[q_{min}, q_{max}]$. In other software, such as scipy or opensim, linear extrapolation is done to avoid undefined behaviour outside of the bounds.
Here is a proposition for linear extrapolation for the joint spline :

  • Check if $q_{min} < q < q_{max}$
  • If not, evaluate the spline at the nearest endpoint, either $q_{min}$ or $q_{max}$, e.g compute S and M
  • Extrapolate the transform using the endpoint twist

$$ G(q) = M_{min \ or \ max} exp((q - q_{min \ or \ max})S_{min \ or \ max}) $$

To speed up the process, when the joint is build, we can precompute $M_{min}$, $M_{max}$, $S_{min}$ and $S_{max}$

@LucasJoseph @jorisv @lpuch

Motivation

To match opensim SimmSpline behaviour.

Alternatives

No response

Additional context

It will have to wait for #2784 to be merged, before it is investigated.

Checklist

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions