CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

How to get average flow quantities from oscillating steady solver results in FLUENT

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 1, 2018, 12:55
Default How to get average flow quantities from oscillating steady solver results in FLUENT
  #1
New Member
 
Join Date: Apr 2018
Posts: 5
Rep Power: 8
superluminality is on a distinguished road
I simulate one case using pressure-based, steady solver. Pressure-velocity coupling scheme is SIMPLEC. After 1,000 iterations all the residuals becomes flat, with the continuity residual around 3e-1 (obviously not small enough to be satisfactory). Flow quantity (e.g. temperature) on one sampled point was also monitored. Temperature on this sampled point oscillates from 295 K to 312 K for every 20 iterations.
Now I want to calculate the average flow quantities (including velocity magnitude, temperature) over the whole fluid domain during those 20 iterations. Could anyone tell me how to do it in FLUENT?
PS: For transient solver in FLUENT, you can enable the option 'data sampling for time statistics' to average among time steps. But for steady solver in Fluent, is there similar way to average among iterations?
Pictures of scaled residual and temperature history on the sampled point are also attached for reference.
Attached Images
File Type: jpg Scaled Residual.JPG (67.0 KB, 61 views)
File Type: png Temperature history of one sampled point-1.png (44.7 KB, 56 views)
File Type: jpg Temperature history of one sampled point-2-zoom in.jpg (69.4 KB, 56 views)
superluminality is offline   Reply With Quote

Old   August 1, 2018, 13:16
Default
  #2
Senior Member
 
Lucky
Join Date: Apr 2011
Location: Orlando, FL USA
Posts: 5,761
Rep Power: 66
LuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura about
Fluent doesn't have this option built-in. Although I agree it would be a nice diagnostic tool to have. You should request it as a feature to Ansys support and maybe it'll show up in a future version.
LuckyTran is offline   Reply With Quote

Old   August 1, 2018, 13:25
Default
  #3
New Member
 
Join Date: Apr 2018
Posts: 5
Rep Power: 8
superluminality is on a distinguished road
Many thanks for your reply. Is it possible to use Macros in 'Execute Commands' under 'Calculation Activities', or even, hook up a UDF? I have tried these manners but still haven't got a clue... Many thanks if you could give a hint.
superluminality is offline   Reply With Quote

Old   August 1, 2018, 13:26
Default
  #4
New Member
 
Join Date: Apr 2018
Posts: 5
Rep Power: 8
superluminality is on a distinguished road
Quote:
Originally Posted by LuckyTran View Post
Fluent doesn't have this option built-in. Although I agree it would be a nice diagnostic tool to have. You should request it as a feature to Ansys support and maybe it'll show up in a future version.
Many thanks for your reply. Is it possible to use Macros in 'Execute Commands' under 'Calculation Activities', or even, hook up a UDF? I have tried these manners but still haven't got a clue... Many thanks if you could give a hint.
superluminality is offline   Reply With Quote

Old   August 1, 2018, 18:15
Default
  #5
Senior Member
 
Lucky
Join Date: Apr 2011
Location: Orlando, FL USA
Posts: 5,761
Rep Power: 66
LuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura aboutLuckyTran has a spectacular aura about
You are right it certainly is doable with a udf. Off the top of my head I don't know what the final form would be. You would only need to loop through the cell thread and keep an index of the iteration count. It sounds simple at least... You might want to google udf's for calculating the time-average and replacing the time-step with iterations.
LuckyTran is offline   Reply With Quote

Old   August 2, 2018, 05:12
Default
  #6
New Member
 
Join Date: Apr 2018
Posts: 5
Rep Power: 8
superluminality is on a distinguished road
Quote:
Originally Posted by LuckyTran View Post
You are right it certainly is doable with a udf. Off the top of my head I don't know what the final form would be. You would only need to loop through the cell thread and keep an index of the iteration count. It sounds simple at least... You might want to google udf's for calculating the time-average and replacing the time-step with iterations.
Many thanks! I have not used UDF before and would try as you've suggested. Is there any other resource (like UDF samples and tutorials) you suggested which could help me to tackle this problem ASAP?
superluminality is offline   Reply With Quote

Old   August 2, 2018, 07:58
Default
  #7
Senior Member
 
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34
AlexanderZ will become famous soon enoughAlexanderZ will become famous soon enough
ansys fluent customization manual
google
youtube
this forum as well

best regards
AlexanderZ is offline   Reply With Quote

Old   August 2, 2018, 13:39
Default
  #8
New Member
 
Join Date: Apr 2018
Posts: 5
Rep Power: 8
superluminality is on a distinguished road
Quote:
Originally Posted by LuckyTran View Post
You are right it certainly is doable with a udf. Off the top of my head I don't know what the final form would be. You would only need to loop through the cell thread and keep an index of the iteration count. It sounds simple at least... You might want to google udf's for calculating the time-average and replacing the time-step with iterations.
I have compiled a UDF to achieve this purpose after learning programming with it in Customization Manual. In the meantime, I have contacted ANSYS technical support and they created a feature request. Hopefully it will be done automatically in future versions. Many thanks for your kind reply!
superluminality is offline   Reply With Quote

Old   September 21, 2022, 19:08
Default averaging values over a few iterations
  #9
New Member
 
Mehrnoosh Ahmadi
Join Date: Sep 2022
Posts: 2
Rep Power: 0
Nush87 is on a distinguished road
Quote:
Originally Posted by superluminality View Post
I have compiled a UDF to achieve this purpose after learning programming with it in Customization Manual. In the meantime, I have contacted ANSYS technical support and they created a feature request. Hopefully it will be done automatically in future versions. Many thanks for your kind reply!
Hello. I am having a similar issue with velocity and pressure on some of my models. I am simulating cross ventilation flow in an isothermal building. Could you please be extremely kind and share your UDF? an architect with no coding knowledge will thank you forever here!

Last edited by Nush87; September 21, 2022 at 19:30. Reason: more details
Nush87 is offline   Reply With Quote

Reply

Tags
average field, fluent, iterations, steady solver


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
About Some Concepts:Laminar flow, turbulent flow, steady flow and time-dependent flow Jing Main CFD Forum 8 October 5, 2018 18:02
FLUENT: Oscillating Results for Cd and Cl values mrwts FLUENT 1 September 14, 2016 05:03
fluent divergence for no reason sufjanst FLUENT 2 March 23, 2016 17:08
using steady state results for unsteady flow siva appanna Main CFD Forum 3 February 20, 2006 06:29
fluid flow fundas ram Main CFD Forum 5 June 17, 2000 22:31


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