Page 1 of 1

estimating ground reaction forces using forward dynamics

Posted: Mon Oct 21, 2019 1:54 am
by flaaaj
Hello again,

My objective is to estimate ground reaction forces and moments produced by a walking human. All data I have is the mass of the subject and recorded markers. GRF/Ms don't have to be accurate, just estimations. What I've already done:

1. Succesfully applied markers and scaled a model
2. Used inverse kinematics
3. inserted results of IK into CMC (with Tasks and Actuators files from model2354), to get controls file
4. Modelled contacts using 3 spheres (or in alternative version - 2 spheres, which can be more correct given inaccuracy of foot markers placement)

Now I'm having a problem with forward dynamics. I am using controls file generated with CMC and the same actuators file as in CMC. But when running Forward Dynamics my model doesn't move as it should. So now I have some questions

1.Which contact model should I use? ElasticFoundation or HuntCrossley?
2. Should I enable contacts during CMC or it doesn't impact the computation process?
3. If you noticed I already did something wrong feel free to correct me

I really need some help :(

Re: estimating ground reaction forces using forward dynamics

Posted: Thu Oct 24, 2019 3:14 am
by flaaaj
up :(

Re: estimating ground reaction forces using forward dynamics

Posted: Thu Oct 24, 2019 4:24 am
by mitkof6
Hi,

The approach you use will not work, because when you solve for the muscle excitations you will have to account for the work done to counterbalance the ground reactions, which you do not know. You will have to treat ground reaction forces and muscle excitations as unknowns because the forces are sensitive to the foot placement prescribed by the kinematics. You can look into the predictive simulation approach used in Moco or SCONE

https://simtk-confluence.stanford.edu/p ... w/36439019

https://simtk.org/projects/scone/

Re: estimating ground reaction forces using forward dynamics

Posted: Thu Oct 24, 2019 10:22 am
by flaaaj
So it's not doable in opensim alone (estimating GRF/Ms) ? Thanks, that's the answer I needed. Not sarcasm. My teacher told me it can be done in opensim and I wasted few weeks trying to do it.

Re: estimating ground reaction forces using forward dynamics

Posted: Thu Oct 24, 2019 11:41 am
by mitkof6
It is possible, but not through CMC in the way that you tried. The way it is currently done, is to attach contact geometries on the feet and the ground and try to generate plausible behaviors without prescribing the kinematics. Also, with Moco and SCONE it might be possible to try to mimic the kinematics while predicting the ground reaction forces and muscle excitations.

Re: estimating ground reaction forces using forward dynamics

Posted: Thu Oct 24, 2019 12:59 pm
by flaaaj
Ok. And how to "generate plausible behaviors"? The only thing that comes to my mind is to attach forces to bodies' centers of mass so that F=ma (while getting 'a' by double-diffrentiating CoM positions) is fulfilled, but I guess that would be too easy.

When it comes to predictive simulations, I'm already using 3dpredictsim framework and it's more-less working right now. Will surely try SCONE (since MOCO is unavailable right now). But I got the task to predict GRFs in OpenSim so it would be nice if there was a way :P

Re: estimating ground reaction forces using forward dynamics

Posted: Sat Oct 26, 2019 6:03 pm
by vinaym815
Hello Michal and Dimitar,

If you consider the phase of the motion when the subject has one foot in contact with the ground. You can assume that the foot is attached to ground, and the problem becomes analogous to a fully actuated serial link manipulator (degrees of freedom = degrees of actuation). You can compute the joint torques uniquely. Then you can resolve these joint torques into corresponding muscle forces using static optimization. Once you have the joint torques, you can actuate another human model which has a feet-ground contact formulation to obtain the joint torques.

When both of the subject's feet are in contact with the ground, you end with a closed-loop (ground, right leg, hip, left leg, ground). Due to this closed-loop, you end up with an overactuated mechanism (Degrees of actuation > Degrees of freedom). In this case, you can not solve the dynamical equation for a unique set of joint torques. I think you require some sought of optimization to resolve the joint torques uniquely. Once you have the joint torques, you can move same as above and obtain the muscle forces and GRFs.

For an over actuated mechanisms, if you use MOCO or scone to obtain a set of joint torques, you will arrive one of the many possible non-unique solutions. The results won't be repetitive between different sets of simulations.

I might be wrong here, so I will like your opinions about this.

Re: estimating ground reaction forces using forward dynamics

Posted: Mon Oct 28, 2019 2:00 am
by mitkof6
Hi, thank you for your post. It sounds good, but I am not sure how well it will perform.

If your goal is to predict the ground reaction forces from the motion alone, then you can try one of the following methods:

https://link.springer.com/article/10.10 ... 016-9537-4
https://projekter.aau.dk/projekter/file ... se2015.pdf
https://research.utwente.nl/en/publicat ... -tools-for
https://www.sciencedirect.com/science/a ... 9018300861

I am sure you can also find alternative methods (e.g., machine learning). It would be nice if this can be implemented as a plugin in OpenSim and shared so that others can also use it.

Re: estimating ground reaction forces using forward dynamics

Posted: Wed Mar 22, 2023 7:10 am
by lucasmoca
Hello Michal, Dimitar, Thomas

I am currently working on a similar project to compute ground reaction forces and torques based on kinematics of human gait, deduced by motion capture. The goal is to get rid of expensive instrumentized treadmills and rely solely on motion capture.
The ressources you provided were very informative.

I was wondering if this issue had resulted in more recent progress for developping such a tool for the OpenSim API ?

Thank you for time,

Lucas