Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
6
Task/Euler-method/Oforth/euler-method-1.oforth
Normal file
6
Task/Euler-method/Oforth/euler-method-1.oforth
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
: euler(f, y, a, b, h)
|
||||
| t |
|
||||
a b h step: t [
|
||||
System.Out t <<wjp(6, JUSTIFY_RIGHT, 3) " : " << y << cr
|
||||
t y f perform h * y + ->y
|
||||
] ;
|
||||
7
Task/Euler-method/Oforth/euler-method-2.oforth
Normal file
7
Task/Euler-method/Oforth/euler-method-2.oforth
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
: newtonCoolingLaw(t, y)
|
||||
y 20 - -0.07 * ;
|
||||
|
||||
: test
|
||||
euler(#newtonCoolingLaw, 100.0, 0.0, 100.0, 2)
|
||||
euler(#newtonCoolingLaw, 100.0, 0.0, 100.0, 5)
|
||||
euler(#newtonCoolingLaw, 100.0, 0.0, 100.0, 10) ;
|
||||
Loading…
Add table
Add a link
Reference in a new issue