Spring 2009
Instructor Dr. Turgay Korkmaz
Homework 1
Due by Feb 6 (Friday), 2009 (5:00pm)
!!!! NO LATE HOMEWORK WILL BE ACCEPTED !!!
Total 50 points
HW Question:
Suppose
we have three complex numbers:
Z1
= a1 + b1*i,
Z2
= a2 + b2*i, and
Z3
= a3 + b3*i
We want to compute Z1*Z2*Z3.
Write a C program that solves this problem
and
prints the result as “R + I*i” .
Note: Z1*Z2
= (a1*a2 - b1*b2) + (a1*b2 + b1*a2)*i.
What to
return:
!!!! NO LATE HOMEWORK
WILL BE ACCEPTED !!!
1. Give me the
printout of your source program (e.g., hw1.c) and outputs for two different
runs.