The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: fmincon problem
Replies: 5   Last Post: Jul 18, 2011 3:22 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]

Posts: 33
Registered: 3/21/08
Re: fmincon problem
Posted: Jul 18, 2011 11:32 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Hello Matt,

Thanks for the reply. I corrected the ub and lb portion of my code.

I have not set the 'AlwaysHonorConstraints' option. It is probably set to the default value.

Some constraints of c(i) are off by as large AS 10 or 2000 ! So, it's not coming from the round-off error, I guess.

Your help will be very appreciated.

Thank again,


"Matt J" wrote in message <j013ed$em9$>...
> "Nazmul Islam" wrote in message <j00ji7$65k$>...
> >
> >
> > After I run the code, one of the W value comes out to be negative !!! However, I explicitly set a bound for W (between 0 and 900). So, it should not happen !

> ===================
> You've set ub and lb to scalars, which means only W(1) will be bounded.
> You need
> lb=[0,0,0];
> ub=[900,900,900];
> Aside from that, have you set the 'AlwaysHonorConstraints' option? We can't tell from the code you've shown.

> > Beside, one of the inequality constraint does not get satisfied, too ! I want all entries in the c vector to be negative. But some of them come out to be negative !
> =======================
> Could the non-negative c(i) simply be due to round-off error or incomplete convergence. How large are those values?

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.