[arch-commits] Commit in maxima-ecl/trunk (PKGBUILD matrixexp.patch)

Antonio Rojas arojas at archlinux.org
Tue Feb 17 23:10:38 UTC 2015


    Date: Wednesday, February 18, 2015 @ 00:10:38
  Author: arojas
Revision: 127885

Fix matrix exponentiation in Sage

Added:
  maxima-ecl/trunk/matrixexp.patch
Modified:
  maxima-ecl/trunk/PKGBUILD

-----------------+
 PKGBUILD        |   23 +++++++++++++----------
 matrixexp.patch |   13 +++++++++++++
 2 files changed, 26 insertions(+), 10 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2015-02-17 21:59:26 UTC (rev 127884)
+++ PKGBUILD	2015-02-17 23:10:38 UTC (rev 127885)
@@ -8,23 +8,24 @@
 _pkgname=maxima
 pkgver=5.35.1
 _eclver=13.5.1
-pkgrel=1
+pkgrel=3
 pkgdesc="A sophisticated computer algebra system (compiled against ecl)"
 arch=('i686' 'x86_64')
-license=('GPL')
+license=(GPL)
 url="http://maxima.sourceforge.net"
-depends=("ecl=$_eclver" 'texinfo')
-makedepends=('python2')
+depends=("ecl=$_eclver" texinfo)
+makedepends=(python2 emacs)
 optdepends=('gnuplot: plotting capabilities' 'rlwrap: readline support via /usr/bin/rmaxima' 'tk: graphical xmaxima interface')
-conflicts=('maxima')
-provides=('maxima')
-options=('!zipman') # don't zip info pages or they won't work inside maxima
+conflicts=(maxima)
+provides=(maxima)
+options=(!zipman) # don't zip info pages or they won't work inside maxima
 install=maxima.install
 source=("http://downloads.sourceforge.net/sourceforge/${_pkgname}/${_pkgname}-${pkgver}.tar.gz"
-        "${_pkgname}.desktop" 'build-fasl.patch')
+        "${_pkgname}.desktop" 'build-fasl.patch' 'matrixexp.patch')
 md5sums=('4bb0b999645ec2b20b7e301d36f83a4c'
          '24aa81126fbb8b726854e5a80d4c2415'
-         'eb33481ea06afb97743af06ff52c099b')
+         'eb33481ea06afb97743af06ff52c099b'
+         '0a1fb7bb0cfdede965252b75decc2c0d')
 
 prepare() {
   cd $_pkgname-$pkgver
@@ -34,6 +35,8 @@
 
 # build maxima ecl library
   patch -p1 -i ../build-fasl.patch
+# fix matrix exponentiation
+  patch -p1 -i ../matrixexp.patch
 }
 
 build() {
@@ -49,7 +52,7 @@
 
 package() {
   cd $_pkgname-$pkgver
-  make DESTDIR="$pkgdir" install
+  make DESTDIR="$pkgdir" emacsdir=/usr/share/emacs/site-lisp/maxima install
 
   # install some freedesktop.org compatibility
   install -Dm644 ${srcdir}/${_pkgname}.desktop \

Added: matrixexp.patch
===================================================================
--- matrixexp.patch	                        (rev 0)
+++ matrixexp.patch	2015-02-17 23:10:38 UTC (rev 127885)
@@ -0,0 +1,13 @@
+--- a/share/linearalgebra/matrixexp.lisp
++++ b/share/linearalgebra/matrixexp.lisp
+@@ -138,8 +138,8 @@
+ 	   (print `(ratvars = ,$ratvars gcd = '$gcd algebraic = ,$algebraic))
+ 	   (print `(ratfac = ,$ratfac))
+ 	   (merror "Unable to find the spectrum")))
+-   
+-    (setq res ($fullratsimp (ncpower (sub (mult z ($ident n)) mat) -1) z))
++
++    (setq res ($fullratsimp ($invert_by_lu (sub (mult z ($ident n)) mat) '$crering) z))
+     (setq m (length sp))
+     (dotimes (i m)
+       (setq zi (nth i sp))



More information about the arch-commits mailing list