- **Main CFD Forum**
(*https://www.cfd-online.com/Forums/main/*)

- - **Help Me, what's the Cell Above any given cell in 3D.**
(*https://www.cfd-online.com/Forums/main/92336-help-me-whats-cell-above-any-given-cell-3d.html*)

Help Me, what's the Cell Above any given cell in 3D.Hi evryone!
iam writing an UDF and iam bloked in. i Have a small problem ( isn't small for me)!! i have a Cell in 3D domaine (any given Cell)!! i wana to get the cell just above it! i know in 3D domaine there is about 20 cells around my Cell (the cell is chosen just like that in 3d domaine), so what is the instruction that can give me the Cell just abouve my cell. i have found some instruction to give the faces of any given Cell! but i wana to Get the cell Above mine in the Z direction!! any Help is very apreciated |

i still waiting!i am waiting for any instruction, and in the same time iam looking by my self to resolve my problm, so if i find the answer i will put it here!!!!
A+ |

Short answer:
The z-direction cell stacks are consecutively indexed in the k index cell center coordinates are as follows for cell (i,j,k) and cell(i,j,k+1): so cell (i,j,k) -> x(i), y(j), z(k) and cell (i,j,k+1) -> x(i), y(j), z(k+1) is just 'above' it in the z direction. cell centered variables p(i,j,k) -> p(i,j,k+1), rho(i,j,k) -> rho(i,j,k+1) p(xi,yj,zk) -> p(xi,yj,zk+dz), rho(xi,yj,zk) -> rho(xi,yj,zk+dz) At least, it was that way in the mid-90's when I used the code. The version number was much lower then! |

thxQuote:
well inside my UDF, i try to copy the velocity vector from the cell above my cell (can be any cell)! and as you know we can not find evry thg in manuals or the internet, specially thx related to CFD!!! so thx again, i will try the way you have interpret thniks and i hope that work! A+ |

All times are GMT -4. The time now is 05:32. |