Hi everyone, I compared eigen() and irlba() (from the eponym package), for the eigen decomposition of 1500x1500 and 3000x3000 dense matrices, retaining only the two major eigenpairs.
I obtained the following results (VM running on two cores of a core i7-2600) : - 1500x1500 : 5.4s with eigen(), 0.28 with irlba() - 3000x3000 : 45.2s with eigen(), 1.05 with irlba() Furthermore, the result of irlba() approximates the result of eigen() in the range of numeric precision ([1e-18, 1e-15]). There may exist further optimizations, specifically crafted for real symmetric matrices, but with accounting for my specifics, it is not worth the effort. Thanks again, Pierrick Bruneau CRP Gabriel Lippmann On Fri, Feb 1, 2013 at 10:50 AM, Pierrick Bruneau <pbrun...@gmail.com>wrote: > Thanks a lot, I'll test this package very soon. > As it seems general purpose (ie not specifically fitted to the square > symmetric context), I hope the advantage over the standard routine for > symmetric matrices remains significant. > > Pierrick Bruneau > CRP Gabriel Lippmann > > On Thursday, January 31, 2013, Mark Leeds wrote: > >> hi: the irlba package does what you're looking for. >> >> >> On Thu, Jan 31, 2013 at 3:32 AM, Pierrick Bruneau <pbrun...@gmail.com>wrote: >> >>> Hi everyone, >>> >>> I am using eigen() to extract the 2 major eigenpairs from a large real >>> square symmetric matrix. The procedure is already rather efficient, but >>> becomes somehow slow for real time needs with moderately large matrices >>> (few thousand lines). >>> >>> The R implementation statically extracts all eigenvalues (and optionally >>> associated eigenvectors). I heard about optimizations of the eigen >>> decomposition when only few eigenpairs are needed : did somebody already >>> care about this problem (through a contributed package for example) ? Or >>> do >>> I have to directly try to mess around with the LAPACK library (and >>> contribute the package myself afterwards) ? >>> >>> Thanks by advance for your help, >>> Pierrick Bruneau >>> CRP Gabriel Lippmann >>> >>> [[alternative HTML version deleted]] >>> >>> ______________________________________________ >>> R-help@r-project.org mailing list >>> https://stat.ethz.ch/mailman/listinfo/r-help >>> PLEASE do read the posting guide >>> http://www.R-project.org/posting-guide.html >>> and provide commented, minimal, self-contained, reproducible code. >>> >> >> [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.