{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

findzero - y1 =.4*x1^2 7*x1 35 y2 =.4*x2^2 7*x2 35 if(ymid...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
% 3/31/2011 % Topic: Recursive (iteration) % function out = findzero(x1,x2) if abs(x1-x2) < .0001 out = x1; else xmid = (x1+x2)/2; ymid = -4.*xmid^2+n*xmid+35;
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: y1 = -.4.*x1^2+7*x1+35; y2 = -.4.*x2^2+7*x2+35; if (ymid * y1) <= 0 out = findzero(x1, midx); else out = findzero(midx, x2);...
View Full Document

{[ snackBarMessage ]}