[OSRS-PROJ] cs2cs and prime meridian

Markus Neteler neteler at itc.it
Wed Feb 25 12:41:54 EST 2004


Dear list members,

I would like to report a strange (for me) observation in 'cs2cs'.
Trying to reproject from Gauss-Boaga to LatLong, I obtain somehow
odd results:

1) Gauss-Boaga/Fuso 1 (Ovest) to LatLong:

cs2cs -v +init="epsg:26591" \
      +to +proj=latlong +datum=WGS84
# ---- From Coordinate System ----
#Transverse Mercator
#       Cyl, Sph&Ell
# +init=epsg:26591 +proj=tmerc +lat_0=0 +lon_0=21.45233333333333 +k=0.999600
# +x_0=1500000 +y_0=0 +ellps=intl +pm=rome +units=m +no_defs
# ---- To Coordinate System ----
#Lat/long (Geodetic)
#
# +proj=latlong +datum=WGS84 +ellps=WGS84 +towgs84=0,0,0
1660469 5101082 100
23d31'34.538"E  46d2'37.045"N 100.000

   This result is wrong.


2) Specifying the parameters manually without prime meridian:

cs2cs -v +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0 \
   +ellps=intl +units=m +no_defs \
   +to +proj=latlong +datum=WGS84
# ---- From Coordinate System ----
#Transverse Mercator
#       Cyl, Sph&Ell
# +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0 +ellps=intl
# +units=m +no_defs
# ---- To Coordinate System ----
#Lat/long (Geodetic)
#
# +proj=latlong +datum=WGS84 +ellps=WGS84 +towgs84=0,0,0
1660469 5101082 100
11d4'26.138"E   46d2'37.045"N 100.000

   This result is correct (at least close to be correct).

3) Specifying the parameters manually *with* prime meridian:

cs2cs -v +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0 \
   +ellps=intl +units=m +pm=rome +no_defs \
   +to +proj=latlong +datum=WGS84
# ---- From Coordinate System ----
#Transverse Mercator
#       Cyl, Sph&Ell
# +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0 +ellps=intl
# +units=m +pm=rome +no_defs
# ---- To Coordinate System ----
#Lat/long (Geodetic)
#
# +proj=latlong +datum=WGS84 +ellps=WGS84 +towgs84=0,0,0
1660469 5101082 100
11d4'26.138"E   46d2'37.045"N 100.000
 
4) Specifying the parameters manually with *wrong* prime meridian:
cs2cs -v +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0 \
   +ellps=intl +units=m +pm=ferro +no_defs \
   +to +proj=latlong +datum=WGS84
# ---- From Coordinate System ----
#Transverse Mercator
#       Cyl, Sph&Ell
# +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0 +ellps=intl
# +units=m +pm=ferro +no_defs
# ---- To Coordinate System ----
#Lat/long (Geodetic)
#
# +proj=latlong +datum=WGS84 +ellps=WGS84 +towgs84=0,0,0
1660469 5101082 100
11d4'26.138"E   46d2'37.045"N 100.000

   Same results with +pm=ferro and +pm=rome, strange.

5) Test again, using nonsense +pm value:

cs2cs -v +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0
+ellps=intl +units=m +pm="99.999" +no_defs    +to +proj=latlong +datum=WGS84
# ---- From Coordinate System ----
#Transverse Mercator
#       Cyl, Sph&Ell
# +proj=tmerc +lat_0=0 +lon_0=9 +k=0.999600 +x_0=1500000 +y_0=0 +ellps=intl
# +units=m +pm=99.999 +no_defs
# ---- To Coordinate System ----
#Lat/long (Geodetic)
#
# +proj=latlong +datum=WGS84 +ellps=WGS84 +towgs84=0,0,0
1660469 5101082 100
11d4'26.138"E   46d2'37.045"N 100.000

To me this indicates that all specifications of the prime meridian in
the epsg file are ignored by 'cs2cs'. Since some month ago, when the 
lon_0 values were adapted to introduce the concept of prime meridian,
all calculations based on these epsg entries are wrong (tested only 'rome'
pm).

Number of potentially affected definitions:
grep '+pm=' /usr/local/share/proj/epsg | wc -l
     66

Please tell me that I am wrong (where's the trick?).
Sorry, if this was a stupid observation, but I don't manage
to use 'cs2cs' any more for Gauss-Boaga.

Otherwise, should I file a bug report?
See also related bug report in GDAL Bugtracker: "gdalwarp 900km off"
    http://bugzilla.remotesensing.org/show_bug.cgi?id=367

Kind regards

 Markus Neteler
 
----------------------------------------
PROJ.4 Discussion List
See http://www.remotesensing.org/proj for subscription, unsubscription
and other information.



More information about the Proj mailing list