namespace alps {
class LatticeDescriptor : public coordinate_lattice<simple_lattice<>,std::vector<alps::StringValue> >
{
public:
typedef coordinate_lattice<simple_lattice<>,std::vector<alps::StringValue> > base_type;
typedef lattice_traits<base_type>::unit_cell_type unit_cell_type;
typedef lattice_traits<base_type>::offset_type offset_type;
typedef lattice_traits<base_type>::cell_descriptor cell_descriptor;
typedef lattice_traits<base_type>::vector_type vector_type;
typedef lattice_traits<base_type>::basis_vector_iterator basis_vector_iterator;
LatticeDescriptor() {}
LatticeDescriptor(const palmxml::XMLTag&, std::istream&);
void set_parameters(const alps::Parameters&);
template<class T>
void add_default_parameter(const std::string& name, const T& value)
void write_xml(std::ostream&, const std::string& new_name= "") const;
const std::string& name() const;
std::size_t dimension() const;
};
typedef std::map<std::string,LatticeDescriptor> LatticeMap;
class FiniteLatticeDescriptor : hypercubic_lattice<coordinate_lattice<simple_lattice<>,std::vector<alps::StringValue> >, std::vector<alps::StringValue> >
{
public:
typedef hypercubic_lattice<coordinate_lattice<simple_lattice<>,std::vector<alps::StringValue> >, std::vector<alps::StringValue> > base_type;
typedef lattice_traits<base_type>::unit_cell_type unit_cell_type;
typedef lattice_traits<base_type>::offset_type offset_type;
typedef lattice_traits<base_type>::cell_descriptor cell_descriptor;
typedef lattice_traits<base_type>::vector_type vector_type;
typedef lattice_traits<base_type>::basis_vector_iterator basis_vector_iterator;
typedef lattice_traits<base_type>::cell_iterator cell_iterator;
typedef lattice_traits<base_type>::size_type size_type;
FiniteLatticeDescriptor() {}
FiniteLatticeDescriptor(const palmxml::XMLTag&, std::istream&,
const LatticeMap& = LatticeMap());
void set_parameters(const palm::Parameters&);
void write_xml(std::ostream&, const std::string& n= "") const;
const std::string& name() const;
std::size_t dimension() const;
};
typedef std::map<std::string,FiniteLatticeDescriptor> FiniteLatticeMap;
std::ostream& operator<<(std::ostream& out, const LatticeDescriptor& l);
std::ostream& operator<<(std::ostream& out, const FiniteLatticeDescriptor& l);
}
these types are inherited from coordinate_lattice.typedef lattice_traits<base_type>::unit_cell_type unit_cell_type;
typedef lattice_traits<base_type>::offset_type offset_type;
typedef lattice_traits<base_type>::cell_descriptor cell_descriptor;
typedef lattice_traits<base_type>::vector_type vector_type;
typedef lattice_traits<base_type>::basis_vector_iterator basis_vector_iterator;
an empty lattice without any information.LatticeDescriptor() {}
reads the LatticeDescriptor in XML from a stream assuming the Lattice XML schema on http://xml.comp-phys.org. The start tag <LATTICE ...> has already been read and is passed as a palmxml::XMLTag.LatticeDescriptor(const palmxml::XMLTag&, std::istream&);
sets parameters for the lattice, e.g. parammeters specifying the basis vectors.void set_parameters(const alps::Parameters&);
template<class T>
void add_default_parameter(const std::string& name, const T& value)
adds a new parameter and default value to the LatticeDescriptor.
writes the lattice in XML, using the same Lattice XML schema on http://xml.comp-phys.org. It can optionally be renamed by passing a new name as the second argument.void write_xml(std::ostream&, const std::string& new_name= "") const;
returns the name of the latticeconst std::string& name() const;
returns the dimension of the lattice.std::size_t dimension() const;
can be used to keep a collection of LatticeDescriptor objects, indexed by their name.typedef std::map<std::string,LatticeDescriptor> LatticeMap;
these types are inherited from hypercubic_lattice.typedef lattice_traits<base_type>::unit_cell_type unit_cell_type;
typedef lattice_traits<base_type>::offset_type offset_type;
typedef lattice_traits<base_type>::cell_descriptor cell_descriptor;
typedef lattice_traits<base_type>::vector_type vector_type;
typedef lattice_traits<base_type>::basis_vector_iterator basis_vector_iterator;
typedef lattice_traits<base_type>::cell_iterator cell_iterator;
typedef lattice_traits<base_type>::size_type size_type;
an empty lattice without any information.FiniteLatticeDescriptor() {}
reads the FiniteLatticeDesriptor in XML from a stream assuming the Lattice XML schema on http://xml.comp-phys.org. The start tag <FINITELATTICE ...> has already been read and is passed as a palmxml::XMLTagFiniteLatticeDescriptor(const palmxml::XMLTag&, std::istream&,
const LatticeMap& = LatticeMap());
In the lattice schema the <FINITELATTICE ...> contains a <LATTICE ...> element. This can either describe the lattice fully, or refer to a lattice by name. The optional LatticeMap argument can be used to pass the known lattices.
The lattice schema allows the extent and boundary conditions to be specified by external parameters. The set_parameters function allows to pass a map of parameters, to fill the values of the parameters.void set_parameters(const palm::Parameters&);
writes the finite lattice in XML, using the same Lattice XML schema on http://xml.comp-phys.org. It can optionally be renamed by passing a new name as the second argument.void write_xml(std::ostream&, const std::string& new_name= "") const;
returns the name of the latticeconst std::string& name() const;
returns the dimension of the lattice.std::size_t dimension() const;
can be used to keep a collection of FiniteLatticeDescriptor objects, indexed by their name.typedef std::map<std::string,FiniteLatticeDescriptor> FiniteLatticeMap;
write the LatticeDescriptor and FiniteLatticeDescriptor in XML, using the write_xml member functions.std::ostream& operator<<(std::ostream& out, const LatticeDescriptor& l);
std::ostream& operator<<(std::ostream& out, const FiniteLatticeDescriptor& l);
copyright (c) 1994-2010 by Matthias Troyer
Distributed under the Boost Software License, Version 1.0. (See http://www.boost.org/LICENSE_1_0.txt)