|
[Sponsors] |
June 27, 2010, 02:45 |
A question about the access of properties?
|
#1 |
New Member
zouzheng
Join Date: Jun 2010
Posts: 5
Rep Power: 16 |
Hello! In the UDF of Fluent, is there any difference among the macro of MATERIAL_PROP( , ),generic property (name,c,t,prop,id,T)and C_***(c,t),such as MATERIAL_PROP(sp,PROP_RHO),generic property (name,c,t,PROP_RHO,id,T) and rho_s= C_R(cell, htread_s)?
Thank you in advanced! |
|
July 2, 2010, 18:28 |
|
#2 |
Member
Tim Diller
Join Date: Mar 2010
Location: Austin, TX
Posts: 32
Rep Power: 16 |
I think those must be the same thing. They're all macros defined by Fluent.
|
|
July 5, 2010, 00:11 |
|
#3 |
New Member
zouzheng
Join Date: Jun 2010
Posts: 5
Rep Power: 16 |
Thank you ! May be they are the same, but I find the results are not same using different macro!
|
|
October 31, 2014, 02:56 |
|
#4 |
Member
Georgy
Join Date: Apr 2011
Location: Russia
Posts: 32
Rep Power: 15 |
Hello!
As far as I can judge, the difference is following. MATERIAL_PROP(sp,PROP_mu) returns the value of viscosity if it is constant. If we use power dependence on temperture the returned value is zero. generic_property(c,t,PROP_mu,i,T) takes into account temperature in cell c; so we can use viscosity as a function of temperature, but I found that it does not work for power-law option. At the same time, it works well for polynomial option. Does anybody know how to get viscosity of mixture component if viscosity has the power-law option? Thank you! |
|
October 31, 2014, 08:40 |
|
#5 |
Senior Member
Rick
Join Date: Oct 2010
Posts: 1,016
Rep Power: 27 |
If you can't access the mixture viscosity when it is set to power-law, what do you think of write the udf for mixture power-law viscosity, declare as a global variable the mixture viscosity so you can access it in other macros?
|
|
October 31, 2014, 08:49 |
|
#6 |
Member
Georgy
Join Date: Apr 2011
Location: Russia
Posts: 32
Rep Power: 15 |
I've done it. Of course, it works fine, but if I change viscosity in GUI of Fluent, I need to change my udf. This is inconvinient. So the idea was to use fluent for viscosity calculation. In that case if user changes the viscosity law, for example, to "kinetic" then udf-code automatically uses new viscosity dependence (not necessary to re-compile).
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Question of properties in two phase solver | mmjhuang | OpenFOAM Running, Solving & CFD | 2 | October 29, 2012 23:56 |
General question what fluid properties do you use | harly | OpenFOAM Running, Solving & CFD | 0 | November 18, 2008 16:38 |
Poisson Solver question | Suresh | Main CFD Forum | 3 | August 12, 2005 05:37 |
Addiotional scalar properties: gas or liquid? | Julie Polyakh | Siemens | 0 | June 20, 2004 16:54 |
question | K.L.Huang | Siemens | 1 | March 29, 2000 05:57 |