Math Help Forum

Math Help Forum Feed Site Feed

Go Back   Math Help Forum > High School Math Help > Geometry
Reply
 
Thread Tools Display Modes
  #1  
Old 11-16-2008, 07:54 PM
Newbie
 
Join Date: Nov 2008
Posts: 1
Country:
Thanks: 0
Thanked 0 Times in 0 Posts
Seymour Clufley is on a distinguished road
Default Plot a path between 2 points, speed decelerating

Hi there,

I'm a programmer trying to plot the positions between two points. The number of steps from Point1 to Point2 is variable, as are the x,y positions of the two points.

I can do it if the speed is constant. The function is as follows:

Code:
PlotMotion(x1,y1,x2,y2,steps)
 
  xinc = Beat(x1,x2)-Defeat(x1,x2)
  xinc=xinc/(steps-2)
 
  yinc = Beat(y1,y2)-Defeat(y1,y2)
  yinc=yinc/(steps-2)
 
  For a = 2 To steps
      c(a)\x=Defeat(x1,x2)+(xinc*a)
      c(a)\y=Defeat(y1,y2)+(yinc*a)
  Next a
 
  c(1)\x=x1
  c(1)\y=y1
  c(steps)\x=x2
  c(steps)\y=y2
That's the program code (PureBasic). Forgive my ignorance but I believe the mathematical formula would be something like:

Xn = (x2-x1) / steps * n
Yn = y2-y1) / steps * n
assuming that x2 is greater than x1, and y2 is greater than y1.

However, can anyone tell me how to plot the path between two points if the speed is steadily decelerating?

At high school I could possibly have done this by myself but that's years ago and I'm reduced to googling for the formula. Hours later, I still can't find it, so any help would be greatly appreciated.

Thanks for reading,
Seymour.
Reply With Quote
Advertisement
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off
Forum Jump


All times are GMT -7. The time now is 03:33 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 ©2008, Crawlability, Inc.
©2005 - 2008 Math Help Forum


Math Help Forum is a community of maths forums with an emphasis on maths help in all levels of mathematics.
Register to post your math questions or just hang out and try some of our math games or visit the arcade.