diff --git a/dune/tectonic/globallaursennonlinearity.hh b/dune/tectonic/globallaursennonlinearity.hh
index 4bf9dd87bc5bf5ff6a0abfe6ff4161403daf29ca..84e13def8eb777273f72f50d7b1ccef74600c3b6 100644
--- a/dune/tectonic/globallaursennonlinearity.hh
+++ b/dune/tectonic/globallaursennonlinearity.hh
@@ -13,10 +13,12 @@
 #include "nicefunction.hh"
 
 namespace Dune {
-template <int dim, class OuterFunctionType, class VectorType, class MatrixType>
+template <int dimZ, class OuterFunctionType, class VectorType, class MatrixType>
 class GlobalLaursenNonlinearity
-    : public GlobalNonlinearity<dim, VectorType, MatrixType> {
+    : public GlobalNonlinearity<dimZ, VectorType, MatrixType> {
 public:
+  using GlobalNonlinearity<dimZ, VectorType, MatrixType>::dim;
+
   GlobalLaursenNonlinearity(
       shared_ptr<BlockVector<FieldVector<double, 1>> const> mu,
       shared_ptr<BlockVector<FieldVector<double, 1>> const> normalStress,
diff --git a/dune/tectonic/globalnonlinearity.hh b/dune/tectonic/globalnonlinearity.hh
index 61f5c7447c9e0029f266b51997ff8a2cfa1ea936..64e3178cd649a4da7337b953709feeab72b2a1f2 100644
--- a/dune/tectonic/globalnonlinearity.hh
+++ b/dune/tectonic/globalnonlinearity.hh
@@ -12,11 +12,12 @@
 #include "localnonlinearity.hh"
 
 namespace Dune {
-template <int dim, class VectorTypeTEMPLATE, class MatrixTypeTEMPLATE>
+template <int dimX, class VectorTypeTEMPLATE, class MatrixTypeTEMPLATE>
 class GlobalNonlinearity {
 public:
   typedef VectorTypeTEMPLATE VectorType;
   typedef MatrixTypeTEMPLATE MatrixType;
+  int static const dim = VectorTypeTEMPLATE::block_type::dimension;
 
   double operator()(VectorType const &x) const {
     double tmp = 0;
diff --git a/dune/tectonic/globalruinanonlinearity.hh b/dune/tectonic/globalruinanonlinearity.hh
index c3643cf12265d682d1e6d798b185fe0bd3324d56..c42298129358399e35b07818942b573955beb54c 100644
--- a/dune/tectonic/globalruinanonlinearity.hh
+++ b/dune/tectonic/globalruinanonlinearity.hh
@@ -14,10 +14,12 @@
 #include "nicefunction.hh"
 
 namespace Dune {
-template <int dim, class VectorType, class MatrixType>
+template <int dimX, class VectorType, class MatrixType>
 class GlobalRuinaNonlinearity
-    : public GlobalNonlinearity<dim, VectorType, MatrixType> {
+    : public GlobalNonlinearity<dimX, VectorType, MatrixType> {
 public:
+  using GlobalNonlinearity<dimX, VectorType, MatrixType>::dim;
+
   GlobalRuinaNonlinearity(
       shared_ptr<BlockVector<FieldVector<double, 1>> const> nodalIntegrals,
       shared_ptr<BlockVector<FieldVector<double, 1>> const> a,