How to identify the cells near the interface?
Dear All
Here is my question. There are two regions A and B with an interior interface I in my model. Now I want to identify the neighboring cells near the interface, so that I can add an source term into these cells. How can I identify these cells? Thank u very much! Xiaoguang |
Quote:
Use Lookup_Thread(id) to get the face. Use F_C0, F_C1 to get the neighbour cells |
I'm facing a pursuing problem:
I want to access the value of a UDM C_UDMI(c,t,1) in an adjacent cell across an interface. I use the following code snippet in my UDF: Code:
tm = THREAD_SUPER_THREAD(thread); Code:
n = C_NFACES(cell,thread); I also should mention that I'm using the mixture model (the UDF refers to the secondary phase, see THREAD_SUPER_THREAD) and that C_UDMI(c,t,0), C_UDMI(c,t,1) and a[9] are initialized with the value 1.0 in the first time step. Where does this contradiction come from and how can I manage to access the right value across the interface? I'm thanking you in anticipation. |
All times are GMT -4. The time now is 09:56. |