#CV输入文件
#和mdin规则本质一样
#print_CV = A和print { CV = A }是等效的
#单井号可以单行注释
##双井号可以多行注释，注释掉这一行加上整个大括号中的内容，例如下面大括号内的内容全都是注释
{
输入文件分为定义CV虚原子、定义CV、使用CV和其他四部分
四部分顺序不重要，谁先谁后都可以，重要的是命令名
}

###########################
#       定义CV虚原子      #
###########################
#center_of_mass:质心
com_of_123
{
    vatom_type = center_of_mass
    atom = 1 2 3
}
#center: 任意权重的中心
center_of_45
{
    vatom_type = center
    atom = 4 5
    weight = 0.8 0.2
}
###########################
#         定义CV          #
###########################
#CV名不和程序内部所有使用CV命令的名重合即可
#通过type定义该CV的类型
#其他参数根据对应type设置
#下面列举了目前支持的CV

x1
{
    CV_type = position_x
    atom = 1
}

x2
{
    CV_type = position_x
    atom = 2
}

x3
{
    CV_type = position_x
    atom = 3
}

xcom
{
    CV_type = position_x
    atom = com_of_123
}

y4
{
    CV_type = position_y
    atom = 4
}

y5
{
    CV_type = position_y
    atom = 5
}

ycenter
{
    CV_type = position_y
    atom = center_of_45
}

##x0
{
     CV_type = position_x  #原子的x坐标，注意可能会超出周期性边界
     atom = 0  #1个Int参数，哪个原子的坐标，注意是从0开始计数的
}

##nice_day
{
     CV_type = position_y  #原子的x坐标，注意可能会超出周期性边界
     atom = 50  #1个Int参数，哪个原子的坐标
}

##z2
{
     CV_type = position_z  #原子的z坐标，注意可能会超出周期性边界
     atom = 777
}

##fx0
{
    CV_type = scaled_position_x   #原子的x坐标除以盒子x轴长度
    atom = 0
}

##fy0
{
    CV_type = scaled_position_y   #原子的y坐标除以盒子y轴长度
    atom = 0
}

##fz0
{
    CV_type = scaled_position_z   #原子的z坐标除以盒子z轴长度
    atom = 0
}

##lx
{
    CV_type = box_length_x    #盒子的x轴长度
}

##ly 
{
    CV_type = box_length_y    #盒子的y轴长度
}

##lz

{
    CV_type = box_length_z    #盒子的z轴长度
}

##r12
{
    CV_type = distance    #两个原子之间的距离（周期性边界条件下）
    atom = 1 2         #两个整数
}

##x21
{
    CV_type = displacement_x    #两个原子之间的x方向上的位移（周期性边界条件下）
    atom = 1 2               #两个整数，后减前
}

##y21
{
    CV_type = displacement_y    #两个原子之间的y方向上的位移（周期性边界条件下）
    atom = 1 2               #两个整数，后减前
}

##z21
{
    CV_type = displacement_z    #两个原子之间的z方向上的位移（周期性边界条件下）
    atom = 1 2               #两个整数，后减前
}

##angle0
{
    CV_type = angle             #三个原子之间的角度
    atom = 0 1 2             #01矢量和21矢量之间的夹角（单位rad，0~pi）
}

torsion0
{
    CV_type = dihedral           #四个原子之间的二面角角度（单位rad，0~2pi）
    atom = 0 1 2 3            #0-1-2-3的二面角
}

##rmsd0
{
    CV_type = rmsd
}
###########################
#         使用CV          #
###########################
#print：将CV打印到mdout中
print
{
    CV = torsion0 x1 x2 x3 xcom y4 y5 ycenter#通过CV名列表给出CV，对应定义CV部分
}

#restrain: 在体系中添加一个bias, E_bias = \sum_i weight_i * (CV_i - reference_i) ^ 2
##restrain
{
    CV = x0 z2
    #与CV数量相同的参数
    weight = 5.5e1 .8
    reference = 96 87.3811
}
###########################
#          其他           #
###########################
#不检查CV的使用情况
#dont_check_input = 1
