OpenSim Moco: Musculoskeletal optimal control

Musculoskeletal simulations of movement can provide insights needed to help humans regain mobility after injuries and design robots that interact with humans. Here, we introduce Open-Sim Moco, a software toolkit for optimizing the motion and control of musculoskeletal models built in the OpenSim modeling and simulation package. OpenSim Moco uses the direct collocation method, which is often faster and can handle more diverse problems than other methods for musculoskeletal simulation but requires extensive technical expertise to implement. Moco frees researchers from implementing direct collocation themselves, allowing them to focus on their scientific questions. The software can handle the wide range of problems that interest biomechanists, including motion tracking, motion prediction, parameter optimization, model fitting, electromyography-driven simulation, and device design. Moco is the first musculoskeletal direct collocation tool to handle kinematic constraints, which are common in musculoskeletal models. To show Moco’s abilities, we first solve for muscle activity that produces an observed walking motion while minimizing muscle excitations and knee joint loading. Then, we predict a squat-to-stand motion and optimize the stiffness of a passive assistive knee device. We designed Moco to be easy to use, customizable, and extensible, thereby accelerating the use of simulations to understand human and animal movement.

[1]  Michael H. Schwartz,et al.  Can altered muscle synergies control unimpaired gait? , 2019, Journal of biomechanics.

[2]  Grant Trewartha,et al.  Cervical Spine Injuries: A Whole-Body Musculoskeletal Model for the Analysis of Spinal Loading , 2017, PloS one.

[3]  Scott L. Delp,et al.  Full-Body Musculoskeletal Model for Muscle-Driven Simulation of Human Gait , 2016, IEEE Transactions on Biomedical Engineering.

[4]  Matthew S. DeMers,et al.  Changes in tibiofemoral forces due to variations in muscle activity during walking , 2014, Journal of orthopaedic research : official publication of the Orthopaedic Research Society.

[5]  Katja Mombaur,et al.  Optimal Control for Applications in Medical and Rehabilitation Technology: Challenges and Solutions , 2016 .

[6]  M. Pandy,et al.  Dynamic optimization of human walking. , 2001, Journal of biomechanical engineering.

[7]  Marcus G. Pandy,et al.  Direct Methods for Predicting Movement Biomechanics Based Upon Optimal Control Theory with Implementation in OpenSim , 2015, Annals of Biomedical Engineering.

[8]  H. Bock,et al.  A Multiple Shooting Algorithm for Direct Solution of Optimal Control Problems , 1984 .

[9]  O. V. Stryk,et al.  Numerical Solution of Optimal Control Problems by Direct Collocation , 1993 .

[10]  Jochen Triesch,et al.  OpenEyeSim: A biomechanical model for simulation of closed-loop visual perception. , 2016, Journal of vision.

[11]  Scott L. Delp,et al.  A Model of the Lower Limb for Analysis of Human Movement , 2010, Annals of Biomedical Engineering.

[12]  Hanz Richter,et al.  Optimal design and control of an electromechanical transfemoral prosthesis with energy regeneration , 2017, PloS one.

[13]  Marko Ackermann,et al.  Optimality principles for model-based prediction of human gait. , 2010, Journal of biomechanics.

[14]  Lorenz T. Biegler,et al.  On the implementation of an interior-point filter line-search algorithm for large-scale nonlinear programming , 2006, Math. Program..

[15]  D. Lloyd,et al.  An EMG-driven musculoskeletal model to estimate muscle forces and knee joint moments in vivo. , 2003, Journal of biomechanics.

[16]  Jeffrey A. Reinbolt,et al.  From the Selectedworks of Jeffrey A. Reinbolt Design of Patient-specific Gait Modifications for Knee Osteoarthritis Rehabilitation Design of Patient-specific Gait Modifications for Knee Osteoarthritis Rehabilitation , 2022 .

[17]  Deniz Erdag,et al.  Kinematic and Electromyographic Activity Changes during Back Squat with Submaximal and Maximal Loading , 2017, Applied bionics and biomechanics.

