To determine the number of edges in a forest with \({\bf{n}}\) vertices, we require to know the number of trees in the forest.
For example, if we know that a forest contains\({\bf{m}}\) trees and \({\bf{n}}\) vertices.
Let \({{\bf{n}}_{\bf{i}}}\) be the number of vertices in tree \({\bf{i}}\), then \({{\bf{n}}_{\bf{1}}}{\bf{ + }}{{\bf{n}}_{\bf{2}}}{\bf{ + \ldots + }}{{\bf{n}}_{\bf{k}}}{\bf{ = n}}{\bf{.}}\)
Tree \({\bf{i}}\) needs to have \({{\bf{n}}_{\bf{i}}}{\bf{ - 1}}\) edges by part \(\left( {\bf{a}} \right)\) and thus the forest then contains
\(\left( {{{\bf{n}}_{\bf{1}}}{\bf{ - 1}}} \right){\bf{ + }}\left( {{{\bf{n}}_{\bf{2}}}{\bf{ - 1}}} \right){\bf{ + \ldots + }}\left( {{{\bf{n}}_{\bf{m}}}{\bf{ - 1}}} \right){\bf{ = }}\left( {{{\bf{n}}_{\bf{1}}}{\bf{ + }}{{\bf{n}}_{\bf{2}}}{\bf{ + \ldots + }}{{\bf{n}}_{\bf{k}}}} \right){\bf{ - m = n - m}}\) edges.