Regularly spaced N dimensional grid base type. More...
#include <regular_grid.hpp>

Public Member Functions | |
| Eigen::Vector< int, NDim > | cell_near (const Eigen::Vector< double, NDim > &p) const |
| Compute nearest grid cell coordinates given plane coordinates. More... | |
| Eigen::Vector< double, NDim > | coordinates_at (const Eigen::Vector< int, NDim > &pi) const |
| Compute plane coordinates given grid cell coordinates. More... | |
| template<class Range > | |
| auto | coordinates_for (Range &&cells) const |
| Compute plane coordinates given a range of cell coordinates. More... | |
Regularly spaced N dimensional grid base type.
When instantiated, it satisfies Beluga named requirements: RegularGrid.
| Derived | Concrete regular grid type. It must define Derived::resolution(), as described in Beluga named requirements: RegularGrid. |
| NDim | Dimension of the grid. |
Definition at line 65 of file regular_grid.hpp.
|
inline |
Compute nearest grid cell coordinates given plane coordinates.
Note this is a surjective function.
| p | Plane coordinates. |
Definition at line 74 of file regular_grid.hpp.
|
inline |
Compute plane coordinates given grid cell coordinates.
Note this is an injective function.
| pi | Grid cell coordinates. |
Definition at line 86 of file regular_grid.hpp.
|
inline |
Compute plane coordinates given a range of cell coordinates.
| cells | Range of grid cell identifiers. |
Definition at line 96 of file regular_grid.hpp.