This is the MATLAB source code for CPSid, which is a data-driven discovery framework for cyber-physical systems (CPS). The testing platform is Windows 10, and the code was implemented in MATLAB 2017a. For versions MATLAB 2018a and later, when using the slr function to identify transition logic, you should set the algorithm to trust-region. You can replace the code in line 103 of the function slr_learning_l1
with:
option = optimset('Gradobj', 'on', 'Hessian', 'on', 'MaxIter', WMaxIter, 'Display', WDisplay, 'Algorithm', 'trust-region');
Note that the CVX toolbox is required to run the code.
Reference: Yuan, Y., Tang, X., Zhou, W., et al. Data-driven discovery of cyber-physical systems. Nat Commun 10, 4894 (2019).