11 #ifndef PANZER_TENSOR_TO_STD_VECTOR_IMPL_HPP
12 #define PANZER_TENSOR_TO_STD_VECTOR_IMPL_HPP
19 template<
typename EvalT,
typename Traits>
30 const std::vector<std::string>& vector_names =
33 vector_fields.resize(vector_names.size());
34 for (std::size_t i=0; i < vector_names.size(); ++i)
40 (
"Tensor Name"), tensor_dl);
42 this->addDependentField(tensor_field);
44 for (std::size_t i=0; i < vector_fields.size(); ++i)
45 this->addEvaluatedField(vector_fields[i]);
47 std::string n =
"TensorToStdVector: " + tensor_field.fieldTag().name();
52 template<
typename EvalT,
typename Traits>
62 for (index_t cell = 0; cell < workset.
num_cells; ++cell) {
65 for (size_type pt = 0; pt < tensor_field.extent(1); ++pt) {
68 for (std::size_t vec = 0; vec < vector_fields.size(); ++vec) {
71 for (std::size_t dim = 0; dim < tensor_field.extent(2); ++dim) {
73 vector_fields[vec](cell,pt,dim) = tensor_field(cell,pt,vec,dim);
int num_cells
DEPRECATED - use: numCells()
T & get(const std::string &name, T def_value)
TensorToStdVector(const Teuchos::ParameterList &p)
void evaluateFields(typename Traits::EvalData d)