Hello! I'm currently working with a problem which allows modelling ball motion
$$\begin{aligned} m \ddot{x} & =-k_x \dot{x} \sqrt{\dot{x}^2+\dot{y}^2} \\ m \ddot{y} & =-k_y \dot{y} \sqrt{\dot{x}^2+\dot{y}^2}-m g \end{aligned}$$
Given that ##k_x, k_y=0.005##, ##m=0.01## and ##g=9.81## and when...
Hey all,
For the Runge-Kutta method in 3-D (specifically to solve the 3-D TDSE), I was wondering if there were any subtleties I should expect, or if I could just simply use the 1-d method and add on the respective contributions from the other 2 dimensions.
Thanks.
Hi everyone. I'm a new member, great to be here:)
I have a few questions that I wanted to ask you guys regarding the method by which we implement the Runge-Kutta approximation of Projectile Motion if we should do it using a numerical iterative method with a Spreadsheet like Excel.
I have...
To apply this Runge-Kutta scheme, we will need to write our second order DE as a system of first order DEs.
Let $\displaystyle u = y $ and $\displaystyle v = y' $, then we have
$\displaystyle \begin{align*} y'' + 4\,v - 7\,u^2 &= 0.2 \\
y'' &= 0.2 - 4\,v + 7\,u^2 \end{align*} $
So our system...
Hello,
I try to solve a system of ODE's by Runge-Kutta method from here: https://websites.pmc.ucsc.edu/~fnimmo/eart290c_17/NumericalRecipesinF77.pdf, page 704 in the book (not pdf). Bellow is also a code. In function rk4dumb I don't understand how are implemented differential equations. Input...
Homework Statement
I have this equations of motion, I have this equations of motion for a schwarchild black hole, I wish to use the 4th order Runge-Kutta method to solve them for a body falling to the black hole from a distance r0 and with L = 0. My problem is I am struggling to apply this...
Homework Statement
Run a numerical analysis on elliptical orbits using the standard Runka-Kutta method. I already have the equations from Euler-Lagrange method in cartesian x,y-coordinates.
d2x/dt2 = -K x (x2 + y2 )-3/2
d2y/dt2 = -K y (x2 + y2 )-3/2
Homework Equations
I find it a little to...
Hi, I want to solve the p.d.e.:
##\frac{\partial u(x,t)}{\partial t} - \frac{\partial^2 u(x,t)}{\partial x^2}=f(x,t)##,
with periodic boundary conditions ##u(x,t)=u(L,t)##.
using a second order Runge-Kutta method in time. However, I am not having the proper results when I apply this method to...
Homework Statement
When a rocket launches, it burns fuel at a constant rate of (kg/s) as it accelerates, maintaining a constant thrust of T. The weight of the rocket, including fuel is 1200 kg (including 900 kg of fuel). So, the mass of the rocket changes as it accelerates:
m(t) = 1200 - m_ft...
Hi, I'm trying to study Runge-Kutta method and apply on a simple pendulum.
Using a timestep dt=0.1 (h=0.1) the pendulum increses energy of 1% every period...
while in this site:
https://www.myphysicslab.com/pendulum/pendulum/pendulum-en.html
decreses energy about 0.01%
What am I doing wrong...
Based on this link, in particular Figure 1, what is the exact meaning of the plot?
To my understanding, it implies that for a given differential equation:
$$ \frac {dy}{dt} = \lambda y $$
that the value ##\lambda \Delta t## has to be within the complex region shown in Figure 1 corresponding...
Hello, thanks for your interest in may help me, i appreciate it, really.
My question is, I've wrote this code to solve an physical EDO system. But for some reason it copies the element k[1][3] at k[2][3].
After i call the initials elements the code becomes:
for ( int n=1 ; n<=1; n++ ){...
I'm writing a program to compute an ODE solution of the Kepler's problem based on Runge-Kutta 4th order method and today I've past the whole day trying to made it work, but I've failed, maybe you could help me to kill the problem ?
The solutions is cartesian.
int main(){
int n...
Hi! I have this code in C++ that simulates 2 body interacting through gravity using Runge-Kutta 4th order method. I plotted the trajectory of the 2 bodies and as you can see in the first picture they seems to be what I expect, 2 circles. But when I zoom in on one of them (second image) it looks...
MX''=Fn(cosΦ−usinΦ)
MZ''=Fn(sinΦ+ucosΦ)−Mg
MΦ''=Fn(Bxx+uBz)
I tried using Runge-Kutta methods to approximate motion equations in MATLAB but it turn out wrong.
I also tired finding and researching forums and web for solution but to no avail.
Fn,M,θ,u is constant fn/M = 0.866
it seems that i...
Hi! I am trying to simulate the rotation of a planet around a star, using the 2nd order Runge-Kutta method (I am starting with this and I will try 4th order later, I am new to this topic). I have this code but it doesn't work. When I plot y(x) I should get a circle, but I don't get it. Any idea...
Homework Statement
Given: Initial orbital elements of a satellite
a=6652.555663km;
e=0.075;
i=28.5 degrees;
Ω=40 degrees;
w=30 degrees;
n=0 degrees;Tasks(using MATLAB):
1. Convert orbital elements to position and velocity vectors
2. Use these vectors to initialize the Runge-Kutta...
Hello! (Wave)
The following Runge-Kutta method is given:
$$\begin{vmatrix}
0 & 0 & | 0\\
\frac{1}{2} & \frac{1}{2} & | 1 \\ \\
\frac{1}{2} & \frac{1}{2}
\end{vmatrix} \\$$
and I want to show that its order of accuracy is $2$.
I have tried the following:
$$t^{n,1}=t^n \\ t^{n,2}=t^n+...
Homework Statement
I'm currently working on a project in which I have to solve the energy eigenvalues of the Schrodinger equation to compute the mass of certain Mesons. We've been taught very little programming (so apologies that my understanding is very basic), and are therefore given any...
Hi,
I'm not a bright programmer , but I have to solve the fallowing equations:
##\frac{df}{dt} = \alpha f -\beta f + \theta g - (f+h)f##
##\frac{dg}{dt} = \psi f- \phi g##
##\frac{dh}{dt} = \xi f+ \mu h -\tau h + \epsilon w- (f+h)h##
##\frac{dw}{dt} = \nu h - \chi h##
Where ##f(t)## ...
Greetings all !
This is my first post on the forum, so please kindly let me know if I am not asking a proper question or on a proper board.
I would like to use Runge-Kutta 8th order method (89) in a celestial mechanics / astrodynamics application, written in C++. Therefore I wonder if...
When deriving the Runge-Kutta Method to solve y'=f(x) we need to use Taylor expansion. Hence we need to differentiate the function many times.
y'(x)=f(y(x))
y''(x)=f'(y(x))y'(x) = f'(y(x))f(y(x))
y''' = f''(y(x))(f(y(x)),y'(x)) + f'(y(x))f'(y(x))y'(x)
I can understand the second...
So here I am trying to solve Rayleigh's differential equation using Rungen-Kutta 4th order analytic method.
This is what the exercise gives me: X(0 to 40), Y1(0)=0.1, Y2(0)=0, H=0.1, μ=0.5
This is what I ve written and gives me this error:
IMPLICIT REAL*8(A-K,O-Z)
DIMENSION...
Hello, I am trying to program a double pendulum via the 4th order Runge-Kutta method and I cannot seem to be getting the right output. At first I used the Euler-Cromer method, but now I am aiming to make it more accurate.
Homework Statement
I have the equations of motion: d(omega)/dt and...
Homework Statement
"Use Excel to approximate dF/dt=-0.1F+70, F(0)=0 to generate approximations for F at t=1,2 and 4 using step size 0.1. Explain whether these approximation are greater than or less than the exact values. Determine whether the shape of the solution curve is increasing...
Hi all, this is my first post here and i apologize if some rules aren't followed.
I have to complete the Project 13.1 (studies of neutron stars: p 346-350)
http://www.cec.uchile.cl/cinetica/pcordero/MC_libros/Hjorth-Jensen2008.pdf
When browsing using pdf pages 346 to 350, assignments 1...
Using the 4th-order Runge-Kutta method, I have been able to successfully compute the solutions to a coupled pair of two first order differential equations using the following formula:
When solving systems of ODEs with more than two equations I am unsure if I am properly expanding on the...
Homework Statement
Hello, maybe this is due to my lack of understand of RK4, but I have an equation: x'' + b^2*x=0 (derivatives with respect to variable t) and I need to use RK4 to find the solution on an interval. I can readily find solutions analytically, but my understanding of RK4...
Homework Statement
Note: I think there is a typo here but I'm not sure. Is there supposed to be a comma between the delta t/2 and y_n on K2 and K3, and delta t and y_n on K4?
Homework Equations
See above.The Attempt at a Solution
Substituting dy/t = z gives
\frac{dz}{dt} = 3z - 2ty - cos(t)...
Hi,
I am trying to solve something similar to ut = f(x,y), and ut = f(t,x,y) using RK4. I asked a few friends, and nobody knew for sure how to go about it. I've also looked online, without much success. Can anyone give me a hint on this one?
In reality, it is probably preferable to...
(DISCLOSURE: I have already posted this problem in http://math.stackexchange.com/questions/256393/calculate-runge-kutta-order-4s-order-of-error-experimentally, but found no satisfactory answer)
The problem is this. I need to experimentally check that RK4 method has an error of order 4...
I have this project that involves the runge-kutta method, and I honestly have no clue what I am doing.
I never learned about this before, and I don't know much about ordinary differential equations. I am learning all of this next semester but it is required information for this project.
In...
The Wikipedia page for "Runge-Kutta methods"[1] gives the following example:
y' = tan y + 1
y(1) = 1
t in [1, 1.1]
Using a step-size of h = .025, this solution is found:
y(1.1) = 1.335079087
I decided to check this solution by solving symbolically. But my attempts to symbolically...
Runge-Kutta for gravitational N-Body simulation - "prediction" of acceleration
Hey!
I'm Raph, as you can see this is my first post, so, thus I'll start saying that it's nice to be here ;).
I've got the following question:
I'm simulating a system of N gravitationally interacting objects...
Hi,
As you can seeh here, according to wikipedia, the Runge-Kutta methods are iterative, but I don't see what is iterative about it. As I see it, starting from a certain value of x where you know y, you calculate y at x+h, then at x+2h, etc. Where is the iteration?
Homework Statement
I have to find eigenvalues to
\frac{d^2y}{dx^2} + p^2 e^x y = 0,\, y(0)=0,y(1)=0
using the Runge-Kutta single step method to solve the ODE (splitting it up), with step length h and then another numerical method. This is not a problem. However, I need to be able to find...
I made a small program to simulate the time development of a 1D wavepacket obeying the Schrodinger equation, mostly in order to learn a new programming language - so in order to not have to invoke big numerical methods packages, I opted for the simplest solution: The standard three-point...
Homework Statement
Hi. I've written a program to find the solution of the differential equation
[ -d/dx^2 + d/dx + l(l+1) + r^2(V(x)-E) ]P(x) = 0
where l is an integer constant, V(x) is defined on a grid, and E is a real number.
The boundary condition is P(xi) = 1, dP/dx(xi) = l.
I'm using...
Homework Statement
Hi!
I'm to build a model which solves the basic dynamic eqns in the so called SIR model in epidemology. I'm using MatLab and RK4.
There are tree populations in this model: Succeptible S, infected I and recovered R.
Homework Equations
The eqations are
dS/dt =...
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...
Hey folks I'm experimenting with symplectic integrators and I'm trying to figure out how to deal with fourth order implicit Runge-Kutta methods as shown here (symplectic version second link).
http://en.wikipedia.org/wiki/Runge%E2%80%93Kutta_methods#Implicit_Runge.E2.80.93Kutta_methods...
For weeks I've been coding a program to simulate waves on a string. Currently I am working on some numerical methods. Namely Euler and Runge-Kutta. I have Euler working fine as far as I can see for a variety of input waveforms (of course after it runs for a while it goes a bit beserk due to...
Hey all!
I'm trying to use the Runge-Kutta method on this differential equation but I am getting nowhere and it's starting to confuse me :S
Any help would be greatly appreciated!
\frac{dx_{1}}{dt} = g_{2} \frac{y_{2} - y_{1}}{{|r_{2} - r_{1}|}^2}
Hi,
Could someone please show me how to solve the following simple problem using the Runge-Kutta (RK4) integration method?
(tw')' + tw = 0 with w(0) = 1, w'(0) = 0 on the interval [0,1]
by introducing the new variable v=tw' and considering the resulting first order differential system...
Homework Statement
Use a coupled fourth order Runge-Kutta, to find the structure of white dwarf stars.
I think I am applying the Runge-kutta method wrong?
Variables defined in C code notes
Homework Equations
Equations in c code. and in attached images.
The Attempt at a Solution
This is...
i would like to programing in MATLAB with runge kutta 4 with 2nd order the variables (x with y and Q) where x distance , y hight of water and Q discharge from the following tow equation
dydx = (s0-(((Q0^2*n^2)/(B^2.*y^(10/3))*(1+2.*y/B)^(4/3))+dQdx))/(1-Q0^2/(g*B^2*y.^3));
dQdx =...