[R] solve() function freezes CLI in GNU R 3.6.3

Rasmus Liland jr@| @end|ng |rom po@teo@no
Wed May 13 20:29:33 CEST 2020


On 2020-05-13 13:04 -0400, J C Nash wrote:
> On 2020-05-13 11:28 a.m., Rasmus Liland wrote:
> > 
> > I get another solution on my Linux i7-7500U 
> > 
> > > D %*% solve(D)
> >              [,1] [,2]
> > [1,] 1.000000e+00    0
> > [2,] 8.881784e-16    1
> > > sessionInfo()
> > BLAS:   /usr/lib/libopenblasp-r0.3.9.so
> > LAPACK: /usr/lib/liblapack.so.3.9.0
> 
> Note that my sessionInfo() gave
> 
> R version 4.0.0 (2020-04-24)
> Platform: x86_64-pc-linux-gnu (64-bit)
> Running under: Linux Mint 19.3
> 
> Matrix products: default
> BLAS:   /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.7.1
> LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.7.1
> 
> So you have an older R but newer libraries, and the libblas is
> a different one.
> 
> Given the output is very similar, and within the rounding
> margins of the double arithmetic, this looks like the
> libraries are very slightly different. I suppose I should
> be more inquisitive and try to seek out the changelog or other
> description of the differences, but ...
> 
> JN

Dear JN,

I was thinking BLAS could be changed to 
OpenBLAS, apparently not:

If I switch from OpenBLAS back to regular 
BLAS, the output is as expected ... I thought 
OpenBLAS should be a real alternative to BLAS 
in many cases, but not in this example?

> D %*% solve(D)
     [,1]         [,2]
[1,]    1 1.110223e-16
[2,]    0 1.000000e+00
> sessionInfo()
R version 3.6.3 (2020-02-29)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Arch Linux

Matrix products: default
BLAS:   /usr/lib/libblas.so.3.9.0
LAPACK: /usr/lib/liblapack.so.3.9.0

Best,
Rasmus



More information about the R-help mailing list