Position of ankle relative to hip calculated from IMU on thigh and leg

I want to Assess where someone's ankle is relative to their hip. I have an IMU on the thigh and leg/shin (capturing orientation) and know the lengths of these. I want to know the distance down, across and forward between the hip and ankle. Is there code already suited for this application?

I have an IMU on the persons lower back and want the direction of forward/back and side/side to be relative to this IMU i.e the way the persons facing, defines what is forward.

Work out the trigonometry on paper and post a diagram, so forum members can clearly understand the problem.

The C/C++ equation(s) should fit into a line or two of Arduino code, which supports standard tangent, cosine, sine and their inverse functions.

1 Like

I don't have the knowledge to work out the trigonemetry

float D = L*sin(alpha); // alpha in radians

junk

1 Like

Twenty-one minutes.

Thirty-two minutes.

tl;dr:
c^2 = a^2 + b^2

1 Like

Ah .... SOH CAH TOA.

I remember it well from maths lessons in the late 60s.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.