Thread: Differential equation using numerical methods

1. Differential equation using numerical methods

$
d2y/dx2 + dy/dx = y + 5x$

In runge kutta method i can only solve differential equations of degree 1 am i correct ? So how can i solve the above equation which is of degree 2 using runge kutta ?

2. For higher-order equation, just use the standard reduction of order down to a first-order system routine. That is, let $y_{1}=y$ and $y_{2}=y'.$ You obtain, then, a first-order system in two variables. Then you can apply Runge-Kutta 4. Make sense?

3. hey Ackbeet. To solve any differential equation you need a known pair of (x,y) values. Ami correct ?

4. If you're going to solve numerically, you definitely need initial or boundary conditions in order to solve. You need as many conditions as the degree of the equation. In your case, you need two conditions. If you have initial conditions (much easier to work with than boundary conditions!), then you'd have the value of the function y and its derivative at one particular x value. The corresponding initial conditions in vector format would be the value of the vector [y1 y2] at a particular x value.

Make sense?

5. Thanks Ackbeet. How do i solve a 3rd order differential equation using numeical methods ? Is there a easy direct method ?

6. You can do the same sort of reduction to a system that you do for a second order ODE. You'll just have a 3-component vector solution instead of a 2 component vector solution.

7. Say i have a first order differential equation. In matlab to estimate the value of y at x = (some value) do i still have to give it a pair of x.y values ?

8. You will definitely need to give MATLAB an initial condition in order to integrate the DE to find the value of y at some x not equal to the initial x. As far as I know, you simply cannot integrate an ODE numerically without a complete set of initial conditions or boundary conditions.