Hi all,
I’m working with the ELBA coarse grain model and am trying to simulate a lipid bilayer example. When the simulation gets to the fix ave/spatial commands, it fails with the error:
ERROR: Illegal fix ave/spatial command (…/fix_ave_spatial.cpp:255)
I’ve tried commenting everything except for the variables and groups prior to these commands to see if I can diagnose the problem, but I haven’t been successful. Below is the first fix command:
fix numDensLip lip ave/spatial {Ne} {Nr} {Nf} z center {Dz} &
density/number units box file numDensLip.zProfile
I’ve read the documentation and I’m not sure what the mistake is in the command. Does anyone know what is wrong with the fix command?
Thanks in advance,
Patrick
What are the values of the 4 variables?
Steve
These are all the variables:
variable Neqnvt equal 5000
variable Neqnpt equal 50000
variable Nprod equal 30000
variable Ne equal 2
variable Nr equal 50000
variable Nf equal {Nprod}+{Neqnvt}+{Neqnpt}
variable Nthe_e equal {Nthe}/${Ne}
variable Dz equal 1.0
I think it might be due to the fact that Nr and Neqnpt are the same value, is that possible?
Thanks,
Patrick
From the fix ave/spatial doc page:
Also, the timesteps contributing to the average value cannot overlap, i.e. Nfreq > (Nrepeat-1)*Nevery is required.
I believe you have 2 50000 85000 so that is not allowed.
I.e. you can’t get 50K samples every other timestep within 85K steps.
Steve
Ah thank you so much for the help, that makes sense. I brought Nr down to 5000 and it works perfectly fine now.
Patrick