diff --git a/scripts/get_pdfs.sh b/scripts/get_pdfs.sh
index 9dd954d2dc562fa3e986c49b75dbc5a2bc5fd495..6b6a15d380d466795f78dc768bac006ff94633d0 100755
--- a/scripts/get_pdfs.sh
+++ b/scripts/get_pdfs.sh
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 
-export URL="http://sftp.km3net.de/data/latest/"
+export URL="https://sftp.km3net.de/data/v17.0.0/"
 if [ ! -d "pdfs" ]; then
     echo "Retrieving PDFs..."
     mkdir pdfs
diff --git a/src/jpp/JLang/JSTDTypes.hh b/src/jpp/JLang/JSTDTypes.hh
index 9811aaa54158f2b6af534c50ce3a8c71e728a2e7..e29dc2ce0b750789dcfbd95186c541b57bbb4827 100644
--- a/src/jpp/JLang/JSTDTypes.hh
+++ b/src/jpp/JLang/JSTDTypes.hh
@@ -8,22 +8,30 @@
  * \author mdejong
  */
 
-namespace std {
-  template<class JElement_t, class JAllocator_t>                                    class vector;
-  template<class JElement_t, class JComparator_t, class JAllocator_t>               class set;
-  template<class JElement_t, class JComparator_t, class JAllocator_t>               class multiset;
-  template<class JFirst_t, class JSecond_t>                                         class pair;
-  template<class JKey_t, class JValue_t, class JComparator_t, class JAllocator_t>   class map;
-  template<class JKey_t, class JValue_t, class JComparator_t, class JAllocator_t>   class multimap;
-  template<class Category, class T, class Distance, class Pointer, class Reference> struct iterator;
-#ifdef _GLIBCXX_USE_CXX11_ABI
-  inline namespace __cxx11 {
-    template<class JElement_t, class JAllocator_t>                                  class list;
-  }
-#else
-  template<class JElement_t, class JAllocator_t>                                    class list;
-#endif 
-}
+#include <vector>
+#include <set>
+#include <utility>
+#include <map>
+#include <list>
+#include <iterator>
+
+// TODO: this gives an ambigous error on macOS with std::pair
+// namespace std {
+//   template<class JElement_t, class JAllocator_t>                                    class vector;
+//   template<class JElement_t, class JComparator_t, class JAllocator_t>               class set;
+//   template<class JElement_t, class JComparator_t, class JAllocator_t>               class multiset;
+//   template<class JFirst_t, class JSecond_t>                                         struct pair;
+//   template<class JKey_t, class JValue_t, class JComparator_t, class JAllocator_t>   class map;
+//   template<class JKey_t, class JValue_t, class JComparator_t, class JAllocator_t>   class multimap;
+//   template<class Category, class T, class Distance, class Pointer, class Reference> struct iterator;
+// #ifdef _GLIBCXX_USE_CXX11_ABI
+//   inline namespace __cxx11 {
+//     template<class JElement_t, class JAllocator_t>                                  class list;
+//   }
+// #else
+//   template<class JElement_t, class JAllocator_t>                                    class list;
+// #endif
+// }
 
 #endif
 
