Sine/Cosine EquationsDate: 10/23/96 at 16:54:51 From: Tyler Durrett Subject: Sine/Cosine equations Hi. Is there any equation for sine or cosine? If so, what are they? Thanks. Tyler Durrett Date: 10/24/96 at 20:17:21 From: Doctor Tom Subject: Re: Sine/Cosine equations Do you mean to calculate them from scratch? Sure. If x is the angle in radians (3.14159265... radians = 180 degrees), then here's a formula for sin(x) and cos(x): sin(x) = x - x^3/3! + x^5/5! - x^7/7! + x^9/9! - ... cos(x) = 1 - x^2/2! + x^4/4! - x^6/6! + x^8/8! - ... 7! means "7 factorial", or 7x6x5x4x3x2x1, and so on. You have to add together an infinite number of terms in the formulas above to get the exact values of sin and cos, but in practical situations, the terms get small very rapidly, and if you use just the first 5 or 6 terms you will have a very accurate result. For reasons of numerical stability and for slightly better accuracy, computers use different formulas, but those formulas only work for the numbers a computer can represent. My formulas above can be used to get as exact a value as you want, simply by using enough terms. So if you wanted to find the sin of 30 degrees, that's 1/6 of pi, so x = pi/6. Plug that into the sin(x) formula and work out as many terms as you need. -Doctor Tom, The Math Forum Check out our web site! http://mathforum.org/dr.math/ |
Search the Dr. Math Library: |
[Privacy Policy] [Terms of Use]
Ask Dr. Math^{TM}
© 1994-2013 The Math Forum
http://mathforum.org/dr.math/