# P_VEL(p)[i] Actual meaning?

 Register Blogs Members List Search Today's Posts Mark Forums Read

 April 7, 2015, 04:32 P_VEL(p)[i] Actual meaning? #1 Senior Member   Join Date: Mar 2014 Posts: 375 Rep Power: 9 Wondering what this actually means P_VEL(p)[i], I was thinking it is an array of values of each of the velocity components (Tangential Radial Axial)?And are these the same as the (x y z) components? I think not not but just hoping for a nice explanation. Anyhow, if it is one of the component systems from above, I found in the Fluent UDF manual for calculating the normal velocity the normal component is given in an array of 3 values as well. Shouldn't it be just a single value? Or am i misunderstanding this part of the code from the UDF manual: for(i=0; i

 April 7, 2015, 05:12 #2 Senior Member   Join Date: Mar 2015 Posts: 892 Rep Power: 14 P_VEL(p)[i] is a macro returning velocities for a particle. P_VEL(p)[0] corresponds to the velocity in the x-direction, and so forth in Cartesian coordinates. A vector, such as a (unit) normal vector, has several components as well so it makes sense to operate in each direction at a time (component-wise).

 April 7, 2015, 05:36 #3 Senior Member   Join Date: Mar 2014 Posts: 375 Rep Power: 9 How would you relate the velocities in the different Cartesian coordinates to the normal or tangential components? I thought that the components of P_VEL(p)[i] are the tangential, radial, axial components and each is equivalent to a direction (x,y,z). Are you saying that the X velocity has further 3 components as well, that makes i a 3x3 matrix? Also in the above equation vn is the normal velocity, then why is it not written with its components like the other terms in the equation 'vn [i]'. Thanks

 April 7, 2015, 05:54 #4 Senior Member   Join Date: Mar 2015 Posts: 892 Rep Power: 14 Normal or tangential to what? Are you using Cartesian, cylindrical or other coordinates? No. The particle has a motion in space and this velocity vector is the first time derivative of the displacement vector. In 3-D Cartesian coordinates: u=dx/dt, v=dy/dt and w=dz/dt. Or as vectors, u=dx/dt. For the particles in Fluent's DPM: u=P_VEL(p)[0], v=P_VEL(p)[1] and w=P_VEL(p)[2]. 'vn' is the magnitude of the normal velocity (perpendicular to the boundary face) and the normal unit vector is the variable 'normal' according to this post I assume you're referring to. Have a read of this Wikipedia article on the dot product operation.

 April 7, 2015, 08:43 #5 Senior Member   Join Date: Mar 2014 Posts: 375 Rep Power: 9 Thanks for that, I will go through it. Actually I dont even know what coordinates am i using, does it depend on the geometry? I suppose they are just cartesian, how do I tell?

 April 7, 2015, 09:04 #6 Senior Member   Join Date: Mar 2015 Posts: 892 Rep Power: 14 You'll more than likely be using Cartesian coordinates, and that's fine (I'm not familiar with using other coordinate systems in Fluent and whether it's possible or practical to do so).