Solved

# formula for converting DD to DMS (waypoints)?

Posted on 2005-04-10
Medium Priority
1,233 Views

what is the formula for converting the following:

Degree Decimal  Example: lat = 37.379   lon = -122.061

TO

Degree Minute Second Example: lat= 37°22'44.4" N   lon = 122° 2'39.6" W

Please explain how to determine the N/W portions of the waypoint

IELite
0
Question by:IElite

LVL 85

Assisted Solution

ozo earned 1000 total points
ID: 13750501
Degree = floor(37.379)
Minute = floor((37.379-Degree)*60)
Second = ((37.379 - Degree) *60 - Minute) * 60
0

LVL 6

Expert Comment

ID: 13750815
decimal to minutes : (replace ceiling function with int if negative value)
deg = int(lat)
min = int((lat-deg)*60)
sec = ((lat-deg)*3600) % 60

minute to decimal :

lat = deg + min/60 + sec/3600

* same for lon
** -/+ sign : if MINUS is used , ceiling function must replace the integer function
0

LVL 31

Accepted Solution

GwynforWeb earned 1000 total points
ID: 13754915
IElite,
All the equations you will use will have trigonometric function in them (eg, sin, cos etc). You  will require radians not degrees to use your formulea, just convert the degrees into radians ie

and use those values in the formulea

eg
lonDegree=37.379

0

## Featured Post

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A Guide to the PMT, FV, IPMT and PPMT Functions In MS Excel we have the PMT, FV, IPMT and PPMT functions, which do a fantastic job for interest rate calculations.  But what if you don't have Excel ? This article is for programmers looking to re…
How to Win a Jar of Candy Corn: A Scientific Approach! I love mathematics. If you love mathematics also, you may enjoy this tip on how to use math to win your own jar of candy corn and to impress your friends. As I said, I love math, but I gu…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…
###### Suggested Courses
Course of the Month14 days, 9 hours left to enroll