TAGGED: dpm, enthalpy, particle-surface-reaction
-
-
September 19, 2020 at 9:32 amJeroenSubscriber
I have made a model for a custom particle surface reaction using the multiple surface reactions model with a UDF. Now the heat of reaction for this particle surface reaction is given by:
September 23, 2020 at 5:48 pmStephen OrlandoAnsys EmployeeHi,nCan you copy and paste your UDF in a reply so that we can have a look? You might want to look at the section 2.2.1. DEFINE_ADJUST in the UDF section of the Fluent Customization Manual which shows how to compute a volume integral in a udf.nThanks,nStevenSeptember 25, 2020 at 2:49 pmJeroenSubscriberHi steve, here is the UDF i am currently using. It returns a reaction rate (in kg/s) for a particle. Fluent uses this reaction rate to determine the heat of reaction which should be calculated according to the equation mentioned in my previous post. However, it does not seem to take the integral term into account. This is also something this UDF cannot return (as far as I am aware).n#include udf.hn#include dpm.hn#include stdlib.hnnnDEFINE_PR_RATE(reduction_rate, c, t, r, mw, pp, tp, sf, dif_i, cat_i, rr)n{nntcphase_state_t *c0 = &(tp->cphase[0]); /* cell information of particle location */nntMaterial *mat = THREAD_MATERIAL(t);ntint ind_H2O = mixture_specie_index(mat, h2o); /* get steam index */ntint ind_H2 = mixture_specie_index(mat, h2);  /* get hydrogen index */nntint atm = 101325;        /* atmospheric pressure [Pa] */ntreal T_c = c0->temp;       /* cell temperature [K] */ntreal T_p = TP_T(tp);ttt /* particle temperature [K] */ntreal pp_H2O = pp[ind_H2O] / atm; /* partial pressure steam [atm] */ntreal pp_H2 = pp[ind_H2] / atm;  /* partial pressure hydrogen [atm] */nntreal E_act;ntreal k0;ntint s;ntint n1;ntint n2;nntif (TP_INIT_RHO(tp) == 5150)nt{nttE_act = 214000;nttk0 = 4.41e7;ntts = 0;nttn1 = 2;nttn2 = 3;nt}ntelsent{nttn1 = 3;nttn2 = 4;nttif (T_p >= 1623.15)ntt{ntttE_act = 170000;ntttk0 = 2.5e7;nttts = -1;ntt}nttelsentt{ntttE_act = 193000;ntttk0 = 8.65e6;nttts = 0;ntt}nt}nnt/*************nt Calculationsnt**************/ntreal K = -4.053E-7 * pow((T_p - 273.15), 2) + 0.001404 * (T_p - 273.15) - 0.3145; /* Equilibrium constant */nntfloat molMass1 = 55.845 / 1000;tttttntfloat molMass2 = 15.9994 / 1000;ttttntreal molMass3 = n1 * molMass1 + n2 * molMass2;nntreal mp_t = TP_MASS(tp);ttt /* total particle mass [kg] (at current time) */ntreal mp_i = TP_INIT_MASS(tp);tt /* initial particle mass [kg] (at injection) */nntreal W_oi = (n2 * molMass2) / (molMass3);ttttttttttttttttttt /* initial mass fraction of 2 */ntreal X0 = (mp_i - mp_t) / (mp_i * W_oi);tttttttttttttttttttt /* current conversion degree */ntreal Dp_mu = TP_DIAM(tp)*pow(10, 6);ttttttttttttttttttttt /* particle diameter in mu */ntreal dXdt = k0 * exp(-E_act / (UNIVERSAL_GAS_CONSTANT / 1000 * T_p)) * (pp_H2 - (pp_H2O / K)) * (1 - X0) * pow(Dp_mu, s); /* increase in conversion degree */ntreal dmdt = dXdt * mp_i * W_oi;ttttttttttttttttttttttt /* change in particle mass [kg/s] */nnt*rr = -dmdt / (n2 * molMass2) * molMass3;t/* reaction rate */n}nOctober 6, 2020 at 9:03 amAmine Ben Hadj AliAnsys EmployeePlease check if the material used for Multiple Surface Reaction are correct regarding the SSE.nViewing 3 reply threads- The topic ‘How is the heat of reaction calculated for the multiple surface reactions model?’ is closed to new replies.
Ansys Innovation SpaceTrending discussions- Non-Intersected faces found for matching interface periodic-walls
- Script error Code: 800a000d
- Unburnt Hydrocarbons contour in ANSYS FORTE for sector mesh
- Help: About the expression of turbulent viscosity in Realizable k-e model
- Fluent fails with Intel MPI protocol on 2 nodes
- Cyclone (Stairmand) simulation using RSM
- error udf
- Diesel with Ammonia/Hydrogen blend combustion
- Mass Conservation Issue in Methane Pyrolysis Shock Tube Simulation
- Script Error
Top Contributors-
1341
-
591
-
584
-
525
-
366
Top Rated Tags© 2025 Copyright ANSYS, Inc. All rights reserved.
Ansys does not support the usage of unauthorized Ansys software. Please visit www.ansys.com to obtain an official distribution.
-
The Ansys Learning Forum is a public forum. You are prohibited from providing (i) information that is confidential to You, your employer, or any third party, (ii) Personal Data or individually identifiable health information, (iii) any information that is U.S. Government Classified, Controlled Unclassified Information, International Traffic in Arms Regulators (ITAR) or Export Administration Regulators (EAR) controlled or otherwise have been determined by the United States Government or by a foreign government to require protection against unauthorized disclosure for reasons of national security, or (iv) topics or information restricted by the People's Republic of China data protection and privacy laws.