Complex numbers
Complex numbers have 2 distinct parts: a real part and an imaginary part. In general a complex number z has the formwhere x, y are real numbers. The real part of z, written Re{z}, is x. The imaginary part of z, written Im{z}, is y. Notice that, confusingly, the imaginary part is a real number. The imaginary part times i is an imaginary number. So
The set of complex numbers, therefore, is defined by
Every real number is in Complex, because x = x + i0; and every imaginary number iy is in Complex, because iy = 0 + iy.
Two complex numbers z1 = x1 + iy1 and z2 = x2 + iy2 are equal if and only if their real parts are equal and their imaginary parts are equal, that is, z1 = z2 if and only ifIm{z1} = Im{z2}.