+ Reply to Thread
Results 1 to 11 of 11

Excel Solver not solving problem, keeps spitting out an error.

  1. #1
    Registered User
    Join Date
    10-13-2023
    Location
    Birmingham England
    MS-Off Ver
    Excel
    Posts
    5

    Excel Solver not solving problem, keeps spitting out an error.

    Problem_1 (2) (1).xlsx



    The product portfolio problem asks which products a firm should be making. If there are contracts that obligate the firm to enter certain markets, then the question is which products to make in quantities beyond the required minimum. Consider Grocery Distributors (GD), a company that distributes 15 different vegetables to grocery stores. GD’s vegetables come in standard cardboard cartons that each take up 1.4 cubic feet in the warehouse.

    The company replenishes its supply of frozen foods at the start of each week and rarely has any inventory remaining at week’s end. An entire week’s supply of frozen vegetables arrives each Monday morning at the warehouse, which can hold up to 20,000 cubic feet of product. In addition, GD’s supplier extends a line of credit amounting to $33,000. That is, GD is permitted to purchase up to $33,000 worth of product each Monday. GD can predict sales for each of the 15 products for the coming week. This forecast is expressed in terms of a minimum and maximum level of sales. The minimum quantity is based on a contractual agreement that GD has made with a few retail grocery chains; the maximum quantity represents an estimate of the sales potential in the upcoming week. The unit cost and unit selling price for each product are known.

    How many cartons of each product should GD order at the start of the week to maximise its profit?


    this is the problem data I am trying to solve with excel solver. simpler problems work with it but it just refuses to work with this one. I know the constraints and everything but it theres some sort of conflict, can anyone help?

    regards

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

    Re: Excel Solver not solving problem, keeps spitting out an error.

    I don't replicate the problem. When I open your file and execute the Solver model, it quickly finds a solution and reports the solution (max profit of about $3500).

    You haven't told us which version of Excel, so the only thing I can think of is that my older version of Excel, that is limited to a few simpler solver algorithms (not that GRG nonlinear is necessarily simple), is using a different solver algorithm than yours. Maybe try a different solver algorithm.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  3. #3
    Registered User
    Join Date
    10-13-2023
    Location
    Birmingham England
    MS-Off Ver
    Excel
    Posts
    5

    Re: Excel Solver not solving problem, keeps spitting out an error.

    Microsoft® Excel® for Microsoft 365 MSO (Version 2309 Build 16.0.16827.20130) 32-bit is the version.


    I am using the solver however when I click solve, an error appears saying variable bounds conflict in binary or alldifferent constraint.

    I have tried the 3 different solving methods that are available to me. what could be going wrong?

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

    Re: Excel Solver not solving problem, keeps spitting out an error.

    Interesting. I see neither of those constraints in your solver model when I open it. My older version doesn't support an "all different" constraint, but it does support a "binary" constraint, but that constraint is not present when I open the Solver model. I don't see anything in the problem statement that would suggest "all different" or "binary" constraints would be part of the Solver model. Are you trying to apply a binary/all different constraint? Can you relax that constraint to see if the model will solve without an "all different" or "binary" constraint?

  5. #5
    Registered User
    Join Date
    10-13-2023
    Location
    Birmingham England
    MS-Off Ver
    Excel
    Posts
    5

    Re: Excel Solver not solving problem, keeps spitting out an error.

    by all different / binary constraint, does the program mean an actual constraint, with "bin" or "dif"? i have none of those.

    genuinely dont know where im going wrong. could you test to see if your solver runs and works on this file? this is a completed version of another problem with different constraints. it tells me the lower and upper bounds on variables allow no feasible solution for this one...

    Product_Portfolio_Problem.xlsx.xlsx

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

    Re: Excel Solver not solving problem, keeps spitting out an error.

    On the file in #5, I get the same result -- no feasible solution. I haven't looked at it in more detail, but that usually suggests that the problem is overspecified in the Solver model so that Solver cannot solve the problem and meet one or more of the constraints on the problem.

    For the file in the OP, I cannot explain why you would be getting a "conflict in binary or all different constraint" error if you have not told Solver to use either of those constraints.

  7. #7
    Registered User
    Join Date
    10-13-2023
    Location
    Birmingham England
    MS-Off Ver
    Excel
    Posts
    5

    Re: Excel Solver not solving problem, keeps spitting out an error.

    Problem_1 (2).xlsx


    Tinkered with it. Managed to get a solution through deleting the credit constraint. What could be causing it?

  8. #8
    Forum Expert
    Join Date
    09-01-2012
    Location
    Norway
    MS-Off Ver
    Office 365
    Posts
    2,844

    Re: Excel Solver not solving problem, keeps spitting out an error.

    In my experience Solver is buggy.
    <----- If you were helped by my posts you can say "Thank you" by clicking the star symbol down to the left

    If the problem is solved, finish of the thread by clicking SOLVED under Thread Tools
    I don't wish to leave you with no answer, yet I sometimes miss posts. If you feel I forgot you, remind me with a PM or just bump the thread.

  9. #9
    Registered User
    Join Date
    10-13-2023
    Location
    Birmingham England
    MS-Off Ver
    Excel
    Posts
    5

    Re: Excel Solver not solving problem, keeps spitting out an error.

    SOLVED!

    downloaded opensolver, immediately let me know that the $33,000 value is meant to be numeric. changed it to 33,000, and have got a result.

    Thank you all for input!

  10. #10
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Excel Solver not solving problem, keeps spitting out an error.

    I looked at this before anyone else posted, and I got the same error. I couldn't figure anything out so I didn't post. Given the fact that the problem was text in a numeric field (which I did not notice), the error message is really out of whack. Glad you solved it.
    Jeff
    | | |·| |·| |·| |·| | |:| | |·| |·|
    Read the rules
    Use code tags to [code]enclose your code![/code]

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

    Re: Excel Solver not solving problem, keeps spitting out an error.

    Interesting. I wonder why my older version had no trouble solving the problem. Double checking the original file, I do get a green error triangle indicating "number stored as text" in F41, but my version of Solver seemed to have no trouble with the number stored as text.

+ 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. Solving an Excel game with Solver
    By firstbornunicorn in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-02-2021, 11:01 AM
  2. Replies: 9
    Last Post: 07-17-2014, 11:48 AM
  3. Is Solver capable of solving my problem?
    By devpatel85 in forum Excel Programming / VBA / Macros
    Replies: 30
    Last Post: 01-26-2014, 11:06 PM
  4. Solving equation using the Solver Function of Excel
    By ltomilas in forum Excel General
    Replies: 2
    Last Post: 08-29-2013, 04:13 PM
  5. [SOLVED] Solving Engineering problem using Solver
    By mukund23534 in forum Excel General
    Replies: 5
    Last Post: 12-17-2012, 03:31 PM
  6. [SOLVED] Solver problem - macro to execute a Evolutionary Solving Method
    By timtim89 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-01-2012, 02:18 PM
  7. Solving a problem within VBA without using solver
    By xodus8 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-23-2011, 03:53 PM

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