42 #ifndef STOKHOS_KL_PRODUCT_EIGENPAIR_HPP
43 #define STOKHOS_KL_PRODUCT_EIGENPAIR_HPP
52 template <
typename eigen_function_type,
typename ExecutionSpace>
87 for (std::size_t i=0; i<sz; i++)
92 template <
typename po
int_type>
93 KOKKOS_INLINE_FUNCTION
97 for (std::size_t i=0; i<sz; i++)
98 result *=
eig_pairs[i].eig_func.evaluate(x[i]);
103 void print(std::ostream& os)
const {
106 for (std::size_t i=0; i<sz-1; i++) {
117 template <
typename E,
typename D>
119 operator << (std::ostream& os, const ProductEigenPair<E,D>&
f) {
125 template <
typename E,
typename D>
127 public std::binary_function<ProductEigenPair<E,D>,
128 ProductEigenPair<E,D>,
140 #endif // STOKHOS_KL_PRODUCT_EIGENPAIR_HPP
Container for multi-dimensional product of 1-D eigenfunctions/values.
ProductEigenPair()
Default constructor.
eig_pair_type eig_pairs
Eigenpairs for each dimension.
Container for one-dimensional eigenfunction and eigenvalue.
void set(const Teuchos::Array< one_d_eigen_pair_type > &ep)
Set eigen pairs.
Teuchos::Array< one_d_eigen_pair_type > eig_pair_type
bool operator()(const ProductEigenPair< E, D > &a, const ProductEigenPair< E, D > &b)
KOKKOS_INLINE_FUNCTION value_type evalEigenfunction(const point_type &x) const
Evaluate eigenfunction at a given point.
OneDEigenPair< eigen_function_type > one_d_eigen_pair_type
void print(std::ostream &os) const
Print eigenpair.
ExecutionSpace execution_space
ProductEigenPair & operator=(const ProductEigenPair &ep)
Assignment.
Predicate class for sorting product eigenfunctions based on eigenvalue.
ScalarType f(const Teuchos::Array< ScalarType > &x, double a, double b)
eigen_function_type::value_type value_type
ProductEigenPair(const ProductEigenPair &ep)
Copy constructor.
value_type eig_val
Product eigenvalue.