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

Interpreted Error in SourceTerm of k-omeca Model

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 10, 2004, 04:05
Default Interpreted Error in SourceTerm of k-omeca Model
  #1
Bowling
Guest
 
Posts: n/a
My FLUENT5.5 has standard k-epsilon model but I would like to build k-omeca model which differ from k-epsilon in source term only. It has strain rate which already have function in FLUENT [Strainrate_Mag(c,t)]. When I interpreted it the message is:

cpp -ID:\FLUENT.INC\fluent5.5/src -ID:\FLUENT.INC\fluent5.5/cortex/src -ID:\FLUENT.INC\fluent5.5/client/src -ID:\FLUENT.INC\fluent5.5/multiport/src -I. -DUDFCONFIG_H="<udfconfig.h>" Test_2.c

Error: Test_2.c: line 63: function "Strainrate_Mag" not found (pc=24).

Error: Test_2.c: line 63: function "Strainrate_Mag" not found (pc=31).

Error: Test_2.c: line 63: function "Strainrate_Mag" not found (pc=238).

Error: Test_2.c: line 63: function "Strainrate_Mag" not found (pc=245).

.entry

Because it said that "call Strainrate_Mag (-1)"

The message on FLUENT is:

Material water-liquid: New property "UDS Diffusivity" has been added. Selecting uds method for "UDS Diffusivity" -- data required.

Material air: New property "UDS Diffusivity" has been added. Selecting uds method for "UDS Diffusivity" -- data required. chip-exec: k_source: wrong return type: void udf function expectedTest_2.c:2: math.h: No such file or directory

Error: FLUENT received fatal signal (ACCESS_VIOLATION) 1. Note exact events leading to error. 2. Save case/data under new name. 3. Exit program and restart to continue. 4. Report error to your distributor. Error Object: () chip-exec: k_source: wrong return type: void udf function expected

This is my C code:

#include "udf.h" #include "math.h"

/* Turbulence model constants */

#define C_MU 0.09 #define SIG_TKE 2.0 #define SIG_TDR 2.0 #define C1_D 0.556 #define C2_D 1.92

/*Use-defined scalars*/ enum { TKE, TDR, N_REQUIRED_UDS };

DEFINE_SOURCE(k_source,c,t,dS,eqn) { real G_k;

G_k=C_MU_T(c,t)*SQR(Strainrate_Mag(c,t)); dS[eqn]=-2*C_R(c,t)*C_R(c,t)*C_MU*C_UDSI(c,t,TKE)/C_MU_T(c,t);

return G_k-(C_R(c,t)*C_R(c,t)*C_MU*SQR(C_UDSI(c,t,TKE))/C_MU_T(c,t)); }

DEFINE_SOURCE(d_source,c,t,dS,eqn) { real G_k;

G_k=C_MU_T(c,t)*SQR(Strainrate_Mag(c,t));

dS[eqn]=-2*C_R(c,t)*C_R(c,t)*C_MU*C_UDSI(c,t,TKE);

return C1_D*C_UDSI(c,t,TDR)*G_k/C_UDSI(c,t,TKE)-C2_D*C_R(c,t)*SQR(C_UDSI(c,t,TDR))/C_UDSI(c,t,TKE); }

DEFINE_ADJUST(turb_adjust , domain) {

Thread *t;

cell_t c;

/* set the turbulent viscosity */

thread_loop_c(t,domain)

{

if (FLUID_THREAD_P(t))

{

begin_c_loop(c,t)

{

C_MU_T(c,t) =C_R(c,t)*C_UDSI(c,t,TKE)/C_UDSI(c,t,TDR);

}

end_c_loop(c,t)

}

} }

Another problem, at if (FLUID_THREAD_P(t)) it said structure reference not implemented. I don't know why.
  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
Problems bout CFD model of biomass gasification, Downdraft gasifier wanglong FLUENT 2 November 25, 2009 23:27
help for different between les model (subgrid-scale model) liuyuxuan FLUENT 1 October 2, 2009 15:25
Grid resolution for full-scale and down scaled model gravis Main CFD Forum 0 October 2, 2009 10:27
model han Main CFD Forum 0 September 27, 2005 08:35
Why Turbulence models are not universal. Senthil Main CFD Forum 4 July 5, 2000 04:34


All times are GMT -4. The time now is 11:38.