... | ... | @@ -17,7 +17,7 @@ class grid_cpu |
|
|
{
|
|
|
|
|
|
```
|
|
|
A grid has a natural indexing based on k-indexes with k == dimensionality of the grid, the last template argument, grid_ind=grid_sm<dim>, with the class grid_sm give specify a linearisation (map) of the indexes. The class grid_sm implement the typical linearisation of the indexes by stride with last index as the lower index (C ordering), others map implementations can produce strides with first index as lower index (Fortran ordering), or implementing other ordering like Hilbert curves for cache friendly access, other space filling curves or even other more complex mappings.
|
|
|
A grid has a natural indexing based on k-indexes with k == dimensionality of the grid, the last template argument, grid_ind=grid_sm<dim>, with the class grid_sm give specify a linearisation (map) of the indexes. The class grid_sm implement the typical linearisation of the indexes by stride with last index as the lower index (C ordering), others map implementations can produce strides with first index as lower index (Fortran ordering), or implementing other maps like Hilbert curves for cache friendlyness, other space filling curves or even other more complex mappings that can involve sparse rappresentation/multi-resolution.
|
|
|
|
|
|
|
|
|
The definition of a linearisation is required only for structure with random access capabilities.
|
... | ... | |