dynamicslab / pysindy

A package for the sparse identification of nonlinear dynamical systems from data
https://pysindy.readthedocs.io/en/latest/
Other
1.46k stars 324 forks source link

Align projection tensor calculations with master #499

Closed Jacob-Stevens-Haas closed 6 months ago

Jacob-Stevens-Haas commented 6 months ago

This PR extracts the simplified routines for creating the projection tensors. The simplification is possible because of explicitly relying on the PolynomialLibrary through the helper function _build_lib_info, which allows methods to look up indexes for relevant terms. As a result, the PQ and PL matrices now have tests to ensure they are built correctly.

We also remove the check_P_tensors function, because we have explicit tests.

Finally, this also

For review, start with the tests, then the projection calculations. If desired, see the helper functions.

Jacob-Stevens-Haas commented 6 months ago

Ok I'm going to merge this one now, I need to start digging into the algorithm stuff