CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

strain rate magnitude

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

Like Tree11Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 21, 2011, 05:58
Smile strain rate magnitude
  #1
Member
 
Rakesh
Join Date: May 2011
Posts: 33
Rep Power: 14
rakadit is on a distinguished road
Dear All!

what is the correct definition for finding strain rate magnitude?

in Fluent. in Flunent ,STRAIN-RATE-MAG(c,t) is defined as:

strain_rate_mag(c,t) = sqrt[[C_DUDX(c,t)*(C_DUDX(c,t)+C_DUDX(c,t))+C_DUDY(c,t)* (C_DUDY(c,t)+C_DVDX(c,t))+C_DUDZ(c,t)*(C_DUDZ(c,t) +C_DWDX(c,t))]+ [C_DVDX(c,t)*(C_DVDX(c,t)+C_DUDY(c,t))+C_DVDY(c,t)* (C_DVDY(c,t)+C_DVDY(c,t))+C_DVDZ(c,t)*(C_DVDZ(c,t) +C_DWDY(c,t))]+ [C_DWDX(c,t)*(C_DWDX(c,t)+C_DUDZ(c,t))+C_DWDY(c,t)* (C_DWDY(c,t)+C_DVDZ(c,t))+C_DWDZ(c,t)*(C_DWDZ(c,t) +C_DWDZ(c,t))]];

is the above definition correct .please elaborate on this?

Thanks ,

Rakesh
rakadit is offline   Reply With Quote

Old   July 21, 2011, 15:42
Default
  #2
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Montreal, QC
Posts: 735
Blog Entries: 1
Rep Power: 22
Amir is on a distinguished road
Hi,
the compact form is:
\sqrt{2*D:D}
which is:
\sqrt{2*DijDij} ; i,j=1,2,3 (two inner products)
D : strain rate tensor
sadjad.s and alainislas like this.

Last edited by Amir; July 23, 2011 at 04:30.
Amir is offline   Reply With Quote

Old   July 23, 2011, 03:18
Smile starin rate
  #3
Member
 
Rakesh
Join Date: May 2011
Posts: 33
Rep Power: 14
rakadit is on a distinguished road
Dear Sir,
Thanks for your quick response.
it would be great help If you elaborate a liitle more.

is sqrt(Dij Dij) =sqrt(e11^2+e12^2+e13^2+e21^2+......and so on).
here e11 etc.means 9 strain rate components.

but then how is it equivalent to the relation given in Fluent manual as S^2=delu/delx*(e11)+delu/dely*e12)+delu/delz*(e13)+................and so on.


Thanks ,

Rakesh
rakadit is offline   Reply With Quote

Old   July 23, 2011, 04:43
Default
  #4
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Montreal, QC
Posts: 735
Blog Entries: 1
Rep Power: 22
Amir is on a distinguished road
Dear Rakesh,
In Mathematics, the magnitude of a second order tensor is defined as \sqrt{T:T}, but here, as you said, we have a convention for shear strain magnitude in which an extra constant coefficient is multiplied, so:
strain rate magnitude= \sqrt{2*D:D}=\sqrt{2*D^{2}_{11}+2*D^{2}_{12}+...}
Note that it is equivalent with FLUENT manual interpretation: (after some manipulations)
s=\sqrt{2u^{2}_{x}+2v^{2}_{y}+2w^{2}_{z}+(u_{z}+w_{x})^{2}+(u_{y}+v_{x})^{2}+(w_{y}+v_{z})^{2}}


Amir

Last edited by Amir; July 23, 2011 at 08:31.
Amir is offline   Reply With Quote

Old   July 26, 2011, 11:05
Thumbs up
  #5
Member
 
Rakesh
Join Date: May 2011
Posts: 33
Rep Power: 14
rakadit is on a distinguished road
Dear Sir,

Thank you very much.


Rakesh
rakadit is offline   Reply With Quote

Old   September 20, 2012, 05:00
Default
  #6
Unneoetech
Guest
 
Posts: n/a
The term you mention is usually defined as the shear rate. Is in Fluent the shear rate and the strain rate equal for Non-Newtonian flow?
  Reply With Quote

Old   September 20, 2012, 10:26
Default
  #7
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Montreal, QC
Posts: 735
Blog Entries: 1
Rep Power: 22
Amir is on a distinguished road
Quote:
Originally Posted by Unneoetech View Post
The term you mention is usually defined as the shear rate. Is in Fluent the shear rate and the strain rate equal for Non-Newtonian flow?
Dear friend,

