Skip to content
Snippets Groups Projects
Commit c803c430 authored by Dr. Felix Tobias Schindler's avatar Dr. Felix Tobias Schindler
Browse files

[localevaluation.elliptic] added some explicit specializations

* otherwise the compiler can not select in case of 1d grids
parent d96bc392
No related branches found
No related tags found
No related merge requests found
......@@ -155,17 +155,45 @@ public:
} // ... evaluate< ..., 1, 1 >(...)
/**
* \brief Computes an elliptic evaluation for a matrix-valued local function and matrix-valued basefunctionsets.
* \brief Computes an elliptic evaluation for a 2x2 matrix-valued local function and matrix-valued basefunctionsets.
* \tparam E EntityType
* \tparam D DomainFieldType
* \tparam d dimDomain
* \tparam R RangeFieldType
* \note Unfortunately we need this explicit specialization, otherwise the compiler will complain for 1d grids.
*/
template <class E, class D, int d, class R>
static void evaluate(const Stuff::LocalfunctionInterface<E, D, d, R, d, d>& localFunction,
static void evaluate(const Stuff::LocalfunctionInterface<E, D, d, R, 2, 2>& localFunction,
const Stuff::LocalfunctionSetInterface<E, D, d, R, 1, 1>& testBase,
const Stuff::LocalfunctionSetInterface<E, D, d, R, 1, 1>& ansatzBase,
const Dune::FieldVector<D, d>& localPoint, Dune::DynamicMatrix<R>& ret)
{
evaluate_matrix_valued_(localFunction, testBase, ansatzBase, localPoint, ret);
}
/**
* \brief Computes an elliptic evaluation for a 3x3 matrix-valued local function and matrix-valued basefunctionsets.
* \tparam E EntityType
* \tparam D DomainFieldType
* \tparam d dimDomain
* \tparam R RangeFieldType
* \note Unfortunately we need this explicit specialization, otherwise the compiler will complain for 1d grids.
*/
template <class E, class D, int d, class R>
static void evaluate(const Stuff::LocalfunctionInterface<E, D, d, R, 3, 3>& localFunction,
const Stuff::LocalfunctionSetInterface<E, D, d, R, 1, 1>& testBase,
const Stuff::LocalfunctionSetInterface<E, D, d, R, 1, 1>& ansatzBase,
const Dune::FieldVector<D, d>& localPoint, Dune::DynamicMatrix<R>& ret)
{
evaluate_matrix_valued_(localFunction, testBase, ansatzBase, localPoint, ret);
}
private:
template <class E, class D, int d, class R>
static void evaluate_matrix_valued_(const Stuff::LocalfunctionInterface<E, D, d, R, d, d>& localFunction,
const Stuff::LocalfunctionSetInterface<E, D, d, R, 1, 1>& testBase,
const Stuff::LocalfunctionSetInterface<E, D, d, R, 1, 1>& ansatzBase,
const Dune::FieldVector<D, d>& localPoint, Dune::DynamicMatrix<R>& ret)
{
typedef typename Stuff::LocalfunctionInterface<E, D, d, R, d, d>::RangeType DiffusionRangeType;
typedef typename Stuff::LocalfunctionSetInterface<E, D, d, R, 1, 1>::JacobianRangeType JacobianRangeType;
......@@ -192,9 +220,8 @@ public:
retRow[jj] = product * testGradients[ii][0];
}
}
} // ... evaluate< ..., d, d >(...)
} // ... evaluate_matrix_valued_(...)
private:
const LocalizableFunctionType& inducingFunction_;
}; // class LocalElliptic
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment