Loading ...
Sorry, an error occurred while loading the content.

Re: [ublas-dev] Diagonalizing sparse matrices

Expand Messages
  • Gunter Winkler
    ... You could use an iterative method like the power method which converges to the dominant eigenvalue/eigenvector pair: start with x=(1,0,...,0), iterate x :=
    Message 1 of 5 , Dec 1, 2003
    • 0 Attachment
      Am Sonntag 30 November 2003 23:16 schrieb Derek:
      > I have to play with large sparse symmetric matrices that will not fit
      > into 500MB memory if I used dense or symmetric storage. I only need the
      > first 3 or 4 eigenvectors.
      >
      > Is there a library for diagonalizing sparse (symmetric) matrices that
      > makes use of sparse matrix storage (such as that in ublas)?
      > Or something that can be used with code developed with ublas.

      You could use an iterative method like the power method which converges to the
      dominant eigenvalue/eigenvector pair:

      start with x=(1,0,...,0),
      iterate
      x := Ax,
      normalize x,
      stop if new x is (nearly) proportional to old x,
      then lamba=(x^T A x)/(x^T x) (Rayleigh Quotient)

      The convergence is slow, but you don't need extra storage. To compute more
      eigenvalues you have to iterate the shifted matrix (A-lambda I), where lambda
      is the previously computed eigenvalue.

      regards
      Gunter
    • Matthias Troyer
      Dear Derek, The IETL also works with sparse matrices and we have a new version (not yet released because the documentation is not fully updated yet) that
      Message 2 of 5 , Dec 1, 2003
      • 0 Attachment
        Dear Derek,

        The IETL also works with sparse matrices and we have a new version
        (not yet released because the documentation is not fully updated yet)
        that supports all uBLAS matrix formats. We use it ourselves with sparse
        matrices. If you are interested, I can send you a version.

        Matthias

        On Nov 30, 2003, at 11:16 PM, Derek wrote:

        > Hi,
        >
        > I have to play with large sparse symmetric matrices that will not fit
        > into 500MB memory if I used dense or symmetric storage. I only need the
        > first 3 or 4 eigenvectors.
        >
        > Is there a library for diagonalizing sparse (symmetric) matrices that
        > makes use of sparse matrix storage (such as that in ublas)?
        > Or something that can be used with code developed with ublas.
        >
        > I found the IETL library which is very nice, but I think it only works
        > with dense storage at the moment.
        >
        > Any advice would be most appreciated!
        >
        > -Derek
        >
        >
        > ------------------------ Yahoo! Groups Sponsor
        > ---------------------~-->
        > Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
        > Printer at MyInks.com. Free s/h on orders $50 or more to the US &
        > Canada.
        > http://www.c1tracking.com/l.asp?cid=5511
        > http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/EbFolB/TM
        > ---------------------------------------------------------------------
        > ~->
        >
        > To unsubscribe from this group, send an email to:
        > ublas-dev-unsubscribe@yahoogroups.com
        >
        >
        >
        > Your use of Yahoo! Groups is subject to
        > http://docs.yahoo.com/info/terms/
        >
      • Derek Lee
        Dear Matthias, I was hoping you would say that. Yes please! If it is too large to send by email, it can pick it up by anon ftp. Regards Derek
        Message 3 of 5 , Dec 1, 2003
        • 0 Attachment
          Dear Matthias,

          I was hoping you would say that. Yes please!

          If it is too large to send by email, it can pick it up by anon ftp.

          Regards
          Derek

          Matthias Troyer wrote:
          > Dear Derek,
          >
          > The IETL also works with sparse matrices and we have a new version
          > (not yet released because the documentation is not fully updated yet)
          > that supports all uBLAS matrix formats. We use it ourselves with sparse
          > matrices. If you are interested, I can send you a version.
          >
          > Matthias
          >
          > On Nov 30, 2003, at 11:16 PM, Derek wrote:
          >
          >
          >>Hi,
          >>
          >>I have to play with large sparse symmetric matrices that will not fit
          >>into 500MB memory if I used dense or symmetric storage. I only need the
          >>first 3 or 4 eigenvectors.
          >>
          >>Is there a library for diagonalizing sparse (symmetric) matrices that
          >>makes use of sparse matrix storage (such as that in ublas)?
          >>Or something that can be used with code developed with ublas.
          >>
          >>I found the IETL library which is very nice, but I think it only works
          >>with dense storage at the moment.
          >>
          >>Any advice would be most appreciated!
          >>
          >>-Derek
          >>
          >>
          >>------------------------ Yahoo! Groups Sponsor
          >>---------------------~-->
          >>Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
          >>Printer at MyInks.com. Free s/h on orders $50 or more to the US &
          >>Canada.
          >>http://www.c1tracking.com/l.asp?cid=5511
          >>http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/EbFolB/TM
          >>---------------------------------------------------------------------
          >>~->
          >>
          >>To unsubscribe from this group, send an email to:
          >>ublas-dev-unsubscribe@yahoogroups.com
          >>
          >>
          >>
          >>Your use of Yahoo! Groups is subject to
          >>http://docs.yahoo.com/info/terms/
          >>
          >
          >
          >
          >
          > To unsubscribe from this group, send an email to:
          > ublas-dev-unsubscribe@yahoogroups.com
          >
          >
          >
          > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
          >
          >
          >
        • Matthias Troyer
          Dear all, The static constant index_base_ in compressed_matrix is declared in the class but not defined. This causes link-time failures on the IBM compiler,
          Message 4 of 5 , Dec 13, 2003
          • 0 Attachment
            Dear all,

            The static constant index_base_ in compressed_matrix is declared in the
            class but not defined. This causes link-time failures on the IBM
            compiler, which is stricter than other compilers about missing
            definitions of static constants. Since I do not have access to the
            boost CVS could somebody please fix it and add the missing definition?

            Best regards

            Matthias
          Your message has been successfully submitted and would be delivered to recipients shortly.