Converting degree, minute, second to decimal value and vice versa.
Note: the same process is applicable also to convert time from hour minute and second to decimal values.

To convert from degree (d) minute (m) second (s) to
decimal (D) values use the equation: 


To convert from decimal (D) to degree (d), minute (m) and second (s) use the following steps:
d = integer portion of D
remainder = D ⎯ d
m = integer portion of (remainder * 60)
remainder = remainder * 60 ⎯ m
s = remainder * 60

Example: convert angle of 4degree 15 minute and 40 seconds to decimal value. 
The value in decimal will be

Example: convert 1.56 hours from decimal value to hour, minute and second values. 
According to the steps presented for angle conversion from decimal to d, m and s (change h instead of d) we have:
h = 1
remainder = 1.56 ⎯ 1 = 0.56
m = integer (0.56 * 60) = integer (33.6) = 33
remainder = 0.56 * 60 ⎯ 33 = 0.6
s = 0.6 * 60 = 36
The value is: 1 hour, 33 minutes and 36 seconds.