[18]  Marko Ackermann,et al.  Predictive simulation of gait at low gravity reveals skipping as the preferred locomotion strategy. , 2012, Journal of biomechanics.

[19]  Christopher A. Dicesare,et al.  Knee abduction moment is predicted by lower gluteus medius force and larger vertical and lateral ground reaction forces during drop vertical jump in female athletes. , 2020, Journal of biomechanics.

[20]  Moritz Diehl,et al.  CasADi: a software framework for nonlinear optimization and optimal control , 2018, Mathematical Programming Computation.

[21]  John McPhee,et al.  Predictive dynamic simulation of Olympic track cycling standing start using direct collocation optimal control , 2020 .

[22]  Anil V. Rao,et al.  Evaluation of Direct Collocation Optimal Control Problem Formulations for Solving the Muscle Redundancy Problem , 2016, Annals of Biomedical Engineering.

[23]  Antonie J van den Bogert,et al.  A metabolic energy expenditure model with a continuous first derivative and its application to predictive simulations of gait , 2018, Computer methods in biomechanics and biomedical engineering.

[24]  Ayman Habib,et al.  OpenSim: Open-Source Software to Create and Analyze Dynamic Simulations of Movement , 2007, IEEE Transactions on Biomedical Engineering.

[25]  Antonie J van den Bogert,et al.  Joint contact forces can be reduced by improving joint moment symmetry in below-knee amputee gait simulations. , 2016, Gait & posture.

[26]  Katja D. Mombaur,et al.  Motion Optimization and Parameter Identification for a Human and Lower Back Exoskeleton Model , 2017, IEEE Robotics and Automation Letters.

[27]  C. Hargraves,et al.  DIRECT TRAJECTORY OPTIMIZATION USING NONLINEAR PROGRAMMING AND COLLOCATION , 1987 .

[28]  Yaser Sheikh,et al.  OpenPose: Realtime Multi-Person 2D Pose Estimation Using Part Affinity Fields , 2018, IEEE Transactions on Pattern Analysis and Machine Intelligence.

[29]  J. Heegaard,et al.  Predictive algorithms for neuromuscular control of human locomotion. , 2001, Journal of biomechanics.

[30]  Ricardo Matias,et al.  A Biomechanical Model of the Scapulothoracic Joint to Accurately Capture Scapular Kinematics during Shoulder Movements , 2016, PloS one.

[31]  Antonie J van den Bogert,et al.  Estimation of gait kinematics and kinetics from inertial sensor data using optimal control of musculoskeletal models. , 2019, Journal of biomechanics.

[32]  Marko Ackermann,et al.  Searching for strategies to reduce the mechanical demands of the sit-to-stand task with a muscle-actuated optimal control model. , 2016, Clinical biomechanics.

[33]  Scott L. Delp,et al.  Predicting gait adaptations due to ankle plantarflexor muscle weakness and contracture using physics-based musculoskeletal simulations , 2019, bioRxiv.

[34]  Scott Kuindersma,et al.  Optimization and stabilization of trajectories for constrained dynamical systems , 2016, 2016 IEEE International Conference on Robotics and Automation (ICRA).

[35]  Ayman Habib,et al.  OpenSim: Simulating musculoskeletal dynamics and neuromuscular control to study human and animal movement , 2018, PLoS Comput. Biol..

[36]  Jeffrey A. Reinbolt,et al.  Erratum to "Design of patient-specific gait modifications for knee osteoarthritis rehabilitation" , 2007, IEEE Trans. Biomed. Eng..

[37]  Anil V. Rao,et al.  Exploiting Sparsity in Direct Collocation Pseudospectral Methods for Solving Optimal Control Problems , 2012 .

[38]  S. Delp,et al.  Musculoskeletal modelling deconstructs the paradoxical effects of elastic ankle exoskeletons on plantar-flexor mechanics and energetics during hopping , 2014, Journal of Experimental Biology.

[39]  M. Schwartz,et al.  Muscle synergies and complexity of neuromuscular control during gait in cerebral palsy , 2015, Developmental medicine and child neurology.

