Tag Archives: math.floor

When looking through some of my old papers I found at my father’s house after he died, I found some old Fortran code for converting Gergorian calendar dates to and from Julian dates. I haven’t used Fortran since the 1970s, so the code looked a little strange. Some examples of Julian dates: Julian Date Equivalent… Read More »

I needed a function to truncate a number. Math.floor() worked … until I tried it on a negative number. So I had to write my own truncate function. Even though I needed to truncate numbers to the integer portion only, I figured sooner or later I would need to truncate to a given number of… Read More »