Theoretical study of the electronic spectra of cyclopentadiene, pyrrole, and furan