Differential equations: Difference between revisions
From JSXGraph Wiki
A WASSERMANN (talk | contribs) No edit summary |
A WASSERMANN (talk | contribs) No edit summary |
||
Line 5: | Line 5: | ||
</html> | </html> | ||
<jsxgraph width="500" height="500"> | <jsxgraph width="500" height="500"> | ||
var brd = JXG.JSXGraph.initBoard('jxgbox', {axis:true, boundingbox:[- | var brd = JXG.JSXGraph.initBoard('jxgbox', {axis:true, boundingbox:[-1,5,11,-5]}); | ||
var P = brd.create('point',[0,0], {name:'x_0'}); | var P = brd.create('point',[0,0], {name:'x_0'}); | ||
var f = function(t,xx) { | var f = function(t,xx) { | ||
Line 20: | Line 20: | ||
function ode() { | function ode() { | ||
return JXG.Math.Numerics.rungeKutta(JXG.Math.Numerics.predefinedButcher.Heun, [P.Y()], [0, | return JXG.Math.Numerics.rungeKutta(JXG.Math.Numerics.predefinedButcher.Heun, [P.Y()], [0, 10], 20, f); | ||
} | } | ||
Revision as of 09:38, 14 July 2010