Class ComplexDouble

Inheritance Relationships

Base Type

Class Documentation

class SymEngine::ComplexDouble : public SymEngine::ComplexBase

Complex Double Class to hold std::complex<double> values.

Public Functions

ComplexDouble(std::complex<double> i)

Constructor of ComplexDouble class.

hash_t __hash__() const

Return

size of the hash

bool __eq__(const Basic &o) const

Equality comparator

Return

whether the 2 objects are equal

Parameters
  • o: - Object to be compared with

int compare(const Basic &o) const

Returns -1, 0, 1 for this < o, this == o, this > o. This method is used when you want to sort things like x+y+z into canonical order. This function assumes that o is the same type as this. Use __cmp__ if you want general comparison.

RCP<const Number> real_part() const

Get the real part of the complex number.

RCP<const Number> imaginary_part() const

Get the imaginary part of the complex number.

RCP<const Basic> conjugate() const

Get the conjugate of the complex number.

bool is_positive() const

Return

false

bool is_negative() const

Return

false

bool is_complex() const

Return

true

std::complex<double> as_complex_double() const

Return

self as a double

bool is_exact() const

Return

false

Evaluate &get_eval() const

Get Evaluate singleton to evaluate numerically.

bool is_zero() const

Return

true if equal to 0

bool is_one() const

Return

false

bool is_minus_one() const

Return

false

RCP<const Number> addcomp(const Integer &other) const

Add ComplexDoubles

Parameters

RCP<const Number> addcomp(const Rational &other) const

Add ComplexDoubles

Parameters

RCP<const Number> addcomp(const Complex &other) const

Add ComplexDoubles

Parameters

RCP<const Number> addcomp(const RealDouble &other) const

Add ComplexDoubles

Parameters

RCP<const Number> addcomp(const ComplexDouble &other) const

Add ComplexDoubles

Parameters

RCP<const Number> add(const Number &other) const

Converts the param other appropriately and then calls addcomp

RCP<const Number> subcomp(const Integer &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> subcomp(const Rational &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> subcomp(const Complex &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> subcomp(const RealDouble &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> subcomp(const ComplexDouble &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> sub(const Number &other) const

Converts the param other appropriately and then calls subcomp

RCP<const Number> rsubcomp(const Integer &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> rsubcomp(const Rational &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> rsubcomp(const Complex &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> rsubcomp(const RealDouble &other) const

Subtract ComplexDoubles

Parameters

RCP<const Number> rsub(const Number &other) const

Converts the param other appropriately and then calls subcomp

RCP<const Number> mulcomp(const Integer &other) const

Multiply ComplexDoubles

Parameters

RCP<const Number> mulcomp(const Rational &other) const

Multiply ComplexDoubles

Parameters

RCP<const Number> mulcomp(const Complex &other) const

Multiply ComplexDoubles

Parameters

RCP<const Number> mulcomp(const RealDouble &other) const

Multiply ComplexDoubles

Parameters

RCP<const Number> mulcomp(const ComplexDouble &other) const

Multiply ComplexDoubles

Parameters

RCP<const Number> mul(const Number &other) const

Converts the param other appropriately and then calls mulcomp

RCP<const Number> divcomp(const Integer &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> divcomp(const Rational &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> divcomp(const Complex &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> divcomp(const RealDouble &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> divcomp(const ComplexDouble &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> div(const Number &other) const

Converts the param other appropriately and then calls divcomp

RCP<const Number> rdivcomp(const Integer &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> rdivcomp(const Rational &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> rdivcomp(const Complex &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> rdivcomp(const RealDouble &other) const

Divide ComplexDoubles

Parameters

RCP<const Number> rdiv(const Number &other) const

Converts the param other appropriately and then calls divcomp

RCP<const Number> powcomp(const Integer &other) const

Raise ComplexDouble to power other

Parameters

RCP<const Number> powcomp(const Rational &other) const

Raise ComplexDouble to power other

Parameters

RCP<const Number> powcomp(const Complex &other) const

Raise ComplexDouble to power other

Parameters

RCP<const Number> powcomp(const RealDouble &other) const

Raise ComplexDouble to power other

Parameters

RCP<const Number> powcomp(const ComplexDouble &other) const

Raise ComplexDouble to power other

Parameters

RCP<const Number> pow(const Number &other) const

Converts the param other appropriately and then calls powcomp

RCP<const Number> rpowcomp(const Integer &other) const

Raise other to power ComplexDouble

Parameters

RCP<const Number> rpowcomp(const Rational &other) const

Raise other to power ComplexDouble

Parameters

RCP<const Number> rpowcomp(const Complex &other) const

Raise other to power ComplexDouble

Parameters

RCP<const Number> rpowcomp(const RealDouble &other) const

Raise other to power ComplexDouble

Parameters

RCP<const Number> rpow(const Number &other) const

Converts the param other appropriately and then calls powcomp

Public Members

std::complex<double> i