12 template <
typename coeff_type>
20 template <
typename coeff_type>
30 template <
typename coeff_type>
35 const typename traits_type::cloner_type& cloner)
41 template <
typename coeff_type>
49 template <
typename coeff_type>
55 template <
typename coeff_type>
67 template <
typename coeff_type>
73 const typename traits_type::cloner_type& cloner)
79 template <
typename coeff_type>
88 template <
typename coeff_type>
97 theTerm[dimension] = order;
99 return *(this->coeff_[this->map_->LID(index)]);
102 template <
typename coeff_type>
111 theTerm[dimension] = order;
113 return *(this->coeff_[this->map_->LID(index)]);
116 template <
typename coeff_type>
127 template <
typename coeff_type>
133 const coeff_type& vec)
138 i_gid = this->map_->GID(i);
140 weight*basis_values[i_gid]/basis_norms[i_gid],
145 template <
typename coeff_type>
151 os <<
"Stokhos::VectorOrthogPoly of global size "
152 << this->map_->NumGlobalElements() <<
", local size " << sz <<
" in basis "
153 <<
"\n" << basis_->getName() <<
":" << std::endl;
161 os <<
"Term " << i <<
" (";
163 os << trm[
j] <<
", ";
164 os << trm[trm.
size()-1] <<
"):" << std::endl;
165 traits_type::print(os, *(this->coeff_[this->map_->LID(i)]));
170 os <<
"Term " << this->map_->GID(i) <<
":" << std::endl;
171 traits_type::print(os, *(this->coeff_[i]));
ProductContainer< coeff_type >::ordinal_type ordinal_type
Typename of ordinals.
virtual ~VectorOrthogPoly()
Destructor.
void sumIntoAllTerms(const value_type &weight, const Teuchos::Array< value_type > &basis_values, const Teuchos::Array< value_type > &basis_norms, const coeff_type &vec)
Evaluate polynomial at supplied basis values.
ProductContainer & operator=(const ProductContainer &)
Assignment.
ordinal_type size() const
Size.
VectorOrthogPoly()
Constructor with no basis.
std::ostream & print(std::ostream &os) const
Print polynomial.
VectorOrthogPoly & operator=(const VectorOrthogPoly &)
Assignment.
Abstract base class for multivariate orthogonal polynomials.
void reset(const Teuchos::RCP< const Epetra_BlockMap > &map)
Resize to new map map.
Abstract base class for multivariate orthogonal polynomials generated from tensor products of univari...
Teuchos::RCP< const Stokhos::OrthogPolyBasis< ordinal_type, value_type > > basis_
Basis.
A product (in the mathematical sense) container class whose coefficients are vectors, operators, or in general any type that would have an expensive copy constructor.
A container class storing an orthogonal polynomial whose coefficients are vectors, operators, or in general any type that would have an expensive copy constructor.
void evaluate(const Teuchos::Array< value_type > &basis_values, coeff_type &result) const
Evaluate polynomial at supplied basis values.
Teuchos::RCP< const Stokhos::OrthogPolyBasis< ordinal_type, value_type > > basis() const
Get basis.
void reset(const Teuchos::RCP< const Stokhos::OrthogPolyBasis< ordinal_type, value_type > > &new_basis, const Teuchos::RCP< const Epetra_BlockMap > &new_map, const typename traits_type::cloner_type &cloner)
Reset to a new basis.
coeff_type & term(ordinal_type dimension, ordinal_type order)
Get term for dimension dimension and order order.
void update(const ValueType &alpha, VectorType &x, const ValueType &beta, const VectorType &y)
ProductContainer< coeff_type >::value_type value_type
Typename of values.