You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Gilles Sadowski (Jira)" <ji...@apache.org> on 2021/06/05 13:08:00 UTC

[jira] [Updated] (MATH-1176) QRDecomposition does not detect the matrix singularity

     [ https://issues.apache.org/jira/browse/MATH-1176?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gilles Sadowski updated MATH-1176:
----------------------------------
    Fix Version/s:     (was: 4.0)
                   4.X

> QRDecomposition does not detect the matrix singularity
> ------------------------------------------------------
>
>                 Key: MATH-1176
>                 URL: https://issues.apache.org/jira/browse/MATH-1176
>             Project: Commons Math
>          Issue Type: Bug
>    Affects Versions: 3.3
>            Reporter: alberto trivellato
>            Priority: Minor
>             Fix For: 4.X
>
>         Attachments: MATH-1176.failing.patch
>
>
> QRDecomposition fails this test. The default contructor sets the threshold=0, so we will never have abs(Rii) <= 0
> public void testSimpleRankDeficient() throws Exception {
> 		double[][] A = new double[][] { 
> 				{ 1, 2, 3 }, 
> 				{ 4, 5, 6 },
> 				{ 7, 8, 9 }};
> 		//this matrix is singular			
> 		
> 		RealMatrix M2 = MatrixUtils.createRealMatrix(A);
> 		QRDecomposition qr2 = new QRDecomposition(M2);
> 		assertFalse(qr2.getSolver().isNonSingular());//this fails
> }



--
This message was sent by Atlassian Jira
(v8.3.4#803005)