X-Git-Url: https://ginac.de/ginac.git//ginac.git?a=blobdiff_plain;ds=sidebyside;f=ginac%2Fstructure.h;h=1932c0f357c293c8a1ae1331be237eaba0ac61d2;hb=695f6ae955ec530cded8f21efd5569df39447f76;hp=dbe97d4226740060ef3a329a5b8913534ef2a117;hpb=69cf20e8ee183eadfe457af33dc88a9f568038e8;p=ginac.git diff --git a/ginac/structure.h b/ginac/structure.h index dbe97d42..1932c0f3 100644 --- a/ginac/structure.h +++ b/ginac/structure.h @@ -3,7 +3,7 @@ * Wrapper template for making GiNaC classes out of C++ structures. */ /* - * GiNaC Copyright (C) 1999-2003 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2005 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 @@ -26,6 +26,7 @@ #include #include "ex.h" +#include "ncmul.h" #include "operators.h" #include "print.h" @@ -133,7 +134,7 @@ public: ex evalf(int level = 0) const { return inherited::evalf(level); } ex evalm() const { return inherited::evalm(); } protected: - ex eval_ncmul(const exvector & v) const { return this->hold_ncmul(v); } + ex eval_ncmul(const exvector & v) const { return hold_ncmul(v); } public: ex eval_indexed(const basic & i) const { return i.hold(); } @@ -194,7 +195,7 @@ public: // indexed objects exvector get_free_indices() const { return exvector(); } ex add_indexed(const ex & self, const ex & other) const { return self + other; } - ex scalar_mul_indexed(const ex & self, const numeric & other) const { return self * other; } + ex scalar_mul_indexed(const ex & self, const numeric & other) const { return self * ex(other); } bool contract_with(exvector::iterator self, exvector::iterator other, exvector & v) const { return false; } // noncommutativity