When an electron is ejected from a metal surface it has kinetic energy. The amount of kinetic energy the electron has depends on the difference between the energy of the photon and the work function of the metal.
The kinetic energy of the electron is equal to the energy of the photon minus the work function of the metal. This is shown by the equation:
\(E_{k}=E-W\)
In this equation:
\(E_{k}\) is the kinetic energy of the electron
\(E\) is the energy of the photon
\(W\) is the work function of the metal
As \(E=hf\) and \(W=hf_{o}\), this means that the equation can also be written as: