+ Reply to Thread
Results 1 to 5 of 5

formula to increase by a decimal does not work

  1. #1
    Registered User
    Join Date
    10-19-2011
    Location
    Barkhamsted, CT
    MS-Off Ver
    Excel 2013
    Posts
    22

    formula to increase by a decimal does not work

    Good day All,
    To put it simple I have the number -58 in A1. I type =A1+0.2 in cell A2. The result is -57.8 as expected. I then copy A2 and paste into A3-A100. All is good until it gets to where it should be say -54.4 where is says -54.39999999999... The numbers go up to 302 so I do not wish to hand type it all. It seems to work fine if the formula is not a decimal. Any ideas?

    Thank you,
    Ken

  2. #2
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,827

    Re: formula to increase by a decimal does not work

    That is one of the classic examples used to illustrate floating point error (more than you want to know about floating point arithmetic and errors: https://www.excelforum.com/groups/ma...nd-errors.html ). The usual first solution is to incorporate a ROUND() (or similar) function. =ROUND(A1+0.2,1) for example.

    Will that work for you?
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  3. #3
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,827

    Re: formula to increase by a decimal does not work

    There are instructions at the top of the page explaining how to attach your sample workbook.

    A good sample workbook has just 10-20 rows of representative data that has been desensitised. It also has expected results mocked up, relevant cells highlighted and a few explanatory notes.

    Administrative Note:

    Members will tailor the solutions they offer to the version of Office (Excel) that you have. Please check that your forum profile is up-to-date in this respect. If you aren't sure, in Excel go to File | Account and report what it says below the MS logo at the top of that page. If your version is for Mac, please also state this. Thanks.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  4. #4
    Registered User
    Join Date
    10-19-2011
    Location
    Barkhamsted, CT
    MS-Off Ver
    Excel 2013
    Posts
    22

    Re: formula to increase by a decimal does not work

    MrShorty,
    Thank you very much. I was so frustrated with why it wasn't working, I did not even think of using the Round function.

    Have a great weekend and Merry Christmas, Happy Holidays.

    Ken

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,827

    Re: formula to increase by a decimal does not work

    Are you still using Excel 2013? If not, please update your profile as requested.

    Please remember to acknowledege ALL messages in your threads. Thanks.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How to increase the decimal value in excel with VBA
    By Sekar G in forum Excel General
    Replies: 4
    Last Post: 01-29-2022, 02:13 AM
  2. create a formula for increase/decrease decimal
    By ammartino44 in forum Excel General
    Replies: 1
    Last Post: 07-06-2015, 05:15 PM
  3. How to increase the decimal value in a loop
    By Karthik Sen in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-17-2014, 12:37 PM
  4. [SOLVED] Change hh:mm to hh:decimal eg 12:30 to 12.5 but already have formula for work hours in cel
    By doobynuts in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-30-2013, 03:29 AM
  5. Replies: 2
    Last Post: 08-15-2011, 01:52 AM
  6. [SOLVED] increase/decrease decimal
    By cbfinancial in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-10-2006, 05:50 PM
  7. increase/decrease decimal via short key
    By andrei.aksenov@ in forum Excel General
    Replies: 1
    Last Post: 03-15-2005, 08:30 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1