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

how to accurately simulate flow around cylinder

Register Blogs Community New Posts Updated Threads Search

Like Tree16Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 18, 2014, 15:44
Default
  #81
Senior Member
 
Alexey Matveichev
Join Date: Aug 2011
Location: Nancy, France
Posts: 1,930
Rep Power: 38
alexeym has a spectacular aura aboutalexeym has a spectacular aura about
Send a message via Skype™ to alexeym
Here are my results: http://matveichev.blogspot.fr/2014/0...ex-street.html
alexeym is offline   Reply With Quote

Old   March 19, 2014, 05:24
Default
  #82
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Dear Alexey,

many thanks for your post.

All the best
Maimouna is offline   Reply With Quote

Old   March 19, 2014, 05:59
Default
  #83
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Dear Alexey,

I have one question please,

what's your accurate result in terms of strouhal number?
tareqkh likes this.
Maimouna is offline   Reply With Quote

Old   March 19, 2014, 13:30
Default
  #84
Senior Member
 
Alexey Matveichev
Join Date: Aug 2011
Location: Nancy, France
Posts: 1,930
Rep Power: 38
alexeym has a spectacular aura aboutalexeym has a spectacular aura about
Send a message via Skype™ to alexeym
You're joking, right?
tareqkh likes this.
alexeym is offline   Reply With Quote

Old   March 20, 2014, 04:55
Default
  #85
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Sorry for that might be silly question, just I would like to know if you checked your convergence in terms of Strouhal number?
Maimouna is offline   Reply With Quote

Old   March 24, 2014, 02:46
Default
  #86
New Member
 
Wentao Zheng
Join Date: Nov 2013
Posts: 7
Rep Power: 12
774024952 is on a distinguished road
hi, Maimouna, I'm new with CFD. And I have a question. What's the meaning of Aref and lRef? And how can I calculate them?
Thanks a lot.
774024952 is offline   Reply With Quote

Old   March 24, 2014, 03:17
Default
  #87
New Member
 
Wentao Zheng
Join Date: Nov 2013
Posts: 7
Rep Power: 12
774024952 is on a distinguished road
I've found the explain of the Aref and lRef, thanks.
774024952 is offline   Reply With Quote

Old   March 24, 2014, 04:37
Default
  #88
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Hi. Sorry for late reply. Any question you welcome.

Best wishes
Maimouna is offline   Reply With Quote

Old   March 26, 2014, 12:07
Default
  #89
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Dear Alexey,

did you try free vibration of cylinder in flow in your case about flow past a circular cylinder?

I'm doing that now, but I couldn't fix my problem yet. If you try it, I need your help please.

Many thanks in advanced.
Maimouna is offline   Reply With Quote

Old   May 8, 2014, 01:58
Default
  #90
New Member
 
