# Limitations of coordinates transformations

In order to apply `shapely.affinity.scale` (see documentation) I have had to transform a series of geodetic coordinates to projected coordinates, see python - UserWarning: Geometry is in a geographic CRS. Results from 'buffer' are likely incorrect - Stack Overflow and UserWarning: Geometry is in a geographic CRS. Results from 'buffer' are likely incorrect for context

All my coordinates are within a bounding box defined as 35.5, -11.0, 71.5, 31.5 (South, West, North, East) covering most of Europe.

Transformation of e.g. 54.1767° latitude and 7.8911° longitude from EPSG:4326 (WGS 84) to EPSG:4936 (ETRS89) results in X: 3705858.6428144597 and Y: 513643.6629113175. But the reverse transformation results in 0° latitude and 7.8911° longitude! So something is wrong.

Transformation from EPSG:4326 to EPSG:3034 (ETRS89-extended / LCC Europe) and back to EPSG:4326 works just fine.

Both coordinate systems (EPSG:4936 and EPSG:3034) cover the same area (WGS84 bounds: -16.1 32.88, 40.18 84.73) and the coordinates used fall within these bounds.

What limitation of coordinates transformations am I missing?

UPDATE: a Minimal, Reproducible Example in Python

``````In : import geopandas as gpd
import pandas as pd
import shapely

In : point = shapely.Point([7.8911,54.1767])

In : gdf = gpd.GeoDataFrame(index=, crs="epsg:4326",
geometry=[point])

In : # transform point from WGS 84 to ETRS89
gdf["geometry"].to_crs(4936)
Out: 0    POINT (3705858.64281 513643.66291)
Name: geometry, dtype: geometry

In : # transform point from WGS 84 to ETRS89 and back to WGS 84
gdf["geometry"].to_crs(4936).to_crs(4326)
Out: 0    POINT (7.89110 0.00000)
Name: geometry, dtype: geometry

In : # transform point from WGS 84 to ETRS89-extended
gdf["geometry"].to_crs(3034)
Out: 0    POINT (3866814.669 3036011.045)
Name: geometry, dtype: geometry

In : # transform point from WGS 84 to ETRS89-extended and back to WGS 84
gdf["geometry"].to_crs(3034).to_crs(4326)
Out: 0    POINT (7.89110 54.17670)
Name: geometry, dtype: geometry
``````
• simply all kinds of transformation come with some loss on accuracy, in particular when changing the so-called geodetic datum. Transforming twice will therefor double the error. Mar 7 at 21:24
• @MakePeaceGreatAgain I understand that, but 54.34707° to 0° latitude is not a rounding error. Mar 7 at 21:33
• On the inverse the values need to be swapped. What you have labeled as X is the northing values and Y is the easting value. Mar 19 at 23:30
• @mkennedy I do not understand your comment. But I have simplified the MRE to make my original question easier to read. Which values exactly do you think need to be swapped? Mar 20 at 22:06
• OH, I should have checked the WKIDs. 4936 is the XYZ (3D geocentric/ECEF) version of ETRS89 so you should be printing 3 values for the output coordinates. I think dropping the 3rd value is what causes the very different results in the inverse calculation. I'd assumed 4936 was a UTM or GK projected CRS. Mar 21 at 15:15