Hello,
I'm a graduate student who has been using Python for research on dynamics and controls for the past year or so. When I first was getting setup, I was having problems installing PyDy on my windows machine so I ended up rolling my own framework which has the primary function of taking EOMs of a plant and (callable of a) controller and simulate. I'm interested in seeing if those features could/should be integrated into PyDy or if it would be better off as a separate library. I just published my repo here:
https://github.com/sixpearls/NonlinearDynamicalModelingSimulationLike PyDy, I'm interested in the junction of the symbolic and numeric. Here are a few goals/features I have:
- A method of "connecting" multiple systems and/or callables into a single ode function. Ideally all symbolic expressions could be passed through a code generator together so CSE and other efficiencies could be used. I'm thinking of this as a text-based simulink, where each system/callable is a "block" and the user simply defines the connections. I would also like it if systems had output expressions which could be used for connections. Some cleverness of not computing unused connections until after integration would also be possible.
- A simulation function that handles discrete
time systems and controllers, and discrete/continuous time hybrid systems i.e., a discrete time controller on a continuous time plant. I found that having callbacks and way of passing extra information back and forth was helpful for developing algorithm-based controllers which are computationally expensive.
- a way of handling stochastic inputs/specified signals
- Incorporating some classical nonlinear control design/analysis. At this point, I'm mainly thinking of describing functions and phase portraits. But perhaps moving linearization from KanesMethod might make sense, too.
If any of these seem like they might be a good fit for PyDy, I'd love to figure out how I could start implementing them and contributing to the project. If not, I can keep those features in a separate project. Either way, I would be interested in leveraging some of the system and code generation modules as it's a bit more sophisticated than what I have. However, in order to use it I would want de-couple System from the eom_method framework.
Based on
https://github.com/pydy/pydy/issues/83, it seems there was an interest in decoupling from the KanesMethod. Is there any reason not to decouple from all methods and just accept the RHS and optional mass matrix as inputs? I would think this kind of decoupling would be ideal, but I couldn't figure out where (if at all) the *Method was being used apart from the RHS and mass matrix expressions.
Thanks for reading. I look forward to your feedback!
Ben Margolis