15.11.2014 Views

MATLAB Mathematics - SERC - Index of

MATLAB Mathematics - SERC - Index of

MATLAB Mathematics - SERC - Index of

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

4 Function Functions<br />

100<br />

80<br />

60<br />

40<br />

20<br />

0<br />

−20<br />

−1 −0.5 0 0.5 1 1.5 2<br />

Using a Starting Interval<br />

The graph <strong>of</strong> humps indicates that the function is negative at x = -1 and<br />

positive at x = 1. You can confirm this by calculating humps at these two points.<br />

humps(1)<br />

ans =<br />

16<br />

humps(-1)<br />

ans =<br />

-5.1378<br />

Consequently, you can use [-1 1] as a starting interval for fzero.<br />

4-22

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

Saved successfully!

Ooh no, something went wrong!