%! TEX root = PC.tex
% vim: tw=80 ft=tex
% 15/10/2025 09AM

  We can write
  \begin{align*}
    \Ebb X^2
    &= \sum_{S, T \in [n]^{(3)}} \Pbb(T^{(2)}, S^{(2)} \subset G) \\
    (\Ebb X)^2
    &= \sum_{S, T \in [n]^{(3)}} \Pbb(T^{(2)} \subset G) \Pbb(S^{(2)} \subset G) \\
  \end{align*}
  Since the pairs of events are independent whenever $|S^{(2)} \cap T^{(2)}|
  = 0$, and since $|S^{(2)} \cap T^{(2)}| = 2$ is impossible, we have
  \begin{center}
    \includegraphics[width=0.6\linewidth]{images/c25c922691a04073.png}
  \end{center}
  \begin{align*}
    \Var X
    &\le \sum_{\substack{S, T \in [n]^{(3)} \\ |S^{(2)} \cap T^{(2)}| = 1}}
    \Pbb(S, T \subset G)
    + \sum_{\substack{S, T \in [n]^{(3)} \\ |S^{(2)} \cap T^{(2)}| = 3}}
    \Pbb(S, T \subset G) \\
    &= p^5 n^4 + \Ebb X
  \end{align*}
  Now note
  \begin{align*}
    \Pbb(|X - \Ebb X| \ge \delta \Ebb X)
    &\le \frac{\Var X}{\delta^2 (\Ebb X)^2} \\
    &\le \frac{p^5 n^4}{\delta^2 (\Ebb X)^2}
    + \frac{1}{\delta^2 \Ebb X} \\
    &\le C\frac{p^5 n^4}{(n^3 p^3)^2}
    + \frac{1}{\delta^2 \Ebb X} \\
    &\le C\frac{1}{n^2 p}
    + \frac{1}{\delta^2 \Ebb X} \\
    &\to 0
    \qedhere
  \end{align*}
\end{proof}

\textbf{Recall:} In \cref{lemma:randomindnum} we showed that for $G \sim G(n,
p)$, $\frac{1}{n} \ll p \le \half$, we have
\[
  \indnum(G)
  \le (2 + o(1)) \frac{\log(np)}{p}
\]
with high probability.

\begin{proof}[Proof of \cref{thm:firstr3klowerbound}, a lower bound on $R(3, k)$]
  Set $n = \left( \frac{k}{2\log k} \right)^{3/2}$, $p = n^{-2/3} = \frac{2\log
  k}{k}$.
  Let $G \sim G(n, p)$ and let $\tilde{G}$ be $G$ with a vertex deleted from
  each triangle.
  Then clearly $\indnum(\tilde{G}) \le \indnum(G)$, so with high probability we
  have
  \begin{align*}
    \indnum(\tilde{G})
    &\le \indnum(G) \\
    &\le (2 + o(1)) \frac{\log np}{p} \\
    &\le \left( \frac{2}{3} + o(1) \right) n^{2/3} \log n \\
    &\le \left( \frac{2}{3} + o(1) \right) \frac{k}{2\log k} (\log k^{3/2}) \\
    &\le \left(1 + o(1)\right) \frac{k}{2} \\
    &< k
    \tag{$*$}
    \label{lec3eq1}
  \end{align*}
  We also have with high probability:
  \begin{align*}
    |V(\tilde{G})|
    &\ge n - (\#\text{of triangles in $G$}) \\
    &\ge n - (1 + o(1)) \frac{p^3 n^3}{6} \\
    &= n - (1 + o(1)) \frac{n}{6} \\
    &\ge \frac{n}{2}
    \tag{$**$}
    \label{lec3eq2}
  \end{align*}
  So with high probability \eqref{lec3eq1} and \eqref{lec3eq2} hold (if
  \eqref{lec3eq1} holds with probability at least $1 - \eps_1$ and
  \eqref{lec3eq2} holds with probability at least $1 - \eps_2$, then the
  probability that they both hold is at least $1 - \eps_1 - \eps_2 \to 1$).
  So there must exist a graph $\tilde{G}$ on $\frac{n}{2} = \half \left(
  \frac{k}{2\log k} \right)^{3 / 2}$ vertices with no triangles and independence
  number $< k$.
\end{proof}

\begin{definition*}[Chromatic number]
  Let $G$ be a graph.
  The chromatic number of $G$ is the minimum $k$ such that there exists $\chi :
  V(G) \to [k]$ such that no edge has both ends in the same colour.
  \begin{center}
    \includegraphics[width=0.3\linewidth]{images/43911b45218549c4.png}
  \end{center}
  $\chi(G)$ denotes the chromatic number.
\end{definition*}

\begin{fcdefn}[Girth]
  The \emph{girth} of a graph $G$ is the length of the shortest cycle in $G$.
\end{fcdefn}

Using a method similar to the proof of \cref{thm:firstr3klowerbound} that we
just saw, Erdős proved:

\begin{theorem*}[Erdős]
  There exist graphs $G$ with arbitrarily large chromatic number and arbitrarily
  large girth, i.e. for all $g, k \in \Nbb$ there exists $G$ with girth $> g$
  and $\chi(G) > k$.
\end{theorem*}

This theorem is somewhat surprising, because if you think of examples of graphs
with large chromatic number, the first things you try have small girth (for
example, $K_n$).
It shows that the answer to the question ``what kind of necessary conditions are
there for chromatic number to be large?'' is not so simple.

\newpage
\section{An edge deletion method}

In this section, we'll improve the lower bound on $R(3, k)$ that we proved in
\cref{thm:firstr3klowerbound}.

Idea: let's delete an \emph{edge} from each triangle, instead of a vertex (we
have a lot more edges to spend than we have vertices!). ``The vertex set is our
most expensive real estate.''

