Loading [MathJax]/jax/output/HTML-CSS/jax.js
Skip to main content
Library homepage
 

Text Color

Text Size

 

Margin Size

 

Font Type

Enable Dyslexic Font
Mathematics LibreTexts

3.3E: The Runge-Kutta Method (Exercises)

( \newcommand{\kernel}{\mathrm{null}\,}\)

Most of the following numerical exercises involve initial value problems considered in the exercises in Sections 3.2. You’ll find it instructive to compare the results that you obtain here with the corresponding results that you obtained in those sections.

Q3.3.1

In Exercises 3.3.1 -3.3.5 use the Runge-Kutta method to find approximate values of the solution of the given initial value problem at the points xi=x0+ih, where x0 is the point where the initial condition is imposed and i=1, 2.

1. y=2x2+3y22,y(2)=1;h=0.05

2. y=y+x2+y2,y(0)=1;h=0.1

3. y+3y=x23xy+y2,y(0)=2;h=0.05

4. y=1+x1y2,y(2)=3;h=0.1

5. y+x2y=sinxy,y(1)=π;h=0.2

Q3.3.2

6. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of the initial value problem

y+3y=7e4x,y(0)=2,

at x=0, 0.1, 0.2, 0.3, …, 1.0. Compare these approximate values with the values of the exact solution y=e4x+e3x, which can be obtained by the method of Section 2.1. Present your results in a table like Table 3.3.1.

7. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of the initial value problem

y+2xy=3x3+1,y(1)=1

at x=1.0, 1.1, 1.2, 1.3, …, 2.0. Compare these approximate values with the values of the exact solution

y=13x2(9lnx+x3+2),

which can be obtained by the method of Section 2.1. Present your results in a table like Table 3.3.1.

8. Use the Runge-Kutta method with step sizes h=0.05, h=0.025, and h=0.0125 to find approximate values of the solution of the initial value problem

y=y2+xyx2x2,y(1)=2

at x=1.0, 1.05, 1.10, 1.15 …, 1.5. Compare these approximate values with the values of the exact solution

y=x(1+x2/3)1x2/3,

which was obtained in Example

Example 3.3E.1 :

Add text here. For the automatic number to work, you need to add the “AutoNum” template (preferably at 2.2.3}. Present your results in a table like Table 3.3.1.

9. In Example

Example 3.3E.1 :

Add text here. For the automatic number to work, you need to add the “AutoNum” template (preferably at 2.2.3} it was shown that

y5+y=x2+x4

is an implicit solution of the initial value problem

y=2x+15y4+1,y(2)=1.

Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of (A) at x=2.0, 2.1, 2.2, 2.3, …, 3.0. Present your results in tabular form. To check the error in these approximate values, construct another table of values of the residual

R(x,y)=y5+yx2x+4

for each value of (x,y) appearing in the first table.

10. You can see from Example

Example 3.3E.1 :

Add text here. For the automatic number to work, you need to add the “AutoNum” template (preferably at 2.5.1} that

x4y3+x2y5+2xy=4

is an implicit solution of the initial value problem

y=4x3y3+2xy5+2y3x4y2+5x2y4+2x,y(1)=1.

Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of (A) at x=1.0, 1.1, 1.2, 1.3, …, 2.0. Present your results in tabular form. To check the error in these approximate values, construct another table of values of the residual

R(x,y)=x4y3+x2y5+2xy4

for each value of (x,y) appearing in the first table.

11. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of the initial value problem

(3y2+4y)y+2x+cosx=0,y(0)=1(Exercise 2.2.13)

at x=0, 0.1, 0.2, 0.3, …, 1.0.

12. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of the initial value problem

y+(y+1)(y1)(y2)x+1=0,y(1)=0(Exercise 2.2.14)

at x=1.0, 1.1, 1.2, 1.3, …, 2.0.

13. Use the Runge-Kutta method and the Runge-Kutta semilinear method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of the initial value problem

y+3y=e3x(14x+3x24x3),y(0)=3

at x=0, 0.1, 0.2, 0.3, …, 1.0. Compare these approximate values with the values of the exact solution y=e3x(3x+2x2x3+x4), which can be obtained by the method of Section 2.1. Do you notice anything special about the results? Explain.

