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

limitTemperature in buoyantBoussinesqSimpleFoam

Register Blogs Community New Posts Updated Threads Search

Like Tree4Likes
  • 3 Post By jherb
  • 1 Post By SHUBHAM9595

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 8, 2021, 05:58
Default limitTemperature in buoyantBoussinesqSimpleFoam
  #1
Member
 
Javier Vinuales
Join Date: May 2016
Posts: 42
Rep Power: 9
jvinuales is on a distinguished road
Hi everyone,

I am using OpenFOAM v2006. I use a modified version of buoyantBoussinesqSimpleFoam (removing buoyant effects) in order to study forced convetion on internal flows.

I want to use limitTemperaure option in fvOptions but I got an error about thermophysicalProperties, as these are not utilised in buoyantBoussinesqSimpleFoam (I tried to add them in constant but does not work)

Code:
request for basicThermo thermophysicalProperties from objectRegistry region0 failed
    available objects of type basicThermo are
0()
Is there a way I can use this option at all with this solver?

Thanks.
jvinuales is offline   Reply With Quote

Old   February 8, 2021, 06:00
Default
  #2
Member
 
Javier Vinuales
Join Date: May 2016
Posts: 42
Rep Power: 9
jvinuales is on a distinguished road
Or any other alternatives to use temperature limiters?
jvinuales is offline   Reply With Quote

Old   February 11, 2021, 04:52
Default
  #3
Member
 
Javier Vinuales
Join Date: May 2016
Posts: 42
Rep Power: 9
jvinuales is on a distinguished road
anyone has a clue?
jvinuales is offline   Reply With Quote

Old   February 11, 2021, 05:30
Default
  #4
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 932
Rep Power: 12
HPE is on a distinguished road
Hi,

is there any way to test a tutorial, so that we can replicate the issue of yours locally? And then potentially, find a solution.

To my knowledge, there is no other temperature limiter fvOption available in OpenFOAM.
HPE is offline   Reply With Quote

Old   February 11, 2021, 05:44
Default
  #5
Member
 
Javier Vinuales
Join Date: May 2016
Posts: 42
Rep Power: 9
jvinuales is on a distinguished road
Sure thing, thanks for your reply. In order to recreate the error easily, I just added the fvOptions to the iglooWithFridges tutorial (buoyantBoussinesqSimpleFoam solver):

fvOptions:
Code:
limitT
{
    type       		limitTemperature;
    min        		0;
    max        		2000;
    selectionMode 	all;
	active      	yes;
}
error:
Code:
Selecting finite volume options type limitTemperature
    Source: limitT
    - selecting all cells
    - selected 7197 cell(s) with volume 129.524


--> FOAM FATAL ERROR: 

    request for basicThermo thermophysicalProperties from objectRegistry region0 failed
    available objects of type basicThermo are
0()

    From const Type& Foam::objectRegistry::lookupObject(const Foam::word&, bool) const [with Type = Foam::basicThermo]
    in file /home/pawan/OpenFOAM/OpenFOAM-v2006/src/OpenFOAM/lnInclude/objectRegistryTemplates.C at line 463.
Attached Files
File Type: zip iglooWithFridges.zip (15.2 KB, 5 views)
jvinuales is offline   Reply With Quote

Old   February 21, 2021, 12:30
Default
  #6
Senior Member
 
Joachim Herb
Join Date: Sep 2010
Posts: 650
Rep Power: 21
jherb is on a distinguished road
You are right, the existing limitTemperatue fvOption does not work with buoyantBoussinesqSimple/PimpleFoam solvers. You have to implement them yourself.
You can do this by copying the existing one, giving it a new name and compile it into seperate library. I think, the only thing you need to change is this line: https://github.com/OpenFOAM/OpenFOAM...tTemperature.C
Code:
fieldNames_.setSize(1, thermo.he().name());
into
Code:
fieldNames_.setSize(1, "T");
LuComet, SHUBHAM9595 and saidc. like this.
jherb is offline   Reply With Quote

Old   February 22, 2021, 03:17
Default
  #7
Senior Member
 
Join Date: Dec 2019
Posts: 215
Rep Power: 7
shock77 is on a distinguished road
Hi,


I have had the more or less the same issue when I wanted to use limitTemperature with rhoCentralFoam. I have implemented it myself, which is described in this thread: Sudden Increase of residuals.


I am using openfoam4.
shock77 is offline   Reply With Quote

Old   February 24, 2021, 04:37
Default
  #8
Member
 
Javier Vinuales
Join Date: May 2016
Posts: 42
Rep Power: 9
jvinuales is on a distinguished road
Thanks both for your answers. I will try to modify the existing limitTemperature as suggested by Joachim. Do you have any guidance about how to compile a new library? So far, I just have compiled new solvers, which is more straighforward.
jvinuales is offline   Reply With Quote

Old   February 24, 2021, 17:25
Default
  #9
Senior Member
 
Joachim Herb
Join Date: Sep 2010
Posts: 650
Rep Power: 21
jherb is on a distinguished road
These links should help (even if the first two are about a new boundary condtions instead of fvOptions):


https://openfoamwiki.net/index.php/H...dary_condition
https://www.youtube.com/watch?v=t0Vj2O_9HBQ
http://www.tfd.chalmers.se/~hani/kur..._Segersson.pdf
jherb is offline   Reply With Quote

Old   May 19, 2022, 14:43
Default
  #10
Member
 
MNM
Join Date: Aug 2017
Posts: 69
Rep Power: 8
SHUBHAM9595 is on a distinguished road
As mentioned here fvOptions: temperatureLimitsConstraint or limitTemperature not working on V3.0+ if u r using recent versions then this issue might be fixed already.....

However, if u r old school and still using former versions (like me)....Here's the attached file that have all the necessary modifications required to limit the Temperature......

Thanks to Joachim for the hint limitTemperature in buoyantBoussinesqSimpleFoam

However only commenting out that part wont solve the problem............The issue seems to arise bcz of the 'he' (either enthalpy or specific internal energy)based formulation of the Energy equation....thus the inherent version will try to limit "he" instead of directly putting constraints on T......

1)Extract the zip file,move its contents to $FOAM_SRC/fvOptions/corrections/customLimitTemp
2)Dont forget to update fvoptions/Make/file to

Code:
/* Corrections */

corrections/limitTemperature/limitTemperature.C
corrections/limitVelocity/limitVelocity.C
corrections/customLimitTemp/customLimitTemp.C


LIB = $(FOAM_USER_LIBBIN)/libfvOptions
3) wclean libso followed by wmake libso...........and u r good to go
Attached Files
File Type: zip customLimitTemp.zip (3.3 KB, 22 views)
Mars409 likes this.
SHUBHAM9595 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
fvOptions limitTemperature crashing in compressibleInterFoam JM27 OpenFOAM Running, Solving & CFD 38 November 29, 2023 03:55
fvOptions: temperatureLimitsConstraint or limitTemperature not working on V3.0+ derekm OpenFOAM Running, Solving & CFD 6 February 1, 2021 01:16
No limitScalar in fvOptions? Only limitTemperature superkelle OpenFOAM Programming & Development 2 May 31, 2020 19:38
twoPhaseEulerFoam + fvOptions limitTemperature hanness OpenFOAM Running, Solving & CFD 5 July 19, 2018 08:53


All times are GMT -4. The time now is 21:16.