X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?a=blobdiff_plain;f=check%2Ftime_dennyfliegner.cpp;h=4936a591619d553906964991743742bf01ff405d;hb=62168ea93d23c81172ad07f9ec2f7044d1570681;hp=b14d1b49be410e51bfa9f4231e3cc9d9c69b245c;hpb=5b44febe31956b36b62cd3650f7c5249bbe8100c;p=ginac.git diff --git a/check/time_dennyfliegner.cpp b/check/time_dennyfliegner.cpp index b14d1b49..4936a591 100644 --- a/check/time_dennyfliegner.cpp +++ b/check/time_dennyfliegner.cpp @@ -7,7 +7,7 @@ * after which e should be just a1^2. */ /* - * GiNaC Copyright (C) 1999-2005 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2015 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 @@ -24,7 +24,14 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#include "times.h" +#include "ginac.h" +#include "timer.h" +using namespace GiNaC; + +#include +#include +#include +using namespace std; static unsigned expand_subs(unsigned size) { @@ -58,7 +65,6 @@ unsigned time_dennyfliegner() unsigned result = 0; cout << "timing commutative expansion and substitution" << flush; - clog << "-------commutative expansion and substitution:" << endl; vector sizes; vector times; @@ -76,12 +82,6 @@ unsigned time_dennyfliegner() cout << '.' << flush; } - if (!result) { - cout << " passed "; - clog << "(no output)" << endl; - } else { - cout << " failed "; - } // print the report: cout << endl << " size: "; for (vector::iterator i=sizes.begin(); i!=sizes.end(); ++i) @@ -93,3 +93,12 @@ unsigned time_dennyfliegner() return result; } + +extern void randomify_symbol_serials(); + +int main(int argc, char** argv) +{ + randomify_symbol_serials(); + cout << setprecision(2) << showpoint; + return time_dennyfliegner(); +}