|
[Sponsors] |
UDF to fix the pressure in domain - not working |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
August 17, 2015, 00:58 |
UDF to fix the pressure in domain - not working
|
#1 |
Senior Member
|
Hi Every One
I am trying to fix the pressure in domain using DEFINE_EXECUTE_AT_END macro for the journal bearing simulation. Although I am able to solve it using the cavitation model along with mixture model, but there are some variables for which I don't have info, for example vaporization pressure...therefore I am preferring the first method... Here is the UDF I am using (got it from this forum in some thread), but it is not fixing static pressure in domain as intended i.e. I want to make the static pressure at end of each iteration to zero... Here are the results i am getting after each iteration (some random iteration) |
|
July 24, 2017, 10:34 |
|
#3 |
New Member
Duyikang
Join Date: Jun 2015
Location: Wuhan,China
Posts: 4
Rep Power: 11 |
hello,I am glad to know you success.Now, i am encountering the same difficult.Can you tell me how to change the negative pressure into zero?Thanks a lot!
DEFINE_ADJUST(adjust_pressure,domain) { Thread *t; cell_t c; thread_loop_c(t,domain) { begin_c_loop(c,t) { if(C_P(c, t) < 0) { C_P(c, t) = 0; } } end_c_loop(c,t) } } |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Domain Reference Pressure and mass flow inlet boundary | AdidaKK | CFX | 75 | August 20, 2018 06:37 |
pulsatile blood flow - developing larger pressure in the fluid domain | KushalJ | CFX | 4 | April 29, 2015 01:14 |
UDF to set velocity and pressure in inlet | GerardX89 | Fluent UDF and Scheme Programming | 0 | July 16, 2012 11:15 |
how to get pressure and pressure gradient using UDF | Honglin | Fluent UDF and Scheme Programming | 0 | May 24, 2012 07:47 |
Gas pressure question | Dan Moskal | Main CFD Forum | 0 | October 24, 2002 23:02 |