Forum Discussion
Converting numbers in decimal to hours & minutes
This is from a while ago, but I was looking for the same thing pertaining to times given as decimals.
So 17.80 (A1) was suppose to convert to 17.48 (mm:ss). I have been using the following to calculate paces for running.
To convert 17.80
I used =((A1-17) * 60) / 100 + 17
This gives me 17.48
This means that for each cell where the minutes changed from 17 to 18 or 19, the formula needed to be adjusted where the 17 was replaced with whatever the minutes were.
The goal was to type in a race time for a 5k (3.1 mile), like 17:25, and have the pace for each mile given. So my quick, bs setup is:
A1 = [00:17:25] (as text, not as a time or number)
B1 =HOUR(A1) * 60 + MINUTE(A1) + SECOND(A1) / 60 [17.42]
C1 = B1/3.1 [5.618]
D1 = ((C1-5) * 60) / 100 + 5 [5.37]
Like I stated above, every time the "minutes" in cell C1 changes from 5 to 6 etc., then the "minutes" in the D1 formula need to be changed to match.
For the pace to be in kilometers (5k is 5 kilometers), I change C1 and D1 to be the following;
C1 = B1/5 [3.483]
D1 = ((C1-3) * 60) / 100 + 3 [3.29]
I still don't like the requirement for manually adjusting cells, but it works for what I need.
Probably a million ways to do this, most are probably easier, if someone else has a better way let me know.
-B
crossover250 Again, to me: it seems an unnecessary complication, given that each time one need to find the integer and fractional part of a number and excel seems to have decided a different definition of the floor and ceiling and relative functions (wrt what I have learned at high school as well as at university). This is true especially for time/date where somebody has input human readable numbers....