Q3.3.3

The linear initial value problems in Exercises 3.3.14–3.3.19 can’t be solved exactly in terms of known elementary functions. In each exercise use the Runge-Kutta and the Runge-Kutta semilinear methods with the indicated step sizes to find approximate values of the solution of the given initial value problem at 11 equally spaced points (including the endpoints) in the interval.

14. y2y=11+x2,y(2)=2;   h=0.1,0.05,0.025 on [2,3]

15. y+2xy=x2,y(0)=3; h=0.2,0.1,0.05 on [0,2] (Exercise 2.1.38)

16. y+1xy=sinxx2,y(1)=2; h=0.2,0.1,0.05 on [1,3] (Exercise 2.1.39)

17. y+y=extanxx,y(1)=0; h=0.05,0.025,0.0125 on [1,1.5] (Exercise 2.1.40)

18. y+2x1+x2y=ex(1+x2)2,y(0)=1; h=0.2,0.1,0.05 on [0,2] (Exercise 2.1.41)

19. xy+(x+1)y=ex2,y(1)=2; h=0.05,0.025,0.0125 on [1,1.5] (Exercise 2.1.42)

Q3.3.4

In Exercises 3.3.20–3.3.22 use the Runge-Kutta method and the Runge-Kutta semilinear method with the indicated step sizes to find approximate values of the solution of the given initial value problem at 11 equally spaced points (including the endpoints) in the interval.

20. y+3y=xy2(y+1),y(0)=1;   h=0.1,0.05,0.025 on [0,1]

21. y4y=xy2(y+1),y(0)=1;   h=0.1,0.05,0.025 on [0,1]

22. y+2y=x21+y2,y(2)=1;   h=0.1,0.05,0.025 on [2,3]

Q3.3.5

23. Suppose a<x0, so that x0<a. Use the chain rule to show that if z is a solution of

z=f(x,z),z(x0)=y0,

on [x0,a], then y=z(x) is a solution of

y=f(x,y),y(x0)=y0,

on [a,x0].

24. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of

y=y2+xyx2x2,y(2)=1

at x=1.1, 1.2, 1.3, …2.0. Compare these approximate values with the values of the exact solution

y=x(43x2)4+3x2,

which can be obtained by referring to Example

Example 3.3E.1 :

Add text here. For the automatic number to work, you need to add the “AutoNum” template (preferably at 2.4.3}.

25. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of

y=x2yxy2,y(1)=1

at x=0, 0.1, 0.2, …, 1.

26. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of

y+1xy=7x2+3,y(1)=32

at x=0.5, 0.6,…, 1.5. Compare these approximate values with the values of the exact solution

y=7lnxx+3x2,

which can be obtained by the method discussed in Section 2.1.

27. Use the Runge-Kutta method with step sizes h=0.1, h=0.05, and h=0.025 to find approximate values of the solution of

xy+2y=8x2,y(2)=5

at x=1.0, 1.1, 1.2, …, 3.0. Compare these approximate values with the values of the exact solution

y=2x212x2,

which can be obtained by the method discussed in Section 2.1.

28. Numerical Quadrature (see Exercise 3.1.23).

a. Derive the quadrature formula

baf(x)dxh6(f(a)+f(b))+h3n1i=1f(a+ih)+2h3ni=1f(a+(2i1)h/2)

(where h=(ba)/n) by applying the Runge-Kutta method to the initial value problem

y=f(x),y(a)=0.

This quadrature formula is called Simpson’s Rule.

b. For several choices of a, b, A, B, C, and D apply (A) to f(x)=A+Bx+Cx+Dx3, with n=10, 20, 40, 80, 160, 320. Compare your results with the exact answers and explain what you find.

c. For several choices of a, b, A, B, C, D, and E apply (A) to f(x)=A+Bx+Cx2+Dx3+Ex4, with n=10,20,40,80,160,320. Compare your results with the exact answers and explain what you find.


This page titled 3.3E: The Runge-Kutta Method (Exercises) is shared under a CC BY-NC-SA 3.0 license and was authored, remixed, and/or curated by William F. Trench.

Support Center

How can we help?