Graphics Reference
In-Depth Information
Specific functions for the real and imaginary part
Function
Meaning
abs (Z)
Module of the complex Z
angle (Z)
Argument of the complex Z
conj (Z)
Complex conjugate of Z
real (Z)
Real part of the complex Z
imag (Z)
Imaginary part of the complex Z
Below are some examples of operations with complex numbers.
>> round(1.5-3.4i)
ans =
2 - 3i
>> real(i^i)
ans =
0.2079
>> (2+2i)^2/(-3-3*sqrt(3)*i)^90
Ans =
0502e-085 - 1 + 7. 4042e-070i
>> sin(1+i)
Ans =
1.2985. 6350i
A.11 Operators
MATLAB has operators to perform calculations involving arithmetic, logical, relational, and conditional operations.
A.11.1 Arithmetic Operators
There are two types of arithmetic operations in MATLAB: matrix arithmetic operations, which are governed by
the rules of linear algebra, and arithmetic operations with vectors, which are performed element to element. The
operators involved are presented in the following table.
 
 
Search WWH ::




Custom Search