# Phonon Bands with LO-TO¶

This example shows how to plot the phonon band structure of AlAs including the LO-TO splitting. See tutorial/lesson_rf2.html

Out:

/Users/gmatteo/git_repos/pymatgen/pymatgen/util/plotting.py:550: UserWarning: Matplotlib is currently using agg, which is a non-GUI backend, so cannot show the figure.
plt.show()


from abipy.abilab import abiopen
import abipy.data as abidata

# Open PHBST file produced by anaddb and extract the phonon bands object.
# (alternatively one can use the shell and abiopen.py OUT_PHBST.nc -nb
# to open the file in a jupyter notebook.
with abiopen(abidata.ref_file("ZnSe_hex_886.out_PHBST.nc")) as ncfile:
phbands = ncfile.phbands

# Phonon frequencies with non analytical contributions, if calculated, are saved
# in the anaddb.nc file produced by anaddb. The results should be fetched from there
# and added to the phonon bands.