[postgis-users] Center of a path.

cuicui meuh.meuh at noos.fr
Sat Jan 11 02:26:06 PST 2003


Hi everyone,

I need to check the distance between the centre of a path (which 
represents a road) and a point (which represents a school). A simple way 
  to do this is to put the path in a box and to take the centre of a box.

school.point <-> center(box(road.path))

The problem is that this "centre" is not necessary on the path. I would 
like to know if a function exist and can find the centre of a path with 
this definition : "A point ON the path, which is half way from each end 
of the path".

Any ideas ? :)

Cheers,

Nicolas




More information about the postgis-users mailing list