CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > FLUENT

How to create over one particles in udf

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

Reply
 
LinkBack Thread Tools Display Modes
Old   July 26, 2014, 22:43
Default How to create over one particles in udf
  #1
New Member
 
heiko
Join Date: Feb 2014
Posts: 4
Rep Power: 4
chaocaho_0627 is on a distinguished road
Thanks for coming.here is my code,but only could create one particle,how could i create at least two particles?

#include "udf.h"
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>

DEFINE_DPM_INJECTION_INIT(initial_particle,I)
{
Particle *p;Message("Initializing Injection: %s\n",I->name);
loop(p,I->p)
{
P_POS(p)[0]=0.0002;
P_POS(p)[1]=0.00002;
P_DIAM(p)=2.5e-5;
P_RHO(p)=8978;
P_MASS(p)=3.14*4/3*(P_DIAM(p)/2)*(P_DIAM(p)/2)*(P_DIAM(p)/2);
}

}
chaocaho_0627 is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
UDF for deleting particles in DPM imanmirzaii Fluent UDF and Scheme Programming 5 January 29, 2013 08:02
Can I change the diameter and density of Particles depend on the pressure using UDF Yanlong Li Fluent UDF and Scheme Programming 2 January 13, 2013 11:46
Looping inside UDF and use of C_UDMs in DEFINE_DPM_BC shankara.2 Fluent UDF and Scheme Programming 0 November 10, 2009 18:11
fluent add additional zones for the mesh file SSL FLUENT 2 January 26, 2008 12:55
how to create a linearly varying tempraturein UDF arwang FLUENT 4 April 22, 2005 18:23


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