Help about the numerical computation on the following equations

In summary, the speaker is seeking help with a numerical computation involving differential equations and the use of four-step Runge-Kutta methods. They are struggling with achieving convergence and are wondering which Fortran subroutine to use. They also clarify the use of "i" as the imaginary unit and mention trying different methods such as IMSL and the book 'numerical recipe', but not obtaining correct results. They then mention the original equations being 2500 differential equations that are oscillatory and provide a corrected version of the equations. They have solved the problem.
  • #1
PRB147
127
0
Dear every memeber, I encountered the numerical computation on the following
differential equations. I use four-step Runge-Kutta methods to integrate, but
the result is not converge, even if I take the time step (t=0.0001).
please help me why so? Could you please tellme which Fortran subroutine can do the tasks? (I know the following equations has exact solutions.)

[tex]i\frac{dy_1}{dt}=20.0y_2; \\ i\frac{dy_2}{dt}=20.0y_1[/tex]
 
Physics news on Phys.org
  • #2
What do you mean by "converge"? Runge-Kutta gives a specific result, there is no "convegence" involved. Or do you mean "converge, as the time step gets smaller, to the answer I get by integrating directly"?
 
  • #3
Why the "i"?
 
  • #4
"i" is the imaginary unit.
I tried Runge-Kutta in IMSL, and code in the well-known book 'numerical recipe'.
They can not give the correct result. The original equations are 2500 differential equations looking like this
[tex]i\frac{dp_{ij}}{dt}=-50*(p_{i+1,j}+P_{i-1,j})+50*(p_{i,j-1}+P_{i,j+1})))-ip_{ij}/5 [/tex]
i,j=1,2,..50.

Please help me, Dudes.

I can not obtained the correct numerical result.
 
  • #5
Does not look very bad. I think you should first write the equations in the form that does not involve i-s.
 
  • #6
Thank you, timur, J77 , Hallsofivy

+50 should be -50.
The problem is that it is high oscillatory, I can obtained the numerical result when
i=1,2,3, and j=1,2,3. when i is larger than 3, the numerical result start to diverge.
That is very tricky

the correct equations should be

[tex]i\frac{dp_{m,n}}{dt}=-50\times[(p_{m-1,n}+p_{m+1,n})+(p_{m,n-1}+p_{m,n+1})]-ip_{mn}/5[/tex]

i is the the imaginary unit
 
  • #7
I solved it.
 
Last edited:

1. What is numerical computation and how is it different from analytical computation?

Numerical computation is a method of solving mathematical equations using numerical algorithms and approximations, rather than exact analytical solutions. It involves breaking down a complex equation into simpler steps and using numerical techniques to obtain a solution. This is different from analytical computation, which involves solving equations using algebraic manipulation and exact mathematical formulas.

2. What types of equations can be solved using numerical computation?

Numerical computation can be applied to a wide range of equations, including linear equations, nonlinear equations, differential equations, and partial differential equations. It is particularly useful for solving complex equations that do not have exact analytical solutions.

3. What are some common numerical methods used in computation?

Some common numerical methods used in computation include Newton's method, bisection method, Gaussian elimination, and Runge-Kutta method. These methods involve using iterative processes, approximation techniques, and numerical algorithms to obtain a solution to an equation.

4. Is numerical computation always accurate?

No, numerical computation is not always accurate. The accuracy of the solution depends on the complexity of the equation, the choice of numerical method, and the precision of the computations. In some cases, round-off errors and truncation errors can also affect the accuracy of the solution.

5. How can I check the accuracy of a numerical computation?

To check the accuracy of a numerical computation, you can compare the solution obtained using numerical methods to an exact analytical solution (if one exists). You can also perform the computation with different numerical methods and compare the results to see if they are consistent. Additionally, you can use error analysis techniques to determine the level of accuracy in the solution.

Similar threads

Replies
44
Views
571
  • Differential Equations
Replies
1
Views
1K
Replies
2
Views
2K
Replies
2
Views
373
  • Differential Equations
Replies
2
Views
1K
  • Differential Equations
Replies
1
Views
1K
  • Differential Equations
Replies
4
Views
2K
Replies
3
Views
438
  • Differential Equations
Replies
8
Views
3K
  • Differential Equations
Replies
1
Views
2K
Back
Top