12345
DESCRIPTION
mabdheuiTRANSCRIPT
1. The imaginary unit is denoted byi(lower-case "eye") in MATLAB. So, to assign5+3itoa, enter
a = 5 + 3*i
Enter the following complex numbers in your worksheet: a = 5 + 3i b = 2 - 4i c = - 3 + i d = - 2 - 4i
2. Enter the following lines of MATLAB code, and describe what each of theMATLABcommands does. Check by trying with a number different froma. real(a) imag(a) abs(a) conj(a)
3. Theanglefunction needs special attention. Enter each of the following: angle(a) angle(b) angle(c) angle(d)What is the range of theanglefunction? Describe carefully what theanglefunction does.
4. It is often useful to consider complex numbers in their polar form (Theta,R). The built-in MATLAB function "cart2pol" converts cartesian coordinates (x,y) to polar coordinates (Theta,R).
Let's convert the complex numberafrom above to its polar form. Enter:
[Theta_a, R_a] = cart2pol( real(a), imag(a) )
Repeat this forbto get[Theta_b, R_b].
5. The built-in MATLAB function "pol2cart" converts polar coordinates (Theta,R) to cartesian coordinates (x,y). Let's see if we can recover our originala. Enter:
[x, y] = pol2cart(Theta_a, R_a);new_a = x + y*i
Repeat this for[Theta_b, R_b]to get the originalbback.
6. Calculate the polar form ofa*b. How is the polar form of the product related to the polar forms of the factors?