# [lammps-users] Question about TopoTools for benzaldehyde

Hello all,
Sorry if I ask the following questions in this forum.

I just developed the LAMMPS data file for benzaldehyde phenylhydrazone using TopoTools, as shown below. Each partial charge is calculated by involving the electrovalency, electronegativity, both number of bonding and non-bonding electron. I am wondering if that is the way to calculate the charge as in TopoTools.

Subsequently, I try to find out the force field parameter, such as pair_coeff, bond_coeff, angle_coeff, dihedral_coeff, improper_coeff from http://zarbi.chem.yale.edu/ligpargen/. However, the number of dihedral types and improper types are different from those generated by TopoTools.

Any suggestion would be appreciated.

set selh [atomselect top {name H}]

\$selh set mass 1.00800
\$selh set charge 0.064

set selc [atomselect top {name C}]
\$selc set mass 12.01100
\$selc set charge -0.064 ;

set seln [atomselect top {name N}]
\$seln set mass 14.0067
\$seln set charge -0.205 ;

\$selh delete
set selh [atomselect top {index 10}]
\$selh set charge 0.165 ; #H1

\$selc delete
set selc [atomselect top {index 5}]
\$selc set charge 0 ; #C6

\$selc delete
set selc [atomselect top {index 6}]
\$selc set charge 0.141 ; #C7

\$selc delete
set selc [atomselect top {index 9}]
\$selc set charge 0.102 ; #C8

\$seln delete
set seln [atomselect top {index 8}]
\$seln set charge -0.267 ; #N2

set sel [atomselect top all]

topo retypebonds
topo numbondtypes
topo guessangles
topo numangletypes
topo guessdihedrals
topo numdihedraltypes
topo guessimpropers
topo numimpropertypes

mol reanalyze top
set minmax [measure minmax \$sel -withradii]
set box [vecscale 1.1 [vecsub [lindex \$minmax 1] [lindex \$minmax 0]]]
pbc set \$box

set center [measure center \$sel weight none]
\$sel moveby [vecscale -1.0 \$center]
TopoTools::replicatemol top 3 3 4

topo writelammpsdata data.BDHP full
animate write pdb BDHP.pdb

Regards,
Rizal

Hello all,
Sorry if I ask the following questions in this forum.

please note that this is mostly the wrong forum. the vmd mailing list would be more suited. but then again, the major issue at hand is a matter of understanding force fields and how to use them correctly and less so how things need to be done with TopoTools or LAMMPS.the

I just developed the LAMMPS data file for benzaldehyde phenylhydrazone using TopoTools, as shown below. Each partial charge is calculated by involving the electrovalency, electronegativity, both number of bonding and non-bonding electron. I am wondering if that is the way to calculate the charge as in TopoTools.

no. the partial charges need to be determined in accordance with the force field you are using. each force field has different “rules”. TopoTools does not care. Like VMD, TopoTools is for the most part completely agnostic of the force field. It just offers tools to conveniently enter and modify topology related data, plus commands to write out topology files in multiple formats. To produce suitable output files, it has to assume that you have done and correctly entered the forcefield atom typing and bond topology information beforehand.

Subsequently, I try to find out the force field parameter, such as pair_coeff, bond_coeff, angle_coeff, dihedral_coeff, improper_coeff from http://zarbi.chem.yale.edu/ligpargen/. However, the number of dihedral types and improper types are different from those generated by TopoTools.

TopoTools (same as VMD) knows nothing about specific force fields or atom types or types of bonded interactions and how to assign them.
It follows simple rules outlined in the TopoTools documentation. Explaining/discussing those here would be off topic.

Any suggestion would be appreciated.

you are apparently putting the carriage before the horse. not TopoTools discriminates how you have to assign/build a topology but the force field does and TopoTools (and VMD/Tcl scripting) is merely a tool to realize that. As you can see from the examples in the TopoTools tutorials, those need to be adjusted to each specific case and force field.

Please also keep in mind that any command that has “guess” in its name is just that, a (educated) guess (sometimes more educated, sometimes less). The result can be used as a starting point, but you - as the person knowing the force file and having studied the literature - have to correct and improve on that.

Axel.

Dear Axel,