commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Luc Maisonobe (JIRA)" <>
Subject [jira] [Commented] (MATH-1094) Incorrect linear system solution
Date Sun, 26 Jan 2014 11:36:37 GMT


Luc Maisonobe commented on MATH-1094:

I think the behaviour is correct.

The getSolver method for QR decomposition provides a solver for A X = B in the least squares

This means the X comuted by the solver is minimizes || A X - B ||, it does not find 0, only
a minumum norm.
In your case, the system is rectangular, so there is no way a true solution can be achieved.

I have verified (using simple loops and gnuplot countour plots) that indeed the x = 7.5, y
= 5.5 does minimizes the norm, which is 39.0.

> Incorrect linear system solution
> --------------------------------
>                 Key: MATH-1094
>                 URL:
>             Project: Commons Math
>          Issue Type: Bug
>    Affects Versions: 3.2
>         Environment: Oracle JDK7
> Linux x86-64
>            Reporter: Bogdan Bezpartochnyy
>              Labels: patch
>         Attachments:
> Firstly I would like to point out that I'm not very proficient in linear algebra, but
in my opinion the following behavior should not occur. When I solve the following linear system
by hand it has no solution, but in commons math using QRDecomposition it outputs  x1= 7.5
x2 = 5.5

This message was sent by Atlassian JIRA

View raw message