Cost function.

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
User avatar
Andrea Morelli
Posts: 89
Joined: Thu Jan 24, 2008 1:10 pm

Cost function.

Post by Andrea Morelli » Mon Jul 14, 2008 6:52 am

Opensim currently is able to solve only tracking problem right (generate simulation that emulate existing experimental data) ?
This is true ?
It will be available in future a cost function optimization to do "what if" test ?
(p.e. optimize for metabolic cost, maximum power...)

Thank you
Andrea

User avatar
Jicheng Xia
Posts: 6
Joined: Tue Jun 03, 2008 1:53 pm

RE: Cost function.

Post by Jicheng Xia » Mon Jul 14, 2008 8:53 am

Andrea,

As far as I know, Opensim is also able to do forward simulation without existing experimental data. By changing muscle excitation pattern, you can predict the behavior of some certain patient.

You can refer to the following paper to find more information: "OpenSim: Open-Source Software to Create and Analyze Dynamic Simulations of Movement" (author: Scott L. Delp, Frank C. Anderson, etc)

Good luck,
Jicheng

User avatar
Andrea Morelli
Posts: 89
Joined: Thu Jan 24, 2008 1:10 pm

RE: Cost function.

Post by Andrea Morelli » Mon Jul 14, 2008 10:28 am

Hi Jicheng,
thank you for your answer.
I have cycling kinematics and kinetics data, I would like to optimize for example saddle position to minimize knee joint load.

I will look at your ref.
Thank you
Andrea

User avatar
Andrea Morelli
Posts: 89
Joined: Thu Jan 24, 2008 1:10 pm

RE: Cost function.

Post by Andrea Morelli » Tue Jul 15, 2008 10:48 am

I read the paper you mentioned and for what I see is possible to do "what if analysis". One of the question arise, is that in the paper the authors refere about cost function optimization but on another paper where it was done with SIMM.
So i not understand yet if this is possible in Opensim or not.

Thank you for your support.
Andrea

User avatar
Ayman Habib
Posts: 2235
Joined: Fri Apr 01, 2005 12:24 pm

RE: Cost function.

Post by Ayman Habib » Tue Jul 15, 2008 11:32 am

Hi Andrea,

In this context (tracking), the cost function referred to is the function used in CMC to resolve the redundancy (too many muscles for the number of degrees of freedom). For now this function is fixed but we plan to expose this function (allow users to provide their own) in version 2.0 late in the summer.

-Ayman

User avatar
Andrea Morelli
Posts: 89
Joined: Thu Jan 24, 2008 1:10 pm

RE: Cost function.

Post by Andrea Morelli » Tue Jul 15, 2008 12:22 pm

Thank you for the answer.
I'm anxious to see that build.

Thank you for your continuing work
Andrea


User avatar
Nicolas Schwenck
Posts: 13
Joined: Fri Aug 15, 2008 5:29 am

optimization

Post by Nicolas Schwenck » Fri Aug 29, 2008 1:19 am

Hej,

I'm new in OpenSim and think my question is related to Andrea's.

My example is the analysis of a longjump. I have the motion capture data and the ground reaction forces. I have done the IK, ID, RRA, CMC. Now i want to do a kind of Forward Dynamics. I want to simulate a longer jump.
I would like to know if it is possible to do the Forward Dynamic "backwards"? So that I could find out, which muscles have to be stronger or do I have to run faster and so on.

Another Example: Normal Gait:
Again I have the motion capture data and the ground reaction forces. I have done the IK, ID, RRA, CMC. Now I want to simulate the gait of the same person, but with larger steps.

Is it possible to scale the kinematics easily?

User avatar
Andrew Lewis
Posts: 18
Joined: Wed Oct 22, 2008 5:58 am

RE: Cost function.

Post by Andrew Lewis » Tue Oct 26, 2010 3:22 am

Hi Ayman,
I see this thread is a couple of years old now and that OpenSim 2.0 is now released. Is it now possible to edit the cost function used in CMC?

I am currently running gait data through OpenSim 2.0 with the gait2392 and LLM2010 models and using the CMC tool to generate muscle activation data. My expertise are currently limited to manually editing the XML setup files, running scaling and IK through the OpenSim GUI and RRA/CMC through the Windows command line.

I see from the OpenSim user guide that the default CMC cost function is set to minimise total muscle activation. I am interested in changing this to try optimising on other muscle parameters (such as pennation angle). Would this be possible? If so how would I go about doing this?

Thanks for your help,
Andy

User avatar
Ayman Habib
Posts: 2235
Joined: Fri Apr 01, 2005 12:24 pm

RE: Cost function.

Post by Ayman Habib » Tue Oct 26, 2010 11:34 am

Hi Andrew,

Unfortunately nothing has changed in CMC since this post, so the cost function is still embedded inside the CMC code and users do not have access to it to change it. We're working on a mechanism to make these more available but it will take a few more months before it makes it to a release. Will keep you posted.

Good luck,
-Ayman

User avatar
Marta Meneses
Posts: 26
Joined: Thu Mar 03, 2011 2:49 am

RE: optimization

Post by Marta Meneses » Wed May 25, 2011 10:47 am

Is it possible to change the cost function of CMC in 2.2.1 release?If so, how can we do it?

Thanks,

Marta

POST REPLY