[postgis-users] Which SRID to choose?
Homme Zwaagstra
hrz at geodata.soton.ac.uk
Thu Mar 25 02:09:47 PST 2004
On Wed, Mar 24, 2004 at 04:27:12PM +0100, Markus Schaber wrote:
> Hi,
>
> We currently get our geometry data in longitude/latitude format in
> degrees (e. G., 'POINT(8.53951 47.37704)' is Z?rich).
Have you had a look at the spatial_ref_sys table? This is created if
you load the spatial_ref_sys.sql file when you enable PostGIS on your
database. I find this to be a valuable source of projection and SRID
information, especially as it lists the proj4 options for each SRID.
> Our two data sources currently are GPS receivers and Shapefiles from
> ArcView Premium.
Your GPS receivers are likely to return coordinates in the WGS 1984
system. The EPSG (http://www.epsg.org/) code for this is 4326. All
srids currently appear to be the same as the EPSG code in the
spatial_ref_sys table:
select srid,auth_srid from spatial_ref_sys where srid != auth_srid;
I can't comment much on your shapefile data except that shapefiles
don't contain coordinate system information. You therefore have to
find this out from associated metadata or your data supplier. If this
doesn't reveal a specific EPSG code then some judicial searching of
the spatial_ref_sys table (based on the coordinate system parameters
you have otherwise found) should be fruitful.
> Now we're unshure which SRIDs to choose for those datas because we did
> not find any Documentation (yet) that was enlightening enough for us :-(
Try the documentation that comes with the proj4 command line tools at
<http://www.remotesensing.org/proj/> which should explain the contents
of the proj4text column in the spatial_ref_sys table.
The OpenGIS Coordinate Transformation Services at
<http://www.opengis.org/docs/01-009.pdf> describes the well known text
(WKT) format contained in the srtext column of the spatial_ref_sys table.
> Is there a single SRID that works for all longitude/latitude data?
No. As I understand it the earth is mathematically modelled in
different ways (often as a spheroid or ellipsoid). These
representations of the earth must be 'anchored' to the real earth at a
specific place. This anchor is the datum. There are many different
datums around the world. Combining a datum with an earth model is a
prerequisite for a geographic coordinate system.
An added (but optional) layer of complexity is created when the
datum/model combination is projected onto a flat surface. There are
different ways of projecting the earth models onto a flat surface.
Much of the complexity of coordinate systems stems from the multitude
of combinations that can be made between datums, models, and projections.
The EPSG, however, attempts to simplify things by maintaining a
database of the common combinations.
If you are lucky (and you should be) your longitude/latitude data will be in a coordinate
system represented by an EPSG SRID. Otherwise you will have to define
your own coordinate system and insert it into the spatial_ref_sys table.
> Do you know any good documentation / introduction into spatial reference
> systems in general and OpenGIS/PostGIS specific?
I'm no expert on the matters we're discussing; I've just gleaned as
much information as I can from places like:
http://www.colorado.edu/geography/gcraft/notes/notes.html
http://www.mentorsoftwareinc.com/cc/gistips/TIPSarch.HTM
http://www.terrainmap.com/rm1.html#projection
http://acl.arts.usyd.edu.au/VISTA/20-maps&projections/map_projections.htm
http://erg.usgs.gov/isb/pubs/MapProjections/projections.html
> Thanks in advance,
> Markus
Kind regards,
Homme Zwaagstra
More information about the postgis-users
mailing list