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

DEFINE_DPM_OUTPUT

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

Reply
 
LinkBack Thread Tools Display Modes
Old   March 22, 2007, 01:01
Default DEFINE_DPM_OUTPUT
  #1
wzslj
Guest
 
Posts: n/a
Hi,I want to use the DEFINE_DPM_OUTPUT to get the droplet information(spray dry) form the sample plane that i constructed according to the command:Surface/plane.The DEFINE_DFINE_OUTPUT is shown below :

#include "udf.h" #include "dpm.h" DEFINE_DPM_OUTPUT(injetion_output, header, fp, p, thread, plane) { char name[100];

if (header)

{

if (NNULLP(thread))

printf(fp,"(%s %d)\n",thread->head->dpm_summary.sort_file_name,11);

else

printf(fp,"(%s %d)\n",plane->sort_file_name,11);

printf(fp,"(%10s %10s %10s %10s %10s %10s %10s"

" %10s %10s %10s %10s %s)\n",

"X","Y","Z","U","V","W","diameter","T","mass-flow",

"time","melt-index","name");

}

else

{

sprintf(name,"%s:%d",p->injection->name,p->part_id);

printf(fp,

"((%10.6g %10.6g %10.6g %10.6g %10.6g %10.6g "

"%10.6g %10.6g %10.6g %10.6g %10.6g) %s)\n",

p->state.pos[0], p->state.pos[1], p->state.pos[2],

p->state.V[0], p->state.V[1], p->state.V[2],

p->state.diam, p->state.temp, p->flow_rate, p->state.time,

p->user[0], name);

} }

I compiled the programme after the spray dry calculation is completed.The compiling process is success,but when i carry the order:Report/Discrete phase/sample, the data is unable to appendix the to file. Also the pointers to the particle *p and to the thread *t are all NULL

Who can tell me why?

Thank you very much!

Lily
  Reply With Quote

Old   March 22, 2007, 13:05
Default Re: DEFINE_DPM_OUTPUT
  #2
Allan Walsh
Guest
 
Posts: n/a
Not sure exactly what you are doing, but you may have to use the RP_CELL and RP_THREAD macros to get Cell and Thread from the Particle Structure. See the UDF examples in the manual.
  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



All times are GMT -4. The time now is 16:45.