Exams
Test Series
Previous Year Papers
JEE Main Previous Year Question Paper JEE Advanced Previous Year Papers NEET Previous Year Question Paper CUET Previous Year Papers COMEDK UGET Previous Year Papers UP Polytechnic Previous Year Papers AP POLYCET Previous Year Papers TS POLYCET Previous Year Papers KEAM Previous Year Papers MHT CET Previous Year Papers WB JEE Previous Year Papers GUJCET Previous Year Papers ICAR AIEEA Previous Year Papers CUET PG Previous Year Papers JCECE Previous Year Papers Karnataka PGCET Previous Year Papers NEST Previous Year Papers KCET Previous Year Papers LPUNEST Previous Year Papers AMUEEE Previous Year Papers IISER IAT Previous Year Papers Bihar Diploma DECE-LE Previous Year Papers NPAT Previous Year Papers JMI Entrance Exam Previous Year Papers PGDBA Exam Previous Year Papers AP ECET Previous Year Papers PU CET Previous Year Papers GPAT Previous Year Papers CEED Previous Year Papers AIAPGET Previous Year Papers JKCET Previous Year Papers HPCET Previous Year Papers CG PAT Previous Year Papers SRMJEEE Previous Year Papers BCECE Previous Year Papers AGRICET Previous Year Papers TS PGECET Previous Year Papers MP PAT Previous Year Papers IIT JAM Previous Year Papers CMC Vellore Previous Year Papers ACET Previous Year Papers TS EAMCET Previous Year Papers NATA Previous Year Papers AIIMS MBBS Previous Year Papers BITSAT Previous Year Papers JEXPO Previous Year Papers HITSEEE Previous Year Papers AP EAPCET Previous Year Papers UCEED Previous Year Papers CG PET Previous Year Papers OUAT Previous Year Papers VITEEE Previous Year Papers
Syllabus
JEE Main Syllabus JEE Advanced Syllabus NEET Syllabus CUET Syllabus COMEDK UGET Syllabus UP Polytechnic JEECUP Syllabus AP POLYCET Syllabus TS POLYCET Syllabus KEAM Syllabus MHT CET Syllabus WB JEE Syllabus OJEE Syllabus ICAR AIEEA Syllabus CUET PG Syllabus NID Syllabus JCECE Syllabus Karnataka PGCET Syllabus NEST Syllabus KCET Syllabus UPESEAT EXAM Syllabus LPUNEST Syllabus PUBDET Syllabus AMUEEE Syllabus IISER IAT Syllabus NPAT Syllabus JIPMER Syllabus JMI Entrance Exam Syllabus AAU VET Syllabus PGDBA Exam Syllabus AP ECET Syllabus GCET Syllabus CEPT Syllabus PU CET Syllabus GPAT Syllabus CEED Syllabus AIAPGET Syllabus JKCET Syllabus HPCET Syllabus CG PAT Syllabus BCECE Syllabus AGRICET Syllabus TS PGECET Syllabus BEEE Syllabus MP PAT Syllabus MCAER PG CET Syllabus VITMEE Syllabus IIT JAM Syllabus CMC Vellore Syllabus AIMA UGAT Syllabus AIEED Syllabus ACET Syllabus TS EAMCET Syllabus PGIMER Exam Syllabus NATA Syllabus AFMC Syllabus AIIMS MBBS Syllabus BITSAT Syllabus BVP CET Syllabus JEXPO Syllabus HITSEEE Syllabus AP EAPCET Syllabus GITAM GAT Syllabus UPCATET Syllabus UCEED Syllabus CG PET Syllabus OUAT Syllabus IEMJEE Syllabus VITEEE Syllabus SEED Syllabus MU OET Syllabus
Books
Cut Off
JEE Main Cut Off JEE Advanced Cut Off NEET Cut Off CUET Cut Off COMEDK UGET Cut Off UP Polytechnic JEECUP Cut Off AP POLYCET Cut Off TNEA Cut Off TS POLYCET Cut Off KEAM Cut Off MHT CET Cut Off WB JEE Cut Off ICAR AIEEA Cut Off CUET PG Cut Off NID Cut Off JCECE Cut Off Karnataka PGCET Cut Off NEST Cut Off KCET Cut Off UPESEAT EXAM Cut Off AMUEEE Cut Off IISER IAT Cut Off Bihar Diploma DECE-LE Cut Off JIPMER Cut Off JMI Entrance Exam Cut Off PGDBA Exam Cut Off AP ECET Cut Off GCET Cut Off CEPT Cut Off PU CET Cut Off CEED Cut Off AIAPGET Cut Off JKCET Cut Off HPCET Cut Off CG PAT Cut Off SRMJEEE Cut Off TS PGECET Cut Off BEEE Cut Off MP PAT Cut Off VITMEE Cut Off IIT JAM Cut Off CMC Vellore Cut Off ACET Cut Off TS EAMCET Cut Off PGIMER Exam Cut Off NATA Cut Off AFMC Cut Off AIIMS MBBS Cut Off BITSAT Cut Off BVP CET Cut Off JEXPO Cut Off HITSEEE Cut Off AP EAPCET Cut Off GITAM GAT Cut Off UCEED Cut Off CG PET Cut Off OUAT Cut Off VITEEE Cut Off MU OET Cut Off
Latest Updates
Eligibility
JEE Main Eligibility JEE Advanced Eligibility NEET Eligibility CUET Eligibility COMEDK UGET Eligibility UP Polytechnic JEECUP Eligibility TNEA Eligibility TS POLYCET Eligibility KEAM Eligibility MHT CET Eligibility WB JEE Eligibility OJEE Eligibility ICAR AIEEA Eligibility CUET PG Eligibility NID Eligibility JCECE Eligibility Karnataka PGCET Eligibility NEST Eligibility KCET Eligibility LPUNEST Eligibility PUBDET Eligibility AMUEEE Eligibility IISER IAT Eligibility Bihar Diploma DECE-LE Eligibility NPAT Eligibility JIPMER Eligibility JMI Entrance Exam Eligibility AAU VET Eligibility PGDBA Exam Eligibility AP ECET Eligibility GCET Eligibility CEPT Eligibility PU CET Eligibility GPAT Eligibility CEED Eligibility AIAPGET Eligibility JKCET Eligibility HPCET Eligibility CG PAT Eligibility SRMJEEE Eligibility BCECE Eligibility AGRICET Eligibility TS PGECET Eligibility MP PAT Eligibility MCAER PG CET Eligibility VITMEE Eligibility IIT JAM Eligibility CMC Vellore Eligibility AIMA UGAT Eligibility AIEED Eligibility ACET Eligibility PGIMER Exam Eligibility CENTAC Eligibility NATA Eligibility AFMC Eligibility AIIMS MBBS Eligibility BITSAT Eligibility JEXPO Eligibility HITSEEE Eligibility AP EAPCET Eligibility GITAM GAT Eligibility UPCATET Eligibility UCEED Eligibility CG PET Eligibility OUAT Eligibility IEMJEE Eligibility SEED Eligibility MU OET Eligibility

