Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
shammath::iterator_utils::LatticeIterator< Tvec, Lattice > Class Template Reference

Iterator going through a lattice coordinates range in order. More...

#include <shammath/include/shammath/crystalLattice.hpp>

Public Member Functions

 LatticeIterator (Tscal dr, std::array< i32, dim > coord_min, std::array< i32, dim > coord_max)
bool is_done ()
Tvec next ()
std::vector< Tvec > next_n (u64 nmax)
void skip (u64 n)

Detailed Description

template<class Tvec, class Lattice>
class shammath::iterator_utils::LatticeIterator< Tvec, Lattice >

Iterator going through a lattice coordinates range in order.

Template Parameters
Tvecposition vector type
Latticelattice class providing a static generator(dr, coord) function

Definition at line 56 of file crystalLattice.hpp.

Constructor & Destructor Documentation

◆ LatticeIterator()

template<class Tvec, class Lattice>
shammath::iterator_utils::LatticeIterator< Tvec, Lattice >::LatticeIterator ( Tscal dr,
std::array< i32, dim > coord_min,
std::array< i32, dim > coord_max )
inline

Definition at line 70 of file crystalLattice.hpp.

Member Function Documentation

◆ is_done()

template<class Tvec, class Lattice>
bool shammath::iterator_utils::LatticeIterator< Tvec, Lattice >::is_done ( )
inline

Definition at line 89 of file crystalLattice.hpp.

◆ next()

template<class Tvec, class Lattice>
Tvec shammath::iterator_utils::LatticeIterator< Tvec, Lattice >::next ( )
inline

Definition at line 91 of file crystalLattice.hpp.

◆ next_n()

template<class Tvec, class Lattice>
std::vector< Tvec > shammath::iterator_utils::LatticeIterator< Tvec, Lattice >::next_n ( u64 nmax)
inline

Definition at line 119 of file crystalLattice.hpp.

◆ skip()

template<class Tvec, class Lattice>
void shammath::iterator_utils::LatticeIterator< Tvec, Lattice >::skip ( u64 n)
inline

Definition at line 131 of file crystalLattice.hpp.


The documentation for this class was generated from the following file: