Bisection Method to Find Root of the Equation f(x) = x² - 3.
Version 1.0.0 (1.7 KB) by
Prem Manoj Mule
This MATLAB program finds the root of f(x) = x² - 3 using the Bisection Method. It keeps dividing interval & checks the error at each step.
The Bisection Method is a numerical technique used to find the root of a function within a given interval where the function changes sign. This method ensures convergence by iteratively halving the interval and selecting the subinterval that contains the root.
✅ User inputs initial bracketing values (a, b).
✅ Checks if f(a) and f(b) have opposite signs (valid interval).
✅ User inputs the number of iterations for refinement.
✅ Displays iteration-wise updates, including:
- Interval endpoints a and b.
- Function values f(a) and f(b).
- Midpoint c and its function value f(c).
- Error at each step.
✅ Outputs the final approximate root after the given iterations.
How to Use:
1️⃣ Run the script in MATLAB.
2️⃣ Enter the first bracketing value (a) and second bracketing value (b).
3️⃣ Ensure that f(a) and f(b) have opposite signs.
4️⃣ Enter the number of iterations for the method to refine the root.
5️⃣ The script will display each iteration’s results and the final approximate root.
Cite As
Prem Manoj Mule (2025). Bisection Method to Find Root of the Equation f(x) = x² - 3. (https://uk.mathworks.com/matlabcentral/fileexchange/180386-bisection-method-to-find-root-of-the-equation-f-x-x-3), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Created with
R2024b
Compatible with R2020a and later releases
Platform Compatibility
Windows macOS LinuxTags
Acknowledgements
Inspired by: Bisection Numerical Method, Solve 65*x^5 -70*x^3 + 15x = 0 Using the Bisection Method
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
| Version | Published | Release Notes | |
|---|---|---|---|
| 1.0.0 |
