Cody

Problem 965. False position (linear interpolation) method of finding a root.

Solution 867421

Submitted on 6 Apr 2016
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Fail
f=@(x) x.^2-4; x_lower = 1; x_upper = 3; es = 0; maxit=1; y_correct = 1.75; assert(isequal(false_position(f,x_lower,x_upper,es,maxit),y_correct))

Error using false_position (line 13) Undefined function or variable 'x'.

Suggested Problems

More from this Author17

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!