gnu: livemedia-utils: Update to 2019.03.06.
[jackhill/guix/guix.git] / gnu / packages / maths.scm
index 66d6063..cc7459f 100644 (file)
@@ -2,13 +2,13 @@
 ;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
 ;;; Copyright © 2014, 2016, 2017 John Darrington <jmd@gnu.org>
-;;; Copyright © 2014, 2015, 2016, 2017, 2018 Eric Bavier <bavier@member.fsf.org>
+;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Eric Bavier <bavier@member.fsf.org>
 ;;; Copyright © 2014 Federico Beffa <beffa@fbengineering.ch>
 ;;; Copyright © 2014 Mathieu Lirzin <mathieu.lirzin@openmailbox.org>
 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
 ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
 ;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
-;;; Copyright © 2015, 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2015, 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2015 Fabian Harfert <fhmgufs@web.de>
 ;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
 ;;; Copyright © 2016, 2018 Kei Kebreau <kkebreau@posteo.net>
 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2016, 2017 Thomas Danckaert <post@thomasdanckaert.be>
 ;;; Copyright © 2017, 2018 Paul Garlick <pgarlick@tourbillion-technology.com>
-;;; Copyright © 2017 Nils Gillmann <ng0@n0.is>
+;;; Copyright © 2017 ng0 <ng0@n0.is>
 ;;; Copyright © 2017 Ben Woodcroft <donttrustben@gmail.com>
 ;;; Copyright © 2017 Theodoros Foradis <theodoros@foradis.org>
 ;;; Copyright © 2017, 2019 Arun Isaac <arunisaac@systemreboot.net>
-;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
+;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;; Copyright © 2017 Dave Love <me@fx@gnu.org>
 ;;; Copyright © 2018 Jan Nieuwenhuizen <janneke@gnu.org>
 ;;; Copyright © 2018 Joshua Sierles, Nextjournal <joshua@nextjournal.com>
@@ -148,19 +148,19 @@ beginners.")
 (define-public c-graph
   (package
    (name "c-graph")
-   (version "2.0")
+   (version "2.0.1")
    (source (origin
             (method url-fetch)
             (uri (string-append "mirror://gnu/c-graph/c-graph-" version
                                 ".tar.gz"))
             (sha256 (base32
-                     "1hlvpzrh7hzzf533diyfiabzskddi8zx92av9hwkjw3l46z7qv01"))))
+                     "092412jzxy6wdvpk96pfj499hpmaww8xllavbvlqspfpr7ips9id"))))
    (build-system gnu-build-system)
    (inputs
-     `(("fortran" ,gfortran)))
+    `(("fortran" ,gfortran)))
    (synopsis "Visualizing and demonstrating convolution")
    (description
-     "GNU C-Graph is a tool for demonstrating the theory of convolution.
+    "GNU C-Graph is a tool for demonstrating the theory of convolution.
 Thus, it can serve as an excellent aid to students of signal and systems
 theory in visualizing the convolution process.  Rather than forcing the
 student to write code, the program offers an intuitive interface with
@@ -428,15 +428,17 @@ LP/MIP solver is included in the package.")
 (define-public 4ti2
   (package
     (name "4ti2")
-    (version "1.6.7")
+    (version "1.6.9")
     (source
      (origin
-      (method url-fetch)
-      (uri (string-append "http://www.4ti2.de/version_" version
-                          "/4ti2-" version ".tar.gz"))
-      (sha256
-       (base32
-        "1frix3rnm9ffr93alqzw4cavxbfpf524l8rfbmcpyhwd3n1km0yl"))))
+       (method url-fetch)
+       (uri (string-append "https://github.com/4ti2/4ti2/releases/download/"
+                           "Release_"
+                           (string-map (lambda (c) (if (char=? c #\.) #\_ c))
+                                       version)
+                           "/4ti2-" version ".tar.gz"))
+       (sha256
+        (base32 "0rj92x6p9m3la5gasjbj7sa569im527ffmka5y2sv1amgd3fflrh"))))
     (build-system gnu-build-system)
     (native-inputs
      `(("which" ,(@ (gnu packages base) which)))) ; for the tests
@@ -584,7 +586,8 @@ problems in numerical linear algebra.")
                            version ".tgz"))
        (sha256
         (base32
-         "0p1r61ss1fq0bs8ynnx7xq4wwsdvs32ljvwjnx6yxr8gd6pawx0c"))))
+         "0p1r61ss1fq0bs8ynnx7xq4wwsdvs32ljvwjnx6yxr8gd6pawx0c"))
+       (patches (search-patches "scalapack-blacs-mpi-deprecations.patch"))))
     (build-system cmake-build-system)
     (inputs
      `(("mpi" ,openmpi)
@@ -608,15 +611,14 @@ singular value problems.")
 (define-public gnuplot
   (package
     (name "gnuplot")
-    (version "5.2.4")
+    (version "5.2.6")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://sourceforge/gnuplot/gnuplot/"
                                   version "/gnuplot-"
                                   version ".tar.gz"))
        (sha256
-        (base32
-         "1jvh8xmd2cvrhlsg88kxwh55wkwx31sg50v1n59slfippl0g058m"))))
+        (base32 "1vllgap08nhvdmc03idmkdnk9cfl2bp81hps50q1pqrr640qzp9m"))))
     (build-system gnu-build-system)
     (inputs `(("readline" ,readline)
               ("cairo" ,cairo)
@@ -749,7 +751,7 @@ incompatible with HDF5.")
 (define-public hdf5
   (package
     (name "hdf5")
-    (version "1.8.19")
+    (version "1.8.21")
     (source
      (origin
       (method url-fetch)
@@ -759,12 +761,14 @@ incompatible with HDF5.")
                                 version ".tar.bz2")
                  (string-append "https://support.hdfgroup.org/ftp/HDF5/"
                                 "current"
-                                (apply string-append
-                                       (take (string-split version #\.) 2))
+                                (match (string-split version #\.)
+                                  ((major minor _ ...)
+                                   (string-append major minor)))
                                 "/src/hdf5-" version ".tar.bz2")))
       (sha256
-       (base32 "0f3jfbqpaaq21ighi40qzs52nb52kc2d2yjk541rjmsx20b3ih2r"))
-      (patches (list (search-patch "hdf5-config-date.patch")))))
+       (base32 "03glk4w4wyb1jyb443g53y3y1ncnf6mj2cqwm6avfr2awkgb3cg5"))
+      (patches (search-patches "hdf5-config-date.patch"
+                               "hdf5-1.8-mpi-deprecations.patch"))))
     (build-system gnu-build-system)
     (inputs
      `(("zlib" ,zlib)))
@@ -877,125 +881,135 @@ extremely large and complex data collections.")
                                 "/src/hdf5-" version ".tar.bz2")))
       (sha256
        (base32 "1pr85fa1sh2ky6ai2hs3f21lp252grl2cq3wbyi4rh7dm83gyrqj"))
