Richard Kreckel [Tue, 26 Jun 2001 21:19:34 +0000 (21:19 +0000)]
* Ctors of class numeric are not explicit any more. All built-in callers for
pseudofunctions are now templated and default to ex arguments which relaxes
the need for explicit ctors.
Christian Bauer [Sat, 23 Jun 2001 16:52:04 +0000 (16:52 +0000)]
- added find() (like has(), but returns list of all occurrences)
- added lst::sort() and lst::unique()
- status_flags::expanded is only taken into account when no expand options
are specified. This makes it possible to re-expand with other options.
- added expand_options::expand_function_args
- collect(foo, {}) doesn't crash any more
- introduced match_same_type() method which is slightly similar to
is_equal_same_type() but doesn't check subexpressions. Fixed a number of
match() bugs with this (e.g. a==b matched a!=b, and matrices with different
dimensions but the same number of elements could match). Only container
classes with additional member variables that have to be equal for a match
need to implement match_same_type().
Richard Kreckel [Tue, 19 Jun 2001 21:33:04 +0000 (21:33 +0000)]
* Fix a bitch of a bug where 1<I (and all other relationals) returned true.
This did not happen for the binary relational operators between numerics.
Now the behaviour is more consistent (throwing exceptions when the difference
becomes complex).
* Some regression tests were actually wrong in the light of this bug. :-(
Christian Bauer [Tue, 19 Jun 2001 19:50:02 +0000 (19:50 +0000)]
- The default implementations of evalf(), diff(), normal() and expand() use
map() where useful. This has the nice effect of having a more reasonable
default behaviour for container functions (most of the evalfchildren() etc.
stuff is gone).
- diff() works with non-commutative products (product rule) and no longer
bails on indexed objects.
- added decomp_rational()
- added sqrfree_parfrac() which doesn't yet work in the general case and
is unsupported
Richard Kreckel [Sat, 16 Jun 2001 18:38:00 +0000 (18:38 +0000)]
* Supplement some (now deprecated) macros by inlined template functions:
- ex_to_foobar(baz) -> ex_to<foobar>(baz).
* De-document is_of_type(obj, type) and document is_a<type>(obj).
* De-document ex_to_type(obj) and document ex_to<type>(obj) eliminating the
need to declare one's one inline converters in the mystring example.
Christian Bauer [Mon, 11 Jun 2001 23:48:43 +0000 (23:48 +0000)]
- Instead of just totally symmetric or antisymmetric, complex symmetries
can now be defined for indexed objects. Symmetries are described by a
tree of "symmetry" objects that is constructed with the sy_none(),
sy_symm(), sy_anti() and sy_cycl() functions. The symmetry of a function
with respect to its arguments can also be defined (this is currently
only used for the Beta function).
- color_trace() and dirac_trace() can be applied to a more general class
of expressions, e.g. using it on a relation will take the trace on both
sides etc.
- Generalized map() to take a function object instead of a function pointer.
This allows passing an arbitrary number of additional state to the
function being called.
- The unarchiving functinos find_bool(), find_unsigned() and find_string()
can take an additional "index" argument.
Christian Bauer [Sat, 9 Jun 2001 19:17:32 +0000 (19:17 +0000)]
- added lst::remove_first() and lst::remove_last()
- added symmetrize_cyclic()
- antisymmetrize() is slightly faster
- ensure_if_modifiable() clears the hash_calculated flag
Richard Kreckel [Wed, 6 Jun 2001 22:15:18 +0000 (22:15 +0000)]
- config.*: updated from FSF.
- Removed cint subdir for good because the new separate package seems to
work properly now (after some longish argument with makecint).
Richard Kreckel [Tue, 5 Jun 2001 13:55:01 +0000 (13:55 +0000)]
- ++version_major.
- added matrix::pow() to handle integer exponents with the least amount of
multiplications possible and...
- ...added power::evalm() to actually use it.
- classhierarchy.fig: add class wildcard.
- some cleanups.
Christian Bauer [Fri, 1 Jun 2001 22:50:00 +0000 (22:50 +0000)]
- in the output, list delimiters are now { } and matrix delimiters are [ ]
- added evalm() method for evaluating sums and products of matrices
- added map() method for applying a function to subexpressions
- power(noncommut, posint) automatically expands the product, removed ncpow()
Christian Bauer [Fri, 25 May 2001 20:51:35 +0000 (20:51 +0000)]
- removed debugging code in match()
- added ex::match(const ex & pattern) which doesn't take a list as second
argument
- expairseq::subs() substitutes in recombined pairs when the pattern is a
product or a power; this is necessary for things like subs(2*x^2,x^2==3)
because the first expression is mul(<x,2>,2) and only substituting in the
"rest" part of the expair is not enough
Christian Bauer [Mon, 21 May 2001 22:49:16 +0000 (22:49 +0000)]
- Clifford traces of many gammas are a lot faster now (especially with gamma5)
- new simplifications for color classes:
d.abc T.b T.c = 5/6 T.a
f.abc T.b T.c = 3/2 I T.a
- added indexed::has_dummy_index_for() member function
Christian Bauer [Sat, 19 May 2001 00:42:07 +0000 (00:42 +0000)]
- dummy index renamer didn't account for internal dummy indices of objects
in products; a~mu.mu-a~nu.nu gets simplified to 0 now
- made a little more use of STL facilities for exvectors, especially in the
indexed stuff; append_exvector_to_exvector() and index_set_difference() are
gone and utils.h defines the functors ex_is_less and ex_is_equal
Christian Bauer [Fri, 18 May 2001 00:53:07 +0000 (00:53 +0000)]
- simplify_indexed() renames dummy indices so, e.g., "a.i*a.i+a.j*a.j" gets
simplified to "2*a.i*a.i" (or 2*a.j*a.j, you can't know which one)
- fixed possible crash when calling subs() on expressions with non-commutative
products
- added canonicalize_clifford()
Richard Kreckel [Fri, 11 May 2001 19:43:31 +0000 (19:43 +0000)]
- Renamed our detected libreadline version in order to avoid conflicts
with Chat Rameys (still broken) macros and future CPP definitions in
libreadline's headers. Oh what a pain in the ass!