These are two different concepts. Strain rate contains both shear and normal rates; you can consider strain rate as rate of deformation where the shear rate is just one part of that.
The strain rate tensor is extracted from gradient of velocity field while the fluid type just affects the constitutive relation (relation between stress and rate of strain) so these definitions can be used for each type.

Bests,
hulli likes this.
__________________
Amir
Amir is offline   Reply With Quote

Old   September 20, 2012, 10:37
Default
  #8
Unneoetech
Guest
 
Posts: n/a
Hi Amir,

That is just what I found out a couple of seconds ago It is also described in the Fluent manual in Section 30.4
http://hpce.iitm.ac.in/website/Manua...219.htm#217910
Quote:

Strain Rate (in the Derivatives... category) relates shear stress to the viscosity. Also called the shear rate ( in Equation 8.4-17), the strain rate is related to the second invariant of the rate-of-deformation tensor . Its unit quantity is time-inverse. In 3D Cartesian coordinates, the strain rate,, is defined as Eq. (30.4-30)

Thanks for your fast answer!
  Reply With Quote

Old   September 20, 2012, 10:44
Default
  #9
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Montreal, QC
Posts: 735
Blog Entries: 1
Rep Power: 22
Amir is on a distinguished road
Quote:
Originally Posted by Unneoetech View Post
Hi Amir,

That is just what I found out a couple of seconds ago It is also described in the Fluent manual in Section 30.4
http://hpce.iitm.ac.in/website/Manua...219.htm#217910
Quote:

Strain Rate (in the Derivatives... category) relates shear stress to the viscosity. Also called the shear rate ( in Equation 8.4-17), the strain rate is related to the second invariant of the rate-of-deformation tensor . Its unit quantity is time-inverse. In 3D Cartesian coordinates, the strain rate,, is defined as Eq. (30.4-30)

Thanks for your fast answer!
Yes I've seen that.
What I said was the definition in continuum mechanics but in FLUENT some definitions have changed! e.g., wall shear stress is wall traction!

Bests,
__________________
Amir
Amir is offline   Reply With Quote

Old   September 25, 2012, 04:52
Default
  #10
Member
 
Naimah
Join Date: Nov 2011
Posts: 58
Rep Power: 14
wanna88 is on a distinguished road
Quote:
Originally Posted by Unneoetech View Post
Hi Amir,

That is just what I found out a couple of seconds ago It is also described in the Fluent manual in Section 30.4
http://hpce.iitm.ac.in/website/Manua...219.htm#217910
Quote:

Strain Rate (in the Derivatives... category) relates shear stress to the viscosity. Also called the shear rate ( in Equation 8.4-17), the strain rate is related to the second invariant of the rate-of-deformation tensor . Its unit quantity is time-inverse. In 3D Cartesian coordinates, the strain rate,, is defined as Eq. (30.4-30)

Thanks for your fast answer!
Hi,

So is that means in the Fluent, the strain rate equal to shear rate?

Thank you.

Regards,
Naimah
wanna88 is offline   Reply With Quote

Old   January 10, 2013, 07:43
Default mean shear rate
  #11
New Member
 
Michael Rembe
Join Date: Oct 2009
Location: Germany
Posts: 4
Rep Power: 16
rembe is on a distinguished road
Hi,

I'm not a expert in fluid mechanics. Can you tell me the difference between the strain rate magnitude:




and the mean strain rate:

Sij=1/2*(dUi/Dxj+dUj/dxi)

I need th correct formulation in the SMAGORINSKY-model.

Thank you very much
Michael
rembe is offline   Reply With Quote

Old   August 17, 2014, 17:37
Default
  #12
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
Dear Amir,
I would like to calculate in UDF daviatoric part of strain rate tensor so definition of it as following:
S_prime_ij=S_ij - S_mm*kronecker_delta_ij/3,
so the part of kronecker_delta_ij is confused me…I must again calculate the magnitude if the S_prime as you explained in this thread or it is different?
thanks in advance!
Quote:
Originally Posted by Amir View Post
Dear Rakesh,
In Mathematics, the magnitude of a second order tensor is defined as \sqrt{T:T}, but here, as you said, we have a convention for shear strain magnitude in which an extra constant coefficient is multiplied, so:
strain rate magnitude= \sqrt{2*D:D}=\sqrt{2*D^{2}_{11}+2*D^{2}_{12}+...}
Note that it is equivalent with FLUENT manual interpretation: (after some manipulations)
s=\sqrt{2u^{2}_{x}+2v^{2}_{y}+2w^{2}_{z}+(u_{z}+w_{x})^{2}+(u_{y}+v_{x})^{2}+(w_{y}+v_{z})^{2}}


