X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=blobdiff_plain;f=ginac%2Fmul.cpp;h=15dee661c735f831789bb5e1df634621634f009c;hp=3f2d5cdbfc06f8cade28ce9dc8b4ade995a68caa;hb=1c65b3c7d04ab7123bbc7fc9e420c8bd484927a1;hpb=6eb7dee7ea9e83d3e0599aec9ab7c6084a47b71c diff --git a/ginac/mul.cpp b/ginac/mul.cpp index 3f2d5cdb..15dee661 100644 --- a/ginac/mul.cpp +++ b/ginac/mul.cpp @@ -3,7 +3,7 @@ * Implementation of GiNaC's products of expressions. */ /* - * GiNaC Copyright (C) 1999-2015 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2016 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 @@ -292,13 +292,6 @@ bool mul::info(unsigned inf) const return true; return overall_coeff.info(inf); } - case info_flags::algebraic: { - for (auto & it : seq) { - if (recombine_pair_to_ex(it).info(inf)) - return true; - } - return false; - } case info_flags::positive: case info_flags::negative: { if ((inf==info_flags::positive) && (flags & status_flags::is_positive)) @@ -581,22 +574,14 @@ ex mul::eval() const return this->hold(); } -ex mul::evalf(int level) const +ex mul::evalf() const { - if (level==1) - return mul(seq, overall_coeff); - - if (level==-max_recursion_level) - throw(std::runtime_error("max recursion level reached")); - epvector s; s.reserve(seq.size()); - --level; - for (auto & it : seq) { - s.push_back(expair(it.rest.evalf(level), it.coeff)); - } - return dynallocate(std::move(s), overall_coeff.evalf(level)); + for (auto & it : seq) + s.push_back(expair(it.rest.evalf(), it.coeff)); + return dynallocate(std::move(s), overall_coeff.evalf()); } void mul::find_real_imag(ex & rp, ex & ip) const