]> www.ginac.de Git - ginac.git/blobdiff - check/time_toeplitz.cpp
match() (find()): use exmap (exset) to store matched subexpressions.
[ginac.git] / check / time_toeplitz.cpp
index 9bf569ab7d6b35ad7c8f00a5a7b080aaf90b094b..813e5214fd741468156a2bfd2ee4da36d897c626 100644 (file)
@@ -6,7 +6,7 @@
  */
 
 /*
- *  GiNaC Copyright (C) 1999-2007 Johannes Gutenberg University Mainz, Germany
+ *  GiNaC Copyright (C) 1999-2008 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
  *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#include "times.h"
+#include <iostream>
+#include <vector>
+#include "ginac.h"
+#include "timer.h"
+using namespace std;
+using namespace GiNaC;
 
 static unsigned toeplitz_det(unsigned size)
 {
@@ -69,7 +74,6 @@ unsigned time_toeplitz()
        unsigned result = 0;
 
        cout << "timing determinant of polyvariate symbolic Toeplitz matrices" << flush;
-       clog << "-------determinant of polyvariate symbolic Toeplitz matrices:" << endl;
 
        vector<unsigned> sizes;
        vector<double> times;
@@ -93,12 +97,6 @@ unsigned time_toeplitz()
                cout << '.' << flush;
        }
 
-       if (!result) {
-               cout << " passed ";
-               clog << "(no output)" << endl;
-       } else {
-               cout << " failed ";
-       }
        // print the report:
        cout << endl << "       dim:   ";
        for (vector<unsigned>::iterator i=sizes.begin(); i!=sizes.end(); ++i)
@@ -110,3 +108,12 @@ unsigned time_toeplitz()
 
        return result;
 }
+
+extern void randomify_symbol_serials();
+
+int main(int argc, char** argv)
+{
+       randomify_symbol_serials();
+       cout << setprecision(2) << showpoint;
+       return time_toeplitz();
+}