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

Create field for Celsius Temperatures

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 24, 2017, 02:59
Default Create field for Celsius Temperatures
  #1
Senior Member
 
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20
bastil is on a distinguished road
Hello all,

I want to export temperatures out of OpenFOAM 5.x in Celsius-Format. Therefore, I need a way to create Celsius-fields out of Kelvin-fields.

In general, something like the following should to the trick:

Code:
postProcess -fields "(T 273.15)" -func subtract
However, this functions requires two fields and does not accept the scalar "273.15". Any other ideas? Thanks.
bastil is offline   Reply With Quote

Old   August 24, 2017, 03:43
Default
  #2
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 29
akidess will become famous soon enough
Well, as a workaround you could just add a volScalarField Toffset with zeroGradient boundary conditions and an initial value of 273K in the time directories you want to export and then proceed with postProcess. In the past I would use my foamCalcEx tool, but I'm not sure if it still works with OF5.
__________________
*On twitter @akidTwit
*Spend as much time formulating your questions as you expect people to spend on their answer.
akidess is offline   Reply With Quote

Old   August 24, 2017, 08:12
Default
  #3
Senior Member
 
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20
bastil is on a distinguished road
Thanks. this leads me to foamCalc. I did not know this before:

http://caefn.com/openfoam/utilities-foamcalc

Code:
foamCalc addSubtract T subtract -value 273.15 -resultName Tdeg
bastil 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
[mesh manipulation] Importing Multiple Meshes thomasnwalshiii OpenFOAM Meshing & Mesh Conversion 18 December 19, 2015 18:57
Steady simulation does not iterate in Time=1 agustinvo OpenFOAM Running, Solving & CFD 3 November 19, 2015 04:57
Field Function to create a Random Vector darsonli STAR-CCM+ 1 August 21, 2014 10:16
Is good initial guess field is neccessary ? mmkr825 OpenFOAM 5 October 17, 2012 12:58
How to create points and field files? sega OpenFOAM Post-Processing 19 July 22, 2009 03:16


All times are GMT -4. The time now is 15:52.