Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

py math: Support matrix inverse for dtype=AutoDiffXd and Expression #11164

Closed
EricCousineau-TRI opened this issue Apr 4, 2019 · 0 comments
Closed

Comments

@EricCousineau-TRI
Copy link
Contributor

EricCousineau-TRI commented Apr 4, 2019

Pending some form of resolution for #8116 for proper ufuncs, we should add a shim for matrix inverse in pydrake.math.

Slack convo: https://drakedevelopers.slack.com/archives/C3YB3EV5W/p1554344618003700

good question from an underactuated student:

Thanks a lot I did the same as u did in quadrotor2d! I actually have a new problem for DirectCollocation and AutoDiffXd.

I'v seen there's the open feed on how to make numpy linear algebra compatible with AutoDiffXd type arrays.

I guess np.linalg.inv is not yet compatible (I get that TypeError: No loop matching the specified signature and casting was found for ufunc inv error).

My question is: when you have a system in manipulator equations form, and you want to fill up the _DoCalcTimeDerivatives method, do you have to  invert the inertia matrix  by hand and plug in the algebraic coefficient of the inverse to make it compatible with  AutoDiffXd?

Or is there a built-in way to do this?

\cc @RussTedrake

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant