Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
NCTM or The Math Forum.



Re: nlinfit
Posted:
Mar 11, 2013 3:54 PM


>> > function f=order1(a,x1,x2) >> > f=(a(1)*x1)+((a(2)*a(3)*x1)/(1+a(3)*x1+a(4)*x2)); ... > I did that but now I'm getting this error: > > ??? Error using ==> nlinfit at 127 > MODELFUN should return a vector of fitted values the same length as Y.
I suspect you want elementwise division using "./" instead of "/" for matrix division.
 Tom



