A class for constructing and defining operations on complex matrices. More...
#include <gslpp_matrix_complex.h>
A class for constructing and defining operations on complex matrices.
This class defines some common operations on complex matrices using the GSL.
Definition at line 45 of file gslpp_matrix_complex.h.
Public Member Functions | |
| gsl_matrix_complex & | as_gsl_type () |
| const gsl_matrix_complex & | as_gsl_type () const |
| gsl_matrix_complex * | as_gsl_type_ptr () const |
| void | assign (const size_t &i, const size_t &j, const complex &z) |
| void | assign (const size_t &i, const size_t &j, const double &a) |
| void | assign (const size_t &i, const size_t &j, const matrix< complex > &z) |
| void | assign (const size_t &i, const size_t &j, const matrix< double > &a) |
| void | assignim (const size_t &i, const size_t &j, const double &a) |
| void | assignre (const size_t &i, const size_t &j, const double &a) |
| void | eigensystem (matrix< complex > &U, vector< double > &S) const |
| matrix< complex > | hconjugate () const |
| matrix< double > | imag () const |
| matrix< complex > | inverse () const |
| bool | isSingular () |
| matrix (const gsl_matrix_complex &m) | |
| matrix (const gsl_matrix_complex *m) | |
| matrix (const matrix< complex > &m) | |
| matrix (const matrix< double > &m) | |
| matrix (const size_t &size_i, const complex &z) | |
| matrix (const size_t &size_i, const double &a) | |
| matrix (const size_t &size_i, const size_t &size_j, const complex &z) | |
| Constructor. More... | |
| matrix (const size_t &size_i, const size_t &size_j, const double &a) | |
| Constructor. More... | |
| matrix (const vector< complex > &v) | |
| matrix (const vector< double > &v) | |
| bool | operator!= (const matrix< complex > &a) const |
| const complex | operator() (const size_t &i, const size_t &j) const |
| matrix< complex > | operator* (const complex &z) const |
| matrix< complex > | operator* (const double &a) const |
| matrix< complex > | operator* (const matrix< complex > &m) const |
| matrix< complex > | operator* (const matrix< double > &m) const |
| vector< complex > | operator* (const vector< complex > &v) const |
| vector< complex > | operator* (const vector< double > &v) const |
| matrix< complex > & | operator*= (const complex &z) |
| matrix< complex > & | operator*= (const double &a) |
| matrix< complex > & | operator*= (const matrix< complex > &m) |
| matrix< complex > | operator+ (const complex &z) const |
| matrix< complex > | operator+ (const double &a) const |
| matrix< complex > | operator+ (const matrix< complex > &m) const |
| matrix< complex > | operator+ (const matrix< double > &m) const |
| matrix< complex > & | operator+= (const complex &z) |
| matrix< complex > & | operator+= (const double &a) |
| matrix< complex > & | operator+= (const matrix< complex > &m) |
| matrix< complex > | operator- () const |
| matrix< complex > | operator- (const complex &z) const |
| matrix< complex > | operator- (const double &a) const |
| matrix< complex > | operator- (const matrix< complex > &m) const |
| matrix< complex > | operator- (const matrix< double > &m) const |
| matrix< complex > & | operator-= (const complex &z) |
| matrix< complex > & | operator-= (const double &a) |
| matrix< complex > & | operator-= (const matrix< complex > &m) |
| matrix< complex > | operator/ (const complex &z) const |
| matrix< complex > | operator/ (const double &a) const |
| matrix< complex > & | operator/= (const complex &z) |
| matrix< complex > & | operator/= (const double &a) |
| matrix< complex > & | operator= (const matrix< complex > &m) |
| bool | operator== (const matrix< complex > &a) const |
| matrix< double > | real () const |
| void | reset () |
| void | singularvalue (matrix< complex > &U, matrix< complex > &V, vector< double > &S) const |
| size_t | size () const |
| size_t | size_i () const |
| size_t | size_j () const |
| matrix< complex > | transpose () const |
| ~matrix () | |
Static Public Member Functions | |
| static matrix< complex > | Id (size_t size) |
Private Attributes | |
| gsl_matrix_complex * | _matrix |
Friends | |
| std::ostream & | operator<< (std::ostream &output, const matrix< complex > &v) |
Operations on matrix<complex> | |
| matrix< complex > | operator+ (matrix< double > m1, const matrix< complex > m2) |
| matrix< complex > | operator- (matrix< double > m1, const matrix< complex > m2) |
| matrix< complex > | operator+ (const complex &z, const matrix< complex > m) |
| matrix< complex > | operator- (const complex &z, const matrix< complex > m) |
| matrix< complex > | operator* (const complex &z, const matrix< complex > m) |
| vector< complex > | operator* (const vector< complex > &v, const matrix< complex > m) |
| vector< complex > | operator* (const vector< double > &v, const matrix< complex > m) |
| matrix< complex > | operator+ (const double &a, const matrix< complex > m) |
| matrix< complex > | operator- (const double &a, const matrix< complex > m) |
| matrix< complex > | operator* (const double &a, const matrix< complex > m) |
| gslpp::matrix< complex >::matrix | ( | const size_t & | size_i, |
| const size_t & | size_j, | ||
| const complex & | z | ||
| ) |
| gslpp::matrix< complex >::matrix | ( | const size_t & | size_i, |
| const complex & | z | ||
| ) |
| gslpp::matrix< complex >::matrix | ( | const size_t & | size_i, |
| const size_t & | size_j, | ||
| const double & | a | ||
| ) |
| gslpp::matrix< complex >::matrix | ( | const size_t & | size_i, |
| const double & | a | ||
| ) |
| gslpp::matrix< complex >::matrix | ( | const matrix< complex > & | m | ) |
| gslpp::matrix< complex >::matrix | ( | const matrix< double > & | m | ) |
Definition at line 58 of file gslpp_matrix_complex.cpp.
| gslpp::matrix< complex >::matrix | ( | const vector< complex > & | v | ) |
Definition at line 69 of file gslpp_matrix_complex.cpp.
| gslpp::matrix< complex >::matrix | ( | const vector< double > & | v | ) |
Definition at line 79 of file gslpp_matrix_complex.cpp.
| gslpp::matrix< complex >::matrix | ( | const gsl_matrix_complex & | m | ) |
Definition at line 89 of file gslpp_matrix_complex.cpp.
| gslpp::matrix< complex >::matrix | ( | const gsl_matrix_complex * | m | ) |
Definition at line 95 of file gslpp_matrix_complex.cpp.
| gslpp::matrix< complex >::~matrix | ( | ) |
Destructor
Definition at line 102 of file gslpp_matrix_complex.cpp.
| gsl_matrix_complex & gslpp::matrix< complex >::as_gsl_type | ( | ) |
Definition at line 389 of file gslpp_matrix_complex.cpp.
| const gsl_matrix_complex & gslpp::matrix< complex >::as_gsl_type | ( | ) | const |
Definition at line 394 of file gslpp_matrix_complex.cpp.
| gsl_matrix_complex * gslpp::matrix< complex >::as_gsl_type_ptr | ( | ) | const |
| void gslpp::matrix< complex >::assign | ( | const size_t & | i, |
| const size_t & | j, | ||
| const complex & | z | ||
| ) |
Assign element
Definition at line 140 of file gslpp_matrix_complex.cpp.
| void gslpp::matrix< complex >::assign | ( | const size_t & | i, |
| const size_t & | j, | ||
| const double & | a | ||
| ) |
Definition at line 146 of file gslpp_matrix_complex.cpp.
| void gslpp::matrix< complex >::assign | ( | const size_t & | i, |
| const size_t & | j, | ||
| const matrix< complex > & | z | ||
| ) |
| void gslpp::matrix< complex >::assign | ( | const size_t & | i, |
| const size_t & | j, | ||
| const matrix< double > & | a | ||
| ) |
Definition at line 182 of file gslpp_matrix_complex.cpp.
| void gslpp::matrix< complex >::assignim | ( | const size_t & | i, |
| const size_t & | j, | ||
| const double & | a | ||
| ) |
Definition at line 158 of file gslpp_matrix_complex.cpp.
| void gslpp::matrix< complex >::assignre | ( | const size_t & | i, |
| const size_t & | j, | ||
| const double & | a | ||
| ) |
Definition at line 152 of file gslpp_matrix_complex.cpp.
| void gslpp::matrix< complex >::eigensystem | ( | matrix< complex > & | U, |
| vector< double > & | S | ||
| ) | const |
Eigenvalues and eigenvectors
| U | matrix<complex>& eigenvectors |
| S | vector<double>& eigenvalues |
Definition at line 347 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::hconjugate | ( | ) | const |
|
static |
Identity matrix
Definition at line 211 of file gslpp_matrix_complex.cpp.
| matrix< double > gslpp::matrix< complex >::imag | ( | ) | const |
| matrix< complex > gslpp::matrix< complex >::inverse | ( | ) | const |
| bool gslpp::matrix< complex >::isSingular | ( | ) |
Check is matrix is singular to avoid errors in luc.c
Check if matrix is singular (This is to avoid error checking by luc.c)
Definition at line 287 of file gslpp_matrix_complex.cpp.
|
inline |
Definition at line 182 of file gslpp_matrix_complex.h.
| const complex gslpp::matrix< complex >::operator() | ( | const size_t & | i, |
| const size_t & | j | ||
| ) | const |
Get i-th element
Definition at line 108 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator* | ( | const complex & | z | ) | const |
Multiplication operator
Multiplication operator (complex)
Definition at line 581 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator* | ( | const double & | a | ) | const |
Multiplication operator
Multiplication operator (double)
Definition at line 647 of file gslpp_matrix_complex.cpp.
Multiplication operator
Multiplication operator (matrix complex)
Definition at line 443 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator* | ( | const matrix< double > & | m | ) | const |
Multiplication operator
Multiplication operator (matrix double)
Definition at line 491 of file gslpp_matrix_complex.cpp.
Multiplication operator
Multiplication operator (vector complex)
Definition at line 498 of file gslpp_matrix_complex.cpp.
| vector< complex > gslpp::matrix< complex >::operator* | ( | const vector< double > & | v | ) | const |
Multiplication operator (vector double)
Definition at line 522 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator*= | ( | const complex & | z | ) |
Multiplication assignment
Multiplication assignment (complex)
Definition at line 619 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator*= | ( | const double & | a | ) |
Multiplication assignment
Multiplication assignment (double)
Definition at line 675 of file gslpp_matrix_complex.cpp.
Multiplication assignment
Multiplication assignment (matrix)
Definition at line 543 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator+ | ( | const complex & | z | ) | const |
Addition operator
Addition operator (complex)
Definition at line 557 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator+ | ( | const double & | a | ) | const |
Addition operator
Addition operator (double)
Definition at line 633 of file gslpp_matrix_complex.cpp.
Addition operator
Addition operator (matrix)
Definition at line 418 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator+ | ( | const matrix< double > & | m | ) | const |
Addition operator
Addition operator (matrix)
Definition at line 465 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator+= | ( | const complex & | z | ) |
Addition assignment
Addition assignment (complex)
Definition at line 605 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator+= | ( | const double & | a | ) |
Addition assignment
Addition assignment (double)
Definition at line 661 of file gslpp_matrix_complex.cpp.
Addition assignment
Addition assignment (matrix)
Definition at line 529 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator- | ( | ) | const |
check whether two matrices are equal Unary minus
Unary minus
Definition at line 404 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator- | ( | const complex & | z | ) | const |
Subtraction operator
Subtraction operator (complex)
Definition at line 569 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator- | ( | const double & | a | ) | const |
Subtraction operator
Subtraction assignment (double)
Definition at line 640 of file gslpp_matrix_complex.cpp.
Subtraction operator
Subtraction operator (matrix)
Definition at line 430 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator- | ( | const matrix< double > & | m | ) | const |
Subtraction operator
Subtraction operator (matrix)
Definition at line 478 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator-= | ( | const complex & | z | ) |
Subtraction assignment
Subtraction assignment (complex)
Definition at line 612 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator-= | ( | const double & | a | ) |
Subtraction assignment
Subtraction assignment (double)
Definition at line 668 of file gslpp_matrix_complex.cpp.
Subtraction assignment
Subtraction assignment (matrix)
Definition at line 536 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator/ | ( | const complex & | z | ) | const |
Division operator
Division operator (complex)
Definition at line 593 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::operator/ | ( | const double & | a | ) | const |
Division operator
Division operator (double)
Definition at line 654 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator/= | ( | const complex & | z | ) |
Division assignment
Division assignment (complex)
Definition at line 626 of file gslpp_matrix_complex.cpp.
| matrix< complex > & gslpp::matrix< complex >::operator/= | ( | const double & | a | ) |
Division assignment
Division assignment (double)
Definition at line 682 of file gslpp_matrix_complex.cpp.
Set i-th element Assign
Definition at line 127 of file gslpp_matrix_complex.cpp.
| bool gslpp::matrix< complex >::operator== | ( | const matrix< complex > & | a | ) | const |
Comparison == (matrix)
Definition at line 689 of file gslpp_matrix_complex.cpp.
| matrix< double > gslpp::matrix< complex >::real | ( | ) | const |
| void gslpp::matrix< complex >::reset | ( | ) |
| void gslpp::matrix< complex >::singularvalue | ( | matrix< complex > & | U, |
| matrix< complex > & | V, | ||
| vector< double > & | S | ||
| ) | const |
Singular Value Decomposition as U diagonalmatrix(S) V^+
| U | matrix<complex>& |
| V | matrix<complex>& |
| S | vector<double>& |
Definition at line 363 of file gslpp_matrix_complex.cpp.
| size_t gslpp::matrix< complex >::size | ( | ) | const |
Definition at line 199 of file gslpp_matrix_complex.cpp.
| size_t gslpp::matrix< complex >::size_i | ( | ) | const |
Get matrix size
Definition at line 189 of file gslpp_matrix_complex.cpp.
| size_t gslpp::matrix< complex >::size_j | ( | ) | const |
Definition at line 194 of file gslpp_matrix_complex.cpp.
| matrix< complex > gslpp::matrix< complex >::transpose | ( | ) | const |
Transpose matrix
Definition at line 217 of file gslpp_matrix_complex.cpp.
Multiply a complex number by complex matrix
| z | Complex number |
| m | Complex matrix |
Definition at line 737 of file gslpp_matrix_complex.cpp.
Multiply a real number by a complex matrix
| a | Real number |
| m | Complex matrix |
Definition at line 762 of file gslpp_matrix_complex.cpp.
Multiply a complex vector by a complex matrix
| v | Complex vector |
| m | Complex matrix |
Definition at line 742 of file gslpp_matrix_complex.cpp.
Multiply a real vector by a complex matrix
| v | Real vector |
| m | Complex matrix |
Definition at line 747 of file gslpp_matrix_complex.cpp.
Add a complex number to a complex matrix
| z | Complex number |
| m | Complex matrix |
Definition at line 727 of file gslpp_matrix_complex.cpp.
Add a real number to a complex matrix
| a | Real number |
| m | Complex matrix |
Definition at line 752 of file gslpp_matrix_complex.cpp.
Add a double matrix to a complex matrix
| m1 | Double matrix |
| m2 | Complex matrix |
Definition at line 717 of file gslpp_matrix_complex.cpp.
Subtract a complex number from a complex matrix
| z | Complex number |
| m | Complex matrix |
Definition at line 732 of file gslpp_matrix_complex.cpp.
Subtract a complex matrix from a real number
| a | Real number |
| m | Complex matrix |
Definition at line 757 of file gslpp_matrix_complex.cpp.
Subtract a double matrix to a complex matrix
| m1 | Double matrix |
| m2 | Complex matrix |
Definition at line 722 of file gslpp_matrix_complex.cpp.
friend functions
Definition at line 703 of file gslpp_matrix_complex.cpp.
|
private |
Definition at line 47 of file gslpp_matrix_complex.h.