It is perfectly fine to not have any functions in this project. The point of the project is to practice nested for loops. If you want to use functions that is fine, but it is not necessary to get a 100.
In this section, we have some questions and comments from the students. As usual, names have been withheld to protect the innocent and the questions have been edited for spelling and grammar.
For example, in my answer sin(360)= -0.0932502, but yours is -0.0932458.
I understand how to get everything working except how to alternate the + and - signs in the formula. Could you give me just a few hints on how to go about it?
Thank You, Clueless.
P.S Is this really anonymous mail or you have a sneaky way of finding out who the author is?
Another HINT: -1 * -1 * -1 = -1.
I have no interest in "exposing" people who send me anonymous mail. Ever since Sister Jacinta asked us to write down what we really think of her music class in 6th grade, I have a great respect for the value of keeping anonymous messages anonymous. (Yes, I did. Yes, they made me "apologize".)
Now, if it bothers you that it might be possible for someone to say a message is sent anonymously without it truly being anonymous, you can always use Netscape from a Macintosh or PC and not tell the machine who you are. If the machine doesn't know who you are, it can't tell who sent the message. The most that can be gathered from the message is where it was sent from and when.
Well, if you are really worried that someone is recording who is using which machine and when, you can always type up a note and shove it under my door when nobody is watching. Better yet, send a friend to shove it under my door.
Sincerely, Haven't A Clue
Traditionally, people have used degrees to measure an angle. We all know that 90 degrees is a right angle, 180 degrees is a straight line, and 360 degrees turns you completely around. Why do we use 0 through 360? Well, there are historical reasons for this, but it is certainly not the only way. In fact, using degrees is not very convenient if you want to calculate the values of trigonometric functions (sine, cosine, tangent, etc).
An alternate way of measuring an angle, called radians, puts a value of PI/2 (roughly 1.57) on a right angle. It's the same right angle as before, we are just giving it a different number. It's like saying 1.6 kilometers is equal to 1 mile. Same distance, different number. So, an angle with 180 degrees has PI radians (roughly 3.14). An angle with 360 degrees has 2*PI radians (roughly 6.28), and so forth. The clincher is that the formula (Taylor series) for sin(x) given in the handout works when x is the measurement of the angle in radians. So to compute the value of sin(360 degrees), you should use the formula to find the value of sin(2*PI radians).
So, the formula for converting degrees to radians is (as written on the handout)
radians = PI * degrees/180This allows you to convert degrees to radians for all angles, no matter if they are multiples of fifteen. For example, 33 degrees, is roughly 3.14 * 33 /180 which gives you around 0.576 radians.