Code covered by the BSD License  

Highlights from
Tips & Tricks: Getting started using optimization with MATLAB

image thumbnail
from Tips & Tricks: Getting started using optimization with MATLAB by Stuart Kozola
Demo files from the August 21, 2008 Webinar

myCurveFcn(x,t,y)
function resid = myCurveFcn(x,t,y)

% x is the vector of coefficiencts
% t is the time vector
% y is the obesrvations at given t
% resid is the residual (or error)

yhat = x(1) + x(2)*exp(-t);
resid = yhat -y;

Contact us at files@mathworks.com