|
[Sponsors] |
Access inlet mass flow value (target mass flow rate) |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
March 31, 2018, 15:30 |
Access inlet mass flow value (target mass flow rate)
|
#1 |
New Member
Join Date: Mar 2018
Location: Brazil
Posts: 7
Rep Power: 8 |
Hello everyone,
I need to specify the mass flow rate percentage through multiple outlets, just as in outflow boundary condition, but using pressure-outlet boundary condition instead, and target mass flow rate option. The inlet mass flow varies with time. How can I retrieve this value ? I've created the UDFs, but the results are weird. I think I am not retrieving the correct inlet mass flow. --------------------------------------------------------------------------- Here is the code I've created: DEFINE_PROFILE(target_massflow_left1,outlet_thread ,massflow) { face_t f; face_t inlet; Domain *domain; real percentage = 0.24; int inlet_zone_id = 61; real inlet_massflow; domain = Get_Domain(1); //fluid domain Thread *inlet_thread = Lookup_Thread(domain,inlet_zone_id); //thread containing inlet begin_f_loop(inlet,inlet_thread) { if(BOUNDARY_FACE_THREAD_P(inlet_thread)) //found inlet { inlet_massflow = -F_FLUX(inlet,inlet_thread); } } end_f_loop(inlet, inlet_thread); //loop over every face on the thread begin_f_loop(f,outlet_thread) { F_PROFILE(f,outlet_thread,massflow) = percentage * inlet_massflow ; } end_f_loop(f, outlet_thread); } ---------------------------------------------------------------------------------- Thanks in advance, YCarv |
|
April 1, 2018, 07:27 |
|
#2 |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
To get the total inflow, you need to sum the inflow overall faces in the inlet.
Code:
real inlet_massflow=0; [...] inlet_massflow -= F_FLUX(inlet,inlet_thread); |
|
April 1, 2018, 09:09 |
|
#3 |
New Member
Join Date: Mar 2018
Location: Brazil
Posts: 7
Rep Power: 8 |
oh, of course !
Thank you very much pakk, I will try this now ! |
|
Tags |
target-mass-flow-rate |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
mass flow inlet and pressure outlet with target mass flow rate | Zigainer | FLUENT | 13 | October 26, 2018 06:58 |
Target Mass Flow Rate | Nitin | FLUENT | 9 | June 17, 2017 11:30 |
DPM total mass flow rate | yow | FLUENT | 0 | July 17, 2015 13:01 |
OpenFOAM14 for Mac OSX Darwin 104 | gschaider | OpenFOAM Installation | 118 | July 20, 2008 06:19 |
Mass Flow Inlet | Pravir Kumar Rai | FLUENT | 0 | February 17, 2003 20:23 |