\begin{center}
  \includegraphics[width=0.6\linewidth]{images/b833a09e8e084e34.png}
\end{center}

For this we want
\[
  p^3 n^3
  \ll pn^2
\]
so $p = \frac{\gamma}{\sqrt{n}}$.
For some small $\gamma > 0$.

\textbf{Danger:} when we delete an edge from each triangle, we need to ensure that
we don't hurt $\indnum(G)$.

\begin{fcthm}[Erdos, 1960s]
  \label{thm:r3kedgedeletion}
  $R(3, k) \ge c \frac{k^2}{(\log k)^2}$
  for some $c > 0$.
\end{fcthm}

Since we already saw $R(3, k) \le k^2$ in \cref{coro:trivialr3kupperbound}
(which followed from \nameref{thm:erdosszekeres}), this theorem now tells us
the polynomial order of $R(3, k)$ (up to poly-logs).

% To prove this, it is enough to prove for sufficiently large $n$ that there
% exists a triangle free graph on $n$ vertices with
% \[
%   \indnum(G)
%   \le C n^{\half} \log n
% \]
% for some $C > 0$.
% Note that we only have to deal with ``sufficiently large'' $n$ because once we
% have this, we can just adjust the value of $c$ to handle the small values of
% $n$.

To prove this, it is enough to prove the following:

\begin{fcthm}[]
  \label{thm:r3kedgedeletionsuffices}
  There exists a constant $C$ such that for all $n \ge 2$, there exists a
  triangle-free graph $G$ on $n$ vertices with
  \[
    \indnum(G)
    \le C\sqrt{n} \log n
  .\]
\end{fcthm}

\begin{proof}[Proof of \cref{thm:r3kedgedeletion} from \cref{thm:r3kedgedeletionsuffices}]
  Set $k = C\sqrt{n} \log n$, and then get $n = c \frac{k^2}{(\log k)^2}$.
\end{proof}

When proving \cref{thm:r3kedgedeletionsuffices}, note that we only have to prove
it for large $n$, because then we can just adjust our value of $C$ to make the
result also true for small $n$.

% More sketching of the idea:
Now we sketch the idea of \cref{thm:r3kedgedeletionsuffices}:
we know $\indnum(G) \le 2 \frac{\log n}{p}$.

What if $k > 2 \frac{\log np}{p}$?
Then there must be an edge (because $\indnum(G) < k$.
\begin{center}
  \includegraphics[width=0.6\linewidth]{images/fa2a320512db4adc.png}
\end{center}
Not very impressive.

What if $k > 100 \frac{\log np}{p}$?
Then we actually get a lot of edges: expect $pk^2$, and can guarantee
$\frac{pk^2}{16}$.

\begin{fclemma}[]
  \label{lemma:bighasmanyedges}
  Assuming:
  - $\frac{1}{n} \ll p \le \half$
  - $G \sim G(n, p)$
  - $k > C \frac{\log n}{p}$
  Then:
  with high probability every set of size $\ge k$ in $G$ induces
  at least $\frac{pk^2}{16}$ edges.
\end{fclemma}

This lemma will be used to show that we can delete an edge from every triangle
without increasing the independence number of our graph too much, but we will
see later that a small trick is needed before we can apply this.