Runge Kutta 4th Order Method Introduction, Formula, Algorithm & Example

Last Updated on Jul 03, 2025
Download As PDF
IMPORTANT LINKS

The Runge-Kutta method is a popular and effective way to solve ordinary differential equations (ODEs), especially when we know the starting value (initial value problem). It gives more accurate results than simple methods like Euler’s method and does not need complicated higher-order derivatives.

Among the different Runge-Kutta methods, the 4th order Runge-Kutta method (often called RK4) is the most widely used. It works by estimating four different slopes (or values of the function’s rate of change) at each step. These slopes are then combined in a smart way to give a better estimate of the next value. This makes the method both accurate and easy to apply using just the original function, without needing its higher derivatives.

Maths Notes Free PDFs

Topic PDF Link
Class 12 Maths Important Topics Free Notes PDF Download PDF
Class 10, 11 Mathematics Study Notes Download PDF
Most Asked Maths Questions in Exams Download PDF
Increasing and Decreasing Function in Maths Download PDF

What is Runge-Kutta Method

The Taylor series method needs you to find higher-order derivatives (like second, third, and so on) of a function. This can be hard and take a lot of time, especially for complex equations.

The Runge-Kutta method makes things easier. It turns the problem into a series of simple first-order equations and uses step-by-step calculations to find the solution at different points.

There are different levels (or orders) of the Runge-Kutta method:

  • First-order Runge-Kutta method is also called Euler’s method. It’s the simplest and uses a basic formula to estimate the next value.
  • Second-order Runge-Kutta method, also known as the midpoint method, checks the value at the middle of the step to get a better estimate.
  • Third-order Runge-Kutta method adds even more steps in between to improve accuracy further.

1st Order:

2nd Order:

3rd Order:

