|
[Sponsors] |
July 20, 2011, 11:03 |
plot bulk mean temperature in cfd-post
|
#1 |
New Member
mamad
Join Date: Aug 2010
Posts: 15
Rep Power: 15 |
Hi
I want to calculate nusselt number for turbulent flow in a pipe with constant temperature in wall and i need to plot bulk mean temperature. how can i plot the change of bulk mean temperture along lenght of tube in cfd-post??? |
|
July 20, 2011, 20:35 |
|
#2 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,665
Rep Power: 143 |
The easiest way I can think of is to use a session file to generate lots of cross section planes and calculate the average temperature on each plane, then assemble the average temperatures into a graph or data file. I suspect this needs to be scripted.
|
|
July 21, 2011, 05:49 |
|
#3 |
New Member
mamad
Join Date: Aug 2010
Posts: 15
Rep Power: 15 |
thanks a lot...
but how can i use this method??? |
|
July 21, 2011, 08:56 |
|
#4 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,665
Rep Power: 143 |
Record a session file in CFD-Post and edit it. Do the CFD-Post tutorials on session files.
|
|
July 21, 2011, 09:03 |
|
#5 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,665
Rep Power: 143 |
Record a session file in CFD-Post and edit it. Do the CFD-Post tutorials on session files.
|
|
July 21, 2011, 21:21 |
|
#6 |
Member
Ali Torbaty
Join Date: Jul 2009
Location: Sydney, Australia
Posts: 72
Rep Power: 16 |
#you can use below eample to create an array of planes in your preffered offsets
# you have to change the $PlotVariable and $CalcFunction according to your model, this example is made to calculate average velocity for a multiphase model # this example shall be run on CFX-POST Command Editor !CreateSectionPlanes(); ! sub CreateSectionPlanes{ # Data ! $PlanePreName = "Plane YZ "; ! $PlotVariable = "Water.Superficial Velocity"; ! $CalcFunction = "areaAve($PlotVariable)"; # Set the Min and Max plot variables for new planes ! $MinVal = 0; ! $MaxVal = 2.25; # First plane coordinates ! $startX = -27; ! $startY = 0; ! $startZ = 13; # new plane offsets ! $dX = 2; ! $dY = 0; ! $dZ = 0; # Total num,ber of planes to be created ! $TotalPlanesNo = 14; # Create a CSV file in C:\ to export the results ! open(SwRes,">C:/Results.csv") || die "Can't open file $!\n"; ! print SwRes "Plane , X , Y , Z , ",$CalcFunction ,"\n"; ! for ($j=0; $j<$TotalPlanesNo ;$j++) { ! $PlaneName = $PlanePreName . ($j+1); ! $NewX = $startX + $dX * $j; ! $NewY = $startY + $dY * $j; ! $NewZ = $startZ + $dZ * $j; ! $CalcString = $CalcFunction . "@" . $PlaneName; PLANE: $PlaneName Apply Instancing Transform = On Apply Texture = Off Blend Texture = On Bound Radius = 0.5 [m] Colour = 0.75, 0.75, 0.75 Colour Map = Default Colour Map Colour Mode = Variable Colour Scale = Linear Colour Variable = $PlotVariable Colour Variable Boundary Values = Hybrid Culling Mode = No Culling Direction 1 Bound = 1.0 [m] Direction 1 Orientation = 0 [degree] Direction 1 Points = 10 Direction 2 Bound = 1.0 [m] Direction 2 Points = 10 Domain List = /DOMAIN GROUP:All Domains Draw Faces = On Draw Lines = Off Instancing Transform = /DEFAULT INSTANCE TRANSFORMefault Transform Invert Plane Bound = Off Lighting = Off Line Colour = 0, 0, 0 Line Colour Mode = Default Line Width = 1 Max = $MaxVal Min = $MinVal Normal = 1 , 0 , 0 Option = YZ Plane Plane Bound = None Plane Type = Slice Point = 0 [m], 0 [m], 0 [m] Point 1 = 0 [m], 0 [m], 0 [m] Point 2 = 1 [m], 0 [m], 0 [m] Point 3 = 0 [m], 1 [m], 0 [m] Range = User Specified Render Edge Angle = 0 [degree] Specular Lighting = On Surface Drawing = Smooth Shading Texture Angle = 0 Texture Direction = 0 , 1 , 0 Texture File = Texture Material = Metal Texture Position = 0 , 0 Texture Scale = 1 Texture Type = Predefined Tile Texture = Off Transform Texture = Off Transparency = 0.0 Visibility = On X = $NewX Y = $NewY Z = $NewZ OBJECT VIEW TRANSFORM: Apply Reflection = Off Apply Rotation = Off Apply Scale = Off Apply Translation = Off Principal Axis = Z Reflection Plane Option = XY Plane Rotation Angle = 0.0 [degree] Rotation Axis From = 0 [m], 0 [m], 0 [m] Rotation Axis To = 0 [m], 0 [m], 0 [m] Rotation Axis Type = Principal Axis Scale Vector = 1 , 1 , 1 Translation Vector = 0 [m], 0 [m], 0 [m] X = 0.0 [m] Y = 0.0 [m] Z = 0.0 [m] END END ! $CalcVal = getExprVal($CalcString); ! print SwRes $PlaneName," , ",$NewX," , ",$NewY," , ",$NewZ," , ", $CalcVal,"\n"; ! }; ! close SwRes; !}; Last edited by AliTr; July 21, 2011 at 22:07. |
|
July 22, 2011, 06:57 |
|
#7 |
New Member
mamad
Join Date: Aug 2010
Posts: 15
Rep Power: 15 |
tahnks a lot AliTr but can you explain more about geometry of your problem for better understanding or give me a tutorial that explain the use of command editor???
|
|
July 23, 2011, 03:28 |
|
#8 |
Member
Ali Torbaty
Join Date: Jul 2009
Location: Sydney, Australia
Posts: 72
Rep Power: 16 |
check the CFX-POST help, it has all you need.
to use the code, you need to define the start coordinate in mentioned section (# First plane coordinates ) and also provide dx,dy,dz for new planes. |
|
July 23, 2011, 05:36 |
|
#9 |
New Member
mamad
Join Date: Aug 2010
Posts: 15
Rep Power: 15 |
thanks AliTr
i need to define new variable as "Temperature*Velocity" and use areaAve(Temperature*Velocity)@plane to determine bulk temperature but when i run this,have some error as "Temperature*Velocity does not exist"... do you know reason of error? |
|
July 24, 2011, 05:31 |
|
#10 |
Member
Ali Torbaty
Join Date: Jul 2009
Location: Sydney, Australia
Posts: 72
Rep Power: 16 |
you need to define a new variable in CFX-Post and use it instead of "Temperature*Velocity". PLEASE READ CFX help, these are basics. however below expression will create a new variable as "TmprVelocity"
LIBRARY: CEL: EXPRESSIONS: TmprVel = Temperature * VelocityEND END END USER SCALAR VARIABLE: TmprVelocity Boundary Values = ConservativeEND |
|
July 24, 2011, 06:41 |
|
#11 |
New Member
mamad
Join Date: Aug 2010
Posts: 15
Rep Power: 15 |
thanks a lot...
|
|
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Creating Face in CFD Post and export Values as Boundary Conditions | flow87 | CFX | 2 | June 4, 2011 05:06 |
Plotting recirculation zone in CFD Post | ashtonJ | CFX | 0 | April 30, 2011 21:31 |
CFD post processing techniques & streamlining | klk | Main CFD Forum | 0 | October 19, 2010 08:37 |
how to find bulk temperature plot and results in fluent | cadcamvijay | Main CFD Forum | 2 | March 21, 2009 01:36 |
Plot temperature vs time for a defined point | FREDERIK | FLUENT | 0 | August 26, 2005 06:49 |