def to_brng deg, format = :dms, dp = 0
      deg = (deg.to_f + 360) % 360  # normalise -ve values to 180º..360º
      brng = Dms.to_dms deg, format, dp
      brng.gsub /360/, '0'  # just in case rounding took us up to 360º!
    end
def to_brng deg, format = :dms, dp = 0
      deg = (deg.to_f + 360) % 360  # normalise -ve values to 180º..360º
      brng = Dms.to_dms deg, format, dp
      brng.gsub /360/, '0'  # just in case rounding took us up to 360º!
    end
Convert numeric degrees to deg/min/sec as a bearing (0º..360º)

 @param   {Number} deg: Degrees
 @param   {String} [format=dms]: Return value as 'd', 'dm', 'dms'
 @param   {Number} [dp=0|2|4]: No of decimal places to use - default 0 for dms, 2 for dm, 4 for d
 @returns {String} Deg/min/seconds