Euler method: Difference between revisions

Content added Content deleted
m (Added the Sidef language)
Line 1,379: Line 1,379:
</lang>
</lang>


=={{header|Mathematica}}==
=={{header|Mathematica}} / {{header|Wolfram Language}}==
Better methods for differential equation solving are built into Mathematica, so the typical user would omit the Method and StartingStepSize options in the code below. However since the task requests Eulers method, here is the bad solution...
Better methods for differential equation solving are built into Mathematica, so the typical user would omit the Method and StartingStepSize options in the code below. However since the task requests Eulers method, here is the bad solution...
<lang Mathematica>
<lang Mathematica>
Line 1,393: Line 1,393:
euler[10, 100]
euler[10, 100]
20.0005</pre>
20.0005</pre>

=={{header|Maxima}}==
=={{header|Maxima}}==
<lang Maxima>euler_method(f, y0, a, b, h):= block(
<lang Maxima>euler_method(f, y0, a, b, h):= block(