MTL5 -- Matrix Template Library C++ API
mtl:: -- C++20 header-only linear algebra for mixed-precision algorithm design
Loading...
Searching...
No Matches
mtl::mat::view::hermitian_view< Matrix > Class Template Reference

Non-owning hermitian view: A(r,c) = conj(A(c,r)) when r > c. More...

#include <hermitian_view.hpp>

Public Types

using value_type = typename Matrix::value_type
using size_type = typename Matrix::size_type
using const_reference = value_type
using reference = value_type

Public Member Functions

 hermitian_view (const Matrix &m)
value_type operator() (size_type r, size_type c) const
size_type num_rows () const
size_type num_cols () const
size_type size () const
const Matrix & base () const

Detailed Description

template<typename Matrix>
class mtl::mat::view::hermitian_view< Matrix >

Non-owning hermitian view: A(r,c) = conj(A(c,r)) when r > c.

Assumes the upper triangle of the underlying matrix is stored.

The matrix must be square, checked once at construction in every build (#826): for a 3x2 A, H(2,0) read A(0,2). The diagonal is returned as stored. A Hermitian matrix has a real diagonal, so for one the view is exact; for a matrix whose stored diagonal is not real, the view is not Hermitian there, and it does not take the real part for you.

Member Typedef Documentation

◆ const_reference

template<typename Matrix>
using mtl::mat::view::hermitian_view< Matrix >::const_reference = value_type

◆ reference

template<typename Matrix>
using mtl::mat::view::hermitian_view< Matrix >::reference = value_type

◆ size_type

template<typename Matrix>
using mtl::mat::view::hermitian_view< Matrix >::size_type = typename Matrix::size_type

◆ value_type

template<typename Matrix>
using mtl::mat::view::hermitian_view< Matrix >::value_type = typename Matrix::value_type

Constructor & Destructor Documentation

◆ hermitian_view()

template<typename Matrix>
mtl::mat::view::hermitian_view< Matrix >::hermitian_view ( const Matrix & m)
inlineexplicit

Member Function Documentation

◆ base()

template<typename Matrix>
const Matrix & mtl::mat::view::hermitian_view< Matrix >::base ( ) const
inline

◆ num_cols()

template<typename Matrix>
size_type mtl::mat::view::hermitian_view< Matrix >::num_cols ( ) const
inline

◆ num_rows()

template<typename Matrix>
size_type mtl::mat::view::hermitian_view< Matrix >::num_rows ( ) const
inline

◆ operator()()

template<typename Matrix>
value_type mtl::mat::view::hermitian_view< Matrix >::operator() ( size_type r,
size_type c ) const
inline

◆ size()

template<typename Matrix>
size_type mtl::mat::view::hermitian_view< Matrix >::size ( ) const
inline

The documentation for this class was generated from the following file: