Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / New Users / December 2005

Tip: Looking for answers? Try searching our database.

Solver Not Respecting Constraints

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Larry Curcio - 25 Dec 2005 14:47 GMT
Is there a known bug where the solver, in nonlinear mode,
ignores constraints? I'm constraining a decision variable to
be positive and getting a negative answer.

Here is a recording of the procedure:

SolverReset
   SolverAdd CellRef:="$B$2", Relation:=3, FormulaText:="0.000001"
   SolverAdd CellRef:="$C$2", Relation:=3, FormulaText:="0.000001"
   SolverAdd CellRef:="$D$2", Relation:=3, FormulaText:="0.000001"
   SolverAdd CellRef:="$E$2", Relation:=3, FormulaText:="0.000001"
   SolverOk SetCell:="$A$2", MaxMinVal:=1, ValueOf:="0",
ByChange:="$B$2:$E$2"
   SolverSolve

The D2 is coming up negative.

Thanks and Regards,
-Larry (New to Excel) Curcio
kcc - 29 Dec 2005 21:45 GMT
I've run problems with 40 constraints with no problems.
On a problem like this it's easier to enter all the constraints
on one line. e.g.
SolverAdd CellRef:="$B$2:$E$2", Relation:=3, FormulaText:="0.000001"
or in solver by entering the range in the cell reference box.
This is one of those areas where Excel is smart enough to
apply the constraint to each cell in the range and it seems to
do it more consistently than separate constraints.

Also, some option settings can also cause problems,
e.g. high tolerance or low iterations.  It may be assuming
a small negative number is close enough for what you are doing
kcc

> Is there a known bug where the solver, in nonlinear mode,
> ignores constraints? I'm constraining a decision variable to
[quoted text clipped - 15 lines]
> Thanks and Regards,
> -Larry (New to Excel) Curcio
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.