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

UDF for heat source

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 16, 2011, 06:54
Default UDF for heat source
  #1
Member
 
prince
Join Date: Jun 2011
Posts: 56
Rep Power: 14
prince_pahariaa is on a distinguished road
Hello friends

I got stuck in one problem and will appreciate any help

In my problem there is a heat source of 15KW which will distribute uniformaly in some part of window (over area of 10 cm2 in window zone). I have written simple UDF code to identify the area over which heat has to distributed.

#include "udf.h"
#define CX 0.0
#define CY 0.0
#define CZ 0.0

DEFINE_SOURCE(heat, cell, thread, ds, eqn)
{
real source;
real x[ND_ND];
real r,y, a, b,qr;


C_CENTROID(x, cell, thread);

a = (x[0]-CX)*(x[0]-CX);
b = (x[2]-CZ)*(x[2]-CZ);
r = (sqrt(a + b));
y = x[1];


if(y>1.068798307 && y<=1.070483879)
{
if(r<=0.06)
source=8.39e09;

if(r>0.06)
source=0.0;
}





ds[eqn]=0.0;

return source;
}

My problem is, i am not getting right area over which heat has to distribute.

Thankss
Attached Images
File Type: jpg window.jpg (87.7 KB, 7 views)
File Type: jpg geometry.jpg (86.2 KB, 7 views)
File Type: jpg geometry solid.jpg (82.9 KB, 7 views)
prince_pahariaa is offline   Reply With Quote

Reply


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
UDF for energy source João Fernandes FLUENT 4 October 17, 2008 04:53
UDF - source terms Fred FLUENT 2 October 11, 2005 20:53
help on UDF mass source shao1 FLUENT 2 July 11, 2002 20:36
UDFs for Scalar Eqn - Fluid/Solid HT Greg Perkins FLUENT 0 October 13, 2000 23:03
UDFs for Scalar Eqn - Fluid/Solid HT Greg Perkins FLUENT 0 October 11, 2000 03:43


All times are GMT -4. The time now is 21:24.