Dune Core Modules (2.10.0)

Some generic functions for pretty printing vectors and matrices. More...

#include <cmath>
#include <complex>
#include <limits>
#include <ios>
#include <iomanip>
#include <fstream>
#include <string>
#include "matrixutils.hh"
#include "istlexception.hh"
#include <dune/common/fvector.hh>
#include <dune/common/fmatrix.hh>
#include <dune/common/hybridutilities.hh>
#include <dune/common/reservedvector.hh>
#include <dune/istl/bcrsmatrix.hh>
#include <dune/istl/blocklevel.hh>

Go to the source code of this file.

Classes

struct  Dune::DefaultSVGMatrixOptions
 Default options class to write SVG matrices. More...
 

Namespaces

namespace  Dune
 Dune namespace.
 

Functions

template<class V >
void Dune::recursive_printvector (std::ostream &s, const V &v, std::string rowtext, int &counter, int columns, int width)
 Recursively print a vector. More...
 
template<class V >
void Dune::printvector (std::ostream &s, const V &v, std::string title, std::string rowtext, int columns=1, int width=10, int precision=2)
 Print an ISTL vector. More...
 
void Dune::fill_row (std::ostream &s, int m, int width, int precision)
 Print a row of zeros for a non-existing block. More...
 
template<class K , std::enable_if_t< Dune::IsNumber< K >::value, int > = 0>
void Dune::print_row (std::ostream &s, const K &value, typename FieldMatrix< K, 1, 1 >::size_type I, typename FieldMatrix< K, 1, 1 >::size_type J, typename FieldMatrix< K, 1, 1 >::size_type therow, int width, int precision)
 Print one row of a matrix, specialization for number types. More...
 
template<class M , std::enable_if_t< not Dune::IsNumber< M >::value, int > = 0>
void Dune::print_row (std::ostream &s, const M &A, typename M::size_type I, typename M::size_type J, typename M::size_type therow, int width, int precision)
 Print one row of a matrix. More...
 
template<class M >
void Dune::printmatrix (std::ostream &s, const M &A, std::string title, std::string rowtext, int width=10, int precision=2)
 Print a generic block matrix. More...
 
template<class A , class InnerMatrixType >
void Dune::printSparseMatrix (std::ostream &s, const BCRSMatrix< InnerMatrixType, A > &mat, std::string title, std::string rowtext, int width=3, int precision=2)
 Prints a BCRSMatrix with fixed sized blocks. More...
 
template<class FieldType , std::enable_if_t< Dune::IsNumber< FieldType >::value, int > = 0>
void Dune::writeMatrixToMatlabHelper (const FieldType &value, int rowOffset, int colOffset, std::ostream &s)
 Helper method for the writeMatrixToMatlab routine. More...
 
template<class MatrixType , std::enable_if_t< not Dune::IsNumber< MatrixType >::value, int > = 0>
void Dune::writeMatrixToMatlabHelper (const MatrixType &matrix, int externalRowOffset, int externalColOffset, std::ostream &s)
 Helper method for the writeMatrixToMatlab routine. More...
 
template<class MatrixType >
void Dune::writeMatrixToMatlab (const MatrixType &matrix, const std::string &filename, int outputPrecision=18)
 Writes sparse matrix in a Matlab-readable format. More...
 
template<class VectorType >
void Dune::writeVectorToMatlab (const VectorType &vector, const std::string &filename, int outputPrecision=18)
 Writes vectors in a Matlab-readable format. More...
 
template<class Mat , class SVGOptions = DefaultSVGMatrixOptions>
void Dune::writeSVGMatrix (std::ostream &out, const Mat &mat, SVGOptions opts={})
 Writes the visualization of matrix in the SVG format. More...
 
template<class Mat , class SVGOptions = DefaultSVGMatrixOptions>
void Dune::writeSVGMatrix (const Mat &mat, std::ostream &out, SVGOptions opts={})
 Writes the visualization of matrix in the SVG format. More...
 

Detailed Description

Some generic functions for pretty printing vectors and matrices.

Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.111.3 (Dec 26, 23:30, 2024)