LAMMPS WWW Site - LAMMPS Documentation - LAMMPS Mailing List Archives
Re: [lammps-users] Define average density during simulation
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lammps-users] Define average density during simulation


From: alberto <voodoo.bender@...24...>
Date: Fri, 30 Jun 2017 20:09:26 +0200

Thanks,
I noticed that the atoms created fall down immediately.
I think that the problem is the set of velocity or the timestep of my simulation...

Infact...

Step v_T v_p1 E_vdwl E_coul PotEng KinEng TotEng Density Volume Atoms
v_rho_al Temp Press
       0           87            1 -0.085806415            0
-0.085806415   0.25933047   0.17352406   0.13265713         1000
 2        0.002           87   0.85264037
      10           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      20           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      30           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      40           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      50           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      60           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      70           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      80           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
      90           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
     100           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558
     110           87            1 -0.0027002717            0
-0.0027002717           -0 -0.0027002717            0         1000
   0            0            0  -0.36973558

....

velocity ars create ${T} ${vel_seed} sum yes mom yes rot yes dist
uniform loop all

Timestep is 1.0 in real style


Regards

Al


Il 30/giu/2017 05:09 PM, "Steve Plimpton" <sjplimp@...24...> ha scritto:
The "ave" keyword for fix ave/time has an option for
"running", which should produce averages for any
length run.

Steve

On Mon, Jun 26, 2017 at 2:38 PM, alberto <voodoo.bender@...24...> wrote:
Hi steve,
after some tests I produced average for all steps on my simulation, but I think that to produce iterative average loding per steps, I would write a function with 'sum' and 'mean' in syntax c++

Regards 

Al

Il 23/giu/2017 04:49 PM, "Steve Plimpton" <sjplimp@...24...> ha scritto:
Re: your previous Q:
fix   avload all ave/time 1 100000 1
is invalid, hence the error.  See the fix ave/time doc
page about how to define those 3 numeric values.  The
last one would have to be >= 100000 in this case.

Re: your unexpected output.
I imagine you can debug this yourself
Print v_dal with thermo output.  Verify it
is what you expect at each timestep.
Then output it with fix ave/time with no averaging.
See if the values are the same.
Then expt with some averaging, and check by
hand that the values you now get are the averages
of the single timestep values.  Etc, etc.

Steve


On Fri, Jun 23, 2017 at 8:03 AM, alberto <voodoo.bender@...24...> wrote:
hi,

I tried to define
variable    dal equal atoms/vol (in real units)

and

fix   avload all ave/time 1 1 1 v_dal file ave.log

to obtain the comulative average loading

in my case 100 points

the file ave.log report a wrong average

1 0.1
2 0.3
3 0.0

.

I expect that


Step.   Atoms.  Vol.  Density.   Av
1.        1.     10    0.1.     0.1
2.        3.     10    0.3.     0.2
3         0.     10     0       0.1

Av = ( 0.1+ 0.3) /2 = 0.2

I must define manually _expression_ to calculate it. I can print the results in themo_style ?

Al



2017-06-22 16:17 GMT+02:00 alberto <voodoo.bender@...92......>:
Hi,

I define a variable
variable    dal equal atoms/vol
and I use fix ave/time as

fix   avload all ave/time 1 100000 1 v_dal ave one,  where 100000 is the total steps of my simulation
but I obtain message error

ERROR: Illegal fix ave/time command

Al

2017-06-21 16:20 GMT+02:00 Steve Plimpton <sjplimp@...24...>:
The fix ave/time command can do averaging with a moving window or cummulative
ave, see its doc page and keywords.

Steve

On Tue, Jun 20, 2017 at 2:15 PM, alberto <voodoo.bender@...24...> wrote:
Hi,
during a gcmc simulation, I produce density of gas per step. I would produce other column with the average density for every n-th step: for second step the average between the first and second, the third as the average between the first, the second, the third, and so on.
I'm a young user of lammps, and on manual I found the keyword fix ave/time command. It's a good idea to produce the results that I wish, or exist other procedure, or it's not possible during lammps run?

Regards 

Al

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
lammps-users mailing list
lammps-users@...655....net
https://lists.sourceforge.net/lists/listinfo/lammps-users