|
[Sponsors] |
cell wall distance using C_WALL_DIST(c,t) or other udf |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
March 20, 2016, 01:39 |
cell wall distance using C_WALL_DIST(c,t) or other udf
|
#1 | |
Member
志新高(Zhixin Gao)
Join Date: Aug 2014
Location: hz.China
Posts: 30
Rep Power: 12 |
Hi all,
I've been calculating the cell wall distance of the first layer. I used the C_WALL_DIST(c,t) macro, but the result seems to be untrue, so I used the following udf and got two different result. Quote:
Best, Gao Last edited by zhixin; March 20, 2016 at 05:10. |
||
March 20, 2016, 05:10 |
|
#2 |
Member
志新高(Zhixin Gao)
Join Date: Aug 2014
Location: hz.China
Posts: 30
Rep Power: 12 |
I have another question:
I use ICEM to draw the hexahedral structure mesh and set the height of first layer as 0.002mm. So can I say the distance between the first layer and boundary is 0.001mm? |
|
April 15, 2016, 17:01 |
|
#3 |
New Member
Pratik Dhoot
Join Date: Mar 2016
Location: Boston, MA
Posts: 20
Rep Power: 10 |
Hi,
I used the same macro, but my solution fails to initialize. How did you run the solution? did the macro C_WALL_DIST work without initialization? Thanks, Pratik |
|
April 16, 2016, 05:09 |
|
#4 |
Member
志新高(Zhixin Gao)
Join Date: Aug 2014
Location: hz.China
Posts: 30
Rep Power: 12 |
Hi Pratik,
When I used the C_WALL_DIST(c,t) macro, I based on this, http://www.cfd-online.com/Forums/flu...-centroid.html and yes I initialize before calculation, I think it's needed. Can you post your error? Maybe me or others can find out the reason. Best. |
|
April 18, 2016, 10:06 |
|
#5 | |
New Member
Pratik Dhoot
Join Date: Mar 2016
Location: Boston, MA
Posts: 20
Rep Power: 10 |
Quote:
|
||
April 18, 2016, 10:17 |
|
#6 |
Member
志新高(Zhixin Gao)
Join Date: Aug 2014
Location: hz.China
Posts: 30
Rep Power: 12 |
Have you defined the "user defined-memory?" if you used the memory to store message.
|
|
April 18, 2016, 10:29 |
|
#7 |
New Member
Pratik Dhoot
Join Date: Mar 2016
Location: Boston, MA
Posts: 20
Rep Power: 10 |
||
April 18, 2016, 10:38 |
|
#8 |
Member
志新高(Zhixin Gao)
Join Date: Aug 2014
Location: hz.China
Posts: 30
Rep Power: 12 |
I don't know why this error happened, y=C_WALL_DIST(c,t) seems right, so would you mind post the key part about this macro.
|
|
April 18, 2016, 10:41 |
|
#9 | |
New Member
Pratik Dhoot
Join Date: Mar 2016
Location: Boston, MA
Posts: 20
Rep Power: 10 |
Quote:
DEFINE_PROFILE(wall_d_bc,t,i) { Thread *t0; face_t f; cell_t c, c0; double F_x,area,A[ND_ND],yplus,wshear; begin_f_loop(f,t) { c0 = F_C0(f,t); t0 = THREAD_T0(t); yplus = C_STORAGE_R(f,t,SV_WALL_YPLUS_UTAU); /* Y+*/ F_x = F_STORAGE_R_N3V(f,t,SV_WALL_SHEAR)[0]; F_AREA(A, f, t); area = NV_MAG(A); wshear=-1*F_x/area; /* wshear = C_MU_L(c0,t0)*C_U(c0,t0)/C_WALL_DIST(c0,t0); wall shear stress */ F_PROFILE(f,t,i) = 6.*wshear/(0.075*C_MU_L(c0,t0)*SQR(yplus)); } end_f_loop(f,t) } Look at this function for velocity profile. Save it as .c and interpret it in FLUENT. Tell me if you can initialize. If you can directly reply in email, my id is dhoot.p@husky.neu.edu |
||
April 18, 2016, 10:47 |
|
#10 |
Member
志新高(Zhixin Gao)
Join Date: Aug 2014
Location: hz.China
Posts: 30
Rep Power: 12 |
I can initialize it.
|
|
April 18, 2016, 10:50 |
|
#11 |
New Member
Pratik Dhoot
Join Date: Mar 2016
Location: Boston, MA
Posts: 20
Rep Power: 10 |
||
April 18, 2016, 11:17 |
|
#12 |
Member
志新高(Zhixin Gao)
Join Date: Aug 2014
Location: hz.China
Posts: 30
Rep Power: 12 |
Sorry I also can't initialize. I don't know why.
I suggest you ask others in new thread. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to use a UDF to set the volume fraction in the cells next to a wall? | DF15 | Fluent UDF and Scheme Programming | 33 | August 20, 2020 14:36 |
udf wall distance segmentation violation | gento | FLUENT | 1 | April 15, 2016 16:59 |
Wrong flow in ratating domain problem | Sanyo | CFX | 17 | August 15, 2015 07:20 |
Locate a cell with a specific wall Distance value | be_inspired | OpenFOAM Programming & Development | 2 | May 29, 2013 06:43 |
film thickness using cell wall distance | RAHULME | FLUENT | 0 | June 27, 2011 08:25 |