x finds y using newtons method

2 views (last 30 days)
Ryan Elway
Ryan Elway on 10 Nov 2017
Answered: Jan on 10 Nov 2017
I'm a little confused on how I would go about this problem. The function y=f(x) which given x finds y such that x=y+1/8cos(y^2) by performing 5 iterations using newtons method. The code should be within function definition.
Given:
function y=f(x)
y=x
[code goes here]
endfunction
any help with this would help me out tremendously!

Answers (1)

Jan
Jan on 10 Nov 2017
This is your homework. We can expect, that you have learned the details of the Newton method in the lessons, or you can find them at least in your text book or at https://en.wikipedia.org/wiki/Newton%27s_method. The WikiPedia article contains a "pseudo code" example, which can be converted to Matlab very easily.
Please try it and ask a specific question in case of problems.

Categories

Find more on Symbolic Math Toolbox in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!