My 6×6 symbolic Jacobian matrix is massive, and matlabFunction( ) is having trouble writing the corresponding numerical function file.
Hi there!
I currently have a 6×6 symoblic Jacobian using the Symbolic Math Toolbox. It is massive, when I take a peek at it using the Command Window. I then used matlabFunction( ) to convert this symbolic Jacobian to a numerical function. If I use matlabFunction’s default optimize = true, the numerical function file is about 8,000 lines of code, and I get a message there that says the code is too complex to analyze, and that I should reduce the number of operations in my code. On the other hand, if I use matlabFunction’s optimize = false option, the numerical function file is 59,506 lines of code, and I get a message there that says the file is too large. I then tried passing to matlabFunction( ), "Sparse", true, to try to get a sparse numerical Jacobian function file, but I still get the message in the numerical file that the code is too complex to analyze.
What can I do from here?
My goal is to successfully get a numerical Jacobian function file, then evaluate it to get a numerical Jacobian, and then find its eigenvalues using eig( ).
Thanks in advance,Hi there!
I currently have a 6×6 symoblic Jacobian using the Symbolic Math Toolbox. It is massive, when I take a peek at it using the Command Window. I then used matlabFunction( ) to convert this symbolic Jacobian to a numerical function. If I use matlabFunction’s default optimize = true, the numerical function file is about 8,000 lines of code, and I get a message there that says the code is too complex to analyze, and that I should reduce the number of operations in my code. On the other hand, if I use matlabFunction’s optimize = false option, the numerical function file is 59,506 lines of code, and I get a message there that says the file is too large. I then tried passing to matlabFunction( ), "Sparse", true, to try to get a sparse numerical Jacobian function file, but I still get the message in the numerical file that the code is too complex to analyze.
What can I do from here?
My goal is to successfully get a numerical Jacobian function file, then evaluate it to get a numerical Jacobian, and then find its eigenvalues using eig( ).
Thanks in advance, Hi there!
I currently have a 6×6 symoblic Jacobian using the Symbolic Math Toolbox. It is massive, when I take a peek at it using the Command Window. I then used matlabFunction( ) to convert this symbolic Jacobian to a numerical function. If I use matlabFunction’s default optimize = true, the numerical function file is about 8,000 lines of code, and I get a message there that says the code is too complex to analyze, and that I should reduce the number of operations in my code. On the other hand, if I use matlabFunction’s optimize = false option, the numerical function file is 59,506 lines of code, and I get a message there that says the file is too large. I then tried passing to matlabFunction( ), "Sparse", true, to try to get a sparse numerical Jacobian function file, but I still get the message in the numerical file that the code is too complex to analyze.
What can I do from here?
My goal is to successfully get a numerical Jacobian function file, then evaluate it to get a numerical Jacobian, and then find its eigenvalues using eig( ).
Thanks in advance, jacobian symbolic numerical matlab MATLAB Answers — New Questions