CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM

Unsteady simple-based sovler and dual time stepping

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   May 17, 2011, 09:26
Default Unsteady simple-based sovler and dual time stepping
  #1
New Member
 
Join Date: Feb 2011
Posts: 20
Rep Power: 7
L1011 is on a distinguished road
Hi Foamer!

I've been interested in implementing in openFoam the simple algorithm for the simulation of unsteady flows with a dual time stepping method. Before I start coding any stupid thing, I was wondering if:

  1. adding a time derivative in the currant simpleFoam solver is enough to make it become unsteady
  2. you could refer to me articles that discuss the dts implementation in incompressible solvers
It'll be interesting to see how an unsteady simple-based solver behave with respect to pisoFoam.

Great thanks!

L1011
L1011 is offline   Reply With Quote

Old   May 17, 2011, 09:40
Default
  #2
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 21
niklas will become famous soon enoughniklas will become famous soon enough
...and pimpleFoam is not good enough because?
niklas is offline   Reply With Quote

Old   May 17, 2011, 09:48
Default
  #3
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,211
Blog Entries: 1
Rep Power: 17
nimasam is on a distinguished road
i guess so, add fvm::ddt(U) to UEqn then
compare the result of simpleFoam for cavity with pisoFoam
nimasam is offline   Reply With Quote

Old   May 18, 2011, 11:28
Default Hi!
  #4
New Member
 
Join Date: Feb 2011
Posts: 20
Rep Power: 7
L1011 is on a distinguished road
Thanks for your responses!

@Niklas: you're right pimpleFoam already provides the implementations I intended to do. But what about the dual time stepping? In fact what I'm trying to do is, for each physical iteration:
  1. move/deform a mesh
  2. execute sub-iterations until convergence is reached
  3. back to 1
and I'm wondering if the correction loops (nNonOrthogonalCorrectors, nOuterCorrectors, nCorrectors) can be considered as sub-iterations in the same meaning of the dual time step method?

L1011
L1011 is offline   Reply With Quote

Old   May 20, 2011, 11:17
Default
  #5
New Member
 
Join Date: Feb 2011
Posts: 20
Rep Power: 7
L1011 is on a distinguished road
Any guesses?

I used pimpleFoam to simulate the flow around a NACA0012 airfoil and the following settings:

Code:
/*--------------------------------*- C++ -*----------------------------------*\ 
| =========                 |                                                 |
| \      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \    /   O peration     | Version:  1.7.1                                 |
|   \  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
ddtSchemes
{
    default         backward;
}
gradSchemes
{
    default         Gauss linear;
    grad(p)         Gauss linear;
    grad(U)         Gauss linear;
}
divSchemes
{
    default         none;
    div(phi,U)         Gauss limitedLinearV 1;
    div(phi,k)         Gauss upwind;
    div(phi,omega)         Gauss upwind;
    div((nuEff*dev(grad(U).T())))         Gauss linear;
}
laplacianSchemes
{
    default         none;
    laplacian(nuEff,U)          Gauss linear corrected;
    laplacian((1|A(U)),p)          Gauss linear corrected;
    laplacian(DkEff,k)          Gauss linear corrected;
    laplacian(DomegaEff,omega)          Gauss linear corrected;
}
interpolationSchemes
{
    default         linear;
    interpolate(U)           linear;
}
snGradSchemes
{
    default         corrected;
}
fluxRequired
{
    default         no;
    p       ;  
}


// ************************************************************************* //
Code:
/*--------------------------------*- C++ -*----------------------------------*\n| =========                 |                                                 |
| \      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \    /   O peration     | Version:  1.7.1                                 |
|   \  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      fvSolution;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

solvers
{
    p
    {
        solver          GAMG;
        tolerance       1e-7;
        relTol          0;
     mergeLevels  1;
     smoother  GaussSeidel; 
     agglomerator faceAreaPair ;
     nCellsInCoarsestLevel  100;
     nPreSweeps 0; 
     nPostSweeps 2; 
     cacheAgglomeration true; 
    }

    pFinal
    {
        solver          GAMG;
        tolerance       1e-7;
        relTol          0;
     mergeLevels  1;
     smoother  GaussSeidel; 
     agglomerator faceAreaPair ;
     nCellsInCoarsestLevel  100;
     nPreSweeps 0; 
     nPostSweeps 2; 
     cacheAgglomeration true; 
    }

    U
    {
        solver          smoothSolver;
        tolerance       1e-7;
        relTol          0;
    nSweeps  2;
    smoother  GaussSeidel; 
    }
    UFinal
    {
        solver          smoothSolver;
        tolerance       1e-7;
        relTol          0;
    nSweeps  2;
    smoother  GaussSeidel; 
    }


    k
    {
        solver          smoothSolver;
    smoother GaussSeidel ;
    nSweeps 1 ;
        tolerance        1e-7;
        relTol           0;
    }

    omega
    {
        solver          smoothSolver;
    smoother GaussSeidel ; 
    nSweeps 1 ;
        tolerance        1e-7;
        relTol           0;
    };


    }
    PIMPLE
     {
        nNonOrthogonalCorrectors 4; 
       pRefValue 1;
       pRefCell 0;    
        nOuterCorrectors 10;
        nCorrectors     2;
      };
      relaxationFactors
      {
       default                  1;
        p                  0.5;
        U                  0.5;
        k                  0.5;
        omega                  0.5;
      };
    

}

// ************************************************************************* //
However,I made two strange observations:

1) Even-tough the aerodynamic coefficients get in absolute close to zero, they change significantly from one iteration to the other (see attached file).

2) The velocity field converges from the first outer iteration while the pressure needs couple iteration to get physical.

Do anyone has already experienced something similar?

Thanks in advance!

L1011
Attached Images
File Type: png Screenshot-5.png (29.1 KB, 39 views)
L1011 is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 13:28.