Runge-Kutta method: Difference between revisions

Content deleted Content added
Grondilu (talk | contribs)
→‎{{header|Perl 6}}: golfing a bit
Grondilu (talk | contribs)
m →‎{{header|Perl 6}}: minor rewrite
Line 502: Line 502:
t + δt, y + 6 R/ [+] <1 2 2 1> Z*
t + δt, y + 6 R/ [+] <1 2 2 1> Z*
map {
map {
state $yp = 0;
state $dy = 0;
δt* ($yp = yp(t + $_*δt, y + δt*$_*$yp))
$dy = δt * yp(t + $_*δt, y + $_*$dy)
}, <0 1/2 1/2 1>;
}, <0 1/2 1/2 1>;
}
}