I admit this is confusing, and we should try to make the next version of VNL produce a script which labels the states according to the quantum numbers.
To "fix" this manually, you can modify the last bit of the code slightly, by hand:
######################################################################
# Calculate physical properties
######################################################################
quantum_numbers = (14,15)
eigenstates = calculateEigenstates(
self_consistent_calculation = scf,
quantum_numbers = quantum_numbers
)
for state_index,state in enumerate(eigenstates):
label='Eigenstate'+' '+str(quantum_numbers[state_index])
if processIsMaster(): file.addToSample(state, 'molecule_configuration', label)
This will make it easier to identify the states in the Result Browser (or, rather, in the Nanoscope) when you plot them.
An xyz file should look like
First line: number of atoms (so, 17 in your case)
Second line: some comment
Third to last line: Element symbol x y z (in Angstrom)
Like so:
17
my molecule
N -4.056579 -0.069489 2.250744
...
Try this.
import sys
from NL.ScienceUtilities import PeriodicTable as P
fname = sys.argv[2]
f = open(fname,'r')
lines = f.readlines()
new_lines = []
for i in range(len(lines)):
tmp = lines[i].strip().split()
if len(tmp)>0:
new_lines.append(tmp)
print len(new_lines)
print 'XYZ file converted from',fname
for line in new_lines:
print P.__all_elements[int(line[1])-1].symbol(),
print line[3],line[4],line[5]
Save as "convert.py", then run
atk convert.py myfile > newfile.xyz
Here "myfile" should have the format indicated above, but without the extra 3 lines at the top, that is only the lines with coordinates.