- speedup for matrix multiplication of somewhat sparse matrices.
- gamma -> Euler (sorry 4 that, again).
- two new tests (Q and Q') from Lewis' and Wester's testsuite.
- fixed compilation desaster in timing M1 by using the new parser.
- had a glass of beer.
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- series(f(x),x,p[,o]) -> series(f(x),x==p,o)
- gamma() -> tgamma() (The true Gamma function, there is now also
log(tgamma()), called lgamma(), in accord with ISO/IEC 9899:1999.)
- - EulerGamma -> gamma
+ - EulerGamma -> Euler
* #include'ing ginac.h defines the preprocessor symbols GINACLIB_MAJOR_VERSION,
GINACLIB_MINOR_VERSION, and GINACLIB_MICRO_VERSION with the respective GiNaC
library version numbers.
LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
-$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
+$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
|| AC_MSG_ERROR([libtool configure failed])
# Reload cache, that may have been modified by ltconfig
AC_REQUIRE([AC_PROG_LN_S])dnl
dnl
+case "$target" in
+NONE) lt_target="$host" ;;
+*) lt_target="$target" ;;
+esac
+
# Check for any special flags to pass to ltconfig.
libtool_flags="--cache-file=$cache_file"
test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
# Some flags need to be propagated to the compiler or linker for good
# libtool support.
-case "$host" in
+case "$lt_target" in
*-*-irix6*)
# Find out which ABI we are using.
echo '[#]line __oline__ "configure"' > conftest.$ac_ext
AC_MSG_RESULT(no)
fi
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
-AC_SUBST(LD)
AC_PROG_LD_GNU
])
fi])
NM="$ac_cv_path_NM"
AC_MSG_RESULT([$NM])
-AC_SUBST(NM)
])
# AC_CHECK_LIBM - check for math library
AC_DEFUN(AC_CHECK_LIBM,
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
LIBM=
-case "$host" in
+case "$lt_target" in
*-*-beos* | *-*-cygwin*)
# These system don't have libm
;;
time_vandermonde.cpp time_toeplitz.cpp time_lw_A.cpp time_lw_B.cpp \
time_lw_C.cpp time_lw_D.cpp time_lw_E.cpp time_lw_F.cpp time_lw_G.cpp \
time_lw_H.cpp time_lw_IJKL.cpp time_lw_M1.cpp time_lw_O.cpp time_lw_P.cpp \
- time_lw_Pprime.cpp timer.cpp times.cpp times.h
+ time_lw_Pprime.cpp time_lw_Q.cpp time_lw_Qprime.cpp \
+ timer.cpp times.cpp times.h
times_LDADD = ../ginac/libginac.la
INCLUDES = -I$(srcdir)/../ginac
CLEANFILES = exams.out checks.out times.out
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
checks_SOURCES = check_numeric.cpp check_inifcns.cpp check_matrices.cpp check_lsolve.cpp genex.cpp checks.cpp checks.h
checks_LDADD = ../ginac/libginac.la
-times_SOURCES = time_dennyfliegner.cpp time_gammaseries.cpp time_vandermonde.cpp time_toeplitz.cpp time_lw_A.cpp time_lw_B.cpp time_lw_C.cpp time_lw_D.cpp time_lw_E.cpp time_lw_F.cpp time_lw_G.cpp time_lw_H.cpp time_lw_IJKL.cpp time_lw_M1.cpp time_lw_O.cpp time_lw_P.cpp time_lw_Pprime.cpp timer.cpp times.cpp times.h
+times_SOURCES = time_dennyfliegner.cpp time_gammaseries.cpp time_vandermonde.cpp time_toeplitz.cpp time_lw_A.cpp time_lw_B.cpp time_lw_C.cpp time_lw_D.cpp time_lw_E.cpp time_lw_F.cpp time_lw_G.cpp time_lw_H.cpp time_lw_IJKL.cpp time_lw_M1.cpp time_lw_O.cpp time_lw_P.cpp time_lw_Pprime.cpp time_lw_Q.cpp time_lw_Qprime.cpp timer.cpp times.cpp times.h
times_LDADD = ../ginac/libginac.la
INCLUDES = -I$(srcdir)/../ginac
time_vandermonde.o time_toeplitz.o time_lw_A.o time_lw_B.o time_lw_C.o \
time_lw_D.o time_lw_E.o time_lw_F.o time_lw_G.o time_lw_H.o \
time_lw_IJKL.o time_lw_M1.o time_lw_O.o time_lw_P.o time_lw_Pprime.o \
-timer.o times.o
+time_lw_Q.o time_lw_Qprime.o timer.o times.o
times_DEPENDENCIES = ../ginac/libginac.la
times_LDFLAGS =
CXXFLAGS = @CXXFLAGS@
.deps/time_lw_C.P .deps/time_lw_D.P .deps/time_lw_E.P .deps/time_lw_F.P \
.deps/time_lw_G.P .deps/time_lw_H.P .deps/time_lw_IJKL.P \
.deps/time_lw_M1.P .deps/time_lw_O.P .deps/time_lw_P.P \
-.deps/time_lw_Pprime.P .deps/time_toeplitz.P .deps/time_vandermonde.P \
-.deps/timer.P .deps/times.P
+.deps/time_lw_Pprime.P .deps/time_lw_Q.P .deps/time_lw_Qprime.P \
+.deps/time_toeplitz.P .deps/time_vandermonde.P .deps/timer.P \
+.deps/times.P
SOURCES = $(exams_SOURCES) $(checks_SOURCES) $(times_SOURCES)
OBJECTS = $(exams_OBJECTS) $(checks_OBJECTS) $(times_OBJECTS)
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
unsigned result = 0;
symbol a("a");
- for (int size=3; size<16; ++size) {
+ for (int size=3; size<17; ++size) {
matrix A(size,size);
+ for (int r=0; r<size-1; ++r) {
+ // populate one element in each row:
+ A.set(r,unsigned(rand()%size),dense_univariate_poly(a,5));
+ }
for (int c=0; c<size; ++c) {
- for (int r=0;r<size-1; ++r)
- // populate 10 percent of the entries, the rest remains 0:
- if (!(int)(10.0*rand()/(RAND_MAX+1.0)))
- A.set(r,c,dense_univariate_poly(a,5));
// set the last line to a linear combination of two other lines
// to guarantee that the determinant vanishes:
A.set(size-1,c,A(0,c)-A(size-2,c));
result += inifcns_consist_gamma(); cout << '.' << flush;
result += inifcns_consist_psi(); cout << '.' << flush;
result += inifcns_consist_zeta(); cout << '.' << flush;
-
+
if (!result) {
cout << " passed " << endl;
clog << "(no output)" << endl;
e = tgamma(2*x);
d = pow(x+1,-1)*numeric(1,4) +
pow(x+1,0)*(numeric(3,4) -
- numeric(1,2)*gamma) +
+ numeric(1,2)*Euler) +
pow(x+1,1)*(numeric(7,4) -
- numeric(3,2)*gamma +
- numeric(1,2)*pow(gamma,2) +
+ numeric(3,2)*Euler +
+ numeric(1,2)*pow(Euler,2) +
numeric(1,12)*pow(Pi,2)) +
pow(x+1,2)*(numeric(15,4) -
- numeric(7,2)*gamma -
- numeric(1,3)*pow(gamma,3) +
+ numeric(7,2)*Euler -
+ numeric(1,3)*pow(Euler,3) +
numeric(1,4)*pow(Pi,2) +
- numeric(3,2)*pow(gamma,2) -
- numeric(1,6)*pow(Pi,2)*gamma -
+ numeric(3,2)*pow(Euler,2) -
+ numeric(1,6)*pow(Pi,2)*Euler -
numeric(2,3)*zeta(3)) +
- pow(x+1,3)*(numeric(31,4) - pow(gamma,3) -
- numeric(15,2)*gamma +
- numeric(1,6)*pow(gamma,4) +
- numeric(7,2)*pow(gamma,2) +
+ pow(x+1,3)*(numeric(31,4) - pow(Euler,3) -
+ numeric(15,2)*Euler +
+ numeric(1,6)*pow(Euler,4) +
+ numeric(7,2)*pow(Euler,2) +
numeric(7,12)*pow(Pi,2) -
- numeric(1,2)*pow(Pi,2)*gamma -
+ numeric(1,2)*pow(Pi,2)*Euler -
numeric(2)*zeta(3) +
- numeric(1,6)*pow(gamma,2)*pow(Pi,2) +
+ numeric(1,6)*pow(Euler,2)*pow(Pi,2) +
numeric(1,40)*pow(Pi,4) +
- numeric(4,3)*zeta(3)*gamma) +
+ numeric(4,3)*zeta(3)*Euler) +
Order(pow(x+1,4));
result += check_series(e, -1, d, 4);
{
// Determinant of a sparse matrix that comes up in graph theory:
symbol x1("x1"), x2("x2"), x3("x3"), x4("x4"), x5("x5");
- ex w[26][11] = {
+ static ex w[26][11] = {
{ 1, 1, 1, 7, x4, 12, x3, 17, x2, 22, x1},
{ 2, 2, 1, 8, x4, 13, x3, 18, x2, 23, x1},
{ 3, 3, 1, 9, x4, 14, x3, 19, x2, 24, x1},
}
ex det = m.determinant();
// The result should have been:
- ex cmp = -12*pow(x1*x5,2)*x4-12*x1*pow(x2*x4,2)-12*x3*pow(x4*x5,2)
- -pow(x5,3)*pow(x4,2)-12*x1*pow(x4*x5,2)-12*x2*pow(x4*x5,2)
- -pow(x4,3)*pow(x5,2)-2*pow(x5,3)*x4*x3-2*pow(x4,3)*x5*x3
- -36*x3*x1*pow(x5,2)*x4-36*x3*x1*pow(x4,2)*x5-12*pow(x3*x5,2)*x4
- -12*pow(x3*x4,2)*x5-36*x3*x2*pow(x5,2)*x4-36*x3*x2*pow(x4,2)*x5
- -36*x1*x5*pow(x3,2)*x4-36*x2*x5*pow(x3,2)*x4-12*x1*pow(x3*x5,2)
- -12*x1*pow(x3*x4,2)-pow(x3,3)*pow(x5,2)-pow(x3,3)*pow(x4,2)
- -2*pow(x3,3)*x5*x4-12*x2*pow(x3*x5,2)-12*x2*pow(x3*x4,2)
- -12*x1*pow(x2*x5,2)-12*pow(x2*x5,2)*x4-12*pow(x2*x4,2)*x5
- -12*pow(x2*x5,2)*x3-12*pow(x2*x4,2)*x3-12*pow(x2*x3,2)*x5
- -12*pow(x2*x3,2)*x4-pow(x3,2)*pow(x5,3)-pow(x3,2)*pow(x4,3)
- -2*pow(x5,3)*x4*x2-2*pow(x4,3)*x5*x2-2*x3*pow(x5,3)*x2
- -2*x3*pow(x4,3)*x2-2*pow(x3,3)*x5*x2-2*pow(x3,3)*x4*x2
- -2*pow(x2,3)*x5*x4-36*x2*x1*pow(x5,2)*x4-36*x2*x1*pow(x4,2)*x5
- -120*x2*x1*x5*x4*x3-36*x2*x1*pow(x5,2)*x3-36*x2*x1*pow(x4,2)*x3
- -36*x2*x1*pow(x3,2)*x5-36*x2*x1*pow(x3,2)*x4-36*pow(x2,2)*x5*x4*x3
- -36*pow(x1,2)*x5*x4*x3-12*pow(x1*x5,2)*x3-12*pow(x1*x4,2)*x3
- -12*pow(x1*x3,2)*x5-12*pow(x1*x3,2)*x4-12*pow(x1*x5,2)*x2
- -12*pow(x1*x4,2)*x2-12*pow(x1*x3,2)*x2-12*pow(x1*x2,2)*x5
- -12*pow(x1*x2,2)*x4-12*pow(x1*x2,2)*x3-pow(x2,2)*pow(x5,3)
- -pow(x2,2)*pow(x4,3)-pow(x2,2)*pow(x3,3)-36*x1*x5*pow(x2,2)*x4
- -36*x1*x5*pow(x2,2)*x3-36*x1*x4*pow(x2,2)*x3-36*x2*pow(x1,2)*x5*x4
- -pow(x2,3)*pow(x5,2)-pow(x2,3)*pow(x4,2)-pow(x2,3)*pow(x3,2)
- -2*pow(x2,3)*x5*x3-2*pow(x2,3)*x4*x3-12*x1*pow(x2*x3,2)
- -12*pow(x1*x4,2)*x5-pow(x1,3)*pow(x5,2)-pow(x1,3)*pow(x4,2)
- -pow(x1,3)*pow(x3,2)-pow(x1,3)*pow(x2,2)-pow(x1,2)*pow(x5,3)
- -pow(x1,2)*pow(x4,3)-pow(x1,2)*pow(x3,3)-pow(x1,2)*pow(x2,3)
- -36*x2*x3*pow(x1,2)*x5-36*x2*x3*pow(x1,2)*x4-2*pow(x5,3)*x4*x1
- -2*pow(x4,3)*x5*x1-2*x3*pow(x5,3)*x1-2*x3*pow(x4,3)*x1
- -2*pow(x3,3)*x5*x1-2*pow(x3,3)*x4*x1-2*x2*pow(x5,3)*x1
- -2*x2*pow(x4,3)*x1-2*x2*pow(x3,3)*x1-2*pow(x2,3)*x5*x1
- -2*pow(x2,3)*x4*x1-2*pow(x2,3)*x3*x1-2*pow(x1,3)*x5*x4
- -2*pow(x1,3)*x5*x3-2*pow(x1,3)*x5*x2-2*pow(x1,3)*x4*x3
- -2*pow(x1,3)*x4*x2-2*pow(x1,3)*x3*x2;
- if (det!=cmp) {
+ const char *cmp = "-12*x2^2*x5^2*x4-12*x1*x5^2*x3^2-x5^3*x4^2-12*x1*x5^2*x4^2-12*x2*x5^2*x4^2-12*x3*x5^2*x4^2-x4^3*x5^2-36*x3*x1*x5^2*x4-36*x3*x1*x4^2*x5-36*x3*x2*x5^2*x4-36*x3*x2*x4^2*x5-2*x5^3*x4*x2-12*x3^2*x5^2*x4-12*x3^2*x4^2*x5-2*x5^3*x4*x3-2*x4^3*x5*x3-12*x1*x5^2*x2^2-36*x1*x5*x3^2*x4-36*x2*x5*x3^2*x4-x3^3*x5^2-x3^3*x4^2-2*x3^3*x5*x4-12*x2^2*x4^2*x5-12*x2*x5^2*x3^2-12*x2*x4^2*x3^2-12*x1*x4^2*x3^2-x3^2*x5^3-x3^2*x4^3-2*x4^3*x5*x2-2*x3*x5^3*x2-2*x3*x4^3*x2-2*x3^3*x5*x2-2*x3^3*x4*x2-2*x2^3*x5*x4-2*x2^3*x5*x3-2*x2^3*x4*x3-36*x2^2*x5*x4*x3-36*x2*x1*x5^2*x4-36*x2*x1*x4^2*x5-120*x2*x1*x5*x4*x3-36*x2*x1*x5^2*x3-36*x2*x1*x4^2*x3-36*x2*x1*x3^2*x5-36*x2*x1*x3^2*x4-12*x2^2*x5^2*x3-12*x2^2*x4^2*x3-12*x2^2*x3^2*x5-12*x2^2*x3^2*x4-2*x1^3*x4*x3-2*x1^3*x4*x2-2*x1^3*x3*x2-2*x1^3*x5*x2-36*x1^2*x5*x4*x3-36*x2*x1^2*x5*x4-36*x2*x3*x1^2*x5-36*x2*x3*x1^2*x4-x1^3*x5^2-x1^3*x4^2-x1^3*x3^2-x1^3*x2^2-x2^2*x5^3-x2^2*x4^3-x2^2*x3^3-12*x1*x4^2*x2^2-12*x1*x3^2*x2^2-12*x1^2*x5^2*x4-12*x1^2*x4^2*x5-12*x1^2*x5^2*x3-12*x1^2*x4^2*x3-12*x1^2*x3^2*x5-12*x1^2*x3^2*x4-12*x1^2*x5^2*x2-12*x1^2*x4^2*x2-12*x1^2*x3^2*x2-12*x1^2*x2^2*x5-12*x1^2*x2^2*x4-12*x1^2*x2^2*x3-2*x5^3*x4*x1-2*x4^3*x5*x1-2*x3*x5^3*x1-2*x3*x4^3*x1-2*x3^3*x5*x1-2*x3^3*x4*x1-2*x2*x5^3*x1-2*x2*x4^3*x1-2*x2*x3^3*x1-2*x2^3*x5*x1-2*x2^3*x4*x1-2*x2^3*x3*x1-2*x1^3*x5*x4-2*x1^3*x5*x3-36*x1*x5*x2^2*x4-36*x1*x5*x2^2*x3-36*x1*x4*x2^2*x3-x1^2*x5^3-x1^2*x4^3-x1^2*x3^3-x2^3*x5^2-x2^3*x4^2-x2^3*x3^2-x1^2*x2^3";
+ istrstream cmpstrm(cmp,strlen(cmp));
+ ex cmpex = lst(x1,x2,x3,x4,x5);
+ cmpstrm >> cmpex;
+ if (det!=cmpex) {
clog << "The determinant was miscalculated" << endl;
return 1;
}
--- /dev/null
+/** @file time_lw_Q.cpp
+ *
+ * Test Q from the paper "Comparison of Polynomial-Oriented CAS" by Robert H.
+ * Lewis and Michael Wester. */
+
+/*
+ * GiNaC Copyright (C) 1999-2000 Johannes Gutenberg University Mainz, Germany
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include "times.h"
+#include "time_lw_w101n.h"
+
+static unsigned test(void)
+{
+ matrix m(101,101);
+ symbol lambda("lambda");
+ for (unsigned r=0; r<101; ++r) {
+ for (unsigned c=0; c<10; ++c) {
+ m.set(r,
+ unsigned(ex_to_numeric(w101_numeric[r][2*c+1]).to_int()-1),
+ w101_numeric[r][2*c+2]);
+ }
+ }
+ ex cp = m.charpoly(lambda);
+
+ if (cp.coeff(lambda,96) != numeric("75287520")) {
+ clog << "characteristic polynomial miscalculated as " << cp << endl;
+ return 1;
+ }
+ return 0;
+}
+
+unsigned time_lw_Q(void)
+{
+ unsigned result = 0;
+ unsigned count = 0;
+ timer rolex;
+ double time = .0;
+
+ cout << "timing Lewis-Wester test Q (charpoly(P))" << flush;
+ clog << "-------Lewis-Wester test Q (charpoly(P))" << endl;
+
+ rolex.start();
+ // correct for very small times:
+ do {
+ result = test();
+ ++count;
+ } while ((time=rolex.read())<0.1 && !result);
+ cout << '.' << flush;
+
+ if (!result) {
+ cout << " passed ";
+ clog << "(no output)" << endl;
+ } else {
+ cout << " failed ";
+ }
+ cout << int(1000*(time/count))*0.001 << 's' << endl;
+
+ return result;
+}
--- /dev/null
+/** @file time_lw_Qprime.cpp
+ *
+ * Test Q' from the paper "Comparison of Polynomial-Oriented CAS" by Robert H.
+ * Lewis and Michael Wester. */
+
+/*
+ * GiNaC Copyright (C) 1999-2000 Johannes Gutenberg University Mainz, Germany
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#include "times.h"
+#include "time_lw_w101n.h"
+
+static unsigned test(void)
+{
+ matrix m(101,101);
+ symbol lambda("lambda");
+ for (unsigned r=0; r<101; ++r) {
+ for (unsigned c=0; c<10; ++c) {
+ m.set(r,
+ unsigned(ex_to_numeric(w101_numeric[r][2*c+1]).to_int()-1),
+ w101_numeric[r][2*c+2]);
+ }
+ }
+ matrix m2(m);
+ ex a;
+ for (unsigned r=0; r<101; ++r) {
+ a = m2(r,0);
+ for (unsigned c=0; c<100; ++c) {
+ m2.set(r,c,m2(r,c+1));
+ }
+ m2.set(r,100,a);
+ }
+ for (unsigned r=0; r<101; ++r) {
+ for (unsigned c=0; c<101; ++c) {
+ if (!m(r,c).is_zero())
+ m2.set(r,c,m(r,c));
+ }
+ }
+ ex cp = m2.charpoly(lambda);
+
+ if (cp.coeff(lambda,0) != numeric("140816284877507872414776")) {
+ clog << "characteristic polynomial miscalculated as " << cp << endl;
+ return 1;
+ }
+ return 0;
+}
+
+unsigned time_lw_Qprime(void)
+{
+ unsigned result = 0;
+ unsigned count = 0;
+ timer rolex;
+ double time = .0;
+
+ cout << "timing Lewis-Wester test Q' (charpoly(P'))" << flush;
+ clog << "-------Lewis-Wester test Q' (charpoly(P'))" << endl;
+
+ rolex.start();
+ // correct for very small times:
+ do {
+ result = test();
+ ++count;
+ } while ((time=rolex.read())<0.1 && !result);
+ cout << '.' << flush;
+
+ if (!result) {
+ cout << " passed ";
+ clog << "(no output)" << endl;
+ } else {
+ cout << " failed ";
+ }
+ cout << int(1000*(time/count))*0.001 << 's' << endl;
+
+ return result;
+}
++result;
}
+ try {
+ result += time_lw_Q();
+ } catch (const exception &e) {
+ cout << "Error: caught exception " << e.what() << endl;
+ ++result;
+ }
+
+ try {
+ result += time_lw_Qprime();
+ } catch (const exception &e) {
+ cout << "Error: caught exception " << e.what() << endl;
+ ++result;
+ }
+
if (result) {
cout << "Error: something went wrong. ";
if (result == 1) {
#include <sys/resource.h>
#include <stdlib.h>
+#include <strstream>
#include <vector>
#include "ginac.h"
unsigned time_lw_O();
unsigned time_lw_P();
unsigned time_lw_Pprime();
+unsigned time_lw_Q();
+unsigned time_lw_Qprime();
#endif // ndef CHECKS_H
(no output)
-------Lewis-Wester test P' (det of less sparse rank 101)
(no output)
+-------Lewis-Wester test Q (charpoly(P))
+(no output)
+-------Lewis-Wester test Q' (charpoly(P'))
+(no output)
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
echo "$ac_t""no" 1>&6
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
-
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1556: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1555: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1572: checking for BSD-compatible nm" >&5
+echo "configure:1571: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
NM="$ac_cv_path_NM"
echo "$ac_t""$NM" 1>&6
-
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1609: checking whether ln -s works" >&5
+echo "configure:1607: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
+case "$target" in
+NONE) lt_target="$host" ;;
+*) lt_target="$target" ;;
+esac
+
# Check for any special flags to pass to ltconfig.
libtool_flags="--cache-file=$cache_file"
test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
# Some flags need to be propagated to the compiler or linker for good
# libtool support.
-case "$host" in
+case "$lt_target" in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 1653 "configure"' > conftest.$ac_ext
- if { (eval echo configure:1654: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 1656 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:1657: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case "`/usr/bin/file conftest.o`" in
*32-bit*)
LD="${LD-ld} -32"
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:1675: checking whether the C compiler needs -belf" >&5
+echo "configure:1678: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1680 "configure"
+#line 1683 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:1687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
-$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
+$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
|| { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
# Reload cache, that may have been modified by ltconfig
exec 5>>./config.log
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1789: checking how to run the C preprocessor" >&5
+echo "configure:1792: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 1804 "configure"
+#line 1807 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1810: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1813: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 1821 "configure"
+#line 1824 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1827: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1830: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 1838 "configure"
+#line 1841 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1844: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1874: checking for $ac_word" >&5
+echo "configure:1877: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "flex", so it can be a program name with args.
set dummy flex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1907: checking for $ac_word" >&5
+echo "configure:1910: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
*) ac_lib=l ;;
esac
echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
-echo "configure:1941: checking for yywrap in -l$ac_lib" >&5
+echo "configure:1944: checking for yywrap in -l$ac_lib" >&5
ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$ac_lib $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1949 "configure"
+#line 1952 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
yywrap()
; return 0; }
EOF
-if { (eval echo configure:1960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1963: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking lex output file root""... $ac_c" 1>&6
-echo "configure:1983: checking lex output file root" >&5
+echo "configure:1986: checking lex output file root" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
-echo "configure:2004: checking whether yytext is a pointer" >&5
+echo "configure:2007: checking whether yytext is a pointer" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_save_LIBS="$LIBS"
LIBS="$LIBS $LEXLIB"
cat > conftest.$ac_ext <<EOF
-#line 2016 "configure"
+#line 2019 "configure"
#include "confdefs.h"
`cat $LEX_OUTPUT_ROOT.c`
int main() {
; return 0; }
EOF
-if { (eval echo configure:2023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2026: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_prog_lex_yytext_pointer=yes
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2049: checking for $ac_word" >&5
+echo "configure:2052: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:2106: checking size of long" >&5
+echo "configure:2109: checking size of long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_long=4
else
cat > conftest.$ac_ext <<EOF
-#line 2114 "configure"
+#line 2117 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:2125: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long=`cat conftestval`
else
echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:2145: checking size of long long" >&5
+echo "configure:2148: checking size of long long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_long_long=8
else
cat > conftest.$ac_ext <<EOF
-#line 2153 "configure"
+#line 2156 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:2164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2167: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long_long=`cat conftestval`
else
echo $ac_n "checking size of long double""... $ac_c" 1>&6
-echo "configure:2184: checking size of long double" >&5
+echo "configure:2187: checking size of long double" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long_double'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_sizeof_long_double=12
else
cat > conftest.$ac_ext <<EOF
-#line 2192 "configure"
+#line 2195 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:2203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long_double=`cat conftestval`
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2235: checking for $ac_hdr" >&5
+echo "configure:2238: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2240 "configure"
+#line 2243 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2245: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2248: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2275: checking for $ac_hdr" >&5
+echo "configure:2278: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2280 "configure"
+#line 2283 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2285: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2288: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
for ac_func in tgetent
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2322: checking for $ac_func" >&5
+echo "configure:2325: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2327 "configure"
+#line 2330 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:2353: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2356: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
:
else
echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6
-echo "configure:2381: checking for tgetent in -lncurses" >&5
+echo "configure:2384: checking for tgetent in -lncurses" >&5
ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lncurses $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2389 "configure"
+#line 2392 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
tgetent()
; return 0; }
EOF
-if { (eval echo configure:2403: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test -z "$LIBTERMCAP"; then
echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6
-echo "configure:2425: checking for tgetent in -ltermcap" >&5
+echo "configure:2428: checking for tgetent in -ltermcap" >&5
ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ltermcap $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2433 "configure"
+#line 2436 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
tgetent()
; return 0; }
EOF
-if { (eval echo configure:2447: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
save_LIBS=$LIBS
LIBS="$LIBTERMCAP $LIBS"
echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
-echo "configure:2474: checking for readline in -lreadline" >&5
+echo "configure:2477: checking for readline in -lreadline" >&5
ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lreadline $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2482 "configure"
+#line 2485 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
readline()
; return 0; }
EOF
-if { (eval echo configure:2496: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking for cout in -lstdc++""... $ac_c" 1>&6
-echo "configure:2535: checking for cout in -lstdc++" >&5
+echo "configure:2538: checking for cout in -lstdc++" >&5
ac_lib_var=`echo stdc++'_'cout | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lstdc++ $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2543 "configure"
+#line 2546 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
cout()
; return 0; }
EOF
-if { (eval echo configure:2557: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2589: checking for $ac_hdr" >&5
+echo "configure:2592: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2594 "configure"
+#line 2597 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2599: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2602: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2630: checking for $ac_hdr" >&5
+echo "configure:2633: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2635 "configure"
+#line 2638 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2640: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2643: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2672: checking for $ac_hdr" >&5
+echo "configure:2675: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2677 "configure"
+#line 2680 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2682: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2685: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2709: checking for $ac_hdr" >&5
+echo "configure:2712: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2714 "configure"
+#line 2717 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2719: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2722: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
echo $ac_n "checking for doublefactorial in -lcln""... $ac_c" 1>&6
-echo "configure:2754: checking for doublefactorial in -lcln" >&5
+echo "configure:2757: checking for doublefactorial in -lcln" >&5
saved_LIBS="${LIBS}"
if eval "test \"`echo '$''{'ginac_cv_lib_cln_link'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
case "${ac_cv_header_cln_cln_h}" in
"yes")
cat > conftest.$ac_ext <<EOF
-#line 2763 "configure"
+#line 2766 "configure"
#include "confdefs.h"
#include <cln/cl_integer.h>
int main() {
doublefactorial(2);
; return 0; }
EOF
-if { (eval echo configure:2770: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ginac_cv_lib_cln_link="-lcln"
else
;;
*)
cat > conftest.$ac_ext <<EOF
-#line 2783 "configure"
+#line 2786 "configure"
#include "confdefs.h"
#include <cl_integer.h>
int main() {
doublefactorial(2);
; return 0; }
EOF
-if { (eval echo configure:2790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2793: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ginac_cv_lib_cln_link="-lcln"
else
# Extract the first word of "doxygen", so it can be a program name with args.
set dummy doxygen; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2831: checking for $ac_word" >&5
+echo "configure:2834: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_DOXYGEN'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "latex", so it can be a program name with args.
set dummy latex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2867: checking for $ac_word" >&5
+echo "configure:2870: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LATEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "makeindex", so it can be a program name with args.
set dummy makeindex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2903: checking for $ac_word" >&5
+echo "configure:2906: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MAKEINDEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "dvips", so it can be a program name with args.
set dummy dvips; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2939: checking for $ac_word" >&5
+echo "configure:2942: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_DVIPS'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "fig2dev", so it can be a program name with args.
set dummy fig2dev; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2975: checking for $ac_word" >&5
+echo "configure:2978: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_FIG2DEV'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cint", so it can be a program name with args.
set dummy cint; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3043: checking for $ac_word" >&5
+echo "configure:3046: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CINT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "makecint", so it can be a program name with args.
set dummy makecint; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3079: checking for $ac_word" >&5
+echo "configure:3082: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MAKECINT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
s%@build_os@%$build_os%g
s%@RANLIB@%$RANLIB%g
s%@CC@%$CC%g
-s%@LD@%$LD%g
-s%@NM@%$NM%g
s%@LN_S@%$LN_S%g
s%@LIBTOOL@%$LIBTOOL%g
s%@LEX@%$LEX%g
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
benchmark some predefined problems with different sizes and display the
CPU time used in seconds. Each individual test should return a message
@samp{passed}. This is mostly intended to be a QA-check if something
-was broken during development, not a sanity check of your system.
-Another intent is to allow people to fiddle around with optimization.
+was broken during development, not a sanity check of your system. Some
+of the tests in sections @emph{checks} and @emph{timings} may require
+insane amounts of memory and CPU time. Feel free to kill them if your
+machine catches fire. Another quite important intent is to allow people
+to fiddle around with optimization.
Generally, the top-level Makefile runs recursively to the
subdirectories. It is therfore safe to go into any subdirectory
@item
development tools: powerful development tools exist for C++, like fancy
editors (e.g. with automatic indentation and syntax highlighting),
-debuggers, visualization tools, documentation tools...
+debuggers, visualization tools, documentation generators...
@item
modularization: C++ programs can easily be split into modules by
@item
efficiency: often large parts of a program do not need symbolic
calculations at all. Why use large integers for loop variables or
-arbitrary precision arithmetics where double accuracy is sufficient?
-For pure symbolic applications, GiNaC is comparable in speed with other
-CAS.
+arbitrary precision arithmetics where @code{int} and @code{double} are
+sufficient? For pure symbolic applications, GiNaC is comparable in
+speed with other CAS.
@end itemize
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
return Pi;
else if (s == Catalan.name)
return Catalan;
- else if (s == gamma.name)
- return gamma;
+ else if (s == Euler.name)
+ return Euler;
else
throw (std::runtime_error("unknown constant '" + s + "' in archive"));
} else
/** Pi. (3.14159...) Diverts straight into CLN for evalf(). */
const constant Pi("Pi", PiEvalf);
-/** Catalan's constant. (0.91597...) Diverts straight into CLN for evalf(). */
-const constant gamma("gamma", gammaEvalf);
/** Euler's constant. (0.57721...) Sometimes called Euler-Mascheroni constant.
* Diverts straight into CLN for evalf(). */
+const constant Euler("Euler", EulerEvalf);
+/** Catalan's constant. (0.91597...) Diverts straight into CLN for evalf(). */
const constant Catalan("Catalan", CatalanEvalf);
#ifndef NO_NAMESPACE_GINAC
extern const constant some_constant;
extern const type_info & typeid_constant;
-// extern const numeric I;
extern const constant Pi;
extern const constant Catalan;
-extern const constant gamma;
+extern const constant Euler;
#ifndef NO_NAMESPACE_GINAC
} // namespace GiNaC
if (nx.is_integer()) {
// integer case
if (nx.is_positive()) {
- // psi(n) -> 1 + 1/2 +...+ 1/(n-1) - gamma
+ // psi(n) -> 1 + 1/2 +...+ 1/(n-1) - Euler
numeric rat(0);
for (numeric i(nx+_num_1()); i.is_positive(); --i)
rat += i.inverse();
- return rat-gamma;
+ return rat-Euler;
} else {
// for non-positive integers there is a pole:
throw (std::domain_error("psi_eval(): simple pole"));
if ((_num2()*nx).is_integer()) {
// half integer case
if (nx.is_positive()) {
- // psi((2m+1)/2) -> 2/(2m+1) + 2/2m +...+ 2/1 - gamma - 2log(2)
+ // psi((2m+1)/2) -> 2/(2m+1) + 2/2m +...+ 2/1 - Euler - 2log(2)
numeric rat(0);
for (numeric i((nx+_num_1())*_num2()); i.is_positive(); i-=_num2())
rat += _num2()*i.inverse();
- return rat-gamma-_ex2()*log(_ex2());
+ return rat-Euler-_ex2()*log(_ex2());
} else {
// use the recurrence relation
// psi(-m-1/2) == psi(-m-1/2+1) - 1 / (-m-1/2)
function::register_new(function_options("psi").
eval_func(psi2_eval).
evalf_func(psi2_evalf).
- derivative_func(psi2_deriv).
+ derivative_func(psi2_deriv).
series_func(psi2_series).
overloaded(2));
/* special values */
Pi yylval = Pi; return T_LITERAL;
-gamma yylval = gamma; return T_LITERAL;
+Euler yylval = Euler; return T_LITERAL;
Catalan yylval = Catalan; return T_LITERAL;
FAIL yylval = *new fail(); return T_LITERAL;
I yylval = I; return T_NUMBER;
#include "lst.h"
#include "utils.h"
#include "debugmsg.h"
+#include "power.h"
+#include "symbol.h"
#ifndef NO_NAMESPACE_GINAC
namespace GiNaC {
void matrix::copy(const matrix & other)
{
inherited::copy(other);
- row=other.row;
- col=other.col;
- m=other.m; // use STL's vector copying
+ row = other.row;
+ col = other.col;
+ m = other.m; // STL's vector copying invoked here
}
void matrix::destroy(bool call_parent)
m.resize(r*c, _ex0());
}
-// protected
+ // protected
/** Ctor from representation, for internal use only. */
matrix::matrix(unsigned r, unsigned c, const exvector & m2)
throw (std::logic_error("matrix::mul(): incompatible matrices"));
exvector prod(row*other.col);
- for (unsigned i=0; i<row; ++i) {
- for (unsigned j=0; j<other.col; ++j) {
- for (unsigned l=0; l<col; ++l) {
- prod[i*other.col+j] += m[i*col+l] * other.m[l*other.col+j];
- }
+
+ for (unsigned r1=0; r1<row; ++r1) {
+ for (unsigned c=0; c<col; ++c) {
+ if (m[r1*col+c].is_zero())
+ continue;
+ for (unsigned r2=0; r2<other.col; ++r2)
+ prod[r1*other.col+r2] += m[r1*col+c] * other.m[c*other.col+r2];
}
}
return matrix(row, other.col, prod);
}
}
- if (numeric_flag)
+ if (numeric_flag) // purely numeric matrix
return determinant_numeric();
- if (5*sparse_count<row*col) { // MAGIC, maybe 10 some bright day?
+ // Does anybody really know when a matrix is sparse?
+ if (4*sparse_count<row*col) { // < row/2 non-zero elements average in row
matrix M(*this);
- // int sign = M.division_free_elimination();
int sign = M.fraction_free_elimination();
+ if (!sign)
+ return _ex0();
if (normal_flag)
- return sign*M(row-1,col-1).normal();
+ return sign * M(row-1,col-1).normal();
else
- return sign*M(row-1,col-1).expand();
+ return sign * M(row-1,col-1).expand();
}
// Now come the minor expansion schemes. We always develop such that the
}
-/** Characteristic Polynomial. The characteristic polynomial of a matrix M is
- * defined as the determiant of (M - lambda * 1) where 1 stands for the unit
- * matrix of the same dimension as M. This method returns the characteristic
- * polynomial as a new expression.
+/** Characteristic Polynomial. Following mathematica notation the
+ * characteristic polynomial of a matrix M is defined as the determiant of
+ * (M - lambda * 1) where 1 stands for the unit matrix of the same dimension
+ * as M. Note that some CASs define it with a sign inside the determinant
+ * which gives rise to an overall sign if the dimension is odd. This method
+ * returns the characteristic polynomial collected in powers of lambda as a
+ * new expression.
*
* @return characteristic polynomial as new expression
* @exception logic_error (matrix not square)
* @see matrix::determinant() */
-ex matrix::charpoly(const ex & lambda) const
+ex matrix::charpoly(const symbol & lambda) const
{
if (row != col)
throw (std::logic_error("matrix::charpoly(): matrix not square"));
+ bool numeric_flag = true;
+ for (exvector::const_iterator r=m.begin(); r!=m.end(); ++r) {
+ if (!(*r).info(info_flags::numeric)) {
+ numeric_flag = false;
+ }
+ }
+
+ // The pure numeric case is traditionally rather common. Hence, it is
+ // trapped and we use Leverrier's algorithm which goes as row^3 for
+ // every coefficient. The expensive section is the matrix multiplication,
+ // maybe this can be sped up even more?
+ if (numeric_flag) {
+ matrix B(*this);
+ ex c = B.trace();
+ ex poly = power(lambda,row)-c*power(lambda,row-1);
+ for (unsigned i=1; i<row; ++i) {
+ for (unsigned j=0; j<row; ++j)
+ B.m[j*col+j] -= c;
+ B = this->mul(B);
+ c = B.trace()/ex(i+1);
+ poly -= c*power(lambda,row-i-1);
+ }
+ if (row%2)
+ return -poly;
+ else
+ return poly;
+ }
+
matrix M(*this);
for (unsigned r=0; r<col; ++r)
M.m[r*col+r] -= lambda;
- return (M.determinant());
+ return M.determinant().collect(lambda);
}
}
-/* Leverrier algorithm for large matrices having at least one symbolic entry.
- * This routine is only called internally by matrix::determinant(). The
- * algorithm is very bad for symbolic matrices since it returns expressions
- * that are quite hard to expand. */
-/*ex matrix::determinant_leverrier(const matrix & M)
- *{
- * GINAC_ASSERT(M.rows()==M.cols()); // cannot happen, just in case...
- *
- * matrix B(M);
- * matrix I(M.row, M.col);
- * ex c=B.trace();
- * for (unsigned i=1; i<M.row; ++i) {
- * for (unsigned j=0; j<M.row; ++j)
- * I.m[j*M.col+j] = c;
- * B = M.mul(B.sub(I));
- * c = B.trace()/ex(i+1);
- * }
- * if (M.row%2) {
- * return c;
- * } else {
- * return -c;
- * }
- *}*/
-
-
ex matrix::determinant_minor_sparse(void) const
{
// for small matrices the algorithm does not make any sense:
}
-/* Determinant using a simple Bareiss elimination scheme. Suited for
- * sparse matrices.
- *
- * @return the determinant as a new expression (in expanded form)
- * @see matrix::determinant() */
-ex matrix::determinant_bareiss(void) const
-{
- matrix M(*this);
- int sign = M.fraction_free_elimination();
- if (sign)
- return sign*M(row-1,col-1);
- else
- return _ex0();
-}
-
-
/** Determinant built by application of the full permutation group. This
* routine is only called internally by matrix::determinant().
* NOTE: it is probably inefficient in all cases and may be eliminated. */
matrix transpose(void) const;
ex determinant(void) const;
ex trace(void) const;
- ex charpoly(const ex & lambda) const;
+ ex charpoly(const symbol & lambda) const;
matrix inverse(void) const;
matrix fraction_free_elim(const matrix & vars, const matrix & v) const;
matrix solve(const matrix & vars, const matrix & rhs) const;
ex determinant_numeric(void) const;
ex determinant_minor_sparse(void) const;
ex determinant_minor_dense(void) const;
- ex determinant_bareiss(void) const;
ex determinant_perm(void) const;
int gauss_elimination(void);
int fraction_free_elimination(void);
inline ex trace(const matrix & m)
{ return m.trace(); }
-inline ex charpoly(const matrix & m, const ex & lambda)
+inline ex charpoly(const matrix & m, const symbol & lambda)
{ return m.charpoly(lambda); }
inline matrix inverse(const matrix & m)
/** Floating point evaluation of Euler's constant gamma. */
-ex gammaEvalf(void)
+ex EulerEvalf(void)
{
return numeric(::cl_eulerconst(cl_default_float_format)); // -> CLN
}
// numeric evaluation functions for class constant objects:
ex PiEvalf(void);
-ex gammaEvalf(void);
+ex EulerEvalf(void);
ex CatalanEvalf(void);
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
/* special values */
Pi yylval = Pi; return T_LITERAL;
-gamma yylval = gamma; return T_LITERAL;
+Euler yylval = Euler; return T_LITERAL;
Catalan yylval = Catalan; return T_LITERAL;
FAIL yylval = *new fail(); return T_LITERAL;
I yylval = I; return T_NUMBER;
GINACLIB_VERSION = @GINACLIB_VERSION@
GINSH_LIBS = @GINSH_LIBS@
LATEX = @LATEX@
-LD = @LD@
LEX = @LEX@
LIBGINACCINT = @LIBGINACCINT@
LIBTERMCAP = @LIBTERMCAP@
MAKECINT = @MAKECINT@
MAKEINDEX = @MAKEINDEX@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@for file in $(DISTFILES); do \
d=$(srcdir); \
if test -d $$d/$$file; then \
- cp -pr $$/$$file $(distdir)/$$file; \
+ cp -pr $$d/$$file $(distdir)/$$file; \
else \
test -f $(distdir)/$$file \
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \