Field of complex numbers
MuPAD® notebooks are not recommended. Use MATLAB® live scripts instead.
MATLAB live scripts support most MuPAD functionality, though there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.
Dom::Complex(x
)
Dom::Complex
is the domain of complex constants
represented by expressions of type DOM_INT
, DOM_RAT
, DOM_FLOAT
or DOM_COMPLEX
.
An expression of type DOM_EXPR
is considered a
complex number if it is of type Type::Arithmetical
and if it contains
only indeterminates which are of type Type::ConstantIdents
or if it contains
no indeterminates, cf. Example 2.
Dom::Complex
is of category Cat::Field
due to pragmatism.
This domain actually is not a field because bool(1.0 = float(3)
/ float(3))
returns FALSE
, for example.
Elements of Dom::Complex
are usually not
created explicitly. However, if one creates elements using the usual
syntax, it is checked whether the input expression can be converted
to a number. This means Dom::Complex
is a facade
domain which creates elements of domain type DOM_INT
, DOM_RAT
, DOM_FLOAT
, DOM_COMPLEX
or DOM_EXPR
.
Dom::Complex
has no normal representation,
because 0
and 0.0
both represent
the zero.
Viewed as a differential ring, Dom::Complex
is
trivial. It only contains constants.
Dom::Complex
has the domain Dom::BaseDomain
as its
super domain, i.e., it inherits each method which is defined by Dom::BaseDomain
and
not reimplemented by Dom::Complex
. Methods described
below are reimplemented by Dom::Complex
.
Ax::systemRep
, Ax::efficientOperation
("_divide")
, Ax::efficientOperation
("_mult")
, Ax::efficientOperation
("_invert")
Creating some complex numbers using Dom::Complex
:
Dom::Complex(2/3)
Dom::Complex(2/3 + 4*I)
It's also possible to use expressions or constants for creating
an element of Dom::Complex
:
Dom::Complex(PI)
Dom::Complex(sin(2))
Dom::Complex(sin(2/3*I) + 3)
If the expression cannot be converted to an element of Dom::Complex
we
will get an error message:
Dom::Complex(sin(x))
Error: The arguments are invalid. [Dom::Complex::new]

An expression of type 
"characteristic"  the characteristic of this field is 0. 
"one"  the unit element; it equals 
"zero"  The zero element; it equals 