Home Contents Forum Links Tip Jar
Animation Math in Lingo       

Direction Using Sine & Cosine

In the physics model demos, direction of forces has been parallel to one of the axes. This is easy to program since either the x or y component is zero. What if you want to make a force that operates at an angle not parallel to an axis? What if you want to directly set acceleration at a particular angle?

When forces acting along different axes have been combined, the resulting velocities have had directions in all angles. But what if you wanted to set the direction of velocity directly to an arbitrary angle?

The problem comes down to finding the x and y components for a particular angle, and this is what sine and cosine functions do. Before continuing, make sure you are familiar with Sine & Cosine Definitions.

 
 


Copyright © 2003 JM Harward 
 jmckell~at~jmckell~dot~com
All lingo provided on this site may be used freely for educational purposes. Not for redistribution as uncompiled code. Instructional materials may not be reproduced without permission.