Sign in to follow this  
danielgamedev

The sum of the angle formulas yields

Recommended Posts

Hi guys, The parametric representation of the points on a circle with radius r . Mathematical Elements For Computer Graphics pg 216 reads: Noting that a circle is completely swept out of range of the parameter @ ( THETA ) from 0 to 2PI, and assuming that a fixed number of uniformly spaced points on the circumference are calculated, then DEL@ ( DELTA THETA ), the parameter increment between points, is a constant. The Cartesian coordinates of any point on an origin circle are then: x^i+1 = r cos( @^i + DEL@ ) y^i+1 = r sin( @^i + DEL@ ) where @^i is the value of the parameter that yields the point at x^i, y^i HERE IS WHERE I GET LOST... Using the sum of the angles formulas yields <-????? x^i+1 = r ( cos@^i cosDEL@ - sin@^i sinDEL@ ) y^i+1 = r ( cos@^i sinDEL@ - cosDEL@ sin@^i ) I don't get why and how this " x^i+1 = r cos( @^i + DEL@ ) " turns to this " x^i+1 = r ( cos@^i cosDEL@ - sin@^i sinDEL@ ) " Thank you in advance, DG

Share this post


Link to post
Share on other sites
It took me a while to decipher the equations (representing maths in plain text is such a pain, isn't it [smile]), but I think I get it now!

The missing step is a standard trignomatric expansion for the addition of angles in sines and cosines. The rule goes:

cos(x + y) = cos(x) cos(y) - sin(x) sin(y)

If you let x = theta and y = delta_theta, you get the trig. part of the equation you've got there.

I found a list of these functions (so I was sure I got it right!) at this link. Scroll down to the 'Addition Theorems' to find the relevant one.

Hope that's of some help!

Share this post


Link to post
Share on other sites
well, on this site:
http://www.geocities.com/SiliconValley/2151/math3d.html

it tells about matrix rotations, and the rotations look like this:
Rotatation about the x axis:

x' = x

y' = (cos é * y) - (sin é * z)

z' = (sin é * y) + (cos é * z)

Rotation about the y axis:

x' = (cos é * x) + (sin é * z)

y' = y

z' = -(sin é * x) + (cos é * z)

Rotation about the z axis:

x' = (cos é * x) - (sin é * y)

y' = (sin é * x) + (cos é * y)

z' = z

ignore me if im wrong plz!

Share this post


Link to post
Share on other sites
Quote:
Original post by Trapper Zoid
It took me a while to decipher the equations (representing maths in plain text is such a pain, isn't it [smile]), but I think I get it now!

The missing step is a standard trignomatric expansion for the addition of angles in sines and cosines. The rule goes:

cos(x + y) = cos(x) cos(y) - sin(x) sin(y)

If you let x = theta and y = delta_theta, you get the trig. part of the equation you've got there.

I found a list of these functions (so I was sure I got it right!) at this link. Scroll down to the 'Addition Theorems' to find the relevant one.

Hope that's of some help!


Thank you Trapper. That answers my question perfectly. I had an inkling it had to do with trig expansion but I wasn't sure.

DanielG

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this