OKlibrary  0.2.1.6
OKlib::Matrices::Is_self_dual< Matrix, PermutationsGenerator > Class Template Reference

Functor-predicate for checking whether a matrix in the uBLAS-sense is self_dual (is isomorphic to its transposition) More...

#include <Symmetry.hpp>

Inheritance diagram for OKlib::Matrices::Is_self_dual< Matrix, PermutationsGenerator >:
unary_function

List of all members.

Public Member Functions

bool operator() (const Matrix &m) const

Detailed Description

template<class Matrix, class PermutationsGenerator>
class OKlib::Matrices::Is_self_dual< Matrix, PermutationsGenerator >

Functor-predicate for checking whether a matrix in the uBLAS-sense is self_dual (is isomorphic to its transposition)

Reference implementation, following just the definition.

Todo:

TEST IT.

Write a concept.

Here returning the isomorphism found would be very useful. Perhaps this could be done by providing an overload of operator() with three arguments, where the last two arguments are references for the permutations; before doing so a concept of "permutations" is required. Likely a policy is best here, which says what to do with the results, and which also allows to extract further information.

It would be useful to have "matrix expressions" (in uBLAS terminology ?), so that exactly the same as below would be done, but for suitable permutations pr and pc we would just write the test as OKlib::Matrices::is_equal(permutation(m, pr, pc), trans(m)) (as said, this should have the same complexity as the direct approach below).

Over time a great variety of algorithms and implementations for this basic problem should be developed. It arises the general problem, how to name all these different methods for doing the same thing? It would be good to develop a general scheme.

If the permutation generator delivers Gray-codes, then an improved implementation should be able to exploit this.

Enquiry to the boost e-mail list, whether somehow uBLAS can handle row and column permutations?

Definition at line 121 of file Symmetry.hpp.


Member Function Documentation

template<class Matrix , class PermutationsGenerator >
bool OKlib::Matrices::Is_self_dual< Matrix, PermutationsGenerator >::operator() ( const Matrix &  m) const [inline]

Definition at line 122 of file Symmetry.hpp.

References Latex_Handler::begin(), and end.


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