Christian Bauer [Wed, 5 Apr 2000 19:30:47 +0000 (19:30 +0000)]
- changed comment starter from # to //
- implemented #b, #o, #x and #nR prefixes for binary, octal, hexadecimal, and
base-n integers
- added iprint() command for decimal, octal, and hexadecimal output of integers
- updated man page
Christian Bauer [Fri, 31 Mar 2000 03:48:28 +0000 (03:48 +0000)]
- the ex stream >> operator is gone
- added a new ex constructor ex(string, ex) instead; use as follows:
symbol x("x"), y("y");
ex e("Pi*(4*x^2+y)^10", lst(x, y));
or, for interactive input:
symbol x("x");
string s;
cout << "Input something (may contain 'x'): ";
getline(cin, s);
try {
e = ex(s, lst(x));
cout << "You entered " << e << endl;
cout << "e.diff(x) = " << e.diff(x) << endl;
} catch (exception &c) {
cerr << c.what() << endl;
}
- symbols not specified in the list in the second argument to ex(string, ex)
but encountered in the input expression will throw an exception
Richard Kreckel [Thu, 30 Mar 2000 00:09:13 +0000 (00:09 +0000)]
- dramatic speedup for characteristic polynomials of numerical matrices.
- 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.
Christian Bauer [Wed, 29 Mar 2000 20:20:12 +0000 (20:20 +0000)]
- expressions can now be read from streams; the input expression can contain
a list of predefined symbols to be used, before reading (and overwriting)
the expression, e.g:
symbol x("x"), y("y");
e = lst(x, y);
cout << "Enter an expression containing 'x' and 'y': ";
try {
cin >> e;
} catch (exception &e) {
cerr << e.what() << endl;
}
cout << "You entered " << e << endl;
cout << "de/dx = " << e.diff(x) << endl;
cout << "de/dy = " << e.diff(y) << endl;
Christian Bauer [Tue, 28 Mar 2000 18:58:57 +0000 (18:58 +0000)]
- remembering in divide_in_z() turned off (will eventually have to be replaced
by the new remembering mechanism in remember.cpp)
- new #define options at top of source:
USE_TRIAL_DIVISION makes divide_in_z() use trial division and Newton
interpolation instead of recursive polynomial division (only useful
for very large problems)
STATISTICS enables some statistical output at the end of the program
- gcd(numeric, numeric) is now handled earlier; this should speed up normal()
- added new heuristic: gcd(p^n, p^m) with p a polynomial now immediately
returns p^abs(n-m)
- if GCD is 1, cofactors are returned unexpanded
Richard Kreckel [Thu, 23 Mar 2000 16:50:17 +0000 (16:50 +0000)]
- We now write f(x).series(x==3,5) instead of f(x).series(x,3,5) and
f(x).series(x,4) instead of f(x).series(x,0,4). We also don't allow
default arguments any more.
Christian Bauer [Mon, 13 Mar 2000 19:21:20 +0000 (19:21 +0000)]
- ex::series() catches and re-throws exceptions happening during expansion
(almost always caused by expansion of unhandled poles)
- series(log(x),x) now returns log(x) instead of an error
Richard Kreckel [Mon, 13 Mar 2000 17:14:21 +0000 (17:14 +0000)]
- Two new timimgs that are interesting for optimizing.
- Readjusted some parameters.
- Cleaned up syntax in everything involving matrices to reflect the
policy: "normal if in field, expand otherwise". (It makes many things
much clearer.)
Richard Kreckel [Wed, 1 Mar 2000 21:32:45 +0000 (21:32 +0000)]
- Fixed a logic error in numeric::info().
- Maybe added another world record: an extremely fast fibonacci routine
(a nonrecursive variation of a method suggested by B. Haible).
Richard Kreckel [Tue, 29 Feb 2000 17:28:13 +0000 (17:28 +0000)]
- Completely restructured the checks in subdir check/.
- Optimized Laplace expansion of determinants to not compute anything more
than once.
- Moved int permutation_sign(vector<T> s) from matrix.cpp to utils.h.
- A handful of other fixes assiciated with the above.
Alexander Frink [Mon, 21 Feb 2000 23:11:41 +0000 (23:11 +0000)]
container.pl: can now generate constructors for an arbitary number
of arguments
function.pl: new concept for specifying options for functions,
take a look at the function_options class
first experimental support for remembering functions
IMPORTANT: the syntax of the macro REGISTER_FUNCTION() has
changed incompatibly (see inifcns.cpp for an example)
flags.h: flags for remembering strategies (lru, lfu,...)
inifcns*.cpp: use the new REGISTER_FUNCTION() macro syntax
numeric.h/cpp: hashing for numbers using CLN's cl_equal_hashcode()
seems to give increased performance
simp_lor.h: simplify_simp_lor can be called without scalar products list
structure.pl: bug fix in regular expression
normal.cpp: bug fix, a_numeric.compare(_ex0)
Christian Bauer [Thu, 10 Feb 2000 21:25:38 +0000 (21:25 +0000)]
- normal() now internally keeps numerator and denominator separated and
doesn't combine them to a fraction until the very end. All implementations
of basic::normal() now return a 2-component lst {num, den} instead of a
simple expression.
- dropped status_flags::normal_form
- ex::numer() and ex::denom() didn't work correctly on numerics
- lcm(a, b) with a and b being a numeric returned the GCD of a and b (*argh*)