|
[Sponsors] |
December 22, 2016, 01:59 |
Time alternating Convection and Heat flux BC
|
#1 |
New Member
Simon
Join Date: Dec 2016
Posts: 14
Rep Power: 10 |
Hi everyone,
I wish to apply an edge with where the boundary condition changes from constant heat flux to convection with respect to time (cyclical). Meaning, Heat flux addition for 10 secs, Convection for the another 10 seconds. The cycle repeats. I have no idea how this UDF can be written, as usually thermal condition (heat flux, constant temp, convection) is selected before applying the UDF. Please advice, and thank you very much for reading. Cheers, Simon |
|
December 22, 2016, 04:45 |
|
#2 |
Senior Member
Kevin
Join Date: Dec 2016
Posts: 138
Rep Power: 10 |
I've never done anything like that myself, and I'm doubtful it can be done through a UDF. However, you should be able to achieve that with a journal file. It could be a bit cumbersome, but it's doable. I don't have any examples though.
|
|
December 22, 2016, 05:06 |
|
#3 | |
New Member
Simon
Join Date: Dec 2016
Posts: 14
Rep Power: 10 |
Quote:
Thanks again for helping me! I really appreciate it. Journal files are like macros, yes? To record all the actions executed by the user, to be "replayed" with a click of a button? However it does not automate the cyclical effect yes? Cheers, Simon |
||
December 22, 2016, 06:13 |
|
#4 |
Senior Member
Kevin
Join Date: Dec 2016
Posts: 138
Rep Power: 10 |
Journal files are quite a bit different from the macros you use in UDF. You use journal files if you intend on running Fluent through a script or something similar, not through the GUI. Basically, you set up your whole problem in the journal file and then run it. It's like you do it through the GUI but then instead of clicking and entering your settings, you type them in the journal file using the corresponding TUI command. So instead of you manually, through the GUI, performing a simulation with heat flux bc, stop it, change it to convection, stop it, change it again, etc., you can enter this in a journal file that performs it "automatically".
It's still a bit cumbersome though, but I wouldn't know of another way to do it. Perhaps someone else does? |
|
December 22, 2016, 23:54 |
|
#5 |
New Member
Simon
Join Date: Dec 2016
Posts: 14
Rep Power: 10 |
Alright, thanks again ^^
|
|
December 24, 2016, 02:14 |
|
#6 |
Member
Shashank
Join Date: Apr 2011
Posts: 74
Rep Power: 15 |
Think it can be done using UDF but you'll have to be tricky about it. You can use DEFINE_PROFILE but since you'll be imposing this as a temperature condition, you can only specify the value of temperature on the boundary faces, not the flux (or gradient). Here's how I would tackle the two cases:
1. For the heat flux case, I would perform the interpolation myself and assign a temperature on the wall based on the gradient (which you already know because you know the flux) and the temperature of the cells next to the wall. Depends on how you want to specify your gradient (first order: one cell, second order: two cells). 2. For the convection case, you would write the following equation: k_f * dT/dn = h * (T_w - T_f), where dT/dn is again represented through temperatures of the wall and cells next to the wall. Hope this helps. |
|
Tags |
convection, heat flux, time, udf |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Heat flux with convection and radiation loss | kcgmech | Fluent UDF and Scheme Programming | 0 | February 11, 2016 05:08 |
UDF for time dependent stepwise heat flux profile | bugrasss | Fluent UDF and Scheme Programming | 0 | April 15, 2015 07:32 |
convection + known heat flux BC in the same wall | zfaraday | OpenFOAM | 0 | November 19, 2013 17:01 |
Error finding variable "THERMX" | sunilpatil | CFX | 8 | April 26, 2013 08:00 |
Natural convection with heat flux | Anton | FLUENT | 5 | April 2, 2007 05:03 |