Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • extensions/dune-curvedgeometry
1 result
Show changes
Commits on Source (5)
...@@ -19,12 +19,22 @@ list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/modules" ...@@ -19,12 +19,22 @@ list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/modules"
#include the dune macros #include the dune macros
include(DuneMacros) include(DuneMacros)
if (dune-common_VERSION VERSION_GREATER_EQUAL 2.11)
# deactivate global include-directories
dune_policy(SET DP_DEFAULT_INCLUDE_DIRS NEW)
endif()
# start a dune project with information from dune.module # start a dune project with information from dune.module
dune_project() dune_project()
dune_add_library(dunecurvedgeometry INTERFACE dune_add_library(dunecurvedgeometry INTERFACE
EXPORT_NAME CurvedGeometry EXPORT_NAME CurvedGeometry
LINK_LIBRARIES ${DUNE_LIBS}) LINK_LIBRARIES ${DUNE_LIBS})
if (dune-common_VERSION VERSION_GREATER_EQUAL 2.11)
# set include directories for dunecurvedgeometry library
dune_default_include_directories(dunecurvedgeometry INTERFACE)
endif()
add_subdirectory(src) add_subdirectory(src)
add_subdirectory(dune) add_subdirectory(dune)
add_subdirectory(doc) add_subdirectory(doc)
......
...@@ -71,7 +71,7 @@ public: ...@@ -71,7 +71,7 @@ public:
using LocalCoordinate = typename LG::LocalCoordinate; using LocalCoordinate = typename LG::LocalCoordinate;
/// type of global coordinates /// type of global coordinates
using GlobalCoordinate = std::invoke_result_t<LF,typename LG::GlobalCoordinate>; using GlobalCoordinate = decltype(std::declval<LF>()(std::declval<typename LG::GlobalCoordinate>()));
/// coordinate type /// coordinate type
using ctype = typename LocalCoordinate::value_type; using ctype = typename LocalCoordinate::value_type;
......
...@@ -7,11 +7,11 @@ namespace Dune { ...@@ -7,11 +7,11 @@ namespace Dune {
namespace Impl { namespace Impl {
// Placeholder type for a trivial identity matrix without any functionality // Placeholder type for a trivial identity matrix without any functionality
struct IdentityMatrix {}; struct IdentityMatrixTag {};
// multiplication of an identity-matrix with any real matrix // multiplication of an identity-matrix with any real matrix
template <class K, int n, int m> template <class K, int n, int m>
const FieldMatrix<K,n,m>& AB(const IdentityMatrix& A, const FieldMatrix<K,n,m>& B) const FieldMatrix<K,n,m>& AB(const IdentityMatrixTag& A, const FieldMatrix<K,n,m>& B)
{ {
return B; return B;
} }
...@@ -33,7 +33,7 @@ struct DefaultLocalGeometry ...@@ -33,7 +33,7 @@ struct DefaultLocalGeometry
} }
template <class LocalCoordinate> template <class LocalCoordinate>
Impl::IdentityMatrix jacobianTransposed(LocalCoordinate&& local) const Impl::IdentityMatrixTag jacobianTransposed(LocalCoordinate&& local) const
{ {
return {}; return {};
} }
......
...@@ -620,7 +620,7 @@ ParametrizedGeometry (Geo::ReferenceElement<I>, const LFE&, std::vector<GlobalCo ...@@ -620,7 +620,7 @@ ParametrizedGeometry (Geo::ReferenceElement<I>, const LFE&, std::vector<GlobalCo
-> ParametrizedGeometry<LFE, GlobalCoordinate::dimension>; -> ParametrizedGeometry<LFE, GlobalCoordinate::dimension>;
template <class I, class LFE, class F, template <class I, class LFE, class F,
class Range = std::result_of_t<F(Impl::LocalCoordinate_t<LFE>)>> class Range = decltype(std::declval<F>()(std::declval<Impl::LocalCoordinate_t<LFE>>()))>
ParametrizedGeometry (Geo::ReferenceElement<I>, const LFE&, const F&) ParametrizedGeometry (Geo::ReferenceElement<I>, const LFE&, const F&)
-> ParametrizedGeometry<LFE, Range::dimension>; -> ParametrizedGeometry<LFE, Range::dimension>;
...@@ -629,7 +629,7 @@ ParametrizedGeometry (GeometryType, const LFE& localFE, std::vector<GlobalCoordi ...@@ -629,7 +629,7 @@ ParametrizedGeometry (GeometryType, const LFE& localFE, std::vector<GlobalCoordi
-> ParametrizedGeometry<LFE, GlobalCoordinate::dimension>; -> ParametrizedGeometry<LFE, GlobalCoordinate::dimension>;
template <class LFE, class F, template <class LFE, class F,
class Range = std::result_of_t<F(Impl::LocalCoordinate_t<LFE>)>> class Range = decltype(std::declval<F>()(std::declval<Impl::LocalCoordinate_t<LFE>>()))>
ParametrizedGeometry (GeometryType, const LFE&, const F&) ParametrizedGeometry (GeometryType, const LFE&, const F&)
-> ParametrizedGeometry<LFE, Range::dimension>; -> ParametrizedGeometry<LFE, Range::dimension>;
......
# link tests to Dune::CurvedGeometry by default
link_libraries(Dune::CurvedGeometry)
dune_add_test(NAME test-curvedgeometry-double dune_add_test(NAME test-curvedgeometry-double
SOURCES test-curvedgeometry.cc SOURCES test-curvedgeometry.cc
LINK_LIBRARIES ${DUNE_LIBS}
COMPILE_DEFINITIONS USE_FLOAT128=0 COMPILE_DEFINITIONS USE_FLOAT128=0
CMAKE_GUARD dune-localfunctions_FOUND) CMAKE_GUARD dune-localfunctions_FOUND)
dune_add_test(NAME test-curvedgeometry-float128 dune_add_test(NAME test-curvedgeometry-float128
SOURCES test-curvedgeometry.cc SOURCES test-curvedgeometry.cc
LINK_LIBRARIES ${DUNE_LIBS}
COMPILE_DEFINITIONS USE_FLOAT128=1 COMPILE_DEFINITIONS USE_FLOAT128=1
CMAKE_GUARD CMAKE_GUARD
dune-localfunctions_FOUND dune-localfunctions_FOUND
HAVE_QUADMATH) HAVE_QUADMATH)
add_dune_quadmath_flags(test-curvedgeometry-float128)
dune_add_test(NAME test-parametrizedgeometry-double dune_add_test(NAME test-parametrizedgeometry-double
SOURCES test-parametrizedgeometry.cc SOURCES test-parametrizedgeometry.cc
LINK_LIBRARIES ${DUNE_LIBS}
COMPILE_DEFINITIONS USE_FLOAT128=0 COMPILE_DEFINITIONS USE_FLOAT128=0
CMAKE_GUARD dune-localfunctions_FOUND) CMAKE_GUARD dune-localfunctions_FOUND)
dune_add_test(NAME test-parametrizedgeometry-float128 dune_add_test(NAME test-parametrizedgeometry-float128
SOURCES test-parametrizedgeometry.cc SOURCES test-parametrizedgeometry.cc
LINK_LIBRARIES ${DUNE_LIBS}
COMPILE_DEFINITIONS USE_FLOAT128=1 COMPILE_DEFINITIONS USE_FLOAT128=1
CMAKE_GUARD CMAKE_GUARD
dune-localfunctions_FOUND dune-localfunctions_FOUND
HAVE_QUADMATH) HAVE_QUADMATH)
add_dune_quadmath_flags(test-parametrizedgeometry-float128)
dune_add_test(NAME test-localfunctiongeometry-double dune_add_test(NAME test-localfunctiongeometry-double
SOURCES test-localfunctiongeometry.cc SOURCES test-localfunctiongeometry.cc
LINK_LIBRARIES ${DUNE_LIBS}
COMPILE_DEFINITIONS USE_FLOAT128=0) COMPILE_DEFINITIONS USE_FLOAT128=0)
dune_add_test(NAME test-localfunctiongeometry-float128 dune_add_test(NAME test-localfunctiongeometry-float128
SOURCES test-localfunctiongeometry.cc SOURCES test-localfunctiongeometry.cc
LINK_LIBRARIES ${DUNE_LIBS}
COMPILE_DEFINITIONS USE_FLOAT128=1 COMPILE_DEFINITIONS USE_FLOAT128=1
CMAKE_GUARD HAVE_QUADMATH) CMAKE_GUARD HAVE_QUADMATH)
add_dune_quadmath_flags(test-localfunctiongeometry-float128)
dune_add_test(SOURCES test-globalparametrization.cc dune_add_test(SOURCES test-globalparametrization.cc
LINK_LIBRARIES ${DUNE_LIBS}
CMAKE_GUARD dune-localfunctions_FOUND) CMAKE_GUARD dune-localfunctions_FOUND)
...@@ -47,7 +47,7 @@ public: ...@@ -47,7 +47,7 @@ public:
using Domain = typename Geometry::GlobalCoordinate; using Domain = typename Geometry::GlobalCoordinate;
using LocalDomain = typename Geometry::LocalCoordinate; using LocalDomain = typename Geometry::LocalCoordinate;
using Range = std::result_of_t<Functor(Domain)>; using Range = decltype(std::declval<Functor>()(std::declval<Domain>()));
using Signature = Range(LocalDomain); using Signature = Range(LocalDomain);
public: public:
......
dune_add_test(SOURCES test-lfecache.cc dune_add_test(SOURCES test-lfecache.cc
LINK_LIBRARIES ${DUNE_LIBS} LINK_LIBRARIES Dune::CurvedGeometry
CMAKE_GUARD dune-localfunctions_FOUND) CMAKE_GUARD dune-localfunctions_FOUND)
\ No newline at end of file