Amir
Kanarya is offline   Reply With Quote

Old   August 18, 2014, 08:33
Default
  #13
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Montreal, QC
Posts: 735
Blog Entries: 1
Rep Power: 22
Amir is on a distinguished road
Quote:
Originally Posted by Kanarya View Post
Dear Amir,
I would like to calculate in UDF daviatoric part of strain rate tensor so definition of it as following:
S_prime_ij=S_ij - S_mm*kronecker_delta_ij/3,
so the part of kronecker_delta_ij is confused me…I must again calculate the magnitude if the S_prime as you explained in this thread or it is different?
thanks in advance!
Hi,

No, this is quite straight-forward! Just substitute the S_mm term with sum of the diagonal components.
i.e., S_mm=S11+S22+S33

kronecker_delta_ij=0, where i/=j
kronecker_delta_ij=1, where i==j

Bests,
__________________
Amir
Amir is offline   Reply With Quote

Old   August 19, 2014, 09:01
Default
  #14
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
thanks Amir!
I am trying to define tensor in UDF but sth is wrong with the code or udf...
PHP Code:
real puixj[ND_ND][ND_ND];
puixj[0][0]= C_DUDX(c,t);
puixj[1][0]= C_DVDX(c,t);
puixj[0][1]= C_DUDY(c,t);
puixj[1][1]= C_DVDY(c,t);

