|
[Sponsors] |
Problem in fvschemes divSchemes cannot use Gauss linearUpwind |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
Member
nicolas
Join Date: Mar 2009
Location: Glasgow
Posts: 42
Rep Power: 17 ![]() |
Hello,
Looking at the UserGuide, it's something I should be able to do. I want to use the linear Upwind scheme for div(phi,U). Using simpleFoam in Openfoam 1.4.1 on linux 64bit. div(phi,U) Gauss linear; div(phi,U) Gauss linear corrected; div(phi,U) Gauss QUICK; works fine. But div(phi,U) Gauss linearUpwind; does not. I get: --> FOAM FATAL IO ERROR : Grad scheme not specified Valid grad schemes are : 8 ( cellMDLimited extendedLeastSquares faceMDLimited leastSquares fourth faceLimited cellLimited Gauss ) file: /home/nr/OpenFOAM/nrousselon-1.4.1/run/ccm2foam4/system/fvSchemes::div(phi,U) at line 40. From function gradScheme<type>::New(Istream& schemeData) in file /home/nr/OpenFOAM/OpenFOAM-1.4.1/src/finiteVolume/lnInclude/gradScheme.C at line 65. FOAM exiting /*---------------------------------------------------------------------------*\ | ========= | | | \ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \ / O peration | Version: 1.4 | | \ / A nd | Web: http://www.openfoam.org | | \/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; root ""; case ""; instance ""; local ""; class dictionary; object fvSchemes; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // ddtSchemes { default steadyState; } gradSchemes { default Gauss linear; grad(p) Gauss linear; grad(U) Gauss linear; } divSchemes { default none; div(phi,U) Gauss linear corrected; div(phi,k) Gauss upwind; div(phi,epsilon) Gauss upwind; div(phi,R) Gauss upwind; div(R) Gauss linear; div(phi,nuTilda) 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(DepsilonEff,epsilon) Gauss linear corrected; laplacian(DREff,R) Gauss linear corrected; laplacian(DnuTildaEff,nuTilda) Gauss linear corrected; } interpolationSchemes { default linear; interpolate(U) linear; } snGradSchemes { default corrected; } fluxRequired { default no; p; } // ************************************************** *********************** // |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
Join Date: Mar 2009
Posts: 854
Rep Power: 22 ![]() |
You need to specify the grad-scheme used by linearUpwind, e.g.
div(phi,U) Gauss linearUpwind Gauss linear; or div(phi,U) Gauss linearUpwind leastSquares; or if you want to limit the gradient used by the linearUpwind scheme which is often beneficial div(phi,U) Gauss linearUpwind cellLimited Gauss linear 1; etc. |
|
![]() |
![]() |
![]() |
![]() |
#3 |
Member
nicolas
Join Date: Mar 2009
Location: Glasgow
Posts: 42
Rep Power: 17 ![]() |
Thanks,
just what I needed. Nicolas |
|
![]() |
![]() |
![]() |
![]() |
#4 | ||
Member
Join Date: Nov 2009
Location: Munich
Posts: 43
Rep Power: 17 ![]() |
I have the same problem and tried to adapte it on my case with the bouyantBoussinesqSimpleFoam, but it didn't work.
This is what I get: Quote:
Quote:
|
|||
![]() |
![]() |
![]() |
![]() |
#5 |
Senior Member
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33 ![]() |
You messed up the order: cellLimited is a modifier for a gradient scheme, so it comes first. Think about which class should contain which.
![]() div(phi,U) Gauss linearUpwind cellLimited Gauss linear 1; Enjoy, Hrv
__________________
Hrvoje Jasak Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk |
|
![]() |
![]() |
![]() |
![]() |
#6 |
Member
Join Date: Nov 2009
Location: Munich
Posts: 43
Rep Power: 17 ![]() |
Hi Hrvoje,
thank you. Stupid mistake. Now it's running! :-) Regards, Erik |
|
![]() |
![]() |
![]() |
![]() |
#7 |
Senior Member
Claus Meister
Join Date: Aug 2009
Location: Wiesbaden, Germany
Posts: 241
Rep Power: 18 ![]() |
Hello!
I got a question. Does div(phi,U) Gauss linearUpwind fourth mean that with order fourt the velocity field is approximated? Cheers |
|
![]() |
![]() |
![]() |
![]() |
#8 |
Senior Member
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36 ![]() ![]() |
No, it means you use a fourth-order scheme to compute the gradients, but clearly the order of the linearUpwind stays unchanged.
__________________
Alberto Passalacqua GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541) OpenQBMM - An open-source implementation of quadrature-based moment methods. To obtain more accurate answers, please specify the version of OpenFOAM you are using. ![]() |
|
![]() |
![]() |
![]() |
![]() |
#9 |
Senior Member
Claus Meister
Join Date: Aug 2009
Location: Wiesbaden, Germany
Posts: 241
Rep Power: 18 ![]() |
I think I have to learn something. Could you send me a reference which contains the derivation of this kind of scheme?
|
|
![]() |
![]() |
![]() |
![]() |
#10 |
Member
José
Join Date: Jan 2011
Posts: 73
Rep Power: 16 ![]() |
Could you please have a look at this thread I just created?
http://www.cfd-online.com/Forums/ope...fvschemes.html thanks! |
|
![]() |
![]() |
![]() |
![]() |
#11 |
New Member
Jozsef Rideg
Join Date: Feb 2011
Location: Budapest, Hungary
Posts: 21
Rep Power: 15 ![]() |
"
div(phi,U) Gauss linearUpwind Gauss linear; or div(phi,U) Gauss linearUpwind leastSquares; or if you want to limit the gradient used by the linearUpwind scheme which is often beneficial div(phi,U) Gauss linearUpwind cellLimited Gauss linear 1; etc.[/QUOTE]" Does anyone know, how should the same fvSchemes be set in the 2.0 version of OpenFOAM? |
|
![]() |
![]() |
![]() |
![]() |
#12 |
Senior Member
|
Hi!
Code:
gradSchemes { default cellLimited leastSquares 1; } divSchemes { default none; div(phi,epsilon) Gauss linearUpwind grad(epsilon); // OF20x syntax div(phi,k) Gauss linearUpwind grad(k); // OF20x syntax div(phi,U) Gauss linearUpwind grad(U); // OF20x syntax div((nuEff*dev(T(grad(U))))) Gauss linear; // OF20x syntax }
__________________
Best regards, Dr. Alexander VAKHRUSHEV Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics" Simulation and Modelling of Metallurgical Processes Department of Metallurgy University of Leoben http://smmp.unileoben.ac.at |
|
![]() |
![]() |
![]() |
![]() |
#13 |
New Member
Felipe
Join Date: Apr 2010
Posts: 13
Rep Power: 16 ![]() |
Could you help me with this:
Implementing: laplacian(nuEff,U) Gauss linear Gauss fourth; gives: [0] --> FOAM FATAL IO ERROR: [0] Unknown discretisation scheme fourth Valid schemes are : 3 ( corrected limited uncorrected ) but it should be able to work with fourth... Thanks |
|
![]() |
![]() |
![]() |
![]() |
#14 | |
Senior Member
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36 ![]() ![]() |
Quote:
Gauss <scheme> <correction option>; so Gauss linear corrected; For fourth-order it is: Gauss cubic corrected; Best,
__________________
Alberto Passalacqua GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541) OpenQBMM - An open-source implementation of quadrature-based moment methods. To obtain more accurate answers, please specify the version of OpenFOAM you are using. ![]() |
||
![]() |
![]() |
![]() |
![]() |
#15 |
New Member
Felipe
Join Date: Apr 2010
Posts: 13
Rep Power: 16 ![]() |
Thanks Alberto for your reply
Now it is running, so I hope my solution will improve. Thanks Felipe |
|
![]() |
![]() |
![]() |
![]() |
#16 |
New Member
Jozsef Rideg
Join Date: Feb 2011
Location: Budapest, Hungary
Posts: 21
Rep Power: 15 ![]() |
||
![]() |
![]() |
![]() |
![]() |
#17 |
New Member
Felipe
Join Date: Apr 2010
Posts: 13
Rep Power: 16 ![]() |
Hi again Alberto
Well my simulation ran, but I guess I have not achieved what I wanted. In the attached graph I have made the simulations from 0 to 20 degrees with a step of 2 degrees with OpenFOAM and another CFD code. I want to use the QUICK scheme, but I am over predicting my solution with OF in comparison to the other CFD code and both over predict lift in comparison to the measurements (Abbot and Doenhoff). I have my convection terms with QUICK and the diffusion terms with second order scheme (Gauss linear corrected). Thus I change my diffusion terms to a fourth interpolation scheme in order to improve my solution (QUICK2), and I can see that the curve is lower, but still it can not capture the separation pretty well. In this case my diffusion terms are Gauss cubic corrected. Do you have any suggestions for improving my results? Regards Felipe ps: I was going to upload the case but due to the size, it did not let allow me to do it. But I could send you a tar file with it (2.7 MB). |
|
![]() |
![]() |
![]() |
![]() |
#18 |
Senior Member
|
Which OF version do you use?
__________________
Best regards, Dr. Alexander VAKHRUSHEV Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics" Simulation and Modelling of Metallurgical Processes Department of Metallurgy University of Leoben http://smmp.unileoben.ac.at |
|
![]() |
![]() |
![]() |
![]() |
#19 |
New Member
Felipe
Join Date: Apr 2010
Posts: 13
Rep Power: 16 ![]() |
I use 1.7.1
|
|
![]() |
![]() |
![]() |
![]() |
#20 |
Senior Member
|
Ok, because in 20x I noticed strange behavior: viscous terms are under-estimated in my case with equal settings I was simulating in v16 and 17x. I will study it in details and also report here on forum.
__________________
Best regards, Dr. Alexander VAKHRUSHEV Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics" Simulation and Modelling of Metallurgical Processes Department of Metallurgy University of Leoben http://smmp.unileoben.ac.at |
|
![]() |
![]() |
![]() |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
DivSchemes Gauss limitedLinearV and interfaceCompression | nicasch | OpenFOAM Running, Solving & CFD | 1 | July 12, 2010 11:26 |
FvSchemes | sega | OpenFOAM Running, Solving & CFD | 2 | February 15, 2010 12:07 |
DivSchemes limitedLinearV and interfaceCompression | nicasch | OpenFOAM | 0 | February 28, 2008 11:33 |
Divschemes limitedLinearV 1 and interfaceCompression | nicasch | OpenFOAM | 0 | February 27, 2008 13:24 |
FvSchemes from 12 to 11 | fedegavo | OpenFOAM Running, Solving & CFD | 1 | January 20, 2006 14:49 |