ALPS Home Libraries License Support People ALPS Web Site

PrevUpHomeNext

Class template basis_states

alps::basis_states

Synopsis

// In header: <alps/model/basisstates.h>

template<typename I, typename S = std::vector<I>, 
         typename SS = site_state<I> > 
class basis_states : public std::vector< S > {
public:
  // types
  typedef super_type::const_iterator       const_iterator;
  typedef S                                value_type;    
  typedef super_type::size_type            size_type;     
  typedef basis_states_descriptor< I, SS > basis_type;    

  // construct/copy/destruct
  basis_states();
  template<typename J> 
    basis_states(const basis_states_descriptor< I, SS > &, 
                 const std::vector< std::pair< std::string, half_integer< J > > > &);
  basis_states(const basis_states_descriptor< I, SS > &);

  // public member functions
  std::size_t index(const value_type &) const;
  std::pair< std::size_t, std::complex< double > > 
  index_and_phase(const value_type &) const;
  double normalization(size_type) const;
  bool is_real() const;
  bool check_sort() const;
  const basis_type & basis() const;

  // private member functions
  template<typename J> 
    bool satisfies_quantumnumbers(const std::vector< I > &, 
                                  const std::pair< std::string, half_integer< J > > &);
  template<typename J> 
    void build(const std::vector< std::pair< std::string, half_integer< J > > > &);
};

Description

basis_states public construct/copy/destruct

  1. basis_states();
  2. template<typename J> 
      basis_states(const basis_states_descriptor< I, SS > & b, 
                   const std::vector< std::pair< std::string, half_integer< J > > > & c);
  3. basis_states(const basis_states_descriptor< I, SS > & b);

basis_states public member functions

  1. std::size_t index(const value_type & x) const;
  2. std::pair< std::size_t, std::complex< double > > 
    index_and_phase(const value_type & x) const;
  3. double normalization(size_type) const;
  4. bool is_real() const;
  5. bool check_sort() const;
  6. const basis_type & basis() const;

basis_states private member functions

  1. template<typename J> 
      bool satisfies_quantumnumbers(const std::vector< I > & idx, 
                                    const std::pair< std::string, half_integer< J > > &);
  2. template<typename J> 
      void build(const std::vector< std::pair< std::string, half_integer< J > > > &);
Copyright © 1994, 2002-2005 Matthias Troyer, Synge Todo

PrevUpHomeNext