Skip to content
Snippets Groups Projects
Commit d1a6f689 authored by Pascal Engeler's avatar Pascal Engeler
Browse files

Added Diagonalizer readme

parent 41e5098b
No related branches found
No related tags found
No related merge requests found
...@@ -8,7 +8,7 @@ The code is structured in an object oriented approach. The classes that likely w ...@@ -8,7 +8,7 @@ The code is structured in an object oriented approach. The classes that likely w
not need to be adapted for a new situation are found in the `lib` folder. They not need to be adapted for a new situation are found in the `lib` folder. They
consist of the following: consist of the following:
### Type `Vec2` (`vec2.hpp`), 2-vector utility class ### Template Type `Vec2` (`vec2.hpp`), 2-vector utility class
1. Template parameters: 1. Template parameters:
- `value_t`: type of vector entries - `value_t`: type of vector entries
2. Members: 2. Members:
...@@ -33,3 +33,12 @@ consist of the following: ...@@ -33,3 +33,12 @@ consist of the following:
- All versions of `op=` of the above - All versions of `op=` of the above
- `[]` with `std::size_t` - `[]` with `std::size_t`
- `<<` with `std::ostream` - `<<` with `std::ostream`
## Type `Diagonalizer` (`diagonalizer.hpp`) Class to diagonalize symmetric Matrices
1. Members:
- `std::vector<double> ev(std::vector<double> mat, size_t N)`:
returns eigenvalues of the symmetric matrix mat of linear size N
throws upon diagonalization failure
- `std::pair<std::vector<double>, std::vector<double> > evv(std::vector<double> mat, size_t N)`:
returns pair of (eigenvalues, eigenvectors) of the symmetric matrix mat of size N
throws upon diagonalization failure
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment