Web Mercator

Hvorfor bruker de store selskapene (Google, Microsoft, Mapbox, Open Street Map m.fl.) Web Mercator-projeksjonen?

Hvorfor brukes det en kuleflate framfor en ellipsoide som datum i Web Mercator?

Les om Merctor-projeksjonen, f.eks. her: Wikipedia, Mercator projection

The International Association of Oil & Gas Producers (IOGP)

 

Geomatics Committee

 

"If you’re drilling a well in a potentially sensitive area and you’re spending millions of dollars to do it, you want to be certain that well is in the right place.

The IOGP Geomatics Committee helps to provide some of that certainty.

Committee members include specialists in surveying, geodesy, cartography and geospatial data management." 

European Petroleum Survey Group

In 2005, IOGP absorbed the European Petroleum Survey Group or EPSG (1986–2005) into its structure. EPSG was a scientific organization with ties to the European petroleum industry consisting of specialists working in applied geodesy, surveying, and cartography related to oil exploration.

 

EPSG compiled and disseminated the EPSG Geodetic Parameter Set, a widely used database of Earth ellipsoids, geodetic datums, geographic and projected coordinate systems, units of measurement, etc.

EPSG Dataset

 

"The EPSG Geodetic Parameter Dataset is a collection of definitions of coordinate reference systems and coordinate transformations. These may be global, regional, national or local in application. To learn more visit www.epsg.org.

 

The Dataset is maintained by IOGP members through the Geodesy Subcommittee of the Geomatics Committee. It is distributed publicly at no cost as both an online (www.epsg-registry.org) and offline (www.epsg.org) resource, both requiring acceptance of the Terms of Use."

EPSG Dataset

 

Offisiell online database:

https://epsg.org/

 

Uoffisielle kopier:

 

  

Web mercator
 

- datum: sfærisk - ikke ellipsoide-basert

- brukes av

      Bing Maps

      Open Street Map

      Google

- EPSG:3857

- se http://epsg.io/3857

 

- før Web Mercator ble lagt til i EPSG-datasettet, ble koden 900913 brukt (tallkoden ligner på teksten "google")

 

PROJCS["WGS 84 / Pseudo-Mercator",
    GEOGCS["WGS 84",
        DATUM["WGS_1984",
            SPHEROID["WGS 84",6378137,298.257223563,
                AUTHORITY["EPSG","7030"]],
            AUTHORITY["EPSG","6326"]],
        PRIMEM["Greenwich",0,
            AUTHORITY["EPSG","8901"]],
        UNIT["degree",0.0174532925199433,
            AUTHORITY["EPSG","9122"]],
        AUTHORITY["EPSG","4326"]],
    PROJECTION["Mercator_1SP"],
    PARAMETER["central_meridian",0],
    PARAMETER["scale_factor",1],
    PARAMETER["false_easting",0],
    PARAMETER["false_northing",0],
    UNIT["metre",1,
        AUTHORITY["EPSG","9001"]],
    AXIS["X",EAST],
    AXIS["Y",NORTH],
    EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 
                +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext  +no_defs"],
    AUTHORITY["EPSG","3857"]]

EPSG 3857, med ellipsoidisk datum (!)

Opprinnelig EPSG-definisjon for Web Mercator EPSG:3785

PROJCS["Popular Visualisation CRS / Mercator (deprecated)",
    GEOGCS["Popular Visualisation CRS",
        DATUM["Popular_Visualisation_Datum",
            SPHEROID["Popular Visualisation Sphere",6378137,0,
                AUTHORITY["EPSG","7059"]],
            TOWGS84[0,0,0,0,0,0,0],
            AUTHORITY["EPSG","6055"]],
        PRIMEM["Greenwich",0,
            AUTHORITY["EPSG","8901"]],
        UNIT["degree",0.0174532925199433,
            AUTHORITY["EPSG","9122"]],
        AUTHORITY["EPSG","4055"]],
    PROJECTION["Mercator_1SP"],
    PARAMETER["central_meridian",0],
    PARAMETER["scale_factor",1],
    PARAMETER["false_easting",0],
    PARAMETER["false_northing",0],
    UNIT["metre",1,
        AUTHORITY["EPSG","9001"]],
    AXIS["X",EAST],
    AXIS["Y",NORTH],
    EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 
                        +k=1.0 +units=m +nadgrids=@null +wktext  +no_defs"],
    AUTHORITY["EPSG","3785"]]

