Why Does My Solve Linear Equations VI Give an Unexpected Solution Vector?Primary Software: Primary Software Version: 2013 Primary Software Fixed Version: N/A Secondary Software: N/A
Problem: I want to solve the equation AX = B for X, where A is the known matrix, X is the unknown vector, and B is the known vector. However, when using the Solve Linear Equations VI, the resultant B does not appear to be correct. When multiplying AX to check my result, I get a vector that is not B. Why does this occur? Solution: This can occur when the input matrix, A, for the Solve Linear Equations VI is singular. When this is the case, instead of solving the equation AX = B for X, LabVIEW finds the leastsquare solution which is the solution with the least square mean error. This is because there is no solution for AX = B. To check if a matrix is singular, you must determine whether the determinant is zero. If the determinant is zero, the matrix is singular. The easiest way to check this would be to use a Determinant VI to obtain the determinant. Shown below is a VI snippet that demonstrates how a singular matrix can give a misleading solution. The snippet also demonstrates how to use the Determinant VI to test and see if a matrix is singular. Related Links: LabVIEW Help: Solve Linear Equations VI External Link: Invertible matrix  Wikipedia, the free encyclopedia Attachments: Singular Matrix Example.vi
Report Date: 09/24/2002 Last Updated: 09/13/2013 Document ID: 2PNGS2A2
