[lammps-users] A bug with velocity command (maybe)

Hello users,

I am using the velocity command with the granular style and I get a segmentation fault (with the july09 version). Here is my input script:

units si

dimension 3

processors 2 1 1

boundary p p p

newton off

atom_style granular

lattice sc 0.001

region reg_total block -0.005 0.005 -0.005 0.005 -0.005 0.005 units box

create_box 1 reg_total

pair_style gran/hertz/history 200000.0 70000.0 50.0 30.0 0.5 0

pair_coeff * *

create_atoms 1 region reg_total

set group all diameter 0.001

set group all density 10.0

timestep 1.0e-7

velocity all create 1.0 374923 dist uniform

run 10000

The problem arise when I use the velocity command. Is this a bug or am I doing anything wrong?


Francois Fillion-Gourdeau

This was a bug - missing a couple of "else" keywords in velocity.cpp
I'll post a patch - thanks