UDF in Cell Zone (Adjacent Cells)
Hello,
I am hooking a UDF onto a phase cell zone condition to fix the velocities in each cell which will depend on the adjacent cells' density. I am using DEFINE_PROFILE(name,thread,i) for this purpose. My workflow to achieve this in the UDF is:
I drafted my UDF with guidance from the manual. My problem is that when I try to initialize my case in Fluent, I get a an error "Received signal SIGSEGV". I have checked that the c_loop works using that Message, but when I enable the c_face_loop, initializing the case gives me the error. Interestingly, when I initialize the c_loop with check1, the error happens as well but initializing with check2 has no problem (the difference being that check2 is initialized during declaration.** real check1, check2 =0; begin_c_loop(c,thread) { * * *Message ("OK"); * * *// check1 =1; * * *// check2 = 1; * * *c_face_loop(c,thread,n) * * *{ ....... } } May I know if the workflow for getting adjacent cell properties above is correct, and also what am I doing wrong in there? Thank you. |
i think you don't need second loop (c_face_loop(c,thread,n))
use C_FACE and C_FACE_THREAD as a second step and continue with workflow |
I've tried removing the c_face_loop, still does not work and gives me the "Received signal SIGSEGV" error when initializing.
|
show your code
|
All times are GMT -4. The time now is 04:27. |