CFD Online Logo CFD Online URL
Home > Forums > General Forums > Main CFD Forum

Fluent: Find Cell Volume at Current Position DPM UDF

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

LinkBack Thread Tools Search this Thread Display Modes
Old   May 1, 2020, 15:41
Post Fluent: Find Cell Volume at Current Particle Position DPM UDF
Alain Islas
Join Date: Nov 2019
Location: Mexico
Posts: 43
Rep Power: 4
alainislas is on a distinguished road

I am trying to extract the interpolated fluid velocities + cell volume at the current particle position. Anybody experienced in using UDF macros, could you help me to understand what I am doing wrong?

#include "udf.h"

DEFINE_DPM_SCALAR_UPDATE(interp_vel_and_volume,c,t ,init,p)

cphase_state_t *cp;
cp = p->cphase;
P_USER_REAL(p,0) = cp->V[0]; /* Interpolated x-velocity */
P_USER_REAL(p,1) = cp->V[1]; /* Interpolated y-velocity */
P_USER_REAL(p,2) = cp->V[2]; /* Interpolated z-velocity */

Last edited by alainislas; May 1, 2020 at 20:25.
alainislas is offline   Reply With Quote


dpm in fluent, udf compilation

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
[Other] refineWallLayer Error Yuby OpenFOAM Meshing & Mesh Conversion 2 November 11, 2021 12:04
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
negative cell volume detected while running ANSYS Fluent UDF khushbu.bhavsar92 FLUENT 0 March 27, 2016 23:45
Cell centroid and cell volume in general, and in Fluent zmester Main CFD Forum 3 October 17, 2009 12:05
On the damBreak4phaseFine cases paean OpenFOAM Running, Solving & CFD 0 November 14, 2008 22:14

All times are GMT -4. The time now is 01:03.