|
[Sponsors] |
August 8, 2016, 04:19 |
DEFINE_DELTAT problem
|
#1 |
Member
Davoud Malekian
Join Date: Jan 2016
Posts: 53
Rep Power: 10 |
Hi guys,
anyone knows how can i hook DEFINE_DELTAT in fluent? i know i should use adaptive time step in the fluent menu and ... but when i hook my udf in that menu and start the calculation nothing happens (it just calculates 1 time step and nothing more!), i want to know if there is anything that i should do before starting calculation or not, here is my udf : #include "udf.h" DEFINE_DELTAT(delta_t,d) { real time_step; real flow_time = CURRENT_TIME; if (flow_time < 0.1) time_step = 0.001; else if (flow_time < 0.14) time_step = 0.0001; else time_step = 0.001; return time_step; } |
|
August 8, 2016, 09:32 |
|
#2 |
Senior Member
Paritosh Vasava
Join Date: Oct 2012
Location: Lappeenranta, Finland
Posts: 732
Rep Power: 23 |
Try
Code:
if (flow_time >= 0.1 && flow_time < 0.14) time_step = 0.001; else time_step = 0.0001; return time_step; } |
|
August 9, 2016, 02:05 |
|
#3 |
Member
Davoud Malekian
Join Date: Jan 2016
Posts: 53
Rep Power: 10 |
Hi vasava,
tnx for the help , i got the point & tried something similar to your code and it really worked , thanks for the help again |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
UDF compiling problem | Wouter | Fluent UDF and Scheme Programming | 6 | June 6, 2012 05:43 |
Gambit - meshing over airfoil wrapping (?) problem | JFDC | FLUENT | 1 | July 11, 2011 06:59 |
natural convection problem for a CHT problem | Se-Hee | CFX | 2 | June 10, 2007 07:29 |
Adiabatic and Rotating wall (Convection problem) | ParodDav | CFX | 5 | April 29, 2007 20:13 |
Is this problem well posed? | Thomas P. Abraham | Main CFD Forum | 5 | September 8, 1999 15:52 |