Hi everybody
Im currently modifying the movingMesh example to learn how to use Liggghts
Till now I have being able to modify the region geometry, size of particles, particles insertion region, etc
But now I got stuck when I try to apply the wall/gran fix to the stl file that I defined. The program simply crashes.
Does anyone detect where is my mistake?
Here is the scrypt:
atom_style granular
boundary m m m
newton off
communicate single vel yes
units si
#region reg block -.1 0.6 -.1 0.2 -0.3 0.25 units box
region reg cylinder z 0 0 .06 -0.1 .3 units box
create_box 1 reg
neighbor 0.002 bin
neigh_modify delay 0
#Material properties required for new pair styles
fix m1 all property/global youngsModulus peratomtype 5.e6
fix m2 all property/global poissonsRatio peratomtype 0.45
fix m3 all property/global coefficientRestitution peratomtypepair 1 0.9
fix m4 all property/global coefficientFriction peratomtypepair 1 0.05
fix m5 all property/global characteristicVelocity scalar 2.
#New pair style
pair_style gran/hooke/history 1 0 #Hooke without cohesion
pair_coeff * *
timestep 0.00005
fix 1 all nve/sphere
fix 2 all gravity 9.81 vector 0.0 0.0 -1.0
#box walls
fix zwalls all wall/gran/hooke/history 1 0 zplane -0.1 0.3 1
fix cylinder_wall all wall/gran/hooke/history 1 0 zcylinder 0.06 1
#import mesh from cad:
fix cad1 all mesh/gran Paddle3.stl 1 0.001 0 0 250 0 0 0
#particle insertion
region bc cylinder z 0 0 .025 0.01 0.03 units box
group nve_group region reg
fix ins nve_group pour/legacy 1500 1 1 vol 0.5 1000 diam 0.004 0.004 dens 2500 2500 vel 0. 0. 0. 0. -0.8 region bc
#thermo settings
compute 1 all erotate/sphere
thermo_style custom step atoms ke c_1 vol
thermo 1000
thermo_modify lost ignore norm no
compute_modify thermo_temp dynamic yes
#insert the first particles so that dump is not empty
run 1
#make a dump of particles and the stl file
dump dmp all custom 200 post/dump.simula id type type x y z ix iy iz vx vy vz fx fy fz omegax omegay omegaz radius
dump dumpstl all stl 200 post/dump*.stl
#run with particle insertion
run 8000 upto
unfix ins
#run to let particle settle
run 29999 upto
#use the imported mesh as granular wall
fix cylinder_wall all wall/gran/hooke/history 1 0 mesh/gran 1 cad1
run 30000 upto
ckloss | Fri, 03/02/2012 - 12:56
please describe in detail
please describe in detail what error you get - the description above is not concise
Christoph
dnojiri | Wed, 03/07/2012 - 04:12
error message
[Pote:08790] Signal: Segmentation fault (11)
[Pote:08790] Signal code: Address not mapped (1)
[Pote:08790] Failing at address: 0x54
[Pote:08790] [ 0] [0xfb640c]
[Pote:08790] [ 1] liggghts(_ZN9LAMMPS_NS11FixWallGranC2EPNS_6LAMMPSEiPPc+0x1e9) [0x8114a1f]
[Pote:08790] [ 2] liggghts(_ZN9LAMMPS_NS23FixWallGranHookeHistoryC2EPNS_6LAMMPSEiPPc+0x35) [0x8145001]
[Pote:08790] [ 3] liggghts(_ZN9LAMMPS_NS6Modify7add_fixEiPPc+0x229c) [0x81b9586]
[Pote:08790] [ 4] liggghts(_ZN9LAMMPS_NS5Input3fixEv+0x2e) [0x80d8634]
[Pote:08790] [ 5] liggghts(_ZN9LAMMPS_NS5Input15execute_commandEv+0x590) [0x80d9aea]
[Pote:08790] [ 6] liggghts(_ZN9LAMMPS_NS5Input4fileEv+0x25e) [0x80dafbe]
[Pote:08790] [ 7] liggghts(main+0x62) [0x81de2ae]
[Pote:08790] [ 8] /lib/libc.so.6(__libc_start_main+0xf3) [0x4882a3f3]
[Pote:08790] [ 9] liggghts() [0x80a8681]
[Pote:08790] *** End of error message ***
Segmentation fault (core dumped)
I get this just after step 29999, one step before the following line of my program:
fix cylinder_wall all wall/gran/hooke/history 1 0 mesh/gran 1 cad1
run 30000 upto
Thanks for taking time to reply
Philippe | Wed, 03/07/2012 - 09:46
Error
The error is that you assign the name cylinder_wall to your fix wall/gran just like you did in the previous command
fix cylinder_wall all wall/gran/hooke/history 1 0 zcylinder 0.06 1
Assigning a fix name twice to different fix styles will result in undefined behaviour and crashes.
greetz
Philippe
dnojiri | Fri, 03/09/2012 - 05:59
such an obvious problem...
such an obvious problem... :S
How did you noticed it?
Just by glancing at the script? or does the error message indicated something? Im not an experienced programmer so I didnt understand what was written on it.
any tips on how to detect errors while using liggghts?
Thanks Philippe
Dai
Philippe | Fri, 03/09/2012 - 12:42
How I noticed the error
I have made the same mistake a couple of times, so I know how the error looks like ;)