+ Reply to Thread
Results 1 to 5 of 5

Excel - Iterations/Calculations Speed Extremely Slow - Please help

  1. #1
    Registered User
    Join Date
    06-20-2014
    Location
    London
    MS-Off Ver
    Office 2007
    Posts
    45

    Lightbulb Excel - Iterations/Calculations Speed Extremely Slow - Please help

    Hi All,

    I have attached a small spreadsheet of the larger one which we use. The larger spreadsheet has around 100k rows and is constantly increasing, this one uploaded is very small and only has 90 rows. However, all the columns exist in the smaller sheet too. Please refer to the below link for the sheet as it is too large to upload here:

    https://www.dropbox.com/s/pzov3kidwd...heet.xlsx?dl=0

    Moreover, for confidential reasons, I have had to change the name of headings and data as this is for my work place. Although, all the formula etc. remains exactly how it is on the larger complete sheet. Unfortunately, when we run calculations and iterations, it takes hours and hours for it to complete. I appreciate there is a lot of formula, is there something I am missing, or is there a function I have switched on/off that could resolve this issue I am having.

    The Max iterations we have got it set to is 100, and the maximum change is 0.001 - Does this all need changing.

    I know the spreadsheet is fairly large and may take a while to go through, but I would be most grateful if anyone can help.

    Furthermore, even opening, saving and closing takes an awful long time. We are talking 5 ish minutes for this. But it would be great if there was a fix to this too.

    I look forward to help and advice. Thanks in advance.

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Excel - Iterations/Calculations Speed Extremely Slow - Please help

    Can you attach the file to a post here rather than DropBox?
    If posting code please use code tags, see here.

  3. #3
    Registered User
    Join Date
    06-20-2014
    Location
    London
    MS-Off Ver
    Office 2007
    Posts
    45

    Re: Excel - Iterations/Calculations Speed Extremely Slow - Please help

    Quote Originally Posted by Norie View Post
    Can you attach the file to a post here rather than DropBox?
    Unfortunately, I cannot because this file is 21mb and the limit for upload is 10mb. Thanks.

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

    Re: Excel - Iterations/Calculations Speed Extremely Slow - Please help

    For those who don't like to download from another hosting service, it seems like it should be possible to illustrate your spreadsheet with smaller lookup tables in "postage", since that seems to be where a lot of the data storage is.

    A couple of things I see:

    1) There appear to be a lot of lookups within the "circular reference" section. Each of these lookups is using a less efficient "linear" search algorithm, because you are forcing an exact match (4th argument of VLOOKUP() function is FALSE). Binary search (4th argument is TRUE and lookup table is sorted in ascending order) is much faster than a linear search. You might look at your lookup table and your lookups and see if you can arrange them to use the much more efficient binary search algorithm.

    2) For a given row, it seems that all of the lookup functions are essentially looking for the same thing -- where is the value in column P in the lookup table. You might consider a strategy I suggested here (http://www.excelforum.com/showthread...=1#post4041181 ) where you perform the lookup once per row with a MATCH() function, then use several INDEX() functions to extract the desired information.

    3) I have not thoroughly explored the iterative calculation. Clearly if you can rearrange the calculation to not require a circular logic, you can reduce the calculation time by reducing the number of calculations per calculate event. Iteration can dramatically increase the number of calculations, so eliminating the circular reference can yield significant savings.

    That should be a start.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  5. #5
    Registered User
    Join Date
    06-20-2014
    Location
    London
    MS-Off Ver
    Office 2007
    Posts
    45

    Re: Excel - Iterations/Calculations Speed Extremely Slow - Please help

    Quote Originally Posted by MrShorty View Post
    For those who don't like to download from another hosting service, it seems like it should be possible to illustrate your spreadsheet with smaller lookup tables in "postage", since that seems to be where a lot of the data storage is.

    A couple of things I see:

    1) There appear to be a lot of lookups within the "circular reference" section. Each of these lookups is using a less efficient "linear" search algorithm, because you are forcing an exact match (4th argument of VLOOKUP() function is FALSE). Binary search (4th argument is TRUE and lookup table is sorted in ascending order) is much faster than a linear search. You might look at your lookup table and your lookups and see if you can arrange them to use the much more efficient binary search algorithm.

    2) For a given row, it seems that all of the lookup functions are essentially looking for the same thing -- where is the value in column P in the lookup table. You might consider a strategy I suggested here (http://www.excelforum.com/showthread...=1#post4041181 ) where you perform the lookup once per row with a MATCH() function, then use several INDEX() functions to extract the desired information.

    3) I have not thoroughly explored the iterative calculation. Clearly if you can rearrange the calculation to not require a circular logic, you can reduce the calculation time by reducing the number of calculations per calculate event. Iteration can dramatically increase the number of calculations, so eliminating the circular reference can yield significant savings.

    That should be a start.
    Thanks for your input.

+ 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. Replies: 9
    Last Post: 07-17-2015, 10:02 AM
  2. Excel chart extremely slow while printing
    By Proliner in forum Excel General
    Replies: 0
    Last Post: 08-29-2013, 03:44 PM
  3. [SOLVED] Calculations running extremely slow, any suggestions
    By Dena in forum Excel General
    Replies: 1
    Last Post: 08-09-2013, 02:01 PM
  4. HELP! Extremely slow excel file
    By floripabay in forum Excel General
    Replies: 1
    Last Post: 06-29-2011, 06:07 AM
  5. Excel is extremely slow now
    By Martindelica in forum Excel General
    Replies: 0
    Last Post: 05-01-2007, 08:32 PM
  6. Excel vba script extremely slow
    By persenena in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-05-2005, 08:05 AM
  7. [SOLVED] Excel extremely slow opening and using
    By domestic911 in forum Excel General
    Replies: 2
    Last Post: 01-26-2005, 05:06 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