|
From: David L. <lon...@gm...> - 2009-03-22 22:19:06
|
On Sun, Mar 22, 2009 at 5:08 PM, David Lonie <lon...@gm...> wrote: > I've sent this to both lists, since there seems to be a bug in openbabel, but I noticed and can replicate it in avogadro: > > In libavogadro/src/extensions/vibrationdialog.cpp, add some debug output after the frequencies and intensities are loaded in setMolecule, e.g: > > // OK, we have valid vibrations, so add them to the table > vector<double> frequencies = m_vibrations->GetFrequencies(); > vector<double> intensities = m_vibrations->GetIntensities(); > qDebug() << "size intensities " << intensities.size(); > qDebug() << "size frequencies " << frequencies.size(); > > Recompile and open methane.out in testfiles, then open the vibration extension. Output shows: > > size intensities 12 > size frequencies 9 > > Shouldn't these be the same? > > Dave > I did a bit more digging, and here are the frequencies: 0 1575.73 1 1581.4 2 1584.19 3 1718.85 4 1723.36 5 2710.59 6 2770.6 7 2775.4 8 2778.94 And the intensities: 0 0 1 13.763 2 12.309 3 12.408 4 0 5 0.005 6 0.005 7 0.009 8 0 9 51.922 10 48.934 11 48.648 Those zeros shouldn't be there. In the methane.out file, the vibrational mode data is arranged in three groups of three, so it looks like there is an extra zero being thrown in when each row is being read. This is using the 2.2.x branch of svn openbabel and trunk avogadro. Please cc me if replying on openbabel-discuss, I've not actually joined it ;) Dave |