Regular Hypercubic lattice

Functions

void writelat(H5::Group &h5loc, const RegularHypercubic &l)

This function provides the necessary overload for MARQOV::Core such that we can dump useful info into the HDF5 file.

Parameters
  • h5loc: the group of the lattice.

  • l: the lattice that we are dumping info about.

template<int dimT>
class FixedDimRegularHypercubic

Public Functions

constexpr FixedDimRegularHypercubic(int len)
constexpr std::array<int, 2 * dimT> nbrs(const int alpha, const int i) const
constexpr std::array<double, dimT> crds(int k) const

Get the real space coordinates of a site.

Return

the real space coordinates the point.

Parameters
  • k: the index of the site.

constexpr std::array<int, 2 * dimT> flexnbrs(const int alpha, const int i) const
constexpr std::size_t size() const noexcept

Return the number of sites in this lattice.

Return

the number of sites in this lattice.

Public Members

int len = {0}
int npoints = {0}

Public Static Attributes

static constexpr int dim = {dimT}

Private Members

std::array<int, dim> pows = {0}
class RegularHypercubic
#include <regular_hypercubic.h>

The Regular Hypercubic lattice class.

This class provides routines for encapsulating all neighbour and coordinate relations for n-dimensional hypercubic lattices.

Public Functions

RegularHypercubic(int len, int dim)
RegularHypercubic(const RegularHypercubic&) = default
RegularHypercubic(RegularHypercubic&&) noexcept = default
RegularHypercubic &operator=(const RegularHypercubic&) = delete
RegularHypercubic &operator=(const RegularHypercubic&&) = delete
RegularHypercubic() = delete
std::vector<int> nbrs(const int alpha, const int i) const
std::vector<double> crds(const int i) const

Get the real space coordinates of a site.

Return

the real space coordinates the point.

Parameters
  • i: the index of the site.

std::vector<int> flexnbrs(const int alpha, const int i) const
std::size_t size() const noexcept

Return the number of sites in this lattice.

Return

the number of sites in this lattice.

Public Members

int len
int dim
int npoints

Private Members

RegularLattice lattice