Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

atlas::subquotient::Subspace< dim > Class Template Reference

Subspace of (Z/2Z)^d_rank. More...

#include <subquotient.h>

Collaboration diagram for atlas::subquotient::Subspace< dim >:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 Subspace ()
 Subspace (size_t n)
 Subspace (const bitvector::BitVectorList< dim > &, size_t)
 Constructs the normal subspace generated by the collection of |BitVectors| |b|, each of which has rank |n|.
 ~Subspace ()
const bitvector::BitVector<
dim > & 
basis (size_t j) const
const bitvector::BitVectorList<
dim > & 
basis () const
size_t dimension () const
const size_t rank () const
const bitset::BitSet< dim > & support () const
bitvector::BitVector< dim > toBasis (bitvector::BitVector< dim > v) const
 Expresses |v| in the subspace basis.
bitvector::BitVector< dim > fromBasis (bitvector::BitVector< dim > v) const
 Interprets |v| in the subspace basis and returns external form.
bool contains (const bitvector::BitVector< dim > &v) const
bool contains (const bitvector::BitVectorList< dim > &m) const
void representative (bitvector::BitVector< dim > &, const bitvector::BitVector< dim > &) const
 Put in |r| the canonical representative of |v| modulo our subspace.
void mod_reduce (bitvector::BitVector< dim > &w) const
bitvector::BitVector< dim > mod_image (const bitvector::BitVector< dim > &w) const
void apply (const bitvector::BitMatrix< dim > &)
void swap (Subspace &)

Private Attributes

size_t d_rank
 Dimension of the ambient vector space.
bitvector::BitVectorList<
dim > 
d_basis
 Basis of our |Subspace| in reduced form.
bitset::BitSet< dim > d_support
 |BitSet| flagging the positions of the leading nonzero bits in the basis of our |Subspace|.

Detailed Description

template<size_t dim>
class atlas::subquotient::Subspace< dim >

Subspace of (Z/2Z)^d_rank.

Elements of the vector space are |BitVector|s of capacity |dim| and actual size |d_rank|. The subspace is recorded by its (unique) ordered canonical basis |d_basis|. This means its vectors are reduced (in the sense of row-reduced matrices); that is (in the binary case) in the position of the leading (nonzero) bit of each vector, the other vectors heve a bit $0$, and the vectors are ordered by increasing position of their leading bit.

The locations of the leading bits are flagged by the |BitSet| |d_support| (of capacity |d_rank|); the number of set bits in |d_support| is equal to the dimension |d_basis.size()| of the |Subspace|.

Definition at line 58 of file subquotient.h.


Constructor & Destructor Documentation

template<size_t dim>
atlas::subquotient::Subspace< dim >::Subspace  )  [inline]
 

Definition at line 82 of file subquotient.h.

template<size_t dim>
atlas::subquotient::Subspace< dim >::Subspace size_t  n  )  [inline, explicit]
 

Definition at line 84 of file subquotient.h.

template<size_t dim>
atlas::subquotient::Subspace< dim >::Subspace const bitvector::BitVectorList< dim > &  b,
size_t  n
 

Constructs the normal subspace generated by the collection of |BitVectors| |b|, each of which has rank |n|.

Definition at line 35 of file subquotient_def.h.

References atlas::subquotient::Subspace< dim >::d_basis, atlas::subquotient::Subspace< dim >::d_support, and atlas::dynkin::normalize().

template<size_t dim>
atlas::subquotient::Subspace< dim >::~Subspace  )  [inline]
 

Definition at line 88 of file subquotient.h.


Member Function Documentation

template<size_t dim>
void atlas::subquotient::Subspace< dim >::apply const bitvector::BitMatrix< dim > &  r  ) 
 

Synopsis: applies |r| to our subspace, normalizing the resulting subspace.

Precondition: r is a matrix of the appropriate size (it could go to a space of another dimension, even.)

Definition at line 91 of file subquotient_def.h.

References atlas::bitvector::BitMatrix< dim >::apply(), atlas::bitvector::BitMatrix< dim >::numColumns(), atlas::bitvector::BitMatrix< dim >::numRows(), and atlas::subquotient::Subspace< dim >::swap().

template<size_t dim>
const bitvector::BitVectorList<dim>& atlas::subquotient::Subspace< dim >::basis  )  const [inline]
 

Definition at line 98 of file subquotient.h.

template<size_t dim>
const bitvector::BitVector<dim>& atlas::subquotient::Subspace< dim >::basis size_t  j  )  const [inline]
 

Definition at line 93 of file subquotient.h.

template<size_t dim>
bool atlas::subquotient::Subspace< dim >::contains const bitvector::BitVectorList< dim > &  m  )  const [inline]
 

Definition at line 143 of file subquotient.h.

template<size_t dim>
bool atlas::subquotient::Subspace< dim >::contains const bitvector::BitVector< dim > &  v  )  const [inline]
 

