Fcm(group,dim,region)

Hi all,

I want to calculate/output the value of total force for some water molecules in a specified region. Oxygen atoms were specified as groups OXY. Hydrogen atoms were specified as groups HYD.

This is the main body of my input file:

fix 2 all nvt temp 300.0 300.0 100.0

region region1 block INF INF INF INF 24.0 24.5 units box
variable oxy_in_region_1 equal count(OXY,region1)
variable hyd_in_region_1 equal count(HYD,region1)
variable force_1_o equal Fcm(OXY,z,region1)
variable force_1_h equal Fcm(HYD,z,region1)

thermo_style custom step temp epair pe etotal press vol v_force_1_o
thermo_modify flush yes
thermo 100

run 1000000

But I always got the error:
Step Temp E_pair PotEng TotEng Press Volume force_1_
ERROR: Invalid math/group/special function in variable formula

I supposed those variable settings were correct. Did I miss any important information in the manual?

Many thanks in advance!

Hang

Hi all,

I think I know what’s going on for those errors. I should use fcm instead of capical f. Sorry for interrupting you.

Hang

2012/11/12 <physics.hangyan.chen@…24…>