-      (patches (list (search-patch "hdf5-config-date.patch")))))))
+      (patches (search-patches "hdf5-config-date.patch"
+                               "hdf5-mpi-deprecations.patch"))))))
 
 (define-public hdf-java
   (package
-   (name "hdf-java")
-   (version "3.3.2")
-   (source
-    (origin
-      (method url-fetch)
-      (uri (string-append
-            "http://www.hdfgroup.org/ftp/HDF5/releases/HDF-JAVA/hdfjni-"
-            version "/src/CMake-hdfjava-" version ".tar.gz"))
-      (sha256
-       (base32 "0m1gp2aspcblqzmpqbdpfp6giskws85ds6p5gz8sx7asyp7wznpr"))
-      (modules '((guix build utils)))
-      (snippet ; Make sure we don't use the bundled sources and binaries.
-       `(begin
-          (for-each delete-file
-                    (list "SZip.tar.gz" "ZLib.tar.gz" "JPEG8d.tar.gz"
-                          "HDF4.tar.gz" "HDF5.tar.gz"))
-          (delete-file-recursively ,(string-append "hdfjava-" version "/lib"))
-          #t))))
-   (build-system gnu-build-system)
-   (native-inputs
-    `(("jdk" ,icedtea "jdk")
-      ("automake" ,automake) ; For up to date 'config.guess' and 'config.sub'.
-      ;; For tests:
-      ("hamcrest-core" ,java-hamcrest-core)
-      ("junit" ,java-junit)
-      ("slf4j-simple" ,java-slf4j-simple)))
-   (inputs
-    `(("hdf4" ,hdf4)
-      ("hdf5" ,hdf5)
-      ("zlib" ,zlib)
-      ("libjpeg" ,libjpeg)
-      ("slf4j-api" ,java-slf4j-api)))
-   (arguments
-    `(#:configure-flags
-      (list (string-append "--target=" ,(or (%current-target-system) (%current-system)))
-            (string-append "--with-jdk=" (assoc-ref %build-inputs "jdk") "/include,"
-                           (assoc-ref %build-inputs "jdk") "/lib" )
-            (string-append "--with-hdf4=" (assoc-ref %build-inputs "hdf4") "/lib")
-            (string-append "--with-hdf5=" (assoc-ref %build-inputs "hdf5") "/lib"))
-
-      #:make-flags
-      (list (string-append "HDFLIB=" (assoc-ref %build-inputs "hdf4") "/lib")
-            (string-append "HDF5LIB=" (assoc-ref %build-inputs "hdf5") "/lib")
-            (string-append "ZLIB=" (assoc-ref %build-inputs "zlib") "/lib/libz.so")
-            (string-append "JPEGLIB="
-                           (assoc-ref %build-inputs "libjpeg") "/lib/libjpeg.so")
-            "LLEXT=so")
-
-      #:phases
-      (modify-phases %standard-phases
-        (add-before 'configure 'chdir-to-source
-          (lambda _ (chdir ,(string-append "hdfjava-" version))))
-        (add-before 'configure 'patch-build
-          (lambda* (#:key inputs outputs #:allow-other-keys)
-            (substitute* "configure"
-              (("COPT=\"") "COPT=\"-O2 ") ; CFLAGS is ignored in Makefiles
-              (("/bin/cat") (which "cat")))
-            ;; Set classpath for compilation
-            (substitute* '("hdf/hdf5lib/Makefile.in"
-                           "hdf/hdf5lib/exceptions/Makefile.in"
-                           "hdf/hdflib/Makefile.in")
-              (("\\$\\(TOP\\)/lib/slf4j-api-1\\.7\\.5\\.jar")
-               (string-append (assoc-ref inputs "slf4j-api")
-                              "/share/java/slf4j-api.jar")))
-            ;; Replace outdated config.sub and config.guess:
-            (with-directory-excursion "config"
-              (for-each (lambda (file)
-                          (copy-file
-                           (string-append (assoc-ref inputs "automake")
-                                          "/share/automake-1.15/" file) file))
-                        '("config.sub" "config.guess")))
-            (mkdir-p (string-append (assoc-ref outputs "out")))
-            ;; Set classpath for tests
-            (let* ((build-dir (getcwd))
-                   (lib (string-append build-dir "/lib"))
-                   (jhdf (string-append lib "/jhdf.jar"))
-                   (jhdf5 (string-append lib "/jhdf5.jar"))
-                   (testjars
-                    (map (lambda (i)
-                           (string-append (assoc-ref inputs i)
-                                          "/share/java/" i ".jar"))
-                         '("junit" "hamcrest-core" "slf4j-api" "slf4j-simple")))
-                   (class-path
-                    (string-join `("." ,build-dir ,jhdf ,jhdf5 ,@testjars) ":")))
-
-              (substitute* '("test/hdf5lib/Makefile.in"
-                             "test/hdf5lib/junit.sh.in"
-                             "examples/runExample.sh.in")
-                (("/usr/bin/test")
-                 (string-append (assoc-ref inputs "coreutils")
-                                "/bin/test"))
-                (("/usr/bin/uname")
-                 (string-append (assoc-ref inputs "coreutils")
-                                "/bin/uname"))
-                (("CLASSPATH=[^\n]*")
-                 (string-append "CLASSPATH=" class-path)))
-              (setenv "CLASSPATH" class-path))
-            #t))
-        (add-before 'check 'build-examples
-          (lambda _
-            (zero? (apply system* `("javac"
-                                    ,@(find-files "examples" ".*\\.java")))))))
+    (name "hdf-java")
+    (version "3.3.2")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "http://www.hdfgroup.org/ftp/HDF5/releases/HDF-JAVA/hdfjni-"
+             version "/src/CMake-hdfjava-" version ".tar.gz"))
+       (sha256
+        (base32 "0m1gp2aspcblqzmpqbdpfp6giskws85ds6p5gz8sx7asyp7wznpr"))
+       (modules '((guix build utils)))
+       (snippet     ; Make sure we don't use the bundled sources and binaries.
+        `(begin
+           (for-each delete-file
+                     (list "SZip.tar.gz" "ZLib.tar.gz" "JPEG8d.tar.gz"
+                           "HDF4.tar.gz" "HDF5.tar.gz"))
+           (delete-file-recursively ,(string-append "hdfjava-" version "/lib"))
+           #t))))
+    (build-system gnu-build-system)
+    (native-inputs
+     `(("jdk" ,icedtea "jdk")
+       ("automake" ,automake) ; For up to date 'config.guess' and 'config.sub'.
+       ;; For tests:
+       ("hamcrest-core" ,java-hamcrest-core)
+       ("junit" ,java-junit)
+       ("slf4j-simple" ,java-slf4j-simple)))
+    (inputs
+     `(("hdf4" ,hdf4)
+       ("hdf5" ,hdf5)
+       ("zlib" ,zlib)
+       ("libjpeg" ,libjpeg)
+       ("slf4j-api" ,java-slf4j-api)))
+    (arguments
+     `(#:configure-flags
+       (list (string-append "--target=" ,(or (%current-target-system) (%current-system)))
+             (string-append "--with-jdk=" (assoc-ref %build-inputs "jdk") "/include,"
+                            (assoc-ref %build-inputs "jdk") "/lib" )
+             (string-append "--with-hdf4=" (assoc-ref %build-inputs "hdf4") "/lib")
+             (string-append "--with-hdf5=" (assoc-ref %build-inputs "hdf5") "/lib"))
 
-      #:parallel-build? #f
+       #:make-flags
+       (list (string-append "HDFLIB=" (assoc-ref %build-inputs "hdf4") "/lib")
+             (string-append "HDF5LIB=" (assoc-ref %build-inputs "hdf5") "/lib")
+             (string-append "ZLIB=" (assoc-ref %build-inputs "zlib") "/lib/libz.so")
+             (string-append "JPEGLIB="
+                            (assoc-ref %build-inputs "libjpeg") "/lib/libjpeg.so")
+             "LLEXT=so")
+
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'chdir-to-source
+           (lambda _ (chdir ,(string-append "hdfjava-" version)) #t))
+         (add-before 'configure 'patch-build
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (substitute* "configure"
+               (("COPT=\"") "COPT=\"-O2 ") ; CFLAGS is ignored in Makefiles
+               (("/bin/cat") (which "cat")))
+             ;; Set classpath for compilation
+             (substitute* '("hdf/hdf5lib/Makefile.in"
+                            "hdf/hdf5lib/exceptions/Makefile.in"
+                            "hdf/hdflib/Makefile.in")
+               (("\\$\\(TOP\\)/lib/slf4j-api-1\\.7\\.5\\.jar")
+                (string-append (assoc-ref inputs "slf4j-api")
+                               "/share/java/slf4j-api.jar")))
+             ;; Replace outdated config.sub and config.guess:
+             (with-directory-excursion "config"
+               (for-each (lambda (file)
+                           (install-file
+                            (string-append (assoc-ref inputs "automake")
+                                           "/share/automake-"
+                                           ,(version-major+minor (package-version automake))
+                                           "/" file) "."))
+                         '("config.sub" "config.guess")))
+
+             ;; Fix embedded version number
+             (let ((hdf5version (list ,@(string-split (package-version hdf5) #\.))))
+               (substitute* "hdf/hdf5lib/H5.java"
+                 (("1, 8, 19")
+                  (string-join hdf5version ", "))))
+
+             (mkdir-p (string-append (assoc-ref outputs "out")))
+             ;; Set classpath for tests
+             (let* ((build-dir (getcwd))
+                    (lib (string-append build-dir "/lib"))
+                    (jhdf (string-append lib "/jhdf.jar"))
+                    (jhdf5 (string-append lib "/jhdf5.jar"))
+                    (testjars
+                     (map (lambda (i)
+                            (string-append (assoc-ref inputs i)
+                                           "/share/java/" i ".jar"))
+                          '("junit" "hamcrest-core" "slf4j-api" "slf4j-simple")))
+                    (class-path
+                     (string-join `("." ,build-dir ,jhdf ,jhdf5 ,@testjars) ":")))
+
+               (substitute* '("test/hdf5lib/Makefile.in"
+                              "test/hdf5lib/junit.sh.in"
+                              "examples/runExample.sh.in")
+                 (("/usr/bin/test")
+                  (string-append (assoc-ref inputs "coreutils")
+                                 "/bin/test"))
+                 (("/usr/bin/uname")
+                  (string-append (assoc-ref inputs "coreutils")
+                                 "/bin/uname"))
+                 (("CLASSPATH=[^\n]*")
+                  (string-append "CLASSPATH=" class-path)))
+               (setenv "CLASSPATH" class-path))
+             #t))
+         (add-before 'check 'build-examples
+           (lambda _
+             (apply invoke `("javac"
+                             ,@(find-files "examples" ".*\\.java"))))))
+
+       #:parallel-build? #f
 
-      #:parallel-tests? #f ))
-   (home-page "https://support.hdfgroup.org/products/java")
-   (synopsis "Java interface for the HDF4 and HDF5 libraries")
-   (description "Java HDF Interface (JHI) and Java HDF5 Interface (JHI5) use
+       #:parallel-tests? #f ))
+    (home-page "https://support.hdfgroup.org/products/java")
+    (synopsis "Java interface for the HDF4 and HDF5 libraries")
+    (description "Java HDF Interface (JHI) and Java HDF5 Interface (JHI5) use
 the Java Native Interface to wrap the HDF4 and HDF5 libraries, which are
 implemented in C.")
 
-   ;; BSD-style license:
-   (license (license:x11-style
-             "https://support.hdfgroup.org/ftp/HDF5/hdf-java\
+    ;; BSD-style license:
+    (license (license:x11-style
+              "https://support.hdfgroup.org/ftp/HDF5/hdf-java\
 /current/src/unpacked/COPYING"))))
 
 (define-public hdf-eos2
@@ -1292,7 +1306,7 @@ online as well as original implementations of various other algorithms.")
 (define-public ipopt
   (package
     (name "ipopt")
-    (version "3.12.5")
+    (version "3.12.12")
     (source (origin
               (method url-fetch)
               (uri (string-append
@@ -1300,7 +1314,7 @@ online as well as original implementations of various other algorithms.")
                     version".tgz"))
               (sha256
                (base32
-                "09bk2hqy2vgi4yi76xng9zxakddwqy3wij9nx7wf2vfbxxpazrsk"))
+                "07yn9rzdswjk8n246qq6ci9ssf2bcplkifcpsfz9j6cdxw9vgbkv"))
               (modules '((guix build utils)))
               (snippet
                ;; Make sure we don't use the bundled software.
@@ -1391,7 +1405,7 @@ can solve two kinds of problems:
 (define-public octave-cli
   (package
     (name "octave-cli")
-    (version "4.4.1")
+    (version "5.1.0")
     (source
      (origin
       (method url-fetch)
@@ -1399,7 +1413,7 @@ can solve two kinds of problems:
                           version ".tar.lz"))
       (sha256
        (base32
-        "0jsdgizlv02an2ppfjwk5qf209zpwi3317yb7jvlsjzxnir3lvhy"))))
+        "11wwxpy2q1bhxs2v41bqn05i2sb0905cj1xil6mg8l4k2kka4cq6"))))
     (build-system gnu-build-system)
     (inputs
      `(("lapack" ,lapack)
@@ -1632,7 +1646,7 @@ September 2004}")
 (define-public petsc
   (package
     (name "petsc")
-    (version "3.10.2")
+    (version "3.10.4")
     (source
      (origin
       (method url-fetch)
@@ -1640,9 +1654,9 @@ September 2004}")
       (uri (string-append "http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/"
                           "petsc-lite-" version ".tar.gz"))
       (sha256
-       (base32 "0bl64pydak3rblnjffi482r8bin4xim9sb37ksl2jkcxf0i0irsi"))))
-    (outputs '("out"                    ;libraries and headers
-               "examples"))             ;~30MiB of examples
+       (base32 "0fk16944zh3473ra198kdkxdn08rq7b6ap838hxy1mh1i0hb488r"))))
+    (outputs '("out"                    ; libraries and headers
+               "examples"))             ; ~30MiB of examples
     (build-system gnu-build-system)
     (native-inputs
      `(("python" ,python-2)))
@@ -1655,7 +1669,7 @@ September 2004}")
        ))
     (arguments
      `(#:test-target "test"
-       #:parallel-build? #f             ;build is parallel by default
+       #:parallel-build? #f             ; build is parallel by default
        #:configure-flags
        `("--with-mpi=0"
          "--with-openmp=1"
@@ -1791,14 +1805,14 @@ scientific applications modeled by partial differential equations.")
 (define-public python-petsc4py
   (package
     (name "python-petsc4py")
-    (version "3.10.0")
+    (version "3.10.1")
     (source
       (origin
         (method url-fetch)
         (uri (pypi-uri "petsc4py" version))
         (sha256
           (base32
-            "0ch3g6dsvxl7qi984fcssv7cxfbif4bw04gkvxl2l1b8wrmvrm25"))))
+            "094hcnran0r2z1wlvmjswsz3ski1m9kqrl5l0ax8jjhnk55x0flh"))))
     (build-system python-build-system)
     (arguments
      `(#:phases
@@ -2331,7 +2345,8 @@ void mc64ad_dist (int *a, int *b, int *c, int *d, int *e, double *f, int *g,
               "RowPerm = NOROWPERM;"))
            #t))
        (patches (search-patches "superlu-dist-scotchmetis.patch"
-                                "superlu-dist-awpm-grid.patch"))))
+                                "superlu-dist-awpm-grid.patch"
+                                "superlu-dist-fix-mpi-deprecations.patch"))))
     (build-system cmake-build-system)
     (native-inputs
      `(("tcsh" ,tcsh)))
@@ -2691,7 +2706,7 @@ to BMP, JPEG or PNG image formats.")
 (define-public maxima
   (package
     (name "maxima")
-    (version "5.42.1")
+    (version "5.42.2")
     (source
      (origin
        (method url-fetch)
@@ -2699,12 +2714,13 @@ to BMP, JPEG or PNG image formats.")
                            version "-source/" name "-" version ".tar.gz"))
        (sha256
         (base32
-         "1ka0xf70a55ndgmyrq7p5xxbd78pq7bfkqhgxsivaqdw6gn5lmcg"))
+         "0kdncy6137sg3rradirxzj10mkcvafxd892zlclwhr9sa7b12zhn"))
        (patches (search-patches "maxima-defsystem-mkdir.patch"))))
     (build-system gnu-build-system)
     (inputs
      `(("gcl" ,gcl)
        ("gnuplot" ,gnuplot)                       ;for plots
+       ("sed" ,sed)
        ("tk" ,tk)))                               ;Tcl/Tk is used by 'xmaxima'
     (native-inputs
      `(("texinfo" ,texinfo)
@@ -2727,6 +2743,17 @@ to BMP, JPEG or PNG image formats.")
        #:make-flags (list "TMPDIR=/tmp")
        #:phases
        (modify-phases %standard-phases
+         (add-after 'unpack 'patch-paths
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let* ((sed (string-append (assoc-ref inputs "sed") "/bin/sed"))
+                    (coreutils (assoc-ref inputs "coreutils"))
+                    (dirname (string-append coreutils "/bin/dirname"))
+                    (head (string-append coreutils "/bin/head")))
+               (substitute* "src/maxima.in"
+                 (("sed ") (string-append sed " "))
+                 (("dirname") dirname)
+                 (("head") head))
+               #t)))
          (add-before 'check 'pre-check
            (lambda _
              (chmod "src/maxima" #o555)
@@ -2790,7 +2817,7 @@ point numbers.")
 (define-public wxmaxima
   (package
     (name "wxmaxima")
-    (version "18.11.4")
+    (version "19.01.3")
     (source
      (origin
        (method git-fetch)
@@ -2800,7 +2827,7 @@ point numbers.")
        (file-name (git-file-name name version))
        (sha256
         (base32
-         "1sz8n9v23q442l7yjj67pjh0dk78rl4cbcc3j8m1bm88anlfxl9r"))))
+         "1vwahx3zxkn3qlv4z0fm7v8wh0wspvs026alrh7ff7s0c2dcy95x"))))
     (build-system cmake-build-system)
     (native-inputs
      `(("gettext" ,gettext-minimal)))
@@ -2914,7 +2941,7 @@ parts of it.")
 (define-public openblas
   (package
     (name "openblas")
-    (version "0.3.3")
+    (version "0.3.4")
     (source
      (origin
        (method url-fetch)
@@ -2923,7 +2950,7 @@ parts of it.")
        (file-name (string-append name "-" version ".tar.gz"))
        (sha256
         (base32
-         "0cvlixnpc3cdvvn3f30phfvsgnqljqix6wn72ps9rj7xdhvw06jg"))))
+         "1s56lgilyyw86dzmj3jkci9zsg24n60wq4d0zri1hrxlxb6ihimj"))))
     (build-system gnu-build-system)
     (arguments
      `(#:test-target "test"
@@ -3337,7 +3364,7 @@ Failure to do so will result in a library with poor performance.")
 (define-public glm
   (package
     (name "glm")
-    (version "0.9.9.3")
+    (version "0.9.9.4")
     (source
      (origin
        (method url-fetch)
@@ -3345,7 +3372,7 @@ Failure to do so will result in a library with poor performance.")
                            version  "/glm-" version ".zip"))
        (sha256
         (base32
-         "0yqk5r3qh60d4r2iab5q7wq0fryn8p3pz6s28y1i7amqj1aqavj9"))))
+         "17vxbqzy4pxciq5i39bgpxz54f7ifqqmcqwwq7m6xfgikwqqqawp"))))
     (build-system cmake-build-system)
     (native-inputs
      `(("unzip" ,unzip)))
@@ -3430,7 +3457,7 @@ revised simplex and the branch-and-bound methods.")
 (define-public dealii
   (package
     (name "dealii")
-    (version "8.5.1")
+    (version "9.0.1")
     (source
      (origin
        (method url-fetch)
@@ -3438,7 +3465,8 @@ revised simplex and the branch-and-bound methods.")
                            "download/v" version "/dealii-" version ".tar.gz"))
        (sha256
         (base32
-         "1bh9rsmkrg0zi70n27b11djmac9lximghsiy7mg7w7x544n82gnk"))
+         "0r7f8rhl3xr94imd372plizdcbqk0a70w73lwc3vw912dxk0sbyz"))
+       (patches (search-patches "dealii-mpi-deprecations.patch"))
        (modules '((guix build utils)))
        (snippet
         ;; Remove bundled sources: UMFPACK, TBB, muParser, and boost
@@ -3491,10 +3519,8 @@ in finite element programs.")
     (arguments
      (substitute-keyword-arguments (package-arguments dealii)
        ((#:configure-flags cf)
-        ``("-DMPI_C_COMPILER=mpicc"
-           "-DMPI_CXX_COMPILER=mpicxx"
-           "-DMPI_Fortran_COMPILER=mpifort"
-           ,@,cf))
+        `(cons "-DDEAL_II_WITH_MPI:BOOL=ON"
+               ,cf))
        ((#:phases phases '%standard-phases)
         `(modify-phases ,phases
            (add-before 'check 'mpi-setup
@@ -3650,9 +3676,6 @@ set.")
        ("texlive" ,(texlive-union (list texlive-generic-xypic
                                         texlive-fonts-xypic
                                         texlive-latex-hyperref
-                                        texlive-latex-oberdiek
-                                        texlive-generic-ifxetex
-                                        texlive-latex-url
                                         texlive-bibtex)))
        ("ghostscript" ,ghostscript)))
     (inputs
@@ -3957,6 +3980,96 @@ as equations, scalars, vectors, and matrices.")
 theories} (SMT) solver.  It provides a C/C++ API, as well as Python bindings.")
     (license license:expat)))
 
+(define-public elpa
+  (package
+    (name "elpa")
+    (version "2018.11.001")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "http://elpa.mpcdf.mpg.de/html/Releases/"
+                                  version "/elpa-" version ".tar.gz"))
+              (sha256
+               (base32
+                "05hv3v5i6xmziaizw350ff72y1c3k662r85fm3xfdrkclj5zw9yc"))))
+    (build-system gnu-build-system)
+    (native-inputs
+     `(("fortran" ,gfortran)
+       ("perl" ,perl)))                 ;for configure and deps
+    (inputs
+     `(("blas" ,openblas)))
+    (arguments
+     `(#:configure-flags
+       `("--enable-openmp"
+         "--with-mpi=no"
+         ;; ELPA unfortunately does not support runtime dispatch, so we can
+         ;; only enable the "generic" kernels.  See the "Cross compilation"
+         ;; section of INSTALL.md.
+         "--enable-generic"
+         "--disable-sse" "--disable-sse-assembly" ;Require SSE3
+         "--disable-avx" "--disable-avx2" "--disable-avx512"
+         ,(string-append "CFLAGS=-O3 "
+                         "-funsafe-loop-optimizations -funsafe-math-optimizations "
+                         "-ftree-vect-loop-version -ftree-vectorize "
+                         ,(let ((system (or (%current-target-system)
+                                            (%current-system))))
+                            (cond
+                             ((or (string-prefix? "x86_64" system)
+                                  (string-prefix? "i686" system))
+                              "-msse2")
+                             (else "")))))
+       #:parallel-tests? #f             ;tests are multi-threaded, via BLAS
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'patch-header-generation
+           (lambda _
+             (substitute* "configure"
+               (("^  *make.*top_srcdir=\"\\$srcdir\"" &)
+                (string-append & " CPP=\"$CPP\"")))
+             #t))
+         (add-before 'check 'setup-tests
+           (lambda _
+             ;; Decrease test time and RAM use by computing fewer eigenvalues.
+             ;; The flags are (MATRIX-SIZE, EIGENVALUES, BLOCK-SIZE), where
+             ;; the default is (500, 250, 16) for C tests and (5000, 150, 16)
+             ;; for Fortran.  This also causes several tests to pass that
+             ;; otherwise would otherwise fail with matrix size 5000; possibly
+             ;; due to floating point tolerances that are too tight.
+             (setenv "TEST_FLAGS" "1500 50 16") ;from elpa.spec
+             (setenv "OMP_NUM_THREADS" (number->string (parallel-job-count)))
+             (substitute* "Makefile"
+               ;; Test scripts are generated, patch the shebang
+               (("#!/bin/bash") (string-append "#!" (which "sh"))))
+             #t)))))
+    (home-page "http://elpa.mpcdf.mpg.de")
+    (synopsis "Eigenvalue solvers for symmetric matrices")
+    (description
+     "The ELPA library provides efficient and scalable direct eigensolvers for
+symmetric matrices.")
+    (license license:lgpl3)))
+
+(define-public elpa-openmpi
+  (package (inherit elpa)
+    (name "elpa-openmpi")
+    (inputs
+     `(("mpi" ,openmpi)
+       ("scalapack" ,scalapack)
+       ,@(package-inputs elpa)))
+    (arguments
+     (substitute-keyword-arguments (package-arguments elpa)
+       ((#:configure-flags cf '())
+        `(cons "--with-mpi=yes" (delete "--with-mpi=no" ,cf)))
+       ((#:phases phases '%standard-phases)
+        `(modify-phases ,phases
+           (add-before 'check 'mpi-setup
+             (lambda _
+               ;; Tests use 2 mpi tasks by default, use our remaining build
+               ;; cores as OpenMP threads.
+               (setenv "OMP_NUM_THREADS" (number->string
+                                          (max (quotient (parallel-job-count) 2)
+                                               1)))
+               (,%openmpi-setup)))))))
+    (synopsis "Eigenvalue solvers for symmetric matrices (with MPI support)")))
+
 (define-public elemental
   (package
     (name "elemental")
@@ -4232,3 +4345,536 @@ linear algebra primitives specifically targeting graph analytics.")
               license:gpl2+             ;include/psort/(funnel|sort)*.h
               license:x11               ;usort and psort
               license:bsd-3))))         ;CombBLAS and MersenneTwister.h
+
+(define-public dune-common
+  (package
+    (name "dune-common")
+    (version "2.6.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://dune-project.org/download/"
+                           version "/dune-common-" version ".tar.gz"))
+       (sha256
+        (base32
+         "019wcr1qf7jwyxx1y5y290wdlglylskvbb2m01ljkzcza2xnlmhw"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'build-tests
+           (lambda* (#:key make-flags #:allow-other-keys)
+             (apply invoke "make" "build_tests" make-flags)))
+         ;; These tests fail because they require a fully functional MPI
+         ;; environment.
+         (add-after 'unpack 'disable-failing-tests
+           (lambda _
+             (setenv "ARGS"
+                     (string-append "--exclude-regex '("
+                                    (string-join
+                                     (list
+                                      "remoteindicestest"
+                                      "remoteindicestest-mpi-2"
+                                      "syncertest"
+                                      "syncertest-mpi-2"
+                                      "variablesizecommunicatortest"
+                                      "variablesizecommunicatortest-mpi-2"
+                                      "arithmetictestsuitetest"
+                                      "assertandreturntest"
+                                      "assertandreturntest_ndebug"
+                                      "concept"
+                                      "debugaligntest"
+                                      "mpicollectivecommunication"
+                                      "mpicollectivecommunication-mpi-2"
+                                      "mpiguardtest"
+                                      "mpiguardtest-mpi-2"
+                                      "mpihelpertest"
+                                      "mpihelpertest-mpi-2"
+                                      "mpihelpertest2"
+                                      "mpihelpertest2-mpi-2")
+                                     "|")
+                                    ")'"))
+             #t)))))
+    (inputs
+     `(("gmp" ,gmp)
+       ("metis" ,metis)
+       ("openmpi" ,openmpi)
+       ("openblas" ,openblas)
+       ("python" ,python)
+       ("superlu" ,superlu)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment")
+    (description "DUNE, the Distributed and Unified Numerics Environment is a
+modular toolbox for solving @dfn{partial differential equations} (PDEs) with
+grid-based methods.  It supports the easy implementation of methods like
+@dfn{Finite Elements} (FE), @dfn{Finite Volumes} (FV), and also @dfn{Finite
+Differences} (FD).")
+    ;; GPL version 2 with "runtime exception" to make it behave like LGPLv2.
+    (license license:gpl2)))
+
+(define-public dune-geometry
+  (package
+    (name "dune-geometry")
+    (version "2.6.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://dune-project.org/download/"
+                           version "/dune-geometry-" version ".tar.gz"))
+       (sha256
+        (base32
+         "0hlaaxjyv9j05blasvb67sy02hd0w4g9znf68gdh3l731dd1aqbn"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'build-tests
+           (lambda* (#:key make-flags #:allow-other-keys)
+             (apply invoke "make" "build_tests" make-flags))))))
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("openmpi" ,openmpi)
+       ;; Optional
+       ("openblas" ,openblas)
+       ("gmp" ,gmp)
+       ("python" ,python)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment")
+    (description "DUNE, the Distributed and Unified Numerics Environment is a
+modular toolbox for solving @dfn{partial differential equations} (PDEs) with
+grid-based methods.  It supports the easy implementation of methods like
+@dfn{Finite Elements} (FE), @dfn{Finite Volumes} (FV), and also @dfn{Finite
+Differences} (FD).
+
+This package contains the basic DUNE geometry classes.")
+    ;; GPL version 2 with "runtime exception"
+    (license license:gpl2)))
+
+(define-public dune-grid
+  (package
+    (name "dune-grid")
+    (version "2.6.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://dune-project.org/download/"
+                           version "/dune-grid-" version ".tar.gz"))
+       (sha256
+        (base32
+         "1jp4vscm9yb9xg0lh7apzccfkhvgbnk652yahigmh3cvzpl4acd0"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'build-tests
+           (lambda* (#:key make-flags #:allow-other-keys)
+             (apply invoke "make" "build_tests" make-flags)))
+         ;; These tests fail because they require a fully functional MPI
+         ;; environment.
+         (add-after 'unpack 'disable-failing-tests
+           (lambda _
+             (setenv "ARGS"
+                     (string-append "--exclude-regex '("
+                                    (string-join
+                                     (list
+                                      "scsgmappertest"
+                                      "conformvolumevtktest"
+                                      "gnuplottest"
+                                      "nonconformboundaryvtktest"
+                                      "subsamplingvtktest"
+                                      "vtktest"
+                                      "vtktest-mpi-2"
+                                      "vtksequencetest"
+                                      "gmshtest-onedgrid"
+                                      "test-dgf-yasp"
+                                      "test-dgf-yasp-offset"
+                                      "test-dgf-oned"
+                                      "test-geogrid-yaspgrid"
+                                      "test-gridinfo"
+                                      "test-identitygrid"
+                                      "testiteratorranges"
+                                      "test-hierarchicsearch"
+                                      "test-parallel-ug-mpi-2"
+                                      "test-yaspgrid-backuprestore-equidistant"
+                                      "test-yaspgrid-backuprestore-equidistant-mpi-2"
+                                      "test-yaspgrid-backuprestore-equidistantoffset"
+                                      "test-yaspgrid-backuprestore-equidistantoffset-mpi-2"
+                                      "test-yaspgrid-backuprestore-tensor"
+                                      "test-yaspgrid-backuprestore-tensor-mpi-2"
+                                      "test-yaspgrid-tensorgridfactory"
+                                      "test-yaspgrid-tensorgridfactory-mpi-2"
+                                      "test-yaspgrid-yaspfactory-1d"
+                                      "test-yaspgrid-yaspfactory-1d-mpi-2"
+                                      "test-yaspgrid-yaspfactory-2d"
+                                      "test-yaspgrid-yaspfactory-2d-mpi-2"
+                                      "test-yaspgrid-yaspfactory-3d"
+                                      "test-yaspgrid-yaspfactory-3d-mpi-2"
+                                      "globalindexsettest"
+                                      "persistentcontainertest"
+                                      "structuredgridfactorytest"
+                                      "tensorgridfactorytest"
+                                      "vertexordertest")
+                                     "|")
+                                    ")'"))
+             #t)))))
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("dune-geometry" ,dune-geometry)
+       ("gmp" ,gmp)
+       ("metis" ,metis)
+       ("openblas" ,openblas)
+       ("openmpi" ,openmpi)
+       ("python" ,python)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment")
+    (description "DUNE, the Distributed and Unified Numerics Environment is a
+modular toolbox for solving @dfn{partial differential equations} (PDEs) with
+grid-based methods.  It supports the easy implementation of methods like
+@dfn{Finite Elements} (FE), @dfn{Finite Volumes} (FV), and also @dfn{Finite
+Differences} (FD).
+
+This package contains the basic DUNE grid classes.")
+    ;; GPL version 2 with "runtime exception"
+    (license license:gpl2)))
+
+(define-public dune-istl
+  (package
+    (name "dune-istl")
+    (version "2.6.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://dune-project.org/download/"
+                           version "/dune-istl-" version ".tar.gz"))
+       (sha256
+        (base32
+         "0l2gyrvys5w6wsmk0ckbb7295s80b7yk7qrl7x66akv2jv1nzq2w"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'build-tests
+           (lambda* (#:key make-flags #:allow-other-keys)
+             (apply invoke "make" "build_tests" make-flags)))
+         ;; These tests fail because they require a fully functional MPI
+         ;; environment.
+         (add-after 'unpack 'disable-failing-tests
+           (lambda _
+             (setenv "ARGS"
+                     (string-append "--exclude-regex '("
+                                    (string-join
+                                     (list
+                                      "galerkintest"
+                                     "hierarchytest"
+                                     "pamgtest"
+                                     "pamg_comm_repart_test"
+                                     "matrixredisttest"
+                                     "vectorcommtest"
+                                     "matrixmarkettest")
+                                     "|")
+                                    ")'"))
+             #t)))))
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("openmpi" ,openmpi)
+       ;; Optional
+       ("metis" ,metis)
+       ("superlu" ,superlu)
+       ("openblas" ,openblas)
+       ("gmp" ,gmp)
+       ("python" ,python)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment")
+    (description "DUNE, the Distributed and Unified Numerics Environment is a
+modular toolbox for solving @dfn{partial differential equations} (PDEs) with
+grid-based methods.
+
+This is the iterative solver template library which provides generic sparse
+matrix/vector classes and a variety of solvers based on these classes.  A
+special feature is the use of templates to exploit the recursive block
+structure of finite element matrices at compile time.  Available solvers
+include Krylov methods, (block-) incomplete decompositions and
+aggregation-based algebraic multigrid.")
+    ;; GPL version 2 with "runtime exception"
+    (license license:gpl2)))
+
+(define-public dune-localfunctions
+  (package
+    (name "dune-localfunctions")
+    (version "2.6.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://dune-project.org/download/"
+                           version "/dune-localfunctions-" version ".tar.gz"))
+       (sha256
+        (base32
+         "19c6zjinwwpy8jh4v4prhphyd438rapd4x80fj93apmwgw04nrhl"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'build-tests
+           (lambda* (#:key make-flags #:allow-other-keys)
+             (apply invoke "make" "build_tests" make-flags))))))
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("dune-geometry" ,dune-geometry)
+       ("openmpi" ,openmpi)
+       ;; Optional
+       ("metis" ,metis)
+       ("superlu" ,superlu)
+       ("gmp" ,gmp)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment") ; TODO
+    (description "This DUNE module provides interface and implementation for
+shape functions defined on the DUNE reference elements.  In addition to the
+shape function, interpolation operators and special keys are provided which
+can be used to assemble global function spaces on finite-element grids.
+
+This package provides an interface and implementation for shape functions
+defined on the DUNE reference elements.  In addition to the shape function,
+interpolation operators and special keys are provided which can be used to
+assemble global function spaces on finite-element grids.")
+    ;; GPL version 2 with "runtime exception"
+    (license license:gpl2)))
+
+(define-public dune-alugrid
+  (package
+    (name "dune-alugrid")
+    (version "2.6.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://dune-project.org/download/"
+                           version "/dune-alugrid-" version ".tar.gz"))
+       (sha256
+        (base32
+         "1l9adgyjpra8mvwm445s0lpjshnb63jag85fb2hisbjn6bm320yj"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:tests? #f ; 7 of 8 tests fail because they need a full MPI
+                   ; environment
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-include
+           (lambda _
+             (substitute* "dune/alugrid/test/test-alugrid.cc"
+               (("doc/grids/gridfactory/testgrids")
+                "doc/dune-grid/grids/gridfactory/testgrids"))
+             #t))
+         (add-after 'build 'build-tests
+           (lambda* (#:key inputs make-flags #:allow-other-keys)
+             (setenv "CPLUS_INCLUDE_PATH"
+                     (string-append (assoc-ref inputs "dune-grid") "/share:"
+                                    (getenv "CPLUS_INCLUDE_PATH")))
+             (apply invoke "make" "build_tests" make-flags))))))
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("dune-geometry" ,dune-geometry)
+       ("dune-grid" ,dune-grid)
+       ("openmpi" ,openmpi)
+       ;; Optional
+       ("metis" ,metis)
+       ("openblas" ,openblas)
+       ("python" ,python)
+       ("superlu" ,superlu)
+       ("gmp" ,gmp)
+       ("zlib" ,zlib)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment")
+    (description "ALUGrid is an adaptive, loadbalancing, unstructured
+implementation of the DUNE grid interface supporting either simplices or
+cubes.")
+    (license license:gpl2+)))
+
+(define-public dune-typetree
+  (package
+    (name "dune-typetree")
+    (version "2.6.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://gitlab.dune-project.org/staging/dune-typetree.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "0mnv6w2f22lz3j4bdpdjq55vjm8xxfx9v4vvhg9bd36xpsbjpjp9"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'build-tests
+           (lambda* (#:key make-flags #:allow-other-keys)
+             (apply invoke "make" "build_tests" make-flags))))))
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("openmpi" ,openmpi)
+       ;; Optional
+       ("openblas" ,openblas)
+       ("python" ,python)
+       ("metis" ,metis)
+       ("superlu" ,superlu)
+       ("gmp" ,gmp)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment")
+    (description "TypeTree is a template library for constructing and
+operating on statically typed trees of objects.")
+    ;; Either GPL version 2 with "runtime exception" or LGPLv3+.
+    (license (list license:lgpl3+ license:gpl2))))
+
+(define-public dune-functions
+  (package
+    (name "dune-functions")
+    (version "2.6.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://gitlab.dune-project.org/staging/dune-functions.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "1an8gb477n8j0kzpbrv7nr1snh8pxip0gsxq6w63jc83gg3dj200"))))
+    (build-system cmake-build-system)
+    (arguments `(#:tests? #f)) ; FIXME: tests require dune-uugrid
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("dune-istl" ,dune-istl)
+       ("dune-localfunctions" ,dune-localfunctions)
+       ("dune-grid" ,dune-grid)
+       ("dune-geometry" ,dune-geometry)
+       ("dune-typetree" ,dune-typetree)
+       ("openmpi" ,openmpi)
+       ("openblas" ,openblas)
+       ("metis" ,metis)
+       ("python" ,python)
+       ("superlu" ,superlu)
+       ("gmp" ,gmp)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Distributed and Unified Numerics Environment")
+    (description "The dune-functions module provides an abstraction layer for
+global finite element functions.  Its two main concepts are functions
+implemented as callable objects, and bases of finite element spaces.")
+    ;; Either GPL version 2 with "runtime exception" or LGPLv3+.
+    (license (list license:lgpl3+ license:gpl2))))
+
+(define-public dune-pdelab
+  (package
+    (name "dune-pdelab")
+    (version "2.6.0-rc1")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://gitlab.dune-project.org/pdelab/dune-pdelab")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "07g0s9448z65vjrq88g5rv3340iifil85k170n8kbqchsvi4ny5v"))))
+    (build-system cmake-build-system)
+    (arguments '(#:tests? #f)) ; XXX: the tests cannot be compiled
+    (inputs
+     `(("dune-common" ,dune-common)
+       ("dune-istl" ,dune-istl)
+       ("dune-localfunctions" ,dune-localfunctions)
+       ("dune-geometry" ,dune-geometry)
+       ("dune-grid" ,dune-grid)
+       ("dune-typetree" ,dune-typetree)
+       ("dune-functions" ,dune-functions)
+       ("openmpi" ,openmpi)
+       ;; Optional
+       ("openblas" ,openblas)
+       ("eigen" ,eigen)
+       ("metis" ,metis)
+       ("python" ,python)
+       ("superlu" ,superlu)
+       ("gmp" ,gmp)))
+    (native-inputs
+     `(("gfortran" ,gfortran)
+       ("pkg-config" ,pkg-config)))
+    (home-page "https://dune-project.org/")
+    (synopsis "Differential equations solver toolbox")
+    (description "PDELab is a partial differential equations solver toolbox
+built on top of DUNE, the Distributed and Unified Numerics Environment.")
+    ;; Either GPL version 2 with "runtime exception" or LGPLv3+.
+    (license (list license:lgpl3+ license:gpl2))))
+
+(define-public mlucas
+  (package
+    (name "mlucas")
+    (version "18")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "https://mersenneforum.org/mayer/src/C/mlucas_v" version ".txz"))
+       (sha256
+        (base32
+         "1ax12qj9lyvnx4vs3gx7l8r3wx5gjbsdswp5f00ik9z0wz7xf297"))))
+    (build-system gnu-build-system)
+    (inputs
+     `(("python2" ,python-2)))
+    (arguments
+     `(#:tests? #f ; no tests
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'configure
+           (lambda _
+             (chdir "src")
+             (call-with-output-file "Makefile"
+               (lambda (port)
+                 (format port "CC = gcc
+CFLAGS = -O3 ~a -DUSE_THREADS
+LDLIBS = -lm -lpthread -lrt
+Mlucas: $(addsuffix .o,$(basename $(wildcard *.c)))
+"
+                         ,(let ((system (or (%current-target-system)
+                                            (%current-system))))
+                            (cond
+                             ((string-prefix? "x86_64" system) "-DUSE_SSE2")
+                             (else ""))))))
+             #t))
+         (replace 'install
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let ((bin (string-append (assoc-ref outputs "out") "/bin")))
+               (install-file "Mlucas" bin)
+               (install-file "primenet.py" bin))
+             #t)))))
+    (home-page "https://www.mersenne.org")
+    (synopsis "Great Internet Mersenne Prime Search (GIMPS) distributed computing client")
+    (description "Mlucas performs Lucas-Lehmer primality testing of Mersenne
+numbers in search of a world-record prime.  You may use it to test any
+suitable number as you wish, but it is preferable that you do so in a
+coordinated fashion, as part of the Great Internet Mersenne Prime
+Search (GIMPS).  Mlucas also includes a simple Python script for assignment
+management via the GIMPS project's Primenet server.")
+    (license license:gpl2+)))