define_profile and F_UDMI
Hi all,
I am trying to set a particular wall heat transfer coefficient to an external wall. I also wanted to monitor the value computed by my UDF, then I used the user-defined memory. But the correspondent variable (when I search for it in FLuent) is always zero. Note that if I write in the UDF printf('variable name') I get the good values....but I need to put these values into a variable! I copy paste the simplified UDF: Code:
DEFINE_PROFILE(name,t,i) Can someone explain me what is the problem? Thanks in advance philus |
I have seen this behavior too. The UDM stored with F_UDMI did not show up in my Fluent results. I don't know if this is intended or a bug, but I found a workaround that worked for me:
Code:
F_UDMI(f,t,0) = h; |
Hi pakk,
effectively this workaround works well, thank you!! philus |
Hi Pakk
I am trying to calculate volumetric flow rate through an interior surface and using DEFINE_ON_DEMAND macro for the same. A piece of my code is as follows: DEFINE_ON_DEMAND(ach_udf) { Thread *t; face_t f; Domain *d; real A[ND_ND]; real ACHt_mean_out=0; real ACHt_mean_in=0; t = Lookup_Thread(d,2); begin_f_loop(f,t) { F_AREA(A,f,t); real vel_roof= F_FLUX(f,t)/(NV_MAG(A)*1.12); if (vel_roof>0) { ACHt_mean_out += vel_roof*NV_MAG(A); } else { ACHt_mean_in +=vel_roof*NV_MAG(A); } } end_f_loop(f,t) } The code is compiled successfully but as soon as I am executing it using EXECUTE_ON_DEMAND, it is giving the following error: Node 1: Process 20248: Received signal SIGSEGV. ================================================== ============================ ================================================== ============================ Node 999999: Process 6872: Received signal SIGSEGV. ================================================== ============================ ================================================== ================================= = BAD TERMINATION OF ONE OF YOUR APPLICATION PROCESSES = RANK 2 PID 4296 RUNNING AT DESKTOP-PA0EM1I = EXIT STATUS: -1 (ffffffff) Can anyone tell how to fix this? |
d is not defined
compile code and READ log to avoid typoes |
Thankyou Alexander. If figured that out but I am getting stuck at one more point. I have posted in another thread and you are a part of it too. Can you please look into it.
|
|
All times are GMT -4. The time now is 22:56. |