Rounding a duration to nearest 30 min?

I've been scanning the forums for information on rounding a duration to a fixed number of minutes, such as a quarter of an hour or 30 minutes.
Arbetad tid, januari
Datum
Start
Paus
Total tid
30-min-avrundat
7-jan-13
8:00
16:27
0:30
7:57
In this example, the last column is supposed to round the next to last column's 7:57 to 8:00, but I can't figure out how to do it. If the value had been 7:27, I would have liked it to round it to 7:30. All values are "durations" right now, as this was the only way I could find how to subract correctly...
Any ideas? Thanks!
/Robert

Hi Robert,
I know what you mean, but I am not an Excel guru.
My approach with any spreadsheet is to break the problem down into small steps. Then later I can combine solutions into more complex formulas, or hide the columns or tables that reveal my awkward small steps. Then I feel OK about showing the results to Aunt Nelly or the Head Teacher or a client.
With Durations, I tend to think in arithmetic to the base 60 (hours, minutes) rather than the usual arithmetic to base 10.
This may help:
A2 is formatted as Duration. However, it is ambiguous. Is it hr:min or wk:day or sec:ms?
B2 contains the formula =A2, but is formatted to show the units (hours minutes) from A2. Then we can be sure.
C2 contains this formula:
=DUR2MINUTES(B2)
D2 contains this formula:
=C2/60
E2 contains this formula:
=INT(D2)
F2 contains this formula:
=D2−E2
Now it is time for you to apply base 60 arithmetic .
Regards,
Ian,

