]> www.ginac.de Git - ginac.git/blobdiff - ginac/clifford.cpp
* (time_fateman_expand.cpp): new file.
[ginac.git] / ginac / clifford.cpp
index 11f84d0c256e281ad915b3a5b09a7f388e2071fe..ecbfe9ea2594f7b32505f5706f3aade8b2a0171d 100644 (file)
@@ -3,7 +3,7 @@
  *  Implementation of GiNaC's clifford algebra (Dirac gamma) objects. */
 
 /*
- *  GiNaC Copyright (C) 1999-2001 Johannes Gutenberg University Mainz, Germany
+ *  GiNaC Copyright (C) 1999-2002 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
@@ -20,6 +20,9 @@
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
 
+#include <iostream>
+#include <stdexcept>
+
 #include "clifford.h"
 #include "ex.h"
 #include "idx.h"
@@ -34,8 +37,6 @@
 #include "archive.h"
 #include "utils.h"
 
-#include <stdexcept>
-
 namespace GiNaC {
 
 GINAC_IMPLEMENT_REGISTERED_CLASS(clifford, indexed)
@@ -457,7 +458,7 @@ ex dirac_trace(const ex & e, unsigned char rl, const ex & trONE)
                else
                        return _ex0;
 
-       } else if (is_ex_exactly_of_type(e, mul)) {
+       } else if (is_exactly_a<mul>(e)) {
 
                // Trace of product: pull out non-clifford factors
                ex prod = _ex1;
@@ -470,7 +471,7 @@ ex dirac_trace(const ex & e, unsigned char rl, const ex & trONE)
                }
                return prod;
 
-       } else if (is_ex_exactly_of_type(e, ncmul)) {
+       } else if (is_exactly_a<ncmul>(e)) {
 
                if (!is_clifford_tinfo(e.return_type_tinfo(), rl))
                        return _ex0;
@@ -577,7 +578,7 @@ ex canonicalize_clifford(const ex & e)
                ex lhs = srl.op(i).lhs();
                ex rhs = srl.op(i).rhs();
 
-               if (is_ex_exactly_of_type(rhs, ncmul)
+               if (is_exactly_a<ncmul>(rhs)
                 && rhs.return_type() == return_types::noncommutative
                 && is_clifford_tinfo(rhs.return_type_tinfo())) {