|
[Sponsors] |
wallHeatFlux utility for an incompressible case |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
April 15, 2015, 13:33 |
|
#41 | |
Member
Naresh Yathuru
Join Date: Feb 2015
Posts: 66
Rep Power: 11 |
Quote:
I also had the same confusion thanks to wyldkat fot the wiki page. you dont have to copy it into application/utilities. follow this page https://github.com/wyldckat/wallHeatFluxIncompressible Note: follow the second procedure using zip I followed that. basically it works hope it also works for you. let me know if u face any problem. regards, Naresh |
||
April 16, 2015, 02:51 |
|
#42 |
New Member
Gautam Saikia
Join Date: Jan 2015
Location: India
Posts: 12
Rep Power: 11 |
Thank you so much Naresh. I did as mentioned in the page. I guess now I can directly use the utility.
Regards Gautam |
|
July 24, 2015, 14:07 |
|
#43 |
Senior Member
Huynh Phong Thanh
Join Date: Aug 2013
Location: Ho Chi Minh City
Posts: 105
Rep Power: 13 |
Hi everybody,
When I tried wallHeatFlux the buoyantSimpleFoam OF 2.1.1 with thermo type as first comment of topic it was no problem: Code:
hPsiThermo<pureMixture<constTransport<specieThermo<hConstThermo<perfectGas>>>>>; Code:
ePsiThermo<pureMixture<constTransport<specieThermo<eConstThermo<perfectGas>>>>>; Code:
/*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.1.1 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ Build : 2.1.1-221db2718bbb Exec : wallHeatFlux -latestTime Date : Jul 25 2015 Time : 06:53:06 Host : "CompEng" PID : 2979 Case : /home/huynh/OpenFOAM/huynh-2.1.1/run/prism 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.0003 Time = 0.0003 Selecting thermodynamics package ePsiThermo<pureMixture<constTransport<specieThermo<eConstThermo<perfectGas>>>>> --> FOAM FATAL ERROR: Not implemented From function basicThermo::h() in file basicThermo/basicThermo.C at line 260. FOAM aborting #0 Foam::error::printStack(Foam::Ostream&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so" #1 Foam::error::abort() in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so" #2 Foam::basicThermo::h() in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libbasicThermophysicalModels.so" #3 in "/opt/openfoam211/platforms/linuxGccDPOpt/bin/wallHeatFlux" #4 __libc_start_main in "/lib/tls/i686/cmov/libc.so.6" #5 in "/opt/openfoam211/platforms/linuxGccDPOpt/bin/wallHeatFlux" Aborted Last edited by hiuluom; July 24, 2015 at 20:54. |
|
July 25, 2015, 12:10 |
|
#44 |
Senior Member
Huynh Phong Thanh
Join Date: Aug 2013
Location: Ho Chi Minh City
Posts: 105
Rep Power: 13 |
In sonicFoam the thermophyscialProperties is:
Code:
thermoType ePsiThermo<pureMixture<constTransport<specieThermo<eConstThermo<perfectGas>>>>>; mixture { specie { nMoles 1; molWeight 28.9; } thermodynamics { Cv 717.5; Hf 0; } transport { mu 1.8e-05; Pr 0.7; } } Code:
thermoType hPsiThermo<pureMixture<constTransport<specieThermo<hConstThermo<perfectGas>>>>>; pRef 100000; mixture { specie { nMoles 1; molWeight 28.9; } thermodynamics { Cp 1000; Hf 0; } transport { mu 1.8e-05; Pr 0.7; } } Code:
/*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.1.1 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ Build : 2.1.1-221db2718bbb Exec : wallHeatFluxRho -latestTime Date : Jul 25 2015 Time : 22:05:09 Host : "CompEng" PID : 4590 Case : /home/huynh/OpenFOAM/huynh-2.1.1/run/prism 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.0003 Time = 0.0003 Selecting thermodynamics package hPsiThermo<pureMixture<constTransport<specieThermo<hConstThermo<perfectGas>>>>> Reading/calculating face flux field phi Selecting RAS turbulence model kEpsilon kEpsilonCoeffs { Cmu 0.09; C1 1.44; C2 1.92; C3 -0.33; sigmak 1; sigmaEps 1.3; Prt 1; } Wall heat fluxes [W] prismWall 0 End Thank you. Last edited by hiuluom; July 25, 2015 at 22:26. |
|
October 4, 2015, 11:28 |
|
#45 |
New Member
Nikolai Tauber
Join Date: Sep 2015
Location: Aarhus, Denmark
Posts: 14
Rep Power: 11 |
Dear Bruno,
I am trying to use your wallHeatFluxIncompressible utility from https://github.com/wyldckat/wallHeatFluxIncompressible I have followed the instructions, but when i run wmake, I get plenty of errors like the following: Code:
/opt/local/include/gcc46/c++/cwchar:66:11: error: '::mbstate_t' has not been declared /opt/local/include/gcc46/c++/cwchar:141:11: error: '::wint_t' has not been declared /opt/local/include/gcc46/c++/cwchar:143:11: error: '::btowc' has not been declared /opt/local/include/gcc46/c++/cwchar:144:11: error: '::fgetwc' has not been declared /opt/local/include/gcc46/c++/cwchar:145:11: error: '::fgetws' has not been declared /opt/local/include/gcc46/c++/cwchar:146:11: error: '::fputwc' has not been declared /opt/local/include/gcc46/c++/cwchar:147:11: error: '::fputws' has not been declared /opt/local/include/gcc46/c++/cwchar:148:11: error: '::fwide' has not been declared /opt/local/include/gcc46/c++/cwchar:149:11: error: '::fwprintf' has not been declared /opt/local/include/gcc46/c++/cwchar:150:11: error: '::fwscanf' has not been declared /opt/local/include/gcc46/c++/cwchar:151:11: error: '::getwc' has not been declared /opt/local/include/gcc46/c++/cwchar:152:11: error: '::getwchar' has not been declared /opt/local/include/gcc46/c++/cwchar:153:11: error: '::mbrlen' has not been declared /opt/local/include/gcc46/c++/cwchar:154:11: error: '::mbrtowc' has not been declared /opt/local/include/gcc46/c++/cwchar:155:11: error: '::mbsinit' has not been declared /opt/local/include/gcc46/c++/cwchar:156:11: error: '::mbsrtowcs' has not been declared /opt/local/include/gcc46/c++/cwchar:157:11: error: '::putwc' has not been declared /opt/local/include/gcc46/c++/cwchar:158:11: error: '::putwchar' has not been declared /opt/local/include/gcc46/c++/cwchar:160:11: error: '::swprintf' has not been declared /opt/local/include/gcc46/c++/cwchar:162:11: error: '::swscanf' has not been declared /opt/local/include/gcc46/c++/cwchar:163:11: error: '::ungetwc' has not been declared /opt/local/include/gcc46/c++/cwchar:164:11: error: '::vfwprintf' has not been declared /opt/local/include/gcc46/c++/cwchar:166:11: error: '::vfwscanf' has not been declared /opt/local/include/gcc46/c++/cwchar:169:11: error: '::vswprintf' has not been declared /opt/local/include/gcc46/c++/cwchar:172:11: error: '::vswscanf' has not been declared /opt/local/include/gcc46/c++/cwchar:174:11: error: '::vwprintf' has not been declared /opt/local/include/gcc46/c++/cwchar:176:11: error: '::vwscanf' has not been declared /opt/local/include/gcc46/c++/cwchar:178:11: error: '::wcrtomb' has not been declared /opt/local/include/gcc46/c++/cwchar:179:11: error: '::wcscat' has not been declared Code:
wallHeatFluxIncompressible Code:
-bash: wallHeatFluxIncompressible: command not found |
|
October 4, 2015, 16:20 |
|
#46 | |||
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Quick answers:
@hiuluom: Sorry for the late reply, but here are the answers: Quote:
Quote:
... Ah, no, I had this vague memory and this was done by someone else in another thread. You can find the details on how to do this here: http://www.cfd-online.com/Forums/ope...tml#post476479 - post #3 _________________ @niko0807: Quote:
I ask this because if you are not able to build OpenFOAM (or foam-extend) from source code, then you will not be able to build this utility from source code. Last edited by wyldckat; October 8, 2015 at 19:31. Reason: fixed small typo |
||||
October 5, 2015, 08:57 |
|
#47 |
New Member
Nikolai Tauber
Join Date: Sep 2015
Location: Aarhus, Denmark
Posts: 14
Rep Power: 11 |
I am building building on Mac OS X from an image, so that is definitely the problem. Thanks for noticing that.
If I build OpenFOAM from this: http://openfoamwiki.net/index.php/In...OpenFOAM_2.3.x Would that be building from source code or is that also an image build? |
|
October 6, 2015, 01:58 |
|
#48 |
Senior Member
Huynh Phong Thanh
Join Date: Aug 2013
Location: Ho Chi Minh City
Posts: 105
Rep Power: 13 |
Hi Bruno,
i solved my problem at here: http://www.cfd-online.com/Forums/ope...sonicfoam.html Thanks your reply. Thanh |
|
October 8, 2015, 19:33 |
|
#49 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Quote:
|
||
December 27, 2015, 14:15 |
|
#50 |
Member
Thiago Parente Lima
Join Date: Sep 2011
Location: Diamantina, Brazil.
Posts: 65
Rep Power: 15 |
Hi all,
If you look at the utility wallshearStress, it has the options for compressible and incompressible flow (apparently only for RANS modelling). Maybe somebody (not me ) could add this functionality to the wallHeatFlux utility and create a more general one which would work for both types of fluid. Regards,
__________________
Fields of interest: buoyantFoam, chtMultRegionFoam. |
|
January 2, 2016, 18:47 |
|
#51 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Greetings Thiago,
I do have this on my to-do list and I've been taking a look into this for the past hour or so. The conclusion I've reached so far is that such a feature is currently (in OpenFOAM 3.0) rather limited, because the boundary condition "turbulentHeatFluxTemperature" only exists in compressible form. I then remembered about a recent bug report: http://www.openfoam.org/mantisbt/view.php?id=1856 - essentially the explicit "Boussinesq" solver implementations will be dropped in favour of the more general implementation that was introduced in the commits related to this bug report. Therefore, it no longer makes sense to implement an explicit incompressible version of wallHeatFlux, since it's just a matter of using the incompressible thermodynamic implementation and the respective Boussinesq equation of state. Best regards, Bruno
__________________
|
|
January 18, 2016, 08:46 |
|
#52 | |
Member
Join Date: May 2015
Posts: 68
Rep Power: 11 |
Quote:
I used OF 2.4.0 for some testcases with turbulentHeatFluxTemperature and it works fine. So now I am a little confused why there is no turbulentHeatFluxTemperature in Vers 3.0. |
||
January 31, 2016, 13:08 |
|
#53 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Greetings hcl734,
Quote:
Having nearly-duplicated code, leads to having to maintain all of the duplicate parts of the code. If a bug is found in one of them, it will have to be fixed in the other as well. This means that after fixing the bug, it's also necessary to test if the bug was fixed for both parts. Therefore, what was a simple bug that took 20 minutes to solve, can lead to 1 hour or more to fix both bugs, given that the incompressible implementation needs an adapted case for testing the same issue. 1 hour might not seem a lot to you, but take a look at how many bugs are currently open on the bug tracker: http://www.openfoam.org/mantisbt/my_view_page.php - at the time of this writing, 90 issues are still open and unassigned, potentially representing somewhere between 90h to several hundreds of hours to solve of all of those reports. And because most thermodynamic problems require compressible fluid flow, it makes sense that the Boussinesq approach becomes a modelling strategy that is integrated into the compressible side of things. If you want to use the incompressible form of the Boussinesq implementation, the easiest solution is to keep using OpenFOAM 2.4.x . Best regards, Bruno
__________________
|
||
February 10, 2016, 01:52 |
Heat Flux for incompressible laminar flows
|
#54 |
New Member
Join Date: Feb 2015
Posts: 18
Rep Power: 11 |
Dear Bruno,
I'm trying to set up a case based on incompressible laminar flow (air) with heat flux boundary condition in the modified icoFoam solver (which has the energy equation). I'm trying to assign a heat flux B.C. on the circular obstruction wall (see attached image). I've installed the wallHeatFluxIncompressible (v2.3) utility. When I run my_icoFoam (I’m using OpenFOAM 2.4.0). I get the following error: Code:
--> FOAM FATAL IO ERROR: Unknown patchField type turbulentHeatFluxTemperature for patch type wall Valid patchField types are : 62 ( advective calculated codedFixedValue codedMixed cyclic . . . . Code:
--> FOAM FATAL IO ERROR: keyword rhoCp0 is undefined in dictionary "/home/OpenFOAM-2.4.0/tutorials/heatTransfer/buoyantBoussinesqSimpleFoam/1A/constant/transportProperties" file: /home/OpenFOAM-2.4.0/tutorials/heatTransfer/buoyantBoussinesqSimpleFoam/1A/constant/transportProperties from line 17 to line 44. From function dictionary::lookupEntry(const word&, bool, bool) const in file db/dictionary/dictionary.C at line 442. FOAM exiting For the icoFoam directory these are my boundary conditions and other settings: U Code:
dimensions [0 1 -1 0 0 0 0]; internalField uniform (0 0 0); boundaryField { lowerwall { type fixedValue; value uniform (0 0 0); } upperwall { type fixedValue; value uniform (0 0 0); } circle { type fixedValue; value uniform (0 0 0); } inlet { type fixedValue; value uniform (0.1 0 0); } outlet { type zeroGradient; } frontAndBack { type empty; } } Code:
dimensions [0 0 0 1 0 0 0]; internalField uniform 300; boundaryField { lowerwall { type zeroGradient; } upperwall { type zeroGradient; } circlewall { type turbulentHeatFluxTemperature; value uniform 300; q uniform 1000.0; "q" is heat flux then what's "value"? heatSource flux; alphaEff alphaEff; } inlet { type fixedValue; value uniform 300; } outlet { type fixedValue; value uniform 300; } frontAndBack { type empty; } } Code:
dimensions [0 2 -2 0 0 0 0]; internalField uniform 0; boundaryField { lowerwall { type zeroGradient; } upperwall { type zeroGradient; } circlewall { type zeroGradient; } inlet { type zeroGradient; } outlet { type fixedValue; value uniform 0; } frontAndBack { type empty; } } Code:
boundaryField { lowerwall { type calculated; value uniform 0; } upperwall { type calculated; value uniform 0; } circlewall { type calculated; value uniform 0; } inlet { type calculated; value uniform 0; } outlet { type calculated; value uniform 0; } frontAndBack { type empty; } } Code:
boundaryField { bottomwall { type calculated; value uniform 0; } topwall { type calculated; value uniform 0; } obstructionwall { type calculated; value uniform 0; } inlet { type calculated; value uniform 0; } outlet { type calculated; value uniform 0; } frontAndBack { type empty; } } Code:
dimensions [0 -1 0 1 0 0 0]; internalField uniform 0; boundaryField { lowerwall { type calculated; value uniform 0; } upperwall { type calculated; value uniform 0; } circlewall { type calculated; value uniform 0; } inlet { type calculated; value uniform 0; } outlet { type calculated; value uniform 0; } frontAndBack { type empty; } } Code:
nu nu [ 0 2 -1 0 0 0 0 ] 1.5e-05; DT DT [0 2 -1 0 0 0 0] 22e-06; alphat Code:
dimensions [ 0 2 -1 0 0 0 0 ]; internalField uniform 0.0; boundaryField { lowerwall { type alphatJayatillekeWallFunction; Prt 0.85; value uniform 0.0; } upperwall { type alphatJayatillekeWallFunction; Prt 0.85; value uniform 0.0; } inlet { type calculated; //Prt 0.85; value uniform 0.0; } outlet { type calculated; //Prt 0.85; value uniform 0.0; } circlewall { type alphatJayatillekeWallFunction; Prt 0.85; value uniform 0.0; } frontAndBack { type empty; } Code:
dimensions [0 2 -1 0 0 0 0]; internalField uniform 1.764591978e-05; boundaryField { lowerwall { type calculated; value uniform 1.764591978e-05; } upperwall { type calculated; value uniform 1.764591978e-05; } inlet { type calculated; value uniform 1.764591978e-05; } outlet { type calculated; value uniform 1.764591978e-05; } circlewall { type calculated; value uniform 1.764591978e-05; } frontAndBack { type empty; } } Code:
dimensions [ 0 2 -2 0 0 0 0 ]; internalField uniform 0.0; boundaryField { lowerwall { type fixedFluxPressure; value uniform 0; rho rhok; } upperwall { type fixedFluxPressure; value uniform 0; rho rhok; } circlewall { type fixedFluxPressure; value uniform 0; rho rhok; } inlet { type fixedFluxPressure; value uniform 0; rho rhok; } outlet { type fixedFluxPressure; value uniform 0; rho rhok; } frontAndBack { type empty; } Code:
transportModel Newtonian; // Laminar viscosity nu nu [0 2 -1 0 0 0 0] 1.7e-05; // Thermal expansion coefficient beta beta [0 0 0 -1 0 0 0] 3.4482e-03; // 1/Tref // Reference temperature TRef TRef [0 0 0 1 0 0 0] 300; // Laminar Prandtl number Pr Pr [0 0 0 0 0 0 0] 0.9; // Turbulent Prandtl number Prt Prt [0 0 0 0 0 0 0] 0.7; // Cp0 value needed for wallHeatFluxIncompressible //rho0 rho0 [1 -3 0 0 0 0 0] 1.2; // rho0 value needed for wallHeatFluxIncompressible //Cp0 1005; // Cp0 value needed for wallHeatFluxIncompressible rho0 rho0 [1 -3 0 0 0 0 0] 1; // rho0 value needed for wallHeatFluxIncompressible Cp0 1005; Many thanks. Kevin |
|
February 28, 2016, 00:54 |
Heat Flux for incompressible laminar flows
|
#55 |
New Member
Join Date: Feb 2015
Posts: 18
Rep Power: 11 |
Anyone knows how to tackle this ?
|
|
March 19, 2016, 17:40 |
|
#56 | ||
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Greetings Kevin,
Sorry for the late reply, but now that I've read your post, I'm afraid I sighed very heavily ... Quote:
After scrolling through your post (please, next time package the case folder into a ZIP file and attach it in your post or share in a file sharing website, such as DropBox), you have the following entry: Quote:
If you had studied this post: http://www.cfd-online.com/Forums/ope...tml#post516950 - post #27, you would then possibly end up here: http://www.openfoam.org/mantisbt/view.php?id=1433#c3548 - where I explain in summary detail what's going on: Code:
3.b) One perfectionist proposition is to enforce the correct units when reading from the dictionary, e.g.: Code:
Replaced Cp0 with rhoCp0 and added comment concerning units to clarify usage Code:
rhoCp0 rhoCp0 [1 -1 -2 -1 0 0 0] 1005.0; Best regards, Bruno
__________________
|
|||
March 19, 2016, 17:50 |
|
#57 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
The following reply is for Scram_1's question sent via PM, which I believe is best answered here for the benefit of other who are using ports of OpenFOAM on Windows (and no, I'm not referring to Docker ).
The question/problem was this (well, it's just part of the message): Quote:
The problem is somewhat simple: Windows is more picky about which libraries an executable should link to at build time... as a safety measure. Anyway, the solution is to add the missing libraries in the file "Make/options", namely the list "EXE_LIBS". Change this: Code:
EXE_LIBS = \ -lincompressibleTransportModels \ -lincompressibleRASModels \ -lincompressibleLESModels \ -lfiniteVolume \ -lmeshTools Code:
EXE_LIBS = \ -lincompressibleTransportModels \ -lincompressibleRASModels \ -lincompressibleLESModels \ -lincompressibleTurbulenceModel \ -lfiniteVolume \ -lmeshTools Best regards, Bruno
__________________
|
||
March 19, 2016, 18:52 |
|
#58 |
Member
Join Date: Oct 2015
Posts: 63
Rep Power: 11 |
Working like a charm now...
Thanks Bruno!!! |
|
March 25, 2016, 05:37 |
Wall Heat Flux
|
#59 |
New Member
Join Date: Feb 2015
Posts: 18
Rep Power: 11 |
Dear Bruno,
Thank you for your kind assistance! I've studied the posts you've shared, and have included rhoCp0 in transportProperties. Afterwards, I got this error: Code:
wrong token type - expected Scalar, found on line 40 the word 'rhoCp0' HTML Code:
http://www.cfd-online.com/Forums/openfoam-pre-processing/104815-turbulentheatfluxtemperature.html Code:
rhoCp0 rhoCp0 [1 -1 -2 -1 0 0 0] 1005.0 Code:
rhoCp0 1005.0; Kind Regards, Kevin |
|
May 3, 2016, 15:12 |
|
#60 |
New Member
Nestor Rueda
Join Date: Apr 2016
Posts: 3
Rep Power: 10 |
Hi Bruno,
I didn't read your comment about maintenability before, however, I have updated the utility so it can work with OF 3.0.1. I'd like to share it with you so you could upload it if you find it useful. Regards. Nestor |
|
Tags |
incompressible, open foam, wallheatflux |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
how to create an internal fan for a multiRegion case? | phsieh2005 | OpenFOAM | 0 | February 2, 2012 17:32 |
wallHeatFlux utility in OpenFoam1.6 | maruthamuthu_venkatraman | OpenFOAM | 29 | October 3, 2011 11:43 |
thermal analysis - how to model internal fan? | Pei-Ying Hsieh | Main CFD Forum | 6 | March 20, 2008 11:35 |
Free surface boudary conditions with SOLA-VOF | Fan | Main CFD Forum | 10 | September 9, 2006 13:24 |
flow simulation across a small fan | jane luo | Main CFD Forum | 15 | April 12, 2004 18:49 |