9 #ifndef _COMPADRE_SOLUTIONSET_HPP_
10 #define _COMPADRE_SOLUTIONSET_HPP_
14 #include <Kokkos_Core.hpp>
20 template <
typename memory_space = device_memory_space>
24 Kokkos::View<TargetOperation*, memory_space>
_lro;
46 Kokkos::View<double*, layout_right, memory_space>
_alphas;
101 template <
typename other_memory_space>
115 if (
_lro.extent(0) != other.
_lro.extent(0)) {
116 Kokkos::resize(
_lro, other.
_lro.extent(0));
136 Kokkos::deep_copy(
_lro, other.
_lro);
157 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
158 KOKKOS_INLINE_FUNCTION
159 int getTargetOffsetIndex(
const int lro_num,
const int input_component,
const int output_component,
const int evaluation_site_local_index = 0)
const {
163 + output_component );
167 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
168 KOKKOS_INLINE_FUNCTION
171 return getAlpha(lro, target_index, 0, 0, neighbor_index, 0, 0, evaluation_site_local_index);
175 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
176 KOKKOS_INLINE_FUNCTION
179 return getAlpha(lro, target_index, output_component, 0, neighbor_index, 0, 0, evaluation_site_local_index);
183 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
184 KOKKOS_INLINE_FUNCTION
185 double getAlpha0TensorTo2Tensor(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int evaluation_site_local_index = 0)
const {
186 return getAlpha(lro, target_index, output_component_axis_1, output_component_axis_2, neighbor_index, 0, 0, evaluation_site_local_index);
190 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
191 KOKKOS_INLINE_FUNCTION
194 return getAlpha(lro, target_index, 0, 0, neighbor_index, input_component, 0, evaluation_site_local_index);
198 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
199 KOKKOS_INLINE_FUNCTION
200 double getAlpha1TensorTo1Tensor(
TargetOperation lro,
const int target_index,
const int output_component,
const int neighbor_index,
const int input_component,
const int evaluation_site_local_index = 0)
const {
202 return getAlpha(lro, target_index, output_component, 0, neighbor_index, input_component, 0, evaluation_site_local_index);
206 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
207 KOKKOS_INLINE_FUNCTION
208 double getAlpha1TensorTo2Tensor(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int input_component,
const int evaluation_site_local_index = 0)
const {
210 return getAlpha(lro, target_index, output_component_axis_1, output_component_axis_2, neighbor_index, input_component, 0, evaluation_site_local_index);
214 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
215 KOKKOS_INLINE_FUNCTION
216 double getAlpha2TensorTo0Tensor(
TargetOperation lro,
const int target_index,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
217 return getAlpha(lro, target_index, 0, 0, neighbor_index, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
221 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
222 KOKKOS_INLINE_FUNCTION
223 double getAlpha2TensorTo1Tensor(
TargetOperation lro,
const int target_index,
const int output_component,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
224 return getAlpha(lro, target_index, output_component, 0, neighbor_index, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
228 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
229 KOKKOS_INLINE_FUNCTION
230 double getAlpha2TensorTo2Tensor(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
231 return getAlpha(lro, target_index, output_component_axis_1, output_component_axis_2, neighbor_index, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
236 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
237 KOKKOS_INLINE_FUNCTION
245 return (total_neighbors_before_target+
TO_GLOBAL(total_added_alphas_before_target))
247 +
TO_GLOBAL(alpha_column_offset*alphas_per_tile_per_target);
254 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
255 KOKKOS_INLINE_FUNCTION
257 const int output_component_axis_2,
const int input_component_axis_1,
258 const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
270 return getTargetOffsetIndex(lro_number, input_index, output_index, evaluation_site_local_index);
274 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
275 KOKKOS_INLINE_FUNCTION
276 double getAlpha(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
298 "getAlpha called on SolutionSet with _contains_valid_alphas=false");
301 output_component_axis_2, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
303 auto alphas_index = this->
getAlphaIndex(target_index, alpha_column_offset);
304 return _alphas(alphas_index + neighbor_index);
310 template<typename ms=memory_space, enable_if_t<!std::is_same<host_memory_space, ms>::value,
int> = 0>
311 KOKKOS_INLINE_FUNCTION
317 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
318 int getTargetOffsetIndex(
const int lro_num,
const int input_component,
const int output_component,
const int evaluation_site_local_index = 0)
const {
322 + output_component );
326 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
329 return getAlpha(lro, target_index, 0, 0, neighbor_index, 0, 0, evaluation_site_local_index);
333 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
336 return getAlpha(lro, target_index, output_component, 0, neighbor_index, 0, 0, evaluation_site_local_index);
340 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
341 double getAlpha0TensorTo2Tensor(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int evaluation_site_local_index = 0)
const {
342 return getAlpha(lro, target_index, output_component_axis_1, output_component_axis_2, neighbor_index, 0, 0, evaluation_site_local_index);
346 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
349 return getAlpha(lro, target_index, 0, 0, neighbor_index, input_component, 0, evaluation_site_local_index);
353 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
354 double getAlpha1TensorTo1Tensor(
TargetOperation lro,
const int target_index,
const int output_component,
const int neighbor_index,
const int input_component,
const int evaluation_site_local_index = 0)
const {
356 return getAlpha(lro, target_index, output_component, 0, neighbor_index, input_component, 0, evaluation_site_local_index);
360 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
361 double getAlpha1TensorTo2Tensor(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int input_component,
const int evaluation_site_local_index = 0)
const {
363 return getAlpha(lro, target_index, output_component_axis_1, output_component_axis_2, neighbor_index, input_component, 0, evaluation_site_local_index);
367 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
368 double getAlpha2TensorTo0Tensor(
TargetOperation lro,
const int target_index,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
369 return getAlpha(lro, target_index, 0, 0, neighbor_index, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
373 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
374 double getAlpha2TensorTo1Tensor(
TargetOperation lro,
const int target_index,
const int output_component,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
375 return getAlpha(lro, target_index, output_component, 0, neighbor_index, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
379 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
380 double getAlpha2TensorTo2Tensor(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
381 return getAlpha(lro, target_index, output_component_axis_1, output_component_axis_2, neighbor_index, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
386 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
394 return (total_neighbors_before_target+
TO_GLOBAL(total_added_alphas_before_target))
396 +
TO_GLOBAL(alpha_column_offset*alphas_per_tile_per_target);
403 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
405 const int output_component_axis_2,
const int input_component_axis_1,
406 const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
418 return getTargetOffsetIndex(lro_number, input_index, output_index, evaluation_site_local_index);
422 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
423 double getAlpha(
TargetOperation lro,
const int target_index,
const int output_component_axis_1,
const int output_component_axis_2,
const int neighbor_index,
const int input_component_axis_1,
const int input_component_axis_2,
const int evaluation_site_local_index = 0)
const {
445 "getAlpha called on SolutionSet with _contains_valid_alphas=false");
448 output_component_axis_2, input_component_axis_1, input_component_axis_2, evaluation_site_local_index);
450 auto alphas_index = this->
getAlphaIndex(target_index, alpha_column_offset);
451 return _alphas(alphas_index + neighbor_index);
457 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
471 template <
typename other_memory_space>
473 if ((
void*)
this != (
void*)&other) {
484 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
493 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
495 std::vector<TargetOperation> temporary_lro_vector(1, lro);
500 template<typename ms=memory_space, enable_if_t<std::is_same<host_memory_space, ms>::value,
int> = 0>
503 std::vector<TargetOperation> unique_new_lro;
505 auto host_lro_lookup = create_mirror_view(
_lro_lookup);
509 Kokkos::deep_copy(host_lro_lookup, -1);
515 for (
size_t i=0; i<lro.size(); ++i) {
517 bool operation_found =
false;
519 for (
size_t j=0; j<
_lro.size(); ++j) {
522 if (
_lro(j)==lro[i]) {
524 operation_found =
true;
527 host_lro_lookup[(int)lro[i]] = j;
534 if (!operation_found) {
535 host_lro_lookup[(int)lro[i]] =
_lro.size() + unique_new_lro.size();
536 unique_new_lro.push_back(lro[i]);
541 auto new_lro = decltype(
_lro)(
"LRO",
_lro.size() + unique_new_lro.size());
542 for (
size_t i=0; i<
_lro.size(); ++i) {
543 new_lro(i) =
_lro(i);
545 for (
size_t i=0; i<unique_new_lro.size(); ++i) {
546 new_lro(i+
_lro.size()) = unique_new_lro[i];
562 int total_offset = 0;
564 for (
size_t i=0; i<
_lro.size(); ++i) {
565 host_lro_total_offsets(i) = total_offset;
573 host_lro_output_tile_size(i) = output_tile_size;
574 host_lro_input_tile_size(i) = input_tile_size;
576 total_offset += input_tile_size * output_tile_size;
604 "getAlpha called on SolutionSet with _contains_valid_alphas=false");
#define compadre_kernel_assert_debug(condition)
std::size_t global_index_type
#define compadre_assert_debug(condition)
compadre_assert_debug is used for assertions that are checked in loops, as these significantly impact...
#define TO_GLOBAL(variable)
KOKKOS_INLINE_FUNCTION int pown(int n, unsigned p)
n^p (n^0 returns 1, regardless of n)
KOKKOS_INLINE_FUNCTION int getTargetOutputTensorRank(const int &index)
Rank of target functional output for each TargetOperation Rank of target functional input for each Ta...
constexpr SamplingFunctional PointSample
Available sampling functionals.
ProblemType
Problem type, that optionally can handle manifolds.
@ MANIFOLD
Solve GMLS problem on a manifold (will use QR or SVD to solve the resultant GMLS problem dependent on...
KOKKOS_INLINE_FUNCTION int getOutputDimensionOfOperation(TargetOperation lro, const int local_dimensions)
Dimensions ^ output rank for target operation.
KOKKOS_INLINE_FUNCTION int getTargetOutputIndex(const int operation_num, const int output_component_axis_1, const int output_component_axis_2, const int dimensions)
Helper function for finding alpha coefficients.
TargetOperation
Available target functionals.
@ COUNT
Should be the total count of all available target functionals.
KOKKOS_INLINE_FUNCTION int getOutputDimensionOfSampling(SamplingFunctional sro, const int local_dimensions)
Dimensions ^ output rank for sampling operation (always in local chart if on a manifold,...
KOKKOS_INLINE_FUNCTION int getSamplingOutputIndex(const SamplingFunctional sf, const int output_component_axis_1, const int output_component_axis_2)
Helper function for finding alpha coefficients.
NeighborLists assists in accessing entries of compressed row neighborhood lists.
global_index_type getRowOffsetHost(int target_index) const
Get offset into compressed row neighbor lists (host)
KOKKOS_INLINE_FUNCTION global_index_type getRowOffsetDevice(int target_index) const
Get offset into compressed row neighbor lists (device)
KOKKOS_INLINE_FUNCTION int getNumberOfNeighborsDevice(int target_index) const
Get number of neighbors for a given target (device)
int getNumberOfNeighborsHost(int target_index) const
Get number of neighbors for a given target (host)
int output_rank
Rank of sampling functional output for each SamplingFunctional.
All vairables and functionality related to the layout and storage of GMLS solutions (alpha values)
KOKKOS_INLINE_FUNCTION double getAlpha0TensorTo0Tensor(TargetOperation lro, const int target_index, const int neighbor_index, const int evaluation_site_local_index=0) const
Helper function for getting alphas for scalar reconstruction from scalar data.
KOKKOS_INLINE_FUNCTION double getAlpha0TensorTo2Tensor(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int evaluation_site_local_index=0) const
Helper function for getting alphas for matrix reconstruction from scalar data.
KOKKOS_INLINE_FUNCTION double getAlpha2TensorTo2Tensor(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Helper function for getting alphas for matrix reconstruction from matrix data.
KOKKOS_INLINE_FUNCTION double getAlpha0TensorTo1Tensor(TargetOperation lro, const int target_index, const int output_component, const int neighbor_index, const int evaluation_site_local_index=0) const
Helper function for getting alphas for vector reconstruction from scalar data.
void addTargets(TargetOperation lro)
Adds a target to the vector of target functional to be applied to the reconstruction.
Kokkos::View< int *, memory_space > _lro_output_tile_size
dimensions ^ rank of tensor of output for each target functional
KOKKOS_INLINE_FUNCTION double getAlpha1TensorTo1Tensor(TargetOperation lro, const int target_index, const int output_component, const int neighbor_index, const int input_component, const int evaluation_site_local_index=0) const
Helper function for getting alphas for vector reconstruction from vector data.
KOKKOS_INLINE_FUNCTION global_index_type getAlphaIndex(const int target_index, const int alpha_column_offset) const
Gives index into alphas given two axes, which when incremented by the neighbor number transforms acce...
double getAlpha2TensorTo2Tensor(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Helper function for getting alphas for matrix reconstruction from matrix data.
global_index_type getAlphaIndex(const int target_index, const int alpha_column_offset) const
Gives index into alphas given two axes, which when incremented by the neighbor number transforms acce...
KOKKOS_INLINE_FUNCTION double getAlpha2TensorTo0Tensor(TargetOperation lro, const int target_index, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Helper function for getting alphas for scalar reconstruction from matrix data.
SolutionSet(SamplingFunctional data_sampling_functional, int dimensions, int local_dimensions, const ProblemType problem_type)
Constructor for SolutionSet.
Kokkos::View< int *, memory_space > _lro_input_tensor_rank
tensor rank of sampling functional (device)
void clearTargets()
Empties the vector of target functionals to apply to the reconstruction.
double getAlpha0TensorTo0Tensor(TargetOperation lro, const int target_index, const int neighbor_index, const int evaluation_site_local_index=0) const
Helper function for getting alphas for scalar reconstruction from scalar data.
int getTargetOffsetIndex(const int lro_num, const int input_component, const int output_component, const int evaluation_site_local_index=0) const
Handles offset from operation input/output + extra evaluation sites.
Kokkos::View< int *, memory_space > _lro_input_tile_size
dimensions ^ rank of tensor of output for each sampling functional
KOKKOS_INLINE_FUNCTION double getAlpha2TensorTo1Tensor(TargetOperation lro, const int target_index, const int output_component, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Helper function for getting alphas for vector reconstruction from matrix data.
KOKKOS_INLINE_FUNCTION int getTargetOperationLocalIndex(TargetOperation lro) const
Get the local index (internal) to GMLS for a particular TargetOperation Every TargetOperation has a g...
Kokkos::View< TargetOperation *, memory_space > _lro
vector of user requested target operations
double getAlpha0TensorTo1Tensor(TargetOperation lro, const int target_index, const int output_component, const int neighbor_index, const int evaluation_site_local_index=0) const
Helper function for getting alphas for vector reconstruction from scalar data.
int _dimensions
dimension of the problem, set at class instantiation only
int getTargetOperationLocalIndex(TargetOperation lro) const
Get the local index (internal) to GMLS for a particular TargetOperation Every TargetOperation has a g...
NeighborLists< Kokkos::View< int * > > _neighbor_lists
Accessor to get neighbor list data, offset data, and number of neighbors per target.
int _max_evaluation_sites_per_target
maximum number of evaluation sites for each target (includes target site)
SamplingFunctional _data_sampling_functional
generally the same as _polynomial_sampling_functional, but can differ if specified at GMLS class inst...
Kokkos::View< double *, layout_right, memory_space > _alphas
generated alpha coefficients (device)
int _added_alpha_size
additional alpha coefficients due to constraints
KOKKOS_INLINE_FUNCTION int getAlphaColumnOffset(TargetOperation lro, const int output_component_axis_1, const int output_component_axis_2, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Retrieves the offset for an operator based on input and output component, generic to row (but still m...
Kokkos::View< int *, memory_space > _lro_output_tensor_rank
tensor rank of target functional (device)
double getAlpha(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Underlying function all interface helper functions call to retrieve alpha values.
double getAlpha2TensorTo0Tensor(TargetOperation lro, const int target_index, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Helper function for getting alphas for scalar reconstruction from matrix data.
decltype(_alphas) getAlphas() const
Get a view (device) of all alphas.
bool _contains_valid_alphas
whether internal alpha values are valid (set externally on a solve)
double getAlpha0TensorTo2Tensor(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int evaluation_site_local_index=0) const
Helper function for getting alphas for matrix reconstruction from scalar data.
Kokkos::View< int *, memory_space > _lro_lookup
vector containing a mapping from a target functionals enum value to the its place in the list of targ...
void addTargets(std::vector< TargetOperation > lro)
Adds a vector of target functionals to the vector of target functionals already to be applied to the ...
double getAlpha1TensorTo1Tensor(TargetOperation lro, const int target_index, const int output_component, const int neighbor_index, const int input_component, const int evaluation_site_local_index=0) const
Helper function for getting alphas for vector reconstruction from vector data.
double getAlpha1TensorTo2Tensor(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int input_component, const int evaluation_site_local_index=0) const
Helper function for getting alphas for matrix reconstruction from vector data.
double getAlpha2TensorTo1Tensor(TargetOperation lro, const int target_index, const int output_component, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Helper function for getting alphas for vector reconstruction from matrix data.
void copyAlphas(SolutionSet< other_memory_space > &other)
Copies alphas between two instances of SolutionSet Copying of alphas is intentionally omitted in copy...
KOKKOS_INLINE_FUNCTION double getAlpha1TensorTo2Tensor(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int input_component, const int evaluation_site_local_index=0) const
Helper function for getting alphas for matrix reconstruction from vector data.
Kokkos::View< int *, memory_space > _lro_total_offsets
index for where this operation begins the for _alpha coefficients
int _total_alpha_values
used for sizing P_target_row and the _alphas view
ProblemType _problem_type
problem type for GMLS problem, can also be set to STANDARD for normal or MANIFOLD for manifold proble...
KOKKOS_INLINE_FUNCTION double getAlpha1TensorTo0Tensor(TargetOperation lro, const int target_index, const int neighbor_index, const int input_component, const int evaluation_site_local_index=0) const
Helper function for getting alphas for scalar reconstruction from vector data.
KOKKOS_INLINE_FUNCTION int getTargetOffsetIndex(const int lro_num, const int input_component, const int output_component, const int evaluation_site_local_index=0) const
Handles offset from operation input/output + extra evaluation sites.
int getAlphaColumnOffset(TargetOperation lro, const int output_component_axis_1, const int output_component_axis_2, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Retrieves the offset for an operator based on input and output component, generic to row (but still m...
SolutionSet(const SolutionSet< other_memory_space > &other)
Copy constructor (can be used to move data from device to host or vice-versa)
int _local_dimensions
dimension of the problem, set at class instantiation only. For manifolds, generally _global_dimension...
double getAlpha1TensorTo0Tensor(TargetOperation lro, const int target_index, const int neighbor_index, const int input_component, const int evaluation_site_local_index=0) const
Helper function for getting alphas for scalar reconstruction from vector data.
KOKKOS_INLINE_FUNCTION double getAlpha(TargetOperation lro, const int target_index, const int output_component_axis_1, const int output_component_axis_2, const int neighbor_index, const int input_component_axis_1, const int input_component_axis_2, const int evaluation_site_local_index=0) const
Underlying function all interface helper functions call to retrieve alpha values.