Dear Axel,
hi michael,
You replied to my email before regarding creating input files for LAMMPS
and directed me towards your topotools scripts.
You said you could provide me with an example input script for this
which would be useful.
ok. i will send this to you in a separate mail. no need to spam
the list with unfinished code.
At the moment when I load my amorphous system into VMD and write the
LAMMPS data, its outputs list of atoms and xyz coords, and a list of bonds.
But it produces no information on the angles or dihedrals in the system.
I tried the guessangles / guessdihedrals commands but it doesn't seem to
do anything.
well, it _does_ do something, the question is how you determine
that it doesn't work. but without any more specific details or
a way to reproduce what you did, it is difficult to explain what
went wrong. "it doesn't work" or "it has no effect" is pretty much
useless without the context.
Would I just have to start with a single molecule, assign these
parameters manually and then replicate the molecule to build up my
amorphous system, or is there an alternative way of generating a list of
all the bonds, angles, dihedrals and impropers from a starting xyz
coordinates.
if you are working with classical forcefields you have to keep in mind,
that the topology (atom type, bonding patterns, angles, and so on) and
the coordinates can be processed independently, for as long as the
identity of atoms is preserved. so if you have the bonding for one
molecule, you can replicate it easily. in VMD you'd do something like
the following (this is off the top of my head, so please excuse typos):
package require topotools 1.0
set mol1 [topo readlammpsdata full data.single]
set sel1 [atomselect $mol1 all]
set mol2 [mol new bulk.xyz]
set sel2 [atomselect $mol2 all]
set nmols [expr {[$sel2 num] / [$sel1 num]}]
set atoms [$sel1 num]
set oldbonds [topo getbondlist type -molid $mol1 -sel $sel1]
set newbonds {}
for {set i 0} {$i < $nmols} {incr i} {
set offs [expr {$i*$atoms}]
foreach b $oldbonds {
lassign $b b1 b2 t
lappend newbonds [list [expr {$b1+$offs}] [expr {$b2+$offs}] $t]
}
}
topo setbondlist type -molid $mol2 -sel $sel2
you can add similar loops for angles, dihedrals, impropers as needed.
the example script that i'm going to send you will instead grab the
single molecule information from a data base file. the principle is
always the same, though.
HTH,
axel.