Shuai Wang
Join Date: Mar 2014
Posts: 26
Rep Power: 12
Shuai_W is on a distinguished road
Dear Maimouna, I want to simulate the flow around cylinder, and I do it followed step by step. I use openfoam 2.3.0 and the attached case, I excute it via "./Allprepare".however, when I excute "pimpleFoam",there is an error:
/*---------------------------------------------------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.3.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
Build : 2.3.0-f5222ca19ce6
Exec : pimpleFoam
Date : May 08 2014
Time : 13:07:57
Host : "wangshuai-Lenovo-B460"
PID : 6522
Case : /home/wangshuai/OpenFOAM/wangshuai-2.3.0/run/tutorials/incompressible/pimpleFoam/coarse
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
allowSystemOperations : Disallowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create mesh for time = 0



--> FOAM FATAL IO ERROR:
keyword startFace is undefined in dictionary ".defaultFaces"

file: .defaultFaces from line 71 to line 71.

From function dictionary::lookupEntry(const word&, bool, bool) const
in file db/dictionary/dictionary.C at line 437.

FOAM exiting

I cannot handle with it, could you help me? Thanks.
Attached Files
File Type: zip mrklein-flow-past-cylinder-27e3de0543ed (1).zip (16.7 KB, 10 views)
Shuai_W is offline   Reply With Quote

Old   May 8, 2014, 05:36
Default
  #91
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Dear Shuai,

have you tried my one (attached case). Try that case please, if any problem let me know please.

Regards
Attached Files
File Type: gz circularCylinderNew.tar.gz (4.8 KB, 45 views)
Maimouna is offline   Reply With Quote

Old   May 9, 2014, 22:42
Default
  #92
New Member
 
Shuai Wang
Join Date: Mar 2014
Posts: 26
Rep Power: 12
Shuai_W is on a distinguished road
Dear Maimouna, I tried the attached case yesterday. Everything is Ok when I typed “./Allprepare” in my terminal. After that, when I typed “pimpleFoam” in my terminal, error appeared like:



Quote:
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time
Create mesh for time = 0
Reading field p
Reading field U
Reading/calculating face flux field phi
Selecting incompressible transport model Newtonian
Selecting turbulence model type laminar
No finite volume options present
PIMPLE: max iterations = 100
field "(U|p)" : relTol 0, tolerance 0.01
Starting time loop
fieldAverage fieldAverage1:
Starting averaging at time 0
Courant Number mean: 0.0153542679232 max: 0.074259625164
deltaT = 0.00119904076739
Time = 0.00119904076739
PIMPLE: iteration 1
DILUPBiCG: Solving for Ux, Initial residual = 1, Final residual = 0.00162921759868, No Iterations 1
DILUPBiCG: Solving for Uy, Initial residual = 1, Final residual = 0.00157520001085, No Iterations 1
--> FOAM FATAL IO ERROR:
keyword laplacian(rAUf,p) is undefined in dictionary "/home/wangshuai/OpenFOAM/wangshuai-2.3.0/run/tutorials/incompressible/pimpleFoam/circularCylinderNew/system/fvSchemes.laplacianSchemes"
file: /home/wangshuai/OpenFOAM/wangshuai-2.3.0/run/tutorials/incompressible/pimpleFoam/circularCylinderNew/system/fvSchemes.laplacianSchemes from line 37 to line 39.
From function dictionary::lookupEntry(const word&, bool, bool) const
in file db/dictionary/dictionary.C at line 437.

FOAM exiting
The error suggested that “keyword laplacian(rAUf,p) is undefined in….”, and therefore, I modified the fvSchemes.laplacianSchemes in my system file.
Before modification:
Quote:
laplacianSchemes
{
default none;
laplacian(nuEff,U) Gauss cubic corrected;
laplacian((1|A(U)),p) Gauss cubic corrected;
}
After modification:
Quote:
laplacianSchemes
{
default none;
laplacian(nuEff,U) Gauss cubic corrected;
laplacian(rAUf,p) Gauss cubic corrected;
laplacian((1|A(U)),p) Gauss cubic corrected;
}


After that, when I typed “pimpleFoam” in my terminal again, it’s Ok. However, I had three questions as follow:
1. What is the function of changeDictionary? I am very confused with this dictionary.
2. Should it will affect the results when I add “laplacian(rAUf,p) Gauss cubic corrected;” in laplacianSchemes?
3. In your case, I find something like “U~” or “P~”, what does the “~” mean?
My results are in the below (attached case). Thank you for your help.
Attached Images
File Type: jpg QQ图片20180714111411.jpg (44.6 KB, 37 views)
Shuai_W is offline   Reply With Quote

Old   May 11, 2014, 14:49
Default
  #93
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Dear Shuai,

that is good news that case working in your OpenFOAM version 2.3.0. Regarding your questions
Quote:
1. What is the function of changeDictionary? I am very confused with this dictionary.
To get more clarification about change[/QUOTE]Dictionary function look at
http://www.cfd-online.com/Forums/openfoam-pre-processing/101179-how-do-i-use-changedictionary-utility.html

Quote:
2. Should it will affect the results when I add “laplacian(rAUf,p) Gauss cubic corrected;” in laplacianSchemes?
When you get through the previous link you can get more idea.

Quote:
3. In your case, I find something like “U~” or “P~”, what does the “~” mean?
I don't know what that two files mean, but I think they are not affected your result.

All the best.
Maimouna is offline   Reply With Quote

Old   May 16, 2014, 09:37
Default
  #94
Senior Member
 
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 13
Maimouna is on a distinguished road
Dear Shuai,

recently, I'm using OpenFOAM-2.3.0 because I updated my ubuntu 13.10 to 14.04, which I don't really like. OpenFOAM version that only accompanied with that ubuntu version is 2.3.0. Any way, I tried to work with previous case about circular cylinder that I sent you in the previous post #91, but unfortunately it was gave me the same error that you posted in #92. I solved that problem. It started working and then it stopped by that error
Code:
#0  Foam::error::printStack(Foam::Ostream&) at ??:?
#1  Foam::sigFpe::sigHandler(int) at ??:?
#2   in "/lib/x86_64-linux-gnu/libc.so.6"
#3  Foam::GAMGSolver::scale(Foam::Field<double>&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, Foam::Field<double> const&, unsigned char) const at ??:?
#4  Foam::GAMGSolver::Vcycle(Foam::PtrList<Foam::lduMatrix::smoother> const&, Foam::Field<double>&, Foam::Field<double> const&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::PtrList<Foam::Field<double> >&, Foam::PtrList<Foam::Field<double> >&, unsigned char) const at ??:?
#5  Foam::GAMGSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ??:?
#6  Foam::fvMatrix<double>::solveSegregated(Foam::dictionary const&) at ??:?
#7  Foam::fvMatrix<double>::solve(Foam::dictionary const&) at ??:?
#8  
 at ??:?
#9  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#10  
 at ??:?
Floating point exception (core dumped)
What does that mean? Any Idea please?

Regards
Maimouna is offline   Reply With Quote

Old   May 17, 2014, 08:11
Default
  #95
New Member
 
Shuai Wang
Join Date: Mar 2014
Posts: 26
Rep Power: 12
Shuai_W is on a distinguished road
Dear Maimouna:
Did you solve the problem in #93? I am so sorry to say that I have not encountered with that problem, but I think it may be ralated to your OpenFOAM. When you upgrade the version of Ubuntu, and it may have an influence on your OpenFOAM. I used Ubuntu 12.04,and it works well.
I hope you will solve it soon!
Shuai_W is offline   Reply With Quote

Old   May 18, 2014, 11:07
Default
  #96
Member
 
Sami
Join Date: Nov 2012
Location: Cap Town, South Africa
Posts: 87
Rep Power: 13
Mehrez is on a distinguished road
Hi dear sasanghomi,

Thank you for this interesting reply. However I have 2 main questions in order to understand the changes you have apported to the default icoFoam fvSchemes file:
1- When you switch from: "ddtSchemes { default Euler;" to: "ddtSchemes { default backward;", does the effect on the fluid is that I have less damping ?
2- What does the other modifications (like "limited 0.5") do exactly or how they affect the solution ?
Thank you in advance,

Best regards,

Mehrez

Quote:
Originally Posted by sasanghomi View Post
Hi ,
I think you use icoFoam as a solver. So I think two parameters have vital role for getting the exact result : 1) discretization method of terms in equations 2)Mesh generation.
So change your fvSchemes and fvSolution as below :
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM Extend Project: Open Source CFD        |
|  \\    /   O peration     | Version:  1.6-ext                               |
|   \\  /    A nd           | Web:      www.extend-project.de                 |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      fvSolution;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

solvers
{
    p
    {
        solver           PCG;
        preconditioner   DIC;
        tolerance        1e-06;
        relTol           0;
    };

    U
    {
        solver         BiCG;
        preconditioner   DILU;
        tolerance        1e-05;
        relTol           0;
    };
}


PISO
{
   nCorrectors    2;
   nNonOrthogonalCorrectors 0;
    pRefCell        0;
    pRefValue       0;
 }
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM Extend Project: Open Source CFD        |
|  \\    /   O peration     | Version:  1.6-ext                               |
|   \\  /    A nd           | Web:      www.extend-project.de                 |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

ddtSchemes
{
    default backward;
}

gradSchemes
{
    default         Gauss linear;
    grad(p)         Gauss linear;
}

divSchemes
{
    default         none;
    div(phi,U)      Gauss GammaV 0.5 ;

}

laplacianSchemes
{
    default         Gauss linear limited 0.5;
    laplacian(nu,U) Gauss linear limited 0.5;
    laplacian(rUA,pcorr) Gauss linear limited 0.5;
    laplacian(rAU,p) Gauss linear limited 0.5;
}

interpolationSchemes
{
    default         linear;
    interpolate(HbyA) linear;
}

snGradSchemes
{
    default         limited 0.5;
}

fluxRequired
{
    default         no;
    pcorr;
    p;
}
Hope this helps,
Sasan.
Mehrez is offline   Reply With Quote

Old   April 9, 2015, 09:08
Default
  #97
Member
 
Stephanie
Join Date: Feb 2015
Location: Magdeburg, Germany
Posts: 71
Rep Power: 11
stephie is on a distinguished road
Hello everyone,

at the moment I try to solve a tutorial for channel flow with respect to different LES models which was uploaded for a cours at Chalmers University of technology in 2001. After creating the mesh I wanted to refine the Mesh. I run topoSet. After, I should type in the command : refineMesh -dict -overwrite. And here is the first mistake:

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create polyMesh for time = 0

Mesh edge statistics:
x aligned : number:16376 minLen:0.005 maxLen:0.005
y aligned : number:16056 minLen:0.005 maxLen:0.005
z aligned : number:8232 minLen:0.005 maxLen:0.005
other : number:0 minLen:1e+15 maxLen:-1e+15

Refining according to refineMeshDict



--> FOAM FATAL IO ERROR:
cannot open file

file: /home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/-overwrite at line 0.

From function regIOobject::readStream()
in file db/regIOobject/regIOobjectRead.C at line 87.

FOAM exiting

It didn't work. When I typed in <refineMesh> it was okay. Why does this command don't work?

The next step should be to run the simulation by <pyFoamPlotRunner.py pimpleFoam >& log and it also do not work.
There is still the mistake: pyFoamPlotRunner command not found

I had a look in a lot of discussions, but I couldn't find an answer.. because pyFoam is alreay installed.

So i tried to type in <pimpleFoam> to start the simulation and here ist the next mistake:

--> FOAM FATAL IO ERROR: keyword laplacian(rAUf,p) is undefined in dictionary "/home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/system/fvSchemes.laplacianSchemes" file: /home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/system/fvSchemes.laplacianSchemes from line 45 to line 51. From function dictionary::lookupEntry(const word&, bool, bool) const in file db/dictionary/dictionary.C at line 437. FOAM exiting

I would be grateful if anyone might help me to solve this tutorial.

Thank you so much, nice regards,

Stephie
stephie is offline   Reply With Quote

Old   April 9, 2015, 10:36
Default
  #98
Member
 
Sami
Join Date: Nov 2012
Location: Cap Town, South Africa
Posts: 87
Rep Power: 13
Mehrez is on a distinguished road
Hi dear Stephie,
After refining the mesh you should interpolate your fields (U, p... for example) from the old mesh to the new fine mesh. Then, you can start your simulation.
There is a function in OpenFoam to perform interpolation.
Regards,

Mhrz

Quote:
Originally Posted by stephie View Post
Hello everyone,

at the moment I try to solve a tutorial for channel flow with respect to different LES models which was uploaded for a cours at Chalmers University of technology in 2001. After creating the mesh I wanted to refine the Mesh. I run topoSet. After, I should type in the command : refineMesh -dict -overwrite. And here is the first mistake:

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create polyMesh for time = 0

Mesh edge statistics:
x aligned : number:16376 minLen:0.005 maxLen:0.005
y aligned : number:16056 minLen:0.005 maxLen:0.005
z aligned : number:8232 minLen:0.005 maxLen:0.005
other : number:0 minLen:1e+15 maxLen:-1e+15

Refining according to refineMeshDict



--> FOAM FATAL IO ERROR:
cannot open file

file: /home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/-overwrite at line 0.

From function regIOobject::readStream()
in file db/regIOobject/regIOobjectRead.C at line 87.

FOAM exiting

It didn't work. When I typed in <refineMesh> it was okay. Why does this command don't work?

The next step should be to run the simulation by <pyFoamPlotRunner.py pimpleFoam >& log and it also do not work.
There is still the mistake: pyFoamPlotRunner command not found

I had a look in a lot of discussions, but I couldn't find an answer.. because pyFoam is alreay installed.

So i tried to type in <pimpleFoam> to start the simulation and here ist the next mistake:

--> FOAM FATAL IO ERROR: keyword laplacian(rAUf,p) is undefined in dictionary "/home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/system/fvSchemes.laplacianSchemes" file: /home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/system/fvSchemes.laplacianSchemes from line 45 to line 51. From function dictionary::lookupEntry(const word&, bool, bool) const in file db/dictionary/dictionary.C at line 437. FOAM exiting

I would be grateful if anyone might help me to solve this tutorial.

Thank you so much, nice regards,

Stephie
Mehrez is offline   Reply With Quote

Old   April 9, 2015, 11:27
Default
  #99
Senior Member
 
Alexey Matveichev
Join Date: Aug 2011
Location: Nancy, France
Posts: 1,930
Rep Power: 38
alexeym has a spectacular aura aboutalexeym has a spectacular aura about
Send a message via Skype™ to alexeym
Hi,

Quote:
Originally Posted by stephie View Post
After, I should type in the command : refineMesh -dict -overwrite. And here is the first mistake:
...
--> FOAM FATAL IO ERROR:
cannot open file

file: /home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/-overwrite at line 0.
The command in fact should be

Code:
refineMesh -dict system/refineMeshDict -overwrite
Guess this is again due to OpenFOAM's version incompatibility.

Quote:
So i tried to type in <pimpleFoam> to start the simulation and here ist the next mistake:

--> FOAM FATAL IO ERROR: keyword laplacian(rAUf,p) is undefined in dictionary "/home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/system/fvSchemes.laplacianSchemes" file: /home/stephanie/OpenFOAM/stephanie-2.3.1/run/smagorinsky_mini/system/fvSchemes.laplacianSchemes from line 45 to line 51. From function dictionary::lookupEntry(const word&, bool, bool) const in file db/dictionary/dictionary.C at line 437. FOAM exiting
And this again is due to modification in 2.3.1. You have this line in fvSchemes:

Code:
laplacian((1|A(U)),p) Gauss linear corrected;
now it should be written as

Code:
laplacian(rAUf,p)  Gauss linear corrected;
And finally about pyFoamPlotRunner error, it is not pyFoamPlotRunner, it is pyFoamPlotRunner.py.
stephie likes this.
alexeym is offline   Reply With Quote

Old   April 10, 2015, 04:18
Default
  #100
Member
 
Stephanie
Join Date: Feb 2015
Location: Magdeburg, Germany
Posts: 71
Rep Power: 11
stephie is on a distinguished road
Good morning Alexey,

you are amazing - thank you so much. After typing in the correct command to refine the Mesh it worked. Now it looks like the image in the description

Also the second hint was right, I changed this line in fvSchemes and the simulation run.
The only thing, which did not work is pyFoamPlotRunner.py. There is still the mistake command not found. Maybe I miss something when I installed OpenFoam...do you have any idea?
But it doesn't matter... I'm happy, the simulation run.

Thank you so much for your help
stephie 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
[Other] OpenFoam Flow over a Circular Cylinder WolfgangS. OpenFOAM Meshing & Mesh Conversion 12 March 3, 2014 10:53
benchmark: flow over a circular cylinder goodegg Main CFD Forum 12 January 22, 2013 11:47
Particle deposition on circular cylinder in turbulent flow Julian K. CFX 1 October 3, 2011 17:51
flow around a cylinder pXYZ Main CFD Forum 14 July 25, 2011 10:05
Flow induced vibration of a mobile cylinder Hooman Main CFD Forum 0 December 31, 2010 08:48


All times are GMT -4. The time now is 18:58.