Help with calculating time

Hello

I have an issue that i'm not familiar with and again equally not knowledgable to do...so i'm looking for the answer.

the minimal increment a time to calculate on a spreadsheet that i'm working on is .25 minutes. If a user work time is 7.16 then his time within the spreadsheet is represented as 7.25.

My question what is the calculation to make sure any number below .25 is rounded up to .25?

Any help appreciated.

-Shamunda

I would like to thank all of you!!

Quote:

Originally Posted by

**AlephZero** If I understand your question correctly, you just want to know how to round up to the quarter-minute. I am assume that you're writing a computer program? I can tell you how to represent the problem mathematically in terms of functions, and then perhaps someone else can provide some efficient psuedocode.

Let $\displaystyle T$ represent the time worked in minutes. We want to round $\displaystyle T$ up to the nearest quarter-minute. Thus we're only concerned with the fractional portion of $\displaystyle T,$ let's call it $\displaystyle (T)$, and let's call the integer portion $\displaystyle [T]. $ Let $\displaystyle T_r$ be the rounded time. Then

$\displaystyle T_r=\begin{cases} [T]\quad\text{if } (T)=0 \\ [T] + 0.25 \quad\text{if } 0<(T)\leq 0.25 \\ [T] +0.5\quad\text{if } 0.25<(T)\leq 0.5 \\ [T] + 0.75\quad\text{if } 0.5<(T)\leq 0.75 \\ [T] + 1\quad\text{if } 0.75<(T)<1 \end{cases}$

Yes That's exactly what i'm looking for!! I apologize for my late response but yes that's exactly what i'm looking for. I can write out the code for it, but i'm afraid my math skills are greatly inefficient (Thinking)

Sham