where represents the step size, and are the values of the independent and dependent variables at the current step, is the derivative function, and , , and are intermediate calculations based on the derivative function.


What is Runge-Kutta 4th Order Method?

The 4th order Runge-Kutta method approximates the curve of the function f between two points by a 4th degree polynomial. It requires 4 slope estimates at each step.

Geometrically, we can visualize the curve between two points as part of a 4th degree polynomial. The 4th order Runge-Kutta method finds 4 tangents to this curve at evenly spaced points, and uses the average of their slopes as an approximation of the entire curve between the two points.

Runge-Kutta Formula for 4th Order

The formula for Runge-kutta 4th order is:

Where, 

The slope estimates and correspond to tangents at the beginning, middle and end of the interval respectively. Taking the average of these 4 slopes gives a good approximation of the entire curve between the two points.

Test Series
133.1k Students
NCERT XI-XII Physics Foundation Pack Mock Test
323 TOTAL TESTS | 3 Free Tests
  • 3 Live Test
  • 163 Class XI Chapter Tests
  • 157 Class XII Chapter Tests

Get Started

Runge-Kutta 4th Order Method Algorithm

Runge kutta 4th order method algorithm is as follows

Step : 1 Start

Step : 2 Now describe the function f (x,y)

Step : 3 Read the starting condition values the number of steps (n), and the calculation point.

Step : 4 Calculate the size step

Step : 5 Set, i = 0

Step : 6 Loop

i = i +1

Step : 7 Show as the outcome.

Step : 8 Stop

C Program for Runge-Kutta Method 4th Order

#include <stdio.h>

/ Function to calculate the derivative dy/dx
double derivative(double x, double y) {
/ Define the derivative function here
double dy_dx = /* Insert the expression for dy/dx */;
return dy_dx;
}

/ Function to implement the fourth-order Runge-Kutta method
double rungeKutta(double x0, double y0, double x, double h) {
int n = (int)((x - x0) / h); / Number of iterations
double y = y0;

for (int i = 1; i <= n; i++) {
double k1 = h * derivative(x0, y);
double k2 = h * derivative(x0 + 0.5 * h, y + 0.5 * k1);
double k3 = h * derivative(x0 + 0.5 * h, y + 0.5 * k2);
double k4 = h * derivative(x0 + h, y + k3);

/ Calculate the next value of y
y = y + (1.0 / 6.0) * (k1 + 2 * k2 + 2 * k3 + k4);

x0 = x0 + h; / Increment x
}

return y;
}

int main() { double x0 = 0; / Initial x double y0 = 1; / Initial y double x = 0.2; / Final x at which we want y double h = 0.1; / Step size double y = rungeKutta(x0, y0, x, h); printf("The value of y at x = %f is %f\n", x, y); return 0;


}

This C program calculates the value of y at a given x using the fourth-order Runge-Kutta method.

Properties of Runge-Kutta 4th Order Method
  1. High Accuracy
    It gives very accurate results compared to lower-order methods like Euler’s or 2nd-order methods, especially for small step sizes.
  2. No Need for Higher Derivatives
    Unlike the Taylor series method, it doesn’t require calculating second, third, or higher-order derivatives — only the first derivative is used.
  3. Self-Starting Method
    It doesn’t need previous points to start. You can begin solving right from the initial condition, making it easier to implement.
  4. Single-Step Method
    It calculates the solution at the next step using only the current point, without needing values from earlier steps.
  5. Widely Used for Non-Stiff Problems
    It works very well for many types of ordinary differential equations (ODEs) that are not stiff.
  6. Deterministic Results
    For the same initial conditions and step size, it will always give the same result — it’s predictable and stable for most problems.

Advantages of Runge Kutta 4th Order Method

The Runge-Kutta method offers several advantages in numerical computations for solving ordinary differential equations (ODEs). These advantages include:

  • Accuracy: The Runge-Kutta method, especially higher-order variants like the fourth-order method, provides more accurate results compared to simpler numerical methods. It considers multiple intermediate steps and calculates weighted averages, resulting in improved accuracy.
  • Versatility: The Runge-Kutta method is versatile and can be applied to a wide range of ODEs, including both first-order and higher-order differential equations. It is not limited to specific types of equations and can handle various initial conditions.
  • Efficiency: Despite its higher accuracy, the Runge-Kutta method remains computationally efficient. It strikes a balance between accuracy and computational complexity, making it a reliable choice for solving ODEs in various scientific and engineering applications.
  • Stability: The Runge-Kutta method exhibits stability properties, ensuring that the numerical solutions remain bounded and do not diverge significantly. This stability is crucial for obtaining reliable results over a wide range of integration steps.