[40]  Manoj Srinivasan,et al.  Robotic lower limb prosthesis design through simultaneous computer optimizations of human and prosthesis costs , 2016, Scientific reports.

[41]  Marcus G Pandy,et al.  Grand challenge competition to predict in vivo knee loads , 2012, Journal of orthopaedic research : official publication of the Orthopaedic Research Society.

[42]  Ajay Seth,et al.  Is my model good enough? Best practices for verification and validation of musculoskeletal models and simulations of movement. , 2015, Journal of biomechanical engineering.

[43]  E. Hairer,et al.  Solving Ordinary Differential Equations II: Stiff and Differential-Algebraic Problems , 2010 .

[44]  Benjamin J Fregly,et al.  Computational Prediction of Muscle Moments During ARED Squat Exercise on the International Space Station. , 2015, Journal of biomechanical engineering.

[45]  Stephen L. Campbell,et al.  Solving higher index DAE optimal control problems , 2016 .

[46]  Emanuel Todorov,et al.  Optimal control methods suitable for biomechanical systems , 2003, Proceedings of the 25th Annual International Conference of the IEEE Engineering in Medicine and Biology Society (IEEE Cat. No.03CH37439).

[47]  A. J. van den Bogert,et al.  Metabolic cost calculations of gait using musculoskeletal energy models, a comparison study , 2019, bioRxiv.

[48]  Katja D. Mombaur,et al.  Predicting the Motions and Forces of Wearable Robotic Systems Using Optimal Control , 2017, Front. Robot. AI.

[49]  Victor M. Becerra,et al.  Solving complex optimal control problems at no cost with PSOPT , 2010, 2010 IEEE International Symposium on Computer-Aided Control System Design.

[50]  Frank C. Sup,et al.  Bilevel Optimization for Cost Function Determination in Dynamic Simulation of Human Gait , 2019, IEEE Transactions on Neural Systems and Rehabilitation Engineering.

[51]  John T. Betts,et al.  Practical Methods for Optimal Control and Estimation Using Nonlinear Programming , 2009 .

[52]  Rachel W Jackson,et al.  Muscle–tendon mechanics explain unexpected effects of exoskeleton assistance on metabolic rate during walking , 2017, Journal of Experimental Biology.

[53]  Vladimir M Zatsiorsky,et al.  Optimization-Based Models of Muscle Coordination , 2002, Exercise and sport sciences reviews.

[54]  S. Delp,et al.  Biomechanical Effects of an Injury Prevention Program in Preadolescent Female Soccer Athletes , 2017, The American journal of sports medicine.

[55]  Johannes P. Schlöder,et al.  An efficient multiple shooting based reduced SQP strategy for large-scale dynamic process optimization. Part 1: theoretical aspects , 2003, Comput. Chem. Eng..

[56]  Christopher L. Dembia,et al.  Rapid predictive simulations with complex musculoskeletal models suggest that diverse healthy and pathological human gaits can emerge from similar control strategies , 2019, Journal of the Royal Society Interface.

[57]  D. Thelen,et al.  The contribution of passive-elastic mechanisms to lower extremity joint kinetics during human walking. , 2008, Gait & posture.

[58]  Marcus G Pandy,et al.  Three-dimensional data-tracking dynamic optimization simulations of human locomotion generated by direct collocation. , 2017, Journal of biomechanics.

[59]  N. E. Toklu,et al.  Artificial Intelligence for Prosthetics - challenge solutions , 2019, The NeurIPS '18 Competition.

[60]  WächterAndreas,et al.  On the implementation of an interior-point filter line-search algorithm for large-scale nonlinear programming , 2006 .

[61]  Antonie J van den Bogert,et al.  Implicit methods for efficient musculoskeletal simulation and optimal control. , 2011, Procedia IUTAM.

[62]  Antonie J. van den Bogert,et al.  opty: Software for trajectory optimization and parameter identification using direct collocation , 2018, J. Open Source Softw..

