]> www.ginac.de Git - ginac.git/blobdiff - ginac/ex.h
epsilon tensor contractions evaluate to metric tensors instead of deltas,
[ginac.git] / ginac / ex.h
index b1b639bda22b77374fe623d3e28f812a5e94d4bf..88f4e2ef40fd439e5afa349f57a3fe28dc60ebe3 100644 (file)
@@ -70,12 +70,6 @@ public:
         *  symbols and other parser errors will throw an exception. */
        ex(const std::string &s, const ex &l);
        
-       // functions overriding virtual functions from bases classes
-       // none
-       
-       // new virtual functions which can be overridden by derived classes
-       // none
-
        // non-virtual functions in this class
 public:
        void swap(ex & other);
@@ -86,9 +80,10 @@ public:
        bool info(unsigned inf) const { return bp->info(inf); }
        unsigned nops() const { return bp->nops(); }
        ex expand(unsigned options=0) const;
-       bool has(const ex & other) const { return bp->has(other); }
+       bool has(const ex & pattern) const { return bp->has(pattern); }
        ex map(map_function & f) const { return bp->map(f); }
        ex map(ex (*f)(const ex & e)) const;
+       bool find(const ex & pattern, lst & found) const;
        int degree(const ex & s) const { return bp->degree(s); }
        int ldegree(const ex & s) const { return bp->ldegree(s); }
        ex coeff(const ex & s, int n = 1) const { return bp->coeff(s, n); }
@@ -346,8 +341,11 @@ inline unsigned nops(const ex & thisex)
 inline ex expand(const ex & thisex, unsigned options = 0)
 { return thisex.expand(options); }
 
-inline bool has(const ex & thisex, const ex & other)
-{ return thisex.has(other); }
+inline bool has(const ex & thisex, const ex & pattern)
+{ return thisex.has(pattern); }
+
+inline bool find(const ex & thisex, const ex & pattern, lst & found)
+{ return thisex.find(pattern, found); }
 
 inline int degree(const ex & thisex, const ex & s)
 { return thisex.degree(s); }