www.gusucode.com > optim 案例源码 matlab代码程序 > optim/objfun.m
function f = objfun(x) %OBJFUN Objective function. % Documentation example. % Copyright 1990-2008 The MathWorks, Inc. f = exp(x(1)) * (4*x(1)^2 + 2*x(2)^2 + 4*x(1)*x(2) + 2*x(2) + 1);