title: How to convert GPS coordinates to decimal in Lua?
body: <p>I need to convert GPS coordinates from WGS84 to decimal using Lua.</p>
  
  <p>I am sure it's been done before, so I am looking for a hint to a code snippet.</p>
  
  <p>corrected question: Code to convert DMS (Degress Minutes Seconds) to DEG ((decimal) Degrees) in Lua?</p>
  
  <p>examples:
  Vienna: dms: 48°12'30" N 16°22'28" E
  or
  Zurich: dms: 47°21'7" N 8°30'37" E</p>
  
  <p>The difficulty I find is to get the numbers out of these strings. 
  Especially how to handle the signs for degree (°) minutes (') and seconds (").
  So that I would have for example a table coord{} per coordinate to deal with.</p>
  
  <pre><code>coord {1} [48]
  coord {2} [12]
  coord {3} [30]
  coord {4} [N]
  coord {5} [16]
  coord {6} [22]
  coord {7} [28]
  coord {8} [E]
  </code></pre>
  
  <p>Suggestions are appreciated, thanks.</p>