There seems to be problems with ARPACK which is the underlying package beneath eigs. See e.g. https://github.com/JuliaLang/julia/issues/6965. I cannot say if that is the problem here. Anyway, we hope to be able to provide an alternative to ARPACK written in pure Julia when time allows. You should also be aware that if you want specific eigenvalues of a symmetric/Hermitian matrix then it is actually possible with `eig` and `eigfact`.
Med venlig hilsen Andreas Noack 2014-09-06 15:24 GMT-04:00 Gabriel Mitchell <[email protected]>: > Sorry, definitely posted the wrong code (problem still real though!). Here > is the code I meant to post > > T = [.90 .05 .05; > .80 .10 .10; > .70 .10 .20]' > v = collect(eigs(T,nev=1,which = :LR)[2]) > v/sum(v) > > > u = real(eig(T)[2][:,1]) > u/sum(u) > > > print(u-v) > > > On Saturday, September 6, 2014 9:12:31 PM UTC+2, Gabriel Mitchell wrote: >> >> I am interested in a fast way to get the dominant eigenvalue/eigenvector >> of a matrix. The function eigs looked promising. However the following call >> to eigs produces non-deterministic (at and any rate wrong) results (on both >> 0.3.0-rc3 and current release). >> >> T = [.90 .05 .05; >> .80 .10 .10; >> .70 .10 .20]' >> v = collect(eigs(T,nev=1,which = :LR)[2]) >> v/sum(v) >> >> u = real(eig(T)[1]) >> u/sum(u) >> >> print(u-v) >> >> So two questions: >> (1) Does anyone see what I am doing wrong or should I file an issue? >> (2) For now I will stick with eigs, but I wonder if anyone can recommend >> an existing performant way to get what I want? >> >
