CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Fluent UDF and Scheme Programming (https://www.cfd-online.com/Forums/fluent-udf/)
-   -   Inert heating law doesnt activate (https://www.cfd-online.com/Forums/fluent-udf/200318-inert-heating-law-doesnt-activate.html)

skumar112 March 29, 2018 13:05

Inert heating law doesnt activate
 
I am trying to implement a UDF and use my own evaporation within DPM UDF's.

I have complied the UDF and run the case however the inert heating law does not activate. The droplets remain at 300K. I have applied the switching law could anyone see what may be wrong here?

DEFINE_DPM_SWITCH(dpm_switch,tp,coupled)
{
cphase_state_t *c = &(tp->cphase[0]);
Material *m = TP_MATERIAL(tp);
/* If the particle temperature above the vaporization temperature switch to evaporation law */
if (TP_T(tp) > DPM_VAPOR_TEMP(tp,m))
{
TP_CURRENT_LAW(tp) = DPM_LAW_USER_1;
}
if (TP_T(tp) < DPM_VAPOR_TEMP(tp,m))
{
TP_CURRENT_LAW(tp) = DPM_LAW_INITIAL_INERT_HEATING;
}
}

AlexanderZ March 29, 2018 22:09

What does macro TP_MATERIAL(tp) do?

best regards

skumar112 March 30, 2018 05:03

specifies m is the dpm material

AlexanderZ April 1, 2018 21:03

In ansys UDF manual called Ansys Customization manual there is 2.5.13.3. Example

Code:

DEFINE_DPM_SWITCH(dpm_switch, p, coupled)
{
cell_t c = P_CELL(p);
Thread *t = P_CELL_THREAD(p);
Material *m = P_MATERIAL(p);
/* If the relative humidity is higher than 1
* and the particle temperature below the boiling temperature
* switch to condensation law
*/
if ((C_UDMI(c,t,UDM_RH) > 1.0) && (P_T(p) < DPM_BOILING_TEMPERATURE(p, m)))
P_CURRENT_LAW(p) = DPM_LAW_USER_1;
else
P_CURRENT_LAW(p) = DPM_LAW_INITIAL_INERT_HEATING;
}

Material *m = P_MATERIAL(p);

only P not TP

may be this is critical, you may try to check

best regards


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