[63]  Scott L Delp,et al.  Generating dynamic simulations of movement using computed muscle control. , 2003, Journal of biomechanics.

[64]  S. Simon Gait Analysis, Normal and Pathological Function. , 1993 .

[65]  Joseph Hamill,et al.  Optimal footfall patterns for cost minimization in running. , 2015, Journal of biomechanics.

[66]  R. Peng Reproducible Research in Computational Science , 2011, Science.

[67]  Ernst Hairer,et al.  Solving Ordinary Differential Equations I: Nonstiff Problems , 2009 .

[68]  Benjamin J Fregly,et al.  Update on grand challenge competition to predict in vivo knee loads. , 2013, Journal of biomechanical engineering.

[69]  Ilse Jonkers,et al.  EMG-Driven Optimal Estimation of Subject-SPECIFIC Hill Model Muscle–Tendon Parameters of the Knee Joint Actuators , 2017, IEEE Transactions on Biomedical Engineering.

[70]  Michael A Sherman,et al.  Simbody: multibody dynamics for biomedical research. , 2011, Procedia IUTAM.

[71]  Thomas Geijtenbeek,et al.  SCONE: Open Source Software for Predictive Simulation of Biological Motion , 2019, J. Open Source Softw..

[72]  Matthew S. DeMers,et al.  How tibiofemoral alignment and contact locations affect predictions of medial and lateral tibiofemoral contact forces. , 2015, Journal of biomechanics.

[73]  Ross H. Miller,et al.  Optimal Control Modeling of Human Movement , 2017 .

[74]  Samuel R. Hamner,et al.  How muscle fiber lengths and velocities affect muscle force generation as humans walk and run at different speeds , 2013, Journal of Experimental Biology.

[75]  Leng-Feng Lee,et al.  Generating optimal control simulations of musculoskeletal movement using OpenSim and MATLAB , 2016, PeerJ.

[76]  Friedl De Groote,et al.  Algorithmic differentiation improves the computational efficiency of OpenSim-based trajectory optimization of human movement , 2019, PloS one.

[77]  Andreas Griewank,et al.  ADOL‐C: Automatic Differentiation Using Operator Overloading in C++ , 2003 .

[78]  James M. Wakeling,et al.  Metabolic cost underlies task-dependent variations in motor unit recruitment , 2018, Journal of the Royal Society Interface.

[79]  Ilse Jonkers,et al.  Subject-Exoskeleton Contact Model Calibration Leads to Accurate Interaction Force Predictions , 2019, IEEE Transactions on Neural Systems and Rehabilitation Engineering.

[80]  Marcus G Pandy,et al.  Predictive Simulations of Neuromuscular Coordination and Joint-Contact Loading in Human Gait , 2018, Annals of Biomedical Engineering.

[81]  Anil V. Rao,et al.  Muscle Synergies Facilitate Computational Prediction of Subject-Specific Walking Motions , 2016, Front. Bioeng. Biotechnol..

[82]  Michael A. Saunders,et al.  SNOPT: An SQP Algorithm for Large-Scale Constrained Optimization , 2002, SIAM J. Optim..

[83]  J. Hutchinson,et al.  Analysis of hindlimb muscle moment arms in Tyrannosaurus rex using a three-dimensional musculoskeletal computer model: implications for stance, gait, and speed , 2005, Paleobiology.

[84]  George M. Siouris,et al.  Applied Optimal Control: Optimization, Estimation, and Control , 1979, IEEE Transactions on Systems, Man, and Cybernetics.

[85]  Matthew Kelly,et al.  An Introduction to Trajectory Optimization: How to Do Your Own Direct Collocation , 2017, SIAM Rev..

[86]  S. Larson,et al.  Chimpanzee super strength and human skeletal muscle evolution , 2017, Proceedings of the National Academy of Sciences.

[87]  Lorenz T. Biegler,et al.  Contact-Implicit Trajectory Optimization Using Orthogonal Collocation , 2018, IEEE Robotics and Automation Letters.