[lammps-users] Dynamic Angles, Coulomb Scaling Factor

Hi I've got two questions:

1. In the latest LAMMPS installment scaling factors for coulomb forces have been introduced. Are those expected to be implemented in all Coulomb related forces / energies?

2. Did I overlook a way to have dynamically determined angles? I.e. I want angles between all O-Si-O triplets where O-Si<2.0A or something like that.
If I didn't overlook it I will implement a fix to do that, do you think that would be the appropriate way?

It would work like this:

fix name all dynamic_angles nsteps n_angletypes central_atom_type1 left_atom_type1 distance right_atom_type1 distance ...

i.e. to define O-Si-O angles and Si-O-Si angles (type 1 = Si; type 2 = O)

fix SiOangles all dynamic_angles 100 2 1 2 2.0 2 2.0 2 1 2.0 1 2.0

As far as I see it all relevant data arrays (i.e. neighbor->anglelist) are public, so I can access those from my fix. I need it because I am usually preparing glass samples coming from the melt. As long as I am over or close to the glass transition temperatur the system is reordering considerably so I need to redefine angles every so often. Stopping the simulation and externally redetermining the angles is a pain so I want to implement that internal fix. It would be called every nstep timesteps at the end_of_step. Obviously something similar could be done for bonds (although there is already create bond / break bond), dihedrals and such things.

Cheers
Christian

Comments below.

Steve

Hi I've got two questions:

1. In the latest LAMMPS installment scaling factors for coulomb forces have been introduced. Are those expected to be implemented in all Coulomb related forces / energies?

That was for using that potential with thermodynamic integration via fix adapt.
Is that why you are asking, or for something else?

2. Did I overlook a way to have dynamically determined angles? I.e. I want angles between all O-Si-O triplets where O-Si<2.0A or something like that.
If I didn't overlook it I will implement a fix to do that, do you think that would be the appropriate way?

What do you want to do with a list of dynamically determined angles?
Some kind of statistics
on it? Or a force field? Tersoff and SW do this internally. Within
LAMMPS this is different
than the angle list, which stores permanent angles, and is used by
angle style potentials.
There is no angle-style potential that works on dynamic angles.
That's what Tersoff (or the like) does.

> 1. In the latest LAMMPS installment scaling factors for coulomb forces
have been introduced. Are those expected to be implemented in all Coulomb
related forces / energies?

That was for using that potential with thermodynamic integration via fix
adapt.
Is that why you are asking, or for something else?

I am asking in order to know, if that should be implemented in all pair styles with coulomb or not (for USER-CUDA).

> 2. Did I overlook a way to have dynamically determined angles? I.e. I
want angles between all O-Si-O triplets where O-Si<2.0A or something like
that.
> If I didn't overlook it I will implement a fix to do that, do you think
that would be the appropriate way?

What do you want to do with a list of dynamically determined angles?
Some kind of statistics
on it? Or a force field? Tersoff and SW do this internally. Within
LAMMPS this is different
than the angle list, which stores permanent angles, and is used by
angle style potentials.
There is no angle-style potential that works on dynamic angles.
That's what Tersoff (or the like) does.

Basically my problem is that I want to simulate various glass systems where some potentials types use angle forces as well. Usually I prepare my samples coming from the melt (2500K+) and cooling them done where at some point they do a "computer" glass transition and become solid (typically somewhere betwenn 1000K and 800K). At temperatures below say 600K I could work with fixed angle lists since the glass network is stable but above or close to the glass transition temperature the network rearranges during the cause of my simulations. So I would need to reevaluate which triplets of atoms are forming groups and hence should use angle forces. I need various combinations of pair forces (i.e. buck/coul/long, morse/coul/long [wrote that yesterday], lj/coul/long) with angle forces (harmonic, cosine, cosine/squared). So I thought the best way would be to implement a fix which works on the anglelist in the neighbor class.

Viewed from a physics point of view this is not a totally satisfactory solution since resetting angle assignements only every so often will give jumps in the energy. One would probably want something more like i.e.

cos(phi) ... r<r_inner
[1-(r-r_inner)/(r_outer-r_inner)] ... r_inner<r<r_outer
0 ... r_outer < r

But still just resetting angle assignements every so often could be a valid solution if structural rearrangement is very slow, and if it is happening in (local) bursts of activity. And it would not require introducing loads of new pair styles, or neighborlists for angle styles.

Cheers
Christian

More comments below.

Steve

> 1. In the latest LAMMPS installment scaling factors for coulomb forces
have been introduced. Are those expected to be implemented in all Coulomb
related forces / energies?

That was for using that potential with thermodynamic integration via fix
adapt.
Is that why you are asking, or for something else?

I am asking in order to know, if that should be implemented in all pair styles with coulomb or not (for USER-CUDA).

I would just mirror in USER-CUDA what is written in main LAMMPS.
If a pair style has a Coulomb scale factor, then it should have one in
USER-CUDA.

> 2. Did I overlook a way to have dynamically determined angles? I.e. I
want angles between all O-Si-O triplets where O-Si<2.0A or something like
that.
> If I didn't overlook it I will implement a fix to do that, do you think
that would be the appropriate way?

What do you want to do with a list of dynamically determined angles?
Some kind of statistics
on it? Or a force field? Tersoff and SW do this internally. Within
LAMMPS this is different
than the angle list, which stores permanent angles, and is used by
angle style potentials.
There is no angle-style potential that works on dynamic angles.
That's what Tersoff (or the like) does.

Basically my problem is that I want to simulate various glass systems where some potentials types use angle forces as well. Usually I prepare my samples coming from the melt (2500K+) and cooling them done where at some point they do a "computer" glass transition and become solid (typically somewhere betwenn 1000K and 800K). At temperatures below say 600K I could work with fixed angle lists since the glass network is stable but above or close to the glass transition temperature the network rearranges during the cause of my simulations. So I would need to reevaluate which triplets of atoms are forming groups and hence should use angle forces. I need various combinations of pair forces (i.e. buck/coul/long, morse/coul/long [wrote that yesterday], lj/coul/long) with angle forces (harmonic, cosine, cosine/squared). So I thought the best way would be to implement a fix which works on the anglelist in the neighbor class.

It sounds like you are making up your own potential, in which case you
can do whatever
you want. There are no potentials I know of that use a combination of
fixed and dynamic angles. If a potential has fixed angles, then use
one of the angle_style potentials and the list of fixed angles is stored by
LAMMPS. If they are dynamic (Tersoff, SW, other bond-order potentials),
then I can't see the utility of pre-computing or storing them in a fix. The
pair style needs to check all 3-body interactions dynamically from a full
neighbor list, every timestep. That's what Tersoff, etc does.