Implementation of various utilities related to linear algebra. More...
#include <vector>
#include <map>
#include <cmath>
#include <assert.h>
#include <bitset>
#include "viennashe/forwards.h"
Go to the source code of this file.
Classes | |
class | viennashe::math::sparse_matrix< NumericT > |
Sparse matrix class based on a vector of binary trees for holding the entries. More... | |
class | viennashe::math::dense_matrix< NumericT > |
Namespaces | |
namespace | viennashe |
The main ViennaSHE namespace. All functionality resides inside this namespace. | |
namespace | viennashe::math |
Namespace for all math specific code | |
Functions | |
template<typename VectorType > | |
VectorType::value_type | viennashe::math::norm_2 (VectorType const &v) |
template<typename VectorType > | |
VectorType | viennashe::math::subtract (VectorType const &x, VectorType const &y) |
Helper routine for the generic vector subtraction z = x - y;. More... | |
template<typename NumericT , typename VectorT > | |
VectorT | viennashe::math::row_normalize_system (sparse_matrix< NumericT > &system_matrix, VectorT &rhs) |
Normalizes an equation system such that all diagonal entries are non-negative, and such that all 2-norms of the rows are unity. More... | |
template<typename NumericT > | |
std::ostream & | viennashe::math::operator<< (std::ostream &os, sparse_matrix< NumericT > const &system_matrix) |
Converts a sparse matrix (ublas, ViennaCL) to a string. Handy debugging facility. More... | |
template<typename NumericT , typename VectorType > | |
void | viennashe::math::check_types (sparse_matrix< NumericT > const &system_matrix, VectorType const &x) |
template<typename NumericT , typename VectorType > | |
VectorType | viennashe::math::prod (sparse_matrix< NumericT > const &system_matrix, VectorType const &x) |
Computes A * x for a sparse A and a vector x. More... | |
Implementation of various utilities related to linear algebra.
Definition in file linalg_util.hpp.