rwlogo
SourcePro C++ 12.0

SourcePro® C++ API Reference Guide



   SourcePro C++
Documentation Home

RWHermPDQREigServer< TypeT > Class Template Reference
[Symmetric Eigenvalue Decomposition]

The server for the positive definite QR method of computing eigenvalues. More...

#include <rw/lapack/heigsrv.h>

Inheritance diagram for RWHermPDQREigServer< TypeT >:
RWHermEigServer< TypeT >

List of all members.

Public Member Functions

 RWHermPDQREigServer (bool computeVecs=true)
virtual RWSymEigDecomp< double > decompose (const RWTriDiagDecomp< TypeT > &A)
virtual bool computeEigenVectors () const
void computeEigenVectors (bool computeVecs)

Detailed Description

template<class TypeT>
class RWHermPDQREigServer< TypeT >

The class RWHermPDQREigServer<T> is the server for the positive definite QR method of computing eigenvalues. This server applies only to matrices that you know are positive definite. Trying to use it on nonpositive definite matrices results in a decomposition with the incomplete flag set; you can test for this in the class RWHermEigDecomp<T> . Use of this server with positive definite matrices can result in much more accurate eigenvalues and eigenvectors.

Synopsis

 #include <rw/lapack/heigsrv.h>
 
 RWHermPDQREigServer<DComplex> server;
 RWHermEigDecomp<DComplex> eig = server(A);  // A is a
                                             // RWHermBandMat<DComplex>

Examples

 #include <iostream>
 #include <rw/lapack/heigsrv.h>
 
 int main()
 {
     RWHermMat<DComplex> A;                     // input a matrix
     std::cin >> A;
 
     RWHermPDQREigServer<DComplex> server;      // configure a server
     server.computeEigenVectors(false);         // turn off eigenvectors
     RWHermEigDecomp<DComplex> eig = server(A);

     return 0;
 }

Constructor & Destructor Documentation

template<class TypeT>
RWHermPDQREigServer< TypeT >::RWHermPDQREigServer ( bool  computeVecs = true  ) 

Constructs a server. The parameter indicates whether this server should be configured to compute eigenvectors as well as eigenvalues.


Member Function Documentation

template<class TypeT>
void RWHermPDQREigServer< TypeT >::computeEigenVectors ( bool  computeVecs  ) 

Sets whether or not the server should compute eigenvectors as well as eigenvalues.

template<class TypeT>
virtual bool RWHermPDQREigServer< TypeT >::computeEigenVectors (  )  const [virtual]

Returns true if this server is configured to compute eigenvectors as well as eigenvalues.

Implements RWHermEigServer< TypeT >.

template<class TypeT>
virtual RWSymEigDecomp<double> RWHermPDQREigServer< TypeT >::decompose ( const RWTriDiagDecomp< TypeT > &  A  )  [virtual]

Computes the eigenvalue decomposition of the tridiagonal matrix inside the tridiagonal decomposition.

Implements RWHermEigServer< TypeT >.

 All Classes Functions Variables Typedefs Enumerations Enumerator Friends

© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.