HLIBpro  1.2
Public Member Functions | List of all members
TPermutation Class Reference

Describes permutation of index sets.

#include <TPermutation.hh>

Inherits valarray< T >.

Public Member Functions

 TPermutation (const size_t asize=0)
 construct permutation of size asize
 TPermutation (const std::valarray< idx_t > &perm)
 construct permutation with data defined by array perm
 TPermutation (const TPermutation &perm)
 copy ctor
virtual ~TPermutation ()
 dtor
idx_t permute (const idx_t idx) const
 permute given index
void permute (const TVector *x, TVector *y) const
 permute given vectors with source data in x and destination y
void invert ()
 invert permutation
virtual void read (TByteStream &s)
 read object data from bytestream s
virtual void write (TByteStream &s) const
 write object data to bytestream s
virtual size_t bs_size () const
 returns size of object in bytestream
TPermutationoperator= (const TPermutation &perm)
 copy operator
TPermutationoperator= (const std::valarray< idx_t > &perm)
 copy operator for valarray
virtual size_t byte_size () const
 return size in bytes used by this object

Additional Inherited Members

- Public Attributes inherited from valarray< T >
elements
 STL member.