Write and let be the triangle count in a binomial random graph. For every three-element set of vertices, let be the indicator random variable that its three edges are present. Then
For two distinct triples , their indicator random variables are independent random variables unless they share an edge. Sharing just one vertex still leaves the sets of relevant edges disjoint. If they share an edge, their union has five edges, and therefore
There are unordered pairs of distinct triangles in a graph sharing an edge: choose that edge, and then choose their two additional vertices. The variance of a sum consequently gives the exact formula
For sufficiently large , the hypothesis ensures , so . Dropping negative terms and simplifying the binomial coefficients,
Here as well. The event implies . Applying the Chebyshev inequality from part (i) gives the requested conclusion:
Thus the triangle count is concentrated around its expectation throughout this range of the binomial random graph.
For each unordered triple of distinct vertices, let be the indicator variable that its three edges are present. This is a binomial random graph, so edge independence gives . The triangle count in a binomial random graph is . There are such triples; all are triangles in the complete graph.
The combinatorial maximum and expectation are
The maximum is attainable with positive probability if ; for , the random variable is identically zero. The linearity of expectation requires no independence between different triangle indicators.
The Markov inequality states that for a nonnegative random variable and ,
Because is integer-valued, apply it with . With ,
Therefore
This is the first moment method: if the expected triangle count in a binomial random graph tends to zero, triangles occur with vanishing probability.
Chebyshev inequality states that, for a random variable of finite variance and any ,
Let count triangles, where ranges over the three-element vertex sets and is the corresponding indicator random variable. Then
Two distinct triangle indicators are independent unless their triangles share an edge. There are
unordered pairs sharing an edge, and each covariance is
Therefore
It follows that
when . Chebyshev's inequality now gives
Hence
as summarized by the triangle count in a binomial random graph.
Markov inequality says that a nonnegative random variable satisfies
Chebyshev inequality says that a random variable with finite variance satisfies
Let count triangles in . The triangle count in a binomial random graph calculation gives
Since ,
For sufficiently large , , and Chebyshev inequality gives