CFD Online Discussion Forums

CFD Online Discussion Forums (
-   FLUENT (
-   -   non newtonian viscosity problem (

moloykb June 27, 2012 07:21

non newtonian viscosity problem
Dear all,
I am simulating the problem of blood flow through an artery in 2D considering laminar flow. For this I am using the Walburn and Scneck model to define the blood viscosity using the equation:
mu_lam=K*(strain)^(n-1), where K=14.67*10^(-3) and n=0.7755. In order to define the viscosity I am using the following UDF:
#include "udf.h"
double mu_lam;
double strain;
double muinf = 14.67e-3;
double n = .7755;
strain = pow(C_DUDX(c, t),2)+ pow(C_DVDY(c, t),2)+
2*pow(C_DUDY(c, t)+ C_DVDX(c, t),2)+
2*pow(C_DUDZ(c, t),2)+
2*pow(C_DVDZ(c, t),2);
strain = pow(strain, 0.5);
strain =fabs(strain);
return mu_lam;
But, once I try to solve it the solver gives the error: Divergence detected in the AMG solver.
Please help me....

meangreen July 3, 2012 16:47

You should repost this in the UDF section of the forum. You will likely get more help.

meangreen July 3, 2012 16:48

I think it is because when Strain = 0, you will be dividing by zero. Try adding an if statment in there that says if strain is below some value than mu_lam = some large value... or make stain = pow(C_DU...) + 1x10^(-12),

moloykb July 4, 2012 02:51

Thanks for the reply. It works properly.

meangreen July 5, 2012 15:47

no problem.

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