LAMMPS WWW Site - LAMMPS Documentation - LAMMPS Mailing List Archives
Re: [lammps-users] Regarding the calculation of slip events in granular simulation

# Re: [lammps-users] Regarding the calculation of slip events in granular simulation

 From: saikat roy Date: Thu, 3 Aug 2017 12:17:58 +0300

Dear Axel,

Here is the detailed information. when fs>fn I am doing the calculation. The quantity of interest is slipc,lred and slideloss (part of the code where I have added some lines in pair/gran/hooke/history

// energy loss from sliding or damping
if (fs > fn) {
if (shrmag != 0.0) {
fs1 *= 0.8*fn/fs;
fs2 *= 0.8*fn/fs;
fs3 *= 0.8*fn/fs;
shear[0] = -fs1/kt;
shear[1] = -fs2/kt;
shear[2] = -fs3/kt;
fs1l = fs1/0.8;
fs2l = fs2/0.8;
fs3l = fs3/0.8;
fslmag = sqrt(fs1l*fs1l+fs2l*fs2l+fs3l*fs3l);
fsmag = sqrt(fs1*fs1 + fs2*fs2 + fs3*fs3);

lred = 0.25*sqrt(shear[0]*shear[0] + shear[1]*shear[1] +  shear[2]*shear[2]);
slideloss = 0.5*lred*(fsmag+fslmag);
slipc = fs1/fs1;
}
else fs1 = fs2 = fs3 = 0.0;
lred = 0.0*sqrt(shear[0]*shear[0] + shear[1]*shear[1] +  shear[2]*shear[2]);
slideloss = 0.0*lred*(fsmag+fslmag);
slipc = 0*fs1/fs1;

}
else
{
fs1 -= (gammat*vtr1);
fs2 -= (gammat*vtr2);
fs3 -= (gammat*vtr3);
lred = 0.0*sqrt(shear[0]*shear[0] + shear[1]*shear[1] +  shear[2]*shear[2]);
slideloss = 0.0*lred*(fsmag+fslmag);
slipc = 0*fs1/fs1;

}

fl1 = slipc;
fl2 = slideloss;
fl3 = lred;

then I am casting this into

and in the compute pair/gran/local

''else if (strcmp(arg[iarg],"forceloss") == 0) flflag = 1;

nvalues = posflag*6 + idflag*3 + fflag*3 + fsflag*3 + flflag*3 + deltanflag + tflag*3 + hflag*dnum + aflag + hfflag;

if(flflag)
{
array[ipair][n++] = fl1;
array[ipair][n++] = fl2;
array[ipair][n++] = fl3;
}''

These are the places where I have changed. I can succesfully dump deltan, fs1,fs2 and fs3 but not these ones. Can you please suggest where I am going wrong.

On Thu, Aug 3, 2017 at 2:01 AM, Axel Kohlmeyer wrote:

On Wed, Aug 2, 2017 at 5:30 PM, saikat roy wrote:
Dear all,

I am trying to calculate no of slip events in granular simulation. In order to do that I added some lines in the pair/gran model and also compute pair/gran/local. Like when ft>fn, slip=1. Now when I am trying to store this by adding a slipflag, it is giving zero. I must be doing some mistake. Can someone help me on that.

your e-mail has the same problem as your code: it is giving zero (information).

axel.

thanks a lot

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most