[PROJ] Question about transformation using cs2cs

José Luis García Pallero jgpallero at gmail.com
Wed Sep 29 08:03:06 PDT 2021


El mié, 29 sept 2021 a las 16:42, Even Rouault
(<even.rouault at spatialys.com>) escribió:
>
> Hi,
>
> you're actually hitting this very old change in behavior in PROJ that
> still applies with recent versions:
> https://proj.org/usage/differences.html#version-4-6-0
>
> Just specifying a +ellps= doesn't define a datum. There's no way we can
> relate the 2 datums that are partially defined by just their ellipsoids.
> So when considering the geographic coordinates, they are just kept
> unchanged; Which explains the behaviour of the second cs2cs invokation.
>
> Why do you get different results in the UTM projected coordinates ?
> Because projection computation takes into account the ellipsoid shape.
> But you won't get a datum shift by itself when doing so.

Thank you for yout answer

But I understand that in this case the operations are:

1. Inverse projection step from UTM ellps=intl to geographic
coordinates in ellps=intl
2. Geographic coordinates in ellps=intl to cartesian geocentric
coordinates referred to ellps=intl
3. Helmert transformation from cartesian geocentric referred to
ellps=intl to cartesian geocentric referred to ellps=WGS84 using the
parameters defined in PROJ database
4. Cartesian geocentric referred to ellps=WGS84 to geographic
coordinated in ellps=WGS84
5. Projection from geographic coordinated in ellps=WGS84 to UTM ellps=WGS84

Am I right? Then, why do not perform the steps 2, 3, 4 in the case
just specifying +ellps=?

About the datum definitions for the +datum option, I can see in
https://proj.org/operations/conversions/latlon.html that there is the
option -ld in order to see all defined datums. But in my PROJ 7.2.1
there is no such option. Is the -ld option only present in PROJ 8?

Thanks

>
> So you'll probably have to specify a +towgs84 or +nadgrids parameters to
> your source CRS to define how it relates with the WGS 84 datum, and
> replace on the target CRS +ellps=WGS84 by +datum=WGS84
>
> The PROJ debug traces are quite verbose and hard to understand if you're
> not a developer, so they won't help much.
>
> If you know the EPSG codes of the CRS, you'd better using them directly
> to get more significant transformations.
>
> Even
>
> Le 29/09/2021 à 16:18, José Luis García Pallero a écrit :
> > Hello:
> >
> > I'm using PROJ 7.2.1 from Debian repositories and I have some
> > questions about cs2cs. If I run
> >
> > echo 1445748.66 5053500.03 | cs2cs +proj=utm +zone=10 +ellps=intl +to
> > +proj=utm +zone=10 +ellps=WGS84
> >
> > I obtain
> >
> > 1445704.69      5053404.02 0.00
> >
> > so the transformation of UTM coordinates between a point on the
> > international ellipsoid to WGS84 was performed.
> >
> > But if I try to do the same with geographical coordinates as
> >
> > echo 111W 45N | cs2cs +proj=latlong +ellps=intl +to +proj=latlong +ellps=WGS84
> >
> > I obtain
> >
> > 111dW   45dN 0.000
> >
> > so no transformation was performed. Why? Setting PROJ_DEBUG I obtain
> > for this case
> >
> > pj_open_lib(proj.db): call fopen(/usr/share/proj/proj.db) - succeeded
> > pj_open_lib(proj.ini): call fopen(/usr/share/proj/proj.ini) - succeeded
> > pj_ellipsoid - final: a=6378137.000 f=1/298.257, errno=0
> > pj_ellipsoid - final:    ellps=GRS80
> >
> > Here I understand that only the second declaration of +ellps was taken
> > into account (althoug EGS84 and GRS80 ellipsoids are not exactly the
> > same)
> >
> > Thanks
>
> --
> http://www.spatialys.com
> My software is free, but my time generally not.
>


-- 
*****************************************
José Luis García Pallero
jgpallero at gmail.com
(o<
/ / \
V_/_
Use Debian GNU/Linux and enjoy!
*****************************************


More information about the PROJ mailing list