for(
j=0;j<ND_ND;j++)
{
for(
i=0;i<ND_ND;i++)
{
Og[i][j]=0.5*(puixj[i][j]-puixj[j][i]); //Og is the rotation tensor
}

when I am putting random number to i or j it gives some results which is wrong!For example;even Og[25][20] is giving some result ....
do you know what is the problem here?
thanks in advance!
Quote:
Originally Posted by Amir View Post
Hi,

No, this is quite straight-forward! Just substitute the S_mm term with sum of the diagonal components.
i.e., S_mm=S11+S22+S33

kronecker_delta_ij=0, where i/=j
kronecker_delta_ij=1, where i==j

Bests,
Kanarya is offline   Reply With Quote

Old   August 19, 2014, 10:40
Default
  #15
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Montreal, QC
Posts: 735
Blog Entries: 1
Rep Power: 22
Amir is on a distinguished road
Quote:
Originally Posted by Kanarya View Post
when I am putting random number to i or j it gives some results which is wrong!For example;even Og[25][20] is giving some result ....
do you know what is the problem here?
thanks in advance!
I guess, proper definition of the Og tensor as Og[ND_ND][ND_ND] and an initialization of this tensor may fixed this issue! However, I wonder how your UDF may lead to such error during the calculation!
Actually, forcing wrong indices to a matrix may result in previously saved and irrelative data in the memory.

Bests,
__________________
Amir
Amir is offline   Reply With Quote

Old   August 21, 2014, 06:52
Default
  #16
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
Hi Amir,
thanks for the answer!
But I am still getting weird values ...
For example I trying to define kronecker delta like:
PHP Code:
for(jj=0;jj<ND_ND;jj++)
{
for(
ii=0;ii<ND_ND;ii++)
{
if (
ii==jj)
    
delta[ii][jj]=1;
else
    
delta[ii][jj]=0;
}
}
and print 
it out with:
Message("delta: %g/n",delta[ii][jj]); 
the result is always "0"
Do you have any idea what is wrong with it?
thanks in advance!
Quote:
Originally Posted by Amir View Post
I guess, proper definition of the Og tensor as Og[ND_ND][ND_ND] and an initialization of this tensor may fixed this issue! However, I wonder how your UDF may lead to such error during the calculation!
Actually, forcing wrong indices to a matrix may result in previously saved and irrelative data in the memory.

Bests,
Kanarya is offline   Reply With Quote

Old   August 21, 2014, 07:48
Default
  #17
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Montreal, QC
Posts: 735
Blog Entries: 1
Rep Power: 22
Amir is on a distinguished road
Quote:
Originally Posted by Kanarya View Post
Hi Amir,
thanks for the answer!
But I am still getting weird values ...
For example I trying to define kronecker delta like:
PHP Code:
for(jj=0;jj<ND_ND;jj++)
{
for(
ii=0;ii<ND_ND;ii++)
{
if (
ii==jj)
    
delta[ii][jj]=1;
else
    
delta[ii][jj]=0;
}
}
and print 
it out with:
Message("delta: %g/n",delta[ii][jj]); 
the result is always "0"
Do you have any idea what is wrong with it?
thanks in advance!
Hi,
You need to put the Message command inside your loop, not out of that!
Moreover, this is "\n" not "/n".

Bests,
__________________
Amir
Amir is offline   Reply With Quote

Old   August 21, 2014, 08:48
Default
  #18
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
thanks Amir,
it seems it is fine now
Best!
Quote:
Originally Posted by Amir View Post
Hi,
You need to put the Message command inside your loop, not out of that!
Moreover, this is "\n" not "/n".

Bests,
Kanarya is offline   Reply With Quote

Old   August 25, 2014, 14:28
Default
  #19
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
Hi Amir,
I have problem with convergence now.
It seems residuals are fine but the simulation is stopped.
PHP Code:
Updating solution at time levels N and N-1.
 done
.
  
iter  continuity       u-gas     u-solid       v-gas     v-solid       uds-0       uds-1    vf-solid     time/iter
9481 solution is converged
  9481  7.9111e-04  1.2569e-06  8.8861e-08  6.0119e-07  7.8996e-09  2.7750e-07  2.6720e-07  3.6096e-07  0
:00:02  100
Re
0
reyp
0
  9482  2.0487e-03  1.0965e-05  1.4955e-05  3.5806e-06  3.8082e-06  2.1239e-04  2.2740e-04  1.4775e-05  0
:00:02   99
Re
0
reyp
0
  9483  1.8130e-03  4.3936e-06  4.6505e-06  1.4881e-06  1.1923e-06  7.8683e-06  6.0966e-06  7.5522e-06  0
:00:02   98
Re
0
reyp
0
# Divergence detected in AMG solver: uds-1 -> Increasing relaxation sweeps!

Divergence detected in AMG solveruds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Warning
An error or interrupt occurred while reading the journal file.
Some commands may not have been completed.

Halting due to end of file on input
Do you have any idea about it?
thanks in advance!
Quote:
Originally Posted by Amir View Post
Hi,
You need to put the Message command inside your loop, not out of that!
Moreover, this is "\n" not "/n".

Bests,
Kanarya is offline   Reply With Quote

Old   August 29, 2014, 17:53
Default
  #20
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 15
Kanarya is on a distinguished road
Hi,
do you think the problem is coming form the tensor which I have posted in thread 14?
may opposite indices are giving the same result?
thanks in advance!
thanks in advance!
Quote:
Originally Posted by Kanarya View Post
Hi Amir,
I have problem with convergence now.
It seems residuals are fine but the simulation is stopped.
PHP Code:
Updating solution at time levels N and N-1.
 done
.
  
iter  continuity       u-gas     u-solid       v-gas     v-solid       uds-0       uds-1    vf-solid     time/iter
9481 solution is converged
  9481  7.9111e-04  1.2569e-06  8.8861e-08  6.0119e-07  7.8996e-09  2.7750e-07  2.6720e-07  3.6096e-07  0
:00:02  100
Re
0
reyp
0
  9482  2.0487e-03  1.0965e-05  1.4955e-05  3.5806e-06  3.8082e-06  2.1239e-04  2.2740e-04  1.4775e-05  0
:00:02   99
Re
0
reyp
0
  9483  1.8130e-03  4.3936e-06  4.6505e-06  1.4881e-06  1.1923e-06  7.8683e-06  6.0966e-06  7.5522e-06  0
:00:02   98
Re
0
reyp
0
# Divergence detected in AMG solver: uds-1 -> Increasing relaxation sweeps!

Divergence detected in AMG solveruds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Divergence detected in AMG solver
uds-1
Warning
An error or interrupt occurred while reading the journal file.
Some commands may not have been completed.

Halting due to end of file on input
Do you have any idea about it?
thanks in advance!
Kanarya is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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 Off
Pingbacks are On
Refbacks are On


LinkBacks (?)
LinkBack to this Thread: https://www.cfd-online.com/Forums/fluent-udf/90818-strain-rate-magnitude.html
Posted By For Type Date
what is strain rate_Baby's home This thread Refback May 8, 2015 15:37

Similar Threads
Thread Thread Starter Forum Replies Last Post
strain rate in UDF Paulina FLUENT 11 November 20, 2014 03:06
strain rate magnitude ahmadbakri STAR-CCM+ 1 June 3, 2010 13:03
Strain rate. MM? Main CFD Forum 1 February 15, 2006 08:55
strain rate at arbitrary position in a cell K. Kevala FLUENT 0 February 4, 2004 17:14


All times are GMT -4. The time now is 12:43.