Similar Messages

  • Rounding up to the nearest 0.05

    Hi guys i am trying to round a value up to the nearest 0.05. e.g. the value 94.63 would be rounded up as 94.65
    I have used big decimal with the round half up and round up modes but it still outputs 94.63
    How can I get arround this ?
    Cheers

          * Returns the value rounded up to the nearest 0.05
          * @param  double  value to be rounded
          * @return double  rounded up value
         private static double roundOff(double value)
              return Math.ceil(value / ROUNDUP_FACTOR) * ROUNDUP_FACTOR;
         }Where ROUNDUP_FACTOR = 0.05
    Edited by: fatjack on Dec 20, 2007 6:05 AM

  • Rounding stroke thickness to nearest decimal?

    I have a project where many objects have been scaled up and down during the creation of the artwork. And I'm left with some lines that are .9581 pts and some that are 1.039 pts.
    Just because I'm a neat freak, is there a script that would round the stroke thickness to the nearest .1 decimal? Or whole number? Or user selectable amount of decimals?

    Navarro Parker,
    loop through your path items of selection. This is simple, if only path items in your selection exists:
    // StrokeThicknessRoundingNearestDecimal.jsx
    // required: one or more selected stroked pathItem(s)
    // Rounding stroke thickness to nearest decimal
    // https://forums.adobe.com/message/6764907#6764907
    // regards pixxxelschubser
    var sel = app.activeDocument.selection;
    for (i=0; i < sel.length; i++) {
    if (sel[i].stroked == true) {
        sel[i].strokeWidth = Math.round(sel[i].strokeWidth*10)/10;
    But much more complicated, if there are compound paths or e.g. grouped paths or nested grouped grouped … paths and not possible for strokes which are added in the appearance palette.
    Have fun

  • Formulae - rounding down to the nearest five

    I am new to JAVA programming and not (yet) a brilliant mathematician. Can anybody tell me an algebra formula for rounding down to the nearest 5 (in 100)? Thanks in advance [email protected]

    Your question is not very clear.
    Still I think this would help
    //begin
    int remainder = number % 5 ;
    //We get the remainder
    number = number - remainder;
    //Trim down to the lower value
    if (remainder >= 3){
    number = number + 5 ;
    //If the remainder is 3 or more we should round to the higher value
    //End of block
    Hope this helps
    Shubhrajit

  • Needed to round a number to nearest thousand

    Hi all,
    Can any one say is there any function to round a number to nearest thousand.
    example == 73882 it must be rounded to 74000.
    Thanks
    Ravi
    use small case when you are posting the questions
    Edited by: Vijay Babu Dudla on Dec 15, 2008 12:09 PM

    Hi
    try this:
    DATA: V_IN TYPE I VALUE 73882,
          V_OUT TYPE I.
    DATA: V_1  TYPE I.
    V_1 = V_IN DIV 1000 + 1.
    V_OUT = V_1 * 1000.
    WRITE V_OUT.
    or
    DATA: V_IN TYPE I VALUE 73882,
          V_OUT TYPE I.
    DATA: V_1  TYPE I,
          V_2  TYPE I.
    DATA: V_DELTA1 TYPE I,
          V_DELTA2 TYPE I.
    V_1 = V_IN DIV 1000.
    V_DELTA1 = ABS( V_1 * 1000 - V_IN ).
    V_2 = V_1 + 1.
    V_DELTA2 = V_2 * 1000 - V_IN.
    IF V_DELTA1 < V_DELTA2.
      V_OUT = V_1 * 1000.
    ELSE.
      V_OUT = V_2 * 1000.
    ENDIF.
    WRITE V_OUT.
    Max

  • How to round numbers to the nearest .25

    I would like to enter a number in one field and have it rounded to the nearest .25 in another column - (whether that's rounding up or down)
    Example:
    Actual Size
    Adjusted Size
    7.21435
    7.25
    Any help would be appreciated.
    Thanks!

    Hi c,
    The ROUND function limits the precision choices to powers of 10, so we need to work within that limitation:
    Multiply by four, round to the nearer whole number, divide by four.
    Formula in column B: =ROUND(A*4,0)/4
    All cells in B are formatted as Number, with decimal places set to 2.
    Regards,
    Barry

  • Rounding text size to nearest whole number?

    I've had to rescale some artwork, but now I'm left with type sizes that are 71.68px tall, 34.51px tall, etc.
    Is there a script that'll snap all the text in a document to it's nearest whole number or 0.1 decimal?

    // rounds the size of text in all textFrames in your document
    var aTFrame = app.activeDocument.textFrames;
    for ( i = 0; i < aTFrame.length; i++ )
    var fractionSize = aTFrame[i].textRange.characterAttributes.size;
    var RoundedSize = Math.round(fractionSize);
    aTFrame[i].textRange.characterAttributes.size = RoundedSize;
    redraw();
    This will do all the text frames. Copy the above, paste it into a text editor or the Adobe ESTK (ExtendScript Tool Kit) and save as a plain text file with a .jsx extension. Place it into Applications/Adobe Illustrator CSX/Presets/en_US/Scripts folder and restart AI. Run it by having a document open in AI and call it from File>Scripts>scriptname.

  • Rounding float value to nearest 0.05

    Hi,
    can you tell me if there is a convenient way to round off a float ot double to nearest 0.05.
    Example: 18.93 -->18.95 and 18.92 --> 18.90

    Yes. Multiply it by 20. Round to the nearest integer. Divide by 20.

  • Rounding time field to nearest half hour

    Post Author: fiscyn
    CA Forum: Formula
    Is there a way to round a time field?
    For example,  if a time field is from 9:01 to 9:14  I want it to round back to 9:00;  
    9:15 to 9:29  or 9:31 to 9:44   I want either option to round to 9:30
    and 9:45 to 9:59 I want to round to 10:00.
      I want to keep the original time and have the rounded time listed next to it.    Also I want this for a 24 hour clock, military time.  Don't know if that makes a difference.
    Any help is appreciated.
    Thanks.

    Post Author: fiscyn
    CA Forum: Formula
    I'm slowly getting this to work.    Just a couple problems,  minor I hope.
    I used the CTime function and used the rounding formulas for minutes and hours as you suggested.  It works great.   But the results for the hours come out as 12.00  and the minutes as 30.00 or 0.00.   How do I drop the decimals?   I tried the totext, 0 function,  but the numbers don't line up correctly.   If the hour is 9.00,  it drops the zero place holder.   So if 9 and 10 are lined up,  the 9 is above the 1 instead of the 0.  
      It works fine for the minutes except I end up with 0 instead of 00.   Any suggestions?
    I greatly appreciate the help so far.   Thank you.

  • IDVD error - total menu duration exceeds 15 min.  How do I correct this?

    Sometimes this error pops up, and asks me if I want to fix it, and it fixes automatically. But most of the time it doesn't give me the option. How do I fix this myself? thanks.

    If iDVD won't give you the fix option, then maybe your iDVD preferences have become corrupted. Try closing down iDVD and then trashing the file com.apple.iDVD.plist found in User/Library/Preferences. iDVD will create a new .plist file on relaunch. Then do a permissions repair using the Utilities/Disk Utility app on your Mac.
    If that doesn't solve it, then you will need to eliminate or to manually shorten some of the clips that you put into your motion menus. To shorten the clips, before putting the clip into iDVD shorten it in iMovie and export the shortened clip to your desktop as a Full Quality Quicktime movie. Then drag the shortened quicktime movie into your iDVD motion menu.

  • Data usage rounded up to nearest GB in Bill summary; Cannot download details as spreadsheet

    Two problems:
    1. Bill summary misrepresents data usage, rounding up to the nearest GB, for one of our 4 lines.
    2. Data detail "download to spreadsheet" does not work.
    My account has 4 lines. I have an old Family Share plan (no longer available) for 700 minutes; a "feature" for unlimited text; and individual data plans for each of the 4 lines. My daughter has a 2 GB data plan.
    Latest Verizon Wireless bill says my daughter used 1.0000000 GB of data. She didn't think so. I logged in to Verizon, went to "View Bill". then for the Bill Period: May 29, 2014 - June 28, 2014, I selected "Details for" > "DATA". I see all the usage by date and time; I can adjust the display from default "KB" to "MB". Then I clicked the link "Download to SpreadSheet ".
    Unfortunately, I get a file with only one line, just the headers, no data:
    "Date"    "Time"    "Usage Type"    "Description"    "Minutes"    "Application Price"    "Total"
    As a workaround, I can select and copy the data on the web page, then paste it into a spreadsheet program. I added a "sum()" formula and found that she used only 325 MB, not 2 GB.

    Does the bill say she used 1 GB or 2 GB? You had mentioned them both.
    As far as the usage, it's not too say she literally used that much but to say that she used that much or less. It may not matter since she has the 2 GB/$30 which means that you would be billed the same way either way.
    Your inability to download the spreadsheet may be due to an issue with your browser.

  • WT rounding to nearest $

    I want to be able to add hours to a wage type as well as dollars for the recurring payments. The calculation needs to round up to the nearest dollar.
    I understand That in table T511 I need to put a "+" sign against amount and number both.
    For rounding it to nearest dollar, I need to put "100" as a value in rounding divisor.
    Please let me know if I'm not on correct lines.
    Thanks

    Experts, Any inputs plz....

  • Rounding to nearest .5

    Hi
    I have a column which holds the byte size of the data row. I would like to round this to the nearest .5
    example
    1.23453 = 1
    1.345 = 1.5
    1.6523 = 1.5
    1.7893 = 2
    Does anyone know how to do this easily without have to cerate an user defined function.
    Cheers
    Gary

    BluShadow wrote:
    Ah, beaten by the young lady with the trombone. ;)
    laughs Flattery will get you everywhere *{;-)                                                                                                                                                                                                                                                                                                   

  • Always round up to nearest whole in APO DP

    Hi
    there is a requirement to always round up data to nearest whole number. number should be always rounded above and not rounded down.
    Example a value of 0.07 should be rounded to 1
    a value of 1.25 should be rounded to 2
    a value of 1.75 should be rounded to 2
    a value of 1.07 should be rounded to 2
    and so on
    Is there a way i can achieve in APO DP by some settings/paramater/config/macro/exit etc etc - i am on SCM 7.0
    Thanks,
    TJ

    Tejinder
    Try using the CEIL() function in a macro.
    Rishi Menon

  • Help with rounding to nearest multiples of n-1 !!

    i need help writing part of a program;
    start with int n, then round ***up*** to the nearest multiple of n-1; then round **this** value up to the nearest multiple of n-2. (the final step is to round up to the nearest multiple of 2)
    eg
    if n=10;
    9 -> 18
    8->24
    7->28
    6->30
    2->34.
    Please help me with this, i'm really not sure where to begin !

    it's a program to do with the approximation of pi;
    so far i have;
    public double pi (int n) {
    double f; (this is the final value of the nearest
    multiple of 2)
    then from here i'm really not sure how to go about
    it..... in other words i haven't gotten very far.Okay. I'm currious as to how this helps in the approximation of PI. Would you mind posting that?
    I'll give you a few hints. The mod operator "%" tells you the distance a number is from the multiple of n immediately bellow a positive number.
    The Math.IEEERemainder function tells you the distance a number is from the nearest multiple of n (whether above or below).
    I'll leave it to you to figure out how to find the nearest multiple ABOVE the number, and how to use that to round the number. It's actually not all that hard.
    - Adam

Maybe you are looking for

  • Join running JVM

    My program is win32 EXE written in C++. It calls java method through JNI. Now I must create and start new JVM each time the exe is started. Is it possible to find and join JVM that is already running?

  • Integrating Apache with Tomcat?

    Anyone have a guide to integrating Apache with Tomcat using mod_jk? I followed some guides online, but they all seem really dated with some obscure references. This seems like it should be on the top of the list....

  • Elements 8 on iMac running 10.6.8

    I'm running OS 10.6.8 on an iMac. I have Elements 8 loaded and running. Now when I went to open the program, I got a message suggesting that the program was incompatible with my system and that I might need to update or reinstall the program. So I tr

  • Cisco Prime 2.0 - System-Defined Jobs keep running

    Hi PI Experts, The following two jobs keep running for two weeks. Is it normal? They are under Job Dashboard -> System-Defined. Not sure what are they for. Cannot find them with google. Is there any way to stop them from running if it's not normal? S

  • CTS+ - How to hide "export using Filesystem" from PI tool?

    Hi experts, I have already implemented "How To  Configure Enhanced CTS PI 7.1", now I wonder If it is possible to hide export using Filesystem since I would like to force people using "Export using CTS" from PI tools. I have alredy surfing on interne