Page 1 of 1

Static Optimization in Matlab

Posted: Fri Mar 05, 2021 7:52 am
by amreinsa
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.

Re: Static Optimization in Matlab

Posted: Mon Mar 08, 2021 3:30 pm
by ongcf
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.

Re: Static Optimization in Matlab

Posted: Fri Oct 29, 2021 10:26 am
by ajyoder
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=

Re: Static Optimization in Matlab

Posted: Tue Nov 29, 2022 6:04 am
by mokmeka
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