+ Reply to Thread
Results 1 to 5 of 5

Solver and integers

Hybrid View

VReijs Solver and integers 08-05-2010, 02:48 PM
Alf Re: Solver and integers 08-13-2010, 02:39 PM
VReijs Re: Solver and integers 08-14-2010, 05:22 AM
markwiley Re: Solver and integers 08-16-2010, 08:48 AM
VReijs Re: Solver and integers 08-16-2010, 03:34 PM
  1. #1
    Registered User
    Join Date
    07-17-2008
    Location
    Ireland
    Posts
    5

    Solver and integers

    Hello Excel experts,

    I am using Excel Solver and the parameters to be changed is the Month (so an integer, and a non integer values would be interpretated as days, which is not allowed in my case). I use Tolerance at 0.1% and if I put the solver in 'Show Iteration Results' mode, I see the value (which I declared as integer) being changed as a real (the month becomes for instance 11.00003, while I would like to see 10, 11, 12).

    Any help. Thanks for your help on this. I am trying to use Solver to see when (which month and year) a particular sundial is best showing the time.

    Thanks all the best,


    Victor

    P.S. WIndows XP
    excel 2003

  2. #2
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,787

    Re: Solver and integers

    Perhaps changing the formate of the target cell to number formate with no decimals will solve your display problem?

  3. #3
    Registered User
    Join Date
    07-17-2008
    Location
    Ireland
    Posts
    5

    Re: Solver and integers

    Quote Originally Posted by Alf View Post
    Perhaps changing the formate of the target cell to number formate with no decimals will solve your display problem?
    I tried it, but this does not help (I think formatting is only a presentation option, not a definition of the type of variable in a spreadsheet).

    Still searching for a solution on this...

  4. #4
    Registered User
    Join Date
    08-14-2010
    Location
    Chicago, USA
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Solver and integers

    Quote Originally Posted by VReijs View Post
    I tried it, but this does not help (I think formatting is only a presentation option, not a definition of the type of variable in a spreadsheet).

    Still searching for a solution on this...
    Given the finite precision of computers the solver has tolerances build into it. It assumes that 11.00003 is close enough to an integer value. You can try tightening down the one such tolerance it allows you access to. Select Tools|Solver and then the Options button. The Default setting for Precision is 0.000001. Try making it smaller (perhaps even 0). If this does not affect things you could send me your model -- there may be more I can suggest after looking at it.

    Mark
    mark(at)lindo.com

  5. #5
    Registered User
    Join Date
    07-17-2008
    Location
    Ireland
    Posts
    5

    Re: Solver and integers

    Quote Originally Posted by markwiley View Post
    Given the finite precision of computers the solver has tolerances build into it. It assumes that 11.00003 is close enough to an integer value.
    The problem is that the Solver does not add an integer value as it only adds 0.0003 and not 1 or 2 or something like that.
    Quote Originally Posted by markwiley View Post
    If this does not affect things you could send me your model -- there may be more I can suggest after looking at it.
    Will work on this, the problem is that it needs another Add-In (made by myself), which needs to be added in that case...
    Will see if I can reproduce the problem in a smaller environment (without this Add-In).
    Thanks for offering to look at it.

    All the best,


    Victor

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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