|
[Sponsors] |
The UDF is compiled but not undergo calculation |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
August 27, 2019, 04:03 |
The UDF is compiled but not undergo calculation
|
#1 |
New Member
Uttar Pradesh
Join Date: Aug 2019
Posts: 5
Rep Power: 6 |
Hii...
I have written a simple UDF. It has used UDS and UDM. It got successfully compiled but is not undergoing calculation. The code is stated as below.... #include "udf.h" #include "mem.h" DEFINE_ADJUST(adjust,d) { Thread *t; cell_t c; face_t f; real temp; thread_loop_c(t,d) { begin_c_loop(c,t) { C_UDSI(c,t,0) = C_MU_T(c,t); } end_c_loop(c,t) } thread_loop_c(t,d) { begin_c_loop(c,t) { C_UDMI(c,t,0)C_UDSI(c,t,1) = C_UDSI_G(c,t,0); } end_c_loop(c,t) } } As per my experience, there is problem in assigning the accurate number of scalars and memory in the USER-DEFINED panel oof Fluent. Kindly help in sorting out the problem and any other problem if any. Last edited by am2612; August 27, 2019 at 04:12. Reason: question is incomplete |
|
August 27, 2019, 04:22 |
|
#2 |
New Member
Uttar Pradesh
Join Date: Aug 2019
Posts: 5
Rep Power: 6 |
#include "udf.h"
#include "mem.h" enum {GRADT}; DEFINE_ADJUST(adjust,d) { Thread *ct; cell_t c; real temp; thread_loop_c(ct,d) { begin_c_loop(c,ct) { temp = C_T_G(c,ct)[1]; C_UDMI(c,ct,GRADT) = temp; } end_c_loop(c,ct) } } Similar problem is with this code also. please help... |
|
August 28, 2019, 00:33 |
|
#3 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
what problem do you have?
show explicitly errors which you have best regards |
|
August 28, 2019, 07:01 |
|
#4 |
New Member
Uttar Pradesh
Join Date: Aug 2019
Posts: 5
Rep Power: 6 |
Hii Alexander...
thanks for reply. Following are the codes and their respective errors. The codes shown the error. 1. Adjust_udm get compiled but shows error during iteration. 2. Adjust_uds does not get compiled. Regards Aishwarya |
|
August 28, 2019, 23:42 |
|
#5 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
Code:
#include "udf.h" #include "mem.h" enum {GRADT}; DEFINE_ADJUST(adjust_udm,d) { Thread *ct; cell_t c; real temp; thread_loop_c(ct,d) { begin_c_loop(c,ct) { temp = C_T_G(c,ct)[1]; C_UDMI(c,ct,GRADT) = temp; } end_c_loop(c,ct) } } DEFINE_ADJUST(adjust_uds,d) { Thread *t; cell_t c; face_t f; real temp; thread_loop_c(t,d) { begin_c_loop(c,t) { C_UDSI(c,t,0) = C_MU_T(c,t); } end_c_loop(c,t) } thread_loop_c(t,d) { begin_c_loop(c,t) { C_UDMI(c,t,1) = C_UDSI_G(c,t,0)[0]; C_UDMI(c,t,2) = C_UDSI_G(c,t,0)[1]; C_UDMI(c,t,3) = C_UDSI_G(c,t,0)[2]; } end_c_loop(c,t) } } fluent GUI -> user-defined -> scalars -> uds -> 1 best regards |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Viscosity UDF works when interpreted, Doesn't when compiled? | bloodflow | Fluent UDF and Scheme Programming | 4 | April 11, 2019 09:06 |
UDF compiled and loaded but not available | Easyeight | Fluent UDF and Scheme Programming | 7 | June 28, 2018 11:54 |
How to add a UDF to a compiled UDF library | kim | FLUENT | 3 | October 26, 2011 21:38 |
Help! Compiled UDF problem 4 Wave tank tutorial | Shane | FLUENT | 1 | September 3, 2010 02:32 |
difference between udf compiled and udf interprete | chandra sekhar | FLUENT | 2 | April 11, 2006 00:04 |