new RungeKutta4(derives, t0, yStart, h)
The fourth order Runge-Kutta integration method
Parameters:
| Name | Type | Description |
|---|---|---|
derives |
function | Differential equations which needed to integrate |
t0 |
Number | Initial value problem: starting time |
yStart |
Array | Initial value problem: y0 |
h |
Number | Each step-size value |
- Source:
Methods
end(tEnd) → {Array}
Calculate according to xEnd
Parameters:
| Name | Type | Description |
|---|---|---|
tEnd |
Number | final t |
- Source:
Returns:
Calculated result at xEnd
- Type
- Array
step() → {Array}
Calculate each step according to step-size h
- Source:
Returns:
calculated result at this.t
- Type
- Array
steps(steps) → {Array}
Calculate according step times
Parameters:
| Name | Type | Description |
|---|---|---|
steps |
Number | Iterative times |
- Source:
Returns:
Calculated result at this.t
- Type
- Array