Skip to content
Snippets Groups Projects
Commit 4d859e3d authored by Max Kahnt's avatar Max Kahnt
Browse files

Provide FieldTraits that are missing in the core modules.

parent 64434c48
No related branches found
No related tags found
1 merge request!5Feature/organize traits
#install headers #install headers
install(FILES install(FILES
scalartraits.hh fieldtraits.hh
matrixtraits.hh matrixtraits.hh
vectortraits.hh scalartraits.hh
utilities.hh utilities.hh
vectortraits.hh
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dune/matrix-vector/traits) DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dune/matrix-vector/traits)
#ifndef DUNE_MATRIX_VECTOR_TRAITS_FIELDTRAITS_HH
#define DUNE_MATRIX_VECTOR_TRAITS_FIELDTRAITS_HH
#include <dune/common/typetraits.hh>
#include <dune/istl/scaledidmatrix.hh>
/**
* \file
* Add FieldTraits that are not in the core modules.
*/
namespace Dune {
template <class K, int n>
struct FieldTraits<ScaledIdentityMatrix<K, n>> {
using field_type = field_t<K>;
using real_type = real_t<K>;
};
} // end namespace Dune
#endif // DUNE_MATRIX_VECTOR_TRAITS_FIELDTRAITS_HH
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment