24 Expression * e = Expression::shallowReduce(context, angleUnit);
28 #if MATRIX_EXACT_REDUCING 36 invIndex->shallowReduce(context, angleUnit);
38 return p->shallowReduce(context, angleUnit);
41 ExpressionLayout * NthRoot::privateCreateLayout(
PrintFloat::Mode floatDisplayMode, ComplexFormat complexFormat)
const {
48 Complex<T> NthRoot::compute(
const Complex<T>
c,
const Complex<T> d) {
49 if (
c.a() >= 0 &&
c.b() == 0 && d.b() == 0) {
57 Expression * NthRoot::templatedApproximate(Context& context, AngleUnit angleUnit)
const {
62 Complex<T> * basec =
static_cast<Complex<T> *
>(base);
63 Complex<T> * indexc =
static_cast<Complex<T> *
>(index);
64 result = compute(*basec, *indexc);
68 return new Complex<T>(result);
Type type() const override
Expression * replaceWith(Expression *newOperand, bool deleteAfterReplace=true)
Expression * approximate(Context &context, AngleUnit angleUnit=AngleUnit::Default) const
static Complex< T > compute(const Complex< T > c, const Complex< T > d)
const Expression * m_operands[T]
ExpressionLayout * createLayout(PrintFloat::Mode floatDisplayMode=PrintFloat::Mode::Default, ComplexFormat complexFormat=ComplexFormat::Default) const
static Complex< T > Float(T x)
Expression * clone() const override
static Complex< T > compute(const Complex< T > c, const Complex< T > d)
const Expression * operand(int i) const