
[Sponsors] 
May 2, 2013, 14:07 
Exact solution  Euler equations

#1 
New Member
Jakub
Join Date: May 2013
Location: Czech Republic
Posts: 16
Rep Power: 4 
I work on numerical solution of Euler equations in 1D. I implemented some numerical schemes and now I need compare their accuracy due to the exact solution. But I don't know how to compute it. For Burger's equation I compute exact solution with method of characteristics, but I don't know how to implement it for Euler equations or whether it is possible. Can anyone get me some tip how to compute exact solution of Euler equations? Many thanks. Jakub


May 2, 2013, 14:17 

#2  
Senior Member
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 1,569
Rep Power: 20 
Quote:


May 3, 2013, 00:29 

#3 
New Member
Ravindra Shende
Join Date: Feb 2011
Location: Pune, India
Posts: 8
Rep Power: 6 
Check out this paper: ANALYTICAL SOLUTIONS FOR THE UNSTEADY COMPRESSIBLE FLOW EQUATIONS SERVING AS TEST CASES FOR THE VERIFICATION OF NUMERICAL SCHEMES  Tsangaris and Pappou
Also look in the text 'Computational Gasdynamics' by Culbert Laney. 

May 3, 2013, 02:55 

#4 
New Member
Join Date: Mar 2012
Posts: 8
Rep Power: 5 
Check the book on Riemann solvers by Toro, there you'll find many shock tube problems together with the behavior of many different discretizations.
A good starting point may also be: http://wwwtroja.fjfi.cvut.cz/~liska...re8/index.html Moreover, you could setup sound waves in the linear regime. Going to two or three dimensions, simulating flow instabilities (e.g. shear, convection, rayleightaylor) and comparing the growth rates to the theoretical estimates can give much insight into a numerical discretization. Besides that, computing (stationary) vortices are also a good code validation. 

May 3, 2013, 10:00 
Solved

#5 
New Member
Jakub
Join Date: May 2013
Location: Czech Republic
Posts: 16
Rep Power: 4 
Thanks all. It was very helpful for me. I have one more question about solving Euler equations. Please can you get me a good tip again?
I use Euler method, RungeKutta 2nd order method and RK 4th order method for time discretization. I think that RK4 method should be the best and RK2 method better than Euler, but in every cases I get the best accuracy with Euler and worst with RK4. Don't you have any idea where would be a mistake in my implementation? Thanks. Jakub 

May 3, 2013, 14:49 

#6 
Senior Member
cfdnewbie
Join Date: Mar 2010
Posts: 551
Rep Power: 11 
Did you test your implementation of RK2 and 4 for a system of ODEs? It sounds to me like there must be a bug in your implementation?


May 4, 2013, 14:40 

#7 
New Member
Jakub
Join Date: May 2013
Location: Czech Republic
Posts: 16
Rep Power: 4 
I implemented Euler and RK2 on ODEs, but I get same bad results. In first few times RK2 is better than Euler, but after some time not. I enclosed figure with my results. In figure is Euler, RK2, Matlab ode 23 and exact solution. I must have bug in implementation or bug is in book (Finite Volume Method for Hyperbolic Problems  LeVeque  equations (10.18)) which I use.
Here is my code of RK2: Code:
function dy = rigid(t,y) dy = 3*exp(4*t)2*y; end for i=1:length(t)1 k1=rigid(t(i),rk2(i)); %derivate ystar1(i)=rk2(i)+h*k1; %y* k2=rigid(t(i),ystar1(i)); %derivate ystar2(i)=ystar1(i)+h*k2; %y** rk2(i+1)=0.5*(rk2(i)+ystar2(i)); %result = 1/2*(y + y**) end Jakub 

May 6, 2013, 06:47 

#8 
New Member
Jakub
Join Date: May 2013
Location: Czech Republic
Posts: 16
Rep Power: 4 
Please, has anybody any idea for my problem with Runge Kutta? Thanks.
Jakub 

May 6, 2013, 08:02 

#9 
New Member
Join Date: Mar 2012
Posts: 8
Rep Power: 5 
I guess the second evaluation of 'rigid' should not be at time t(i). The algorithm in LeVeque is defined for problems without an explicit time dependence. You should look up the butcher tableau for this time marching scheme to find out the correct time for the second evaluation. I guess, it's just t(i) + h but look it up in order to be certain!


May 6, 2013, 18:14 

#10  
New Member
Jakub
Join Date: May 2013
Location: Czech Republic
Posts: 16
Rep Power: 4 
Quote:
So if I apply now Runge Kutta 2nd order method on Euler equations or on other system of hyperbolic partial differential equations I get this: U* = U(n) + dt*G(U(n))  first step U** = U* + dt*G(U*(n+1))  second step and result is: U(n+1) = 1/2*(U(n) + U**). But how can I compute U** when I don't know U*(n+1) in the second step? Many thanks to all. Jakub. 

Tags 
euler equations, exact solutution 
Thread Tools  
Display Modes  


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Convergence  Centurion2011  FLUENT  24  May 9, 2015 08:02 
Delta form of Heat, Euler and NS equations  RameshK  Main CFD Forum  3  May 30, 2012 10:41 
Exact solution of NS eq. in Kim and Moin's paper  Kyounghwa  Main CFD Forum  5  January 23, 2012 10:36 
Naca 0012 (compressible and inviscid) flow convergence problem  bipulsaha  FLUENT  1  July 6, 2011 07:51 
Euler equations & expansion shocks  technophobe  Main CFD Forum  5  April 28, 2009 15:11 