Azimuthal Projections Info

Example azimuthal map

Azimuthal projection from ARRL headquarters

This all started when I was interested in calculating the distance and bearing between amateur radio stations. I found this reference on calculating the great circle distance and bearing. Ultimately, this interest led to a web form for producing azimuthal maps.

For those who never heard of an azimuthal map, it is a special kind of map that prioritizes correctly showing the great circle distance and bearing from the center reference point. Azimuthal maps are particularly useful for ham radio operators with a directional antenna. For example, if you’re in Connecticut and you want to talk with someone in Cameroon (Africa), the azimuthal map will tell you to point your antenna to a bearing of 90° on a compass (technically you also much adjust for the difference between magnetic north and true north).

It occurred to me that this the bearing and distance calculation was the fundamental tool for making an azimuthal projection. All I needed was a database of land and political boundaries expressed in latitude/longitude pairs.

The azimuthal project is always made from a particular reference point on the globe, and I can convert the points in the  land and political boundary database into bearing and distance using the great circle calculations. This gives me a collection of points in polar coordinates (r, Θ) which is what I need for the azimuthal projection.

For the land and political boundary information, I used the database from the CIA World Databank II; however, it required some massaging. First it was too detailed, and I had to filter the data to an appropriate resolution. Next, I wanted land masses and water bodies to be represented by closed paths. The CIA World Databank II is a collection of unconnected paths, so I had to write a program to patch them together and reorder the points to be clockwise. Having closed paths of points ordered in clockwise orders is necessary to have water and land colored differently. Lastly, I had to identify which closed paths represent land and which represent water. Unfortunately, this work is incomplete. You’ll notice some lakes that aren’t colored blue.

Initially, my Ruby program was generating raw PostScript. However, I recognized that it would be easier for people to use if it generated a PDF.  Rather than using a Postscript to PDF convertor, I changed to generating PDFs directly using the Ruby PDF::Writer. By using PostScript or PDF, I get vector graphic output that is scalable from small to very large sizes without having to make a huge raster graphic files.  There is a limit to the resolution of the continent & political outline data, so at very large sizes, the outlines may not appear smooth.

Ultimately, I used the great circle distance formula from Wikipedia. According the article, it’s accurate for both long and short distances.

The hardest part of the whole project was getting the water blue. There are still some maps where the program gets it wrong, and you’ll see weird coloring. Things tend to go wrong when the reference point is inside a particular small region of land or water. In these cases, the floating  point accuracy seems to cause the colors approach to fail.

My plans for future improvements include:

  • add small tables of bearing & distance for important world cities around the margins
  • add US and world cities to the map (particularly for area map)
  • adjusting political boundaries and labels to be more accurate
  • adding more views to allow people to report lakes that aren’t colored correctly
Share on Facebook

213 Responses to “Azimuthal Projections Info”

  1. Dennis Farr says:

    Our map shows Australia for west (270) of Tampa. That azimuth would follow the meridian and never cross the equator. Did I miss something?

  2. NS6T says:

    It’s often hard to think about these things without looking at a globe. I don’t have one handy, so I don’t know what it would look like. I can offer results from sites that agree with the generated map:

  3. Karen says:

    I can’t get this to work at all.
    At work, I use Chrome and Windows 7 (I think). Also tried Internet Explorer and no go.
    Doesn’t work on my phone either (iPhone 7).
    At home, no go – MacBook Pro & Safari.

    This is the error I continually get:
    Internal Server Error

    The server encountered an internal error or misconfiguration and was unable to complete your request.

    Please contact the server administrator at webmaster@localhost to inform them of the time this error occurred, and the actions you performed just before this error.

    More information about this error may be available in the server error log.

    Apache/2.4.10 (Debian) Server at ns6t.net Port 80

  4. ¡Excelente!
    Lo he difundido varias veces en mi Facebook (www.facebook.com/victorio.marzocchi )
    Hice varios mapas con centro en las Islas Malvinas (Argentina) y Bases Antárticas Argentinas.

    Excellent!
    I have spread it several times in my Facebook http://www.facebook.com/victorio.marzocchi
    I made several maps with center in the Malvinas Islands (Argentina) and Bases Antarctic Argentinas.

  5. Kevin says:

    Thanks, this map is just what I was looking for! its incredible how wrong ones flat map intuitive geometry is when guessing the great circle direction to some far off location but you maps have cleared that up.

  6. Fürst says:

    Thanks! Cool idea. You should improve the input data check. E.g. non English letters in the title returns “The server encountered an internal error or misconfiguration…”. Same with some arbitrary format for the coordinates. It’s possible that a malicious user could exploit this to harm the server. Not only should any character be allowed in the title but the server should also handle wrong input gracefully.

    A tiny improvement: Let the user choose one or more output format for the coordinates. E.g.
    – Decimal degrees
    – Degrees, minutes, seconds
    – Maidenhead locator
    – etc.

  7. Allan says:

    1 Feb 2017
    202 UTC

    Internal Server Error

    The server encountered an internal error or misconfiguration and was unable to complete your request.

    Please contact the server administrator at webmaster@localhost to inform them of the time this error occurred, and the actions you performed just before this error.

    More information about this error may be available in the server error log.
    Apache/2.4.10 (Debian) Server at ns6t.net Port 80

  8. diego ponce de leon says:

    the name of the countries are very difficult to read. the coulor of the words could be more blacky or to have more definiton,
    best 73’s
    diego
    cx4di

  9. Anung says:

    Hi, can you apply day night shading to the generated map?

  10. Andrew says:

    Hi NS6T,

    The map is just brilliant, it addresses my curiosity.

    Thank You,
    VR2VKH

  11. John Marks says:

    Excellent idea, but printing my house as centre and a 10 mile radius, I just got a white sheet, with some points for nearby towns.
    Any chance of choosing standard colour contours (from Wikipedia or Google Earth, for example) instead of just white?

  12. Andy says:

    March24, 2017
    Using MacBook Pro OS 10.12.3 with Chrome.

    Internal Server Error

    The server encountered an internal error or misconfiguration and was unable to complete your request.

    Please contact the server administrator at webmaster@localhost to inform them of the time this error occurred, and the actions you performed just before this error.

    More information about this error may be available in the server error log.

    Apache/2.4.10 (Debian) Server at ns6t.net Port 80

  13. KD0RMI says:

    @ those who get an internal server error – I got that as well, but it was simply solved by clicking the “Estimate Location” button instead of using an actual city name. Type in the city name and state (or country I assume), then click Estimate Location and it will be converted into Lat/Lon coordinates. That worked for me.

    @ Author – Would it be possible to add an option for landscape orientation on the output file? The map is lovely, but I don’t like the output being tall. Maps look better (and are easier to hang on the wall) in landscape orientation, IMO. If it’s hard to add that option, maybe just provide a few of the paper sizes with the dimensions reversed, so the long edge comes first.

Leave a Reply

Your email address will not be published. Required fields are marked *