Solving the Kinematic Equations using Runge-Kutta

In summary, the student is seeking help with writing a physics simulation program using kinematic equations and Runge-Kutta to solve for an object's movement in space. They have found difficulty in finding code specifically for kinematics and are asking for recommendations or resources. They also mention the need to transform the problem into first-order ordinary differential equations and apply a numerical method such as Runge-Kutta.
  • #1
livenail
1
0

Homework Statement


I am attempting to write a physics simulation program using the kinematic equations and using Runge-Kutta to solve them to determine how an object will move through space subject to certain gravitational forces etc.

Homework Equations


I have x=vt+(at^2)/2 as the equation i need to solve.
Same in the Y direction.

The Attempt at a Solution


I've attempted to find code online to help, but what I've found has been mostly the spring equations, nothing dealing with pure kinematics.
If someone knows of a place i could get code for this, in any language it would be much appreciated!
thanks in advance
 
Last edited:
Physics news on Phys.org
  • #2
In general you need to transform your problem into a set of first order ordinary differential equations with one equation for each independent state variable. Assuming you want to calculate your trajectory in 2D you would then have 4 state variables (the 2 position components x and y, and the 2 velocity components u and w) and the equations for constant acceleration ax and ay would then be something like du/dt = ax, dw/dt = ay, dx/dt = u, dy/dt = w.

Having a set of first order ODE's you can start applying a numerical method to solve it [1], like Runge-Kutta [2].

[1] http://en.wikipedia.org/wiki/Numerical_ordinary_differential_equations
[2] http://en.wikipedia.org/wiki/Runge–Kutta_methods
 
  • #3
livenail said:

Homework Statement


I am attempting to write a physics simulation program using the kinematic equations and using Runge-Kutta to solve them to determine how an object will move through space subject to certain gravitational forces etc.

Homework Equations


I have x=vt+(at^2)/2 as the equation i need to solve.
Same in the Y direction.

The Attempt at a Solution


I've attempted to find code online to help, but what I've found has been mostly the spring equations, nothing dealing with pure kinematics.
If someone knows of a place i could get code for this, in any language it would be much appreciated!
thanks in advance

What language are you going to be working in?
 

FAQ: Solving the Kinematic Equations using Runge-Kutta

What are the Kinematic Equations?

The Kinematic Equations are a set of four equations that describe the motion of an object in terms of its position, velocity, acceleration, and time. These equations are commonly used in physics and engineering to solve problems related to motion.

What is Runge-Kutta?

Runge-Kutta is a numerical method used to approximate solutions to differential equations. It is commonly used in scientific and engineering applications, including solving the Kinematic Equations.

How does Runge-Kutta work?

Runge-Kutta works by breaking down a complex differential equation into smaller, simpler steps. It then uses these steps to approximate the solution to the equation, improving the accuracy with each step. The more steps that are taken, the more accurate the solution will be.

Why is Runge-Kutta used to solve the Kinematic Equations?

Runge-Kutta is used to solve the Kinematic Equations because it is a more accurate and efficient method compared to other numerical techniques. It also allows for the solution to be found for a wider range of initial conditions.

What are the benefits of using Runge-Kutta to solve the Kinematic Equations?

Using Runge-Kutta to solve the Kinematic Equations allows for more accurate and precise solutions to be found, which is crucial in scientific and engineering applications. It also allows for a wider range of initial conditions to be solved, making it a versatile and powerful tool for solving complex motion problems.

Similar threads

Replies
1
Views
4K
Replies
3
Views
2K
Replies
2
Views
2K
Replies
3
Views
2K
Replies
4
Views
4K
Replies
8
Views
2K
Back
Top