Disadvantages of Runge-Kutta 4th Order Method
  1. More Calculations Per Step
    It needs multiple function evaluations (4 per step), making it slower than simpler methods like Euler’s for small problems.
  2. Not Ideal for Stiff Equations
    It doesn't work well for "stiff" differential equations (where solutions change very fast). For such problems, special methods are better.
  3. Fixed Step Size
    The basic version uses a fixed step size, which might not be efficient. Small steps give better accuracy but take longer to compute.

Runge-Kutta 3rd Order vs Runge-Kutta 4th order Method

Parameter

Runge-Kutta 3rd Order

Runge-Kutta 4th Order

Formula

<br> <br> <br>

<br> <br> <br> <br>

Accuracy

Less accurate compared to the fourth order

More accurate, provides better approximations

Number of Function Evaluations

Requires three function evaluations at each step

Requires four function evaluations at each step

Computational Complexity

Less computationally expensive

Slightly more computationally expensive

Stability

Less stable for stiff systems

More stable for a wider range of systems

Error Control

Limited error control capabilities

Allows for adaptive step size control and error estimation

Applications

Suitable for general-purpose problems

Preferred for problems requiring high accuracy

Runge-Kutta Method 4th Order Solved Examples

Example 1: Find the value of k₁ using the Runge-Kutta 4th order method, if
dy/dx = x + 2y², and y(0.2) = 1.05, with step size h = 0.1.

Solution:

We are given:

  • Differential equation: dy/dx = x + 2y²
  • Initial values: x₀ = 0.2, y₀ = 1.05
  • Step size: h = 0.1

Step 1: Identify the function
f(x, y) = x + 2y²

Step 2: Apply the Runge-Kutta formula to find k₁
k₁ = h × f(x₀, y₀)

Substitute the values:
k₁ = 0.1 × f(0.2, 1.05)
  = 0.1 × [0.2 + 2 × (1.05)²]
  = 0.1 × [0.2 + 2 × 1.1025]
  = 0.1 × [0.2 + 2.205]
  = 0.1 × 2.405
  = 0.2405

Answer: The value of k₁ is 0.2405.

Example 2: Find the value of k₁ using the Runge-Kutta 4th order method, if
dy/dx = x² + y, and y(0.5) = 1.2, with step size h = 0.1.

Solution:

We are given:

  • Differential equation: dy/dx = x² + y
  • Initial values: x₀ = 0.5, y₀ = 1.2
  • Step size: h = 0.1

Step 1: Identify the function
f(x, y) = x² + y

Step 2: Apply the Runge-Kutta formula to find k₁
k₁ = h × f(x₀, y₀)

Substitute the values:
k₁ = 0.1 × f(0.5, 1.2)
  = 0.1 × [(0.5)² + 1.2]
  = 0.1 × [0.25 + 1.2]
  = 0.1 × 1.45
  = 0.145

Answer:The value of k₁ is 0.145

If you want to score well in your math exam then you are at the right place. Here you will get weekly test preparation, live classes, and exam series. Download the Testbook App now to prepare a smart and high-ranking strategy for the exam.

Important Links
NEET Exam
NEET Previous Year Question Papers NEET Mock Test NEET Syllabus
CUET Exam
CUET Previous Year Question Papers CUET Mock Test CUET Syllabus
JEE Main Exam
JEE Main Previous Year Question Papers JEE Main Mock Test JEE Main Syllabus
JEE Advanced Exam
JEE Advanced Previous Year Question Papers JEE Advanced Mock Test JEE Advanced Syllabus

More Articles for Maths

FAQs For Runge Kutta Method of 4th Order

The approximate value of y for a particular point x is provided by the Runge-Kutta method. The Runge Kutta RK4 approach is only applicable to first order ODEs.

RK4 is fourth order Runge kutta method.

Formula of the Runge-Kutta fourth order method

Yes, Runge-Kutta 4th order method is a direct method.

Simpson's rule is used for approximating definite integrals, while the Runge-Kutta method is employed for solving ordinary differential equations numerically.

The first order Runge-Kutta method is known as Euler's Method and First Order Runge-Kutta.

Yes, it is much more accurate and stable compared to Euler's method, even when using a similar step size.

Report An Error