EPSG:4326

 

- geografiske koordinater

- ikke projisert

- Brukes i

      GPS

      GPX-filer
      KML-filer

 

se http://epsg.io/4326

EPSG-koder brukt i Norge

 

25832: UTM sone 32, EUREF89-datum

25833: UTM sone 33, EUREF89-datum

25835: UTM sone 35, EUREF89-datum

 

Full liste på geonorge.no:

https://register.geonorge.no/epsg-koder

 

 

Hvordan ser Web mercator ut?

 

demo i ArcGIS

 

UTM sone 32, areal i kvadratmeter

Web Mercator, areal i kvadratmeter

Equirektangulær projeksjon (Plate Carrée), areal i kvadratmeter (denne projeksjonen velges automatisk av ArcGIS hvis datasettet har geografiske koordinater, EPSG:4326)

Wikipedia, Equirectangular projection

ArcGIS Desktop, Plate Carrée

Arealberegning med Google Maps API

<!DOCTYPE html>
<html>
<head>
  <title>Arealberegning</title>
  <meta charset="utf-8">
  <script src="https://maps.googleapis.com/maps/api/js?key=YOUR_API_KEY&libraries=geometry"></script>
</head>

<body>
  <p>Google Maps API</p>
  <p>google.maps.geometry.spherical:<br>computeArea()</p>
  <p id="areal"></p>

  <script>

    let p1 = new google.maps.LatLng(60.78962180, 10.68012091);
    let p2 = new google.maps.LatLng(60.78905971, 10.68108467);
    let p3 = new google.maps.LatLng(60.78851428, 10.67966384);
    let p4 = new google.maps.LatLng(60.78898582, 10.67890237);
    let p5 = new google.maps.LatLng(60.78956696, 10.68004903);
    let p6 = new google.maps.LatLng(60.78962180, 10.68012091);

    let area = google.maps.geometry.spherical.computeArea([p1, p2, p3, p4, p5]).toFixed(1, );
       
    document.getElementById('areal').innerHTML = "Areal: " + area + " m<sup>2</sup>";

  </script>

</body>
</html>

Arealberegning med Google Maps API

Arealberegninger med
geografisk datatype i PostGIS

(koordinater oppgitt som lengde/breddegrad)


select ST_Area(ST_GeogFromText('SRID=4326;
            POLYGON((1 1, 2 1, 2 2, 1 2, 1 1))'))

Resultat ved ekvator (breddegrad 1-2): 12304.8 km2
 


select ST_Area(ST_GeogFromText('SRID=4326;
            POLYGON((10 60, 11 60, 11 61,  10 61, 10 60))'))

Resultat ved 60 grader nord: 3108.6 km2
Arealet på 60 grader nord er ca. 25 % av arealet ved ekvator.

HIG

Verktøy       Projeksjon          Areal    % avvik fra seeiendom.no
ArcMap        Web Mercator        29989,0     318
              Equirectangular     14635,4     104
              UTM Sone 32          7163,3       0
PostGIS       Geografisk           7167,5       0
Google Maps   Geografisk           7142,4       0
seeiendom.no  UTM Sone 32          7167,0       0

Boligtomt i Østre Toten

Verktøy       Projeksjon          Areal    % avvik fra seeiendom.no
ArcMap        Web Mercator        4774,9     316
              Equirectangular     2340,8     104
              UTM Sone 32         1151,0       0
PostGIS       Geografisk          1151,2       0
Google Maps   Geografisk
seeiendom.no  UTM Sone 32         1147,4       0

Oppsummert - resultater fra arealberegninger

Oppsummert - resultater

 

  1. Mercator er en konform projeksjon - den bevarer vinkler (og form). Den kan vise jordkloden mellom 82 grader sør og 82 grader nord.
     
  2. Ved 60. breddegrad er avstandsmål fordoblet, arealmål er firedoblet.
     
  3. Arealer og lengder måles normalt i kartplanet - med Web Mercator gir det helt ville resultater unntatt ved ekvator.
     
  4. Lengder og arealer kan beregnes ut fra geografiske koordinater med spesielle beregningsbiblioteker, f.eks. med Google Maps spherical geometry og med PostGIS geografisk datatype og tilhørende bibliotek.

GEO2311 Web Mercator

By sverres

GEO2311 Web Mercator

  • 801