mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-29 19:49:58 +02:00
[poincare] Clean: delete old code that was forgotten
Change-Id: If3d0d0ee794f6993ea1d05aa61ce42ad12f4cb79
This commit is contained in:
@@ -240,12 +240,6 @@ Expression * Power::shallowReduce(Context& context, AngleUnit angleUnit) {
|
||||
}
|
||||
// p^q with p, q rationals
|
||||
if (!letPowerAtRoot && operand(1)->type() == Type::Rational) {
|
||||
double p = a->approximateToScalar<double>(context, angleUnit);
|
||||
double q = operand(1)->approximateToScalar<double>(context, angleUnit);
|
||||
double approx = std::pow(std::fabs(p), std::fabs(q));
|
||||
if (std::isinf(approx) || std::isnan(approx) || std::fabs(approx)> 1E100) {
|
||||
return this;
|
||||
}
|
||||
Rational * exp = static_cast<Rational *>(editableOperand(1));
|
||||
/* First, we check that the simplification does not involve too complex power
|
||||
* of integers (ie 3^999) that would take too much time to compute. */
|
||||
|
||||
Reference in New Issue
Block a user