Newton's root finding method: Difference between revisions

From JSXGraph Wiki
No edit summary
No edit summary
Line 14: Line 14:
<tr><td>&nbsp;</td></tr>
<tr><td>&nbsp;</td></tr>
<script type="text/javascript">
<script type="text/javascript">
function newGraph(v) {
eval("term = function(x){ return "+v+";}");
graph = function(x) { return term(x); };
g.Y = function(x){ return term(x); };
g.updateCurve();
        board.update();
}
// Initial function term
// Initial function term
//var term = function(x) { return x*x; };
//var term = function(x) { return x*x; };
Line 56: Line 66:
     }
     }
}
}
function newGraph(v) {
eval("term = function(x){ return "+v+";}");
graph = function(x) { return term(x); };
g.Y = function(x){ return term(x); };
g.updateCurve();
        board.update();
}
</jsxgraph>
</jsxgraph>

Revision as of 14:13, 3 February 2010

xo is the start value. Drag it.

You may change the function term here:
f(x) =