We develop a simulation to facilitate the teaching of the photoelectric effect in an introductory
course on quantum mechanics at undergraduate level. Through a Visual Basic program we describe the
interaction of light with electrons in a metal conductor in the phenomenon according to the
classical theory. The description includes both the microscopic interaction, as well as the
predictions of the theory for the experimental results, arising from the microscopic scale. The
predictions of the classical model are in stark contrast with the experimental results of a real
photoelectric device.