diff --git a/src/jpp/JMath/JMath.hh b/src/jpp/JMath/JMath.hh
index 8c37cc9352a45599cdde9f9002afbd5c8d917087..7221e2298d843646b4471648a21a51fa3eb5393f 100644
--- a/src/jpp/JMath/JMath.hh
+++ b/src/jpp/JMath/JMath.hh
@@ -32,7 +32,7 @@ namespace JMATH {
   
   
   /**
-   * Power \f$x^y\f$.
+   * Power \f$ x^{y} \f$.
    *
    * \param  x              value
    * \param  y              power
@@ -54,7 +54,7 @@ namespace JMATH {
 
   private:
     /**
-     * Power \f$x^y\f$.
+     * Power \f$ x^{y} \f$.
      * This method corresponds to primitive data types.
      *
      * \param  x              value
@@ -70,8 +70,8 @@ namespace JMATH {
 
 
     /**
-     * Power \f$x^y\f$.
-     * Power.
+     * Power \f$ x^{y} \f$.
+     *
      * This method corresponds to non-primitive data types.
      *
      * \param  x              value
@@ -88,7 +88,7 @@ namespace JMATH {
 
 
   /**
-   * Power \f$x^y\f$.
+   * Power \f$ x^{y} \f$.
    *
    * \param  x              value
    * \param  y              power
@@ -296,7 +296,7 @@ namespace JMATH {
      */
     friend T& operator*=(T& first, const T& second)
     {
-      return first.mul(second);
+      return static_cast<JMath<T>&>(first).mul(second);
     }
 
     
@@ -483,7 +483,7 @@ namespace JMATH {
    * Template definition so that compiler error is generated if implementation is missing (see JEigen3D.hh).
    */
   template<>
-  class JAverage<JGEOMETRY3D::JQuaternion3D>;
+  struct JAverage<JGEOMETRY3D::JQuaternion3D>;
 
 
   /**
diff --git a/tests/test_pdf.py b/tests/test_pdf.py
index 6936c8cfd6898e516efdf1f0e706920250fa4a94..0a748382f18d6b75a36e53084c314a34cea1c275 100644
--- a/tests/test_pdf.py
+++ b/tests/test_pdf.py
@@ -7,16 +7,16 @@ class TestMuonPDF(unittest.TestCase):
     def test_pdf(self):
         muon_pdf = jppy.pdf.JMuonPDF(PDFS, 0)
         result = muon_pdf.calculate(10, 5, 0, 0, 23)
-        self.assertAlmostEqual(0.001545692, result.f)
-        self.assertAlmostEqual(-1.220889709e-05, result.fp)
-        self.assertAlmostEqual(0.022764524, result.v)
-        self.assertAlmostEqual(0.115814468, result.V)
+        self.assertAlmostEqual(0.00067762789, result.f)
+        self.assertAlmostEqual(-1.9661888268460384e-05, result.fp)
+        self.assertAlmostEqual(0.01374949305, result.v)
+        self.assertAlmostEqual(0.053314508, result.V)
 
 class TestShowerPDF(unittest.TestCase):
     def test_pdf(self):
         shower_pdf = jppy.pdf.JShowerPDF(PDFS, 0)
         result = shower_pdf.calculate(100, 10, 0.1, 0.2, 0.3, 6)
-        self.assertAlmostEqual(0.001383343, result.f)
-        self.assertAlmostEqual(5.091930537e-05, result.fp)
-        self.assertAlmostEqual(0.010475308, result.v)
-        self.assertAlmostEqual(0.149635554, result.V)
+        self.assertAlmostEqual(0.0013937540, result.f)
+        self.assertAlmostEqual(5.1614638414144165e-05, result.fp)
+        self.assertAlmostEqual(0.01054815545, result.v)
+        self.assertAlmostEqual(0.150554603, result.V)
diff --git a/tests/test_pdf_evaluator.py b/tests/test_pdf_evaluator.py
index 42bd0619d87cb1468c07ad0e912529781f8aece2..a50fa48f41272090e3930a7a912775ae7ed36427 100644
--- a/tests/test_pdf_evaluator.py
+++ b/tests/test_pdf_evaluator.py
@@ -8,20 +8,17 @@ class TestMuonPDFEvaluator(unittest.TestCase):
         E, t0, t_obs, D, cd, theta, phi = [1e3, 56, 292, 50, 0.7, 1.57, 3.14]
         muon_pdf = jppy.pdf_evaluator.MuonPDF(PDFS, E, t0)
         result = muon_pdf.evaluate(D, cd, theta, phi, t_obs)
-        self.assertAlmostEqual( 0.003644475, result.f)
-        self.assertAlmostEqual(-0.000715558, result.fp)
-        self.assertAlmostEqual( 0.033748905, result.v)
-        self.assertAlmostEqual( 0.097171157, result.V)
+        self.assertAlmostEqual( 0.00388579021, result.f)
+        self.assertAlmostEqual(-0.000739757, result.fp)
+        self.assertAlmostEqual(0.035047945, result.v)
+        self.assertAlmostEqual(0.09606971431, result.V)
 
 class TestShowerPDFEvaluator(unittest.TestCase):
     def test_pdf_evaluator(self):
         E, t0, t_obs, D, cd, theta, phi = [50, 198, 226, 5, 0.6, 0.5, 0.4]
         shower_pdf = jppy.pdf_evaluator.ShowerPDF(PDFS, E, t0)
         result = shower_pdf.evaluate(D, cd, theta, phi, t_obs)
-        self.assertAlmostEqual(0.006204617, result.f)
-        self.assertAlmostEqual(0.000641669, result.fp)
-        self.assertAlmostEqual(0.013960066, result.v)
-        self.assertAlmostEqual(0.296589983, result.V)
-
-
-    
+        self.assertAlmostEqual(0.006247665, result.f)
+        self.assertAlmostEqual(0.0006429129, result.fp)
+        self.assertAlmostEqual(0.01406847423, result.v)
+        self.assertAlmostEqual(0.297769976, result.V)