Cacluate the Rectangle coordinates on spherical surface

Hi,ALL

Thanks for your help.

There are two points with given coordinates.

So, let me connect with the two points to make a line( called center Line).

now, the rectangle is:(let me do assume)

There are two sides which are parallel.

and the distance between center Line and each parallel side is the same, let me assume it as 50 meters.

and the other two sides are vertical the line.

what I want to get are the coordinates of the rectangle corner.

(for example: left low corner coordindates and right upper corner coordinates)

Thanks in advanced

[611 byte] By [lvguangchuana] at [2007-10-2 16:39:30]
# 1
> There are two sides which are parallel.No there aren't. On a sphere distinct lines cannot be parallel. You'll need to rethink your definition.
YAT_Archivista at 2007-7-13 17:47:38 > top of Java-index,Other Topics,Algorithms...
# 2

Thanks YAT.

you are right.

I means that:

1 2

5 6

3 4

For example.1,2,3,4 is a rectangle.

each number stands for a corner.(since I can draw vertical line.)

5 and 6 are the point with given coordinates.

the distance between 5 and 1,3 is 50 meters.

the distance between 6 and 2,4 is 50 meters.

since the distance between 5,and 6 is less than 500 meters.

I assume we can ignore the curve of sphere.

the definition is right?!

Thanks

any idea is greatly appreciated

lvguangchuana at 2007-7-13 17:47:38 > top of Java-index,Other Topics,Algorithms...
# 3
> since the distance between 5,and 6 is less than 500> meters.> > I assume we can ignore the curve of sphere.This depends on the size of the sphere and the accuracy with which the answer is required!
stewartmarshalla at 2007-7-13 17:47:38 > top of Java-index,Other Topics,Algorithms...
# 4
Thanks guys.Forgive my poor english.the sphere is the Earth.I means I want to cacluate the rectangle on the real Earth.So the rectangle is not that big.we can assume it as a flat.Thanks
lvguangchuana at 2007-7-13 17:47:38 > top of Java-index,Other Topics,Algorithms...
# 5
If you can assume the rectangle's flat and 5 and 6 are both on the surface of a sphere centred at C then the vector (5 - C) x (5 - 6) will be parallel to the short sides. Scale it and add to 5 and 6 to get the corners.
YAT_Archivista at 2007-7-13 17:47:38 > top of Java-index,Other Topics,Algorithms...