Jonas-Nicodemus / PINNs-based-MPC

We discuss nonlinear model predictive control (NMPC) for multi-body dynamics via physics-informed machine learning methods. Physics-informed neural networks (PINNs) are a promising tool to approximate (partial) differential equations. PINNs are not suited for control tasks in their original form since they are not designed to handle variable control actions or variable initial values. We thus present the idea of enhancing PINNs by adding control actions and initial conditions as additional network inputs. The high-dimensional input space is subsequently reduced via a sampling strategy and a zero-hold assumption. This strategy enables the controller design based on a PINN as an approximation of the underlying system dynamics. The additional benefit is that the sensitivities are easily computed via automatic differentiation, thus leading to efficient gradient-based algorithms. Finally, we present our results using our PINN-based MPC to solve a tracking problem for a complex mechanical system, a multi-link manipulator.
MIT License
82 stars 22 forks source link

About the data.npz file (resources) #2

Open bao666liang opened 12 months ago

bao666liang commented 12 months ago

Your code is really well written!! At the same time, I would like to ask about how the X and Y parameters (i.e. X_star and Y_star) in the data.npz file are generated? data.npz: ['X ','Y','U ','T','X0 ','X_test','Ytest ','ub','lb '] Are they using parameters obtained from real robotic arm operation or dynamic equations? If possible, could you please provide the code to generate the data.npz file? Also, according to the paper, I believe that x data=x k and y data=x k+1, but based on this code, y data is x k. Am I a bit confused? y data shouldn't be the predicted state for the next moment? image 2 There are a lot of questions, and if you could answer them, I would really, really, really appreciate it!!

Jonas-Nicodemus commented 11 months ago

Hi,

I hope this clarifies everything for you.

bao666liang commented 11 months ago

Thank you so much for your detailed answer!! Therefore, what you mean is that this function is only used to generate initial conditions (because the dynamic equations are accurate enough), so in other words, when my dynamic equation is not accurate, the ydata of this function needs to be x k+1 (i.e. the true value of the next moment) instead of x_ k/x0. I don't know if my understanding is accurate?