|
[Sponsors] |
Regarding error in new expression syntax in openfoam 1912 |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
July 15, 2020, 13:02 |
Regarding error in new expression syntax in openfoam 1912
|
#1 |
Member
ijaz fazil
Join Date: Apr 2013
Location: Singapore
Posts: 73
Rep Power: 13 |
Hi I need to model variable flow rate with time depending on the temperature on the particular patch.
If Temp<300.15 K then flow rate is 0.058; else Temp>300.15K then flow rate is (m*temp)+c I recently read that expressions can be modelled directly in openfoam 1912. Initially I tried to model flowrate I'm unable to do so. Hence I used SERVER_SOURCE { type exprFixedValue; value $internalField; valueExpr "(tSink<=300.15)?vector(0,value1/area1,0):vector(0,((0.00531*tSink)-0.08485)/area1,0)"; variables ( "tSink{SERVER_SINK} = weightAverage(T)" "value1{SERVER_SOURCE} = 0.05852" "area1{SERVER_SOURCE} = area()" ); } But Im getting the following warning while the simulation is running "--> FOAM Warning : From function bool Foam::expressions::exprResult::getUniformChecked(F oam::expressions::exprResult&, Foam::label, bool, bool) const [with Type = double; Foam::label = int] in file expressions/exprResult/exprResultI.H at line 143 Different min/max values: (0.000674827 0.00410428) Using the average 0.00146216 Can any one explain how to fix this error? |
|
July 15, 2020, 13:09 |
updated information
|
#2 |
Member
ijaz fazil
Join Date: Apr 2013
Location: Singapore
Posts: 73
Rep Power: 13 |
for information I changed the expression as below
{ type exprFixedValue; value $internalField; valueExpr "(tSink<=300.15)?vector(0,value2/area2,0):vector(0,((0.00531*tSink)-0.08485)/area2,0)"; variables ( "tSink{SERVER_SINK} = weightAverage(T)" "value2 = 0.05852" "area2 = 0.20025" ); } The simulation is running fine but still I'm not sure what is the cause of the warning. |
|
Tags |
openfoam1912, pyfoam, pyfoam tutorial error, swak4foam, swak4foam error |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Map of the OpenFOAM Forum - Understanding where to post your questions! | wyldckat | OpenFOAM | 10 | September 2, 2021 06:29 |
OpenFOAM Training Beijing 22-26 Aug 2016 | cfd.direct | OpenFOAM Announcements from Other Sources | 0 | May 3, 2016 05:57 |
OpenFOAM Training, London, Chicago, Munich, Sep-Oct 2015 | cfd.direct | OpenFOAM Announcements from Other Sources | 2 | August 31, 2015 14:36 |
Expression and Syntax for PDEs | JD | CFX | 2 | January 3, 2010 05:19 |
Lift, Drag Vs time chart,calculations | Jamesd69climber | CFX | 8 | February 17, 2005 18:23 |