Simulink Singular Value Decomposition (SVD) Bug?

T
Teagan · Mar 5, 2021 · 1.9K views
Question
I have a matrix that when passed through a SVD  simulink block would return a V matrix (specifically, the last column is the negative of the other) that differs from one that is returned in Matlab (even when using the econ option)...   I work in the same workspace ie, I'm using the source block to define the matrix in Simulink...   I have tested several a few matrices, run into the same issue everytime.   An example matrix is [1.0916 0.0595 -0.0324; 0.0595 1.0386 -0.0210; -0.0324 -0.0210 0.0115]   This would give a different v matrix in Matlab than one given in Simulink...   I haven even tried running a embedded Matlab function using svd and still ran into the same problem.   I am using R2008B, doubt this is an issue???
Expert Answer
Profile picture of Neeta Dsouza
Neeta Dsouza PhD Expert
Answered Aug 25, 2026
It's not a bug, the difference you see is simply the signs on the elements of u are the opposite, but that is also true for the v matrix, so that
 
u*s*v' still gives you the factorization of the input matrix
 
If you look at the output of svd() and compare that to the SVD block in the  Signal Processing Blockset, the elements of u and v are equal in magnitude but opposite in sign. The singular values are the same.
100% Run Guarantee 3-Hour Fast-Track Delivery

Need a Custom Version or Complete Simulation for This Problem?

Our 500+ PhD engineers build, debug, and optimize working MATLAB scripts and Simulink (.slx) models tailored to your exact assignment rubrics with zero plagiarism.

Tested on MATLAB R2024b / R2026a
Turnitin 0% Plagiarism Report
Free 7-Day Revisions Guarantee
Have a different question? Ask here

Get a Free Consultation or a Sample Assignment Review!