5 #include <ddc/kernels/splines.hpp>
7 #include "ddc_alias_inline_functions.hpp"
8 #include "ddc_aliases.hpp"
9 #include "ddc_helper.hpp"
10 #include "directional_tag.hpp"
11 #include "vector_field.hpp"
12 #include "vector_field_mem.hpp"
24 static bool constexpr
PERIODIC =
true;
35 static bool constexpr
PERIODIC =
true;
39 using CoordX = Coord<X>;
40 using CoordY = Coord<Y>;
41 using CoordXY = Coord<X, Y>;
43 int constexpr BSDegreeX = 3;
44 int constexpr BSDegreeY = 3;
46 bool constexpr BsplineOnUniformCellsX =
true;
47 bool constexpr BsplineOnUniformCellsY =
true;
51 BsplineOnUniformCellsX,
52 ddc::UniformBSplines<X, BSDegreeX>,
53 ddc::NonUniformBSplines<X, BSDegreeX>>
58 BsplineOnUniformCellsY,
59 ddc::UniformBSplines<Y, BSDegreeY>,
60 ddc::NonUniformBSplines<Y, BSDegreeY>>
64 ddc::BoundCond constexpr SplineXBoundary = ddc::BoundCond::PERIODIC;
65 ddc::BoundCond constexpr SplineYBoundary = ddc::BoundCond::PERIODIC;
68 using SplineInterpPointsX
69 = ddc::GrevilleInterpolationPoints<BSplinesX, SplineXBoundary, SplineXBoundary>;
70 using SplineInterpPointsY
71 = ddc::GrevilleInterpolationPoints<BSplinesY, SplineYBoundary, SplineYBoundary>;
74 struct GridX : SplineInterpPointsX::interpolation_discrete_dimension_type
77 struct GridY : SplineInterpPointsY::interpolation_discrete_dimension_type
83 using SplineXBuilder_XY = ddc::SplineBuilder<
84 Kokkos::DefaultExecutionSpace,
85 Kokkos::DefaultExecutionSpace::memory_space,
90 ddc::SplineSolver::LAPACK,
93 using SplineXEvaluator_XY = ddc::SplineEvaluator<
94 Kokkos::DefaultExecutionSpace,
95 Kokkos::DefaultExecutionSpace::memory_space,
98 ddc::PeriodicExtrapolationRule<X>,
99 ddc::PeriodicExtrapolationRule<X>,
104 using SplineYBuilder_XY = ddc::SplineBuilder<
105 Kokkos::DefaultExecutionSpace,
106 Kokkos::DefaultExecutionSpace::memory_space,
111 ddc::SplineSolver::LAPACK,
114 using SplineYEvaluator_XY = ddc::SplineEvaluator<
115 Kokkos::DefaultExecutionSpace,
116 Kokkos::DefaultExecutionSpace::memory_space,
119 ddc::PeriodicExtrapolationRule<Y>,
120 ddc::PeriodicExtrapolationRule<Y>,
125 using IdxRangeBSX = IdxRange<BSplinesX>;
126 using IdxRangeBSY = IdxRange<BSplinesY>;
127 using IdxRangeBSXY = IdxRange<BSplinesX, BSplinesY>;
129 template <
class ElementType>
130 using BSConstFieldXY = Field<ElementType const, IdxRangeBSXY>;
131 using DBSConstFieldXY = BSConstFieldXY<double>;
134 using IdxX = Idx<GridX>;
135 using IdxY = Idx<GridY>;
136 using IdxXY = Idx<GridX, GridY>;
139 using IdxStepX = IdxStep<GridX>;
140 using IdxStepY = IdxStep<GridY>;
143 using IdxRangeX = IdxRange<GridX>;
144 using IdxRangeY = IdxRange<GridY>;
145 using IdxRangeXY = IdxRange<GridX, GridY>;
149 template <
class ElementType>
150 using FieldMemX = FieldMem<ElementType, IdxRangeX>;
151 using DFieldMemX = FieldMemX<double>;
153 template <
class ElementType>
154 using FieldMemY = FieldMem<ElementType, IdxRangeY>;
155 using DFieldMemY = FieldMemY<double>;
157 template <
class ElementType>
158 using FieldMemXY = FieldMem<ElementType, IdxRangeXY>;
159 using DFieldMemXY = FieldMemXY<double>;
163 template <
class ElementType>
164 using FieldX = Field<ElementType, IdxRangeX>;
165 using DFieldX = FieldX<double>;
167 template <
class ElementType>
168 using FieldY = Field<ElementType, IdxRangeY>;
169 using DFieldY = FieldY<double>;
171 template <
class ElementType>
172 using FieldXY = Field<ElementType, IdxRangeXY>;
173 using DFieldXY = FieldXY<double>;
177 template <
class ElementType>
178 using ConstFieldX = Field<ElementType const, IdxRangeX>;
180 template <
class ElementType>
181 using ConstFieldY = Field<ElementType const, IdxRangeY>;
183 template <
class ElementType>
184 using ConstFieldXY = Field<ElementType const, IdxRangeXY>;
185 using DConstFieldXY = ConstFieldXY<double>;
194 Kokkos::DefaultExecutionSpace::memory_space>;
Pre-declaration of VectorFieldMem.
Definition: vector_field_mem.hpp:54
VectorField< const ElementType, IdxRangeType, NDTag, MemSpace, std::experimental::layout_right > view_type
A type which can hold a constant reference to this VectorFieldMem.
Definition: vector_field_mem.hpp:103
VectorField< ElementType, IdxRangeType, NDTag, MemSpace, std::experimental::layout_right > span_type
A type which can hold a reference to this VectorFieldMem.
Definition: vector_field_mem.hpp:91
Definition: geometry.hpp:76
Definition: geometry.hpp:61
Definition: geometry.hpp:102
Definition: geometry.hpp:78
Define non periodic real X dimension.
Definition: geometry.hpp:278
static constexpr bool PERIODIC
Define periodicity of the dimension.
Definition: geometry.hpp:283
Define non periodic real Y dimension.
Definition: geometry.hpp:289
static constexpr bool PERIODIC
Define periodicity of the dimension.
Definition: geometry.hpp:294