pinocchio
pinocchio copied to clipboard
Derivatives using CppADCodegen for Floating Base Models
Hi Justin and other Pinocchio Developers
First of all, thank you for the excellent library you guys created and your constant support. My Ph.D. research wouldn't have been possible without it. For the past few months, I had been working on getting the first and second-order derivatives of Inverse/Forward Dynamics to work using the Automatic Differentiation toolbox CppAD and CasADi in Pinocchio. With the CppAD tool, I was able to get the partial derivatives correctly for all models (fixed or floating base) without using CodeGen. This unit test that you provided helped a lot
https://github.com/stack-of-tasks/pinocchio/blob/master/unittest/cppad-algo-derivatives.cpp
But when I try to use the Codegen version of CppAD, for models with a floating base, the derivatives are not correct. But fixed base manipulators work perfectly well. Is it possible to extend the CppADCodegen for floating base models too? I tried experimenting with the code-generator-algo header file, but couldn't get it to work.
Any support in this direction would be helpful. Shubham