[Scilab-users] Backslash operator with square singular matrix

Pierre Vuillemin contact at pierre-vuillemin.fr
Tue Oct 27 15:35:01 CET 2015


Well, I must have switched the warnings off at some point and I did not 
realise that it was persistent.

Thank you for pointing that out.


Now that I can see the warnings, this leads me to another question :

With dense matrices, rcond seems to be used to detect singularity when 
doing A\b while in the sparse case, rank deficiency is checked.

cond, rcond and rank works with dense matrices, condestsp works with 
sparse matrices but not with singular ones.

What would be a consistent (and efficient?) way of detecting matrix 
singularity? Through LU factorisation to get the rank of the matrix?



Le 27.10.2015 14:53, Stéphane Mottelet a écrit :
> Hello,
> 
> 
> 
> Le 27/10/2015 13:27, Pierre Vuillemin a écrit :
>> A = [2 4;1 2];
>> disp(det(A))
>> b = [1;1];
>> x = A \ b;
> -->A = [2 4;1 2];
> 
> -->disp(det(A))
> 
>     0.
> 
> -->b = [1;1];
> 
> -->x = A \ b;
> Attention :
> La matrice est presque singulière ou mal conditionnée. rcond = 
> 0.0000D+00
> Calcul de la solution des moindres carrés (voir lsq).
> 
> Isn't it a warning ?
> 
> S.
> 
> _______________________________________________
> users mailing list
> users at lists.scilab.org
> http://lists.scilab.org/mailman/listinfo/users



More information about the users mailing list