CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

Implicit Time Integration for Euler Equations

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 20, 2015, 07:50
Default Implicit Time Integration for Euler Equations
  #1
Member
 
Join Date: Jun 2012
Posts: 76
Rep Power: 13
maHein is on a distinguished road
Hello everybody,

I would like to implement a implicit time integration for Euler equations. For the explicit case, this is pretty straight forward:

\frac{V_i}{\Delta t_i} ( \vec{W}_i^{n+1} - \vec{W}_i^{n}) + \sum_{j \in N(i)}  \vec{F}_{ij}^n S_{ij} = 0

which results in the following OpenFOAM code for the conservation of mass:

Code:
solve
(
    fvm::ddt(rho)
  + fvc::div(rhoFlux)
);
For the implicit case

\frac{V_i}{\Delta t_i} ( \vec{W}_i^{n+1} - \vec{W}_i^{n}) + \sum_{j \in N(i)} \vec{F}_{ij}^{n+1} S_{ij} = 0

one can linearize the flux at time n+1 using Taylor's series expansion

\vec{F}_{ji}^{n+1} \approx \vec{F}^n_{ij} + \left( \frac{\partial \vec{F}}{\partial \vec{W}} \right)_{ij} \Delta \vec{W}^n_{ij}

with the flux Jacobian \frac{\partial \vec{F}}{\partial \vec{W}} calculated using finite difference differentiation. This results in

\frac{V_i}{\Delta t_i} ( \vec{W}_i^{n+1} - \vec{W}_i^{n}) + \sum_{j \in N(i)}  \frac{\partial \vec{F}}{\partial \vec{W}} (\vec{W}_{ij}^{n+1} -  \vec{W}_{ij}^{n}) S_{ij} = -Res_i^n

with the term of the right hand side being the fluxes.

My OpenFOAM implementation of this likes the following for the conservation of mass

Code:
solve
(
    fvm::ddt(rho)
  + fvm::div(jacobianRho, rho)
  - fvc::div(jacobianRho, rho)
 ==
  - fvc::div(rhoFlux)
);
Unfortunatelly, this implementation is not stable and diverges very quickly after a few iterations.

Is my implementation incorrect or where is my mistake in this? Is there maybe a better way to realize this method in OpenFOAM?

Thanks for your help!

Martin
maHein is offline   Reply With Quote

Old   April 20, 2015, 13:40
Default
  #2
Senior Member
 
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 12
ssss is on a distinguished road
So I think I need more information to know what you are trying to do, are you only solving the density equation? Are you solving the Navier-Stokes?

Bare in mind that OpenFOAM uses the Rhie-Chow interpolation method and some assumptions about which terms are taken as explicit and which terms are taken as implicit.

Maybe you can obtain the results you are looking using the correct schemes
ssss is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Elastic or Plastic Deformations in OpenFOAM NickolasPl OpenFOAM Pre-Processing 36 September 23, 2023 08:22
Extrusion with OpenFoam problem No. Iterations 0 Lord Kelvin OpenFOAM Running, Solving & CFD 8 March 28, 2016 11:08
Moving mesh Niklas Wikstrom (Wikstrom) OpenFOAM Running, Solving & CFD 122 June 15, 2014 06:20
How to write k and epsilon before the abnormal end xiuying OpenFOAM Running, Solving & CFD 8 August 27, 2013 15:33
CFL in dual time stepping with implicit scheme dokeun Main CFD Forum 0 May 8, 2013 23:01


All times are GMT -4. The time now is 00:40.