14.01.2013 Views

Global Optimization Toolbox User's Guide - MathWorks

Global Optimization Toolbox User's Guide - MathWorks

Global Optimization Toolbox User's Guide - MathWorks

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

patternsearch<br />

problemtype — Type of problem: unconstrained, bound constrained<br />

or linear constrained<br />

pollmethod — Polling technique<br />

searchmethod — Search technique used, if any<br />

iterations — Total number of iterations<br />

funccount — Total number of function evaluations<br />

meshsize —Meshsizeatx<br />

maxconstraint — Maximum constraint violation, if any<br />

message — Reason why the algorithm terminated<br />

Note patternsearch does not accepts functions whose inputs are of<br />

type complex. To solve problems involving complex data, write your<br />

functions so that they accept real vectors, by separating the real and<br />

imaginary parts.<br />

Examples Given the following constraints<br />

⎡ 1<br />

⎢<br />

⎢<br />

−1<br />

⎣⎢<br />

2<br />

1⎤<br />

2<br />

1<br />

2<br />

⎥ ⎡ ⎤<br />

⎥ ⎢ ⎥ 2<br />

2<br />

1⎦⎥<br />

⎣ ⎦<br />

3<br />

0 0<br />

≤<br />

⎡ ⎤<br />

x ⎢ ⎥<br />

⎢ ⎥<br />

,<br />

x<br />

⎣⎢<br />

⎦⎥<br />

x ≥ , x ≥ ,<br />

1 2<br />

the following code finds the minimum of the function, lincontest6,<br />

that is provided with your software:<br />

A = [1 1; -1 2; 2 1];<br />

b = [2; 2; 3];<br />

lb = zeros(2,1);<br />

[x,fval,exitflag] = patternsearch(@lincontest6,[0 0],...<br />

A,b,[],[],lb)<br />

<strong>Optimization</strong> terminated: mesh size less than<br />

12-51

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!