crest-lab / crest

CREST - A program for the automated exploration of low-energy molecular chemical space.
https://crest-lab.github.io/crest-docs/
GNU Lesser General Public License v3.0
198 stars 42 forks source link

Cregen always removes the first conformer if its energy is exactly 0 #112

Closed simonaxelrod closed 2 years ago

simonaxelrod commented 2 years ago

Hi there,

Thanks for the fantastic open source program! I've recently noticed a strange bug, where the cregen routine always removes the first conformer in an ensemble if its energy is exactly 0. This doesn't happen when the energy is different from zero. I've attached two folders, each with the same ensembles, but one in which the first conformer has energy 0 ("en_zero.zip"), and one in which all the conformers are shifted by a constant of 0.5 Ha ("en_not_zero.zip"). I'm using crest version 2.11.1. The reference conformer file is conf_0.xyz, and the ensemble file is confs.xyz. The output file is cregen.out, and the command is

/home/saxelrod/apps/crest-2.11.1 conf_0.xyz -cregen confs.xyz -ethr 0.150000 -rthr 0.175000 -bthr 0.030000 -ewin 10000.000000 -enso > cregen.out

Note that this also happens when you use an ensemble with one conformer only.

As seen in the file enso.tags, all conformers remain when the lowest energy is 0.5 Ha, but only conformers 2 and 3 remain when the first conformer has energy 0. The reason seems to be related to clashes, as line 46 in en_zero/cregen.out is "number of removed clashes : 1". Also, while en_zero/enso.tags and en_zero/cregen.out both indicate that conformer 1 is removed, the file en_zero/cregen.enso seems to disagree, as its only line is " ALL UNIQUE".

Thanks!

Simon

en_not_zero.zip en_zero.zip

pprcht commented 2 years ago

Interesting. I think you are correct, that doesn't seem quite right.

Have you checked if this error is also present with versions >2.11.1 ?

simonaxelrod commented 2 years ago

Yep, same thing happens in 2.11.2 (which seems to be the latest version)

pprcht commented 2 years ago

Hi, #113 should take care of that. Turns out, it was a check in CREGEN that removed all structures with energies very close to zero. The routine should now be able to handle relative energies, and ensembles without energies (i.e., sort only based on structural criteria).

simonaxelrod commented 2 years ago

Great, thanks so much!