Legacy Documentation

Mathematica® Teacher's Edition (2002)

This is documentation for an obsolete product.
Current products and services
 Documentation /  Mathematica Teacher's Edition /  Built-in Functions /  Numerical Computation /  Number Representation /

Complex

FilledSmallSquare Complex is the head used for complex numbers.

FilledSmallSquare You can enter a complex number in the form x + I y.
FilledSmallSquare _Complex can be used to stand for a complex number in a pattern.
FilledSmallSquare You have to use Re and Im to extract parts of Complex numbers.
FilledSmallSquare See The Mathematica Book on the web: Section 3.1.1.
FilledSmallSquare See also: Complexes, Real, Re, Im.

Further Examples

This number xx is only approximately real.

In[1]:=

Out[1]=

In[2]:=

Out[2]=

Chop gets rid of the small imaginary part.

In[3]:=

Out[3]=

In[4]:=

Out[4]=

This defines the rule rr that converts a complex number into a list made up of its real and imaginary parts.

In[5]:=

You can apply the rule to all the elements of a list.

In[6]:=

Out[6]=

In[7]:=

Out[7]=

In[8]:=