CFD Online Logo CFD Online URL
Home > Forums > OpenFOAM Running, Solving & CFD

Power Law Viscosity Model

Register Blogs Members List Search Today's Posts Mark Forums Read

LinkBack Thread Tools Display Modes
Old   February 12, 2008, 23:10
Default Hi, I tried to use Power La
New Member
J. T.
Join Date: Mar 2009
Posts: 12
Rep Power: 10
cpplabs is on a distinguished road
I tried to use Power Law model by modifying Cross Power Law model. The following is the function I tried:

tmp<volscalarfield> PowerLaw::calcNu() const
return m_ * pow(0.01 + strainRate(), n_ - 1.0);

The function is ok to compile and link. But, when I tried to run the program, a fatal error happens in the following operator function:

dimensionSet operator+(const dimensionSet& ds1, const dimensionSet& ds2)
dimensionSet dimSum(ds1);

if (dimensionSet::debug && ds1 != ds2)
("operator+(const dimensionSet& ds1, const dimensionSet& ds2)")
<< "LHS and RHS of + have different dimensions" << endl
<< " dimensions : " << ds1 << " + " << ds2 << endl
<< abort(FatalError);

return dimSum;

It seems that the summation between the scalar value 0.01 and the strain rate scalar field is not allowed.

Can someone tell me the reason of the problem and how to fix the problem?
Thanks in advance.
cpplabs is offline   Reply With Quote

Old   February 13, 2008, 09:09
Default Hi Dragos, Thanks for the
New Member
J. T.
Join Date: Mar 2009
Posts: 12
Rep Power: 10
cpplabs is on a distinguished road
Hi Dragos,
Thanks for the tip. It is dimension problem, the method can pass the dimension check but it causes problem in the returned volScalarField: the dimension of returned volScaleField changes with the parameter n.
The right way is to do the following:
return nu0_ * pow(0.01 + m_ * strainRate(), n_ - 1.0);
The m_ has reversed dimension with the return of strainRate() so that the product is dimentionless.
cpplabs is offline   Reply With Quote


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Non-Newtonian Power Law for Viscosity John FLUENT 16 September 12, 2015 06:18
new parameter for non newtonian power law model! Antoine FLUENT 0 July 21, 2008 04:30
Non newtonian power law model in pipe annulus Poly FLUENT 0 March 24, 2005 16:12
Power law model for porous media Karl FLUENT 0 December 13, 2004 16:14
Viscosity - power law HOC Main CFD Forum 1 January 15, 2003 16:17

All times are GMT -4. The time now is 06:07.