Taylor order 3Documentation
Description
- Approximates the numerical solution of an ordinary differential equation (ODE) of the form:$$ \frac{\mathrm{d}y}{\mathrm{d}t} = f(t, y) = y - t^2 + 1, \quad a \leq t \leq b, \quad y(a) = \alpha $$Here, $a$ and $b$ are the start and end points of the time interval, and $\alpha$ is the initial value of $y$ at time $t = a$.
1. Method:string,
The initial value method used to integrate the ODE.
2. ODE equation:string, string[ ]
The ODE equation to be integrated numerically.
3. Exact solution:None, string, optional (default=None)
The exact solution of the ODE.
4. Derivative(s):string, string[ ]
A string or array of strings specifying the derivative expressions of the ODE.
5. Variables:string[ ]
Dependent and independent variables of the ODE. For example, in the ODE f(t, y) = y - t^2 + 1, the variables will should be entered as t, y.
6. Time span:float[ ]
Start and end time points (lower and upper limits of integration).
7. Initial y:float, float[ ]
Initial value(s) of the ODE or system of ODEs.
8. Steps:integer, optional (default=10)
Number of steps (time points). This is only shown if the checkbox preceding the label is checked.
9. Stepsize:float
The interval (difference between two consecutive time points). This is only shown if the checkbox preceding the label is unchecked.
10. First k iters:integer, optional (default=50)
Integer representing the number of iterations to be performed. Valid values are 1 <= x <= 50. If 50 is selected, then all iterations are displayed.
Example
Example 1Live Demo
- Approximate the solution of the following ordinary differential equation using Taylor order 3 method.$$\displaystyle\quad\frac{\mathrm{d}y}{\mathrm{d}t} = f'(t, y) = y - t^{2} + 1, \quad 0 \leq t \leq 2, \quad y(0) = 0.5, \quad n = 10 ~~~$$Compare the numerical approximations to the exact solution defined by$$f(t) = (t + 1)^{2} - 0.5 \, e^{t} ~~~$$
Formulation of Input Parameters
The corresponding form values derived from the above problem are as follows.
Form Field | Your input |
---|---|
Method | Taylor order 3 |
ODE equation | y - t^2 + 1 |
Exact solution | (t + 1)^2 - 0.5 * exp(t) |
2 Derivatives | y - t^2 - 2 * t + 1, y - t^2 - 2 * t - 1 |
Variables | t, y |
Time span | 0, 2 |
Initial y | 0.5 |
Steps | 10 |
First k iters | 50 |
Click the link below to explore the output of this example.
Live DemoIn the modal that appears, simply click the Run button to execute the example. Once done, close the modal to view the results.