Definition at line 140 of file subquotient.h.

References atlas::bitvector::BitVector< dim >::isZero().

template<size_t dim>
size_t atlas::subquotient::Subspace< dim >::dimension  )  const [inline]
 

Definition at line 102 of file subquotient.h.

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::dimension(), atlas::subquotient::Subquotient< constants::RANK_MAX >::fromBasis(), and atlas::subquotient::Subquotient< constants::RANK_MAX >::toBasis().

template<size_t dim>
bitvector::BitVector<dim> atlas::subquotient::Subspace< dim >::fromBasis bitvector::BitVector< dim >  v  )  const [inline]
 

Interprets |v| in the subspace basis and returns external form.

Definition at line 129 of file subquotient.h.

References atlas::bitvector::combination(), atlas::bitvector::BitVector< dim >::data(), atlas::lietype::rank(), and atlas::bitvector::BitVector< dim >::size().

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::fromBasis().

template<size_t dim>
bitvector::BitVector<dim> atlas::subquotient::Subspace< dim >::mod_image const bitvector::BitVector< dim > &  w  )  const [inline]
 

Definition at line 159 of file subquotient.h.

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::mod_image().

template<size_t dim>
void atlas::subquotient::Subspace< dim >::mod_reduce bitvector::BitVector< dim > &  w  )  const [inline]
 

Definition at line 156 of file subquotient.h.

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::mod_reduce().

template<size_t dim>
const size_t atlas::subquotient::Subspace< dim >::rank  )  const [inline]
 

Definition at line 106 of file subquotient.h.

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::rank().

template<size_t dim>
void atlas::subquotient::Subspace< dim >::representative bitvector::BitVector< dim > &  r,
const bitvector::BitVector< dim > &  v
const
 

Put in |r| the canonical representative of |v| modulo our subspace.

This |r| is characterized by the vanishing of its bits in positions |d_support| (the leading bits of the canonical basis of our subspace). Note that we are making no reference to the space from which our subspace is divided out; this could be the whole space $(Z/2Z)^n$ (in any case |r| is expressed in its canonical basis) or some subspace containing our subspace.

The algorithm projects v onto pv in the subspace expressed in the canonical basis of the subspace. The coordinates of pv are the entries of v in the coordinates flagged by d_support.

Then w is the BitVector in (Z/2Z)^n given by combining the canonical basis with coefficients pv. Finally r is equal to v-w.

Definition at line 66 of file subquotient_def.h.

References atlas::bitvector::combination(), and atlas::lietype::rank().

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::representative().

template<size_t dim>
const bitset::BitSet<dim>& atlas::subquotient::Subspace< dim >::support  )  const [inline]
 

Definition at line 110 of file subquotient.h.

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::significantBits().

template<size_t dim>
void atlas::subquotient::Subspace< dim >::swap Subspace< dim > &   ) 
 

Definition at line 115 of file subquotient_def.h.

References atlas::subquotient::Subspace< dim >::d_basis, atlas::subquotient::Subspace< dim >::d_rank, atlas::subquotient::Subspace< dim >::d_support, atlas::bitset::BitSet< n >::swap(), and atlas::bitvector::BitMatrix< dim >::swap().

Referenced by atlas::subquotient::Subspace< dim >::apply().

template<size_t dim>
bitvector::BitVector<dim> atlas::subquotient::Subspace< dim >::toBasis bitvector::BitVector< dim >  v  )  const [inline]
 

Expresses |v| in the subspace basis.

Definition at line 117 of file subquotient.h.

References atlas::bitvector::BitVector< dim >::size(), and atlas::bitvector::BitVector< dim >::slice().

Referenced by atlas::subquotient::Subquotient< constants::RANK_MAX >::toBasis().


Member Data Documentation

template<size_t dim>
bitvector::BitVectorList<dim> atlas::subquotient::Subspace< dim >::d_basis [private]
 

Basis of our |Subspace| in reduced form.

Definition at line 70 of file subquotient.h.

Referenced by atlas::subquotient::Subspace< dim >::Subspace(), and atlas::subquotient::Subspace< dim >::swap().

template<size_t dim>
size_t atlas::subquotient::Subspace< dim >::d_rank [private]
 

Dimension of the ambient vector space.

Definition at line 65 of file subquotient.h.

Referenced by atlas::subquotient::Subspace< dim >::swap().

template<size_t dim>
bitset::BitSet<dim> atlas::subquotient::Subspace< dim >::d_support [private]
 

|BitSet| flagging the positions of the leading nonzero bits in the basis of our |Subspace|.

Definition at line 75 of file subquotient.h.

Referenced by atlas::subquotient::Subspace< dim >::Subspace(), and atlas::subquotient::Subspace< dim >::swap().


The documentation for this class was generated from the following files:
Generated on Wed Mar 26 16:53:05 2008 for atlas by  doxygen 1.3.9.1