5

We are interested at the "Pole of inaccessibility" (https://en.wikipedia.org/wiki/Pole_of_inaccessibility) of our country.

Our approach is to use QGIS, and download coastline ([ngdc.noaa.gov]), and repeatedly create "contour lines of equal distance" until there is a point which is the farthest point away from the coastline.

Do you know how to generate a polygon which is an inner polygon and has equal distance the outer one?

An example of contour lines of equal distance on the Wikipedia page:

Example of contour lines of equal distance

After a reminder from @underdark, I finally get the result. Here are my steps:

  1. Get Mainland Coastline Shapefile

    $ curl https://www.ngdc.noaa.gov/mgg/shorelines/data/gshhg/latest/gshhg-shp-2.3.5-1.zip -o gshhg-shp.zip

    [action] use QGIS to add a field value with value 1 to the polygon of mainland coastline

  2. Rasterize the Polygon of Mainland Coastline

    $ gdal_rasterize -a value -tr 0.003 0.003 coastline.shp mainland.tif

  3. Proximity the Rasterized Mainland

    $ gdal_proximity.py -values 0 -distunits GEO -of GTiff mainland.tif proximity.tif

  4. Contour Based on the Proximity Result

    $ gdal_contour -a distance -i 0.005 -f "ESRI Shapefile" proximity.tif proximity_contour.shp

You now have the contour lines of inaccessibility!

3
  • I guess the correct term for "contour lines of equal distance" is buffer. Jan 10 '17 at 16:38
  • Welcome to gis.stackexchange! Please note that a good question on this site is expected to show some degree of research on your part, i.e. what you have tried and - if applicable - code so far. For more info, you can check our faq.
    – underdark
    Jan 10 '17 at 17:51
  • Don't forget to click the green check mark on the answer which helped you the most answer your question.
    – raphael
    Jan 12 '17 at 3:45
6

You could use negative buffer values on your polygons.

However, in your case, I would suggest the you compute the distance from your coastlines (Raster > Analysis > Proximity (Raster Distance)) in order to get a continuous distance raster. Then you can compute the local maxima with some SAGA GIS tools or you can derive your contour lines (raster > extraction > Contour).

Warning: measuring distances globally is tricky. Ideally you should probably work in geodesic distances in order to avoid artefacts caused by the coordinate system. For instance, using r.grow.distance with metric=geodesic.

1
  • Hi @radouxju, thank you very much. By using the proximity tool, we solved the problem. We learned and enjoyed so much from manipulating those data. Thanks to you! :D
    – rudychung
    Jan 11 '17 at 6:12
4

You should take a look at using "Raster > Analysis > Proximity" in QGIS which creates a raster with a value of its distance from a location in each pixel (in this case your coast line). Then just use "Raster > Extraction > Contour" and set a reasonable distance between contours. Because the pixels are all the same size, the incremented distance will increase linearly so your contours that are 10, 100 or 1000 metres apart will be equidistant. The "Pole of Inaccessibility" furthest point would also have the highest value.

To note: you need to use a closed polygon, which is fine if you are usign it on an island, however you'll need to create a polygon if you are searching for somewhere out to sea.

1
  • Thanks @Knightshound! We used Proximity and Contour you said and solved our problem. We enjoyed very much on solving it. Thank you very mcuh.
    – rudychung
    Jan 11 '17 at 6:13
2

A possible alternative method is to calculate the pole of inaccessibility directly. Vladimir Agafonkin recently published a quick (though somewhat imprecise) method for this that is easy to implement. There are also a number of papers with precise but more complex methods available.

2
  • Thanks, @iant. We solved the problem. I'm a bit of lazy to read the paper. But, your referenced article gives why (not just how) on it. Thank you! :D
    – rudychung
    Jan 11 '17 at 6:21
  • This has now been added (as of 3.0) as pole_of_inaccessibility(geometry, tolerance) to the field calculator. Sep 3 '18 at 18:33
0

From QGIS list of functions on vector data, we have the buffer function which:

Returns a geometry that represents all points whose distance from this geometry is less than or equal to distance. Calculations are in the Spatial Reference System of this geometry.

So, you can perform this function repeatedly from your country border, with a negative distance, until you have the smallest area, then get the center of that area.

1
  • Thanks @heltonbiker for your answer. We later used Rasterize, and then Proximity, and then Contour to solve this problem. Thank your for your suggestion. :)
    – rudychung
    Jan 11 '17 at 6:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.