• Aug 20th 2006, 05:06 PM
mrmeanscene
Hello I am trying to find a formula to calculate coordinates depending on speed, long and lat.

x direction = 90 degrees lat, 0 degrees long
y direction = 0 degrees lat, 90 degrees long
z direction = 0 lat, 0 long

http://www.mymeanscene.com/example.jpg

if object travels at random speed,long and lat how does one calculate how quickly the object is moving in each direction

eg: speed = 10mph

how quickly is the object traveling towards x,y,z

hope thats clear enough

• Aug 20th 2006, 05:13 PM
ThePerfectHacker
Are these spherical coordinates?
• Aug 20th 2006, 05:22 PM
mrmeanscene
x = left/right (pitch)
y = up/down (pitch)
z = forward/back

Are these spherical coordinates? I do not know im a little uneducated in mathematical terms.

http://www.mymeanscene.com/3ddesign.html
• Aug 20th 2006, 05:57 PM
Quick
impersonating Soroban
Hello mrmmeanscene,

The question is very strangely put.

Quote:

x direction = 90 degrees lat, 0 degrees long
y direction = 0 degrees lat, 90 degrees long
z direction = 0 lat, 0 long

if object travels at random speed,long and lat how does one calculate how quickly the object is moving in each direction?

eg: speed = 10mph

how quickly is the object traveling towards x,y,z??

It seems to me like your asking how fast the object is going, yet the speed is given for you!

Maybe you mean how long it will take to reach point (x,y,z)?
• Aug 20th 2006, 06:05 PM
mrmeanscene
sorry, its hard for me to explain, I have added a diagram and link to the program in question above.

heres a scenario:
object starts at coordinates x0,y0,z0 and can head in any direction at any speed, if it travels facing 45 degrees long and 45 degrees lat at 10 units per second how would I calculate its coordinates after 2 seconds.
• Aug 20th 2006, 06:14 PM
Quick
Quote:

Originally Posted by mrmeanscene
sorry, its hard for me to explain, I have added a diagram and link to the program in question above.

heres a scenario:
object starts at coordinates x0,y0,z0 and can head in any direction at any speed, if it travels facing 45 degrees long and 45 degrees lat at 10 units per second how would I calculate its coordinates after 2 seconds.

I would like to point out there are no degrees in your picture. However, what I think you want to know is that if you're going, let's say 10 mph longitude, and 5 mph lattitude, at what point will you end up after one hour? If this is the case I can easily help you out.
• Aug 20th 2006, 06:21 PM
mrmeanscene
yeah, that sounds like what im after, ive added degrees also thanks!
• Aug 20th 2006, 06:30 PM
Quick
alright, first thing we'll do is forget about the z-axis until later.

Let's say we're going 4mph along the x-axis (longitude) and 3mph along the y-axis (lattitude)

If we start with point (0,0) after an hour we will get to point (4,3)

Now use the distance formula: $d=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}$

substitute: $d=\sqrt{(4-0)^2+(3-0)^2}$

Subtract: $d=\sqrt{4^2+3^2}$

solve: $d=\sqrt{16+9}$

add: $d=\sqrt{25}$

solve: $d=5$

and speed is distance over time, so we get the speed of 5mph.

In short the formula your going to use is (note: $s_a$ means speed along the "a" axis and t means total): $s_t=\sqrt{s_x^2+s_y^2}$
• Aug 20th 2006, 06:34 PM
Quick
now for the z-axis
I'm not really going to explain this one. But the formula for speed (with the z axis) is: $s_t=\sqrt{s_x^2+s_y^2+s_z^2}$
• Aug 20th 2006, 06:35 PM
ThePerfectHacker
This is how I did it.
You have a point,
$(x,y,z)$
After rotation x coordinate 45 degrees and y coordinate 45 degrees (in counter-clockwise direction) then you new point is,
$\left( \frac{\sqrt{2}}{2}x+\frac{1}{2}y-\frac{1}{2}z,\frac{\sqrt{2}}{2}y+\frac{\sqrt{2}}{2 }z,\frac{\sqrt{2}}{2}x-\frac{\sqrt{2}}{2}y+\frac{1}{2}z\right)$
• Aug 20th 2006, 06:46 PM
Quick
this is probably more relevant
If the x-axis is going 10mph, the y-axis at 5mph, and the z-axis at 4mph, then after one hour you will reach point $(x_1+10\;,\;y_1+5\;,\;z_1+4)$ where x_1, y_1, and z_1 are the points you started off with.

In other words the formula you will use to find the ending point is: $(x_1+mph\times h\;,\;y_1+mph\times h\;,\;z_1+mph\times h)=(x_2\;,\;y_2\;,\;z_2)$ where h is the time in hours after you started and x_2, y_2, and z_2 are the ending points
• Aug 23rd 2006, 05:54 PM
mrmeanscene
Thanks guys, these explanations solve several problems I have had!