<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Consolas;
panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
pre
{mso-style-priority:99;
mso-style-link:"HTML-esimuotoiltu Char";
margin:0cm;
margin-bottom:.0001pt;
font-size:10.0pt;
font-family:"Courier New";}
span.HTML-esimuotoiltuChar
{mso-style-name:"HTML-esimuotoiltu Char";
mso-style-priority:99;
mso-style-link:HTML-esimuotoiltu;
font-family:Consolas;
mso-fareast-language:FI;}
span.Shkpostityyli21
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 2.0cm 70.85pt 2.0cm;}
div.WordSection1
{page:WordSection1;}
/* List Definitions */
@list l0
{mso-list-id:544028099;
mso-list-template-ids:1818624694;}
@list l1
{mso-list-id:890725365;
mso-list-template-ids:-198683984;}
ol
{margin-bottom:0cm;}
ul
{margin-bottom:0cm;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="FI" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-US" style="mso-fareast-language:EN-US">Hi Sebastian,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="mso-fareast-language:EN-US">Thanks for the link to geographiclib calculator including the geometry. I used it in the feature request ticket that I created
<a href="https://github.com/qgis/QGIS/issues/40888">https://github.com/qgis/QGIS/issues/40888</a>.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="mso-fareast-language:EN-US">-Jukka Rahkonen-<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><b>Lähettäjä:</b> Sebastian Gutwein <bas@rdgland.com> <br>
<b>Lähetetty:</b> keskiviikko 6. tammikuuta 2021 18.11<br>
<b>Vastaanottaja:</b> Nicolas Cadieux <njacadieux.gitlab@gmail.com><br>
<b>Kopio:</b> Rahkonen Jukka (MML) <jukka.rahkonen@maanmittauslaitos.fi>; qgis-user@lists.osgeo.org<br>
<b>Aihe:</b> Re: [Qgis-user] Confusion with ellipsoidal method of $area<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal">Hello,<o:p></o:p></p>
<div>
<p class="MsoNormal">Sorry if this gets posted twice I previously attached a .gpkg and it bounced due to the 100kb limit. <o:p></o:p></p>
<div>
<p class="MsoNormal">I am enjoying this fascinating discussion. This is all fairly new to me so I looked some things up and want to make sure that I am getting things right, <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:47.25pt;text-indent:-18.0pt;mso-list:l0 level1 lfo1">
<![if !supportLists]><span style="mso-list:Ignore">1.<span style="font:7.0pt "Times New Roman"">
</span></span><![endif]>In QGIS the $area function uses the sphere/ellipsoid settings of the project not of the CRS of the layer. <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:47.25pt;text-indent:-18.0pt;mso-list:l0 level1 lfo1">
<![if !supportLists]><span style="mso-list:Ignore">2.<span style="font:7.0pt "Times New Roman"">
</span></span><![endif]>QGIS uses the PROJ library to calculate area<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;margin-left:47.25pt;text-indent:-18.0pt;mso-list:l0 level1 lfo1">
<![if !supportLists]><span style="mso-list:Ignore">3.<span style="font:7.0pt "Times New Roman"">
</span></span><![endif]>According to the PROJ documentation <a href="http://even.rouault.free.fr/proj_cpp_api/rst_generated/html/geodesic.html" target="_blank">even.rouault.free.fr/proj_cpp_api/rst_generated/html/geodesic.html</a> PROJ uses GeographicLib to
calculate area. <o:p></o:p></p>
<div>
<p class="MsoNormal">If this is all true then if as Jukka Rahkonen describes the layer and the project were both EPSG:4326 and the ellipsoid in the Project-Settings was WGS 84 (EPSG:7030) then the QGIS measurements should be consistent (if they are correct
is open to discussion).with this GeographicLib web calculator that says it uses the WGS84 ellipsoid <a href="http://geographiclib.sourceforge.io/cgi-bin/Planimeter?type=polygon&rhumb=geodesic&input=59.95688345+20.13293641%0D%0A60.47397663+26.94617837%0D%0A62.56499443+29.74782155%0D%0A68.70650340+27.45254202%0D%0A68.24937206+23.75771765%0D%0A65.27444593+25.42698984%0D%0A63.10353609+21.51545237%0D%0A61.12318104+21.40562760%0D%0A60.40477513+19.41123592%0D%0A59.95688345+20.13293641&option=Submit" target="_blank">geographiclib.sourceforge.io/cgi-bin/Planimeter?type=polygon&rhumb=geodesic&input=59.95688345+20.13293641%0D%0A60.47397663+26.94617837%0D%0A62.56499443+29.74782155%0D%0A68.70650340+27.45254202%0D%0A68.24937206+23.75771765%0D%0A65.27444593+25.42698984%0D%0A63.10353609+21.51545237%0D%0A61.12318104+21.40562760%0D%0A60.40477513+19.41123592%0D%0A59.95688345+20.13293641&option=Submit</a><o:p></o:p></p>
</div>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Using Jukka Rahkonen's points and processes I ended up with the same non consistent results as they reported.
<s>Attached is a geopackage with the polygon that I used,</s><o:p></o:p></p>
</div>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal">On Wed, Jan 6, 2021 at 10:29 AM Sebastian Gutwein <<a href="mailto:bas@rdgland.com">bas@rdgland.com</a>> wrote:<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<div>
<p class="MsoNormal">Hello,<o:p></o:p></p>
<div>
<p class="MsoNormal">I am enjoying this fascinating discussion. This is all fairly new to me so I looked some things up and want to make sure that I am getting things right, <o:p></o:p></p>
</div>
<div>
<ol start="1" type="1">
<li class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l1 level1 lfo2">
In QGIS the $area function uses the sphere/ellipsoid settings of the project not of the CRS of the layer. <o:p></o:p></li><li class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l1 level1 lfo2">
QGIS uses the PROJ library to calculate area<o:p></o:p></li><li class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l1 level1 lfo2">
According to the PROJ documentation <a href="http://even.rouault.free.fr/proj_cpp_api/rst_generated/html/geodesic.html" target="_blank">
even.rouault.free.fr/proj_cpp_api/rst_generated/html/geodesic.html</a> PROJ uses GeographicLib to calculate area. <o:p></o:p></li></ol>
<div>
<p class="MsoNormal">If this is all true then if as Jukka Rahkonen describes the layer and the project were both EPSG:4326 and the ellipsoid in the Project-Settings was WGS 84 (EPSG:7030) then the QGIS measurements should be consistent (if they are correct
is open to discussion).with this GeographicLib web calculator that says it uses the WGS84 ellipsoid <a href="http://geographiclib.sourceforge.io/cgi-bin/Planimeter?type=polygon&rhumb=geodesic&input=59.95688345+20.13293641%0D%0A60.47397663+26.94617837%0D%0A62.56499443+29.74782155%0D%0A68.70650340+27.45254202%0D%0A68.24937206+23.75771765%0D%0A65.27444593+25.42698984%0D%0A63.10353609+21.51545237%0D%0A61.12318104+21.40562760%0D%0A60.40477513+19.41123592%0D%0A59.95688345+20.13293641&option=Submit" target="_blank">geographiclib.sourceforge.io/cgi-bin/Planimeter?type=polygon&rhumb=geodesic&input=59.95688345+20.13293641%0D%0A60.47397663+26.94617837%0D%0A62.56499443+29.74782155%0D%0A68.70650340+27.45254202%0D%0A68.24937206+23.75771765%0D%0A65.27444593+25.42698984%0D%0A63.10353609+21.51545237%0D%0A61.12318104+21.40562760%0D%0A60.40477513+19.41123592%0D%0A59.95688345+20.13293641&option=Submit</a><o:p></o:p></p>
</div>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Using Jukka Rahkonen's points and processes I ended up with the same non consistent results as they reported. Attached is a geopackage with the polygon that I used, <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">-Sebastian<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal">On Tue, Jan 5, 2021 at 3:52 PM Nicolas Cadieux <<a href="mailto:njacadieux.gitlab@gmail.com" target="_blank">njacadieux.gitlab@gmail.com</a>> wrote:<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<p>Hi,<o:p></o:p></p>
<p>QGIS is currently built on Proj version 6.3.2-1. If the other libraries are using a spheroid by default, then they use a sphere for speed and not an ellipsoid for precision. You can probably force this measurement in QGIS by creating a custom CRS with
a spheroid rather than an ellipsoid. The other option is to use the python in QGIS and to force a geoid.<o:p></o:p></p>
<p>Nicolas <o:p></o:p></p>
<div>
<p class="MsoNormal">On 2021-01-05 1:33 p.m., Rahkonen Jukka (MML) wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Hi,<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">I suppose that PostGIS is using the WGS 84 ellipsoid but I am not sure where from the documentation I could find that information. The ST_Area document
<a href="https://postgis.net/docs/ST_Area.html" target="_blank">https://postgis.net/docs/ST_Area.html</a> says only “For geography types by default area is determined on a spheroid with units in square meters”. Same thing with Spatialite, documentation suggests
just that it is “the” spheroid <a href="http://www.gaia-gis.it/gaia-sins/spatialite-sql-latest.html" target="_blank">
http://www.gaia-gis.it/gaia-sins/spatialite-sql-latest.html</a>.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">I did not notice this paragraph in the ST_Area document earlier “Enhanced: 2.2.0 - measurement on spheroid performed with GeographicLib for improved accuracy
and robustness. Requires Proj >= 4.9.0 to take advantage of the new feature.” So no wonder that the web app and PostGIS give the same results because they both use GeographicLib. And SpatiaLite 5.0 is using RTTopo that is a library that is based on LWGeom
so close connection in there too.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">So perhaps the way to get identical areas from QGIS would be to make it to use GeographicLib as well. I have no idea if it is a realistic approach and worth making
a feature request.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">-Jukka Rahkonen-</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><b>Lähettäjä:</b> Nicolas Cadieux
<a href="mailto:njacadieux.gitlab@gmail.com" target="_blank"><njacadieux.gitlab@gmail.com></a>
<br>
<b>Lähetetty:</b> tiistai 5. tammikuuta 2021 20.04<br>
<b>Vastaanottaja:</b> Rahkonen Jukka (MML) <a href="mailto:jukka.rahkonen@maanmittauslaitos.fi" target="_blank">
<jukka.rahkonen@maanmittauslaitos.fi></a>; <a href="mailto:qgis-user@lists.osgeo.org" target="_blank">
qgis-user@lists.osgeo.org</a><br>
<b>Aihe:</b> Re: [Qgis-user] Confusion with ellipsoidal method of $area<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p>Hi,<o:p></o:p></p>
<p>Your method in QGIS is sound. Area is calculated using the wgs84 ellipsoid EPSG 7030. If you reproject to wgs84 zone 35N (I think this is close), area goes from 249566957499.7546m2 to 249566957499.721m2 or a difference of 0.0336 m2. I don't think densification
would change things much.<o:p></o:p></p>
<p>My question is the following: You know that QGIS uses the WGS84 Ellipsoid. What Ellipsoid are using used in the other software??? If you don't know, I would proceed until you figure that out.<o:p></o:p></p>
<p>This is the currently used ellipsoid in the proj database in QGIS 3.16. You can get this by typing proj -le in the OSFeo4W Shell.<o:p></o:p></p>
<p><br>
MERIT a=6378137.0 rf=298.257 MERIT 1983<br>
SGS85 a=6378136.0 rf=298.257 Soviet Geodetic System 85<br>
GRS80 a=6378137.0 rf=298.257222101 GRS 1980(IUGG, 1980)<br>
IAU76 a=6378140.0 rf=298.257 IAU 1976<br>
airy a=6377563.396 rf=299.3249646 Airy 1830<br>
APL4.9 a=6378137.0 rf=298.25 Appl. Physics. 1965<br>
NWL9D a=6378145.0 rf=298.25 Naval Weapons Lab., 1965<br>
mod_airy a=6377340.189 b=6356034.446 Modified Airy<br>
andrae a=6377104.43 rf=300.0 Andrae 1876 (Den., Iclnd.)<br>
danish a=6377019.2563 rf=300.0 Andrae 1876 (Denmark, Iceland)<br>
aust_SA a=6378160.0 rf=298.25 Australian Natl & S. Amer. 1969<br>
GRS67 a=6378160.0 rf=298.2471674270 GRS 67(IUGG 1967)<br>
GSK2011 a=6378136.5 rf=298.2564151 GSK-2011<br>
bessel a=6377397.155 rf=299.1528128 Bessel 1841<br>
bess_nam a=6377483.865 rf=299.1528128 Bessel 1841 (Namibia)<br>
clrk66 a=6378206.4 b=6356583.8 Clarke 1866<br>
clrk80 a=6378249.145 rf=293.4663 Clarke 1880 mod.<br>
clrk80ign a=6378249.2 rf=293.4660212936269 Clarke 1880 (IGN).<br>
CPM a=6375738.7 rf=334.29 Comm. des Poids et Mesures 1799<br>
delmbr a=6376428. rf=311.5 Delambre 1810 (Belgium)<br>
engelis a=6378136.05 rf=298.2566 Engelis 1985<br>
evrst30 a=6377276.345 rf=300.8017 Everest 1830<br>
evrst48 a=6377304.063 rf=300.8017 Everest 1948<br>
evrst56 a=6377301.243 rf=300.8017 Everest 1956<br>
evrst69 a=6377295.664 rf=300.8017 Everest 1969<br>
evrstSS a=6377298.556 rf=300.8017 Everest (Sabah & Sarawak)<br>
fschr60 a=6378166. rf=298.3 Fischer (Mercury Datum) 1960<br>
fschr60m a=6378155. rf=298.3 Modified Fischer 1960<br>
fschr68 a=6378150. rf=298.3 Fischer 1968<br>
helmert a=6378200. rf=298.3 Helmert 1906<br>
hough a=6378270.0 rf=297. Hough<br>
intl a=6378388.0 rf=297. International 1909 (Hayford)<br>
krass a=6378245.0 rf=298.3 Krassovsky, 1942<br>
kaula a=6378163. rf=298.24 Kaula 1961<br>
lerch a=6378139. rf=298.257 Lerch 1979<br>
mprts a=6397300. rf=191. Maupertius 1738<br>
new_intl a=6378157.5 b=6356772.2 New International 1967<br>
plessis a=6376523. b=6355863. Plessis 1817 (France)<br>
PZ90 a=6378136.0 rf=298.25784 PZ-90<br>
SEasia a=6378155.0 b=6356773.3205 Southeast Asia<br>
walbeck a=6376896.0 b=6355834.8467 Walbeck<br>
WGS60 a=6378165.0 rf=298.3 WGS 60<br>
WGS66 a=6378145.0 rf=298.25 WGS 66<br>
WGS72 a=6378135.0 rf=298.26 WGS 72<br>
WGS84 a=6378137.0 rf=298.257223563 WGS 84<br>
sphere a=6370997.0 b=6370997.0 Normal Sphere (r=6370997)<o:p></o:p></p>
<p>Nicolas<o:p></o:p></p>
<p> <o:p></o:p></p>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">On 2021-01-05 11:43 a.m., Rahkonen Jukka (MML) wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Hi,<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">I wonder what method QGIS is using when it computes ellipsoidal area with $area function. I made a test with this EPSG:4326 polygon:</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">POLYGON (( 20.13293641 59.95688345, 26.94617837 60.47397663, 29.74782155 62.56499443, 27.45254202 68.7065034, 23.75771765 68.24937206, 25.42698984 65.27444593,
21.51545237 63.10353609, 21.4056276 61.12318104, 19.41123592 60.40477513, 20.13293641 59.95688345 ))</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">I checked that the CRS of the project and layer were both EPSG:4326. The ellipsoid in the Project-Settings was WGS 84 (EPSG:7030). The area that $area returns
is</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">249566957499.7546</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">As a references I used PostGIS and web site
<a href="https://geographiclib.sourceforge.io/scripts/geod-calc.html#area" target="_blank">
https://geographiclib.sourceforge.io/scripts/geod-calc.html#area</a>. With my test polygon they both give this result:</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">251199344354.4308</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">PostGIS returns bigger area. The difference is 0.654% so not huge but not negligible either.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">A third test with SpatiaLite 5.0 gives a result that is very close to PostGIS (difference 0.001%).</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">251195856999.549927</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">As a conclusion I have decided to trust in PostGIS because it gives the same results than the web site
<a href="https://geographiclib.sourceforge.io/scripts/geod-calc.html" target="_blank">
https://geographiclib.sourceforge.io/scripts/geod-calc.html</a> that feels scientifically sound. However, I wonder if I have used QGIS in a correct way or if there is anything I could do for getting areas to match better with PostGIS for example by densifying
the long segments in my test polygon.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">For getting testing easy I attach directly runnable SQL for PostGIS and Spatialite (version 5.0 with RTTopo is needed) as well as a coordinate list for the web
app.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">PostGIS</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">select st_area(st_geogfromtext('POLYGON ((</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">20.13293641 59.95688345,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">26.94617837 60.47397663,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">29.74782155 62.56499443,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">27.45254202 68.70650340,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">23.75771765 68.24937206,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">25.42698984 65.27444593,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">21.51545237 63.10353609,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">21.40562760 61.12318104,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">19.41123592 60.40477513,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">20.13293641 59.95688345))') , true);</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Spatialite</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">select st_area(st_geomfromtext('POLYGON ((</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">20.13293641 59.95688345,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">26.94617837 60.47397663,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">29.74782155 62.56499443,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">27.45254202 68.70650340,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">23.75771765 68.24937206,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">25.42698984 65.27444593,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">21.51545237 63.10353609,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">21.40562760 61.12318104,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">19.41123592 60.40477513,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">20.13293641 59.95688345))') ,true);</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Web site (notice lat-lon order)</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">59.95688345 20.13293641
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">60.47397663 26.94617837
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">62.56499443 29.74782155
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">68.70650340 27.45254202
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">68.24937206 23.75771765
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">65.27444593 25.42698984
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">63.10353609 21.51545237
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">61.12318104 21.40562760
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">60.40477513 19.41123592
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">59.95688345 20.13293641</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">-Jukka Rahkonen-
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;margin-bottom:12.0pt"><o:p> </o:p></p>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>Qgis-user mailing list<o:p></o:p></pre>
<pre><a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a><o:p></o:p></pre>
<pre>List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><o:p></o:p></pre>
<pre>Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><o:p></o:p></pre>
</blockquote>
<pre>-- <o:p></o:p></pre>
<pre>Nicolas Cadieux<o:p></o:p></pre>
<pre><a href="https://gitlab.com/njacadieux" target="_blank">https://gitlab.com/njacadieux</a><o:p></o:p></pre>
</div>
</blockquote>
<pre>-- <o:p></o:p></pre>
<pre>Nicolas Cadieux<o:p></o:p></pre>
<pre><a href="https://gitlab.com/njacadieux" target="_blank">https://gitlab.com/njacadieux</a><o:p></o:p></pre>
</div>
<p class="MsoNormal">_______________________________________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a><br>
List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">
https://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">
https://lists.osgeo.org/mailman/listinfo/qgis-user</a><o:p></o:p></p>
</blockquote>
</div>
</div>
</blockquote>
</div>
</div>
</body>
</html>