Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Obtaining real answers with lsqcurvefit
Date: Thu, 2 Jul 2009 23:00:03 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 11
Message-ID: <h2je5j$rm4$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1246575603 28356 172.30.248.35 (2 Jul 2009 23:00:03 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 2 Jul 2009 23:00:03 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1895232
Xref: news.mathworks.com comp.soft-sys.matlab:552576


Hello all,

I'm fit a dataset to F=A.x^2+log(Bx+C).  My lower bounds for A, B and C are Zero, and my upper bounds vary between 10 and .1. 

After a few iterations, lsqcurvefit outputs imaginary estimates for A,B, and C.  

My question is:
1- How can I force it to output only real values?
2-How can I impose 0< Bx+C <.1?

Thanks!