Hermitebasistest: function derivative Range has wrong type
When investigating a failing pipeline in core/dune-common!1401 (see, e.g., https://gitlab.dune-project.org/infrastructure/dune-nightly-test/-/jobs/599575) I noticed that for some reason in the hermitbasistest a differentiable function is created that returns a FieldVector<double,1>
but the Range
type of the corresponding DifferentiableFunctionFromCallables
is set to FieldMatrix<double, 1,1>
. I guess, somewhere along the way the DefaultDerivativeTraits
transform a "scalar" return type that is given as a FieldVector<double,1>
into a FieldMatrix<double,1,1>
. The assignment of the one to the other actually should not be valid, but for some reason it is working with the current implementation in dune-common.
It is very hard to track why the Range
is defined as FieldMatrix<double,1,1>
at all. This seems only to happen in the OneDGrid case.
In order to provoke the error, you could try out the dune-common branch issue/fieldvector-1-constructors-2
with the current dune-function HEAD. By changing the implementation of the DenseMatrixAssigner
default template specializations, I could make it compile again, but I think, this might be a bug on the dune-functions side.