I can't understand the results of ST_Project:

  • I use geography-type here, but the results are the same for geometry.
  • I use a rather long distance, because I need, at least in one direction, for my application a large distance. Because of this I found the problem in the first place.

I just want to project a point towards North, East, South and West. With the direction north, everything is as I expect it:

SELECT ST_AsText(ST_Project('POINT(-30 -0.5)'::geography, 1e7, radians(0)));
POINT(-30 89.4874128664049)

But in the other directions, here for example East, I get this:

SELECT ST_AsText(ST_Project('POINT(-30 -0.5)'::geography, 1e7, radians(90)));
POINT(59.8315233716443 0.00116689648502556)

I think this should be POINT(59.8315233716443 -0.5)

This behaviour occurs in all directions save north.

I'm new to whole earth coordinate systems so maybe I missed something, but I thought that when one walks directly west (or south) one would, by definition, not leave the current longitude (or latitude)-line but only change the other.

1 Answer 1


Straight lines on the sphere (paths you achieve by moving straight and not turning) are not lines of constant bearing, with only a couple exceptions (north/south meridians and the equator).

ST_Project projects along a great circle (a straight line in spherical terms), starting with the given bearing.

Lines of latitude (except the equator) are not great circles, so projecting directly east and west will not land you at a position on the same line of latitude.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.