Static Optimization in Matlab

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Sabrina Amrein
Posts: 3
Joined: Thu Nov 19, 2020 5:22 am

Static Optimization in Matlab

Post by Sabrina Amrein » Fri Mar 05, 2021 7:52 am

Hi,

I have a specific question regarding static optimization using matlab. The file I'm trying to use (attached as .txt) allows me to specify external forces, however, there is no option to append my model with reserve and residual actuators. Hence, the resulting muscle forces are markedly higher than expected.

Is it possible to include such an actuators file in the matlab code (or C++ code, also attached)? Both files are part of "Wu's musculoskeletal model for evaluating shoulder muscle and joint force". They both are based on version 3.3.
Attachments
StaticOptimizationMatlab.txt
(8 KiB) Downloaded 91 times
JR3_mex_parent_source.cpp
(3.39 KiB) Downloaded 66 times

Tags:

User avatar
Carmichael Ong
Posts: 401
Joined: Fri Feb 24, 2012 11:50 am

Re: Static Optimization in Matlab

Post by Carmichael Ong » Mon Mar 08, 2021 3:30 pm

You can perform Static Optimization by making an AnalyzeTool object, and then adding a StaticOptimization object to the AnalyzeTool.

AnalyzeTool has a "getAnalysisSet()" method to grab the analysis set, and then the analysis set will have a "cloneAndAppend(staticoptimization)" method to add the StaticOptimization object.

The AnalyzeTool also has methods such as "setForceSetFiles()" and "setExternalLoadsFileName()" to append additional forces and actuators.

User avatar
Adam Yoder
Posts: 16
Joined: Thu Jul 19, 2012 4:24 pm

Re: Static Optimization in Matlab

Post by Adam Yoder » Fri Oct 29, 2021 10:26 am

The setForceSetFiles() method doesnt actually appear to be working in MATALB API 4.3

More detail and a scripting work-around to append needed actuators here:
viewtopicPhpbb.php?f=91&t=11013&p=40469&start=0&view=

User avatar
Thomas Mokadim
Posts: 4
Joined: Thu Jul 22, 2021 4:13 am

Re: Static Optimization in Matlab

Post by Thomas Mokadim » Tue Nov 29, 2022 6:04 am

Hi Adam, I am about to code a simulation also based on those tools ( Static Opti + some external forces appended to my model, the whole thing being monitored by Matlab )

Did you manage to get through your bugs ?

Thanks

POST REPLY