|August 1, 2011, 13:52||
Access_violation Errors when using the macros C_T_G(c,t) in FLUENT UDF
Join Date: Aug 2011
Posts: 2Rep Power: 0
I am using FLUENT 6.3.26 on a Windows 64 bit machine with XP installed. I am writing UDF source files in Visual Studio 2008 on the same computer.
If I use the following code without line [*] (i.e. just set grad_f = 0.0 or something), then the code will generally initialise and iterate fine. (Using interpreted UDFs for now).
#define K_MEMB 0.6
#define K_F 0.0242
#define T_o 310.66
#define DELTA_MEMB 0.001
DEFINE_PROFILE(heat_flux, thread, position)
real T_s, grad_f, q_f, q_memb, q_use;
/*Find the relavant cell to current face*/
c = F_C0(f,thread);
/*Find the face temperature*/
T_s = F_T(f,thread);
/*Find the face area vector*/
/*Find the temperature gradient in the face normal direction*/
[*] grad_f = (C_T_G(c,thread))*A + (C_T_G(c,thread))*A + (C_T_G(c,thread))*A;
/*Find the heat flux*/
q_f = -K_F*grad_f;
/*Apply this value to the boundary*/
F_PROFILE(f, thread, position) = q_f;
When the problem is either initialised or iterations are begun (it differs from time to time), the following error pops up:
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: ()
And just cannot get it to work. It will work provided there is no mention of C_T_G(c,t). (it works with A, A and A). I have tried typing solve/set/expert into the command window and selecting yes to "keep tempory memory from being freed?", to no avail.
Any help would be very appreciated!
Last edited by SuperNova79; August 4, 2011 at 08:48.
|Thread||Thread Starter||Forum||Replies||Last Post|
|Fluent UDF Discontinuous Motion||lequi7||Fluent UDF and Scheme Programming||2||November 4, 2011 00:18|
|UDF in Fluent||subha_meter||Main CFD Forum||0||October 17, 2009 23:54|
|Compiling UDF in Fluent 12||jsm||FLUENT||1||July 22, 2009 07:40|
|accessing solver data with UDF macros||Dushan||FLUENT||0||October 4, 2006 01:39|
|UDF of Zimont model in fluent||Z||Main CFD Forum||0||February 17, 2005 04:07|