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

udf problem about wall heat flux

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 23, 2007, 15:12
Default udf problem about wall heat flux
  #1
stepanie
Guest
 
Posts: n/a
Hi, I don't know how to define uniform heat flux of wall changing with time. Here is my code. But there is error when I start to iteration. If I should use DEFINE_HEAT_FLUX? Is there an simple example for this micro? Thanks!

#include "udf.h"

DEFINE_PROFILE(fluxflow, thread, position) { real tim;

face_t f; cell_t c; Thread *t;

begin_f_loop(f, thread) { tim=RP_Get_Real("flow-time");

F_PROFILE(f, thread, position)=10tim } end_f_loop(f, thread) }

  Reply With Quote

Old   February 23, 2007, 16:06
Default Re: udf problem about wall heat flux
  #2
shanti
Guest
 
Posts: n/a
I think there are syntax errors. There is no semicolon at the end of F_PROFILE statement.

F_PROFILE(f, thread, position) = 10* time;

try this..if its working or not..

shanti
  Reply With Quote

Old   February 23, 2007, 17:02
Default Re: udf problem about wall heat flux
  #3
stepanie
Guest
 
Posts: n/a
Hi shanti,

Thanks for your suggestion, I will try later when I finish my class now.

  Reply With Quote

Old   February 23, 2007, 18:45
Default Re: udf problem about wall heat flux
  #4
stepanie
Guest
 
Posts: n/a
Hi,

I have modified the F_PROFILE(f, thread, position)=10*time; Now it can pass interperted. But when I initialize and run, there is error message.

I want to give a heat flux changing with time into the sidewall of a solid cylinder. How to define it? Which macro should I use? Thanks.

chip-exec: fluxflow: argument 1: incorrect type (36): int expectedchip-exec: fluxflow: argument 2: incorrect type (5): pointer expectedchip-exec: fluxflow: argument 3: incorrect type (0): int expectedchip-exec: fluxflow: argument 4: incorrect type (0): pointer expectedchip-exec: fluxflow: argument 5: incorrect type (0): pointer expectedchip-exec: fluxflow: argument 6: incorrect type (0): pointer expected

  Reply With Quote

Old   February 23, 2007, 18:54
Default Re: udf problem about wall heat flux
  #5
shanti
Guest
 
Posts: n/a
Hi

do you want the flux value to be 10*time?

shanti
  Reply With Quote

Old   February 23, 2007, 18:57
Default Re: udf problem about wall heat flux
  #6
stepanie
Guest
 
Posts: n/a
Yes. I want the flux is the function of time, and the time is from 0~120 sec.

  Reply With Quote

Old   February 23, 2007, 18:59
Default Re: udf problem about wall heat flux
  #7
shanti
Guest
 
Posts: n/a
Can you give the exact relation between the heat flux and the time?
  Reply With Quote

Old   February 23, 2007, 19:06
Default Re: udf problem about wall heat flux
  #8
stepanie
Guest
 
Posts: n/a
flux=10*time;

That is when time=0, flux=0;

time=1, flux=10;

time=2, flux=20;

. .

. .

. .

time=120,flux=1200;

  Reply With Quote

Old   February 23, 2007, 19:09
Default Re: udf problem about wall heat flux
  #9
shanti
Guest
 
Posts: n/a
sorry, I have no clue about the error. I will lwt you know if i can figure it out..

shanti
  Reply With Quote

Old   February 23, 2007, 19:13
Default Re: udf problem about wall heat flux
  #10
stepanie
Guest
 
Posts: n/a
Thanks. I think should use DEFINE_HEAT_FLUX to give the condition of wall flux. But I don't konw how to use DEFINE_HEAT_FLUX....
  Reply With Quote

Old   February 26, 2007, 04:25
Default Re: udf problem about wall heat flux
  #11
prasanth
Guest
 
Posts: n/a
hi stepaine,

why cant you go to the require reference in the fluent documentation using index option.

regarding your query for DEFINE_HEAT_FLUX, please refer section no. 4.3.8 in fluent documentation (6.2. version).
  Reply With Quote

Old   August 5, 2015, 00:09
Default
  #12
Senior Member
 
Astio Lamar
Join Date: May 2012
Location: Pipe
Posts: 186
Rep Power: 13
asal is on a distinguished road
Hi!

I have the same problem when I run a case with a UDF. I receive this error:

this the UDF:

#include "udf.h"

DEFINE_DIFFUSIVITY(mean_age_diff,c,t,i)
{
return C_R(c,t) * 2.88e-05 + C_MU_EFF(c,t) / 0.7;
}




and this is the error:

ip-exec: mean_age_diff: argument 4:
incorrect type (0): int expectedchip-exec: mean_age_diff: argument 3: incorrect type (5): pointer expectedchip-exec: mean_age_diff: argument 4:
incorrect type (0): int expectedchip-exec: mean_age_diff: argument 3: incorrect type (5): pointer expectedchip-exec: mean_age_diff: argument 4:
incorrect type (490510): int expectedchip-exec: mean_age_diff: argument 3: incorrect type (5): pointer expectedchip-exec: mean_age_diff: argument 4:
incorrect type (0): int expectedchip-exec: mean_age_diff: argument 3: incorrect type (5): pointer expectedchip-exec: mean_age_diff: argument 4:
incorrect type (0): int expectedchip-exec: mean_age_diff: argument 3: incorrect type (5): pointer expectedchip-exec: mean_age_diff: argument 4:
incorrect type (0): int expectedchip-exec: mean_age_diff: argument 3: incorrect type (5): pointer expectedchip-exec: mean_age_diff: argument 4:
incorrect type (0): int expectedchip-exec: mean_age_diff: argument 3: incorrect type (5): pointer expectedch 40047 2.4

Is there any solution to fix this?
Thanks.
asal is offline   Reply With Quote

Reply

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
User Wall Heat Flux Dyls STAR-CCM+ 0 May 13, 2013 11:58
Water subcooled boiling Attesz CFX 7 January 5, 2013 03:32
UDF to calculate average heat flux dynamics Fluent UDF and Scheme Programming 0 July 21, 2012 18:54
heat flow UDF on coupled surface (wall-shadow wall) Friedmann Fluent UDF and Scheme Programming 0 August 5, 2010 10:25
Multicomponent fluid Andrea CFX 2 October 11, 2004 05:12


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