Jason K. Moore
Jason K. Moore
Ok, thanks. I'll probably be posting a number of PRs over winter break. I am just finishing teaching with sympy/pydy in grad level multibody dynamics and a number of things...
So the solution I had in mind for this was to do this: ``` python class MBodyDiffEquations(object): """This class holds information about the ODEs or DAEs that describe a multibody...
For any multibody system you will be able to form symbolic expressions for M, F, and G in: M u' = F q' = G where q are the generalized...
The above also skips the case when you have Lagrange Multipliers due to constraints. See issue #127. We also need to support that case.
For the basic case where n = len(u) = len(q) so that M.shape = (n, n) and `M*.shape = (2*n, 2*n)` you have O(n^3) and `O((2*n)^3)`, for inverting M and...
What do you mean by setup? I'm not sure what you are referring to. There really isn't any setup in evaluating the right hand side. For complex mbody systems the...
This script compares the two for a 20 DoF system: ``` python import numpy as np import sympy as sm from pydy.models import n_link_pendulum_on_cart from pydy.codegen.ode_function_generators import CythonODEFunctionGenerator sys =...
> That 1.5x computation speed is about what I would expect for inverting M and M*. Why would you expect that when the theory is very clear about what the...
Here is a better profile using the pure `array` arg types from: `%prun for i in range(10000): f(x, t, r, p)` ``` 350003 function calls in 0.625 seconds Ordered by:...
And with: `%prun for i in range(10000): f_star(x, t, r, p)` ``` 350003 function calls in 0.765 seconds Ordered by: internal time ncalls tottime percall cumtime percall filename:lineno(function) 10000 0.352...