Page 2 of 2

Re: OpenSim API: problem of muscle force velocity function with Millard muscle type

Posted: Mon Nov 21, 2022 7:00 am
by jsn-74
Thanks Mr. Uchida for this idea. It works only with Opensim4.4, right ? With Opensim 4.1 python scripting, I get a "'Millard2012EquilibriumMuscle' object has no attribute 'getFiberVelocityInfo'" error. For test purpose, please attached find py test script, the associated models and matplotlib figures highlighting the problem...

Re: OpenSim API: problem of muscle force velocity function with Millard muscle type

Posted: Fri Feb 03, 2023 2:47 am
by jsn-74
Hi everyone, unfortunately I confirm that this bug still exists in Opensim 4.4 (with python 3.8). The force-velocity multiplier remains totally flat. If anyone has an idea, it would be greatly appreciated, as this topic seems to have been ignored for months :?

Re: OpenSim API: problem of muscle force velocity function with Millard muscle type

Posted: Tue Apr 25, 2023 2:04 am
by jsn-74
Changing one property for all Millard muscles leads to the expected simulation :
<ignore_tendon_compliance>false</ignore_tendon_compliance>

Re: OpenSim API: problem of muscle force velocity function with Millard muscle type

Posted: Wed Apr 26, 2023 9:01 am
by kernalnet
Hi, in Millard2012EquilibriumMuscle both set_ignore_tendon_compliance and computeEquilibrium influence the force-velocity multiplier values, i.e.:

Code: Select all

ignoreTendonCompliance     computeEquilibrium     ForceVelocityMultiplier
        False                     False                     0
        False                     True                      1
        True                      False                     values
        True                      True                      values
More info can be found here:
https://github.com/opensim-org/opensim- ... #L537-L556
https://github.com/opensim-org/opensim- ... #L742-L896

I'm not sure if this is a bug. In this paper for instance, Muscle coordination retraining inspired by musculoskeletal simulations reduces knee contact force, compliant tendons were incorporated followed by equilibrateMuscles, and hence, force-velocity relationship was excluded (ForceVelocityMultiplier==1).