<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://tcs.nju.edu.cn/wiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Etone</id>
	<title>TCS Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://tcs.nju.edu.cn/wiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Etone"/>
	<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Special:Contributions/Etone"/>
	<updated>2026-05-04T22:24:26Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.45.3</generator>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/The_probabilistic_method&amp;diff=13641</id>
		<title>组合数学 (Fall 2026)/The probabilistic method</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/The_probabilistic_method&amp;diff=13641"/>
		<updated>2026-04-17T13:18:44Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;== The Probabilistic Method == The probabilistic method provides another way of proving the existence of objects: instead of explicitly constructing an object, we define a probability space of objects in which the probability is positive that a randomly selected object has the required property.  The basic principle of the probabilistic method is very simple, and can be stated in intuitive ways: *If an object chosen randomly from a universe satisfies a property with posi...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== The Probabilistic Method ==&lt;br /&gt;
The probabilistic method provides another way of proving the existence of objects: instead of explicitly constructing an object, we define a probability space of objects in which the probability is positive that a randomly selected object has the required property.&lt;br /&gt;
&lt;br /&gt;
The basic principle of the probabilistic method is very simple, and can be stated in intuitive ways:&lt;br /&gt;
*If an object chosen randomly from a universe satisfies a property with positive probability, then there must be an object in the universe that satisfies that property.&lt;br /&gt;
:For example, for a ball(the object) randomly chosen from a box(the universe) of balls, if the probability that the chosen ball is blue(the property) is &amp;gt;0, then there must be a blue ball in the box.&lt;br /&gt;
*Any random variable assumes at least one value that is no smaller than its expectation, and at least one value that is no greater than the expectation.&lt;br /&gt;
:For example, if we know the average height of the students in the class is &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt;, then we know there is a students whose height is at least &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt;, and there is a student whose height is at most &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Although the idea of  the probabilistic method is simple, it provides us a powerful tool for existential proof.&lt;br /&gt;
&lt;br /&gt;
===Ramsey number===&lt;br /&gt;
&lt;br /&gt;
Recall the Ramsey theorem which states that in a meeting of at least six people, there are either three people knowing each other or three people not knowing each other. In graph theoretical terms, this means that no matter how we color the edges of &amp;lt;math&amp;gt;K_6&amp;lt;/math&amp;gt; (the complete graph on six vertices), there must be a &#039;&#039;&#039;monochromatic&#039;&#039;&#039; &amp;lt;math&amp;gt;K_3&amp;lt;/math&amp;gt; (a triangle whose edges have the same color).&lt;br /&gt;
&lt;br /&gt;
Generally, the &#039;&#039;&#039;Ramsey number&#039;&#039;&#039; &amp;lt;math&amp;gt;R(k,\ell)&amp;lt;/math&amp;gt; is the smallest integer &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; such that in any two-coloring of the edges of a complete graph on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; by red and blue, either there is a red &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt; or there is a blue &amp;lt;math&amp;gt;K_\ell&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Ramsey showed in 1929 that &amp;lt;math&amp;gt;R(k,\ell)&amp;lt;/math&amp;gt; is finite for any &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt;. It is extremely hard to compute the exact value of &amp;lt;math&amp;gt;R(k,\ell)&amp;lt;/math&amp;gt;. Here we give a lower bound of &amp;lt;math&amp;gt;R(k,k)&amp;lt;/math&amp;gt; by the probabilistic method.&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Theorem (Erdős 1947)|&lt;br /&gt;
:If &amp;lt;math&amp;gt;{n\choose k}\cdot 2^{1-{k\choose 2}}&amp;lt;1&amp;lt;/math&amp;gt; then it is possible to color the edges of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; with two colors so that there is no monochromatic &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt; subgraph.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof| Consider a random two-coloring of edges of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; obtained as follows:&lt;br /&gt;
* For each edge of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt;, independently flip a fair coin to decide the color of the edge.&lt;br /&gt;
&lt;br /&gt;
For any fixed set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; vertices, let &amp;lt;math&amp;gt;\mathcal{E}_S&amp;lt;/math&amp;gt; be the event that the &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt; subgraph induced by &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is monochromatic. There are &amp;lt;math&amp;gt;{k\choose 2}&amp;lt;/math&amp;gt; many edges in &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt;, therefore&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[\mathcal{E}_S]=2\cdot 2^{-{k\choose 2}}=2^{1-{k\choose 2}}.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Since there are &amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt; possible choices of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;, by the union bound&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr[\exists S, \mathcal{E}_S]\le {n\choose k}\cdot\Pr[\mathcal{E}_S]={n\choose k}\cdot 2^{1-{k\choose 2}}.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Due to the assumption, &amp;lt;math&amp;gt;{n\choose k}\cdot 2^{1-{k\choose 2}}&amp;lt;1&amp;lt;/math&amp;gt;, thus there exists a two coloring that none of &amp;lt;math&amp;gt;\mathcal{E}_S&amp;lt;/math&amp;gt; occurs, which means  there is no monochromatic &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt; subgraph.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
For &amp;lt;math&amp;gt;k\ge 3&amp;lt;/math&amp;gt; and we take &amp;lt;math&amp;gt;n=\lfloor2^{k/2}\rfloor&amp;lt;/math&amp;gt;, then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
{n\choose k}\cdot 2^{1-{k\choose 2}}&lt;br /&gt;
&amp;amp;&amp;lt;&lt;br /&gt;
\frac{n^k}{k!}\cdot\frac{2^{1+\frac{k}{2}}}{2^{k^2/2}}\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
\frac{2^{k^2/2}}{k!}\cdot\frac{2^{1+\frac{k}{2}}}{2^{k^2/2}}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{2^{1+\frac{k}{2}}}{k!}\\&lt;br /&gt;
&amp;amp;&amp;lt;1.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
By the above theorem, there exists a two-coloring of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; that there is no monochromatic &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt;. Therefore, the Ramsey number &amp;lt;math&amp;gt;R(k,k)&amp;gt;\lfloor2^{k/2}\rfloor&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;k\ge 3&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
===Tournament===&lt;br /&gt;
A &#039;&#039;&#039;[http://en.wikipedia.org/wiki/Tournament_(graph_theory) tournament]&#039;&#039;&#039; (竞赛图) on a set &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; players is an &#039;&#039;&#039;orientation&#039;&#039;&#039; of the edges of the complete graph on the set of vertices &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt;. Thus for every two distinct vertices &amp;lt;math&amp;gt;u,v&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt;, either &amp;lt;math&amp;gt;(u,v)\in E&amp;lt;/math&amp;gt; or &amp;lt;math&amp;gt;(v,u)\in E&amp;lt;/math&amp;gt;, but not both.&lt;br /&gt;
&lt;br /&gt;
We can think of the set &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt; as a set of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; players in which each pair participates in a single match, where &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt; is in the tournament iff player &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt; beats player &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Definition|&lt;br /&gt;
:We say that a tournament has &#039;&#039;&#039;&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-paradoxical&#039;&#039;&#039; if for every set of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; players there is a player who beats them all.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Is it true for every finite &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;, there is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-paradoxical tournament (on more than &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; vertices, of course)? This problem was first raised by Schütte, and as shown by Erdős, can be solved almost trivially by the probabilistic method.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem (Erdős 1963)|&lt;br /&gt;
:If &amp;lt;math&amp;gt;{n\choose k}\left(1-2^{-k}\right)^{n-k}&amp;lt;1&amp;lt;/math&amp;gt; then there is a tournament on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices that is &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-paradoxical.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Consider a uniformly random tournament &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; on the set &amp;lt;math&amp;gt;V=[n]&amp;lt;/math&amp;gt;. For every fixed subset &amp;lt;math&amp;gt;S\in{V\choose k}&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; vertices, let &amp;lt;math&amp;gt;A_S&amp;lt;/math&amp;gt; be the event defined as follows&lt;br /&gt;
:&amp;lt;math&amp;gt;A_S:\,&amp;lt;/math&amp;gt; there is no vertex in &amp;lt;math&amp;gt;V\setminus S&amp;lt;/math&amp;gt; that beats all vertices in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
In a uniform random tournament, the orientations of edges are independent. For any &amp;lt;math&amp;gt;u\in V\setminus S&amp;lt;/math&amp;gt;,&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[u\mbox{ beats all }v\in S]=2^{-k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
Therefore, &amp;lt;math&amp;gt;\Pr[u\mbox{ does not beats all }v\in S]=1-2^{-k}&amp;lt;/math&amp;gt; and&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[A_S]=\prod_{u\in V\setminus S}\Pr[u\mbox{ does not beats all }v\in S]=(1-2^{-k})^{n-k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
It follows that&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr\left[\bigvee_{S\in{V\choose k}}A_S\right]\le \sum_{S\in{V\choose k}}\Pr[A_S]={n\choose k}(1-2^{-k})^{n-k}&amp;lt;1.&amp;lt;/math&amp;gt;&lt;br /&gt;
Therefore,&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[\,T\mbox{ is }k\mbox{-paradoxical }]=\Pr\left[\bigwedge_{S\in{V\choose k}}\overline{A_S}\right]=1-\Pr\left[\bigvee_{S\in{V\choose k}}A_S\right]&amp;gt;0.&amp;lt;/math&amp;gt; &lt;br /&gt;
There is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-paradoxical tournament.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Linearity of expectation ===&lt;br /&gt;
Let &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; be a discrete &#039;&#039;&#039;random variable&#039;&#039;&#039;.  The expectation of &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; is defined as follows.&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Definition (Expectation)|&lt;br /&gt;
:The &#039;&#039;&#039;expectation&#039;&#039;&#039; of a discrete random variable &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;, denoted by &amp;lt;math&amp;gt;\mathbf{E}[X]&amp;lt;/math&amp;gt;, is given by&lt;br /&gt;
::&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
\mathbf{E}[X] &amp;amp;= \sum_{x}x\Pr[X=x],&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
:where the summation is over all values &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; in the range of &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
A fundamental fact regarding the expectation is its &#039;&#039;&#039;linearity&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Theorem (Linearity of Expectations)|&lt;br /&gt;
:For any discrete random variables &amp;lt;math&amp;gt;X_1, X_2, \ldots, X_n&amp;lt;/math&amp;gt;, and any real constants &amp;lt;math&amp;gt;a_1, a_2, \ldots, a_n&amp;lt;/math&amp;gt;,&lt;br /&gt;
::&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
\mathbf{E}\left[\sum_{i=1}^n a_iX_i\right] &amp;amp;= \sum_{i=1}^n a_i\cdot\mathbf{E}[X_i].&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
;Hamiltonian paths&lt;br /&gt;
The following result of Szele in 1943 is often considered the first use of the probabilistic method.&lt;br /&gt;
{{Theorem|Theorem (Szele 1943)|&lt;br /&gt;
:There is a tournament on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; players with at least &amp;lt;math&amp;gt;n!2^{-(n-1)}&amp;lt;/math&amp;gt; Hamiltonian paths.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Consider the uniform random tournament &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; on &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt;. For any permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;X_{\pi}&amp;lt;/math&amp;gt; be the indicator random variable defined as &lt;br /&gt;
:&amp;lt;math&amp;gt;X_{\pi}=\begin{cases}&lt;br /&gt;
1 &amp;amp; \forall i\in[n-1], (\pi_i,\pi_{i+1})\in T,\\&lt;br /&gt;
0 &amp;amp; \mbox{otherwise}.&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
In other words, &amp;lt;math&amp;gt;X_{\pi}&amp;lt;/math&amp;gt; indicates whether &amp;lt;math&amp;gt;\pi_0\rightarrow\pi_1\rightarrow\pi_2\rightarrow\cdots\rightarrow\pi_{n-1}&amp;lt;/math&amp;gt; gives a Hamiltonian path. &lt;br /&gt;
It holds that&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathrm{E}[X_\pi]=1\cdot\Pr[X_\pi=1]+0\cdot\Pr[X_\pi=0]=\Pr[\forall i\in[n-1], (\pi_i,\pi_{i+1})\in T]=2^{-(n-1)}.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;X=\sum_{\pi:\text{permutation of }[n]}X_\pi\,&amp;lt;/math&amp;gt;. Clearly &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; is the number of Hamiltonian paths in the tournament &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;. &lt;br /&gt;
Due to the linearity of expectation,&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathrm{E}[X]=\mathrm{E}\left[\sum_{\pi:\text{permutation of }[n]}X_\pi\right]=\sum_{\pi:\text{permutation of }[n]}\mathrm{E}[X_\pi]=n!2^{-(n-1)}.&amp;lt;/math&amp;gt;&lt;br /&gt;
This is the average number of Hamiltonian paths in a tournament, where the average is taken over all tournaments.&lt;br /&gt;
Thus some tournament has at least &amp;lt;math&amp;gt;n!2^{-(n-1)}&amp;lt;/math&amp;gt; Hamiltonian paths.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
===Independent sets===&lt;br /&gt;
An independent set of a graph is a set of vertices with no edges between them. The following theorem gives a lower bound on the size of the largest independent set.&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Theorem|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt; be a graph on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices with &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; edges. Then &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; has an independent set with at least &amp;lt;math&amp;gt;\frac{n^2}{4m}&amp;lt;/math&amp;gt; vertices.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof| Let &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; be a set of vertices constructed as follows:&lt;br /&gt;
:For each vertex &amp;lt;math&amp;gt;v\in V&amp;lt;/math&amp;gt;:&lt;br /&gt;
:* &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; is included in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; independently with probability &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt;,&lt;br /&gt;
&amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; to be determined.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;X=|S|&amp;lt;/math&amp;gt;. It is obvious that &amp;lt;math&amp;gt;\mathbf{E}[X]=np&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For each edge &amp;lt;math&amp;gt;e\in E&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;Y_{e}&amp;lt;/math&amp;gt; be the random variable which indicates whether both endpoints of &amp;lt;math&amp;gt;e=uv&amp;lt;/math&amp;gt; are in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;.&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\mathbf{E}[Y_{uv}]=\Pr[u\in S\wedge v\in S]=p^2.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Let &amp;lt;math&amp;gt;Y&amp;lt;/math&amp;gt; be the number of edges in the subgraph of &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; induced by &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;. It holds that &amp;lt;math&amp;gt;Y=\sum_{e\in E}Y_e&amp;lt;/math&amp;gt;. By linearity of expectation,&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbf{E}[Y]=\sum_{e\in E}\mathbf{E}[Y_e]=mp^2&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Note that although &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is not necessary an independent set, it can be modified to one if for each edge &amp;lt;math&amp;gt;e&amp;lt;/math&amp;gt; of the induced subgraph &amp;lt;math&amp;gt;G(S)&amp;lt;/math&amp;gt;, we delete one of the endpoint of &amp;lt;math&amp;gt;e&amp;lt;/math&amp;gt; from &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;. Let &amp;lt;math&amp;gt;S^*&amp;lt;/math&amp;gt; be the resulting set. It is obvious that &amp;lt;math&amp;gt;S^*&amp;lt;/math&amp;gt; is an independent set since there is no edge left in the induced subgraph &amp;lt;math&amp;gt;G(S^*)&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Since there are &amp;lt;math&amp;gt;Y&amp;lt;/math&amp;gt; edges in &amp;lt;math&amp;gt;G(S)&amp;lt;/math&amp;gt;, there are at most &amp;lt;math&amp;gt;Y&amp;lt;/math&amp;gt; vertices in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; are deleted to make it become &amp;lt;math&amp;gt;S^*&amp;lt;/math&amp;gt;. Therefore, &amp;lt;math&amp;gt;|S^*|\ge X-Y&amp;lt;/math&amp;gt;. By linearity of expectation,&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\mathbf{E}[|S^*|]\ge\mathbf{E}[X-Y]=\mathbf{E}[X]-\mathbf{E}[Y]=np-mp^2.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
The expectation is maximized when &amp;lt;math&amp;gt;p=\frac{n}{2m}&amp;lt;/math&amp;gt;, thus&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\mathbf{E}[|S^*|]\ge n\cdot\frac{n}{2m}-m\left(\frac{n}{2m}\right)^2=\frac{n^2}{4m}.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
There exists an independent set which contains at least &amp;lt;math&amp;gt;\frac{n^2}{4m}&amp;lt;/math&amp;gt; vertices.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Coloring large-girth graphs ==&lt;br /&gt;
The girth of a graph is the length of the shortest cycle of the graph.&lt;br /&gt;
{{Theorem|Definition|&lt;br /&gt;
Let &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt; be an undirected graph.&lt;br /&gt;
* A &#039;&#039;&#039;cycle&#039;&#039;&#039; of length &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; is a sequence of distinct vertices &amp;lt;math&amp;gt;v_1,v_2,\ldots,v_{k}&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;v_iv_{i+1}\in E&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;i=1,2,\ldots,k-1&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;v_kv_1\in E&amp;lt;/math&amp;gt;.&lt;br /&gt;
* The &#039;&#039;&#039;girth&#039;&#039;&#039; of &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;, dented &amp;lt;math&amp;gt;g(G)&amp;lt;/math&amp;gt;, is the length of the shortest cycle in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The chromatic number of a graph is the minimum number of colors with which the graph can be &#039;&#039;properly&#039;&#039; colored.&lt;br /&gt;
{{Theorem|Definition (chromatic number)|&lt;br /&gt;
* The &#039;&#039;&#039;chromatic number&#039;&#039;&#039; of &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;, denoted &amp;lt;math&amp;gt;\chi(G)&amp;lt;/math&amp;gt;, is the minimal number of colors which we need to color the vertices of &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; so that no two adjacent vertices have the same color. Formally,&lt;br /&gt;
::&amp;lt;math&amp;gt;\chi(G)=\min\{C\in\mathbb{N}\mid \exists f:V\rightarrow[C]\mbox{ such that }\forall uv\in E, f(u)\neq f(v)\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
In 1959, Erdős proved the following theorem: for any fixed &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt;, there exists a finite graph with girth at least &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; and chromatic number at least &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt;. This is considered a striking example of the probabilistic method. The statement of the theorem itself calls for nothing about probability or randomness. And the result is highly contra-intuitive: if the girth is large there is no simple reason why the graph could not be colored with a few colors. We can always &amp;quot;locally&amp;quot; color a cycle with 2 or 3 colors. Erdős&#039; result shows that there are &amp;quot;global&amp;quot; restrictions for coloring, and although such configurations are very difficult to explicitly construct, with the probabilistic method, we know that they commonly exist.&lt;br /&gt;
&lt;br /&gt;
{{Theorem| Theorem (Erdős 1959)|&lt;br /&gt;
: For all &amp;lt;math&amp;gt;k,\ell&amp;lt;/math&amp;gt; there exists a graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;g(G)&amp;gt;\ell&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\chi(G)&amp;gt;k\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
It is very hard to directly analyze the chromatic number of a graph. We find that the chromatic number can be related to the size of the maximum independent set.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Definition (independence number)|&lt;br /&gt;
* The &#039;&#039;&#039;independence number&#039;&#039;&#039; of &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;, denoted &amp;lt;math&amp;gt;\alpha(G)&amp;lt;/math&amp;gt;, is the size of the largest independent set in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;. Formally,&lt;br /&gt;
::&amp;lt;math&amp;gt;\alpha(G)=\max\{|S|\mid S\subseteq V\mbox{ and }\forall u,v\in S, uv\not\in E\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
We observe the following relationship between the chromatic number and the independence number.&lt;br /&gt;
{{Theorem|Lemma|&lt;br /&gt;
:For any &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-vertex graph,&lt;br /&gt;
::&amp;lt;math&amp;gt;\chi(G)\ge\frac{n}{\alpha(G)}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
*In the optimal coloring, &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices are partitioned into &amp;lt;math&amp;gt;\chi(G)&amp;lt;/math&amp;gt; color classes according to the vertex color.&lt;br /&gt;
*Every color class is an independent set, or otherwise there exist two adjacent vertice with the same color.&lt;br /&gt;
*By the pigeonhole principle, there is a color class (hence an independent set) of size &amp;lt;math&amp;gt;\frac{n}{\chi(G)}&amp;lt;/math&amp;gt;. Therefore, &amp;lt;math&amp;gt;\alpha(G)\ge\frac{n}{\chi(G)}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The lemma follows.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Therefore, it is sufficient to prove that &amp;lt;math&amp;gt;\alpha(G)\le\frac{n}{k}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;g(G)&amp;gt;\ell&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Prooftitle|Proof of Erdős theorem|&lt;br /&gt;
Fix &amp;lt;math&amp;gt;\theta&amp;lt;\frac{1}{\ell}&amp;lt;/math&amp;gt;. Let &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; be &amp;lt;math&amp;gt;G(n,p)&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;p=n^{\theta-1}&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
For any length-&amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; simple cycle &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;X_\sigma&amp;lt;/math&amp;gt; be the indicator random variable such that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
X_\sigma=&lt;br /&gt;
\begin{cases}&lt;br /&gt;
1 &amp;amp; \sigma\mbox{ is a cycle in }G,\\&lt;br /&gt;
0 &amp;amp; \mbox{otherwise}.&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The number of cycles of length at most &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt; in graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; is &lt;br /&gt;
:&amp;lt;math&amp;gt;X=\sum_{i=3}^\ell\sum_{\sigma:i\text{-cycle}}X_\sigma&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For any particular length-&amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; simple cycle &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;,&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbf{E}[X_\sigma]=\Pr[X_\sigma=1]=\Pr[\sigma\mbox{ is a cycle in }G]=p^i=n^{\theta i-i}&amp;lt;/math&amp;gt;.&lt;br /&gt;
For any &amp;lt;math&amp;gt;3\le i\le n&amp;lt;/math&amp;gt;, the number of length-&amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; simple cycle is &amp;lt;math&amp;gt;\frac{n(n-1)\cdots (n-i+1)}{2i}&amp;lt;/math&amp;gt;. By the linearity of expectation,&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbf{E}[X]=\sum_{i=3}^\ell\sum_{\sigma:i\text{-cycle}}\mathbf{E}[X_\sigma]=\sum_{i=3}^\ell\frac{n(n-1)\cdots (n-i+1)}{2i}n^{\theta i-i}\le \sum_{i=3}^\ell\frac{n^{\theta i}}{2i}=o(n)&amp;lt;/math&amp;gt;.&lt;br /&gt;
Applying Markov&#039;s inequality,&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[X\ge \frac{n}{2}\right]\le\frac{\mathbf{E}[X]}{n/2}=o(1).&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Therefore, with high probability the random graph has less than &amp;lt;math&amp;gt;n/2&amp;lt;/math&amp;gt; short cycles.&lt;br /&gt;
&lt;br /&gt;
Now we proceed to analyze the independence number. Let &amp;lt;math&amp;gt;m=\left\lceil\frac{3\ln n}{p}\right\rceil&amp;lt;/math&amp;gt;, so that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr[\alpha(G)\ge m]&lt;br /&gt;
&amp;amp;\le\Pr\left[\exists S\in{V\choose m}\forall \{u,v\}\in{S\choose 2}, uv\not\in G\right]\\&lt;br /&gt;
&amp;amp;\le{n\choose m}(1-p)^{m\choose 2}\\&lt;br /&gt;
&amp;amp;&amp;lt;n^m\mathrm{e}^{-p{m\choose 2}}\\&lt;br /&gt;
&amp;amp;=\left(n\mathrm{e}^{-p(m-1)/2}\right)^m=o(1)&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
The probability that either of the above events occurs is &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr\left[X\ge\frac{n}{2}\vee \alpha(G)\ge m\right]&lt;br /&gt;
\le \Pr\left[X\ge \frac{n}{2}\right]+\Pr\left[\alpha(G)\ge m\right]&lt;br /&gt;
=o(1).&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Therefore, there exists a graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; with less than &amp;lt;math&amp;gt;n/2&amp;lt;/math&amp;gt; &amp;quot;short&amp;quot; cycles, i.e., cycles of length at most &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt;, and with &amp;lt;math&amp;gt;\alpha(G)&amp;lt;m\le 3n^{1-\theta}\ln n&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Take each &amp;quot;short&amp;quot; cycle in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; and remove a vertex from the cycle (and also remove all adjacent edges to the removed vertex). This gives a graph &amp;lt;math&amp;gt;G&#039;&amp;lt;/math&amp;gt; which has no short cycles, hence the girth &amp;lt;math&amp;gt;g(G&#039;)\ge\ell&amp;lt;/math&amp;gt;. And &amp;lt;math&amp;gt;G&#039;&amp;lt;/math&amp;gt; has at least &amp;lt;math&amp;gt;n/2&amp;lt;/math&amp;gt; vertices, because at most &amp;lt;math&amp;gt;n/2&amp;lt;/math&amp;gt; vertices are removed.&lt;br /&gt;
&lt;br /&gt;
Notice that removing vertices cannot makes &amp;lt;math&amp;gt;\alpha(G)&amp;lt;/math&amp;gt; grow. It holds that &amp;lt;math&amp;gt;\alpha(G&#039;)\le\alpha(G)&amp;lt;/math&amp;gt;. Thus&lt;br /&gt;
:&amp;lt;math&amp;gt;\chi(G&#039;)\ge\frac{n/2}{\alpha(G&#039;)}\ge\frac{n}{2m}\ge\frac{n^\theta}{6\ln n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
The theorem is proved by taking &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; sufficiently large so that this value is greater than &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The proof contains a very simple procedure which for any &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt; &#039;&#039;generates&#039;&#039; such a graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;g(G)&amp;gt;\ell&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\chi(G)&amp;gt;k&amp;lt;/math&amp;gt;. The procedure is as such:&lt;br /&gt;
* Fix some &amp;lt;math&amp;gt;\theta&amp;lt;\frac{1}{\ell}&amp;lt;/math&amp;gt;. Choose sufficiently large &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;\frac{n^\theta}{6\ln n}&amp;gt;k&amp;lt;/math&amp;gt;, and let &amp;lt;math&amp;gt;p=n^{\theta-1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
* Generate a random graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; as &amp;lt;math&amp;gt;G(n,p)&amp;lt;/math&amp;gt;.&lt;br /&gt;
* For each cycle of length at most &amp;lt;math&amp;gt;\ell&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;, remove a vertex from the cycle.&lt;br /&gt;
The resulting graph &amp;lt;math&amp;gt;G&#039;&amp;lt;/math&amp;gt; satisfying that &amp;lt;math&amp;gt;g(G)&amp;gt;\ell&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\chi(G)&amp;gt;k&amp;lt;/math&amp;gt; with high probability.&lt;br /&gt;
&lt;br /&gt;
== Lovász Local Lemma==&lt;br /&gt;
Consider a set of &amp;quot;bad&amp;quot; events &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt;. Suppose that &amp;lt;math&amp;gt;\Pr[A_i]\le p&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;1\le i\le n&amp;lt;/math&amp;gt;. We want to show that there is a situation that none of the bad events occurs. Due to the probabilistic method, we need to prove that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]&amp;gt;0.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
;Case 1&amp;lt;nowiki&amp;gt;: mutually independent events.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
If all the bad events &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt; are mutually independent, then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]\ge(1-p)^n&amp;gt;0,&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
for any &amp;lt;math&amp;gt;p&amp;lt;1&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
;Case 2&amp;lt;nowiki&amp;gt;: arbitrarily dependent events.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
On the other hand, if we put no assumption on the dependencies between the events, then by the union bound (which holds unconditionally),&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]=1-\Pr\left[\bigvee_{i=1}^n A_i\right]\ge 1-np,&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
which is not an interesting bound for &amp;lt;math&amp;gt;p\ge\frac{1}{n}&amp;lt;/math&amp;gt;. We cannot improve bound without further information regarding the dependencies between the events.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
We would like to know what is going on between the two extreme cases: mutually independent events, and arbitrarily dependent events. The Lovász local lemma provides such a tool.&lt;br /&gt;
&lt;br /&gt;
The local lemma is powerful tool for showing the possibility of rare event under &#039;&#039;limited dependencies&#039;&#039;. The structure of dependencies between a set of events is described by a &#039;&#039;&#039;dependency graph&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Definition|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt; be a set of events. A graph &amp;lt;math&amp;gt;D=(V,E)&amp;lt;/math&amp;gt; on the set of vertices &amp;lt;math&amp;gt;V=\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; is called a &#039;&#039;&#039;dependency graph&#039;&#039;&#039; for the events &amp;lt;math&amp;gt;A_1,\ldots,A_n&amp;lt;/math&amp;gt; if for each &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;1\le i\le n&amp;lt;/math&amp;gt;, the event &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; is mutually independent of all the events &amp;lt;math&amp;gt;\{A_j\mid (i,j)\not\in E\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
;Example&lt;br /&gt;
:Let &amp;lt;math&amp;gt;X_1,X_2,\ldots,X_m&amp;lt;/math&amp;gt; be a set of &#039;&#039;mutually independent&#039;&#039; random variables. Each event &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; is a predicate defined on a number of variables among &amp;lt;math&amp;gt;X_1,X_2,\ldots,X_m&amp;lt;/math&amp;gt;. Let &amp;lt;math&amp;gt;v(A_i)&amp;lt;/math&amp;gt; be the unique smallest set of variables which determine &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt;. The dependency graph &amp;lt;math&amp;gt;D=(V,E)&amp;lt;/math&amp;gt; is defined by &lt;br /&gt;
:::&amp;lt;math&amp;gt;(i,j)\in E&amp;lt;/math&amp;gt; iff &amp;lt;math&amp;gt;v(A_i)\cap v(A_j)\neq \emptyset&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The following lemma, known as the Lovász local lemma, first proved by Erdős and Lovász in 1975, is an extremely powerful tool, as it supplies a way for dealing with rare events.&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Lovász Local Lemma (symmetric case)|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt; be a set of events, and assume that the following hold:&lt;br /&gt;
:#for all &amp;lt;math&amp;gt;1\le i\le n&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;\Pr[A_i]\le p&amp;lt;/math&amp;gt;;&lt;br /&gt;
:#the maximum degree of the dependency graph for the events &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;d&amp;lt;/math&amp;gt;, and &lt;br /&gt;
:::&amp;lt;math&amp;gt;ep(d+1)\le 1&amp;lt;/math&amp;gt;.&lt;br /&gt;
:Then&lt;br /&gt;
::&amp;lt;math&amp;gt;\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]&amp;gt;0&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
We will prove a general version of the local lemma, where the events &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; are not symmetric. This generalization is due to Spencer.&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Lovász Local Lemma (general case)|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;D=(V,E)&amp;lt;/math&amp;gt; be the dependency graph of events &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt;. Suppose there exist real numbers &amp;lt;math&amp;gt;x_1,x_2,\ldots, x_n&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;0\le x_i&amp;lt;1&amp;lt;/math&amp;gt; and for all &amp;lt;math&amp;gt;1\le i\le n&amp;lt;/math&amp;gt;,&lt;br /&gt;
::&amp;lt;math&amp;gt;\Pr[A_i]\le x_i\prod_{(i,j)\in E}(1-x_j)&amp;lt;/math&amp;gt;.&lt;br /&gt;
:Then &lt;br /&gt;
::&amp;lt;math&amp;gt;\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]\ge\prod_{i=1}^n(1-x_i)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
We can use the following probability identity to compute the probability of the intersection of events:&lt;br /&gt;
{{Theorem|Chain rule|&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]=\prod_{i=1}^n\Pr\left[\overline{A_i}\mid \bigwedge_{j=1}^{i-1}\overline{A_{j}}\right]&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
By definition of conditional probability,&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[\overline{A_n}\mid\bigwedge_{i=1}^{n-1}\overline{A_{i}}\right]&lt;br /&gt;
=\frac{\Pr\left[\bigwedge_{i=1}^n\overline{A_{i}}\right]}&lt;br /&gt;
{\Pr\left[\bigwedge_{i=1}^{n-1}\overline{A_{i}}\right]}&amp;lt;/math&amp;gt;,&lt;br /&gt;
so we have&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr\left[\bigwedge_{i=1}^n\overline{A_{i}}\right]=\Pr\left[\bigwedge_{i=1}^{n-1}\overline{A_{i}}\right]\Pr\left[\overline{A_n}\mid\bigwedge_{i=1}^{n-1}\overline{A_{i}}\right]&amp;lt;/math&amp;gt;.&lt;br /&gt;
The lemma is proved by recursively applying this equation.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Next we prove by induction on &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; that for any set of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; events &amp;lt;math&amp;gt;i_1,\ldots,i_m&amp;lt;/math&amp;gt;,&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr\left[A_{i_1}\mid \bigwedge_{j=2}^m\overline{A_{i_j}}\right]\le x_{i_1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
The local lemma is a direct consequence of this by applying the chain rule.&lt;br /&gt;
&lt;br /&gt;
For &amp;lt;math&amp;gt;m=1&amp;lt;/math&amp;gt;, this is obvious. For general &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;i_2,\ldots,i_k&amp;lt;/math&amp;gt; be the set of vertices adjacent to  &amp;lt;math&amp;gt;i_1&amp;lt;/math&amp;gt; in the dependency graph. Clearly &amp;lt;math&amp;gt;k-1\le d&amp;lt;/math&amp;gt;. And it holds that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[A_{i_1}\mid \bigwedge_{j=2}^m\overline{A_{i_j}}\right]&lt;br /&gt;
=\frac{\Pr\left[ A_i\wedge \bigwedge_{j=2}^k\overline{A_{i_j}}\mid \bigwedge_{j=k+1}^m\overline{A_{i_j}}\right]}&lt;br /&gt;
{\Pr\left[\bigwedge_{j=2}^k\overline{A_{i_j}}\mid \bigwedge_{j=k+1}^m\overline{A_{i_j}}\right]}&lt;br /&gt;
&amp;lt;/math&amp;gt;,&lt;br /&gt;
which is due to the basic conditional probability identity&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[A\mid BC]=\frac{\Pr[AB\mid C]}{\Pr[B\mid C]}&amp;lt;/math&amp;gt;.&lt;br /&gt;
We bound the numerator&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr\left[ A_{i_1}\wedge \bigwedge_{j=2}^k\overline{A_{i_j}}\mid \bigwedge_{j=k+1}^m\overline{A_{i_j}}\right]&lt;br /&gt;
&amp;amp;\le\Pr\left[ A_{i_1}\mid \bigwedge_{j=k+1}^m\overline{A_{i_j}}\right]\\&lt;br /&gt;
&amp;amp;=\Pr[A_{i_1}]\\&lt;br /&gt;
&amp;amp;\le x_{i_1}\prod_{(i_1,j)\in E}(1-x_j).&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
The equation is due to the independence between &amp;lt;math&amp;gt;A_{i_1}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;A_{i_k+1},\ldots,A_{i_m}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The denominator can be expanded using the chain rule as&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[\bigwedge_{j=2}^k\overline{A_{i_j}}\mid \bigwedge_{j=k+1}^m\overline{A_{i_j}}\right]&lt;br /&gt;
=\prod_{j=2}^k\Pr\left[\overline{A_{i_j}}\mid \bigwedge_{\ell=j+1}^m\overline{A_{i_\ell}}\right]&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
which by the induction hypothesis, is at least &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\prod_{j=2}^k(1-x_{i_j})=\prod_{\{i_1,i_j\}\in E}(1-x_j)&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
where &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; is the edge set of the dependency graph.&lt;br /&gt;
&lt;br /&gt;
Therefore,&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left[A_{i_1}\mid \bigwedge_{j=2}^m\overline{A_{i_j}}\right]&lt;br /&gt;
\le\frac{x_{i_1}\prod_{(i_1,j)\in E}(1-x_j)}{\prod_{\{i_1,i_j\}\in E}(1-x_j)}\le x_{i_1}.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Applying the chain rule, &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]&lt;br /&gt;
&amp;amp;=\prod_{i=1}^n\Pr\left[\overline{A_i}\mid \bigwedge_{j=1}^{i-1}\overline{A_{j}}\right]\\&lt;br /&gt;
&amp;amp;=\prod_{i=1}^n\left(1-\Pr\left[A_i\mid \bigwedge_{j=1}^{i-1}\overline{A_{j}}\right]\right)\\&lt;br /&gt;
&amp;amp;\ge\prod_{i=1}^n\left(1-x_i\right).&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
To prove the symmetric case. Let &amp;lt;math&amp;gt;x_i=\frac{1}{d+1}&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;i=1,2,\ldots,n&amp;lt;/math&amp;gt;. Note that &amp;lt;math&amp;gt;\left(1-\frac{1}{d+1}\right)^d&amp;gt;\frac{1}{\mathrm{e}}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If the following conditions are satisfied:&lt;br /&gt;
:#for all &amp;lt;math&amp;gt;1\le i\le n&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;\Pr[A_i]\le p&amp;lt;/math&amp;gt;;&lt;br /&gt;
:#&amp;lt;math&amp;gt;ep(d+1)\le 1&amp;lt;/math&amp;gt;;&lt;br /&gt;
then for all &amp;lt;math&amp;gt;1\le i\le n&amp;lt;/math&amp;gt;,&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[A_i]\le p\le\frac{1}{e(d+1)}&amp;lt;\frac{1}{d+1}\left(1-\frac{1}{d+1}\right)^d\le x_i\prod_{(i,j)\in E}(1-x_j)&amp;lt;/math&amp;gt;.&lt;br /&gt;
Due to the local lemma for general cases, this implies that&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr\left[\bigwedge_{i=1}^n\overline{A_i}\right]\ge\prod_{i=1}^n(1-x_i)=\left(1-\frac{1}{d+1}\right)^n&amp;gt;0&amp;lt;/math&amp;gt;.&lt;br /&gt;
This gives the symmetric version of local lemma.&lt;br /&gt;
&lt;br /&gt;
=== Ramsey number, revisited ===&lt;br /&gt;
{{Theorem|Ramsey number|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;k,\ell&amp;lt;/math&amp;gt; be positive integers. The Ramsey number &amp;lt;math&amp;gt;R(k,\ell)&amp;lt;/math&amp;gt; is defined as the smallest integer satisfying:&lt;br /&gt;
:If &amp;lt;math&amp;gt;n\ge R(k,\ell)&amp;lt;/math&amp;gt;, for any coloring of edges of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; with two colors red and blue, there exists a red &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt; or a blue &amp;lt;math&amp;gt;K_\ell&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The Ramsey theorem says that for any &amp;lt;math&amp;gt;k,\ell&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;R(k,\ell)&amp;lt;/math&amp;gt; is finite. The actual value of &amp;lt;math&amp;gt;R(k,\ell)&amp;lt;/math&amp;gt; is extremely difficult to compute.&lt;br /&gt;
We can use the local lemma to prove a lower bound for the diagonal Ramsey number.&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:&amp;lt;math&amp;gt;R(k,k)\ge Ck2^{k/2}&amp;lt;/math&amp;gt; for some constant &amp;lt;math&amp;gt;C&amp;gt;0&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
To prove a lower bound &amp;lt;math&amp;gt;R(k,k)&amp;gt;n&amp;lt;/math&amp;gt;, it is sufficient to show that there exists a 2-coloring of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; without a monochromatic &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt;. We prove this by the probabilistic method.&lt;br /&gt;
&lt;br /&gt;
Pick a random 2-coloring of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; by coloring each edge uniformly and independently with one of the two colors. For any set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; vertices, let &amp;lt;math&amp;gt;A_S&amp;lt;/math&amp;gt; denote the event that &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; forms a monochromatic &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt;. It is easy to see that &amp;lt;math&amp;gt;\Pr[A_s]=2^{1-{k\choose 2}}=p&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For any &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subset &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; of vertices, &amp;lt;math&amp;gt;A_S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;A_T&amp;lt;/math&amp;gt; are dependent if and only if &amp;lt;math&amp;gt;|S\cap T|\ge 2&amp;lt;/math&amp;gt;. For each &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;, the number of &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; that &amp;lt;math&amp;gt;|S\cap T|\ge 2&amp;lt;/math&amp;gt; is at most &amp;lt;math&amp;gt;{k\choose 2}{n\choose k-2}&amp;lt;/math&amp;gt;, so the max degree of the dependency graph is &amp;lt;math&amp;gt;d\le{k\choose 2}{n\choose k-2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Take &amp;lt;math&amp;gt;n=Ck2^{k/2}&amp;lt;/math&amp;gt; for some appropriate constant &amp;lt;math&amp;gt;C&amp;gt;0&amp;lt;/math&amp;gt;.&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\mathrm{e}p(d+1)&lt;br /&gt;
&amp;amp;\le \mathrm{e}2^{1-{k\choose 2}}\left({k\choose 2}{n\choose k-2}+1\right)\\&lt;br /&gt;
&amp;amp;\le 2^{3-{k\choose 2}}{k\choose 2}{n\choose k-2}\\&lt;br /&gt;
&amp;amp;\le 1&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Applying the local lemma, the probability that there is no monochromatic &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt; is &lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr\left[\bigwedge_{S\in{[n]\choose k}}\overline{A_S}\right]&amp;gt;0&amp;lt;/math&amp;gt;.&lt;br /&gt;
Therefore, there exists a 2-coloring of &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt; which has no monochromatic &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt;, which means&lt;br /&gt;
:&amp;lt;math&amp;gt;R(k,k)&amp;gt;n=Ck2^{k/2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13640</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13640"/>
		<updated>2026-04-17T13:18:00Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2026/03/25)&#039;&#039;&#039;&amp;lt;font color=red size=4&amp;gt; 第一次作业已发布&amp;lt;/font&amp;gt;，请在 2026/04/08 上课之前提交到 [mailto:njucomb26@163.com njucomb26@163.com] (文件名为&#039;学号_姓名_A1.pdf&#039;)&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行([mailto:652024330006@smail.nju.edu.cn 652024330006@smail.nju.edu.cn])&lt;br /&gt;
** 周灿&lt;br /&gt;
** 方子伊&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* [[组合数学 (Spring 2026)/Problem Set 1|Problem Set 1]]&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Sieve methods|Sieve methods | 筛法]] ([http://tcs.nju.edu.cn/slides/comb2026/PIE.pdf slides])&lt;br /&gt;
# Guest lecture by Prof. Penghui Yao on entropy and counting ([http://tcs.nju.edu.cn/slides/comb2026/entropy.pdf notes]) &lt;br /&gt;
# [[组合数学 (Fall 2026)/Cayley&#039;s formula|Cayley&#039;s formula | Cayley公式]]  ([http://tcs.nju.edu.cn/slides/comb2026/Cayley.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Existence problems|Existence problems | 存在性问题]]&lt;br /&gt;
# [[组合数学 (Fall 2026)/The probabilistic method|The probabilistic method | 概率法]] ([http://tcs.nju.edu.cn/slides/comb2026/ProbMethod.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13639</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13639"/>
		<updated>2026-04-17T13:17:48Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2026/03/25)&#039;&#039;&#039;&amp;lt;font color=red size=4&amp;gt; 第一次作业已发布&amp;lt;/font&amp;gt;，请在 2026/04/08 上课之前提交到 [mailto:njucomb26@163.com njucomb26@163.com] (文件名为&#039;学号_姓名_A1.pdf&#039;)&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行([mailto:652024330006@smail.nju.edu.cn 652024330006@smail.nju.edu.cn])&lt;br /&gt;
** 周灿&lt;br /&gt;
** 方子伊&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* [[组合数学 (Spring 2026)/Problem Set 1|Problem Set 1]]&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Sieve methods|Sieve methods | 筛法]] ([http://tcs.nju.edu.cn/slides/comb2026/PIE.pdf slides])&lt;br /&gt;
# Guest lecture by Prof. Penghui Yao on entropy and counting ([http://tcs.nju.edu.cn/slides/comb2026/entropy.pdf notes]) &lt;br /&gt;
# [[组合数学 (Fall 2026)/Cayley&#039;s formula|Cayley&#039;s formula | Cayley公式]]  ([http://tcs.nju.edu.cn/slides/comb2026/Cayley.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Existence problems|Existence problems | 存在性问题]]&lt;br /&gt;
# [[组合数学 (Fall 2026)/The probabilistic method|The probabilistic method | 概率法]] ([http://tcs.nju.edu.cn/slides/comb2025/ProbMethod.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Weierstrass_Approximation_Theorem&amp;diff=13638</id>
		<title>概率论与数理统计 (Spring 2026)/Weierstrass Approximation Theorem</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Weierstrass_Approximation_Theorem&amp;diff=13638"/>
		<updated>2026-04-16T08:13:07Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;[https://en.wikipedia.org/wiki/Stone%E2%80%93Weierstrass_theorem &amp;#039;&amp;#039;&amp;#039;魏尔施特拉斯逼近定理&amp;#039;&amp;#039;&amp;#039;]（&amp;#039;&amp;#039;&amp;#039;Weierstrass approximation theorem&amp;#039;&amp;#039;&amp;#039;）陈述了这样一个事实：闭区间上的连续函数总可以用多项式一致逼近。 {{Theorem|魏尔施特拉斯逼近定理| :设 &amp;lt;math&amp;gt;f:[a,b]\to\mathbb{R}&amp;lt;/math&amp;gt; 为定义在实数区间 &amp;lt;math&amp;gt;[a,b]&amp;lt;/math&amp;gt; 上的连续实值函数。对每个 &amp;lt;math&amp;gt;\epsilon&amp;gt;0&amp;lt;/math&amp;gt;，存在一个多项式 &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; 使得对...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[https://en.wikipedia.org/wiki/Stone%E2%80%93Weierstrass_theorem &#039;&#039;&#039;魏尔施特拉斯逼近定理&#039;&#039;&#039;]（&#039;&#039;&#039;Weierstrass approximation theorem&#039;&#039;&#039;）陈述了这样一个事实：闭区间上的连续函数总可以用多项式一致逼近。&lt;br /&gt;
{{Theorem|魏尔施特拉斯逼近定理|&lt;br /&gt;
:设 &amp;lt;math&amp;gt;f:[a,b]\to\mathbb{R}&amp;lt;/math&amp;gt; 为定义在实数区间 &amp;lt;math&amp;gt;[a,b]&amp;lt;/math&amp;gt; 上的连续实值函数。对每个 &amp;lt;math&amp;gt;\epsilon&amp;gt;0&amp;lt;/math&amp;gt;，存在一个多项式 &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; 使得对于 &amp;lt;math&amp;gt;[a,b]&amp;lt;/math&amp;gt; 中所有 &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;，均有 &amp;lt;math&amp;gt;|p(x)-f(x)|\le \epsilon&amp;lt;/math&amp;gt;，即&lt;br /&gt;
:::&amp;lt;math&amp;gt;\sup_{x\in[a,b]}\|f(x)-p(x)\|\le \epsilon&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
不失一般性地，可以仅考虑区间&amp;lt;math&amp;gt;[a,b]=[0,1]&amp;lt;/math&amp;gt;。因为对于定义在一般的实数区间&amp;lt;math&amp;gt;[a,b]&amp;lt;/math&amp;gt;上的任意函数&amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt;，可通过变量变换&amp;lt;math&amp;gt;t\mapsto a+(b-a)t&amp;lt;/math&amp;gt;将其转化为定义在&amp;lt;math&amp;gt;[0,1]&amp;lt;/math&amp;gt;上的新函数&amp;lt;math&amp;gt;g(t)=f(a+(b-a)t)&amp;lt;/math&amp;gt;，这并不会改变函数的连续性以及是否为多项式。&lt;br /&gt;
&lt;br /&gt;
因此，可假设连续函数&amp;lt;math&amp;gt;f:[0,1]\to\mathbb{R}&amp;lt;/math&amp;gt;。令&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;为足够大的正整数，取值待定。&lt;br /&gt;
&lt;br /&gt;
对于任意 &amp;lt;math&amp;gt;x\in [0,1]&amp;lt;/math&amp;gt;，令 &amp;lt;math&amp;gt;Y_x\sim\text{Bin}\left(n,x\right)&amp;lt;/math&amp;gt; 为以&amp;lt;math&amp;gt;n,x&amp;lt;/math&amp;gt;为参数的二项分布随机变量。&lt;br /&gt;
&lt;br /&gt;
将多项式 &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; 定义如下。对每个 &amp;lt;math&amp;gt;x\in[0,1]&amp;lt;/math&amp;gt;，令：&lt;br /&gt;
:&amp;lt;math&amp;gt;p(x)=\mathbb{E}\left[f\left(\frac{Y_x}{n}\right)\right]=\sum_{k=0}^nf\left(\frac{k}{n}\right)\Pr(Y_x=k)=\sum_{k=0}^nf\left(\frac{k}{n}\right){n\choose k}x^k(1-x)^{n-k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
容易看出，这是一个关于变量 &amp;lt;math&amp;gt;x\in[0,1]&amp;lt;/math&amp;gt; 的（&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;次）多项式。&lt;br /&gt;
&lt;br /&gt;
根据[https://en.wikipedia.org/wiki/Heine%E2%80%93Cantor_theorem &#039;&#039;&#039;一致连续性定理&#039;&#039;&#039;](&#039;&#039;&#039;海涅-康托尔定理&#039;&#039;&#039;)，紧空间 &amp;lt;math&amp;gt;[0,1]&amp;lt;/math&amp;gt; 上的连续函数 &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; 必然也是&#039;&#039;&#039;一致连续&#039;&#039;&#039;的。即，对任意 &amp;lt;math&amp;gt;\epsilon&amp;gt;0&amp;lt;/math&amp;gt;，总存在 &amp;lt;math&amp;gt;\delta_\epsilon&amp;gt;0&amp;lt;/math&amp;gt;，使得对于 &amp;lt;math&amp;gt;[0,1]&amp;lt;/math&amp;gt; 中任意满足 &amp;lt;math&amp;gt;|x-y|\le\delta_\epsilon&amp;lt;/math&amp;gt; 的 &amp;lt;math&amp;gt;x,y&amp;lt;/math&amp;gt;，都有 &amp;lt;math&amp;gt;|f(x)-f(y)|\le\frac{\epsilon}{2}&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
不妨定下任意的&amp;lt;math&amp;gt;\epsilon&amp;gt;0&amp;lt;/math&amp;gt;，以及一致连续性定理因此保证的 &amp;lt;math&amp;gt;\delta_\epsilon&amp;gt;0&amp;lt;/math&amp;gt;。&lt;br /&gt;
并且定下任意的 &amp;lt;math&amp;gt;x\in[0,1]&amp;lt;/math&amp;gt;。我们希望验证 &amp;lt;math&amp;gt;|p(x)-f(x)|\le\epsilon&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
根据 &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; 的定义，有：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
|p(x)-f(x)|&lt;br /&gt;
=&amp;amp;&lt;br /&gt;
\left|\mathbb{E}\left[f\left(\frac{Y_x}{n}\right)\right]-f(x)\right|\\&lt;br /&gt;
=&amp;amp;&lt;br /&gt;
\left|\mathbb{E}\left[f\left(\frac{Y_x}{n}\right)-f(x)\right]\right| &amp;amp;&amp;amp; \text{(期望的线性)}\\&lt;br /&gt;
\le&amp;amp; &lt;br /&gt;
\mathbb{E}\left[\left|f\left(\frac{Y_x}{n}\right)-f(x)\right|\right] &amp;amp;&amp;amp; \text{(琴生不等式)}\\&lt;br /&gt;
=&amp;amp;&lt;br /&gt;
\mathbb{E}\left[\left|f\left(\frac{Y_x}{n}\right)-f(x)\right|\,\,\bigg{|}\,\, \left|\frac{Y_x}{n}-x\right|\le \delta_\epsilon\right]&lt;br /&gt;
\cdot&lt;br /&gt;
\Pr\left[\left|\frac{Y_x}{n}-x\right|\le \delta_\epsilon\right] \\&lt;br /&gt;
&amp;amp;+&lt;br /&gt;
\mathbb{E}\left[\left|f\left(\frac{Y_x}{n}\right)-f(x)\right|\,\,\bigg{|}\,\, \left|\frac{Y_x}{n}-x\right|&amp;gt; \delta_\epsilon\right]&lt;br /&gt;
\cdot&lt;br /&gt;
\Pr\left[\left|\frac{Y_x}{n}-x\right|&amp;gt; \delta_\epsilon\right] &amp;amp;&amp;amp; \text{(全期望法则)}\\&lt;br /&gt;
\le&amp;amp;&lt;br /&gt;
\frac{\epsilon}{2}&lt;br /&gt;
+2\|f\|_{\infty}\cdot \Pr\left[\left|\frac{Y_x}{n}-x\right|&amp;gt; \delta_\epsilon\right] &amp;amp;&amp;amp; (\star)&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
上述最后一个不等式 &amp;lt;math&amp;gt;(\star)&amp;lt;/math&amp;gt; 成立是因为根据一致连续性，条件 &amp;lt;math&amp;gt;\left|\frac{Y_x}{n}-x\right|\le \delta_\epsilon&amp;lt;/math&amp;gt; 保证了 &amp;lt;math&amp;gt;\left|f\left(\frac{Y_x}{n}\right)-f(x)\right|\le\frac{\epsilon}{2}&amp;lt;/math&amp;gt;，因此&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbb{E}\left[\left|f\left(\frac{Y_x}{n}\right)-f(x)\right|\,\,\bigg{|}\,\, \left|\frac{Y_x}{n}-x\right|\le \delta_\epsilon\right]\le\frac{\epsilon}{2}&amp;lt;/math&amp;gt;&lt;br /&gt;
另一方面，有 &amp;lt;math&amp;gt;\left|f\left({Y_x}/{n}\right)-f(x)\right|\le \sup_{y\in[0,1]}|f(y)-f(x)|\le 2\sup_{y\in[0,1]}|f(y)| = 2\|f\|_{\infty}&amp;lt;/math&amp;gt; 无条件成立，因此&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbb{E}\left[\left|f\left(\frac{Y_x}{n}\right)-f(x)\right|\,\,\bigg{|}\,\, \left|\frac{Y_x}{n}-x\right|&amp;gt; \delta_\epsilon\right]\le 2\|f\|_{\infty}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
公式 &amp;lt;math&amp;gt;(\star)&amp;lt;/math&amp;gt; 中的概率可由切比雪夫不等式得出如下上界：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr\left[\left|\frac{Y_x}{n}-x\right|&amp;gt; \delta_\epsilon\right]&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\Pr\left[\left|{Y_x}-\mathbb{E}[Y_x]\right|&amp;gt; n\delta_\epsilon\right]  &amp;amp;&amp;amp; (\mathbb{E}[Y_x]=nx)\\&lt;br /&gt;
&amp;amp;\le&lt;br /&gt;
\frac{\mathbf{Var}[Y_x]}{n^2\delta_\epsilon^2} &amp;amp;&amp;amp; \text{(切比雪夫不等式)}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{nx(1-x)}{n^2\delta_\epsilon^2} &amp;amp;&amp;amp; (\mathbf{Var}[Y_x]=nx(1-x))\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
\frac{1}{4n\delta_\epsilon^2}.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
因此可以选择 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 为任意满足 &amp;lt;math&amp;gt;n\ge\frac{\|f\|_{\infty}}{\epsilon\delta_\epsilon^2}&amp;lt;/math&amp;gt; 的正整数（注意到这一 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 的选取是与  &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; 无关的，因此可对所有  &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; 选取一致的  &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;）。如此可保证以上的概率上界为 &amp;lt;math&amp;gt;\frac{1}{4n\delta_\epsilon^2}\le\frac{\epsilon}{4\|f\|_{\infty}}&amp;lt;/math&amp;gt;。&lt;br /&gt;
将其代回至 &amp;lt;math&amp;gt;(\star)&amp;lt;/math&amp;gt;式，得到如下结论：&lt;br /&gt;
:&amp;lt;math&amp;gt;|p(x)-f(x)|\le \frac{\epsilon}{2}+2\|f\|_{\infty}\cdot \frac{\epsilon}{4\|f\|_{\infty}}\le\epsilon&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Threshold_of_k-clique_in_random_graph&amp;diff=13637</id>
		<title>概率论与数理统计 (Spring 2026)/Threshold of k-clique in random graph</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Threshold_of_k-clique_in_random_graph&amp;diff=13637"/>
		<updated>2026-04-16T08:12:47Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;在 Erdős-Rényi 随机图模型 &amp;lt;math&amp;gt;G(n,p)&amp;lt;/math&amp;gt; 中，一个随机无向图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 以如下的方式生成：图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 包含 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 个顶点，每一对顶点之间都独立同地以概率 &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; 连一条无向边。如此生成的随机图记为 &amp;lt;math&amp;gt;G\sim G(n,p)&amp;lt;/math&amp;gt;。  固定整数 &amp;lt;math&amp;gt;k\ge 3&amp;lt;/math&amp;gt;，考虑随机图 &amp;lt;math&amp;gt;G\sim G(n,p)&amp;lt;/math&amp;gt; 包含 &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt;（&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-团，&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-clique）子图...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;在 Erdős-Rényi 随机图模型 &amp;lt;math&amp;gt;G(n,p)&amp;lt;/math&amp;gt; 中，一个随机无向图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 以如下的方式生成：图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 包含 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 个顶点，每一对顶点之间都独立同地以概率 &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; 连一条无向边。如此生成的随机图记为 &amp;lt;math&amp;gt;G\sim G(n,p)&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
固定整数 &amp;lt;math&amp;gt;k\ge 3&amp;lt;/math&amp;gt;，考虑随机图 &amp;lt;math&amp;gt;G\sim G(n,p)&amp;lt;/math&amp;gt; 包含 &amp;lt;math&amp;gt;K_k&amp;lt;/math&amp;gt;（&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-团，&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-clique）子图概率。&lt;br /&gt;
&lt;br /&gt;
特别地，对于任意固定（即，常数）的整数 &amp;lt;math&amp;gt;k\ge 3&amp;lt;/math&amp;gt;，我们将证明存在函数 &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt; 使得对所有足够大的 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 和随机图 &amp;lt;math&amp;gt;G\sim G(n,p)&amp;lt;/math&amp;gt; 有&lt;br /&gt;
:&amp;lt;math&amp;gt;({\color{red}\star})\qquad&amp;lt;/math&amp;gt; &amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr\left(G\text{ 包含子图 }K_k\right)&lt;br /&gt;
=\begin{cases}&lt;br /&gt;
o(1) &amp;amp; \text{如果} p=o(p_k(n))\\&lt;br /&gt;
1-o(1) &amp;amp; \text{如果} p=\omega(p_k(n))&lt;br /&gt;
\end{cases}&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
这描述了“包含 &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-团“这一性质，在随机图 &amp;lt;math&amp;gt;G(n,p)&amp;lt;/math&amp;gt; 上，展现出的一种所谓的&#039;&#039;&#039;阈值现象&#039;&#039;&#039;：随着参数 &amp;lt;math&amp;gt;p&amp;lt;/math&amp;gt; 从远小于 &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt; 增长到远大于 &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;，“包含 &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-团“这一事件在随机图 &amp;lt;math&amp;gt;G(n,p)&amp;lt;/math&amp;gt; 上从渐进几乎从不（asymptotically almost never）发生变为渐进几乎一定（&#039;&#039;&#039;a.a.s.&#039;&#039;&#039;）发生。&lt;br /&gt;
&lt;br /&gt;
固定整数 &amp;lt;math&amp;gt;k\ge 3&amp;lt;/math&amp;gt;，假设&amp;lt;math&amp;gt;k=O(1)&amp;lt;/math&amp;gt;为常数。抽取随机图 &amp;lt;math&amp;gt;G\sim G(n,p)&amp;lt;/math&amp;gt;。令随机变量 &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; 表示 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中包含的 &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-团的个数，因此有：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left(G\text{ 包含子图 }K_k\right)&lt;br /&gt;
=&lt;br /&gt;
\Pr(X\ge 1)&lt;br /&gt;
&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=一阶矩方法=&lt;br /&gt;
根据马尔可夫不等式：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr(X\ge 1)\le\mathbb{E}[X]&lt;br /&gt;
&amp;lt;/math&amp;gt;.&lt;br /&gt;
因此，通过计算 &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; 的期望（一阶矩），可得到概率 &amp;lt;math&amp;gt;\Pr\left(G\text{ 包含子图 }K_k\right)&amp;lt;/math&amp;gt; 的上界。&lt;br /&gt;
&lt;br /&gt;
对于顶点集合 &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; 的任意 &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-子集 &amp;lt;math&amp;gt;S\in{[n]\choose k}&amp;lt;/math&amp;gt;，定义指示随机变量 &amp;lt;math&amp;gt;I_S=I(K_S\subseteq G)&amp;lt;/math&amp;gt;，即 &amp;lt;math&amp;gt;I_S=1&amp;lt;/math&amp;gt; 当且仅当点集 &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; 在随机图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中构成了一个 &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-团。根据这个定义，有：&lt;br /&gt;
*&amp;lt;math&amp;gt;X=\sum_{S\in{[n]\choose k}}I_S&amp;lt;/math&amp;gt;&lt;br /&gt;
*&amp;lt;math&amp;gt;\mathbb{E}[I_S]=\Pr(K_S\subseteq G)=p^{{k\choose 2}}&amp;lt;/math&amp;gt;&lt;br /&gt;
于是根据期望的线性：&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbb{E}[X]=\sum_{S\in{[n]\choose k}}\mathbb{E}[I_S]={n\choose k}p^{{k\choose 2}}&amp;lt;/math&amp;gt;.&lt;br /&gt;
对于常数 &amp;lt;math&amp;gt;k=O(1)&amp;lt;/math&amp;gt;，当 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 足够大时，&amp;lt;math&amp;gt;{n\choose k}p^{{k\choose 2}}=\Theta\left(n^kp^{k(k-1)/2}\right)&amp;lt;/math&amp;gt;。这提示我们将函数 &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt; 做如下定义：&lt;br /&gt;
:&amp;lt;math&amp;gt;p_k(n)=n^{-2/(k-1)}&amp;lt;/math&amp;gt;.&lt;br /&gt;
于是，容易验证有：&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbb{E}[X]=\Theta\left(n^kp^{k(k-1)/2}\right)=\begin{cases}&lt;br /&gt;
o(1) &amp;amp; \text{如果 } p=o(p_k(n))=o\left(n^{-2/(k-1)}\right)\\&lt;br /&gt;
\omega(1) &amp;amp; \text{如果 } p=\omega(p_k(n))=\omega\left(n^{-2/(k-1)}\right)&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
特别地，当 &amp;lt;math&amp;gt;p=o(p_k(n))=o\left(n^{-2/(k-1)}\right)&amp;lt;/math&amp;gt; 时，&amp;lt;math&amp;gt;\mathbb{E}[X]=o(1)&amp;lt;/math&amp;gt;。根据马尔可夫不等式：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left(G\text{ 包含子图 }K_k\right)=\Pr(X\ge 1)\le \mathbb{E}[X]=o(1).&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
因此，&amp;lt;math&amp;gt;({\color{red}\star})&amp;lt;/math&amp;gt; 中的概率上界已得到证明。&lt;br /&gt;
&lt;br /&gt;
事实上，这一结果可以更加直接地使用 union bound 证明：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr\left(G\text{ 包含子图 }K_k\right)=\mbox{$\Pr\left(\bigcup_{S\in{[n]\choose k}}(K_S\subseteq G)\right)$}\le {n\choose k}p^{{k\choose 2}}=o(1)\qquad\left(\text{如果 $p=o(p_k(n))$}\right)&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
尽管如此，对于一阶矩的分析，有助于我们猜测出正确的阈值 &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;，而且对于更高阶矩的估计也是必要的。&lt;br /&gt;
&lt;br /&gt;
=二阶矩方法=&lt;br /&gt;
为了完全证明 &amp;lt;math&amp;gt;({\color{red}\star})&amp;lt;/math&amp;gt;，我们需要补全其中的概率下界，即在 &amp;lt;math&amp;gt;\mathbb{E}[X]=\omega(1)&amp;lt;/math&amp;gt; 的情况下，证明&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr(X\ge 1)\ge 1-o(1)&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
很遗憾，为实现这一目的，仅知道 &amp;lt;math&amp;gt;\mathbb{E}[X]=\omega(1)&amp;lt;/math&amp;gt; 是不够的。我们还需要知道关于随机变量 &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; 更多的信息，比方说它的方差（二阶中心矩）。&lt;br /&gt;
&lt;br /&gt;
根据切比雪夫不等式：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\Pr(X=0)\le \Pr(|X-\mathbb{E}[X]|\ge \mathbb{E}[X])\le \frac{\mathbf{Var}[X]}{\mathbb{E}[X]^2}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
于是，上述目标归结为证明方差和期望之间有如下渐进关系： &amp;lt;math&amp;gt;\mathbf{Var}[X]=o\left(\mathbb{E}[X]^2\right)&amp;lt;/math&amp;gt;。实际上我们证明了更强的性质&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbb{E}[X^2]=o\left(\mathbb{E}[X]^2\right)&amp;lt;/math&amp;gt;.&lt;br /&gt;
这足以推出 &amp;lt;math&amp;gt;\mathbf{Var}[X]=\mathbb{E}[X^2]-\mathbb{E}[X]^2\le \mathbb{E}[X^2]=o\left(\mathbb{E}[X]^2\right)&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
还记得 &amp;lt;math&amp;gt;X=\sum_{S\in{[n]\choose k}}I_S&amp;lt;/math&amp;gt;，于是有：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\mathbb{E}\left[X^2\right]&lt;br /&gt;
=&lt;br /&gt;
\mathbb{E}\left[\left(\sum_{S\in{[n]\choose k}}I_S\right)^2\right]&lt;br /&gt;
=&lt;br /&gt;
\sum_{S\in{[n]\choose k}}\mathbb{E}[I_S^2] + \sum_{\substack{S,T\in{[n]\choose k}\\S\neq T}}\mathbb{E}[I_SI_T]&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
我们将分别计算这两项。首先，由于随机变量 &amp;lt;math&amp;gt;I_S&amp;lt;/math&amp;gt; 取值为0或1，因此 &amp;lt;math&amp;gt;I_S^2=I_S&amp;lt;/math&amp;gt;，于是有：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\sum_{S\in{[n]\choose k}}\mathbb{E}[I_S^2]&lt;br /&gt;
=&lt;br /&gt;
\sum_{S\in{[n]\choose k}}\mathbb{E}[I_S]&lt;br /&gt;
=&lt;br /&gt;
\mathbb{E}[X]&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
另一方面，&amp;lt;math&amp;gt;I_SI_T=1&amp;lt;/math&amp;gt; 当且仅当 &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; 在随机图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中都是 &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-团，于是：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\sum_{\substack{S,T\in{[n]\choose k}\\S\neq T}}\mathbb{E}[I_SI_T]&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{\substack{S,T\in{[n]\choose k}\\S\neq T}}\Pr((K_S\cup K_T)\subseteq G)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{\ell=0}^{k-1}\sum_{|S\cap T|=\ell}p^{2{k\choose 2}-{\ell\choose 2}}\\&lt;br /&gt;
&amp;amp;\le&lt;br /&gt;
\sum_{\ell=0}^{k-1}{n\choose 2k-\ell} {2k-\ell\choose k}{k\choose \ell} p^{2{k\choose 2}-{\ell\choose 2}} &amp;amp;&amp;amp; \left(\text{因为 }{2k-\ell\choose k}{k\choose \ell}\le 2^{2k}=O(1)\right)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
O\left(n^{2k}p^{2{k\choose 2}}\cdot\sum_{\ell=0}^{k-1} n^{-\ell}p^{-{\ell\choose 2}}\right)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\mathbb{E}[X]^2\cdot O\left(\sum_{\ell=0}^{k-1} n^{-\ell}p^{-{\ell\choose 2}}\right). &amp;amp;&amp;amp; \left(\text{因为 }\mathbb{E}[X]=\Theta\left(n^kp^{{k\choose 2}}\right)\right)&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
综上，我们有 &amp;lt;math&amp;gt;\mathbf{Var}[X]\le \mathbb{E}[X^2]\le \mathbb{E}[X]+\mathbb{E}[X]^2\cdot O\left(\sum_{\ell=0}^{k-1} n^{-\ell}p^{-{\ell\choose 2}}\right)&amp;lt;/math&amp;gt;，于是：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\frac{\mathbf{Var}[X]}{\mathbb{E}[X]^2}&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
\frac{\mathbb{E}[X^2]}{\mathbb{E}[X]^2}\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
\frac{1}{\mathbb{E}[X]} + O\left(\sum_{\ell=0}^{k-1} n^{-\ell}p^{-{\ell\choose 2}}\right)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
O\left(\sum_{\ell=2}^{k}n^{-\ell}p^{-{\ell\choose 2}} \right)  &amp;amp;&amp;amp; \left(\text{因为 }\mathbb{E}[X]=\Theta\left(n^kp^{{k\choose 2}}\right)\right)\\&lt;br /&gt;
&amp;amp;=o(1). &amp;amp;&amp;amp; (\text{当 }p=\omega(p_k(n)))&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
正如我们之前分析的，根据切比雪夫不等式，这证明了当 &amp;lt;math&amp;gt;p=\omega(p_k(n))=\omega\left(n^{-2/(k-1)}\right)&amp;lt;/math&amp;gt; 时，有 &amp;lt;math&amp;gt;\Pr(X=0)=o(1)&amp;lt;/math&amp;gt;。和一阶矩方法的部分合起来，这证明了 &amp;lt;math&amp;gt;({\color{red}\star})&amp;lt;/math&amp;gt;。&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13636</id>
		<title>概率论与数理统计 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13636"/>
		<updated>2026-04-16T08:12:04Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;&#039;&#039;&#039;概率论与数理统计&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Probability Theory&#039;&#039;&#039; &amp;lt;br&amp;gt; &amp;amp; &#039;&#039;&#039;Mathematical Statistics&#039;&#039;&#039;&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4  = office&lt;br /&gt;
|data4   = 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = liu@nju.edu.cn  &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = office&lt;br /&gt;
|data7   = 计算机系 516&lt;br /&gt;
|header8 = Class&lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &lt;br /&gt;
|header9 =&lt;br /&gt;
|label9  = Class meeting&lt;br /&gt;
|data9   = Wednesday, 9am-12am&amp;lt;br&amp;gt;&lt;br /&gt;
仙Ⅱ-212&lt;br /&gt;
|header10=&lt;br /&gt;
|label10 = Office hour&lt;br /&gt;
|data10  = TBA &amp;lt;br&amp;gt;计算机系 804（尹一通）&amp;lt;br&amp;gt;计算机系 516（刘景铖）&lt;br /&gt;
|header11= Textbook&lt;br /&gt;
|label11 = &lt;br /&gt;
|data11  = &lt;br /&gt;
|header12=&lt;br /&gt;
|label12 = &lt;br /&gt;
|data12  = [[File:概率导论.jpeg|border|100px]]&lt;br /&gt;
|header13=&lt;br /&gt;
|label13 = &lt;br /&gt;
|data13  = &#039;&#039;&#039;概率导论&#039;&#039;&#039;（第2版·修订版）&amp;lt;br&amp;gt; Dimitri P. Bertsekas and John N. Tsitsiklis&amp;lt;br&amp;gt; 郑忠国 童行伟 译；人民邮电出版社 (2022)&lt;br /&gt;
|header14=&lt;br /&gt;
|label14 = &lt;br /&gt;
|data14  = [[File:Grimmett_probability.jpg|border|100px]]&lt;br /&gt;
|header15=&lt;br /&gt;
|label15 = &lt;br /&gt;
|data15  = &#039;&#039;&#039;Probability and Random Processes&#039;&#039;&#039; (4E) &amp;lt;br&amp;gt; Geoffrey Grimmett and David Stirzaker &amp;lt;br&amp;gt;  Oxford University Press (2020)&lt;br /&gt;
|header16=&lt;br /&gt;
|label16 = &lt;br /&gt;
|data16  = [[File:Probability_and_Computing_2ed.jpg|border|100px]]&lt;br /&gt;
|header17=&lt;br /&gt;
|label17 = &lt;br /&gt;
|data17  = &#039;&#039;&#039;Probability and Computing&#039;&#039;&#039; (2E) &amp;lt;br&amp;gt; Michael Mitzenmacher and Eli Upfal &amp;lt;br&amp;gt;   Cambridge University Press (2017)&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Probability Theory and Mathematical Statistics&#039;&#039; (概率论与数理统计) class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 鞠哲：[mailto:juzhe@smail.nju.edu.cn &amp;lt;juzhe@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
** 祝永祺：[mailto:652025330045@smail.nju.edu.cn &amp;lt;652025330045@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;:&lt;br /&gt;
** 周三：9am-12am，仙Ⅱ-212&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: &lt;br /&gt;
:* TBA, 计算机系 804（尹一通）&lt;br /&gt;
:* TBA, 计算机系 516（刘景铖）&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090092561（申请加入需提供姓名、院系、学号）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
课程内容分为三大部分：&lt;br /&gt;
* &#039;&#039;&#039;经典概率论&#039;&#039;&#039;：概率空间、随机变量及其数字特征、多维与连续随机变量、极限定理等内容&lt;br /&gt;
* &#039;&#039;&#039;概率与计算&#039;&#039;&#039;：测度集中现象 (concentration of measure)、概率法 (the probabilistic method)、离散随机过程的相关专题&lt;br /&gt;
* &#039;&#039;&#039;数理统计&#039;&#039;&#039;：参数估计、假设检验、贝叶斯估计、线性回归等统计推断等概念&lt;br /&gt;
&lt;br /&gt;
对于第一和第二部分，要求清楚掌握基本概念，深刻理解关键的现象与规律以及背后的原理，并可以灵活运用所学方法求解相关问题。对于第三部分，要求熟悉数理统计的若干基本概念，以及典型的统计模型和统计推断问题。&lt;br /&gt;
&lt;br /&gt;
经过本课程的训练，力求使学生能够熟悉掌握概率的语言，并会利用概率思维来理解客观世界并对其建模，以及驾驭概率的数学工具来分析和求解专业问题。&lt;br /&gt;
&lt;br /&gt;
=== 教材与参考书 Course Materials ===&lt;br /&gt;
* &#039;&#039;&#039;[BT]&#039;&#039;&#039; 概率导论（第2版·修订版），[美]伯特瑟卡斯（Dimitri P.Bertsekas）[美]齐齐克利斯（John N.Tsitsiklis）著，郑忠国 童行伟 译，人民邮电出版社（2022）。&lt;br /&gt;
* &#039;&#039;&#039;[GS]&#039;&#039;&#039; &#039;&#039;Probability and Random Processes&#039;&#039;, by Geoffrey Grimmett and David Stirzaker; Oxford University Press; 4th edition (2020).&lt;br /&gt;
* &#039;&#039;&#039;[MU]&#039;&#039;&#039; &#039;&#039;Probability and Computing: Randomization and Probabilistic Techniques in Algorithms and Data Analysis&#039;&#039;, by Michael Mitzenmacher, Eli Upfal; Cambridge University Press; 2nd edition (2017).&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grading Policy ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。符合规则的讨论与致谢将不会影响得分。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
*[[概率论与数理统计 (Spring 2026)/Problem Set 1|Problem Set 1]]  请在 2026/4/1 上课之前(9am UTC+8)提交到 [mailto:pr2026_nju@163.com pr2026_nju@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
** [[概率论与数理统计 (Spring 2026)/第一次作业提交名单|第一次作业提交名单]]&lt;br /&gt;
&lt;br /&gt;
*[[概率论与数理统计 (Spring 2026)/Problem Set 2|Problem Set 2]]  请在 2026/4/22 上课之前(9am UTC+8)提交到 [mailto:pr2026_nju@163.com pr2026_nju@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A2.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lectures =&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/Intro.pdf 课程简介]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/ProbSpace.pdf 概率空间]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第1章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 1&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Entropy and volume of Hamming balls|Entropy and volume of Hamming balls]]&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Karger&#039;s min-cut algorithm| Karger&#039;s min-cut algorithm]]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/RandVar.pdf 随机变量]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第2章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 2, Sections 3.1~3.5, 3.7&#039;&#039;&#039;&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[MU] Chapter 2&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Average-case analysis of QuickSort|Average-case analysis of &#039;&#039;&#039;&#039;&#039;QuickSort&#039;&#039;&#039;&#039;&#039;]]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/Deviation.pdf 矩与偏差]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[MU] Chapter 3&#039;&#039;&#039;&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 章节 2.4, 4.2, 4.3, 5.1&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Sections 3.3, 3.6, 7.3&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Threshold of k-clique in random graph|Threshold of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-clique in random graph]]&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Weierstrass Approximation Theorem|Weierstrass approximation]]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [https://plato.stanford.edu/entries/probability-interpret/ Interpretations of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/History_of_probability History of probability]&lt;br /&gt;
* Example problems:&lt;br /&gt;
** [https://dornsifecms.usc.edu/assets/sites/520/docs/VonNeumann-ams12p36-38.pdf von Neumann&#039;s Bernoulli factory] and other [https://peteroupc.github.io/bernoulli.html Bernoulli factory algorithms]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boy_or_Girl_paradox Boy or Girl paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Monty_Hall_problem Monty Hall problem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bertrand_paradox_(probability) Bertrand paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Hard_spheres Hard spheres model] and [https://en.wikipedia.org/wiki/Ising_model Ising model]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/PageRank &#039;&#039;PageRank&#039;&#039;] and stationary [https://en.wikipedia.org/wiki/Random_walk random walk]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Diffusion_process Diffusion process] and [https://en.wikipedia.org/wiki/Diffusion_model diffusion model]&lt;br /&gt;
*[https://en.wikipedia.org/wiki/Probability_space Probability space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sample_space Sample space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Event_(probability_theory) Event] and [https://en.wikipedia.org/wiki/Σ-algebra &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;-algebra]&lt;br /&gt;
** Kolmogorov&#039;s [https://en.wikipedia.org/wiki/Probability_axioms axioms of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Discrete_uniform_distribution Classical] and [https://en.wikipedia.org/wiki/Geometric_probability goemetric probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Boole%27s_inequality Union bound]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Inclusion%E2%80%93exclusion_principle Inclusion-Exclusion principle]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boole%27s_inequality#Bonferroni_inequalities Bonferroni inequalities]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Conditional_probability Conditional probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Chain_rule_(probability) Chain rule]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_total_probability Law of total probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bayes%27_theorem Bayes&#039; law]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Independence_(probability_theory) Independence] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Pairwise_independence Pairwise independence]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Random_variable Random variable]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cumulative_distribution_function Cumulative distribution function]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Probability_mass_function Probability mass function]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Probability_density_function Probability density function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Multivariate_random_variable Random vector]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Joint_probability_distribution Joint probability distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Conditional_probability_distribution Conditional probability distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Marginal_distribution Marginal distribution]&lt;br /&gt;
* Some &#039;&#039;&#039;discrete&#039;&#039;&#039; probability distributions&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bernoulli_trial Bernoulli trial] and [https://en.wikipedia.org/wiki/Bernoulli_distribution Bernoulli distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Discrete_uniform_distribution Discrete uniform distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Binomial_distribution Binomial distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Geometric_distribution Geometric distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Negative_binomial_distribution Negative binomial distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Hypergeometric_distribution Hypergeometric distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Poisson_distribution Poisson distribution]&lt;br /&gt;
** and [https://en.wikipedia.org/wiki/List_of_probability_distributions#Discrete_distributions others]&lt;br /&gt;
* Balls into bins model&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Multinomial_distribution Multinomial distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Birthday_problem Birthday problem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Coupon_collector%27s_problem Coupon collector]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Balls_into_bins_problem Occupancy problem]&lt;br /&gt;
* Random graphs&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi random graph model]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Galton%E2%80%93Watson_process Galton–Watson branching process]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Expected_value Expectation]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_the_unconscious_statistician Law of the unconscious statistician, &#039;&#039;LOTUS&#039;&#039;]&lt;br /&gt;
** [https://dlsun.github.io/probability/linearity.html Linearity of expectation]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Conditional_expectation Conditional expectation]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_total_expectation Law of total expectation]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/Existence_problems&amp;diff=13623</id>
		<title>组合数学 (Fall 2026)/Existence problems</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/Existence_problems&amp;diff=13623"/>
		<updated>2026-04-08T08:59:32Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;== Existence by Counting == === Shannon&amp;#039;s circuit lower bound=== This is a fundamental problem in in Computer Science.  A &amp;#039;&amp;#039;&amp;#039;boolean function&amp;#039;&amp;#039;&amp;#039; is a function in the form &amp;lt;math&amp;gt;f:\{0,1\}^n\rightarrow \{0,1\}&amp;lt;/math&amp;gt;.  [http://en.wikipedia.org/wiki/Boolean_circuit Boolean circuit] is a mathematical model of computation. Formally, a boolean circuit is a directed acyclic graph. Nodes with indegree zero are input nodes, labeled &amp;lt;math&amp;gt;x_1, x_2, \ldots , x_n&amp;lt;/math&amp;gt;. A circuit h...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Existence by Counting ==&lt;br /&gt;
=== Shannon&#039;s circuit lower bound===&lt;br /&gt;
This is a fundamental problem in in Computer Science.&lt;br /&gt;
&lt;br /&gt;
A &#039;&#039;&#039;boolean function&#039;&#039;&#039; is a function in the form &amp;lt;math&amp;gt;f:\{0,1\}^n\rightarrow \{0,1\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
[http://en.wikipedia.org/wiki/Boolean_circuit Boolean circuit] is a mathematical model of computation.&lt;br /&gt;
Formally, a boolean circuit is a directed acyclic graph. Nodes with indegree zero are input nodes, labeled &amp;lt;math&amp;gt;x_1, x_2, \ldots , x_n&amp;lt;/math&amp;gt;. A circuit has a unique node with outdegree zero, called the output node. Every other node is a gate. There are three types of gates: AND, OR (both with indegree two), and NOT (with indegree one).&lt;br /&gt;
&lt;br /&gt;
Computations in Turing machines can be simulated by circuits, and any boolean function in &#039;&#039;&#039;P&#039;&#039;&#039; can be computed by a circuit with polynomially many gates. Thus, if we can find a function in &#039;&#039;&#039;NP&#039;&#039;&#039; that cannot be computed by any circuit with polynomially many gates, then &#039;&#039;&#039;NP&#039;&#039;&#039;&amp;lt;math&amp;gt;\neq&amp;lt;/math&amp;gt;&#039;&#039;&#039;P&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
The following theorem due to Shannon says that functions with exponentially large circuit complexity do exist.&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Theorem (Shannon 1949)|&lt;br /&gt;
:There is a boolean function &amp;lt;math&amp;gt;f:\{0,1\}^n\rightarrow \{0,1\}&amp;lt;/math&amp;gt; with circuit complexity greater than &amp;lt;math&amp;gt;\frac{2^n}{3n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof| &lt;br /&gt;
We first count the number of boolean functions &amp;lt;math&amp;gt;f:\{0,1\}^n\rightarrow \{0,1\}&amp;lt;/math&amp;gt;. There are &amp;lt;math&amp;gt;2^{2^n}&amp;lt;/math&amp;gt; boolean functions &amp;lt;math&amp;gt;f:\{0,1\}^n\rightarrow \{0,1\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Then we count the number of boolean circuit with fixed number of gates.&lt;br /&gt;
Fix an integer &amp;lt;math&amp;gt;t&amp;lt;/math&amp;gt;, we count the number of circuits with &amp;lt;math&amp;gt;t&amp;lt;/math&amp;gt; gates. By the [http://en.wikipedia.org/wiki/De_Morgan&#039;s_laws De Morgan&#039;s laws], we can assume that all NOTs are pushed back to the inputs. Each gate has one of the two types (AND or OR), and has two inputs. Each of the inputs to a gate is either a constant 0 or 1, an input variable &amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt;, an inverted input variable &amp;lt;math&amp;gt;\neg x_i&amp;lt;/math&amp;gt;, or the output of another gate; thus, there are at most &amp;lt;math&amp;gt;2+2n+t-1&amp;lt;/math&amp;gt; possible gate inputs. It follows that the number of circuits with &amp;lt;math&amp;gt;t&amp;lt;/math&amp;gt; gates is at most &amp;lt;math&amp;gt;2^t(t+2n+1)^{2t}&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
If &amp;lt;math&amp;gt;t=2^n/3n&amp;lt;/math&amp;gt;, then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\frac{2^t(t+2n+1)^{2t}}{2^{2^n}}=o(1)&amp;lt;1,&amp;lt;/math&amp;gt;      thus, &amp;lt;math&amp;gt;2^t(t+2n+1)^{2t} &amp;lt; 2^{2^n}.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Each boolean circuit computes one boolean function. Therefore, there must exist a boolean function &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; which cannot be computed by any circuits with &amp;lt;math&amp;gt;2^n/3n&amp;lt;/math&amp;gt; gates.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Note that by Shannon&#039;s theorem, not only there exists a boolean function with exponentially large circuit complexity, but &#039;&#039;almost all&#039;&#039; boolean functions have exponentially large circuit complexity.&lt;br /&gt;
&lt;br /&gt;
=== Double counting ===&lt;br /&gt;
The double counting principle states the following obvious fact: if the elements of a set are counted in two different ways, the answers are the same.&lt;br /&gt;
==== Handshaking lemma ====&lt;br /&gt;
The following lemma is a standard demonstration of double counting.&lt;br /&gt;
{{Theorem|Handshaking Lemma|&lt;br /&gt;
:At a party, the number of guests who shake hands an odd number of times is even.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
We model this scenario as an undirected graph &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;|V|=n&amp;lt;/math&amp;gt; standing for the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; guests. There is an edge &amp;lt;math&amp;gt;uv\in E&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; shake hands. Let &amp;lt;math&amp;gt;d(v)&amp;lt;/math&amp;gt; be the degree of vertex &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt;, which represents the number of times that &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; shakes hand. The handshaking lemma states that in any undirected graph, the number of vertices whose degrees are odd is even. It is sufficient to show that the sum of odd degrees is even.&lt;br /&gt;
&lt;br /&gt;
The handshaking lemma is a direct consequence of the following lemma, which is proved by Euler in his 1736 paper on [http://en.wikipedia.org/wiki/Seven_Bridges_of_K%C3%B6nigsberg Seven Bridges of Königsberg] that began the study of graph theory.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Lemma (Euler 1736)|&lt;br /&gt;
:&amp;lt;math&amp;gt;\sum_{v\in V}d(v)=2|E|&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
We count the number of &#039;&#039;&#039;directed&#039;&#039;&#039; edges. A directed edge is an ordered pair &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;\{u,v\}\in E&amp;lt;/math&amp;gt;. There are two ways to count the directed edges.&lt;br /&gt;
&lt;br /&gt;
First, we can enumerate by edges. Pick every edge &amp;lt;math&amp;gt;uv\in E&amp;lt;/math&amp;gt; and apply two directions &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;(v,u)&amp;lt;/math&amp;gt; to the edge. This gives us &amp;lt;math&amp;gt;2|E|&amp;lt;/math&amp;gt; directed edges.&lt;br /&gt;
&lt;br /&gt;
On the other hand, we can enumerate by vertices. Pick every vertex &amp;lt;math&amp;gt;v\in V&amp;lt;/math&amp;gt; and for each of its &amp;lt;math&amp;gt;d(v)&amp;lt;/math&amp;gt; neighbors, say &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt;, generate a directed edge &amp;lt;math&amp;gt;(v,u)&amp;lt;/math&amp;gt;. This gives us &amp;lt;math&amp;gt;\sum_{v\in V}d(v)&amp;lt;/math&amp;gt; directed edges.&lt;br /&gt;
&lt;br /&gt;
It is obvious that the two terms are equal, since we just count the same thing twice with different methods. The lemma follows.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The handshaking lemma is implied directly by the above lemma, since the sum of even degrees is even.&lt;br /&gt;
==== Sperner&#039;s lemma ====&lt;br /&gt;
A &#039;&#039;&#039;triangulation&#039;&#039;&#039; of a triangle &amp;lt;math&amp;gt;abc&amp;lt;/math&amp;gt; is a decomposition of &amp;lt;math&amp;gt;abc&amp;lt;/math&amp;gt; to small triangles (called &#039;&#039;cells&#039;&#039;), such that any two different cells are either disjoint, or share an edge, or a vertex.&lt;br /&gt;
&lt;br /&gt;
A &#039;&#039;&#039;proper coloring&#039;&#039;&#039; of a triangulation of triangle &amp;lt;math&amp;gt;abc&amp;lt;/math&amp;gt; is a coloring of all vertices in the triangulation with three colors: &amp;lt;font color=red&amp;gt;red&amp;lt;/font&amp;gt;, &amp;lt;font color=blue&amp;gt;blue&amp;lt;/font&amp;gt;, and &amp;lt;font color=green&amp;gt;green&amp;lt;/font&amp;gt;, such that the following constraints are satisfied:&lt;br /&gt;
* The three vertices &amp;lt;math&amp;gt;a,b&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt; of the big triangle receive all three colors.&lt;br /&gt;
* The vertices in each of the three lines &amp;lt;math&amp;gt;ab&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;bc&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;ac&amp;lt;/math&amp;gt; receive two colors. &lt;br /&gt;
&lt;br /&gt;
The following figure is an example of a properly colored triangulation.&lt;br /&gt;
[[Image:sperner-triangle.png|260px|center]]&lt;br /&gt;
&lt;br /&gt;
In 1928 young Emanuel Sperner gave a combinatorial proof of the famous Brouwer&#039;s fixed point theorem by proving the following lemma (now called Sperner&#039;s lemma), with an extremely elegant proof.&lt;br /&gt;
{{Theorem|Sperner&#039;s Lemma (1928)|&lt;br /&gt;
:For any properly colored triangulation, there exists a cell receiving all three colors.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
The proof is done by appropriately constructing a dual graph of the triangulation. &lt;br /&gt;
&lt;br /&gt;
The dual graph is defined as follows:&lt;br /&gt;
* Each cell in the triangulation corresponds to a distinct vertex in the dual graph.&lt;br /&gt;
* The outer space corresponds to a distinct vertex in the dual graph.&lt;br /&gt;
* An edge is added between two vertices in the dual graph if the corresponding cells share a &amp;lt;math&amp;gt;{\color{Red}\mbox{red}}\mbox{--}{\color{Blue}\mbox{blue}}&amp;lt;/math&amp;gt; edge.&lt;br /&gt;
&lt;br /&gt;
The following is an example of the dual graph of a properly colored triangulation:&lt;br /&gt;
[[Image:sperner-dual.png|260px|center]]&lt;br /&gt;
&lt;br /&gt;
For vertices in the dual graph:&lt;br /&gt;
* If a cell receives all three colors, the corresponding vertex in the dual graph has degree 1;&lt;br /&gt;
* if a cell receives only &amp;lt;math&amp;gt;{\color{Red}\mbox{red}}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;{\color{Blue}\mbox{blue}}&amp;lt;/math&amp;gt;, the corresponding vertex has degree 2;&lt;br /&gt;
* for all other cases (the cell is monochromatic, or does not have blue or red), the corresponding vertex has degree 0.&lt;br /&gt;
&lt;br /&gt;
Besides, the unique vertex corresponding to the outer space must have odd degree, since the number of &amp;lt;math&amp;gt;{\color{Red}\mbox{red}}\mbox{--}{\color{Blue}\mbox{blue}}&amp;lt;/math&amp;gt; transitions between a &amp;lt;math&amp;gt;{\color{Red}\mbox{red}}&amp;lt;/math&amp;gt; endpoint and a &amp;lt;math&amp;gt;{\color{Blue}\mbox{blue}}&amp;lt;/math&amp;gt; endpoint must be odd.&lt;br /&gt;
&lt;br /&gt;
By handshaking lemma, the number of odd-degree vertices in the dual graph is even, thus the number of cells receiving all three colors must be odd, which cannot be zero.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== The Pigeonhole Principle ==&lt;br /&gt;
The &#039;&#039;&#039;pigeonhole principle&#039;&#039;&#039; states the following &amp;quot;obvious&amp;quot; fact:&lt;br /&gt;
:&#039;&#039;&amp;lt;math&amp;gt;n+1&amp;lt;/math&amp;gt; pigeons cannot sit in &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; holes so that every pigeon is alone in its hole.&#039;&#039;&lt;br /&gt;
This is one of the oldest &#039;&#039;&#039;non-constructive&#039;&#039;&#039; principles: it states only the &#039;&#039;existence&#039;&#039; of a pigeonhole with more than one pigeons and says nothing about how to &#039;&#039;find&#039;&#039; such a pigeonhole.&lt;br /&gt;
&lt;br /&gt;
The general form of pigeonhole principle, also known as the &#039;&#039;&#039;averaging principle&#039;&#039;&#039;, is stated as follows.&lt;br /&gt;
{{Theorem|Generalized pigeonhole principle|&lt;br /&gt;
:If a set consisting of more than &amp;lt;math&amp;gt;mn&amp;lt;/math&amp;gt; objects is partitioned into &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; classes, then some class receives more than &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; objects.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Inevitable divisors ===&lt;br /&gt;
The following is one of Erdős&#039; favorite initiation questions to mathematics. The proof uses the Pigeonhole Principle.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:For any subset &amp;lt;math&amp;gt;S\subseteq\{1,2,\ldots,2n\}&amp;lt;/math&amp;gt; of size &amp;lt;math&amp;gt;|S|&amp;gt;n\,&amp;lt;/math&amp;gt;, there are two numbers &amp;lt;math&amp;gt;a,b\in S&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;a|b\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
For every odd number &amp;lt;math&amp;gt;m\in\{1,2,\ldots,2n\}&amp;lt;/math&amp;gt;, let &lt;br /&gt;
:&amp;lt;math&amp;gt;C_m=\{2^km\mid k\ge 0, 2^km\le 2n\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
It is easy to see that for any &amp;lt;math&amp;gt;b&amp;lt;a&amp;lt;/math&amp;gt; from the same &amp;lt;math&amp;gt;C_m&amp;lt;/math&amp;gt;, it holds that &amp;lt;math&amp;gt;a|b&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Every number &amp;lt;math&amp;gt;a\in S&amp;lt;/math&amp;gt; can be uniquely represented as &amp;lt;math&amp;gt;a=2^km&amp;lt;/math&amp;gt; for some odd number &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;, thus belongs to exactly one of &amp;lt;math&amp;gt;C_m&amp;lt;/math&amp;gt;, for odd &amp;lt;math&amp;gt;m\in\{1,2,\ldots, 2n\}&amp;lt;/math&amp;gt;.  There are &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; odd numbers in &amp;lt;math&amp;gt;\{1,2,\ldots,2n\}&amp;lt;/math&amp;gt;, thus &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; different &amp;lt;math&amp;gt;C_m&amp;lt;/math&amp;gt;, but &amp;lt;math&amp;gt;|S|&amp;gt;n&amp;lt;/math&amp;gt;, thus there must exist distinct &amp;lt;math&amp;gt;a,b\in S&amp;lt;/math&amp;gt;, supposed that &amp;lt;math&amp;gt;b&amp;lt;a&amp;lt;/math&amp;gt;, belonging to the same &amp;lt;math&amp;gt;C_m&amp;lt;/math&amp;gt;, which implies that &amp;lt;math&amp;gt;a|b&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Monotonic subsequences ===&lt;br /&gt;
Let &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_n)&amp;lt;/math&amp;gt; be a sequence of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct real numbers. A &#039;&#039;&#039;subsequence&#039;&#039;&#039; is a sequence of distinct terms of &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_n)&amp;lt;/math&amp;gt; appearing in the same order in which they appear in &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_n)&amp;lt;/math&amp;gt;. Formally, a subsequence of &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_n)&amp;lt;/math&amp;gt; is an &amp;lt;math&amp;gt;(a_{i_1},a_{i_2},\ldots,a_{i_k})&amp;lt;/math&amp;gt;, with &amp;lt;math&amp;gt;i_1&amp;lt;i_2&amp;lt;\cdots&amp;lt;i_k&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
A sequence &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_n)&amp;lt;/math&amp;gt; is &#039;&#039;&#039;increasing&#039;&#039;&#039; if &amp;lt;math&amp;gt;a_1&amp;lt;a_2&amp;lt;\cdots&amp;lt;a_n&amp;lt;/math&amp;gt;, and &#039;&#039;&#039;decreasing&#039;&#039;&#039; if &amp;lt;math&amp;gt;a_1&amp;gt;a_2&amp;gt;\cdots&amp;gt;a_n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We are interested in the &#039;&#039;longest&#039;&#039; increasing and decreasing subsequences of an &amp;lt;math&amp;gt;a_1&amp;lt;a_2&amp;lt;\cdots&amp;lt;a_n&amp;lt;/math&amp;gt;. It is intuitive that the length of both the longest increasing subsequence and the longest decreasing subsequence cannot be small simultaneously. A famous result of Erdős and Szekeres formally justifies this intuition. This is one of the first results in extremal combinatorics, published in the influential 1935 paper of Erdős and Szekeres.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem (Erdős-Szekeres 1935)|&lt;br /&gt;
:A sequence of more than &amp;lt;math&amp;gt;mn&amp;lt;/math&amp;gt; different real numbers must contain either an increasing subsequence of length &amp;lt;math&amp;gt;m+1&amp;lt;/math&amp;gt;, or a decreasing subsequence of length &amp;lt;math&amp;gt;n+1&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|(due to Seidenberg 1959)&lt;br /&gt;
Let &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_{N})&amp;lt;/math&amp;gt; be the original sequence of &amp;lt;math&amp;gt;N&amp;gt;mn&amp;lt;/math&amp;gt; distinct real numbers. Associate each &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; a pair &amp;lt;math&amp;gt;(x_i,y_i)&amp;lt;/math&amp;gt;, defined as:&lt;br /&gt;
*&amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt;: the length of the longest &#039;&#039;increasing&#039;&#039; subsequence &#039;&#039;ending&#039;&#039; at &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;;&lt;br /&gt;
*&amp;lt;math&amp;gt;y_i&amp;lt;/math&amp;gt;: the length of the longest &#039;&#039;decreasing&#039;&#039; subsequence &#039;&#039;starting&#039;&#039; at &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;.&lt;br /&gt;
A key observation is that &amp;lt;math&amp;gt;(x_i,y_i)\neq (x_j,y_j)&amp;lt;/math&amp;gt; whenever &amp;lt;math&amp;gt;i\neq j&amp;lt;/math&amp;gt;. This is proved as follows:&lt;br /&gt;
: &#039;&#039;&#039;Case 1:&#039;&#039;&#039; If &amp;lt;math&amp;gt;a_i&amp;lt;a_j&amp;lt;/math&amp;gt;, then the longest increasing subsequence ending at &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; can be extended by adding on &amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;, so &amp;lt;math&amp;gt;x_i&amp;lt;x_j&amp;lt;/math&amp;gt;.&lt;br /&gt;
: &#039;&#039;&#039;Case 2:&#039;&#039;&#039;  If &amp;lt;math&amp;gt;a_i&amp;gt;a_j&amp;lt;/math&amp;gt;, then the longest decreasing subsequence starting at &amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt; can be preceded by &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;, so &amp;lt;math&amp;gt;y_i&amp;gt;y_j&amp;lt;/math&amp;gt;.&lt;br /&gt;
Now we put &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt; &amp;quot;pigeons&amp;quot; &amp;lt;math&amp;gt;a_1,a_2,\ldots,a_N&amp;lt;/math&amp;gt; into &amp;quot;pigeonholes&amp;quot; &amp;lt;math&amp;gt;\{1,2,\ldots,N\}\times\{1,2,\ldots,N\}&amp;lt;/math&amp;gt;, such that &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; is put into hole &amp;lt;math&amp;gt;(x_i,y_i)&amp;lt;/math&amp;gt;, with at most one pigeon per each hole (since different &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; has different &amp;lt;math&amp;gt;(x_i,y_i)&amp;lt;/math&amp;gt;). &lt;br /&gt;
&lt;br /&gt;
The number of pigeons is &amp;lt;math&amp;gt;N&amp;gt;mn&amp;lt;/math&amp;gt;. Due to pigeonhole principle, there must be a pigeon which is outside the region &amp;lt;math&amp;gt;\{1,2,\ldots,m\}\times\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;, which implies that there exists an &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; with either &amp;lt;math&amp;gt;x_i&amp;gt;m&amp;lt;/math&amp;gt; or &amp;lt;math&amp;gt;y_i&amp;gt;n&amp;lt;/math&amp;gt;. Due to our definition of &amp;lt;math&amp;gt;(x_i,y_i)&amp;lt;/math&amp;gt;, there must be either an increasing subsequence of length &amp;lt;math&amp;gt;m+1&amp;lt;/math&amp;gt;, or a decreasing subsequence of length &amp;lt;math&amp;gt;n+1&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Dirichlet&#039;s approximation ===&lt;br /&gt;
Let &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; be an irrational number. We now want to approximate &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; be a rational number (a fraction).&lt;br /&gt;
&lt;br /&gt;
Since every real interval &amp;lt;math&amp;gt;[a,b]&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;a&amp;lt;b&amp;lt;/math&amp;gt; contains infinitely many rational numbers, there must exist rational numbers arbitrarily close to &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;. The trick is to let the denominator of the fraction sufficiently large.&lt;br /&gt;
&lt;br /&gt;
Suppose however we restrict the rationals we may select to have denominators bounded by &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. How closely we can approximate &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; now?&lt;br /&gt;
&lt;br /&gt;
The following important theorem is due to Dirichlet and his &#039;&#039;Schubfachprinzip&#039;&#039; (&amp;quot;drawer principle&amp;quot;). The theorem is fundamental in numer theory and real analysis, but the proof is combinatorial.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem (Dirichlet 1879)|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; be an irrational number. For any natural number &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, there is a rational number &amp;lt;math&amp;gt;\frac{p}{q}&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;1\le q\le n&amp;lt;/math&amp;gt; and &lt;br /&gt;
::&amp;lt;math&amp;gt;\left|x-\frac{p}{q}\right|&amp;lt;\frac{1}{nq}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Let &amp;lt;math&amp;gt;\{x\}=x-\lfloor x\rfloor&amp;lt;/math&amp;gt; denote the &#039;&#039;&#039;fractional part&#039;&#039;&#039; of the real number &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;. It is obvious that &amp;lt;math&amp;gt;\{x\}\in[0,1)&amp;lt;/math&amp;gt; for any real number &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Consider the &amp;lt;math&amp;gt;n+1&amp;lt;/math&amp;gt; numbers &amp;lt;math&amp;gt;\{kx\}&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;k=1,2,\ldots,n+1&amp;lt;/math&amp;gt;. These &amp;lt;math&amp;gt;n+1&amp;lt;/math&amp;gt; numbers (pigeons) belong to the following &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; intervals (pigeonholes):&lt;br /&gt;
:&amp;lt;math&amp;gt;\left(0,\frac{1}{n}\right),\left(\frac{1}{n},\frac{2}{n}\right),\ldots,\left(\frac{n-1}{n},1\right)&amp;lt;/math&amp;gt;.&lt;br /&gt;
Since &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; is irrational, &amp;lt;math&amp;gt;\{kx\}&amp;lt;/math&amp;gt; cannot coincide with any endpoint of the above intervals.&lt;br /&gt;
&lt;br /&gt;
By the pigeonhole principle, there exist &amp;lt;math&amp;gt;1\le a&amp;lt;b\le n+1&amp;lt;/math&amp;gt;, such that &amp;lt;math&amp;gt;\{ax\},\{bx\}&amp;lt;/math&amp;gt; are in the same interval, thus&lt;br /&gt;
:&amp;lt;math&amp;gt;|\{bx\}-\{ax\}|&amp;lt;\frac{1}{n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
Therefore,&lt;br /&gt;
:&amp;lt;math&amp;gt;|(b-a)x-\left(\lfloor bx\rfloor-\lfloor ax\rfloor\right)|&amp;lt;\frac{1}{n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
Let &amp;lt;math&amp;gt;q=b-a&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;p=\lfloor bx\rfloor-\lfloor ax\rfloor&amp;lt;/math&amp;gt;. We have &amp;lt;math&amp;gt;|qx-p|&amp;lt;\frac{1}{n}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;1\le q\le n&amp;lt;/math&amp;gt;. Dividing both sides by &amp;lt;math&amp;gt;q&amp;lt;/math&amp;gt;, the theorem is proved.&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13622</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13622"/>
		<updated>2026-04-08T08:59:09Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2026/03/25)&#039;&#039;&#039;&amp;lt;font color=red size=4&amp;gt; 第一次作业已发布&amp;lt;/font&amp;gt;，请在 2026/04/08 上课之前提交到 [mailto:njucomb26@163.com njucomb26@163.com] (文件名为&#039;学号_姓名_A1.pdf&#039;)&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行([mailto:652024330006@smail.nju.edu.cn 652024330006@smail.nju.edu.cn])&lt;br /&gt;
** 周灿&lt;br /&gt;
** 方子伊&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* [[组合数学 (Spring 2026)/Problem Set 1|Problem Set 1]]&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Sieve methods|Sieve methods | 筛法]] ([http://tcs.nju.edu.cn/slides/comb2026/PIE.pdf slides])&lt;br /&gt;
# Guest lecture by Prof. Penghui Yao on entropy and counting ([http://tcs.nju.edu.cn/slides/comb2026/entropy.pdf notes]) &lt;br /&gt;
# [[组合数学 (Fall 2026)/Cayley&#039;s formula|Cayley&#039;s formula | Cayley公式]]  ([http://tcs.nju.edu.cn/slides/comb2026/Cayley.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Existence problems|Existence problems | 存在性问题]]&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13621</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13621"/>
		<updated>2026-04-08T08:54:40Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2026/03/25)&#039;&#039;&#039;&amp;lt;font color=red size=4&amp;gt; 第一次作业已发布&amp;lt;/font&amp;gt;，请在 2026/04/08 上课之前提交到 [mailto:njucomb26@163.com njucomb26@163.com] (文件名为&#039;学号_姓名_A1.pdf&#039;)&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行([mailto:652024330006@smail.nju.edu.cn 652024330006@smail.nju.edu.cn])&lt;br /&gt;
** 周灿&lt;br /&gt;
** 方子伊&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* [[组合数学 (Spring 2026)/Problem Set 1|Problem Set 1]]&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Sieve methods|Sieve methods | 筛法]] ([http://tcs.nju.edu.cn/slides/comb2026/PIE.pdf slides])&lt;br /&gt;
# Guest lecture by Prof. Penghui Yao on entropy and counting ([http://tcs.nju.edu.cn/slides/comb2026/entropy.pdf notes]) &lt;br /&gt;
# [[组合数学 (Fall 2026)/Cayley&#039;s formula|Cayley&#039;s formula | Cayley公式]]  ([http://tcs.nju.edu.cn/slides/comb2026/Cayley.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13620</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13620"/>
		<updated>2026-04-08T08:52:23Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2026/03/25)&#039;&#039;&#039;&amp;lt;font color=red size=4&amp;gt; 第一次作业已发布&amp;lt;/font&amp;gt;，请在 2026/04/08 上课之前提交到 [mailto:njucomb26@163.com njucomb26@163.com] (文件名为&#039;学号_姓名_A1.pdf&#039;)&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行([mailto:652024330006@smail.nju.edu.cn 652024330006@smail.nju.edu.cn])&lt;br /&gt;
** 周灿&lt;br /&gt;
** 方子伊&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* [[组合数学 (Spring 2026)/Problem Set 1|Problem Set 1]]&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Sieve methods|Sieve methods | 筛法]] ([http://tcs.nju.edu.cn/slides/comb2026/PIE.pdf slides])&lt;br /&gt;
# Guest lecture by Prof. Penghui Yao on [http://tcs.nju.edu.cn/slides/comb2026/entropy.pdf entropy and counting] &lt;br /&gt;
# [[组合数学 (Fall 2026)/Cayley&#039;s formula|Cayley&#039;s formula | Cayley公式]]  ([http://tcs.nju.edu.cn/slides/comb2026/Cayley.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/Cayley%27s_formula&amp;diff=13619</id>
		<title>组合数学 (Fall 2026)/Cayley&#039;s formula</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/Cayley%27s_formula&amp;diff=13619"/>
		<updated>2026-04-08T08:45:55Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;== Cayley&amp;#039;s Formula == We now present a theorem of the number of labeled trees on a fixed number of vertices. It is due to [http://en.wikipedia.org/wiki/Arthur_Cayley Cayley] in 1889. The theorem is often referred by the name [http://en.wikipedia.org/wiki/Cayley&amp;#039;s_formula Cayley&amp;#039;s formula].  {{Theorem|Cayley&amp;#039;s formula for trees| : There are &amp;lt;math&amp;gt;n^{n-2}&amp;lt;/math&amp;gt; different trees on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct vertices. }}  The theorem has several proofs, including the bijectio...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Cayley&#039;s Formula ==&lt;br /&gt;
We now present a theorem of the number of labeled trees on a fixed number of vertices. It is due to [http://en.wikipedia.org/wiki/Arthur_Cayley Cayley] in 1889. The theorem is often referred by the name [http://en.wikipedia.org/wiki/Cayley&#039;s_formula Cayley&#039;s formula].&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Cayley&#039;s formula for trees|&lt;br /&gt;
: There are &amp;lt;math&amp;gt;n^{n-2}&amp;lt;/math&amp;gt; different trees on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct vertices.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The theorem has several proofs, including the bijection which encodes a tree by a [http://en.wikipedia.org/wiki/Pr%C3%BCfer_sequence Prüfer code], through the [http://en.wikipedia.org/wiki/Kirchhoff&#039;s_matrix_tree_theorem Kirchhoff&#039;s matrix tree theorem], and by double counting.&lt;br /&gt;
&lt;br /&gt;
=== Proof of Cayley&#039;s formula by double counting ===&lt;br /&gt;
We now present a double counting proof, which is considered by the [http://en.wikipedia.org/wiki/Proofs_from_THE_BOOK Proofs from THE BOOK] &amp;quot;the most beautiful of them all&amp;quot;.&lt;br /&gt;
{{Prooftitle|Proof of Cayley&#039;s formula by double counting|&lt;br /&gt;
(Due to Pitman 1999)&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;T_n&amp;lt;/math&amp;gt; be the number of different trees defined on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct vertices.&lt;br /&gt;
&lt;br /&gt;
A &#039;&#039;&#039;rooted tree&#039;&#039;&#039; is a tree with a special vertex. That is, one of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices is marked as the &amp;quot;root&amp;quot; of the tree. A rooted tree defines a natural direction of all edges, such that an edge &amp;lt;math&amp;gt;uv&amp;lt;/math&amp;gt; of the tree is directed from &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt; is before &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; along the unique path from the root.&lt;br /&gt;
&lt;br /&gt;
We count the number of different &#039;&#039;sequences&#039;&#039; of directed edges that can be added to an empty graph on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices to form from it a &#039;&#039;rooted&#039;&#039; tree. We note that such a sequence can be formed in two ways:&lt;br /&gt;
# Starting with an unrooted tree, choose one of its vertices as root, and fix an total order of edges to specify the order in which the edges are added.&lt;br /&gt;
# Starting from an empty graph, add the edges one by one in steps.&lt;br /&gt;
&lt;br /&gt;
In the first method, we pick one of the &amp;lt;math&amp;gt;T_n&amp;lt;/math&amp;gt; unrooted trees, choose one of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices as the root, and pick one of the &amp;lt;math&amp;gt;(n-1)!&amp;lt;/math&amp;gt; total orders of the &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; edges. This gives us &amp;lt;math&amp;gt;T_nn(n-1)!=T_nn!&amp;lt;/math&amp;gt; ways.&lt;br /&gt;
&lt;br /&gt;
In the second method, we consider the number of choices in one step, and multiply the numbers of choices in all steps. This is done as follows.&lt;br /&gt;
&lt;br /&gt;
Given a sequence of &#039;&#039;adding&#039;&#039; &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; edges to an empty graph to form a rooted tree, we reverse this sequence and get a sequence of &#039;&#039;removing&#039;&#039; edges one by one from the final rooted tree until no edge left. We observe that:&lt;br /&gt;
* At first, we remove an edge from the rooted tree. Suppose that the root of the tree is &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt;, and the removed directed edge is &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt;.  After removing &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt;, the original rooted tree is disconnected into two rooted trees, one rooted at &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; and the other rooted at &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt;.&lt;br /&gt;
* After removing &amp;lt;math&amp;gt;k-1&amp;lt;/math&amp;gt; edges, there are &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; rooted trees. In the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;th step, a directed edge &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt; in the current forest is removed and the tree containing &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt; is disconnected into two trees, one rooted at the old root of that tree, and the other rooted at &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We now again reverse the above procedure, and consider the sequence of adding directed edges to an empty graph to form a rooted tree.&lt;br /&gt;
* At first, we have &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; rooted trees, each of 0 edge (&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; isolated vertices).&lt;br /&gt;
* After adding &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; edges, there are &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; rooted trees. Denoting the directed edge added next as &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt;. As observed above, &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt; can be any one of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices; but &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; must be the root of one of the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; trees, except the tree which contains &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt;. There are &amp;lt;math&amp;gt;n(k-1)&amp;lt;/math&amp;gt; choices of such &amp;lt;math&amp;gt;(u,v)&amp;lt;/math&amp;gt;.&lt;br /&gt;
Multiplying the numbers of choices in all steps, the number of sequences of adding directed edges to an empty graph to form a rooted tree is given by&lt;br /&gt;
:&amp;lt;math&amp;gt;\prod_{k=2}^nn(k-1)=n^{n-2}n!&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
By the principle of double counting, counting the same thing by different methods yield the same result.&lt;br /&gt;
:&amp;lt;math&amp;gt;T_nn!=n^{n-2}n!&amp;lt;/math&amp;gt;,&lt;br /&gt;
which gives that &amp;lt;math&amp;gt;T_n=n^{n-2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==  Prüfer code ==&lt;br /&gt;
The Prüfer code encodes a labeled tree to a sequence of labels. This gives a bijections between trees and tuples.&lt;br /&gt;
&lt;br /&gt;
=== Encoding  ===&lt;br /&gt;
In a tree, the vertices of degree 1 are called leaves. It is easy to see that:&lt;br /&gt;
* each tree has at least two leaves; and&lt;br /&gt;
* after removing a leaf (along with the edge adjacent to it) from a tree, the resulting graph is still a tree. &lt;br /&gt;
&lt;br /&gt;
The following algorithm transforms a tree &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices &amp;lt;math&amp;gt;1,2,\ldots,n&amp;lt;/math&amp;gt;, to a tuple &amp;lt;math&amp;gt;(v_1,v_2,\ldots,v_{n-2})\in\{1,2,\ldots,n\}^{n-2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
{{Theorem| Prüfer code (encoder)|&lt;br /&gt;
:&#039;&#039;&#039;Input&#039;&#039;&#039;: A tree &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct vertices, labeled by &amp;lt;math&amp;gt;1,2,\ldots,n&amp;lt;/math&amp;gt;.&lt;br /&gt;
:&lt;br /&gt;
:let &amp;lt;math&amp;gt;T_1=T&amp;lt;/math&amp;gt;;&lt;br /&gt;
:for &amp;lt;math&amp;gt;i=1&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt;, do&lt;br /&gt;
::let &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt; be the leaf in &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; with the smallest label, and &amp;lt;math&amp;gt;v_i&amp;lt;/math&amp;gt; be its neighbor;&lt;br /&gt;
::let &amp;lt;math&amp;gt;T_{i+1}&amp;lt;/math&amp;gt; be the new tree obtained from deleting the leaf &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt; from &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt;;&lt;br /&gt;
:end&lt;br /&gt;
:return &amp;lt;math&amp;gt;(v_1,v_2,\ldots,v_{n-2})&amp;lt;/math&amp;gt;;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Decoding ===&lt;br /&gt;
It is trivial to observe the following lemma:&lt;br /&gt;
{{Theorem|Lemma 1|&lt;br /&gt;
:For each &amp;lt;math&amp;gt;1\le i\le n-1&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; is a tree of &amp;lt;math&amp;gt;n-i+1&amp;lt;/math&amp;gt; vertices. In particular, the vertices of &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; are  &amp;lt;math&amp;gt;u_i,u_{i+1},\ldots,u_{n-1},v_{n-1}&amp;lt;/math&amp;gt;, and the edges of &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; are precisely &amp;lt;math&amp;gt;\{u_j,v_j\}&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;i\le j\le n-1&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
And there is a reason that we do not need to store &amp;lt;math&amp;gt;v_{n-1}&amp;lt;/math&amp;gt; in the Prüfer code.&lt;br /&gt;
{{Theorem|Lemma 2|&lt;br /&gt;
:It always holds that &amp;lt;math&amp;gt;v_{n-1}=n&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Every tree (of at least two vertices) has at least two leaves. The &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;1\le i\le n-1&amp;lt;/math&amp;gt;, are the leaf of the smallest label in &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt;, which can never be &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, thus &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is never deleted.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Lemma 1 and 2 together imply that given a Prüfer code &amp;lt;math&amp;gt;(v_1,v_2,\ldots,v_{n-2})&amp;lt;/math&amp;gt;, the only remaining task to reconstruct the tree &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; is to figure out those &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;1\le i\le n-1&amp;lt;/math&amp;gt;. The following lemma state how to obtain &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;1\le i\le n-1&amp;lt;/math&amp;gt;, from a Prüfer code &amp;lt;math&amp;gt;(v_1,v_2,\ldots,v_{n-2})&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Lemma 3|&lt;br /&gt;
:For &amp;lt;math&amp;gt;i=1,2,\ldots,n-1&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt; is the smallest element of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; not in &amp;lt;math&amp;gt;\{u_1,\ldots,u_{i-1}\}\cup\{v_i,\ldots,v_{n-1}\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Note that &amp;lt;math&amp;gt;u_1,u_2,\ldots,u_{n-1},v_{n-1}&amp;lt;/math&amp;gt; is a sequence of distinct vertices, because &amp;lt;math&amp;gt;u_1,u_2,\ldots,u_{n-1}&amp;lt;/math&amp;gt; are deleted one by one from the tree, and &amp;lt;math&amp;gt;v_{n-1}=n&amp;lt;/math&amp;gt; is never deleted. Thus, each vertex &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; appears among &amp;lt;math&amp;gt;u_1,u_2,\ldots,u_{n-1},v_{n-1}&amp;lt;/math&amp;gt; exactly once. And each vertex &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; appears for &amp;lt;math&amp;gt;deg(v)&amp;lt;/math&amp;gt; times among the edges &amp;lt;math&amp;gt;\{u_i,v_i\}&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;1\le i\le n-1&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;deg(v)&amp;lt;/math&amp;gt; denotes the degree of vertex &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; in the original tree &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;. Therefore, each vertex &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; appears among  &amp;lt;math&amp;gt;v_1,v_2,\ldots,v_{n-2}&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;deg(v)-1&amp;lt;/math&amp;gt; times.&lt;br /&gt;
&lt;br /&gt;
Similarly, each vertex &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; appears among &amp;lt;math&amp;gt;v_i,v_{i+1},\ldots,v_{n-2}&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;deg_i(v)-1&amp;lt;/math&amp;gt; times, where &amp;lt;math&amp;gt;deg_i(v)&amp;lt;/math&amp;gt; is the degree of vertex &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; in the tree &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt;. In particular, the leaves of &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; are not among &amp;lt;math&amp;gt;\{v_i,v_{i+1},\ldots,v_{n-2}\}&amp;lt;/math&amp;gt;. Recall that the vertices of &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; are &amp;lt;math&amp;gt;u_i,u_{i+1},\ldots,u_{n-1},v_{n-1}&amp;lt;/math&amp;gt;. Then the leaves of &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; are the elements of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; not in &amp;lt;math&amp;gt;\{u_1,\ldots,u_{i-1}\}\cup\{v_i,\ldots,v_{n-1}\}&amp;lt;/math&amp;gt;. By definition of Prüfer code, &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt; is the leaf in &amp;lt;math&amp;gt;T_i&amp;lt;/math&amp;gt; of smallest label, hence the smallest element of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; not in &amp;lt;math&amp;gt;\{u_1,\ldots,u_{i-1}\}\cup\{v_i,\ldots,v_{n-1}\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Applying Lemma 3, we have the following decoder for the Prüfer code:&lt;br /&gt;
{{Theorem| Prüfer code (decoder)|&lt;br /&gt;
:&#039;&#039;&#039;Input&#039;&#039;&#039;: A tuple &amp;lt;math&amp;gt;(v_1,v_2,\ldots,v_{n-2})\in\{1,2,\ldots,n\}^{n-2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
:&lt;br /&gt;
:let &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; be empty graph, and &amp;lt;math&amp;gt;v_{n-1}=n&amp;lt;/math&amp;gt;;&lt;br /&gt;
:for &amp;lt;math&amp;gt;i=1&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt;, do&lt;br /&gt;
::let &amp;lt;math&amp;gt;u_i&amp;lt;/math&amp;gt; be the smallest label not in &amp;lt;math&amp;gt;\{u_1,\ldots,u_{i-1}\}\cup\{v_i,\ldots,v_{n-1}\}&amp;lt;/math&amp;gt;;&lt;br /&gt;
::add an edge &amp;lt;math&amp;gt;\{u_i,v_i\}&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;;&lt;br /&gt;
:end&lt;br /&gt;
:return &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;; &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
In other words, the encoding of trees to tuples by the Prüfer code is reversible, thus the mapping is injective (1-1). To see it is also surjective, we need to show that for every possible &amp;lt;math&amp;gt;(v_1,v_2,\ldots,v_{n-2})\in\{1,2,\ldots,n\}^{n-2}&amp;lt;/math&amp;gt;, the above decoder recovers a tree from it. &lt;br /&gt;
&lt;br /&gt;
It is easy to see that the decoder always returns a graph of &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; edges on the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices. The only thing remaining to verify is that the returned graph has no cycle in it, which can be easily proved by a timeline argument (left as an exercise).&lt;br /&gt;
&lt;br /&gt;
=== Bijection proof of Cayley&#039;s formula ===&lt;br /&gt;
Therefore, the Prüfer code establishes a bijection between the set of trees on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct vertices and the tuples from &amp;lt;math&amp;gt;\{1,2,\ldots,n\}^{n-2}&amp;lt;/math&amp;gt;. This proves Cayley&#039;s formula.&lt;br /&gt;
&lt;br /&gt;
== Kirchhoff&#039;s Matrix-Tree Theorem ==&lt;br /&gt;
Given an undirected graph &amp;lt;math&amp;gt;G([n],E)&amp;lt;/math&amp;gt;, the &#039;&#039;&#039;adjacency matrix&#039;&#039;&#039; &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; of graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; is an &amp;lt;math&amp;gt;n\times n&amp;lt;/math&amp;gt; matrix such that&lt;br /&gt;
:&amp;lt;math&amp;gt;A(i,j)=\begin{cases}&lt;br /&gt;
1 &amp;amp; \{i,j\}\in E,\\&lt;br /&gt;
0 &amp;amp; \{i,j\}\not\in E.&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Graph Laplacian===&lt;br /&gt;
Let &amp;lt;math&amp;gt;D&amp;lt;/math&amp;gt; be a &amp;lt;math&amp;gt;n\times n&amp;lt;/math&amp;gt; diagonal matrix such that&lt;br /&gt;
:&amp;lt;math&amp;gt;D(i,j)=\begin{cases}&lt;br /&gt;
\text{deg}(i) &amp;amp; i=j,\\&lt;br /&gt;
0 &amp;amp; i\neq j,&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
where &amp;lt;math&amp;gt;\text{deg}(i)&amp;lt;/math&amp;gt; denotes the degree of vertex &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Laplacian matrix&#039;&#039;&#039; &amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt; of graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; is defined as &amp;lt;math&amp;gt;L=D-A&amp;lt;/math&amp;gt;, that is,&lt;br /&gt;
:&amp;lt;math&amp;gt;L(i,j)=\begin{cases}&lt;br /&gt;
\text{deg}(i) &amp;amp; i=j,\\&lt;br /&gt;
-1 &amp;amp; i\neq j\text{ and } \{i,j\}\in E,\\&lt;br /&gt;
0 &amp;amp; \text{otherwise}.&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Suppose &amp;lt;math&amp;gt;G([n],E)&amp;lt;/math&amp;gt; has &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; edges. The &#039;&#039;&#039;incidence matrix&#039;&#039;&#039; &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; of graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; is an &amp;lt;math&amp;gt;n\times m&amp;lt;/math&amp;gt; matrix such that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\forall i\in[n], \forall e\in E,\quad B(i,e)=\begin{cases}&lt;br /&gt;
1 &amp;amp; e=\{i,j\}\text{ and } i&amp;lt;j,\\&lt;br /&gt;
-1 &amp;amp; e=\{i,j\}\text{ and } i&amp;gt;j,\\&lt;br /&gt;
0 &amp;amp; \text{otherwise}.&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following proposition is easy to verify.&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
:&amp;lt;math&amp;gt;L=BB^T&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
For any &amp;lt;math&amp;gt;i,j\in[n]&amp;lt;/math&amp;gt;, we have&lt;br /&gt;
:&amp;lt;math&amp;gt;(BB^T)(i,j)=\sum_{e\in E}B(i,e)B^T(e,j)=\sum_{e\in E}B(i,e)B(j,e)&amp;lt;/math&amp;gt;.&lt;br /&gt;
It is easy to verify that &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\sum_{e\in E}B(i,e)B(j,e)=&lt;br /&gt;
\begin{cases}&lt;br /&gt;
\text{deg}(i) &amp;amp; i=j,\\&lt;br /&gt;
-1 &amp;amp; i\neq j\text{ and } \{i,j\}\in E,\\&lt;br /&gt;
0 &amp;amp; \text{otherwise},&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
which is equal to the definition of &amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== The Matrix-tree Theorem ===&lt;br /&gt;
The matrix-tree theorem of Kirchhoff states a striking fact: The number of spanning trees in any connected graph can be computed as the determinant of some appropriate graph matrix. &lt;br /&gt;
{{Theorem|Kirchhoff&#039;s Matrix-Tree Theorem|&lt;br /&gt;
:For any connected graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; vertices, the number of spanning trees in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;\det(L_{i,i})\,&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;i\in[n]&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;L_{i,i}\,&amp;lt;/math&amp;gt; is the &amp;lt;math&amp;gt;(n-1)\times(n-1)&amp;lt;/math&amp;gt; matrix resulting from the Laplacian matrix &amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt; of graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; by deleting the &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;-th row and the &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;-th column.&lt;br /&gt;
}}&lt;br /&gt;
The determinant can be computed as fast as matrix multiplication, thus is quite efficient, especially when compared to our task: counting the number of subgraphs satisfying certain nontrivial global constraint (e.g. spanning tree). Such efficient algorithm is rarely seen for counting problems, which are usually #P-hard to compute (e.g. number of matchings in a graph).&lt;br /&gt;
&lt;br /&gt;
The key to prove the matrix-tree theorem is the Cauchy-Binet theorem in linear algebra, whose proof is beyond the scope of this class.&lt;br /&gt;
{{Theorem|Cauchy-Binet Theorem|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; be, respectively, &amp;lt;math&amp;gt;n\times m&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;m\times n&amp;lt;/math&amp;gt; matrix. For any &amp;lt;math&amp;gt;S\subseteq [m]&amp;lt;/math&amp;gt; of size &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;A_{[n], S}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B_{S,[n]}&amp;lt;/math&amp;gt; denote, respectively, the &amp;lt;math&amp;gt;n\times n&amp;lt;/math&amp;gt; submatrices of &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;, consisting of the columns of &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;, or the rows of &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;, indexed by elements of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
::&amp;lt;math&amp;gt;\det(AB)=\sum_{S\in{[m]\choose n}}\det(A_{[n],S})\det(B_{S,[n]}).&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; be the incidence matrix of graph &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;. Fix any vertex &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; be the &amp;lt;math&amp;gt;(n-1)\times m&amp;lt;/math&amp;gt; matrix resulting from &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; by deleting the &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;-th row. &lt;br /&gt;
&lt;br /&gt;
Recall that &amp;lt;math&amp;gt;L=BB^T&amp;lt;/math&amp;gt;. It is easy to verify that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
L_{i,i}=CC^T.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Due to the Cauchy-Binet Theorem, we have&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\det(L_{i,i})=\det(CC^T)&lt;br /&gt;
&amp;amp;=\sum_{S\in{[m]\choose n-1}}\det(C_{[n-1],S})\det(C^T_{S,[n-1]})\\&lt;br /&gt;
&amp;amp;=\sum_{S\in{[m]\choose n-1}}\det(C_{[n-1],S})^2.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The next lemma gives a key observation to prove the matrix-tree theorem.&lt;br /&gt;
{{Theorem|Lemma|&lt;br /&gt;
:For any &amp;lt;math&amp;gt;S\subseteq [m]&amp;lt;/math&amp;gt; of size &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt;, the value of &amp;lt;math&amp;gt;\det(C_{[n-1],S})&amp;lt;/math&amp;gt; is either 1, or -1, or 0. Moreover, &amp;lt;math&amp;gt;\det(C_{[n-1],S})=\pm1&amp;lt;/math&amp;gt; if and only if &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; indicates a spanning tree in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
We first show &amp;lt;math&amp;gt;\det(C_{[n-1],S})\in\{0,1,-1\}&amp;lt;/math&amp;gt; by induction on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. &lt;br /&gt;
Note that &amp;lt;math&amp;gt;C_{[n-1],S}&amp;lt;/math&amp;gt; is an &amp;lt;math&amp;gt;(n-1)\times (n-1)&amp;lt;/math&amp;gt; matrix such that each column contains at most one 1 and at most one -1, and all other entries are 0. For such matrix, when &amp;lt;math&amp;gt;n-1=1&amp;lt;/math&amp;gt;, the induction hypothesis &amp;lt;math&amp;gt;\det(C_{[n-1],S})\in\{0,1,-1\}&amp;lt;/math&amp;gt; is trivially true. And for general &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, if every column has a 1 and a -1, then the sum of all rows is the zero vector, so the matrix is singular.  Otherwise, expand the determinant by a column with one nonzero entry to find it is &amp;lt;math&amp;gt;\pm1&amp;lt;/math&amp;gt; times the determinant of a smaller matrix of the same property, which by induction hypothesis has value 0 or &amp;lt;math&amp;gt;\pm1&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We then show that &amp;lt;math&amp;gt;\det(C_{[n-1],S})&amp;lt;/math&amp;gt; is nonzero if and only if &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is a spanning tree. &lt;br /&gt;
&lt;br /&gt;
Suppose the &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; edges corresponding to &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is not a spanning tree of &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;. Then &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; must have more than one components, and there must be a component &amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt; not containing vertex &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;. The rows of &amp;lt;math&amp;gt;C_{[n-1],S}&amp;lt;/math&amp;gt; corresponding to &amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt; add to 0, thus these rows are linearly dependent, and hence &amp;lt;math&amp;gt;\det(C_{[n-1],S})=0&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Suppose the &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; edges corresponding to &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is a spanning tree of &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;. Then there is a vertex &amp;lt;math&amp;gt;j_1\neq i&amp;lt;/math&amp;gt; of degree 1 in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;; let &amp;lt;math&amp;gt;e_1&amp;lt;/math&amp;gt; be the edge in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; incident to &amp;lt;math&amp;gt;j_1&amp;lt;/math&amp;gt;. Deleting vertex &amp;lt;math&amp;gt;j_1&amp;lt;/math&amp;gt; and edge &amp;lt;math&amp;gt;e_1&amp;lt;/math&amp;gt; from &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;, we obtain a tree of &amp;lt;math&amp;gt;n-2&amp;lt;/math&amp;gt; edges. Again there is a vertex &amp;lt;math&amp;gt;j_2\neq i&amp;lt;/math&amp;gt; of degree 1 with incident edge &amp;lt;math&amp;gt;e_2&amp;lt;/math&amp;gt;. Continue this we enumerate all vertices except &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; as &amp;lt;math&amp;gt;j_1,j_2,\ldots,j_{n-1}&amp;lt;/math&amp;gt; and all edges in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; as &amp;lt;math&amp;gt;e_1,e_2,\ldots,e_{n-1}&amp;lt;/math&amp;gt;. Now permute the rows and columns of &amp;lt;math&amp;gt;C_{[n-1],S}&amp;lt;/math&amp;gt; such that the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-th row corresponds to vertex &amp;lt;math&amp;gt;j_k&amp;lt;/math&amp;gt; and the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-th column corresponds to &amp;lt;math&amp;gt;e_k&amp;lt;/math&amp;gt;. By our construction the permuted &amp;lt;math&amp;gt;C_{[n-1],S}&amp;lt;/math&amp;gt; is lower triangle with &amp;lt;math&amp;gt;\pm1&amp;lt;/math&amp;gt; diagonal entries, since when each &amp;lt;math&amp;gt;j_k&amp;lt;/math&amp;gt; is removed it is of degree 1 in the remaining tree and is incident to edge &amp;lt;math&amp;gt;e_k&amp;lt;/math&amp;gt;. Therefore, &amp;lt;math&amp;gt;\det(C_{[n-1],S})=\pm1&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The matrix-tree theorem follows as consequence. Recall we show that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\det(L_{i,i})&lt;br /&gt;
&amp;amp;=\sum_{S\in{[m]\choose n-1}}\det(C_{[n-1],S})^2.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
The sum enumerates over all subgraphs &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; edges, and by the above lemma &amp;lt;math&amp;gt;\det(C_{[n-1],S})^2=1&amp;lt;/math&amp;gt; if and only if &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is a spanning tree in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;. Therefore, &amp;lt;math&amp;gt;\det(L_{i,i})&amp;lt;/math&amp;gt; gives the number of spanning trees in &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Cayley&#039;s formula by the matrix-tree theorem ===&lt;br /&gt;
The number of trees of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct vertices equals the number of spanning trees in the complete graph &amp;lt;math&amp;gt;K_n&amp;lt;/math&amp;gt;. For &amp;lt;math&amp;gt;G=K_n&amp;lt;/math&amp;gt;, for any &amp;lt;math&amp;gt;i\in[n]&amp;lt;/math&amp;gt; the &amp;lt;math&amp;gt;(n-1)\times (n-1)&amp;lt;/math&amp;gt; matrix &amp;lt;math&amp;gt;L_{ii}&amp;lt;/math&amp;gt; is given by&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
L_{i,i}&lt;br /&gt;
=&lt;br /&gt;
\begin{bmatrix}&lt;br /&gt;
n-1 &amp;amp; -1 &amp;amp; \cdots &amp;amp; -1\\&lt;br /&gt;
-1 &amp;amp; n-1 &amp;amp; \cdots &amp;amp; -1\\&lt;br /&gt;
\vdots &amp;amp; \vdots &amp;amp; \ddots &amp;amp; -1\\&lt;br /&gt;
-1 &amp;amp; -1 &amp;amp; \cdots &amp;amp; n-1&lt;br /&gt;
\end{bmatrix},&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
whose determinant is &amp;lt;math&amp;gt;\det(L_{i,i})=n^{n-2}&amp;lt;/math&amp;gt;.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13618</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13618"/>
		<updated>2026-04-08T08:40:11Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2026/03/25)&#039;&#039;&#039;&amp;lt;font color=red size=4&amp;gt; 第一次作业已发布&amp;lt;/font&amp;gt;，请在 2026/04/08 上课之前提交到 [mailto:njucomb26@163.com njucomb26@163.com] (文件名为&#039;学号_姓名_A1.pdf&#039;)&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行([mailto:652024330006@smail.nju.edu.cn 652024330006@smail.nju.edu.cn])&lt;br /&gt;
** 周灿&lt;br /&gt;
** 方子伊&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* [[组合数学 (Spring 2026)/Problem Set 1|Problem Set 1]]&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Sieve methods|Sieve methods | 筛法]] ([http://tcs.nju.edu.cn/slides/comb2026/PIE.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Cayley&#039;s formula|Cayley&#039;s formula | Cayley公式]]  ([http://tcs.nju.edu.cn/slides/comb2026/Cayley.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Average-case_analysis_of_QuickSort&amp;diff=13617</id>
		<title>概率论与数理统计 (Spring 2026)/Average-case analysis of QuickSort</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Average-case_analysis_of_QuickSort&amp;diff=13617"/>
		<updated>2026-04-08T08:38:47Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;[http://en.wikipedia.org/wiki/Quicksort &amp;#039;&amp;#039;&amp;#039;快速排序&amp;#039;&amp;#039;&amp;#039;（&amp;#039;&amp;#039;&amp;#039;Quicksort&amp;#039;&amp;#039;&amp;#039;）]是由Tony Hoare发现的排序算法。该算法的伪代码描述如下（为方便起见，假设数组元素互不相同——更一般情况的分析易推广得到）：   &amp;#039;&amp;#039;&amp;#039;&amp;#039;&amp;#039;QSort&amp;#039;&amp;#039;&amp;#039;&amp;#039;&amp;#039;(A): 输入A[1...n]是存有n个不同数字的数组   if n&amp;gt;1 then        &amp;#039;&amp;#039;&amp;#039;pivot&amp;#039;&amp;#039;&amp;#039; = A[1];        将A中&amp;lt;pivot的元素存于数组L，将A中&amp;gt;pivot的元素存于数组R; \\保持内部元素之...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[http://en.wikipedia.org/wiki/Quicksort &#039;&#039;&#039;快速排序&#039;&#039;&#039;（&#039;&#039;&#039;Quicksort&#039;&#039;&#039;）]是由Tony Hoare发现的排序算法。该算法的伪代码描述如下（为方便起见，假设数组元素互不相同——更一般情况的分析易推广得到）：&lt;br /&gt;
  &#039;&#039;&#039;&#039;&#039;QSort&#039;&#039;&#039;&#039;&#039;(A): 输入A[1...n]是存有n个不同数字的数组&lt;br /&gt;
  if n&amp;gt;1 then&lt;br /&gt;
       &#039;&#039;&#039;pivot&#039;&#039;&#039; = A[1];&lt;br /&gt;
       将A中&amp;lt;pivot的元素存于数组L，将A中&amp;gt;pivot的元素存于数组R; \\保持内部元素之间相对顺序&lt;br /&gt;
       递归调用&#039;&#039;&#039;&#039;&#039;QSort&#039;&#039;&#039;&#039;&#039;(L)和&#039;&#039;&#039;&#039;&#039;QSort&#039;&#039;&#039;&#039;&#039;(R);&lt;br /&gt;
&lt;br /&gt;
该伪代码描述省略了对数组的存取归并等具体实现的交代。可以不妨认为算法中的&amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt;和&amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt;其实就分别是原数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;的前半部分&amp;lt;math&amp;gt;A[1...i-1]&amp;lt;/math&amp;gt;和后半部分&amp;lt;math&amp;gt;A[i...n]&amp;lt;/math&amp;gt;，其中&amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;表示&#039;&#039;&#039;pivot&#039;&#039;&#039;（“&#039;&#039;&#039;基准&#039;&#039;&#039;”、“&#039;&#039;&#039;轴点&#039;&#039;&#039;”、“&#039;&#039;&#039;分水岭&#039;&#039;&#039;”元素）在数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中的序数，即&#039;&#039;&#039;pivot&#039;&#039;&#039;是数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中第&amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;小的数。&lt;br /&gt;
&lt;br /&gt;
作为基于比较的（comparison-based）排序算法，我们将算法进行的元素间的&#039;&#039;&#039;比较次数&#039;&#039;&#039;作为算法的复杂性度量。在&#039;&#039;&#039;最坏情况&#039;&#039;&#039;（&#039;&#039;&#039;worst-case&#039;&#039;&#039;）输入下，我们描述的“快速排序”算法所使用的比较次数可以达到&amp;lt;math&amp;gt;\Theta(n^2)&amp;lt;/math&amp;gt;。而且有趣的是，这一&amp;lt;math&amp;gt;\Omega(n^2)&amp;lt;/math&amp;gt;的复杂度下界是在输入数组是一个已排好序的数组时达到的：此时&#039;&#039;&#039;pivot&#039;&#039;&#039;会将数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;划分为大小极不平衡的子数组&amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt;和&amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt;，递归树也因此极不平衡，而算法使用的比较次数可因此达到&amp;lt;math&amp;gt;(n-1)+(n-2)+(n-3)+\cdots+1=\Omega(n^2)&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
现在我们来分析这一算法的&#039;&#039;&#039;平均情况&#039;&#039;&#039;（&#039;&#039;&#039;average-case&#039;&#039;&#039;）复杂度。&lt;br /&gt;
令输入数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;为&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;个元素的均匀分布的随机排列。如下性质不难递归验证：&lt;br /&gt;
{{Theorem|性质一（输入分布的递归不变性）|&lt;br /&gt;
* 作为基于比较的排序算法，快速排序算法的行为仅与输入数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中元素的相对顺序有关，而与&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中元素的具体数值无关。&lt;br /&gt;
* 进一步地，在算法的每次递归调用中，其输入数组中元素的相对顺序，符合该数量元素的所有排列上的均匀分布。&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
= 快速排序算法的平均复杂度分析 I（基于全期望法则）=&lt;br /&gt;
令随机变量&amp;lt;math&amp;gt;X_n&amp;lt;/math&amp;gt;表示在随机输入&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;下，快速排序算法使用的总比较次数。同时令&amp;lt;math&amp;gt;t(n)=\mathbb{E}[X_n]&amp;lt;/math&amp;gt;表示其期望。正如刚刚解释的，&amp;lt;math&amp;gt;t(n)&amp;lt;/math&amp;gt;是良定义的，因为期望值&amp;lt;math&amp;gt;\mathbb{E}[X_n]&amp;lt;/math&amp;gt;仅与&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;有关。&lt;br /&gt;
&lt;br /&gt;
对&amp;lt;math&amp;gt;1\le i\le n&amp;lt;/math&amp;gt;，定义&amp;lt;math&amp;gt;B_i&amp;lt;/math&amp;gt;为如下事件：&lt;br /&gt;
:*&#039;&#039;&#039;pivot&#039;&#039;&#039;在数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中是第&amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;小的元素。&lt;br /&gt;
则&amp;lt;math&amp;gt;B_1,B_2,\ldots,B_n&amp;lt;/math&amp;gt;构成了对所有情况（样本空间）的一个划分。且每个事件&amp;lt;math&amp;gt;B_i&amp;lt;/math&amp;gt;发生的概率有：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr(B_i)=\frac{(n-1)!}{n!}=\frac{1}{n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
这是因为事件&amp;lt;math&amp;gt;B_i&amp;lt;/math&amp;gt;等价于一个均匀分布的随机排列&amp;lt;math&amp;gt;\pi:[n]\xrightarrow[\text{onto}]{\text{1-1}}[n]&amp;lt;/math&amp;gt;有&amp;lt;math&amp;gt;\pi(1)=i&amp;lt;/math&amp;gt;，而这件事的概率为&amp;lt;math&amp;gt;\frac{1}{n}&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
因此，根据&#039;&#039;&#039;全期望法则&#039;&#039;&#039;（&#039;&#039;&#039;law of total expectation&#039;&#039;&#039;），有：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
t(n)&lt;br /&gt;
=&lt;br /&gt;
\mathbb{E}[X_n]&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{i=1}^n\mathbb{E}[X_n\mid B_i]\Pr(B_i)&lt;br /&gt;
=&lt;br /&gt;
\frac{1}{n}\sum_{i=1}^n\mathbb{E}[X_n\mid B_i]&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;.&lt;br /&gt;
而当事件&amp;lt;math&amp;gt;B_i&amp;lt;/math&amp;gt;发生时，即当&#039;&#039;&#039;pivot&#039;&#039;&#039;恰为数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中第&amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;小的元素，&lt;br /&gt;
算法会将&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中比&#039;&#039;&#039;pivot&#039;&#039;&#039;小的&amp;lt;math&amp;gt;(i-1)&amp;lt;/math&amp;gt;个元素放入子数组&amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt;、将比&#039;&#039;&#039;pivot&#039;&#039;&#039;大的&amp;lt;math&amp;gt;(n-i)&amp;lt;/math&amp;gt;个元素放入子数组&amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt;，这总共会花费&amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt;次比较。&lt;br /&gt;
而且，根据&#039;&#039;&#039;性质一&#039;&#039;&#039;中所述的输入分布的递归不变性，递归调用&#039;&#039;&#039;&#039;&#039;QSort&#039;&#039;&#039;&#039;&#039;&amp;lt;math&amp;gt;(L)&amp;lt;/math&amp;gt;和&#039;&#039;&#039;&#039;&#039;QSort&#039;&#039;&#039;&#039;&#039;&amp;lt;math&amp;gt;(R)&amp;lt;/math&amp;gt;各自所使用的总比较次数分别为&amp;lt;math&amp;gt;X_{i-1}&amp;lt;/math&amp;gt;和&amp;lt;math&amp;gt;X_{n-i}&amp;lt;/math&amp;gt;。&lt;br /&gt;
综上所述，有如下恒等关系：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\mathbb{E}[X_n\mid B_i]&lt;br /&gt;
=&lt;br /&gt;
\mathbb{E}[n-1+X_{i-1}+X_{n-i}]&lt;br /&gt;
&amp;lt;/math&amp;gt;.&lt;br /&gt;
因此，上述全期望因此可被计算如下：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
t(n)&lt;br /&gt;
=&lt;br /&gt;
\mathbb{E}[X_n]&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{1}{n}\sum_{i=1}^n\mathbb{E}[X_n\mid B_i]\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{1}{n}\sum_{i=1}^n\mathbb{E}[n-1+X_{i-1}+X_{n-i}]\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
n-1+\frac{2}{n}\sum_{i=0}^{n-1}\mathbb{E}[X_{i}] &amp;amp;\text{(根据期望的线性)}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
n-1+\frac{2}{n}\sum_{i=0}^{n-1}t(i).&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
我们因此建立了平均复杂度&amp;lt;math&amp;gt;t(n)=\mathbb{E}[X_n]&amp;lt;/math&amp;gt;的如下递归式：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
t(n)&lt;br /&gt;
&amp;amp;= &lt;br /&gt;
n-1+\frac{2}{n}\sum_{i=0}^{n-1}t(i)&lt;br /&gt;
&amp;amp;&amp;amp; &lt;br /&gt;
\text{if }n&amp;gt;1;\\&lt;br /&gt;
t(n)&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
0&lt;br /&gt;
&amp;amp;&amp;amp;&lt;br /&gt;
\text{if }0\le n\le 1.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
我们有若干种方法从这一递归式获得关于&amp;lt;math&amp;gt;t(n)=\mathbb{E}[X_n]&amp;lt;/math&amp;gt;的真相：&lt;br /&gt;
* 一种是使用&#039;&#039;&#039;生成函数&#039;&#039;&#039;等工具来求解这样的递归方程，例如使用[[组合数学_(Fall_2025)/Generating_functions#Analysis_of_Quicksort|&#039;&#039;&#039;本学期组合数学课上的分析&#039;&#039;&#039;]]，最终可精确解出&amp;lt;math&amp;gt;t(n)=2(n+1)H(n)-4n&amp;lt;/math&amp;gt;，此处&amp;lt;math&amp;gt;H(n)=\sum_{k=1}^{n}\frac{1}{k}= \ln n+O(1)&amp;lt;/math&amp;gt;为第&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;个[https://en.wikipedia.org/wiki/Harmonic_number 调和数]；&lt;br /&gt;
* 另一种是采用&#039;&#039;&#039;数学归纳法&#039;&#039;&#039;来对我们猜想的关于&amp;lt;math&amp;gt;t(n)&amp;lt;/math&amp;gt;的界进行验证，例如从&amp;lt;math&amp;gt;t(n)\le c n \ln n&amp;lt;/math&amp;gt;的归纳假设出发，尝试使&amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt;尽量小。令该归纳假设对于所有&amp;lt;math&amp;gt;0\le i&amp;lt;n&amp;lt;/math&amp;gt;都成立，则对于&amp;lt;math&amp;gt;t(n)&amp;lt;/math&amp;gt;，根据递归式因此有：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
t(n)&lt;br /&gt;
&amp;amp;= &lt;br /&gt;
n-1+\frac{2}{n}\sum_{i=0}^{n-1}t(i)\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
n-1+\frac{2c}{n}\sum_{i=1}^{n-1}i \ln i &amp;amp;&amp;amp;\text{(归纳假设)}\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
n-1+\frac{2c}{n}\int_{1}^nx \ln x\,\mathrm{d}x &amp;amp;&amp;amp;\text{(求和的积分上界)}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
n-1+\frac{c}{2n}\left(2n^2\ln n-n^2+1\right)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
cn\ln n-\left(\frac{c}{2}-1\right)n-1+\frac{c}{2n}&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
设&amp;lt;math&amp;gt;c=2&amp;lt;/math&amp;gt;时，有&amp;lt;math&amp;gt;t(n)\le cn\ln n-\left(\frac{c}{2}-1\right)n-1+\frac{c}{2n}\le 2 n \ln n&amp;lt;/math&amp;gt;对于所有&amp;lt;math&amp;gt;n\ge 1&amp;lt;/math&amp;gt;总是成立。&lt;br /&gt;
&lt;br /&gt;
= 快速排序算法的平均复杂度分析 II（基于期望的线性）=&lt;br /&gt;
令随机变量&amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;表示在随机输入&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;下，快速排序算法使用的总比较次数。我们希望分析得到期望&amp;lt;math&amp;gt;\mathbb{E}[X]&amp;lt;/math&amp;gt;的上界。&lt;br /&gt;
&lt;br /&gt;
假设输入数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;中的元素，在从小到大排序之后为&amp;lt;math&amp;gt;a_1&amp;lt;a_2&amp;lt;\cdots a_n&amp;lt;/math&amp;gt;。&lt;br /&gt;
对&amp;lt;math&amp;gt;1\le i&amp;lt;j\le n&amp;lt;/math&amp;gt;，令布尔值随机变量&amp;lt;math&amp;gt;I_{ij}=I(A_{ij})\in\{0,1\}&amp;lt;/math&amp;gt;指示如下事件的发生：&lt;br /&gt;
* &amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;：元素&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;和&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;在算法运行过程中被比较了。&lt;br /&gt;
&lt;br /&gt;
容易验证：在算法运行过程中，任何元素对&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;和&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;之间至多只会进行一次比较。&lt;br /&gt;
因此总比较次数&amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;可被计算如下：&lt;br /&gt;
:&amp;lt;math&amp;gt;X=\sum_{i&amp;lt;j}I_{ij}&amp;lt;/math&amp;gt;.&lt;br /&gt;
根据&#039;&#039;&#039;期望的线性&#039;&#039;&#039;（&#039;&#039;&#039;linearity of expectation&#039;&#039;&#039;）：&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbb{E}[X]=\sum_{i&amp;lt;j}\mathbb{E}[I_{ij}]=\sum_{i&amp;lt;j}\Pr(A_{ij})&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
因此接下来，仅需要针对每一对具体的&amp;lt;math&amp;gt;1\le i&amp;lt;j\le n&amp;lt;/math&amp;gt;，计算概率：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr(A_{ij})=\Pr(a_i\text{和}a_j\text{在算法中进行了比较})&amp;lt;/math&amp;gt;.&lt;br /&gt;
而事件&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;发生，当且仅当：在&#039;&#039;&#039;某次&#039;&#039;&#039;递归调用中，&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;同属于当前输入数组，且&#039;&#039;&#039;pivot&#039;&#039;&#039;恰好选中&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;或&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;二者之一。&lt;br /&gt;
注意到：假如&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;同属于当前输入数组，则当前数组必然也同时包含它们之间的所有元素&amp;lt;math&amp;gt;\{a_k\mid i&amp;lt;k&amp;lt;j\}&amp;lt;/math&amp;gt;；&lt;br /&gt;
同时，事件&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;的发生与否，仅当&#039;&#039;&#039;首次&#039;&#039;&#039;在某递归调用中&#039;&#039;&#039;pivot&#039;&#039;&#039;选中了&amp;lt;math&amp;gt;\{a_k\mid i\le k\le j\}&amp;lt;/math&amp;gt;中的元素，才会确定。&lt;br /&gt;
综上，于是有：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr(A_{ij})=\Pr(\mathsf{pivot}\in\{a_i,a_j\}\mid\mathsf{pivot}\in\{a_i,a_{i+1},\ldots,a_{j}\})=\frac{2}{j-i+1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{|border=&amp;quot;1&amp;quot;&lt;br /&gt;
|如果你认为该证明不够详细。这里再提供一个对于上述事实的详细证明。&lt;br /&gt;
&lt;br /&gt;
定下任意一对具体的&amp;lt;math&amp;gt;1\le i&amp;lt;j\le n&amp;lt;/math&amp;gt;。&lt;br /&gt;
在算法运行之初（顶层递归调用），元素&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;显然有&amp;lt;math&amp;gt;a_i&amp;lt;a_j&amp;lt;/math&amp;gt;，且同属于当前递归调用的输入数组&amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
事件&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;的发生与否，由如下的递归随机过程确定：&lt;br /&gt;
# 在当前输入元素中按均匀分布随机选择&#039;&#039;&#039;pivot&#039;&#039;&#039;元素。如果刚好选中&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;或&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;二者之一，那么&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;之间必被比较（因为&#039;&#039;&#039;pivot&#039;&#039;&#039;会与当前数组内的所有元素进行比较）。此情况下，事件&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;确定发生。&lt;br /&gt;
# 如果&amp;lt;math&amp;gt;a_i&amp;lt;&amp;lt;/math&amp;gt;&#039;&#039;&#039;pivot&#039;&#039;&#039;&amp;lt;math&amp;gt;&amp;lt;a_j&amp;lt;/math&amp;gt;，即&#039;&#039;&#039;pivot&#039;&#039;&#039;取值在&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;之间，此时&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;会被大小居于其中间的&#039;&#039;&#039;pivot&#039;&#039;&#039;元素分别分流到子数组&amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt;中，且在之后的递归调用中永不再见，因此不会被比较。此情况下，事件&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;确定不发生。&lt;br /&gt;
# 如果&#039;&#039;&#039;pivot&#039;&#039;&#039;选中了比&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;更小或者比&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;更大的元素，在此情况下&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;，连同它们之间的所有元素&amp;lt;math&amp;gt;\{a_k\mid i&amp;lt;k&amp;lt;j\}&amp;lt;/math&amp;gt;，都会被分到同一个子数组&amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt;（假如&#039;&#039;&#039;pivot&#039;&#039;&#039;&amp;lt;math&amp;gt;&amp;gt;a_j&amp;lt;/math&amp;gt;）或者&amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt;（假如&#039;&#039;&#039;pivot&#039;&#039;&#039;&amp;lt;math&amp;gt;&amp;lt;a_i&amp;lt;/math&amp;gt;）中。而此时&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;的发生与否尚未能在这一层递归调用中确定，则需进入下一层递归调用，将当前输入数组改为&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;所同属的那个子数组（即&amp;lt;math&amp;gt;L&amp;lt;/math&amp;gt;如果&#039;&#039;&#039;pivot&#039;&#039;&#039;&amp;lt;math&amp;gt;&amp;gt;a_j&amp;lt;/math&amp;gt;，&amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt;如果&#039;&#039;&#039;pivot&#039;&#039;&#039;&amp;lt;math&amp;gt;&amp;lt;a_i&amp;lt;/math&amp;gt;），然后回到（1）重复。&lt;br /&gt;
不难看出该递归过程跟踪模拟了事件&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;的发生与否，在快速排序算法的递归调用过程中，是如何被确定下来的。&lt;br /&gt;
&lt;br /&gt;
因此，可以得出：&amp;lt;math&amp;gt;A_{ij}&amp;lt;/math&amp;gt;发生，当且仅当在上述情况（1）或（2）之一发生的前提下有（1）发生。&lt;br /&gt;
&lt;br /&gt;
除此之外，如下两个观察通过递归验证易得：&lt;br /&gt;
* 当&amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt;与&amp;lt;math&amp;gt;a_j&amp;lt;/math&amp;gt;同属于当前递归调用的输入数组时，它们之间的所有元素&amp;lt;math&amp;gt;\{a_k\mid i&amp;lt;k&amp;lt;j\}&amp;lt;/math&amp;gt;也属于该数组；&lt;br /&gt;
* 在任何递归调用中，&#039;&#039;&#039;pivot&#039;&#039;&#039;始终在当前输入数组中均匀分布——这也可由&#039;&#039;&#039;性质一&#039;&#039;&#039;所述的输入分布的递归不变性得到。&lt;br /&gt;
综上可得：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr(A_{ij})=\Pr(\mathsf{pivot}\in\{a_i,a_j\}\mid\mathsf{pivot}\in\{a_i,a_{i+1},\ldots,a_{j}\})=\frac{2}{j-i+1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
算法总比较次数的期望&amp;lt;math&amp;gt;\mathbb{E}[X]&amp;lt;/math&amp;gt;可被计算如下：&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
\mathbb{E}\left[X\right] &lt;br /&gt;
&amp;amp;= &lt;br /&gt;
\sum_{i&amp;lt;j}\Pr(A_{ij})\\&lt;br /&gt;
&amp;amp;=\sum_{i=1}^{n-1}\sum_{j=i+1}^n\frac{2}{j-i+1}\\&lt;br /&gt;
&amp;amp;= \sum_{i=1}^{n-1}\sum_{k=2}^{n-i+1}\frac{2}{k} &amp;amp; &amp;amp; (\text{令 }k=j-i+1)\\&lt;br /&gt;
&amp;amp;\le \sum_{i=1}^n\sum_{k=1}^{n}\frac{2}{k}\\&lt;br /&gt;
&amp;amp;= 2n\sum_{k=1}^{n}\frac{1}{k}\\&lt;br /&gt;
&amp;amp;= 2n H(n).&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
此处&amp;lt;math&amp;gt;H(n)=\sum_{k=1}^{n}\frac{1}{k}= \ln n+O(1)&amp;lt;/math&amp;gt;为第&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;个[http://en.wikipedia.org/wiki/Harmonic_number 调和数]。&lt;br /&gt;
&lt;br /&gt;
如果更加仔细一些，我们甚至可以计算出总比较次数期望&amp;lt;math&amp;gt;\mathbb{E}[X]&amp;lt;/math&amp;gt;的精确值：&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
\mathbb{E}\left[X\right] &lt;br /&gt;
&amp;amp;= &lt;br /&gt;
\sum_{i=1}^{n-1}\sum_{k=2}^{n-i+1}\frac{2}{k}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{j=2}^n\sum_{k=2}^{j}\frac{2}{k} &amp;amp;&amp;amp; \text{(令$j=n-i+1$)}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{k=2}^{n}\frac{2(n-k+1)}{k} &amp;amp;&amp;amp; \text{(交换求和顺序)}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{k=2}^{n}\left(\frac{2(n+1)}{k}-2\right)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
2(n+1)\sum_{k=2}^{n}\frac{1}{k}-2(n-1)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
2(n+1)\sum_{k=1}^{n}\frac{1}{k}-4n\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
2(n+1)H(n)-4n.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13616</id>
		<title>概率论与数理统计 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13616"/>
		<updated>2026-04-08T08:38:17Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;&#039;&#039;&#039;概率论与数理统计&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Probability Theory&#039;&#039;&#039; &amp;lt;br&amp;gt; &amp;amp; &#039;&#039;&#039;Mathematical Statistics&#039;&#039;&#039;&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4  = office&lt;br /&gt;
|data4   = 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = liu@nju.edu.cn  &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = office&lt;br /&gt;
|data7   = 计算机系 516&lt;br /&gt;
|header8 = Class&lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &lt;br /&gt;
|header9 =&lt;br /&gt;
|label9  = Class meeting&lt;br /&gt;
|data9   = Wednesday, 9am-12am&amp;lt;br&amp;gt;&lt;br /&gt;
仙Ⅱ-212&lt;br /&gt;
|header10=&lt;br /&gt;
|label10 = Office hour&lt;br /&gt;
|data10  = TBA &amp;lt;br&amp;gt;计算机系 804（尹一通）&amp;lt;br&amp;gt;计算机系 516（刘景铖）&lt;br /&gt;
|header11= Textbook&lt;br /&gt;
|label11 = &lt;br /&gt;
|data11  = &lt;br /&gt;
|header12=&lt;br /&gt;
|label12 = &lt;br /&gt;
|data12  = [[File:概率导论.jpeg|border|100px]]&lt;br /&gt;
|header13=&lt;br /&gt;
|label13 = &lt;br /&gt;
|data13  = &#039;&#039;&#039;概率导论&#039;&#039;&#039;（第2版·修订版）&amp;lt;br&amp;gt; Dimitri P. Bertsekas and John N. Tsitsiklis&amp;lt;br&amp;gt; 郑忠国 童行伟 译；人民邮电出版社 (2022)&lt;br /&gt;
|header14=&lt;br /&gt;
|label14 = &lt;br /&gt;
|data14  = [[File:Grimmett_probability.jpg|border|100px]]&lt;br /&gt;
|header15=&lt;br /&gt;
|label15 = &lt;br /&gt;
|data15  = &#039;&#039;&#039;Probability and Random Processes&#039;&#039;&#039; (4E) &amp;lt;br&amp;gt; Geoffrey Grimmett and David Stirzaker &amp;lt;br&amp;gt;  Oxford University Press (2020)&lt;br /&gt;
|header16=&lt;br /&gt;
|label16 = &lt;br /&gt;
|data16  = [[File:Probability_and_Computing_2ed.jpg|border|100px]]&lt;br /&gt;
|header17=&lt;br /&gt;
|label17 = &lt;br /&gt;
|data17  = &#039;&#039;&#039;Probability and Computing&#039;&#039;&#039; (2E) &amp;lt;br&amp;gt; Michael Mitzenmacher and Eli Upfal &amp;lt;br&amp;gt;   Cambridge University Press (2017)&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Probability Theory and Mathematical Statistics&#039;&#039; (概率论与数理统计) class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 鞠哲：[mailto:juzhe@smail.nju.edu.cn &amp;lt;juzhe@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
** 祝永祺：[mailto:652025330045@smail.nju.edu.cn &amp;lt;652025330045@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;:&lt;br /&gt;
** 周三：9am-12am，仙Ⅱ-212&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: &lt;br /&gt;
:* TBA, 计算机系 804（尹一通）&lt;br /&gt;
:* TBA, 计算机系 516（刘景铖）&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090092561（申请加入需提供姓名、院系、学号）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
课程内容分为三大部分：&lt;br /&gt;
* &#039;&#039;&#039;经典概率论&#039;&#039;&#039;：概率空间、随机变量及其数字特征、多维与连续随机变量、极限定理等内容&lt;br /&gt;
* &#039;&#039;&#039;概率与计算&#039;&#039;&#039;：测度集中现象 (concentration of measure)、概率法 (the probabilistic method)、离散随机过程的相关专题&lt;br /&gt;
* &#039;&#039;&#039;数理统计&#039;&#039;&#039;：参数估计、假设检验、贝叶斯估计、线性回归等统计推断等概念&lt;br /&gt;
&lt;br /&gt;
对于第一和第二部分，要求清楚掌握基本概念，深刻理解关键的现象与规律以及背后的原理，并可以灵活运用所学方法求解相关问题。对于第三部分，要求熟悉数理统计的若干基本概念，以及典型的统计模型和统计推断问题。&lt;br /&gt;
&lt;br /&gt;
经过本课程的训练，力求使学生能够熟悉掌握概率的语言，并会利用概率思维来理解客观世界并对其建模，以及驾驭概率的数学工具来分析和求解专业问题。&lt;br /&gt;
&lt;br /&gt;
=== 教材与参考书 Course Materials ===&lt;br /&gt;
* &#039;&#039;&#039;[BT]&#039;&#039;&#039; 概率导论（第2版·修订版），[美]伯特瑟卡斯（Dimitri P.Bertsekas）[美]齐齐克利斯（John N.Tsitsiklis）著，郑忠国 童行伟 译，人民邮电出版社（2022）。&lt;br /&gt;
* &#039;&#039;&#039;[GS]&#039;&#039;&#039; &#039;&#039;Probability and Random Processes&#039;&#039;, by Geoffrey Grimmett and David Stirzaker; Oxford University Press; 4th edition (2020).&lt;br /&gt;
* &#039;&#039;&#039;[MU]&#039;&#039;&#039; &#039;&#039;Probability and Computing: Randomization and Probabilistic Techniques in Algorithms and Data Analysis&#039;&#039;, by Michael Mitzenmacher, Eli Upfal; Cambridge University Press; 2nd edition (2017).&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grading Policy ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。符合规则的讨论与致谢将不会影响得分。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
*[[概率论与数理统计 (Spring 2026)/Problem Set 1|Problem Set 1]]  请在 2026/4/1 上课之前(9am UTC+8)提交到 [mailto:pr2026_nju@163.com pr2026_nju@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
** [[概率论与数理统计 (Spring 2026)/第一次作业提交名单|第一次作业提交名单]]&lt;br /&gt;
&lt;br /&gt;
*[[概率论与数理统计 (Spring 2026)/Problem Set 2|Problem Set 2]]  请在 2026/4/&amp;lt;font color=red&amp;gt;TBA&amp;lt;/font&amp;gt; 上课之前(9am UTC+8)提交到 [mailto:pr2026_nju@163.com pr2026_nju@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A2.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lectures =&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/Intro.pdf 课程简介]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/ProbSpace.pdf 概率空间]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第1章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 1&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Entropy and volume of Hamming balls|Entropy and volume of Hamming balls]]&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Karger&#039;s min-cut algorithm| Karger&#039;s min-cut algorithm]]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/RandVar.pdf 随机变量]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第2章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 2, Sections 3.1~3.5, 3.7&#039;&#039;&#039;&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[MU] Chapter 2&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Average-case analysis of QuickSort|Average-case analysis of &#039;&#039;&#039;&#039;&#039;QuickSort&#039;&#039;&#039;&#039;&#039;]]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [https://plato.stanford.edu/entries/probability-interpret/ Interpretations of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/History_of_probability History of probability]&lt;br /&gt;
* Example problems:&lt;br /&gt;
** [https://dornsifecms.usc.edu/assets/sites/520/docs/VonNeumann-ams12p36-38.pdf von Neumann&#039;s Bernoulli factory] and other [https://peteroupc.github.io/bernoulli.html Bernoulli factory algorithms]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boy_or_Girl_paradox Boy or Girl paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Monty_Hall_problem Monty Hall problem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bertrand_paradox_(probability) Bertrand paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Hard_spheres Hard spheres model] and [https://en.wikipedia.org/wiki/Ising_model Ising model]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/PageRank &#039;&#039;PageRank&#039;&#039;] and stationary [https://en.wikipedia.org/wiki/Random_walk random walk]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Diffusion_process Diffusion process] and [https://en.wikipedia.org/wiki/Diffusion_model diffusion model]&lt;br /&gt;
*[https://en.wikipedia.org/wiki/Probability_space Probability space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sample_space Sample space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Event_(probability_theory) Event] and [https://en.wikipedia.org/wiki/Σ-algebra &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;-algebra]&lt;br /&gt;
** Kolmogorov&#039;s [https://en.wikipedia.org/wiki/Probability_axioms axioms of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Discrete_uniform_distribution Classical] and [https://en.wikipedia.org/wiki/Geometric_probability goemetric probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Boole%27s_inequality Union bound]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Inclusion%E2%80%93exclusion_principle Inclusion-Exclusion principle]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boole%27s_inequality#Bonferroni_inequalities Bonferroni inequalities]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Conditional_probability Conditional probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Chain_rule_(probability) Chain rule]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_total_probability Law of total probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bayes%27_theorem Bayes&#039; law]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Independence_(probability_theory) Independence] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Pairwise_independence Pairwise independence]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Random_variable Random variable]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cumulative_distribution_function Cumulative distribution function]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Probability_mass_function Probability mass function]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Probability_density_function Probability density function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Multivariate_random_variable Random vector]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Joint_probability_distribution Joint probability distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Conditional_probability_distribution Conditional probability distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Marginal_distribution Marginal distribution]&lt;br /&gt;
* Some &#039;&#039;&#039;discrete&#039;&#039;&#039; probability distributions&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bernoulli_trial Bernoulli trial] and [https://en.wikipedia.org/wiki/Bernoulli_distribution Bernoulli distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Discrete_uniform_distribution Discrete uniform distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Binomial_distribution Binomial distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Geometric_distribution Geometric distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Negative_binomial_distribution Negative binomial distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Hypergeometric_distribution Hypergeometric distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Poisson_distribution Poisson distribution]&lt;br /&gt;
** and [https://en.wikipedia.org/wiki/List_of_probability_distributions#Discrete_distributions others]&lt;br /&gt;
* Balls into bins model&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Multinomial_distribution Multinomial distribution]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Birthday_problem Birthday problem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Coupon_collector%27s_problem Coupon collector]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Balls_into_bins_problem Occupancy problem]&lt;br /&gt;
* Random graphs&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi random graph model]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Galton%E2%80%93Watson_process Galton–Watson branching process]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Expected_value Expectation]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_the_unconscious_statistician Law of the unconscious statistician, &#039;&#039;LOTUS&#039;&#039;]&lt;br /&gt;
** [https://dlsun.github.io/probability/linearity.html Linearity of expectation]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Conditional_expectation Conditional expectation]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_total_expectation Law of total expectation]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/Sieve_methods&amp;diff=13580</id>
		<title>组合数学 (Fall 2026)/Sieve methods</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Fall_2026)/Sieve_methods&amp;diff=13580"/>
		<updated>2026-03-30T17:21:03Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;== Principle of Inclusion-Exclusion == Let &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; be two finite sets. The cardinality of their union is :&amp;lt;math&amp;gt;|A\cup B|=|A|+|B|-{\color{Blue}|A\cap B|}&amp;lt;/math&amp;gt;. For three sets &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;, the cardinality of the union of these three sets is computed as :&amp;lt;math&amp;gt;|A\cup B\cup C|=|A|+|B|+|C|-{\color{Blue}|A\cap B|}-{\color{Blue}|A\cap C|}-{\color{Blue}|B\cap C|}+{\color{Red}|A\cap B\cap C|}&amp;lt;/math&amp;gt;. This is illu...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Principle of Inclusion-Exclusion ==&lt;br /&gt;
Let &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; be two finite sets. The cardinality of their union is&lt;br /&gt;
:&amp;lt;math&amp;gt;|A\cup B|=|A|+|B|-{\color{Blue}|A\cap B|}&amp;lt;/math&amp;gt;.&lt;br /&gt;
For three sets &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;, the cardinality of the union of these three sets is computed as&lt;br /&gt;
:&amp;lt;math&amp;gt;|A\cup B\cup C|=|A|+|B|+|C|-{\color{Blue}|A\cap B|}-{\color{Blue}|A\cap C|}-{\color{Blue}|B\cap C|}+{\color{Red}|A\cap B\cap C|}&amp;lt;/math&amp;gt;.&lt;br /&gt;
This is illustrated by the following figure.&lt;br /&gt;
::[[Image:Inclusion-exclusion.png|200px|border|center]] &lt;br /&gt;
&lt;br /&gt;
Generally, the &#039;&#039;&#039;Principle of Inclusion-Exclusion&#039;&#039;&#039; states the rule for computing the union of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; finite sets &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt;, such that&lt;br /&gt;
{{Equation|&lt;br /&gt;
&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\left|\bigcup_{i=1}^nA_i\right|&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{I\subseteq\{1,\ldots,n\}}(-1)^{|I|-1}\left|\bigcap_{i\in I}A_i\right|.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
-----&lt;br /&gt;
&lt;br /&gt;
In combinatorial enumeration, the Principle of Inclusion-Exclusion is usually applied in its complement form.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n\subseteq U&amp;lt;/math&amp;gt; be subsets of some finite set &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt;. Here &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; is some universe of combinatorial objects, whose cardinality is easy to calculate (e.g. all strings, tuples, permutations), and each &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; contains the objects with some specific property (e.g. a &amp;quot;pattern&amp;quot;) which we want to avoid. The problem is to count the number of objects without any of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; properties. We write &amp;lt;math&amp;gt;\bar{A_i}=U-A_i&amp;lt;/math&amp;gt;. The number of objects without any of the properties &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt; is&lt;br /&gt;
{{Equation|&lt;br /&gt;
&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\left|\bar{A_1}\cap\bar{A_2}\cap\cdots\cap\bar{A_n}\right|=\left|U-\bigcup_{i=1}^nA_i\right|&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
|U|+\sum_{I\subseteq\{1,\ldots,n\}}(-1)^{|I|}\left|\bigcap_{i\in I}A_i\right|.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
For an &amp;lt;math&amp;gt;I\subseteq\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;, we denote&lt;br /&gt;
:&amp;lt;math&amp;gt;A_I=\bigcap_{i\in I}A_i&amp;lt;/math&amp;gt;&lt;br /&gt;
with the convention that &amp;lt;math&amp;gt;A_\emptyset=U&amp;lt;/math&amp;gt;. The above equation is stated as:&lt;br /&gt;
{{Theorem|Principle of Inclusion-Exclusion|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt; be a family of subsets of &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt;. Then the number of elements of &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; which lie in none of the subsets &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; is&lt;br /&gt;
::&amp;lt;math&amp;gt;\sum_{I\subseteq\{1,\ldots, n\}}(-1)^{|I|}|A_I|&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;S_k=\sum_{|I|=k}|A_I|\,&amp;lt;/math&amp;gt;. Conventionally, &amp;lt;math&amp;gt;S_0=|A_\emptyset|=|U|&amp;lt;/math&amp;gt;. The principle of inclusion-exclusion can be expressed as&lt;br /&gt;
{{Equation|&amp;lt;math&amp;gt;&lt;br /&gt;
\left|\bar{A_1}\cap\bar{A_2}\cap\cdots\cap\bar{A_n}\right|=&lt;br /&gt;
S_0-S_1+S_2+\cdots+(-1)^nS_n.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Surjections ===&lt;br /&gt;
In the twelvefold way, we discuss the counting problems incurred by the mappings &amp;lt;math&amp;gt;f:N\rightarrow M&amp;lt;/math&amp;gt;. The basic case is that elements from both &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; are distinguishable. In this case, it is easy to count the number of arbitrary mappings (which is &amp;lt;math&amp;gt;m^n&amp;lt;/math&amp;gt;) and the number of injective (one-to-one) mappings (which is &amp;lt;math&amp;gt;(m)_n&amp;lt;/math&amp;gt;), but the number of surjective is difficult. Here we apply the principle of inclusion-exclusion to count the number of surjective (onto) mappings.&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:The number of surjective mappings from an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set to an &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;-set is given by&lt;br /&gt;
::&amp;lt;math&amp;gt;\sum_{k=1}^m(-1)^{m-k}{m\choose k}k^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Let &amp;lt;math&amp;gt;U=\{f:[n]\rightarrow[m]\}&amp;lt;/math&amp;gt; be the set of mappings from &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;[m]&amp;lt;/math&amp;gt;. Then &amp;lt;math&amp;gt;|U|=m^n&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
For &amp;lt;math&amp;gt;i\in[m]&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; be the set of mappings &amp;lt;math&amp;gt;f:[n]\rightarrow[m]&amp;lt;/math&amp;gt; that none of &amp;lt;math&amp;gt;j\in[n]&amp;lt;/math&amp;gt; is mapped to &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;, i.e. &amp;lt;math&amp;gt;A_i=\{f:[n]\rightarrow[m]\setminus\{i\}\}&amp;lt;/math&amp;gt;, thus &amp;lt;math&amp;gt;|A_i|=(m-1)^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
More generally, for &amp;lt;math&amp;gt;I\subseteq [m]&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;A_I=\bigcap_{i\in I}A_i&amp;lt;/math&amp;gt; contains the mappings &amp;lt;math&amp;gt;f:[n]\rightarrow[m]\setminus I&amp;lt;/math&amp;gt;. And &amp;lt;math&amp;gt;|A_I|=(m-|I|)^n\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
A mapping &amp;lt;math&amp;gt;f:[n]\rightarrow[m]&amp;lt;/math&amp;gt; is surjective if &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; lies in none of &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt;. By the principle of inclusion-exclusion, the number of surjective &amp;lt;math&amp;gt;f:[n]\rightarrow[m]&amp;lt;/math&amp;gt; is&lt;br /&gt;
:&amp;lt;math&amp;gt;\sum_{I\subseteq[m]}(-1)^{|I|}\left|A_I\right|=\sum_{I\subseteq[m]}(-1)^{|I|}(m-|I|)^n=\sum_{j=0}^m(-1)^j{m\choose j}(m-j)^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
Let &amp;lt;math&amp;gt;k=m-j&amp;lt;/math&amp;gt;. The theorem is proved.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Recall that, in the twelvefold way, we establish a relation between surjections and partitions.&lt;br /&gt;
&lt;br /&gt;
* Surjection to ordered partition:&lt;br /&gt;
:For a surjective &amp;lt;math&amp;gt;f:[n]\rightarrow[m]&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;(f^{-1}(0),f^{-1}(1),\ldots,f^{-1}(m-1))&amp;lt;/math&amp;gt; is an &#039;&#039;&#039;ordered partition&#039;&#039;&#039; of &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt;.&lt;br /&gt;
* Ordered partition to surjection:&lt;br /&gt;
:For an ordered &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;-partition &amp;lt;math&amp;gt;(B_0,B_1,\ldots, B_{m-1})&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt;, we can define a function &amp;lt;math&amp;gt;f:[n]\rightarrow[m]&amp;lt;/math&amp;gt; by letting &amp;lt;math&amp;gt;f(i)=j&amp;lt;/math&amp;gt; if and only if &amp;lt;math&amp;gt;i\in B_j&amp;lt;/math&amp;gt;. &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; is surjective since as a partition, none of &amp;lt;math&amp;gt;B_i&amp;lt;/math&amp;gt; is empty.&lt;br /&gt;
&lt;br /&gt;
Therefore, we have a one-to-one correspondence between surjective mappings from an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set to an &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;-set and the ordered &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;-partitions of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set.&lt;br /&gt;
&lt;br /&gt;
The Stirling number of the second kind &amp;lt;math&amp;gt;\left\{{n\atop m}\right\}&amp;lt;/math&amp;gt; is the number of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;-partitions of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set. There are &amp;lt;math&amp;gt;m!&amp;lt;/math&amp;gt; ways to order an &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;-partition, thus the number of surjective mappings &amp;lt;math&amp;gt;f:[n]\rightarrow[m]&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;m! \left\{{n\atop m}\right\}&amp;lt;/math&amp;gt;. Combining with what we have proved for surjections, we give the following result for the Stirling number of the second kind.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
:&amp;lt;math&amp;gt;\left\{{n\atop m}\right\}=\frac{1}{m!}\sum_{k=1}^m(-1)^{m-k}{m\choose k}k^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Derangements ===&lt;br /&gt;
We now count the number of bijections from a set to itself with no fixed points. This is the &#039;&#039;&#039;derangement problem&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
For a permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;, a &#039;&#039;&#039;fixed point&#039;&#039;&#039; is such an &amp;lt;math&amp;gt;i\in\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; that &amp;lt;math&amp;gt;\pi(i)=i&amp;lt;/math&amp;gt;.&lt;br /&gt;
A [http://en.wikipedia.org/wiki/Derangement &#039;&#039;&#039;derangement&#039;&#039;&#039;] of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; is a permutation of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; that has no fixed points.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:The number of derangements of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; given by&lt;br /&gt;
::&amp;lt;math&amp;gt;n!\sum_{k=0}^n\frac{(-1)^k}{k!}\approx \frac{n!}{\mathrm{e}}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Let &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; be the set of all permutations of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;. So &amp;lt;math&amp;gt;|U|=n!&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; be the set of permutations with fixed point &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;; so &amp;lt;math&amp;gt;|A_i|=(n-1)!&amp;lt;/math&amp;gt;. More generally, for any &amp;lt;math&amp;gt;I\subseteq \{1,2,\ldots,n\}&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;A_I=\bigcap_{i\in I}A_i&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;|A_I|=(n-|I|)!&amp;lt;/math&amp;gt;, since permutations in &amp;lt;math&amp;gt;A_I&amp;lt;/math&amp;gt; fix every point in &amp;lt;math&amp;gt;I&amp;lt;/math&amp;gt; and permute the remaining points arbitrarily. A permutation is a derangement if and only if it lies in none of the sets &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt;. So the number of derangements is&lt;br /&gt;
:&amp;lt;math&amp;gt;\sum_{I\subseteq\{1,2,\ldots,n\}}(-1)^{|I|}(n-|I|)!=\sum_{k=0}^n(-1)^k{n\choose k}(n-k)!=n!\sum_{k=0}^n\frac{(-1)^k}{k!}.&amp;lt;/math&amp;gt;&lt;br /&gt;
By Taylor&#039;s series,&lt;br /&gt;
:&amp;lt;math&amp;gt;\frac{1}{\mathrm{e}}=\sum_{k=0}^\infty\frac{(-1)^k}{k!}=\sum_{k=0}^n\frac{(-1)^k}{k!}\pm o\left(\frac{1}{n!}\right)&amp;lt;/math&amp;gt;.&lt;br /&gt;
It is not hard to see that &amp;lt;math&amp;gt;n!\sum_{k=0}^n\frac{(-1)^k}{k!}&amp;lt;/math&amp;gt; is the closest integer to &amp;lt;math&amp;gt;\frac{n!}{\mathrm{e}}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Therefore, there are about &amp;lt;math&amp;gt;\frac{1}{\mathrm{e}}&amp;lt;/math&amp;gt; fraction of all permutations with no fixed points.&lt;br /&gt;
&lt;br /&gt;
=== Permutations with restricted positions ===&lt;br /&gt;
We introduce a general theory of counting permutations with restricted positions. In the derangement problem, we count the number of permutations that &amp;lt;math&amp;gt;\pi(i)\neq i&amp;lt;/math&amp;gt;. We now generalize to the problem of counting permutations which avoid a set of arbitrarily specified positions. &lt;br /&gt;
&lt;br /&gt;
It is traditionally described using terminology from the game of chess. Let &amp;lt;math&amp;gt;B\subseteq \{1,\ldots,n\}\times \{1,\ldots,n\}&amp;lt;/math&amp;gt;, called a &#039;&#039;&#039;board&#039;&#039;&#039;.  As illustrated below, we can think of &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; as a chess board, with the positions in &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; marked by &amp;quot;&amp;lt;math&amp;gt;\times&amp;lt;/math&amp;gt;&amp;quot;.&lt;br /&gt;
{{Chess diagram small&lt;br /&gt;
| &lt;br /&gt;
| &lt;br /&gt;
|=&lt;br /&gt;
 8 |__|xx|xx|__|xx|__|__|xx|=&lt;br /&gt;
 7 |xx|__|__|xx|__|__|xx|__|=&lt;br /&gt;
 6 |xx|__|xx|xx|__|xx|xx|__|=&lt;br /&gt;
 5 |__|xx|__|__|xx|__|xx|__|=&lt;br /&gt;
 4 |xx|__|__|__|xx|xx|xx|__|=&lt;br /&gt;
 3 |__|xx|__|xx|__|__|__|xx|=&lt;br /&gt;
 2 |__|__|xx|__|xx|__|__|xx|=&lt;br /&gt;
 1 |xx|__|__|xx|__|xx|__|__|=&lt;br /&gt;
 a b c d e f g h&lt;br /&gt;
|&lt;br /&gt;
}}&lt;br /&gt;
For a permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;\{1,\ldots,n\}&amp;lt;/math&amp;gt;, define the &#039;&#039;&#039;graph&#039;&#039;&#039; &amp;lt;math&amp;gt;G_\pi(V,E)&amp;lt;/math&amp;gt; as&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
G_\pi &amp;amp;= \{(i,\pi(i))\mid i\in \{1,2,\ldots,n\}\}.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
This can also be viewed as a set of marked positions on a chess board. Each row and each column has only one marked position, because &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; is a permutation. Thus, we can identify each &amp;lt;math&amp;gt;G_\pi&amp;lt;/math&amp;gt; as a placement of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; rooks (“城堡”，规则同中国象棋里的“车”) without attacking each other.&lt;br /&gt;
&lt;br /&gt;
For example, the following is the &amp;lt;math&amp;gt;G_\pi&amp;lt;/math&amp;gt; of such &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; that &amp;lt;math&amp;gt;\pi(i)=i&amp;lt;/math&amp;gt;.&lt;br /&gt;
{{Chess diagram small&lt;br /&gt;
| &lt;br /&gt;
| &lt;br /&gt;
|=&lt;br /&gt;
 8 |rl|__|__|__|__|__|__|__|=&lt;br /&gt;
 7 |__|rl|__|__|__|__|__|__|=&lt;br /&gt;
 6 |__|__|rl|__|__|__|__|__|=&lt;br /&gt;
 5 |__|__|__|rl|__|__|__|__|=&lt;br /&gt;
 4 |__|__|__|__|rl|__|__|__|=&lt;br /&gt;
 3 |__|__|__|__|__|rl|__|__|=&lt;br /&gt;
 2 |__|__|__|__|__|__|rl|__|=&lt;br /&gt;
 1 |__|__|__|__|__|__|__|rl|=&lt;br /&gt;
 a b c d e f g h&lt;br /&gt;
|&lt;br /&gt;
}}&lt;br /&gt;
Now define&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
N_0 &amp;amp;= \left|\left\{\pi\mid B\cap G_\pi=\emptyset\right\}\right|\\&lt;br /&gt;
r_k &amp;amp;= \mbox{number of }k\mbox{-subsets of }B\mbox{ such that no two elements have a common coordinate}\\&lt;br /&gt;
&amp;amp;=\left|\left\{S\in{B\choose k} \,\bigg|\, \forall (i_1,j_1),(i_2,j_2)\in S, i_1\neq i_2, j_1\neq j_2 \right\}\right|&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Interpreted in chess game,&lt;br /&gt;
* &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;: a set of marked positions in an &amp;lt;math&amp;gt;[n]\times [n]&amp;lt;/math&amp;gt; chess board.&lt;br /&gt;
* &amp;lt;math&amp;gt;N_0&amp;lt;/math&amp;gt;: the number of ways of placing &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; non-attacking rooks on the chess board such that none of these rooks lie in &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;.&lt;br /&gt;
* &amp;lt;math&amp;gt;r_k&amp;lt;/math&amp;gt;: number of ways of placing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; non-attacking rooks on &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Our goal is to count &amp;lt;math&amp;gt;N_0&amp;lt;/math&amp;gt; in terms of &amp;lt;math&amp;gt;r_k&amp;lt;/math&amp;gt;. This gives the number of permutations avoid all positions in a &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:&amp;lt;math&amp;gt;N_0=\sum_{k=0}^n(-1)^kr_k(n-k)!&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
For each &amp;lt;math&amp;gt;i\in[n]&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;A_i=\{\pi\mid (i,\pi(i))\in B\}&amp;lt;/math&amp;gt; be the set of permutations &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; whose &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;-th position is in &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;N_0&amp;lt;/math&amp;gt; is the number of permutations avoid all positions in &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;. Thus, our goal is to count the number of permutations &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; in none of &amp;lt;math&amp;gt;A_i&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;i\in [n]&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For each &amp;lt;math&amp;gt;I\subseteq [n]&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;A_I=\bigcap_{i\in I}A_i&amp;lt;/math&amp;gt;, which is the set of permutations &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;(i,\pi(i))\in B&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;i\in I&amp;lt;/math&amp;gt;. Due to the principle of inclusion-exclusion,&lt;br /&gt;
:&amp;lt;math&amp;gt;N_0=\sum_{I\subseteq [n]} (-1)^{|I|}|A_I|=\sum_{k=0}^n(-1)^k\sum_{I\in{[n]\choose k}}|A_I|&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The next observation is that &lt;br /&gt;
:&amp;lt;math&amp;gt;\sum_{I\in{[n]\choose k}}|A_I|=r_k(n-k)!&amp;lt;/math&amp;gt;,&lt;br /&gt;
because we can count both sides by first placing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; non-attacking rooks on &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; and placing &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; additional non-attacking rooks on &amp;lt;math&amp;gt;[n]\times [n]&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;(n-k)!&amp;lt;/math&amp;gt; ways. &lt;br /&gt;
&lt;br /&gt;
Therefore,&lt;br /&gt;
:&amp;lt;math&amp;gt;N_0=\sum_{k=0}^n(-1)^kr_k(n-k)!&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
====Derangement problem====&lt;br /&gt;
We use the above general method to solve the derange problem again.&lt;br /&gt;
&lt;br /&gt;
Take &amp;lt;math&amp;gt;B=\{(1,1),(2,2),\ldots,(n,n)\}&amp;lt;/math&amp;gt; as the chess board.  A derangement &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; is a placement of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; non-attacking rooks such that none of them is in &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;. &lt;br /&gt;
{{Chess diagram small&lt;br /&gt;
| &lt;br /&gt;
| &lt;br /&gt;
|=&lt;br /&gt;
 8 |xx|__|__|__|__|__|__|__|=&lt;br /&gt;
 7 |__|xx|__|__|__|__|__|__|=&lt;br /&gt;
 6 |__|__|xx|__|__|__|__|__|=&lt;br /&gt;
 5 |__|__|__|xx|__|__|__|__|=&lt;br /&gt;
 4 |__|__|__|__|xx|__|__|__|=&lt;br /&gt;
 3 |__|__|__|__|__|xx|__|__|=&lt;br /&gt;
 2 |__|__|__|__|__|__|xx|__|=&lt;br /&gt;
 1 |__|__|__|__|__|__|__|xx|=&lt;br /&gt;
 a b c d e f g h&lt;br /&gt;
|&lt;br /&gt;
}}&lt;br /&gt;
Clearly, the number of ways of placing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; non-attacking rooks on &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;r_k={n\choose k}&amp;lt;/math&amp;gt;. We want to count &amp;lt;math&amp;gt;N_0&amp;lt;/math&amp;gt;, which gives the number of ways of placing &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; non-attacking rooks such that none of these rooks lie in &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
By the above theorem&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
N_0=\sum_{k=0}^n(-1)^kr_k(n-k)!=\sum_{k=0}^n(-1)^k{n\choose k}(n-k)!=\sum_{k=0}^n(-1)^k\frac{n!}{k!}=n!\sum_{k=0}^n(-1)^k\frac{1}{k!}\approx\frac{n!}{e}.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Problème des ménages====&lt;br /&gt;
Suppose that in a banquet, we want to seat &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; couples at a circular table, satisfying the following constraints:&lt;br /&gt;
* Men and women are in alternate places.&lt;br /&gt;
* No one sits next to his/her spouse.&lt;br /&gt;
&lt;br /&gt;
In how many ways can this be done?&lt;br /&gt;
&lt;br /&gt;
(For convenience, we assume that every seat at the table marked differently so that rotating the seats clockwise or anti-clockwise will end up with a &#039;&#039;&#039;different&#039;&#039;&#039; solution.)&lt;br /&gt;
&lt;br /&gt;
First, let the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; ladies find their seats. They may either sit at the odd numbered seats or even numbered seats, in either case, there are &amp;lt;math&amp;gt;n!&amp;lt;/math&amp;gt; different orders. Thus, there are &amp;lt;math&amp;gt;2(n!)&amp;lt;/math&amp;gt; ways to seat the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; ladies.&lt;br /&gt;
&lt;br /&gt;
After sitting the wives, we label the remaining &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; places clockwise as &amp;lt;math&amp;gt;0,1,\ldots, n-1&amp;lt;/math&amp;gt;. And a seating of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; husbands is given by a permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; defined as follows. Let &amp;lt;math&amp;gt;\pi(i)&amp;lt;/math&amp;gt; be the seat of the husband of he lady sitting at the &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;-th place.&lt;br /&gt;
&lt;br /&gt;
It is easy to see that &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; satisfies that &amp;lt;math&amp;gt;\pi(i)\neq i&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\pi(i)\not\equiv i+1\pmod n&amp;lt;/math&amp;gt;, and every permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; with these properties gives a feasible seating of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; husbands. Thus, we only need to count the number of permutations &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;\pi(i)\not\equiv i, i+1\pmod n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Take &amp;lt;math&amp;gt;B=\{(0,0),(1,1),\ldots,(n-1,n-1), (0,1),(1,2),\ldots,(n-2,n-1),(n-1,0)\}&amp;lt;/math&amp;gt; as the chess board.  A permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; which defines a way of seating the husbands, is a placement of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; non-attacking rooks such that none of them is in &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;. &lt;br /&gt;
{{Chess diagram small&lt;br /&gt;
| &lt;br /&gt;
| &lt;br /&gt;
|=&lt;br /&gt;
 8 |xx|xx|__|__|__|__|__|__|=&lt;br /&gt;
 7 |__|xx|xx|__|__|__|__|__|=&lt;br /&gt;
 6 |__|__|xx|xx|__|__|__|__|=&lt;br /&gt;
 5 |__|__|__|xx|xx|__|__|__|=&lt;br /&gt;
 4 |__|__|__|__|xx|xx|__|__|=&lt;br /&gt;
 3 |__|__|__|__|__|xx|xx|__|=&lt;br /&gt;
 2 |__|__|__|__|__|__|xx|xx|=&lt;br /&gt;
 1 |xx|__|__|__|__|__|__|xx|=&lt;br /&gt;
 a b c d e f g h&lt;br /&gt;
|&lt;br /&gt;
}}&lt;br /&gt;
We need to compute &amp;lt;math&amp;gt;r_k&amp;lt;/math&amp;gt;, the number of ways of placing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; non-attacking rooks on &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;. For our choice of &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;r_k&amp;lt;/math&amp;gt; is the number of ways of choosing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; points, no two consecutive, from a collection of &amp;lt;math&amp;gt;2n&amp;lt;/math&amp;gt; points arranged in a circle.&lt;br /&gt;
&lt;br /&gt;
We first see how to do this in a &#039;&#039;line&#039;&#039;.&lt;br /&gt;
{{Theorem|Lemma|&lt;br /&gt;
:The number of ways of choosing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; &#039;&#039;non-consecutive&#039;&#039; objects from a collection of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; objects arranged in a &#039;&#039;line&#039;&#039;, is &amp;lt;math&amp;gt;{m-k+1\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
We draw a line of &amp;lt;math&amp;gt;m-k&amp;lt;/math&amp;gt; black points, and then insert &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; red points into the &amp;lt;math&amp;gt;m-k+1&amp;lt;/math&amp;gt; spaces between the black points (including the beginning and end).&lt;br /&gt;
::&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
&amp;amp;\sqcup \, \bullet \, \sqcup \, \bullet \, \sqcup \, \bullet \, \sqcup \, \bullet \, \sqcup \, \bullet \, \sqcup \, \bullet \, \sqcup \, \bullet \, \sqcup \\&lt;br /&gt;
&amp;amp;\qquad\qquad\qquad\quad\Downarrow\\&lt;br /&gt;
&amp;amp;\sqcup \, \bullet \,\, {\color{Red}\bullet} \, \bullet \,\, {\color{Red}\bullet} \, \bullet \, \sqcup \, \bullet \,\, {\color{Red}\bullet}\, \, \bullet \, \sqcup \, \bullet \, \sqcup \, \bullet \,\, {\color{Red}\bullet}&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
This gives us a line of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; points, and the red points specifies the chosen objects, which are non-consecutive. The mapping is 1-1 correspondence.&lt;br /&gt;
There are &amp;lt;math&amp;gt;{m-k+1\choose k}&amp;lt;/math&amp;gt; ways of placing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; red points into &amp;lt;math&amp;gt;m-k+1&amp;lt;/math&amp;gt; spaces.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The problem of choosing non-consecutive objects in a circle can be reduced to the case that the objects are in a line.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Lemma|&lt;br /&gt;
:The number of ways of choosing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; &#039;&#039;non-consecutive&#039;&#039; objects from a collection of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; objects arranged in a &#039;&#039;circle&#039;&#039;, is &amp;lt;math&amp;gt;\frac{m}{m-k}{m-k\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Let &amp;lt;math&amp;gt;f(m,k)&amp;lt;/math&amp;gt; be the desired number; and let &amp;lt;math&amp;gt;g(m,k)&amp;lt;/math&amp;gt; be the number of ways of choosing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; non-consecutive points from &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; points arranged in a circle, next coloring the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; points red, and then coloring one of the uncolored point blue. &lt;br /&gt;
&lt;br /&gt;
Clearly, &amp;lt;math&amp;gt;g(m,k)=(m-k)f(m,k)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
But we can also compute &amp;lt;math&amp;gt;g(m,k)&amp;lt;/math&amp;gt; as follows:&lt;br /&gt;
* Choose one of the &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; points and color it blue. This gives us &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; ways.&lt;br /&gt;
* Cut the circle to make a line of &amp;lt;math&amp;gt;m-1&amp;lt;/math&amp;gt; points by removing the blue point.&lt;br /&gt;
* Choose &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; non-consecutive points from the line of &amp;lt;math&amp;gt;m-1&amp;lt;/math&amp;gt; points and color them red. This gives &amp;lt;math&amp;gt;{m-k\choose k}&amp;lt;/math&amp;gt; ways due to the previous lemma.&lt;br /&gt;
&lt;br /&gt;
Thus, &amp;lt;math&amp;gt;g(m,k)=m{m-k\choose k}&amp;lt;/math&amp;gt;. Therefore we have the desired number &amp;lt;math&amp;gt;f(m,k)=\frac{m}{m-k}{m-k\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
By the above lemma, we have that &amp;lt;math&amp;gt;r_k=\frac{2n}{2n-k}{2n-k\choose k}&amp;lt;/math&amp;gt;. Then apply the theorem of counting permutations with restricted positions,&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
N_0=\sum_{k=0}^n(-1)^kr_k(n-k)!=\sum_{k=0}^n(-1)^k\frac{2n}{2n-k}{2n-k\choose k}(n-k)!.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This gives the number of ways of seating the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; husbands &#039;&#039;after the ladies are seated&#039;&#039;. Recall that there are &amp;lt;math&amp;gt;2n!&amp;lt;/math&amp;gt; ways of seating the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; ladies. Thus, the total number of ways of seating &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; couples as required by problème des ménages is &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
2n!\sum_{k=0}^n(-1)^k\frac{2n}{2n-k}{2n-k\choose k}(n-k)!.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Inversion ==&lt;br /&gt;
&lt;br /&gt;
=== Posets ===&lt;br /&gt;
A &#039;&#039;&#039;partially ordered set&#039;&#039;&#039; or &#039;&#039;&#039;poset&#039;&#039;&#039; for short is a set &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; together with a binary relation denoted &amp;lt;math&amp;gt;\le_P&amp;lt;/math&amp;gt; (or just &amp;lt;math&amp;gt;\le&amp;lt;/math&amp;gt; if no confusion is caused), satisfying&lt;br /&gt;
* (&#039;&#039;reflexivity&#039;&#039;) For all &amp;lt;math&amp;gt;x\in P, x\le x&amp;lt;/math&amp;gt;.&lt;br /&gt;
* (&#039;&#039;antisymmetry&#039;&#039;) If &amp;lt;math&amp;gt;x\le y&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y\le x&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;x=y&amp;lt;/math&amp;gt;.&lt;br /&gt;
* (&#039;&#039;transitivity&#039;&#039;) If &amp;lt;math&amp;gt;x\le y&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y\le z&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;x\le z&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We say two elements &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y&amp;lt;/math&amp;gt; are &#039;&#039;&#039;comparable&#039;&#039;&#039; if &amp;lt;math&amp;gt;x\le y&amp;lt;/math&amp;gt; or &amp;lt;math&amp;gt;y\le x&amp;lt;/math&amp;gt;; otherwise &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y&amp;lt;/math&amp;gt; are &#039;&#039;&#039;incomparable&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
;Notation&lt;br /&gt;
* &amp;lt;math&amp;gt;x\ge y&amp;lt;/math&amp;gt; means &amp;lt;math&amp;gt;y\le x&amp;lt;/math&amp;gt;.&lt;br /&gt;
* &amp;lt;math&amp;gt;x&amp;lt;y&amp;lt;/math&amp;gt; means &amp;lt;math&amp;gt;x\le y&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;x\neq y&amp;lt;/math&amp;gt;.&lt;br /&gt;
* &amp;lt;math&amp;gt;x&amp;gt;y&amp;lt;/math&amp;gt; means &amp;lt;math&amp;gt;y&amp;lt;x&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== The Möbius function===&lt;br /&gt;
Let &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; be a finite poset. Consider functions in form of &amp;lt;math&amp;gt;\alpha:P\times P\rightarrow\mathbb{R}&amp;lt;/math&amp;gt; defined over domain &amp;lt;math&amp;gt;P\times P&amp;lt;/math&amp;gt;. It is convenient to treat such functions as matrices whose rows and columns are indexed by &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
;Incidence algebra of poset&lt;br /&gt;
:Let &lt;br /&gt;
::&amp;lt;math&amp;gt;I(P)=\{\alpha:P\times P\rightarrow\mathbb{R}\mid \alpha(x,y)=0\text{ for all }x\not\le_P y\}&amp;lt;/math&amp;gt; &lt;br /&gt;
:be the class of &amp;lt;math&amp;gt;\alpha&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;\alpha(x,y)&amp;lt;/math&amp;gt; is non-zero only for &amp;lt;math&amp;gt;x\le_P y&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
:Treating &amp;lt;math&amp;gt;\alpha&amp;lt;/math&amp;gt; as matrix, it is trivial to see that &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt; is closed under addition and scalar multiplication, that is,&lt;br /&gt;
:* if &amp;lt;math&amp;gt;\alpha,\beta\in I(P)&amp;lt;/math&amp;gt; then &amp;lt;math&amp;gt;\alpha+\beta\in I(P)&amp;lt;/math&amp;gt;;&lt;br /&gt;
:* if &amp;lt;math&amp;gt;\alpha\in I(P)&amp;lt;/math&amp;gt; then &amp;lt;math&amp;gt;c\alpha\in I(P)&amp;lt;/math&amp;gt; for any &amp;lt;math&amp;gt;c\in\mathbb{R}&amp;lt;/math&amp;gt;;&lt;br /&gt;
:where &amp;lt;math&amp;gt;\alpha,\beta&amp;lt;/math&amp;gt; are treated as matrices.&lt;br /&gt;
&lt;br /&gt;
:With this spirit, it is natural to define the matrix multiplication in &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt;. For &amp;lt;math&amp;gt;\alpha,\beta\in I(P)&amp;lt;/math&amp;gt;, &lt;br /&gt;
::&amp;lt;math&amp;gt;(\alpha\beta)(x,y)=\sum_{z\in P}\alpha(x,z)\beta(z,y)=\sum_{x\le z\le y}\alpha(x,z)\beta(z,y)&amp;lt;/math&amp;gt;.&lt;br /&gt;
:The second equation is due to that for &amp;lt;math&amp;gt;\alpha,\beta\in I(P)&amp;lt;/math&amp;gt;, for all &amp;lt;math&amp;gt;z&amp;lt;/math&amp;gt; other than &amp;lt;math&amp;gt;x\le z\le y&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;\alpha(x,z)\beta(z,y)&amp;lt;/math&amp;gt; is zero.&lt;br /&gt;
:By the transitivity of relation &amp;lt;math&amp;gt;\le_P&amp;lt;/math&amp;gt;, it is also easy to prove that &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt; is closed under matrix multiplication (the detailed proof is left as an exercise). Therefore, &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt; is closed under addition, scalar multiplication and matrix multiplication, so we have an algebra &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt;, called &#039;&#039;&#039;incidence algebra&#039;&#039;&#039;, over functions on &amp;lt;math&amp;gt;P\times P&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
;Zeta function and Möbius function&lt;br /&gt;
:A special function in &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt; is the so-called &#039;&#039;&#039;zeta function&#039;&#039;&#039; &amp;lt;math&amp;gt;\zeta&amp;lt;/math&amp;gt;, defined as&lt;br /&gt;
::&amp;lt;math&amp;gt;\zeta(x,y)=\begin{cases}1&amp;amp;\text{if }x\le_P y,\\0 &amp;amp;\text{otherwise.}\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
:As a matrix (or more accurately, as an element of the incidence algebra), &amp;lt;math&amp;gt;\zeta&amp;lt;/math&amp;gt; is invertible and its inversion, denoted by &amp;lt;math&amp;gt;\mu&amp;lt;/math&amp;gt;, is called the &#039;&#039;&#039;Möbius function&#039;&#039;&#039;. More precisely, &amp;lt;math&amp;gt;\mu&amp;lt;/math&amp;gt; is also in the incidence algebra &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;\mu\zeta=I&amp;lt;/math&amp;gt; where &amp;lt;math&amp;gt;I&amp;lt;/math&amp;gt; is the identity matrix (the identity of the incidence algebra &amp;lt;math&amp;gt;I(P)&amp;lt;/math&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
There is an equivalent explicit definition of Möbius function.&lt;br /&gt;
{{Theorem|Definition (Möbius function)|&lt;br /&gt;
:&amp;lt;math&amp;gt;\mu(x,y)=\begin{cases}&lt;br /&gt;
-\sum_{x\le z&amp;lt; y}\mu(x,z)&amp;amp;\text{if }x&amp;lt;y,\\&lt;br /&gt;
1&amp;amp;\text{if }x=y,\\&lt;br /&gt;
0&amp;amp;\text{if }x\not\le y. &lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
To see the equivalence between this definition and the inversion of zeta function, we may have the following proposition, which is proved by directly evaluating &amp;lt;math&amp;gt;\mu\zeta&amp;lt;/math&amp;gt;.&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
:For any &amp;lt;math&amp;gt;x,y\in P&amp;lt;/math&amp;gt;,&lt;br /&gt;
::&amp;lt;math&amp;gt;\sum_{x\le z\le y}\mu(x,z)=\begin{cases}1 &amp;amp;\text{if }x=y,\\&lt;br /&gt;
0 &amp;amp;\text{otherwise.}\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
It holds that&lt;br /&gt;
:&amp;lt;math&amp;gt;(\mu\zeta)(x,y)=\sum_{x\le z\le y}\mu(x,z)\zeta(z,y)=\sum_{x\le z\le y}\mu(x,z)&amp;lt;/math&amp;gt;.&lt;br /&gt;
On the other hand, &amp;lt;math&amp;gt;\mu\zeta=I&amp;lt;/math&amp;gt;, i.e. &lt;br /&gt;
:&amp;lt;math&amp;gt;(\mu\zeta)(x,y)=\begin{cases}1 &amp;amp;\text{if }x=y,\\&lt;br /&gt;
0 &amp;amp;\text{otherwise.}\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
The proposition follows.&lt;br /&gt;
}}&lt;br /&gt;
Note that &amp;lt;math&amp;gt;\mu(x,y)=\sum_{x\le z\le y}\mu(x,z)-\sum_{x\le z&amp;lt; y}\mu(x,z)&amp;lt;/math&amp;gt;, which gives the above inductive definition of Möbius function.&lt;br /&gt;
&lt;br /&gt;
=== Computing Möbius functions===&lt;br /&gt;
We consider the simple poset &amp;lt;math&amp;gt;P=[n]&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;\le&amp;lt;/math&amp;gt; is the total order. It follows directly from the recursive definition of Möbius function that&lt;br /&gt;
:&amp;lt;math&amp;gt;\mu(i,j)=\begin{cases}1 &amp;amp; \text{if }i=j,\\&lt;br /&gt;
-1 &amp;amp; \text{if }i+1=j,\\&lt;br /&gt;
0 &amp;amp; \text{otherwise.}&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Usually for general posets, it is difficult to directly compute the Möbius function from its definition. We introduce a rule helping us compute the Möbius function by decomposing the poset into posets with simple structures.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem (the product rule)|&lt;br /&gt;
: Let &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; be two finite posets, and &amp;lt;math&amp;gt;P\times Q&amp;lt;/math&amp;gt; be the poset resulted from Cartesian product of &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt;, where for all &amp;lt;math&amp;gt;(x,y), (x&#039;,y&#039;)\in P\times Q&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;(x,y)\le (x&#039;,y&#039;)&amp;lt;/math&amp;gt; if and only if &amp;lt;math&amp;gt;x\le x&#039;&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y\le y&#039;&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
::&amp;lt;math&amp;gt;\mu_{P\times Q}((x,y),(x&#039;,y&#039;))=\mu_P(x,x&#039;)\mu_Q(y,y&#039;)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
We use the recursive definition &lt;br /&gt;
:&amp;lt;math&amp;gt;\mu(x,y)=\begin{cases}&lt;br /&gt;
-\sum_{x\le z&amp;lt; y}\mu(x,z)&amp;amp;\text{if }x&amp;lt;y,\\&lt;br /&gt;
1&amp;amp;\text{if }x=y,\\&lt;br /&gt;
0&amp;amp;\text{if }x\not\le y. &lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
to prove the equation in the theorem.&lt;br /&gt;
&lt;br /&gt;
If &amp;lt;math&amp;gt;(x,y)=(x&#039;,y&#039;)&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;x=x&#039;&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y=y&#039;&amp;lt;/math&amp;gt;. It is easy to see that both sides of the equation are 1. If &amp;lt;math&amp;gt;(x,y)\not\le(x&#039;,y&#039;)&amp;lt;/math&amp;gt;, then either &amp;lt;math&amp;gt;x\not\le x&#039;&amp;lt;/math&amp;gt; or &amp;lt;math&amp;gt;y\not\le y&#039;&amp;lt;/math&amp;gt;. It is also easy to see that both sides are 0.&lt;br /&gt;
&lt;br /&gt;
The only remaining case is that &amp;lt;math&amp;gt;(x,y)&amp;lt;(x&#039;,y&#039;)&amp;lt;/math&amp;gt;, in which case either &amp;lt;math&amp;gt;x&amp;lt;x&#039;&amp;lt;/math&amp;gt; or &amp;lt;math&amp;gt;y&amp;lt;y&#039;&amp;lt;/math&amp;gt;. &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\sum_{(x,y)\le (u,v)\le (x&#039;,y&#039;)}\mu_P(x,u)\mu_Q(y,v)&lt;br /&gt;
&amp;amp;=\left(\sum_{x\le u\le x&#039;}\mu_P(x,u)\right)\left(\sum_{y\le v\le y&#039;}\mu_Q(y,v)\right)=I(x,x&#039;)I(y,y&#039;)=0,&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
where the last two equations are due to the proposition for &amp;lt;math&amp;gt;\mu&amp;lt;/math&amp;gt;. Thus&lt;br /&gt;
:&amp;lt;math&amp;gt;\mu_P(x,x&#039;)\mu_Q(y,y&#039;)=-\sum_{(x,y)\le (u,v)&amp;lt; (x&#039;,y&#039;)}\mu_P(x,u)\mu_Q(y,v)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
By induction, assume that the equation &amp;lt;math&amp;gt;\mu_{P\times Q}((x,y),(u,v))=\mu_P(x,u)\mu_Q(y,v)&amp;lt;/math&amp;gt; is true for all &amp;lt;math&amp;gt;(u,v)&amp;lt; (x&#039;,y&#039;)&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\mu_{P\times Q}((x,y),(x&#039;,y&#039;))&lt;br /&gt;
&amp;amp;=-\sum_{(x,y)\le (u,v)&amp;lt; (x&#039;,y&#039;)}\mu_{P\times Q}((x,y),(u,v))\\&lt;br /&gt;
&amp;amp;=-\sum_{(x,y)\le (u,v)&amp;lt; (x&#039;,y&#039;)}\mu_P(x,u)\mu_Q(y,v)\\&lt;br /&gt;
&amp;amp;=\mu_P(x,x&#039;)\mu_Q(y,y&#039;),&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
which complete the proof.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
;Poset of subsets&lt;br /&gt;
:Consider the poset defined by all subsets of a finite universe &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt;, that is &amp;lt;math&amp;gt;P=2^U&amp;lt;/math&amp;gt;, and for &amp;lt;math&amp;gt;S,T\subseteq U&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;S\le_P T&amp;lt;/math&amp;gt; if and only if &amp;lt;math&amp;gt;S\subseteq T&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem| Möbius function for subsets|&lt;br /&gt;
:The Möbius function for the above defined poset &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is that for &amp;lt;math&amp;gt;S,T\subseteq U&amp;lt;/math&amp;gt;,&lt;br /&gt;
::&amp;lt;math&amp;gt;\mu(S,T)=&lt;br /&gt;
\begin{cases}&lt;br /&gt;
(-1)^{|T|-|S|} &amp;amp; \text{if }S\subseteq T,\\&lt;br /&gt;
0 &amp;amp;\text{otherwise.}&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
We can equivalently represent each &amp;lt;math&amp;gt;S\subseteq U&amp;lt;/math&amp;gt; by a boolean string &amp;lt;math&amp;gt;S\in\{0,1\}^U&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;S(x)=1&amp;lt;/math&amp;gt; if and only if &amp;lt;math&amp;gt;x\in S&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For each element &amp;lt;math&amp;gt;x\in U&amp;lt;/math&amp;gt;, we can define a poset &amp;lt;math&amp;gt;P_x=\{0, 1\}&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;0\le 1&amp;lt;/math&amp;gt;. By definition of Möbius function, the Möbius function of this elementary poset is given by &amp;lt;math&amp;gt;\mu_x(0,0)=\mu_x(1,1)=1&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;\mu_x(0,1)=-1&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\mu(1,0)=0&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The poset &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; of all subsets of &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; is the Cartesian product of all &amp;lt;math&amp;gt;P_x&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;x\in U&amp;lt;/math&amp;gt;. By the product rule,&lt;br /&gt;
:&amp;lt;math&amp;gt;\mu(S,T)=\prod_{x\in U}\mu_x(S(x), T(x))=\prod_{x\in S\atop x\in T}1\prod_{x\not\in S\atop x\not\in T}1\prod_{x\in S\atop x\not\in T}0\prod_{x\not\in S\atop x\in T}(-1)=\begin{cases}&lt;br /&gt;
(-1)^{|T|-|S|} &amp;amp; \text{if }S\subseteq T,\\&lt;br /&gt;
0 &amp;amp;\text{otherwise.}&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
:Note that the poset &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is actually the [http://en.wikipedia.org/wiki/Boolean_algebra_(structure) Boolean algebra] of rank &amp;lt;math&amp;gt;|U|&amp;lt;/math&amp;gt;. The proof relies only on that the fact that the poset is a Boolean algebra, thus the theorem holds for Boolean algebra posets.&lt;br /&gt;
&lt;br /&gt;
;Posets of divisors&lt;br /&gt;
:Consider the poset defined by all devisors of a positive integer &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, that is &amp;lt;math&amp;gt;P=\{a&amp;gt;0\mid a|n\}&amp;lt;/math&amp;gt;, and for &amp;lt;math&amp;gt;a,b\in P&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;a\le_P b&amp;lt;/math&amp;gt; if and only if &amp;lt;math&amp;gt;a|b\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Möbius function for divisors|&lt;br /&gt;
:The Möbius function for the above defined poset &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is that for &amp;lt;math&amp;gt;a,b&amp;gt;0&amp;lt;/math&amp;gt; that &amp;lt;math&amp;gt;a|n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;b|n&amp;lt;/math&amp;gt;,&lt;br /&gt;
::&amp;lt;math&amp;gt;\mu(a,b)=&lt;br /&gt;
\begin{cases}&lt;br /&gt;
(-1)^{r} &amp;amp; \text{if }\frac{b}{a}\text{ is the product of }r\text{ distinct primes},\\&lt;br /&gt;
0 &amp;amp;\text{otherwise, i.e. if }a\not|b\text{ or }\frac{b}{a}\text{ is not squarefree.}&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Denote &amp;lt;math&amp;gt;n=p_1^{n_1}p_2^{n_2}\cdots p_k^{n_k}&amp;lt;/math&amp;gt;. Represent &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; by a tuple &amp;lt;math&amp;gt;(n_1,n_2,\ldots,n_k)&amp;lt;/math&amp;gt;. Every &amp;lt;math&amp;gt;a\in P&amp;lt;/math&amp;gt; corresponds in this way to a tuple &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_k)&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;a_i\le n_i&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;1\le i\le k&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;P_i=\{1,2,\ldots,n_i\}&amp;lt;/math&amp;gt; be the poset with &amp;lt;math&amp;gt;\le&amp;lt;/math&amp;gt; being the total order. The poset &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; of divisors of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is thus isomorphic to the poset constructed by the Cartesian product of all &amp;lt;math&amp;gt;P_i&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;1\le i\le k&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\mu(a,b)&lt;br /&gt;
&amp;amp;=\prod_{1\le i\le k}\mu(a_i,b_i)=\prod_{1\le i\le k\atop a_i=b_i}1\prod_{1\le i\le k\atop b_i-a_i=1}(-1)\prod_{1\le i\le k\atop b_i-a_i\not\in\{0,1\}}0&lt;br /&gt;
=\begin{cases}&lt;br /&gt;
(-1)^{\sum_{i}(b_i-a_i)} &amp;amp; \text{if all }b_i-a_i\in\{0,1\},\\&lt;br /&gt;
0 &amp;amp;\text{otherwise.}&lt;br /&gt;
\end{cases}\\&lt;br /&gt;
&amp;amp;=\begin{cases}&lt;br /&gt;
(-1)^{r} &amp;amp; \text{if }\frac{b}{a}\text{ is the product of }r\text{ distinct primes},\\&lt;br /&gt;
0 &amp;amp;\text{otherwise.}&lt;br /&gt;
\end{cases}&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Principle of Möbius inversion ===&lt;br /&gt;
We now introduce the the famous Möbius inversion formula.&lt;br /&gt;
{{Theorem|Möbius inversion formula|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; be a finite poset and &amp;lt;math&amp;gt;\mu&amp;lt;/math&amp;gt; its Möbius function. Let &amp;lt;math&amp;gt;f,g:P\rightarrow \mathbb{R}&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
::&amp;lt;math&amp;gt;\forall x\in P,\,\, g(x)=\sum_{y\le x} f(y)&amp;lt;/math&amp;gt;,&lt;br /&gt;
:if and only if&lt;br /&gt;
::&amp;lt;math&amp;gt;\forall x\in P,\,\, f(x)=\sum_{y\le x}g(y)\mu(y,x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
The functions &amp;lt;math&amp;gt;f,g:P\rightarrow\mathbb{R}&amp;lt;/math&amp;gt; are vectors. Evaluate the matrix multiplications &amp;lt;math&amp;gt;f\zeta&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;g\mu&amp;lt;/math&amp;gt; as follows:&lt;br /&gt;
:&amp;lt;math&amp;gt;(f\zeta)(x)=\sum_{y\in P}f(y)\zeta(y,x)=\sum_{y\le x}f(y)&amp;lt;/math&amp;gt;,&lt;br /&gt;
and &lt;br /&gt;
:&amp;lt;math&amp;gt;(g\mu)(x)=\sum_{y\in P}g(y)\mu(y,x)=\sum_{y\le x}g(y)\mu(y,x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
The Möbius inversion formula is nothing but the following statement&lt;br /&gt;
:&amp;lt;math&amp;gt;f\zeta=g\Leftrightarrow f=g\mu&amp;lt;/math&amp;gt;,&lt;br /&gt;
which is trivially true due to &amp;lt;math&amp;gt;\mu\zeta=I&amp;lt;/math&amp;gt; by basic linear algebra.&lt;br /&gt;
&lt;br /&gt;
The following dual form of the inversion formula is also useful.&lt;br /&gt;
{{Theorem|Möbius inversion formula, dual form|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; be a finite poset and &amp;lt;math&amp;gt;\mu&amp;lt;/math&amp;gt; its Möbius function. Let &amp;lt;math&amp;gt;f,g:P\rightarrow \mathbb{R}&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
::&amp;lt;math&amp;gt;\forall x\in P, \,\, g(x)=\sum_{y{\color{red}\ge} x} f(y)&amp;lt;/math&amp;gt;,&lt;br /&gt;
: if and only if &lt;br /&gt;
::&amp;lt;math&amp;gt;\forall x\in P, \,\, f(x)=\sum_{y{\color{red}\ge} x}\mu(x,y)g(y)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
To prove the dual form, we only need to evaluate the matrix multiplications on left:&lt;br /&gt;
:&amp;lt;math&amp;gt;\zeta f=g\Leftrightarrow f=\mu g&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
;Principle of Inclusion-Exclusion&lt;br /&gt;
:Let &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n\subseteq U&amp;lt;/math&amp;gt;. For any &amp;lt;math&amp;gt;J\subseteq\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;, &lt;br /&gt;
:*let &amp;lt;math&amp;gt;f(J)&amp;lt;/math&amp;gt; be the number of elements that belongs to &#039;&#039;exactly&#039;&#039; the sets &amp;lt;math&amp;gt;A_i, i\in J&amp;lt;/math&amp;gt; and to no others, i.e. &lt;br /&gt;
:::&amp;lt;math&amp;gt;f(J)=\left|\left(\bigcap_{i\in J}A_i\right)\setminus\left(\bigcup_{i\not\in J}A_i\right)\right|&amp;lt;/math&amp;gt;;&lt;br /&gt;
:*let &amp;lt;math&amp;gt;g(J)=\left|\bigcap_{i\in J}A_i\right|&amp;lt;/math&amp;gt;.&lt;br /&gt;
:For any &amp;lt;math&amp;gt;J\subseteq\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;, the following relation holds for the above defined &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;g&amp;lt;/math&amp;gt;:&lt;br /&gt;
::&amp;lt;math&amp;gt;g(J)=\sum_{I\supseteq J}f(I)&amp;lt;/math&amp;gt;.&lt;br /&gt;
:Applying the dual form of the Möbius inversion formula, we have that for any &amp;lt;math&amp;gt;J\subseteq\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;,&lt;br /&gt;
::&amp;lt;math&amp;gt;f(J)=\sum_{I\supseteq J}\mu(J,I)g(I)=\sum_{I\supseteq J}\mu(J,I)\left|\bigcap_{i\in I}A_i\right|&amp;lt;/math&amp;gt;,&lt;br /&gt;
:where the Möbius function is for the poset of all subsets of &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;, ordered by &amp;lt;math&amp;gt;\subseteq&amp;lt;/math&amp;gt;, thus it holds that &amp;lt;math&amp;gt;\mu(J,I)=(-1)^{|I|-|J|}\,&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;J\subseteq I&amp;lt;/math&amp;gt;. Therefore,&lt;br /&gt;
::&amp;lt;math&amp;gt;f(J)=\sum_{I\supseteq J}(-1)^{|I|-|J|}\left|\bigcap_{i\in I}A_i\right|&amp;lt;/math&amp;gt;.&lt;br /&gt;
:We have a formula for the number of elements with exactly those properties &amp;lt;math&amp;gt;A_i, i\in J&amp;lt;/math&amp;gt; for any &amp;lt;math&amp;gt;J\subseteq\{1,2,\ldots,n\}&amp;lt;/math&amp;gt;. For the special case that &amp;lt;math&amp;gt;J=\emptyset&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;f(\emptyset)&amp;lt;/math&amp;gt; is the number of elements satisfying no property of &amp;lt;math&amp;gt;A_1,A_2,\ldots,A_n&amp;lt;/math&amp;gt;, and&lt;br /&gt;
::&amp;lt;math&amp;gt;f(\emptyset)=\left|U\setminus\bigcup_iA_i\right|=\sum_{I\subseteq \{1,\ldots,n\}}(-1)^{|I|}\left|\bigcap_{i\in I}A_i\right|&amp;lt;/math&amp;gt;&lt;br /&gt;
:which gives precisely the Principle of Inclusion-Exclusion.&lt;br /&gt;
&lt;br /&gt;
;Möbius inversion formula for number theory&lt;br /&gt;
:The number-theoretical Möbius inversion formula is stated as such: Let &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt; be a positive integer, &lt;br /&gt;
::&amp;lt;math&amp;gt;g(n)=\sum_{d|n}f(d)\,&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;n|N&amp;lt;/math&amp;gt; &lt;br /&gt;
:if and only if &lt;br /&gt;
::&amp;lt;math&amp;gt;f(n)=\sum_{d|n}g(d)\mu\left(\frac{n}{d}\right)\,&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;n|N&amp;lt;/math&amp;gt;,&lt;br /&gt;
:where &amp;lt;math&amp;gt;\mu&amp;lt;/math&amp;gt; is the [http://en.wikipedia.org/wiki/M%C3%B6bius_function number-theoretical Möbius function], defined as&lt;br /&gt;
::&amp;lt;math&amp;gt;\mu(n)=\begin{cases}1 &amp;amp; \text{if }n\text{ is product of an even number of distinct primes,}\\&lt;br /&gt;
-1 &amp;amp;\text{if }n\text{ is product of an odd number of distinct primes,}\\&lt;br /&gt;
0 &amp;amp;\text{otherwise.}\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
:The number-theoretical Möbius inversion formula is just a special case of the Möbius inversion formula for posets, when the poset is the set of divisors of &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt;, and for any &amp;lt;math&amp;gt;a,b\in P&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;a\le_P b&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;a|b&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Sieve Method in Number Theory ==&lt;br /&gt;
=== The Euler totient function ===&lt;br /&gt;
Two integers &amp;lt;math&amp;gt;m, n&amp;lt;/math&amp;gt; are said to be &#039;&#039;&#039;relatively prime&#039;&#039;&#039; if their greatest common diviser &amp;lt;math&amp;gt;\mathrm{gcd}(m,n)=1&amp;lt;/math&amp;gt;. For a positive integer &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;\phi(n)&amp;lt;/math&amp;gt; be the number of positive integers from &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; that are relative prime to &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. This function, called the Euler &amp;lt;math&amp;gt;\phi&amp;lt;/math&amp;gt; function or &#039;&#039;&#039;the Euler totient function&#039;&#039;&#039;, is fundamental in number theory.&lt;br /&gt;
&lt;br /&gt;
We now derive a formula for this function by using the principle of inclusion-exclusion.&lt;br /&gt;
{{Theorem|Theorem (The Euler totient function)|&lt;br /&gt;
Suppose &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is divisible by precisely &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; different primes, denoted &amp;lt;math&amp;gt;p_1,\ldots,p_r&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
:&amp;lt;math&amp;gt;\phi(n)=n\prod_{i=1}^r\left(1-\frac{1}{p_i}\right)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Let &amp;lt;math&amp;gt;U=\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; be the universe. The number of positive integers from &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; which is divisible by some &amp;lt;math&amp;gt;p_{i_1},p_{i_2},\ldots,p_{i_s}\in\{p_1,\ldots,p_r\}&amp;lt;/math&amp;gt;, is &amp;lt;math&amp;gt;\frac{n}{p_{i_1}p_{i_2}\cdots p_{i_s}}&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;\phi(n)&amp;lt;/math&amp;gt; is the number of integers from &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; which is not divisible by any &amp;lt;math&amp;gt;p_1,\ldots,p_r&amp;lt;/math&amp;gt;.&lt;br /&gt;
By principle of inclusion-exclusion,&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\phi(n)&lt;br /&gt;
&amp;amp;=n+\sum_{k=1}^r(-1)^k\sum_{1\le i_1&amp;lt;i_2&amp;lt;\cdots &amp;lt;i_k\le n}\frac{n}{p_{i_1}p_{i_2}\cdots p_{i_k}}\\&lt;br /&gt;
&amp;amp;=n-\sum_{1\le i\le n}\frac{n}{p_i}+\sum_{1\le i&amp;lt;j\le n}\frac{n}{p_i p_j}-\sum_{1\le i&amp;lt;j&amp;lt;k\le n}\frac{n}{p_{i} p_{j} p_{k}}+\cdots + (-1)^r\frac{n}{p_{1}p_{2}\cdots p_{r}}\\&lt;br /&gt;
&amp;amp;=n\left(1-\sum_{1\le i\le n}\frac{1}{p_i}+\sum_{1\le i&amp;lt;j\le n}\frac{1}{p_i p_j}-\sum_{1\le i&amp;lt;j&amp;lt;k\le n}\frac{1}{p_{i} p_{j} p_{k}}+\cdots + (-1)^r\frac{1}{p_{1}p_{2}\cdots p_{r}}\right)\\&lt;br /&gt;
&amp;amp;=n\prod_{i=1}^r\left(1-\frac{1}{p_i}\right).&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Reference ==&lt;br /&gt;
* &#039;&#039;Stanley,&#039;&#039; Enumerative Combinatorics, Volume 1, Chapter 2.&lt;br /&gt;
* &#039;&#039;van Lin and Wilson&#039;&#039;, A course in combinatorics, Chapter 10, 25.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13579</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13579"/>
		<updated>2026-03-30T17:20:04Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2026/03/25)&#039;&#039;&#039;&amp;lt;font color=red size=4&amp;gt; 第一次作业已发布&amp;lt;/font&amp;gt;，请在 2026/04/08 上课之前提交到 [mailto:njucomb26@163.com njucomb26@163.com] (文件名为&#039;学号_姓名_A1.pdf&#039;)&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行([mailto:652024330006@smail.nju.edu.cn 652024330006@smail.nju.edu.cn])&lt;br /&gt;
** 周灿&lt;br /&gt;
** 方子伊&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* [[组合数学 (Spring 2026)/Problem Set 1|Problem Set 1]]&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
# [[组合数学 (Fall 2026)/Sieve methods|Sieve methods | 筛法]] ([http://tcs.nju.edu.cn/slides/comb2026/PIE.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Karger%27s_min-cut_algorithm&amp;diff=13578</id>
		<title>概率论与数理统计 (Spring 2026)/Karger&#039;s min-cut algorithm</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Karger%27s_min-cut_algorithm&amp;diff=13578"/>
		<updated>2026-03-30T17:19:17Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;令 &amp;lt;math&amp;gt;G(V, E)&amp;lt;/math&amp;gt; 是一个无向图。我们称边集 &amp;lt;math&amp;gt;C\subseteq E&amp;lt;/math&amp;gt; 是图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 的一个&amp;#039;&amp;#039;&amp;#039;割&amp;#039;&amp;#039;&amp;#039;，如果图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 在删除所有 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 中的边后变得不连通。  &amp;#039;&amp;#039;&amp;#039;最小割问题&amp;#039;&amp;#039;&amp;#039;, 也称为&amp;#039;&amp;#039;&amp;#039;全局最小割问题&amp;#039;&amp;#039;&amp;#039;, 定义如下。 {{Theorem|全局最小割问题| *&amp;#039;&amp;#039;&amp;#039;输入&amp;#039;&amp;#039;&amp;#039;：无向图 &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt;； *&amp;#039;&amp;#039;&amp;#039;输出&amp;#039;&amp;#039;&amp;#039;：图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中具有最小 &amp;lt;math&amp;gt;|C|&amp;lt;/math&amp;gt; 的割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;。 }}...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;令 &amp;lt;math&amp;gt;G(V, E)&amp;lt;/math&amp;gt; 是一个无向图。我们称边集 &amp;lt;math&amp;gt;C\subseteq E&amp;lt;/math&amp;gt; 是图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 的一个&#039;&#039;&#039;割&#039;&#039;&#039;，如果图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 在删除所有 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 中的边后变得不连通。&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;最小割问题&#039;&#039;&#039;, 也称为&#039;&#039;&#039;全局最小割问题&#039;&#039;&#039;, 定义如下。&lt;br /&gt;
{{Theorem|全局最小割问题|&lt;br /&gt;
*&#039;&#039;&#039;输入&#039;&#039;&#039;：无向图 &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt;；&lt;br /&gt;
*&#039;&#039;&#039;输出&#039;&#039;&#039;：图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中具有最小 &amp;lt;math&amp;gt;|C|&amp;lt;/math&amp;gt; 的割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;。&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
等价地，该问题要求找到一个将 &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt; 分成两个不相交非空子集 &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; 的划分，使得跨越 &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt; 的边总数最小。&lt;br /&gt;
&lt;br /&gt;
我们考虑如下更具一般性的情境：输入图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 可以是&#039;&#039;&#039;多重图&#039;&#039;&#039;（&#039;&#039;&#039;multigraph&#039;&#039;&#039;），这意味着任意两个顶点 &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; 之间可能存在多条&#039;&#039;&#039;平行边&#039;&#039;&#039;（&#039;&#039;&#039;parallel edges&#039;&#039;&#039;），也称为&#039;&#039;&#039;重&#039;&#039;&#039;(读音chóng)&#039;&#039;&#039;边&#039;&#039;&#039;。多重图中的割的定义与之前相同，割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 的大小则由 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 中所有边（包括平行边）的总数给出。等价地，可以将多重图视为带有整数边权重的图，割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 的大小表示为 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 中所有边的总权重。&lt;br /&gt;
&lt;br /&gt;
通过[http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem 最大流-最小割定理]，可以得到这个问题的一个经典的确定性算法。最大流算法可以找到一个最小的&#039;&#039;&#039;&amp;lt;math&amp;gt;s&amp;lt;/math&amp;gt;-&amp;lt;math&amp;gt;t&amp;lt;/math&amp;gt;割&#039;&#039;&#039;, 将由输入任意指定的一个&#039;&#039;&#039;源点&#039;&#039;&#039; &amp;lt;math&amp;gt;s\in V&amp;lt;/math&amp;gt; 和一个&#039;&#039;&#039;汇点&#039;&#039;&#039; &amp;lt;math&amp;gt;t\in V&amp;lt;/math&amp;gt; 分割开来。然后可以通过穷举来找到针对任意固定源点 &amp;lt;math&amp;gt;s&amp;lt;/math&amp;gt; 和所有可能的汇点 &amp;lt;math&amp;gt;t\neq s&amp;lt;/math&amp;gt; 的最小 &amp;lt;math&amp;gt;s&amp;lt;/math&amp;gt;-&amp;lt;math&amp;gt;t&amp;lt;/math&amp;gt; 割，从而求得全局最小割。&lt;br /&gt;
&lt;br /&gt;
== Karger算法 ==&lt;br /&gt;
我们将描述一个简洁优美的随机化算法来解决最小割问题。该算法最初是由[http://people.csail.mit.edu/karger/ David Karger]提出的。&lt;br /&gt;
&lt;br /&gt;
给定一个多重图 &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt; 和一条边 &amp;lt;math&amp;gt;e\in E&amp;lt;/math&amp;gt;，我们定义如下的&#039;&#039;&#039;收缩&#039;&#039;&#039;操作 &amp;lt;math&amp;gt;\mathsf{Contract}(G,e)&amp;lt;/math&amp;gt;，将 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 更新为一个新的多重图。&lt;br /&gt;
{{Theorem|收缩算子 &amp;lt;math&amp;gt;\mathsf{Contract}(G,e)&amp;lt;/math&amp;gt;|&lt;br /&gt;
设 &amp;lt;math&amp;gt;e=\{u,v\}&amp;lt;/math&amp;gt;：&lt;br /&gt;
:* 将顶点 &amp;lt;math&amp;gt;u,v&amp;lt;/math&amp;gt; 替换为一个新顶点 &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;；&lt;br /&gt;
:* 对于图中任何一条连接 &amp;lt;math&amp;gt;u,v&amp;lt;/math&amp;gt; 其中之一到 &amp;lt;math&amp;gt;u,v&amp;lt;/math&amp;gt; 以外某顶点 &amp;lt;math&amp;gt;w\in V\setminus\{u,v\}&amp;lt;/math&amp;gt; 的边，用一条新边 &amp;lt;math&amp;gt;\{x,w\}&amp;lt;/math&amp;gt; 替换它；&lt;br /&gt;
:* 图中剩余的部分保持不变。&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
换言之，&amp;lt;math&amp;gt;\mathsf{Contract}(G,\{u,v\})&amp;lt;/math&amp;gt; 将两个顶点 &amp;lt;math&amp;gt;u&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; 合并成一个新顶点 &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;，该新顶点邻接的边保留了原始图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中与 &amp;lt;math&amp;gt;u,v&amp;lt;/math&amp;gt; 两顶点之一邻接的边（但不包括二者之间的平行边 &amp;lt;math&amp;gt;\{u,v\}&amp;lt;/math&amp;gt;）。现在我们应该能意识到为什么我们考虑多重图而不是简单图——因为即使我们从没有平行边的简单图开始，收缩操作也可能引入平行边。&lt;br /&gt;
&lt;br /&gt;
收缩操作的效果如图所示：&lt;br /&gt;
[[Image:Contract.png|600px|center]]&lt;br /&gt;
&lt;br /&gt;
Karger算法的想法很简单：在每一步中，随机选择当前多重图中的一条边，将其收缩；重复这一操作，直至图中只剩下两个顶点——这两个剩下的顶点之间的所有边的集合，必然是最初图（乃至每一步中的图）中的一个割。&lt;br /&gt;
&lt;br /&gt;
{{Theorem|收缩算法 (Karger 1993)|&lt;br /&gt;
:&#039;&#039;&#039;输入:&#039;&#039;&#039; 多重图 &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt;;&lt;br /&gt;
----&lt;br /&gt;
:while &amp;lt;math&amp;gt;|V|&amp;gt;2&amp;lt;/math&amp;gt; do&lt;br /&gt;
:* 从当前图中均匀分布地选择一条随机的边 &amp;lt;math&amp;gt;e\in E&amp;lt;/math&amp;gt;;&lt;br /&gt;
:* &amp;lt;math&amp;gt;G=\mathsf{Contract}(G,e)&amp;lt;/math&amp;gt;; &lt;br /&gt;
:return &amp;lt;math&amp;gt;C=E&amp;lt;/math&amp;gt; (即当前所剩的最后两个顶点之间所有的平行边);&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
另一种看待收缩操作 &amp;lt;math&amp;gt;\mathsf{Contract}(G,e)&amp;lt;/math&amp;gt; 的方式是将其解读为对两个顶点的等价类的合并。假设 &amp;lt;math&amp;gt;V={v_1,v_2,\ldots,v_n}&amp;lt;/math&amp;gt; 是所有顶点的集合。我们从 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 个顶点等价类 &amp;lt;math&amp;gt;S_1,S_2,\ldots, S_n&amp;lt;/math&amp;gt; 开始，其中每个等价类 &amp;lt;math&amp;gt;S_i={v_i}&amp;lt;/math&amp;gt; 包含一个顶点。通过调用 &amp;lt;math&amp;gt;\mathsf{Contract}(G,e)&amp;lt;/math&amp;gt;，其中 &amp;lt;math&amp;gt;e&amp;lt;/math&amp;gt; 跨越了两个不同的等价类 &amp;lt;math&amp;gt;S_i&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;S_j&amp;lt;/math&amp;gt;，其效果是将等价类 &amp;lt;math&amp;gt;S_i&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;S_j&amp;lt;/math&amp;gt; 合并。收缩后的多重图中的边就是跨越不同顶点等价类之间的边。&lt;br /&gt;
这一视角的效果如图所示：&lt;br /&gt;
[[Image:Contract_class.png|600px|center]]&lt;br /&gt;
&lt;br /&gt;
== Karger算法的分析 ==&lt;br /&gt;
假设输入图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 为一任意给定的多重图。Karger算法输出了该图的一个随机的割。我们需要分析该随机割是最小割的概率，即如下概率的下界：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[\,\text{收缩算法输出了 }G\text{ 的一个最小割}\,]&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
对此，我们证明如下更强的结论。令 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 是输入图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中的某个特定的最小割。我们将分析如下概率的下界：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[\,\text{收缩算法输出了 }C\,]&amp;lt;/math&amp;gt;.&lt;br /&gt;
显然这一概率是收缩算法成功输出最小割的概率的下界（在这里我们使用了如下概率法则：对任意事件 &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;B&amp;lt;/math&amp;gt;，若 &amp;lt;math&amp;gt;A\subseteq B&amp;lt;/math&amp;gt;，则&amp;lt;math&amp;gt;\Pr(A)\le \Pr(B)&amp;lt;/math&amp;gt;）。&lt;br /&gt;
&lt;br /&gt;
我们引入以下记号：&lt;br /&gt;
* 令 &amp;lt;math&amp;gt;e_1,e_2,\ldots,e_{n-2}&amp;lt;/math&amp;gt; 表示在运行收缩算法时，依次选中进行收缩的随机边的序列；&lt;br /&gt;
* 令 &amp;lt;math&amp;gt;G_1=G&amp;lt;/math&amp;gt; 表示最初输入的多重图。对于 &amp;lt;math&amp;gt;i=1,2,\ldots,n-2&amp;lt;/math&amp;gt;，令 &amp;lt;math&amp;gt;G_{i+1}=\mathsf{Contract}(G_{i},e_i)&amp;lt;/math&amp;gt; 表示第 &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; 轮收缩后的多重图。&lt;br /&gt;
&lt;br /&gt;
我们可以做出如下的观察：&lt;br /&gt;
{{Theorem&lt;br /&gt;
|引理 1|&lt;br /&gt;
:如果 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 是多重图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中的一个最小割，且 &amp;lt;math&amp;gt;e\not\in C&amp;lt;/math&amp;gt;，那么 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 在收缩图 &amp;lt;math&amp;gt;G&#039;=\mathsf{Contract}(G,e)&amp;lt;/math&amp;gt; 中仍然是一个最小割。}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
我们首先观察到，收缩永远不会创建新的割：收缩图 &amp;lt;math&amp;gt;G&#039;&amp;lt;/math&amp;gt; 中的每个割也必定是原图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中的一个割。&lt;br /&gt;
&lt;br /&gt;
然后我们观察到，原始图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中的割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 能在收缩图 &amp;lt;math&amp;gt;G&#039;&amp;lt;/math&amp;gt; 中幸存，当且仅当收缩边 &amp;lt;math&amp;gt;e\not\in C&amp;lt;/math&amp;gt;。&lt;br /&gt;
&lt;br /&gt;
这两个观察都很容易通过收缩操作的定义进行验证（特别是在考虑顶点等价类的解释时更容易验证）。&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
根据&#039;&#039;&#039;引理1&#039;&#039;&#039;，我们有：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[\,\text{收缩算法输出了 }C\,]=\Pr[\,e_1,e_2,\ldots,e_{n-2}\not\in C\,]&amp;lt;/math&amp;gt;;&lt;br /&gt;
再根据链式法则，这一概率可被计算如下：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[\,e_1,e_2,\ldots,e_{n-2}\not\in C\,]=\prod_{i=1}^{n-2}\Pr[\,e_i\not\in C\mid e_1,e_2,\ldots,e_{i-1}\not\in C\,]&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
接下来我们的任务是对每个条件概率 &amp;lt;math&amp;gt;\Pr[\,e_i\not\in C\mid e_1,e_2,\ldots,e_{i-1}\not\in C\,]&amp;lt;/math&amp;gt; 给出下界。注意到：根据&#039;&#039;&#039;引理1&#039;&#039;&#039;，条件 &amp;lt;math&amp;gt;e_1,e_2,\ldots,e_{i-1}\not\in C&amp;lt;/math&amp;gt; 的发生意味着 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 仍是当前图 &amp;lt;math&amp;gt;G_i&amp;lt;/math&amp;gt; 中的最小割；而 &amp;lt;math&amp;gt;e_i&amp;lt;/math&amp;gt; 是图 &amp;lt;math&amp;gt;G_i&amp;lt;/math&amp;gt; 中的一条均匀分布的随机边。于是条件概率 &amp;lt;math&amp;gt;\Pr[\,e_i\not\in C\mid e_1,e_2,\ldots,e_{i-1}\not\in C\,]&amp;lt;/math&amp;gt; 即为图 &amp;lt;math&amp;gt;G_i&amp;lt;/math&amp;gt; 中一条均匀随机边未命中其某个最小割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 的概率。直观上：“最小”割应该在边集中相对稀疏，因此这一概率应该有下界。如下引理严格印证了这一直觉。&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|引理 2|&lt;br /&gt;
:如果 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 是多重图 &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt; 中的一个最小割，那么 &amp;lt;math&amp;gt;|E|\ge \frac{|V||C|}{2}&amp;lt;/math&amp;gt;。&lt;br /&gt;
}}&lt;br /&gt;
{{Proof| &lt;br /&gt;
:注意到每个顶点 &amp;lt;math&amp;gt;v\in V&amp;lt;/math&amp;gt; 的度数必然至少为 &amp;lt;math&amp;gt;|C|&amp;lt;/math&amp;gt;，否则所有与 &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; 邻接的边即构成了一个割（将点 &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; 与其余所有点分开），而且这个割比  &amp;lt;math&amp;gt;|C|&amp;lt;/math&amp;gt; 更小，这就与 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 是一个最小割相矛盾。&lt;br /&gt;
:现在由于每个顶点的度至少为 &amp;lt;math&amp;gt;|C|&amp;lt;/math&amp;gt;，应用[https://en.wikipedia.org/wiki/Handshaking_lemma 握手引理]，所有顶点度数之和是 &amp;lt;math&amp;gt;2|E|\ge |V||C|&amp;lt;/math&amp;gt;。（容易验证握手引理对于多重图仍旧成立。）&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
令 &amp;lt;math&amp;gt;V_i&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;E_i&amp;lt;/math&amp;gt; 分别表示多重图 &amp;lt;math&amp;gt;G_i&amp;lt;/math&amp;gt; 的顶点集和边集。注意到 &amp;lt;math&amp;gt;|V_{i}|=n-i+1&amp;lt;/math&amp;gt;。根据&#039;&#039;&#039;引理2&#039;&#039;&#039;，若 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 在 &amp;lt;math&amp;gt;G_i&amp;lt;/math&amp;gt; 中仍然是一个最小割，则有 &amp;lt;math&amp;gt;|E_i|\ge \frac{(n-i+2)|C|}{2}&amp;lt;/math&amp;gt;。于是条件概率 &amp;lt;math&amp;gt;\Pr[\,e_i\not\in C\mid e_1,e_2,\ldots,e_{i-1}\not\in C\,]&amp;lt;/math&amp;gt;可被计算如下：&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr[\,e_i\not\in C\mid e_1,e_2,\ldots,e_{i-1}\not\in C\,]&lt;br /&gt;
&amp;amp;=1-\frac{|C|}{|E_i|}\\&lt;br /&gt;
&amp;amp;\ge 1-\frac{2}{n-i+1}.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
将上述分析归总，可得：&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
\Pr[\,\text{收缩算法输出了 }G\text{ 的一个最小割}\,]&lt;br /&gt;
&amp;amp;\ge&lt;br /&gt;
\Pr[\,\text{收缩算法输出了 }C\,]\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\Pr[\,e_1,e_2,\ldots,e_{n-2}\not\in C\,]\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\prod_{i=1}^{n-2}\Pr[\,e_i\not\in C\mid e_1,e_2,\ldots,e_{i-1}\not\in C\,]\\&lt;br /&gt;
&amp;amp;\ge&lt;br /&gt;
\prod_{i=1}^{n-2}\left(1-\frac{2}{n-i+1}\right)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\prod_{k=3}^{n}\frac{k-2}{k}\\&lt;br /&gt;
&amp;amp;= \frac{2}{n(n-1)}.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
这证明了如下定理：&lt;br /&gt;
{{Theorem&lt;br /&gt;
|定理（收缩算法的正确概率）|&lt;br /&gt;
:对于 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 个顶点的任意多重图，收缩算法返回一个最小割的概率至少为 &amp;lt;math&amp;gt;\frac{2}{n(n-1)}&amp;lt;/math&amp;gt;。&lt;br /&gt;
}}&lt;br /&gt;
初看之下，这一成功概率似乎相当小。然而请注意，一个图中可能存在指数多的割（因为潜在地，每个非空点集 &amp;lt;math&amp;gt;S\subset V&amp;lt;/math&amp;gt; 都可以对应一个将 &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; 与其补集分开的割），而Karger算法有效地将这个指数级的解空间事实上缩小到了平方级别。&lt;br /&gt;
&lt;br /&gt;
我们可以独立地运行上述收缩算法 &amp;lt;math&amp;gt;t=\left\lceil\frac{n(n-1)\ln n}{2}\right\rceil&amp;lt;/math&amp;gt; 次，将所有返回的割中最小的一个作为最终结果返回。最终正确得到最小割的概率至少是：&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
&amp;amp;1-\Pr[\,\text{全部 }t\text{ 次独立运行收缩算法都没有找到 }G\text{ 的最小割}\,] \\&lt;br /&gt;
= &lt;br /&gt;
&amp;amp;1-\Pr[\,\text{一次运行收缩算法没有成功输出 }G\text{ 的最小割}\,]^{t} \\&lt;br /&gt;
\ge &lt;br /&gt;
&amp;amp;1- \left(1-\frac{2}{n(n-1)}\right)^{\frac{n(n-1)}{2}\cdot \ln n} \\&lt;br /&gt;
\ge &lt;br /&gt;
&amp;amp;1-\left(\frac{1}{\mathrm{e}}\right)^{\ln n}\\&lt;br /&gt;
=&lt;br /&gt;
&amp;amp;1-\frac{1}{n}.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== 一个概率法推论 ==&lt;br /&gt;
上述对Karger算法的分析可以导出如下关于图中最小割数量的推论。&lt;br /&gt;
{{Theorem|推论（最小割数量上界）|&lt;br /&gt;
:对于 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 个顶点的任意多重图 &amp;lt;math&amp;gt;G(V,E)&amp;lt;/math&amp;gt;，&amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中最小割的数量至多为 &amp;lt;math&amp;gt;\frac{n(n-1)}{2}&amp;lt;/math&amp;gt;。&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
首先定义事件 &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; 如下：&lt;br /&gt;
:&amp;lt;math&amp;gt;A:&amp;lt;/math&amp;gt; “收缩算法输出了图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 的某个最小割”。&lt;br /&gt;
并对 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中每一个不同的最小割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;，定义事件 &amp;lt;math&amp;gt;A_C&amp;lt;/math&amp;gt; 如下：&lt;br /&gt;
:&amp;lt;math&amp;gt;A_C:&amp;lt;/math&amp;gt; “收缩算法输出了 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;”。&lt;br /&gt;
容易验证，对于图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中的不同最小割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;，事件 &amp;lt;math&amp;gt;A_C&amp;lt;/math&amp;gt; 彼此不相容；而且，事件 &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; 是对所有最小割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt; 事件 &amp;lt;math&amp;gt;A_C&amp;lt;/math&amp;gt; 的并，即&lt;br /&gt;
:&amp;lt;math&amp;gt;A=\bigcup_{G\text{中所有最小割}C}A_C&amp;lt;/math&amp;gt;.&lt;br /&gt;
于是根据概率的 &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;可加性，有：&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr(A)=\sum_{G\text{中所有最小割}C}\Pr(A_C)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
由我们对于Karger算法的分析可得，对任何最小割 &amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;，都有 &amp;lt;math&amp;gt;\Pr(A_c)\ge\frac{2}{n(n-1)}&amp;lt;/math&amp;gt;。而作为良定义的概率，必然有 &amp;lt;math&amp;gt;\Pr(A)\le 1&amp;lt;/math&amp;gt;。因此可知，图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt; 中最小割的总数不会超过 &amp;lt;math&amp;gt;\frac{n(n-1)}{2}&amp;lt;/math&amp;gt;。&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
上述推论是一个&#039;&#039;&#039;概率法&#039;&#039;&#039;（&#039;&#039;&#039;the probabilistic method&#039;&#039;&#039;）的实例：结论本身不具有任何随机性，但是其证明过程引入了概率论。而且这个结论给出的界是紧的：存在 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 个顶点的图 &amp;lt;math&amp;gt;G&amp;lt;/math&amp;gt;，其最小割的个数刚好为  &amp;lt;math&amp;gt;\frac{n(n-1)}{2}&amp;lt;/math&amp;gt;，例如：&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 个顶点的环。&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13577</id>
		<title>概率论与数理统计 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13577"/>
		<updated>2026-03-30T17:18:35Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;&#039;&#039;&#039;概率论与数理统计&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Probability Theory&#039;&#039;&#039; &amp;lt;br&amp;gt; &amp;amp; &#039;&#039;&#039;Mathematical Statistics&#039;&#039;&#039;&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4  = office&lt;br /&gt;
|data4   = 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = liu@nju.edu.cn  &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = office&lt;br /&gt;
|data7   = 计算机系 516&lt;br /&gt;
|header8 = Class&lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &lt;br /&gt;
|header9 =&lt;br /&gt;
|label9  = Class meeting&lt;br /&gt;
|data9   = Wednesday, 9am-12am&amp;lt;br&amp;gt;&lt;br /&gt;
仙Ⅱ-212&lt;br /&gt;
|header10=&lt;br /&gt;
|label10 = Office hour&lt;br /&gt;
|data10  = TBA &amp;lt;br&amp;gt;计算机系 804（尹一通）&amp;lt;br&amp;gt;计算机系 516（刘景铖）&lt;br /&gt;
|header11= Textbook&lt;br /&gt;
|label11 = &lt;br /&gt;
|data11  = &lt;br /&gt;
|header12=&lt;br /&gt;
|label12 = &lt;br /&gt;
|data12  = [[File:概率导论.jpeg|border|100px]]&lt;br /&gt;
|header13=&lt;br /&gt;
|label13 = &lt;br /&gt;
|data13  = &#039;&#039;&#039;概率导论&#039;&#039;&#039;（第2版·修订版）&amp;lt;br&amp;gt; Dimitri P. Bertsekas and John N. Tsitsiklis&amp;lt;br&amp;gt; 郑忠国 童行伟 译；人民邮电出版社 (2022)&lt;br /&gt;
|header14=&lt;br /&gt;
|label14 = &lt;br /&gt;
|data14  = [[File:Grimmett_probability.jpg|border|100px]]&lt;br /&gt;
|header15=&lt;br /&gt;
|label15 = &lt;br /&gt;
|data15  = &#039;&#039;&#039;Probability and Random Processes&#039;&#039;&#039; (4E) &amp;lt;br&amp;gt; Geoffrey Grimmett and David Stirzaker &amp;lt;br&amp;gt;  Oxford University Press (2020)&lt;br /&gt;
|header16=&lt;br /&gt;
|label16 = &lt;br /&gt;
|data16  = [[File:Probability_and_Computing_2ed.jpg|border|100px]]&lt;br /&gt;
|header17=&lt;br /&gt;
|label17 = &lt;br /&gt;
|data17  = &#039;&#039;&#039;Probability and Computing&#039;&#039;&#039; (2E) &amp;lt;br&amp;gt; Michael Mitzenmacher and Eli Upfal &amp;lt;br&amp;gt;   Cambridge University Press (2017)&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Probability Theory and Mathematical Statistics&#039;&#039; (概率论与数理统计) class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 鞠哲：[mailto:juzhe@smail.nju.edu.cn &amp;lt;juzhe@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
** 祝永祺：[mailto:652025330045@smail.nju.edu.cn &amp;lt;652025330045@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;:&lt;br /&gt;
** 周三：9am-12am，仙Ⅱ-212&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: &lt;br /&gt;
:* TBA, 计算机系 804（尹一通）&lt;br /&gt;
:* TBA, 计算机系 516（刘景铖）&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090092561（申请加入需提供姓名、院系、学号）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
课程内容分为三大部分：&lt;br /&gt;
* &#039;&#039;&#039;经典概率论&#039;&#039;&#039;：概率空间、随机变量及其数字特征、多维与连续随机变量、极限定理等内容&lt;br /&gt;
* &#039;&#039;&#039;概率与计算&#039;&#039;&#039;：测度集中现象 (concentration of measure)、概率法 (the probabilistic method)、离散随机过程的相关专题&lt;br /&gt;
* &#039;&#039;&#039;数理统计&#039;&#039;&#039;：参数估计、假设检验、贝叶斯估计、线性回归等统计推断等概念&lt;br /&gt;
&lt;br /&gt;
对于第一和第二部分，要求清楚掌握基本概念，深刻理解关键的现象与规律以及背后的原理，并可以灵活运用所学方法求解相关问题。对于第三部分，要求熟悉数理统计的若干基本概念，以及典型的统计模型和统计推断问题。&lt;br /&gt;
&lt;br /&gt;
经过本课程的训练，力求使学生能够熟悉掌握概率的语言，并会利用概率思维来理解客观世界并对其建模，以及驾驭概率的数学工具来分析和求解专业问题。&lt;br /&gt;
&lt;br /&gt;
=== 教材与参考书 Course Materials ===&lt;br /&gt;
* &#039;&#039;&#039;[BT]&#039;&#039;&#039; 概率导论（第2版·修订版），[美]伯特瑟卡斯（Dimitri P.Bertsekas）[美]齐齐克利斯（John N.Tsitsiklis）著，郑忠国 童行伟 译，人民邮电出版社（2022）。&lt;br /&gt;
* &#039;&#039;&#039;[GS]&#039;&#039;&#039; &#039;&#039;Probability and Random Processes&#039;&#039;, by Geoffrey Grimmett and David Stirzaker; Oxford University Press; 4th edition (2020).&lt;br /&gt;
* &#039;&#039;&#039;[MU]&#039;&#039;&#039; &#039;&#039;Probability and Computing: Randomization and Probabilistic Techniques in Algorithms and Data Analysis&#039;&#039;, by Michael Mitzenmacher, Eli Upfal; Cambridge University Press; 2nd edition (2017).&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grading Policy ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。符合规则的讨论与致谢将不会影响得分。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
*[[概率论与数理统计 (Spring 2026)/Problem Set 1|Problem Set 1]]  请在 2026/4/1 上课之前(9am UTC+8)提交到 [mailto:pr2026_nju@163.com pr2026_nju@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lectures =&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/Intro.pdf 课程简介]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/ProbSpace.pdf 概率空间]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第1章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 1&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Entropy and volume of Hamming balls|Entropy and volume of Hamming balls]]&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Karger&#039;s min-cut algorithm| Karger&#039;s min-cut algorithm]]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/RandVar.pdf 随机变量]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第2章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 2, Sections 3.1~3.5, 3.7&#039;&#039;&#039;&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[MU] Chapter 2&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [https://plato.stanford.edu/entries/probability-interpret/ Interpretations of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/History_of_probability History of probability]&lt;br /&gt;
* Example problems:&lt;br /&gt;
** [https://dornsifecms.usc.edu/assets/sites/520/docs/VonNeumann-ams12p36-38.pdf von Neumann&#039;s Bernoulli factory] and other [https://peteroupc.github.io/bernoulli.html Bernoulli factory algorithms]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boy_or_Girl_paradox Boy or Girl paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Monty_Hall_problem Monty Hall problem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bertrand_paradox_(probability) Bertrand paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Hard_spheres Hard spheres model] and [https://en.wikipedia.org/wiki/Ising_model Ising model]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/PageRank &#039;&#039;PageRank&#039;&#039;] and stationary [https://en.wikipedia.org/wiki/Random_walk random walk]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Diffusion_process Diffusion process] and [https://en.wikipedia.org/wiki/Diffusion_model diffusion model]&lt;br /&gt;
*[https://en.wikipedia.org/wiki/Probability_space Probability space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sample_space Sample space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Event_(probability_theory) Event] and [https://en.wikipedia.org/wiki/Σ-algebra &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;-algebra]&lt;br /&gt;
** Kolmogorov&#039;s [https://en.wikipedia.org/wiki/Probability_axioms axioms of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Discrete_uniform_distribution Classical] and [https://en.wikipedia.org/wiki/Geometric_probability goemetric probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Boole%27s_inequality Union bound]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Inclusion%E2%80%93exclusion_principle Inclusion-Exclusion principle]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boole%27s_inequality#Bonferroni_inequalities Bonferroni inequalities]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Conditional_probability Conditional probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Chain_rule_(probability) Chain rule]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_total_probability Law of total probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bayes%27_theorem Bayes&#039; law]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Independence_(probability_theory) Independence] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Pairwise_independence Pairwise independence]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13576</id>
		<title>概率论与数理统计 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13576"/>
		<updated>2026-03-30T17:17:31Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;&#039;&#039;&#039;概率论与数理统计&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Probability Theory&#039;&#039;&#039; &amp;lt;br&amp;gt; &amp;amp; &#039;&#039;&#039;Mathematical Statistics&#039;&#039;&#039;&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4  = office&lt;br /&gt;
|data4   = 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = liu@nju.edu.cn  &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = office&lt;br /&gt;
|data7   = 计算机系 516&lt;br /&gt;
|header8 = Class&lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &lt;br /&gt;
|header9 =&lt;br /&gt;
|label9  = Class meeting&lt;br /&gt;
|data9   = Wednesday, 9am-12am&amp;lt;br&amp;gt;&lt;br /&gt;
仙Ⅱ-212&lt;br /&gt;
|header10=&lt;br /&gt;
|label10 = Office hour&lt;br /&gt;
|data10  = TBA &amp;lt;br&amp;gt;计算机系 804（尹一通）&amp;lt;br&amp;gt;计算机系 516（刘景铖）&lt;br /&gt;
|header11= Textbook&lt;br /&gt;
|label11 = &lt;br /&gt;
|data11  = &lt;br /&gt;
|header12=&lt;br /&gt;
|label12 = &lt;br /&gt;
|data12  = [[File:概率导论.jpeg|border|100px]]&lt;br /&gt;
|header13=&lt;br /&gt;
|label13 = &lt;br /&gt;
|data13  = &#039;&#039;&#039;概率导论&#039;&#039;&#039;（第2版·修订版）&amp;lt;br&amp;gt; Dimitri P. Bertsekas and John N. Tsitsiklis&amp;lt;br&amp;gt; 郑忠国 童行伟 译；人民邮电出版社 (2022)&lt;br /&gt;
|header14=&lt;br /&gt;
|label14 = &lt;br /&gt;
|data14  = [[File:Grimmett_probability.jpg|border|100px]]&lt;br /&gt;
|header15=&lt;br /&gt;
|label15 = &lt;br /&gt;
|data15  = &#039;&#039;&#039;Probability and Random Processes&#039;&#039;&#039; (4E) &amp;lt;br&amp;gt; Geoffrey Grimmett and David Stirzaker &amp;lt;br&amp;gt;  Oxford University Press (2020)&lt;br /&gt;
|header16=&lt;br /&gt;
|label16 = &lt;br /&gt;
|data16  = [[File:Probability_and_Computing_2ed.jpg|border|100px]]&lt;br /&gt;
|header17=&lt;br /&gt;
|label17 = &lt;br /&gt;
|data17  = &#039;&#039;&#039;Probability and Computing&#039;&#039;&#039; (2E) &amp;lt;br&amp;gt; Michael Mitzenmacher and Eli Upfal &amp;lt;br&amp;gt;   Cambridge University Press (2017)&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Probability Theory and Mathematical Statistics&#039;&#039; (概率论与数理统计) class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 鞠哲：[mailto:juzhe@smail.nju.edu.cn &amp;lt;juzhe@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
** 祝永祺：[mailto:652025330045@smail.nju.edu.cn &amp;lt;652025330045@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;:&lt;br /&gt;
** 周三：9am-12am，仙Ⅱ-212&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: &lt;br /&gt;
:* TBA, 计算机系 804（尹一通）&lt;br /&gt;
:* TBA, 计算机系 516（刘景铖）&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090092561（申请加入需提供姓名、院系、学号）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
课程内容分为三大部分：&lt;br /&gt;
* &#039;&#039;&#039;经典概率论&#039;&#039;&#039;：概率空间、随机变量及其数字特征、多维与连续随机变量、极限定理等内容&lt;br /&gt;
* &#039;&#039;&#039;概率与计算&#039;&#039;&#039;：测度集中现象 (concentration of measure)、概率法 (the probabilistic method)、离散随机过程的相关专题&lt;br /&gt;
* &#039;&#039;&#039;数理统计&#039;&#039;&#039;：参数估计、假设检验、贝叶斯估计、线性回归等统计推断等概念&lt;br /&gt;
&lt;br /&gt;
对于第一和第二部分，要求清楚掌握基本概念，深刻理解关键的现象与规律以及背后的原理，并可以灵活运用所学方法求解相关问题。对于第三部分，要求熟悉数理统计的若干基本概念，以及典型的统计模型和统计推断问题。&lt;br /&gt;
&lt;br /&gt;
经过本课程的训练，力求使学生能够熟悉掌握概率的语言，并会利用概率思维来理解客观世界并对其建模，以及驾驭概率的数学工具来分析和求解专业问题。&lt;br /&gt;
&lt;br /&gt;
=== 教材与参考书 Course Materials ===&lt;br /&gt;
* &#039;&#039;&#039;[BT]&#039;&#039;&#039; 概率导论（第2版·修订版），[美]伯特瑟卡斯（Dimitri P.Bertsekas）[美]齐齐克利斯（John N.Tsitsiklis）著，郑忠国 童行伟 译，人民邮电出版社（2022）。&lt;br /&gt;
* &#039;&#039;&#039;[GS]&#039;&#039;&#039; &#039;&#039;Probability and Random Processes&#039;&#039;, by Geoffrey Grimmett and David Stirzaker; Oxford University Press; 4th edition (2020).&lt;br /&gt;
* &#039;&#039;&#039;[MU]&#039;&#039;&#039; &#039;&#039;Probability and Computing: Randomization and Probabilistic Techniques in Algorithms and Data Analysis&#039;&#039;, by Michael Mitzenmacher, Eli Upfal; Cambridge University Press; 2nd edition (2017).&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grading Policy ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。符合规则的讨论与致谢将不会影响得分。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
*[[概率论与数理统计 (Spring 2026)/Problem Set 1|Problem Set 1]]  请在 2026/4/1 上课之前(9am UTC+8)提交到 [mailto:pr2026_nju@163.com pr2026_nju@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lectures =&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/Intro.pdf 课程简介]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/ProbSpace.pdf 概率空间]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第1章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 1&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Entropy and volume of Hamming balls|Entropy and volume of Hamming balls]]&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Karger&#039;s min-cut algorithm| Karger&#039;s min-cut algorithm]]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [https://plato.stanford.edu/entries/probability-interpret/ Interpretations of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/History_of_probability History of probability]&lt;br /&gt;
* Example problems:&lt;br /&gt;
** [https://dornsifecms.usc.edu/assets/sites/520/docs/VonNeumann-ams12p36-38.pdf von Neumann&#039;s Bernoulli factory] and other [https://peteroupc.github.io/bernoulli.html Bernoulli factory algorithms]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boy_or_Girl_paradox Boy or Girl paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Monty_Hall_problem Monty Hall problem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bertrand_paradox_(probability) Bertrand paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Hard_spheres Hard spheres model] and [https://en.wikipedia.org/wiki/Ising_model Ising model]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/PageRank &#039;&#039;PageRank&#039;&#039;] and stationary [https://en.wikipedia.org/wiki/Random_walk random walk]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Diffusion_process Diffusion process] and [https://en.wikipedia.org/wiki/Diffusion_model diffusion model]&lt;br /&gt;
*[https://en.wikipedia.org/wiki/Probability_space Probability space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sample_space Sample space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Event_(probability_theory) Event] and [https://en.wikipedia.org/wiki/Σ-algebra &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;-algebra]&lt;br /&gt;
** Kolmogorov&#039;s [https://en.wikipedia.org/wiki/Probability_axioms axioms of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Discrete_uniform_distribution Classical] and [https://en.wikipedia.org/wiki/Geometric_probability goemetric probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Boole%27s_inequality Union bound]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Inclusion%E2%80%93exclusion_principle Inclusion-Exclusion principle]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boole%27s_inequality#Bonferroni_inequalities Bonferroni inequalities]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Conditional_probability Conditional probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Chain_rule_(probability) Chain rule]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_total_probability Law of total probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bayes%27_theorem Bayes&#039; law]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Independence_(probability_theory) Independence] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Pairwise_independence Pairwise independence]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Entropy_and_volume_of_Hamming_balls&amp;diff=13529</id>
		<title>概率论与数理统计 (Spring 2026)/Entropy and volume of Hamming balls</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)/Entropy_and_volume_of_Hamming_balls&amp;diff=13529"/>
		<updated>2026-03-17T09:41:13Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;在求解抛掷公平硬币（fair coin）的尾概率时，我们经常会需要分析如下二项式系数求和： :&amp;lt;math&amp;gt;\sum_{k=0}^r{n\choose k}&amp;lt;/math&amp;gt;，对于某个&amp;lt;math&amp;gt;1\le r\le n&amp;lt;/math&amp;gt; 这其实等价与求一个 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 维汉明空间中半径为 &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; 的球的体积。 :{|border=&amp;quot;2&amp;quot; width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;3&amp;quot; rules=&amp;quot;all&amp;quot; style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot; | :&amp;#039;...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;在求解抛掷公平硬币（fair coin）的尾概率时，我们经常会需要分析如下二项式系数求和：&lt;br /&gt;
:&amp;lt;math&amp;gt;\sum_{k=0}^r{n\choose k}&amp;lt;/math&amp;gt;，对于某个&amp;lt;math&amp;gt;1\le r\le n&amp;lt;/math&amp;gt;&lt;br /&gt;
这其实等价与求一个 &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 维汉明空间中半径为 &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; 的球的体积。&lt;br /&gt;
:{|border=&amp;quot;2&amp;quot; width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;3&amp;quot; rules=&amp;quot;all&amp;quot; style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|&lt;br /&gt;
:&#039;&#039;&#039;&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; 维汉明空间&#039;&#039;&#039;（&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-dimensional Hamming space）是如下的度量空间 &amp;lt;math&amp;gt;\left(M,d\right)&amp;lt;/math&amp;gt;：该度量空间点集为 &amp;lt;math&amp;gt;M=\{0,1\}^n&amp;lt;/math&amp;gt;；距离 &amp;lt;math&amp;gt;d(\cdot,\cdot)&amp;lt;/math&amp;gt; 为该点集上的&#039;&#039;&#039;汉明距离&#039;&#039;&#039; (Hamming distance)，即——对于任意 &amp;lt;math&amp;gt;x,y\in\{0,1\}^n&amp;lt;/math&amp;gt;，&amp;lt;math&amp;gt;d(x,y)=\sum_{i=1}^n|x_i-y_i|&amp;lt;/math&amp;gt;。&lt;br /&gt;
:以某点 &amp;lt;math&amp;gt;o\in\{0,1\}^n&amp;lt;/math&amp;gt; 圆心、半径为 &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; 的&#039;&#039;&#039;汉明球体&#039;&#039;&#039; (Hamming ball) 为如下的点集：&lt;br /&gt;
:: &amp;lt;math&amp;gt;B_r(o)=\left\{x\in \{0,1\}^n\mid d(x,o)\le r\right\}&amp;lt;/math&amp;gt;&lt;br /&gt;
:容易验证，对于任何圆心 &amp;lt;math&amp;gt;o\in\{0,1\}^n&amp;lt;/math&amp;gt;，半径为 &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; 的汉明球体的体积，均为：&lt;br /&gt;
:: &amp;lt;math&amp;gt;|B_r(o)|=\sum_{k\le r}{n\choose k}&amp;lt;/math&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
该二项式系数的求和式相当常见。然而不幸地，除对于极少数特殊的 &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; 取值之外，我们对于这一求和式并没有通用的闭合形式解。&lt;br /&gt;
&lt;br /&gt;
对于占整个空间不超过一半的汉明球体，其体积有如下的上界总是成立。&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Lemma|&lt;br /&gt;
:对于任何 &amp;lt;math&amp;gt;p\in\left[0,\frac{1}{2}\right]&amp;lt;/math&amp;gt;，有：&lt;br /&gt;
::&amp;lt;math&amp;gt;\sum_{k\le pn}{n\choose k}\le 2^{n\cdot h(p)}&amp;lt;/math&amp;gt;&lt;br /&gt;
:这里 &amp;lt;math&amp;gt;h(p)&amp;lt;/math&amp;gt; 为&#039;&#039;&#039;二进制信息熵函数&#039;&#039;&#039; ([https://en.wikipedia.org/wiki/Binary_entropy_function binary entropy function])，定义如下：&lt;br /&gt;
::&amp;lt;math&amp;gt;h(p)=p\log_2\frac{1}{p}+(1-p)\log_2\frac{1}{1-p}&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
对此上界，有一个比较初等的计算式证明。&lt;br /&gt;
&lt;br /&gt;
{{Proof|&lt;br /&gt;
（初等证明）&lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\sum_{k\le pn}{n\choose k}/2^{n\cdot h(p)}&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{k\le pn}{n\choose k}p^{pn}(1-p)^{(1-p)n}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{k\le pn}{n\choose k}(1-p)^n\left(\frac{p}{1-p}\right)^{pn}\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
\sum_{k\le pn}{n\choose k}(1-p)^n\left(\frac{p}{1-p}\right)^{k} &amp;amp;&amp;amp;(\text{因为 } p\le 1/2\le 1-p \text{ 以及 } k\le pn)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{k\le pn}{n\choose k}(1-p)^{n-k}p^k\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
\sum_{k=0}^n{n\choose k}(1-p)^{n-k}p^k\\&lt;br /&gt;
&amp;amp;=1&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
最后一个等式是因为这是在对参数为 &amp;lt;math&amp;gt;n,p&amp;lt;/math&amp;gt; 的二项分布的概率质量求和。&lt;br /&gt;
}}&lt;br /&gt;
除了上述初等证明之外，对这一不等式还有一个基于香农信息熵的&#039;&#039;&#039;次可加性&#039;&#039;&#039;（subadditivity）的简单且直观的证明，等到我们学习了随机变量的数学期望之后可以再次学习这个新的证明。&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
与此同时，利用 [https://en.wikipedia.org/wiki/Stirling%27s_approximation Stirling公式]，可以验算得到形式如下的下界：&lt;br /&gt;
:&amp;lt;math&amp;gt;\sum_{k\le pn}{n\choose k}\ge 2^{n\cdot (h(p)-o(1))}&amp;lt;/math&amp;gt;&lt;br /&gt;
因此，上述汉明球体积上界在此渐近意义下是紧的。&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13528</id>
		<title>概率论与数理统计 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13528"/>
		<updated>2026-03-17T09:40:42Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;&#039;&#039;&#039;概率论与数理统计&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Probability Theory&#039;&#039;&#039; &amp;lt;br&amp;gt; &amp;amp; &#039;&#039;&#039;Mathematical Statistics&#039;&#039;&#039;&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4  = office&lt;br /&gt;
|data4   = 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = liu@nju.edu.cn  &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = office&lt;br /&gt;
|data7   = 计算机系 516&lt;br /&gt;
|header8 = Class&lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &lt;br /&gt;
|header9 =&lt;br /&gt;
|label9  = Class meeting&lt;br /&gt;
|data9   = Wednesday, 9am-12am&amp;lt;br&amp;gt;&lt;br /&gt;
仙Ⅱ-212&lt;br /&gt;
|header10=&lt;br /&gt;
|label10 = Office hour&lt;br /&gt;
|data10  = TBA &amp;lt;br&amp;gt;计算机系 804（尹一通）&amp;lt;br&amp;gt;计算机系 516（刘景铖）&lt;br /&gt;
|header11= Textbook&lt;br /&gt;
|label11 = &lt;br /&gt;
|data11  = &lt;br /&gt;
|header12=&lt;br /&gt;
|label12 = &lt;br /&gt;
|data12  = [[File:概率导论.jpeg|border|100px]]&lt;br /&gt;
|header13=&lt;br /&gt;
|label13 = &lt;br /&gt;
|data13  = &#039;&#039;&#039;概率导论&#039;&#039;&#039;（第2版·修订版）&amp;lt;br&amp;gt; Dimitri P. Bertsekas and John N. Tsitsiklis&amp;lt;br&amp;gt; 郑忠国 童行伟 译；人民邮电出版社 (2022)&lt;br /&gt;
|header14=&lt;br /&gt;
|label14 = &lt;br /&gt;
|data14  = [[File:Grimmett_probability.jpg|border|100px]]&lt;br /&gt;
|header15=&lt;br /&gt;
|label15 = &lt;br /&gt;
|data15  = &#039;&#039;&#039;Probability and Random Processes&#039;&#039;&#039; (4E) &amp;lt;br&amp;gt; Geoffrey Grimmett and David Stirzaker &amp;lt;br&amp;gt;  Oxford University Press (2020)&lt;br /&gt;
|header16=&lt;br /&gt;
|label16 = &lt;br /&gt;
|data16  = [[File:Probability_and_Computing_2ed.jpg|border|100px]]&lt;br /&gt;
|header17=&lt;br /&gt;
|label17 = &lt;br /&gt;
|data17  = &#039;&#039;&#039;Probability and Computing&#039;&#039;&#039; (2E) &amp;lt;br&amp;gt; Michael Mitzenmacher and Eli Upfal &amp;lt;br&amp;gt;   Cambridge University Press (2017)&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Probability Theory and Mathematical Statistics&#039;&#039; (概率论与数理统计) class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 鞠哲：[mailto:juzhe@smail.nju.edu.cn &amp;lt;juzhe@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
** 祝永祺：[mailto:652025330045@smail.nju.edu.cn &amp;lt;652025330045@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;:&lt;br /&gt;
** 周三：9am-12am，仙Ⅱ-212&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: &lt;br /&gt;
:* TBA, 计算机系 804（尹一通）&lt;br /&gt;
:* TBA, 计算机系 516（刘景铖）&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090092561（申请加入需提供姓名、院系、学号）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
课程内容分为三大部分：&lt;br /&gt;
* &#039;&#039;&#039;经典概率论&#039;&#039;&#039;：概率空间、随机变量及其数字特征、多维与连续随机变量、极限定理等内容&lt;br /&gt;
* &#039;&#039;&#039;概率与计算&#039;&#039;&#039;：测度集中现象 (concentration of measure)、概率法 (the probabilistic method)、离散随机过程的相关专题&lt;br /&gt;
* &#039;&#039;&#039;数理统计&#039;&#039;&#039;：参数估计、假设检验、贝叶斯估计、线性回归等统计推断等概念&lt;br /&gt;
&lt;br /&gt;
对于第一和第二部分，要求清楚掌握基本概念，深刻理解关键的现象与规律以及背后的原理，并可以灵活运用所学方法求解相关问题。对于第三部分，要求熟悉数理统计的若干基本概念，以及典型的统计模型和统计推断问题。&lt;br /&gt;
&lt;br /&gt;
经过本课程的训练，力求使学生能够熟悉掌握概率的语言，并会利用概率思维来理解客观世界并对其建模，以及驾驭概率的数学工具来分析和求解专业问题。&lt;br /&gt;
&lt;br /&gt;
=== 教材与参考书 Course Materials ===&lt;br /&gt;
* &#039;&#039;&#039;[BT]&#039;&#039;&#039; 概率导论（第2版·修订版），[美]伯特瑟卡斯（Dimitri P.Bertsekas）[美]齐齐克利斯（John N.Tsitsiklis）著，郑忠国 童行伟 译，人民邮电出版社（2022）。&lt;br /&gt;
* &#039;&#039;&#039;[GS]&#039;&#039;&#039; &#039;&#039;Probability and Random Processes&#039;&#039;, by Geoffrey Grimmett and David Stirzaker; Oxford University Press; 4th edition (2020).&lt;br /&gt;
* &#039;&#039;&#039;[MU]&#039;&#039;&#039; &#039;&#039;Probability and Computing: Randomization and Probabilistic Techniques in Algorithms and Data Analysis&#039;&#039;, by Michael Mitzenmacher, Eli Upfal; Cambridge University Press; 2nd edition (2017).&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grading Policy ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。符合规则的讨论与致谢将不会影响得分。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
&lt;br /&gt;
= Lectures =&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/Intro.pdf 课程简介]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/ProbSpace.pdf 概率空间]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第1章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 1&#039;&#039;&#039;&lt;br /&gt;
#* [[概率论与数理统计 (Spring 2026)/Entropy and volume of Hamming balls|Entropy and volume of Hamming balls]]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [https://plato.stanford.edu/entries/probability-interpret/ Interpretations of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/History_of_probability History of probability]&lt;br /&gt;
* Example problems:&lt;br /&gt;
** [https://dornsifecms.usc.edu/assets/sites/520/docs/VonNeumann-ams12p36-38.pdf von Neumann&#039;s Bernoulli factory] and other [https://peteroupc.github.io/bernoulli.html Bernoulli factory algorithms]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boy_or_Girl_paradox Boy or Girl paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Monty_Hall_problem Monty Hall problem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bertrand_paradox_(probability) Bertrand paradox]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Hard_spheres Hard spheres model] and [https://en.wikipedia.org/wiki/Ising_model Ising model]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/PageRank &#039;&#039;PageRank&#039;&#039;] and stationary [https://en.wikipedia.org/wiki/Random_walk random walk]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Diffusion_process Diffusion process] and [https://en.wikipedia.org/wiki/Diffusion_model diffusion model]&lt;br /&gt;
*[https://en.wikipedia.org/wiki/Probability_space Probability space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sample_space Sample space]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Event_(probability_theory) Event] and [https://en.wikipedia.org/wiki/Σ-algebra &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt;-algebra]&lt;br /&gt;
** Kolmogorov&#039;s [https://en.wikipedia.org/wiki/Probability_axioms axioms of probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Discrete_uniform_distribution Classical] and [https://en.wikipedia.org/wiki/Geometric_probability goemetric probability]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Boole%27s_inequality Union bound]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Inclusion%E2%80%93exclusion_principle Inclusion-Exclusion principle]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Boole%27s_inequality#Bonferroni_inequalities Bonferroni inequalities]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Conditional_probability Conditional probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Chain_rule_(probability) Chain rule]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Law_of_total_probability Law of total probability]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Bayes%27_theorem Bayes&#039; law]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Independence_(probability_theory) Independence] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Pairwise_independence Pairwise independence]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13503</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13503"/>
		<updated>2026-03-11T08:51:18Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]] ([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13502</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13502"/>
		<updated>2026-03-11T08:51:10Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]]([http://tcs.nju.edu.cn/slides/comb2026/GeneratingFunction.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)/Generating_functions&amp;diff=13501</id>
		<title>组合数学 (Spring 2026)/Generating functions</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)/Generating_functions&amp;diff=13501"/>
		<updated>2026-03-11T08:38:10Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;== Generating Functions == In Stanley&amp;#039;s magnificent book &amp;#039;&amp;#039;Enumerative Combinatorics&amp;#039;&amp;#039;, he comments the generating function as &amp;quot;the most useful but most difficult to understand method (for counting)&amp;quot;.  The solution to a counting problem is usually represented as some &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt; depending a parameter &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. Sometimes this &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt; is called a &amp;#039;&amp;#039;counting function&amp;#039;&amp;#039; as it is a function of the parameter &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;.  &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt; can also be tre...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Generating Functions ==&lt;br /&gt;
In Stanley&#039;s magnificent book &#039;&#039;Enumerative Combinatorics&#039;&#039;, he comments the generating function as &amp;quot;the most useful but most difficult to understand method (for counting)&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
The solution to a counting problem is usually represented as some &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt; depending a parameter &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. Sometimes this &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt; is called a &#039;&#039;counting function&#039;&#039; as it is a function of the parameter &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;.  &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt; can also be treated as a infinite series:&lt;br /&gt;
:&amp;lt;math&amp;gt;a_0,a_1,a_2,\ldots&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;ordinary generating function (OGF)&#039;&#039;&#039; defined by &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt; is&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
G(x)=\sum_{n\ge 0} a_nx^n.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
So &amp;lt;math&amp;gt;G(x)=a_0+a_1x+a_2x^2+\cdots&amp;lt;/math&amp;gt;. An expression in this form is called a [http://en.wikipedia.org/wiki/Formal_power_series &#039;&#039;&#039;formal power series&#039;&#039;&#039;], and &amp;lt;math&amp;gt;a_0,a_1,a_2,\ldots&amp;lt;/math&amp;gt; is the sequence of &#039;&#039;&#039;coefficients&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
Furthermore, the generating function can be expanded as&lt;br /&gt;
:G(x)=&amp;lt;math&amp;gt;(\underbrace{1+\cdots+1}_{a_0})+(\underbrace{x+\cdots+x}_{a_1})+(\underbrace{x^2+\cdots+x^2}_{a_2})+\cdots+(\underbrace{x^n+\cdots+x^n}_{a_n})+\cdots&amp;lt;/math&amp;gt;&lt;br /&gt;
so it indeed &amp;quot;generates&amp;quot; all the possible instances of the objects we want to count.&lt;br /&gt;
&lt;br /&gt;
Usually, we do not evaluate the generating function &amp;lt;math&amp;gt;GF(x)&amp;lt;/math&amp;gt; on any particular value. &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; remains as a &#039;&#039;&#039;formal variable&#039;&#039;&#039; without assuming any value. The numbers that we want to count are the coefficients carried by the terms in the formal power series. So far the generating function is just another way to represent the sequence&lt;br /&gt;
:&amp;lt;math&amp;gt;(a_0,a_1,a_2,\ldots\ldots)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The true power of generating functions comes from the various algebraic operations that we can perform on these generating functions. We use an example to demonstrate this.&lt;br /&gt;
&lt;br /&gt;
=== Combinations ===&lt;br /&gt;
Suppose we wish to enumerate all subsets of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set. To construct a subset, we specifies for every element of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set whether the element is chosen or not. Let us denote the choice to omit an element by &amp;lt;math&amp;gt;x_0&amp;lt;/math&amp;gt;, and the choice to include it by &amp;lt;math&amp;gt;x_1&amp;lt;/math&amp;gt;. Using &amp;quot;&amp;lt;math&amp;gt;+&amp;lt;/math&amp;gt;&amp;quot; to represent &amp;quot;OR&amp;quot;, and using the multiplication to denote &amp;quot;AND&amp;quot;, the choices of subsets of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set are expressed as&lt;br /&gt;
:&amp;lt;math&amp;gt;\underbrace{(x_0+x_1)(x_0+x_1)\cdots (x_0+x_1)}_{n\mbox{ elements}}=(x_0+x_1)^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For example, when &amp;lt;math&amp;gt;n=3&amp;lt;/math&amp;gt;, we have&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
(x_0+x_1)^3&lt;br /&gt;
&amp;amp;=x_0x_0x_0+x_0x_0x_1+x_0x_1x_0+x_0x_1x_1\\&lt;br /&gt;
&amp;amp;\quad +x_1x_0x_0+x_1x_0x_1+x_1x_1x_0+x_1x_1x_1&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
So it &amp;quot;generate&amp;quot; all subsets of the 3-set. Writing &amp;lt;math&amp;gt;1&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;x_0&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;x_1&amp;lt;/math&amp;gt;, we have &amp;lt;math&amp;gt;(1+x)^3=1+3x+3x^2+x^3&amp;lt;/math&amp;gt;. The coefficient of &amp;lt;math&amp;gt;x^k&amp;lt;/math&amp;gt; is the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subsets of a 3-element set.&lt;br /&gt;
&lt;br /&gt;
In general, &amp;lt;math&amp;gt;(1+x)^n&amp;lt;/math&amp;gt; has the coefficients which are the number of subsets of fixed sizes of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-element set.&lt;br /&gt;
&lt;br /&gt;
-----&lt;br /&gt;
&lt;br /&gt;
Suppose that we have twelve balls: &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;3 red&amp;lt;/font&amp;gt;, &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;4 blue&amp;lt;/font&amp;gt;, and &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;5 green&amp;lt;/font&amp;gt;. Balls with the same color are indistinguishable.&lt;br /&gt;
&lt;br /&gt;
We want to determine the number of ways to select &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; balls from these twelve balls, for some &amp;lt;math&amp;gt;0\le k\le 12&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The generating function of this sequence is&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
&amp;amp;\quad {\color{Red}(1+x+x^2+x^3)}{\color{Blue}(1+x+x^2+x^3+x^4)}{\color{OliveGreen}(1+x+x^2+x^3+x^4+x^5)}\\&lt;br /&gt;
&amp;amp;=1+3x+6x^2+10x^3+14x^4+17x^5+18x^6+17x^7+14x^8+10x^9+6x^{10}+3x^{11}+x^{12}.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
The coefficient of &amp;lt;math&amp;gt;x^k&amp;lt;/math&amp;gt; gives the number of ways to select &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; balls.&lt;br /&gt;
&lt;br /&gt;
=== Fibonacci numbers  ===&lt;br /&gt;
Consider the following counting problems.&lt;br /&gt;
* Count the number of ways that the nonnegative integer &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; can be written as a sum of ones and twos (in order).&lt;br /&gt;
: The problem asks for the number of compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; with summands from &amp;lt;math&amp;gt;\{1,2\}&amp;lt;/math&amp;gt;. Formally, we are counting the number of tuples &amp;lt;math&amp;gt;(x_1,x_2,\ldots,x_k)&amp;lt;/math&amp;gt; for some &amp;lt;math&amp;gt;k\le n&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;x_i\in\{1,2\}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k=n&amp;lt;/math&amp;gt;.&lt;br /&gt;
: Let &amp;lt;math&amp;gt;f_n&amp;lt;/math&amp;gt; be such a number. We observe that a composition either starts with a 1, in which case the rest is a composition of &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt;; or starts with a 2, in which case the rest is a composition of &amp;lt;math&amp;gt;n-2&amp;lt;/math&amp;gt;. So we have the recursion for &amp;lt;math&amp;gt;f_n&amp;lt;/math&amp;gt; that&lt;br /&gt;
::&amp;lt;math&amp;gt;f_n=f_{n-1}+f_{n-2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
* Count the ways to completely cover a &amp;lt;math&amp;gt;2\times n&amp;lt;/math&amp;gt; rectangle with &amp;lt;math&amp;gt;2\times 1&amp;lt;/math&amp;gt; dominos without any overlaps.&lt;br /&gt;
: Dominos are identical &amp;lt;math&amp;gt;2\times 1&amp;lt;/math&amp;gt; rectangles, so that only their orientations --- vertical or horizontal matter.&lt;br /&gt;
: Let &amp;lt;math&amp;gt;f_n&amp;lt;/math&amp;gt; be the number. It also holds that &amp;lt;math&amp;gt;f_n=f_{n-1}+f_{n-2}&amp;lt;/math&amp;gt;. The proof is left as an exercise.&lt;br /&gt;
&lt;br /&gt;
In both problems, the solution is given by &amp;lt;math&amp;gt;f_n&amp;lt;/math&amp;gt; which satisfies the following recursion.&lt;br /&gt;
:&amp;lt;math&amp;gt;f_n=\begin{cases}&lt;br /&gt;
f_{n-1}+f_{n-2} &amp;amp; \mbox{if }n\ge 2,\\&lt;br /&gt;
1 &amp;amp; \mbox{if }n=1\\&lt;br /&gt;
1 &amp;amp; \mbox{if }n=0.&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Instead we consider a closely related quantity:&lt;br /&gt;
:&amp;lt;math&amp;gt;F_n=\begin{cases}&lt;br /&gt;
F_{n-1}+F_{n-2} &amp;amp; \mbox{if }n\ge 2,\\&lt;br /&gt;
1 &amp;amp; \mbox{if }n=1\\&lt;br /&gt;
0 &amp;amp; \mbox{if }n=0.&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Clearly &amp;lt;math&amp;gt;F_n=f_{n-1}&amp;lt;/math&amp;gt; and the quantity &amp;lt;math&amp;gt;F_n&amp;lt;/math&amp;gt; is called the [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number].&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
::&amp;lt;math&amp;gt;F_n=\frac{1}{\sqrt{5}}\left(\phi^n-\hat{\phi}^n\right)&amp;lt;/math&amp;gt;,&lt;br /&gt;
:where &amp;lt;math&amp;gt;\phi=\frac{1+\sqrt{5}}{2}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\hat{\phi}=\frac{1-\sqrt{5}}{2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
The quantity &amp;lt;math&amp;gt;\phi=\frac{1+\sqrt{5}}{2}&amp;lt;/math&amp;gt; is the so-called [http://en.wikipedia.org/wiki/Golden_ratio golden ratio], a constant with some significance in mathematics and aesthetics.&lt;br /&gt;
&lt;br /&gt;
We now prove this theorem by using generating functions.&lt;br /&gt;
The ordinary generating function for the Fibonacci number &amp;lt;math&amp;gt;F_{n}&amp;lt;/math&amp;gt; is&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\sum_{n\ge 0}F_n x^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
We have that &amp;lt;math&amp;gt;F_{n}=F_{n-1}+F_{n-2}&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;n\ge 2&amp;lt;/math&amp;gt;, thus&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
G(x) &lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{n\ge 0}F_n x^n&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
F_0+F_1x+\sum_{n\ge 2}F_n x^n&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
x+\sum_{n\ge 2}(F_{n-1}+F_{n-2})x^n.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
For generating functions, there are general ways to generate &amp;lt;math&amp;gt;F_{n-1}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;F_{n-2}&amp;lt;/math&amp;gt;, or the coefficients with any smaller indices.&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
xG(x)&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}F_n x^{n+1}=\sum_{n\ge 1}F_{n-1} x^n=\sum_{n\ge 2}F_{n-1} x^n\\&lt;br /&gt;
x^2G(x)&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}F_n x^{n+2}=\sum_{n\ge 2}F_{n-2} x^n.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
So we have&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=x+(x+x^2)G(x)\,&amp;lt;/math&amp;gt;,&lt;br /&gt;
hence&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\frac{x}{1-x-x^2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
The value of &amp;lt;math&amp;gt;F_n&amp;lt;/math&amp;gt; is the coefficient of &amp;lt;math&amp;gt;x^n&amp;lt;/math&amp;gt; in the Taylor series for this formular, which is &amp;lt;math&amp;gt;\frac{G^{(n)}(0)}{n!}=\frac{1}{\sqrt{5}}\left(\frac{1+\sqrt{5}}{2}\right)^n-\frac{1}{\sqrt{5}}\left(\frac{1-\sqrt{5}}{2}\right)^n&amp;lt;/math&amp;gt;. Although this expansion works in principle, the detailed calculus is rather painful.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
It is easier to expand the generating function by breaking it into two geometric series.&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;\phi=\frac{1+\sqrt{5}}{2}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\hat{\phi}=\frac{1-\sqrt{5}}{2}&amp;lt;/math&amp;gt;. It holds that&lt;br /&gt;
::&amp;lt;math&amp;gt;\frac{x}{1-x-x^2}=\frac{1}{\sqrt{5}}\cdot\frac{1}{1-\phi x}-\frac{1}{\sqrt{5}}\cdot\frac{1}{1-\hat{\phi} x}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
It is easy to verify the above equation, but to deduce it, we need some (high school) calculation.&lt;br /&gt;
&lt;br /&gt;
{|border=&amp;quot;2&amp;quot; width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;3&amp;quot; rules=&amp;quot;all&amp;quot; style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|&lt;br /&gt;
:{|&lt;br /&gt;
|&lt;br /&gt;
&amp;lt;math&amp;gt;1-x-x^2&amp;lt;/math&amp;gt; has two roots &amp;lt;math&amp;gt;\frac{-1\pm\sqrt{5}}{2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Denote that &amp;lt;math&amp;gt;\phi=\frac{2}{-1+\sqrt{5}}=\frac{1+\sqrt{5}}{2}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\hat{\phi}=\frac{2}{-1-\sqrt{5}}=\frac{1-\sqrt{5}}{2}&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Then &amp;lt;math&amp;gt;(1-x-x^2)=(1-\phi x)(1-\hat{\phi}x)&amp;lt;/math&amp;gt;, so we can write &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\frac{x}{1-x-x^2}&lt;br /&gt;
&amp;amp;=\frac{x}{(1-\phi x)(1-\hat{\phi} x)}\\&lt;br /&gt;
&amp;amp;=\frac{\alpha}{(1-\phi x)}+\frac{\beta}{(1-\hat{\phi} x)},&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
where &amp;lt;math&amp;gt;\alpha&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\beta&amp;lt;/math&amp;gt; satisfying that&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{cases}&lt;br /&gt;
\alpha+\beta=0\\&lt;br /&gt;
\alpha\phi+\beta\hat{\phi}= -1.&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
Solving this we have that &amp;lt;math&amp;gt;\alpha=\frac{1}{\sqrt{5}}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\beta=-\frac{1}{\sqrt{5}}&amp;lt;/math&amp;gt;. Thus,&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\frac{x}{1-x-x^2}=\frac{1}{\sqrt{5}}\cdot\frac{1}{1-\phi x}-\frac{1}{\sqrt{5}}\cdot\frac{1}{1-\hat{\phi} x}&amp;lt;/math&amp;gt;.&lt;br /&gt;
|}&lt;br /&gt;
:&amp;lt;math&amp;gt;\square&amp;lt;/math&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Note that the expression &amp;lt;math&amp;gt;\frac{1}{1-z}&amp;lt;/math&amp;gt; has a well known geometric expansion:&lt;br /&gt;
:&amp;lt;math&amp;gt;\frac{1}{1-z}=\sum_{n\ge 0}z^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Therefore, &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; can be expanded as&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
G(x)&lt;br /&gt;
&amp;amp;=\frac{1}{\sqrt{5}}\cdot\frac{1}{1-\phi x}-\frac{1}{\sqrt{5}}\cdot\frac{1}{1-\hat{\phi} x}\\&lt;br /&gt;
&amp;amp;=\frac{1}{\sqrt{5}}\sum_{n\ge 0}(\phi x)^n-\frac{1}{\sqrt{5}}\sum_{n\ge 0}(\hat{\phi} x)^n\\&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}\frac{1}{\sqrt{5}}\left(\phi^n-\hat{\phi}^n\right)x^n.&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
So the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;th Fibonacci number is given by &lt;br /&gt;
:&amp;lt;math&amp;gt;F_n=\frac{1}{\sqrt{5}}\left(\phi^n-\hat{\phi}^n\right)=\frac{1}{\sqrt{5}}\left(\frac{1+\sqrt{5}}{2}\right)^n-\frac{1}{\sqrt{5}}\left(\frac{1-\sqrt{5}}{2}\right)^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Solving recurrences ==&lt;br /&gt;
The following steps describe a general methodology of solving recurrences by generating functions.&lt;br /&gt;
:1. Give a recursion that computes &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt;. In the case of Fibonacci sequence&lt;br /&gt;
::&amp;lt;math&amp;gt;a_n=a_{n-1}+a_{n-2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
:2. Multiply both sides of the equation by &amp;lt;math&amp;gt;x^n&amp;lt;/math&amp;gt; and sum over all &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. This gives the generating function&lt;br /&gt;
::&amp;lt;math&amp;gt;G(x)=\sum_{n\ge 0}a_nx^n=\sum_{n\ge 0}(a_{n-1}+a_{n-2})x^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
:: And manipulate the right hand side of the equation so that it becomes some other expression involving &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
::&amp;lt;math&amp;gt;G(x)=x+(x+x^2)G(x)\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
:3. Solve the resulting equation to derive an explicit formula for &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
::&amp;lt;math&amp;gt;G(x)=\frac{x}{1-x-x^2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
:4. Expand &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; into a power series and read off the coefficient of &amp;lt;math&amp;gt;x^n&amp;lt;/math&amp;gt;, which is a closed form for &amp;lt;math&amp;gt;a_n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The first step is usually established by combinatorial observations, or explicitly given by the problem. The third step is trivial.&lt;br /&gt;
&lt;br /&gt;
The second and the forth steps need some non-trivial analytic techniques.&lt;br /&gt;
&lt;br /&gt;
=== Algebraic operations on generating functions ===&lt;br /&gt;
The second step in the above methodology is somehow tricky. It involves first applying the recurrence to the coefficients of &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt;, which is easy; and then manipulating the resulting formal power series to express it in terms of &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt;, which is more difficult (because it works backwards).&lt;br /&gt;
&lt;br /&gt;
We can apply several natural algebraic operations on the formal power series.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Generating function manipulation|&lt;br /&gt;
:Let &amp;lt;math&amp;gt;G(x)=\sum_{n\ge 0}g_nx^n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;F(x)=\sum_{n\ge 0}f_nx^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
::&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
&amp;amp;\text{shift:}&lt;br /&gt;
&amp;amp;x^k G(x)&lt;br /&gt;
&amp;amp;= \sum_{n\ge k}g_{n-k}x^n, &amp;amp;\qquad (\mbox{integer }k\ge 0)\\&lt;br /&gt;
&amp;amp;\text{addition:}&lt;br /&gt;
&amp;amp; F(x)+G(x)&lt;br /&gt;
&amp;amp;= \sum_{n\ge 0} (f_n+ g_n)x^n\\&lt;br /&gt;
&amp;amp;\text{convolution:}&lt;br /&gt;
&amp;amp;F(x)G(x)&lt;br /&gt;
&amp;amp;= \sum_{n\ge 0}\sum_{k=0}^nf_kg_{n-k}x^n\\&lt;br /&gt;
&amp;amp;\text{differentiation:}&lt;br /&gt;
&amp;amp;G&#039;(x)&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}(n+1)g_{n+1}x^n&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
When manipulating generating functions, these rules are applied backwards; that is, from the right-hand-side to the left-hand-side.&lt;br /&gt;
&lt;br /&gt;
=== Expanding generating functions ===&lt;br /&gt;
The last step of solving recurrences by generating function is expanding the closed form generating function &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; to evaluate its &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-th coefficient. &lt;br /&gt;
====Taylor expansion====&lt;br /&gt;
In principle, we can always use the [http://en.wikipedia.org/wiki/Taylor_series Taylor series]&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\sum_{n\ge 0}\frac{G^{(n)}(0)}{n!}x^n&amp;lt;/math&amp;gt;,&lt;br /&gt;
where &amp;lt;math&amp;gt;G^{(n)}(0)&amp;lt;/math&amp;gt; is the value of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-th derivative of &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; evaluated at &amp;lt;math&amp;gt;x=0&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
====Geometric sequence====&lt;br /&gt;
In the example of Fibonacci numbers, we use the well known geometric series:&lt;br /&gt;
:&amp;lt;math&amp;gt;\frac{1}{1-x}=\sum_{n\ge 0}x^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
It is useful when we can express the generating function in the form of &amp;lt;math&amp;gt;G(x)=\frac{a_1}{1-b_1x}+\frac{a_2}{1-b_2x}+\cdots+\frac{a_k}{1-b_kx}&amp;lt;/math&amp;gt;. The coefficient of &amp;lt;math&amp;gt;x^n&amp;lt;/math&amp;gt; in such &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;a_1b_1^n+a_2b_2^n+\cdots+a_kb_k^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
====Binomial theorem====&lt;br /&gt;
The &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-th derivative of &amp;lt;math&amp;gt;(1+x)^\alpha&amp;lt;/math&amp;gt; for some real &amp;lt;math&amp;gt;\alpha&amp;lt;/math&amp;gt; is &lt;br /&gt;
:&amp;lt;math&amp;gt;\alpha(\alpha-1)(\alpha-2)\cdots(\alpha-n+1)(1+x)^{\alpha-n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
By Taylor series, we get a generalized version of the binomial theorem known as [http://en.wikipedia.org/wiki/Binomial_coefficient#Newton.27s_binomial_series &#039;&#039;&#039;Newton&#039;s formula&#039;&#039;&#039;]:&lt;br /&gt;
{{Theorem|Newton&#039;s formular (generalized binomial theorem)|&lt;br /&gt;
If &amp;lt;math&amp;gt;|x|&amp;lt;1&amp;lt;/math&amp;gt;, then&lt;br /&gt;
:&amp;lt;math&amp;gt;(1+x)^\alpha=\sum_{n\ge 0}{\alpha\choose n}x^{n}&amp;lt;/math&amp;gt;,&lt;br /&gt;
where &amp;lt;math&amp;gt;{\alpha\choose n}&amp;lt;/math&amp;gt; is the &#039;&#039;&#039;generalized binomial coefficient&#039;&#039;&#039; defined by &lt;br /&gt;
:&amp;lt;math&amp;gt;{\alpha\choose n}=\frac{\alpha(\alpha-1)(\alpha-2)\cdots(\alpha-n+1)}{n!}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Example: multisets ===&lt;br /&gt;
In the last lecture we gave a combinatorial proof of the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set. Now we give a generating function approach to the problem.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;S=\{x_1,x_2,\ldots,x_n\}&amp;lt;/math&amp;gt; be an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-element set. We have&lt;br /&gt;
:&amp;lt;math&amp;gt;(1+x_1+x_1^2+\cdots)(1+x_2+x_2^2+\cdots)\cdots(1+x_n+x_n^2+\cdots)=\sum_{m:S\rightarrow\mathbb{N}} \prod_{x_i\in S}x_i^{m(x_i)}&amp;lt;/math&amp;gt;,&lt;br /&gt;
where each &amp;lt;math&amp;gt;m:S\rightarrow\mathbb{N}&amp;lt;/math&amp;gt; species a possible multiset on &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; with multiplicity function &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Let all &amp;lt;math&amp;gt;x_i=x&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
(1+x+x^2+\cdots)^n&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{m:S\rightarrow\mathbb{N}}x^{m(x_1)+\cdots+m(x_n)}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{\text{multiset }M\text{ on }S}x^{|M|}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{k\ge 0}\left({n\choose k}\right)x^k.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
The last equation is due to the the definition of &amp;lt;math&amp;gt;\left({n\choose k}\right)&amp;lt;/math&amp;gt;. Our task is to evaluate &amp;lt;math&amp;gt;\left({n\choose k}\right)&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
Due to the geometric sequence and the Newton&#039;s formula&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
(1+x+x^2+\cdots)^n=(1-x)^{-n}=\sum_{k\ge 0}{-n\choose k}(-x)^k.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
So&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\left({n\choose k}\right)=(-1)^k{-n\choose k}={n+k-1\choose k}.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
The last equation is due to the definition of the generalized binomial coefficient. We use an analytic (generating function) proof to get the same result of &amp;lt;math&amp;gt;\left({n\choose k}\right)&amp;lt;/math&amp;gt; as the combinatorial proof.&lt;br /&gt;
&lt;br /&gt;
== Catalan Number ==&lt;br /&gt;
We now introduce a class of counting problems, all with the same solution, called [http://en.wikipedia.org/wiki/Catalan_number &#039;&#039;&#039;Catalan number&#039;&#039;&#039;]. &lt;br /&gt;
&lt;br /&gt;
The &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;th Catalan number is denoted as &amp;lt;math&amp;gt;C_n&amp;lt;/math&amp;gt;.&lt;br /&gt;
In Volume 2 of Stanley&#039;s &#039;&#039;Enumerative Combinatorics&#039;&#039;, a set of exercises describe 66 different interpretations of the Catalan numbers. We give a few examples, cited from Wikipedia.&lt;br /&gt;
* &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; is the number of &#039;&#039;&#039;Dyck words&#039;&#039;&#039; of length 2&#039;&#039;n&#039;&#039;. A Dyck word is a string consisting of &#039;&#039;n&#039;&#039; X&#039;s and &#039;&#039;n&#039;&#039; Y&#039;s such that no initial segment of the string has more Y&#039;s than X&#039;s (see also [http://en.wikipedia.org/wiki/Dyck_language Dyck language]). For example, the following are the Dyck words of length 6:&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;big&amp;gt; XXXYYY &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; XYXXYY &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; XYXYXY &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; XXYYXY &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; XXYXYY.&amp;lt;/big&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Re-interpreting the symbol X as an open parenthesis and Y as a close parenthesis, &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; counts the number of expressions containing &#039;&#039;n&#039;&#039; pairs of parentheses which are correctly matched:&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;big&amp;gt; ((())) &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; ()(()) &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; ()()() &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; (())() &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; (()()) &amp;lt;/big&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; is the number of different ways &#039;&#039;n&#039;&#039;&amp;amp;nbsp;+&amp;amp;nbsp;1 factors can be completely parenthesized (or the number of ways of associating &#039;&#039;n&#039;&#039; applications of a &#039;&#039;&#039;binary operator&#039;&#039;&#039;). For &#039;&#039;n&#039;&#039; = 3, for example, we have the following five different parenthesizations of four factors:&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;math&amp;gt;((ab)c)d \quad (a(bc))d \quad(ab)(cd) \quad a((bc)d) \quad a(b(cd))&amp;lt;/math&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Successive applications of a binary operator can be represented in terms of a &#039;&#039;&#039;full binary tree&#039;&#039;&#039;. (A rooted binary tree is &#039;&#039;full&#039;&#039; if every vertex has either two children or no children.) It follows that &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; is the number of full binary trees with &#039;&#039;n&#039;&#039;&amp;amp;nbsp;+&amp;amp;nbsp;1 leaves:&lt;br /&gt;
[[Image:Catalan number binary tree example.png|center]] &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; is the number of &#039;&#039;&#039;monotonic paths&#039;&#039;&#039; along the edges of a grid with &#039;&#039;n&#039;&#039; × &#039;&#039;n&#039;&#039; square cells, which do not pass above the diagonal. A monotonic path is one which starts in the lower left corner, finishes in the upper right corner, and consists entirely of edges pointing rightwards or upwards. Counting such paths is equivalent to counting Dyck words: X stands for &amp;quot;move right&amp;quot; and Y stands for &amp;quot;move up&amp;quot;. The following diagrams show the case &#039;&#039;n&#039;&#039; = 4:&lt;br /&gt;
[[Image:Catalan number 4x4 grid example.svg.png|450px|center]]&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; is the number of different ways a [http://en.wikipedia.org/wiki/Convex_polygon &#039;&#039;&#039;convex polygon&#039;&#039;&#039;] with &#039;&#039;n&#039;&#039;&amp;amp;nbsp;+&amp;amp;nbsp;2 sides can be cut into &#039;&#039;&#039;triangles&#039;&#039;&#039; by connecting vertices with straight lines. The following hexagons illustrate the case &#039;&#039;n&#039;&#039; = 4:&lt;br /&gt;
[[Image:Catalan-Hexagons-example.png|400px|center]]&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; is the number of [http://en.wikipedia.org/wiki/Stack_(data_structure) &#039;&#039;&#039;stack&#039;&#039;&#039;]-sortable permutations of {1, ..., &#039;&#039;n&#039;&#039;}. A permutation &#039;&#039;w&#039;&#039; is called &#039;&#039;&#039;stack-sortable&#039;&#039;&#039; if &#039;&#039;S&#039;&#039;(&#039;&#039;w&#039;&#039;) =&amp;amp;nbsp;(1,&amp;amp;nbsp;...,&amp;amp;nbsp;&#039;&#039;n&#039;&#039;), where &#039;&#039;S&#039;&#039;(&#039;&#039;w&#039;&#039;) is defined recursively as follows: write &#039;&#039;w&#039;&#039; =&amp;amp;nbsp;&#039;&#039;unv&#039;&#039; where &#039;&#039;n&#039;&#039; is the largest element in &#039;&#039;w&#039;&#039; and &#039;&#039;u&#039;&#039; and &#039;&#039;v&#039;&#039; are shorter sequences, and set &#039;&#039;S&#039;&#039;(&#039;&#039;w&#039;&#039;) =&amp;amp;nbsp;&#039;&#039;S&#039;&#039;(&#039;&#039;u&#039;&#039;)&#039;&#039;S&#039;&#039;(&#039;&#039;v&#039;&#039;)&#039;&#039;n&#039;&#039;, with &#039;&#039;S&#039;&#039; being the identity for one-element sequences. &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;C&#039;&#039;&amp;lt;sub&amp;gt;&#039;&#039;n&#039;&#039;&amp;lt;/sub&amp;gt; is the number of ways to tile a stairstep shape of height &#039;&#039;n&#039;&#039; with &#039;&#039;n&#039;&#039; rectangles. The following figure illustrates the case &#039;&#039;n&#039;&#039;&amp;amp;nbsp;=&amp;amp;nbsp;4:&lt;br /&gt;
[[Image:Catalan stairsteps 4.png|400px|center]]&lt;br /&gt;
&lt;br /&gt;
=== Solving the Catalan numbers ===&lt;br /&gt;
{{Theorem|Recurrence relation for Catalan numbers|&lt;br /&gt;
:&amp;lt;math&amp;gt;C_0=1&amp;lt;/math&amp;gt;, and for &amp;lt;math&amp;gt;n\ge1&amp;lt;/math&amp;gt;,&lt;br /&gt;
::&amp;lt;math&amp;gt;&lt;br /&gt;
C_n=&lt;br /&gt;
\sum_{k=0}^{n-1}C_kC_{n-1-k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;G(x)=\sum_{n\ge 0}C_nx^n&amp;lt;/math&amp;gt; be the generating function. Then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
G(x)^2&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}\sum_{k=0}^{n}C_kC_{n-k}x^n\\&lt;br /&gt;
xG(x)^2&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}\sum_{k=0}^{n}C_kC_{n-k}x^{n+1}=\sum_{n\ge 1}\sum_{k=0}^{n-1}C_kC_{n-1-k}x^n.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Due to the recurrence,&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\sum_{n\ge 0}C_nx^n=C_0+\sum_{n\ge 1}\sum_{k=0}^{n-1}C_kC_{n-1-k}x^n=1+xG(x)^2&amp;lt;/math&amp;gt;.&lt;br /&gt;
Solving &amp;lt;math&amp;gt;xG(x)^2-G(x)+1=0&amp;lt;/math&amp;gt;, we obtain&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\frac{1\pm(1-4x)^{1/2}}{2x}&amp;lt;/math&amp;gt;.&lt;br /&gt;
Only one of these functions can be the generating function for &amp;lt;math&amp;gt;C_n&amp;lt;/math&amp;gt;, and it must satisfy&lt;br /&gt;
:&amp;lt;math&amp;gt;\lim_{x\rightarrow 0}G(x)=C_0=1&amp;lt;/math&amp;gt;.&lt;br /&gt;
It is easy to check that the correct function is&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\frac{1-(1-4x)^{1/2}}{2x}&amp;lt;/math&amp;gt;.&lt;br /&gt;
Expanding &amp;lt;math&amp;gt;(1-4x)^{1/2}&amp;lt;/math&amp;gt; by Newton&#039;s formula, &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
(1-4x)^{1/2}&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{n\ge 0}{1/2\choose n}(-4x)^n\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
1+\sum_{n\ge 1}{1/2\choose n}(-4x)^n\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
1-4x\sum_{n\ge 0}{1/2\choose n+1}(-4x)^n&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Then, we have&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
G(x)&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{1-(1-4x)^{1/2}}{2x}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
2\sum_{n\ge 0}{1/2\choose n+1}(-4x)^n&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
Thus, &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
C_n&lt;br /&gt;
&amp;amp;=2{1/2\choose n+1}(-4)^n\\&lt;br /&gt;
&amp;amp;=2\cdot\left(\frac{1}{2}\cdot\frac{-1}{2}\cdot\frac{-3}{2}\cdots\frac{-(2n-1)}{2}\right)\cdot\frac{1}{(n+1)!}\cdot(-4)^n\\&lt;br /&gt;
&amp;amp;=\frac{2^n}{(n+1)!}\prod_{k=1}^n(2k-1)\\&lt;br /&gt;
&amp;amp;=\frac{2^n}{(n+1)!}\prod_{k=1}^n\frac{(2k-1)2k}{2k}\\&lt;br /&gt;
&amp;amp;=\frac{1}{n!(n+1)!}\prod_{k=1}^n (2k-1)2k\\&lt;br /&gt;
&amp;amp;=\frac{(2n)!}{n!(n+1)!}\\&lt;br /&gt;
&amp;amp;=\frac{1}{n+1}{2n\choose n}.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
So we prove the following closed form for Catalan number.&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:&amp;lt;math&amp;gt;C_n=\frac{1}{n+1}{2n\choose n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Analysis of Quicksort ==&lt;br /&gt;
Given as input a set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; numbers, we want to sort the numbers in &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; in increasing order. One of the most famous algorithm for this problem is the  [http://en.wikipedia.org/wiki/Quicksort Quicksort] algorithm.&lt;br /&gt;
{{Theorem|Quicksort algorithm|&lt;br /&gt;
&#039;&#039;&#039;Input&#039;&#039;&#039;: a set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; numbers.&lt;br /&gt;
* if &amp;lt;math&amp;gt;|S|&amp;gt;1&amp;lt;/math&amp;gt; do:&lt;br /&gt;
** pick an &amp;lt;math&amp;gt;x\in S&amp;lt;/math&amp;gt; as the &#039;&#039;pivot&#039;&#039;;&lt;br /&gt;
** partition &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;S_1=\{y\in S\mid y&amp;lt;x\}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;S_2=\{y\in S\mid y&amp;gt;x\}&amp;lt;/math&amp;gt;;&lt;br /&gt;
** recursively sort &amp;lt;math&amp;gt;S_1&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;S_2&amp;lt;/math&amp;gt;;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Usually the input set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is given as an array of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; elements in an arbitrary order. The pivot is picked from a fixed position in the arrary (e.g. the first number in the array). &lt;br /&gt;
&lt;br /&gt;
The time complexity of this sorting algorithm is measured by the &#039;&#039;&#039;number of comparisons&#039;&#039;&#039;.  &lt;br /&gt;
&lt;br /&gt;
=== The quicksort recursion ===&lt;br /&gt;
It is easy to observe that the running time of the algorithm depends only on the relative order of the elements in the input array. &lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;T_n&amp;lt;/math&amp;gt; be the average number of comparison used by the Quicksort to sort an array of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; numbers, where the average is taken over all &amp;lt;math&amp;gt;n!&amp;lt;/math&amp;gt; total orders of the elements in the array.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|The Quicksort recursion|&lt;br /&gt;
:&amp;lt;math&amp;gt;T_n=&lt;br /&gt;
\frac{1}{n}\sum_{k=1}^n\left(n-1+T_{k-1}+T_{n-k}\right)&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
:and &amp;lt;math&amp;gt;T_0=T_1=0\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
The recursion is got from averaging over the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; sub-cases that the pivot is chosen as the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-th smallest element for &amp;lt;math&amp;gt;k=1,2,\ldots,n&amp;lt;/math&amp;gt;. Partitioning the input set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;S_1&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;S_2&amp;lt;/math&amp;gt; takes exactly &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; comparisons regardless the choice of the pivot. Given that the pivot is chosen as the  &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-th smallest element, the sizes of &amp;lt;math&amp;gt;S_1&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;S_2&amp;lt;/math&amp;gt; are &amp;lt;math&amp;gt;k-1&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; respectively, thus the costs of sorting &amp;lt;math&amp;gt;S_1&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;S_2&amp;lt;/math&amp;gt; are given recursively by &amp;lt;math&amp;gt;T_{k-1}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T_{n-k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Manipulating the OGF===&lt;br /&gt;
We write the ordinary generating function (OGF) for the quicksort:&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
G(x)&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}T_nx^n.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The quicksort recursion also gives us another equation for formal power series:&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\sum_{n\ge 0}nT_nx^n&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}\left(\sum_{k=1}^n\left(n-1+T_{k-1}+T_{n-k}\right)\right)x^n\\&lt;br /&gt;
&amp;amp;=\sum_{n\ge 0}n(n-1)x^n+2\sum_{n\ge 0}\left(\sum_{k=0}^{n-1}T_{k}\right)x^n.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We express the three terms &amp;lt;math&amp;gt;\sum_{n\ge 0}n(n-1)x^n&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;2\sum_{n\ge 0}\left(\sum_{k=0}^{n-1}T_{k}\right)x^n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\sum_{n\ge 0}nT_nx^n&amp;lt;/math&amp;gt; in closed form involving &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; as follows:&lt;br /&gt;
# Evaluate the power series: &amp;lt;math&amp;gt;\sum_{n\ge 0}n(n-1)x^n=x^2\sum_{n\ge 0}n(n-1)x^{n-2}=\frac{2x^2}{(1-x)^3}&amp;lt;/math&amp;gt;.&lt;br /&gt;
# Apply the convolution rule of OGF: &amp;lt;math&amp;gt;2\sum_{n\ge 0}\left(\sum_{k=0}^{n-1}T_{k}\right)x^n=2x\sum_{n\ge 0}\left(\sum_{k=0}^{n}T_{k}\right)x^{n}=2xF(x)G(x)&amp;lt;/math&amp;gt;,&lt;br /&gt;
#:where &amp;lt;math&amp;gt;F(x)=\sum_{n\ge 0}x^n=\frac{1}{1-x}&amp;lt;/math&amp;gt;,&lt;br /&gt;
#:therefore, &amp;lt;math&amp;gt;2\sum_{n\ge 0}\left(\sum_{k=0}^{n-1}T_{k}\right)x^n=2xF(x)G(x)=\frac{2x}{1-x}G(x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
# Apply the differentiation rule of OGF: &amp;lt;math&amp;gt;\sum_{n\ge 0}nT_nx^n=x\sum_{n\ge 0}(n+1)T_{n+1}x^{n}=xG&#039;(x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
Therefore we have the following identity for the OGF for quicksort:&lt;br /&gt;
{{Theorem|Equation for the generating function|&lt;br /&gt;
:&amp;lt;math&amp;gt;xG&#039;(x)=\frac{2x^2}{(1-x)^3}+\frac{2x}{1-x}G(x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
=== Solving the equation ===&lt;br /&gt;
The above equation for the generating function &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; is a first-order linear differential equation, which has a general solution.&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\frac{c-2x}{(1-x)^2}+\frac{2}{(1-x)^2}\ln\frac{1}{1-x}&amp;lt;/math&amp;gt; for some constant &amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Taking &amp;lt;math&amp;gt;x=0&amp;lt;/math&amp;gt;, we have that &amp;lt;math&amp;gt;G(0)=c=T_0=0&amp;lt;/math&amp;gt;.&lt;br /&gt;
Therefore&lt;br /&gt;
:&amp;lt;math&amp;gt;G(x)=\frac{-2x}{(1-x)^2}+\frac{2}{(1-x)^2}\ln\frac{1}{1-x}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Expanding ===&lt;br /&gt;
Due to Taylor&#039;s expansion,&lt;br /&gt;
:&amp;lt;math&amp;gt;\frac{1}{(1-x)^2}=\sum_{n\ge 0}(n+1) x^{n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
:&amp;lt;math&amp;gt;\ln\frac{1}{1-x}=\sum_{n\ge 1}\frac{x^n}{n}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\frac{-2x}{(1-x)^2}&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
-\sum_{n\ge 0}2(n+1)x^{n+1}&lt;br /&gt;
=&lt;br /&gt;
-\sum_{n\ge 1}2nx^{n}.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And the convolution product can be calculated by&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\frac{2}{(1-x)^2}\ln\frac{1}{1-x}&lt;br /&gt;
&amp;amp;=2\sum_{n\ge 0}(n+1) x^{n}\sum_{n\ge 1}\frac{x^n}{n}\\&lt;br /&gt;
&amp;amp;=2\sum_{n\ge 1}\left(\sum_{k=1}^{n}(n-k+1)\frac{1}{k}\right)x^n.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The generating function &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt; is calculated as &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
G(x)&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{-2x}{(1-x)^2}+\frac{2}{(1-x)^2}\ln\frac{1}{1-x}\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\sum_{n\ge 1}\left(-2n+2\sum_{k=1}^{n}(n-k+1)\frac{1}{k}\right)x^{n}.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Denote by &amp;lt;math&amp;gt;[x^n]G(x)&amp;lt;/math&amp;gt; the coefficient of &amp;lt;math&amp;gt;x^n&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;G(x)&amp;lt;/math&amp;gt;. Then&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
T_n&lt;br /&gt;
&amp;amp;=[x^n]G(x)\\&lt;br /&gt;
&amp;amp;=-2n+2\sum_{k=1}^{n}(n-k+1)\frac{1}{k}\\&lt;br /&gt;
&amp;amp;=-2n+2(n+1)\sum_{k=1}^n\frac{1}{k}-2\sum_{k=1}^nk\cdot\frac{1}{k}\\&lt;br /&gt;
&amp;amp;=2(n+1)H(n)-4n,&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
where &amp;lt;math&amp;gt;H(n)&amp;lt;/math&amp;gt; is the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;th [http://en.wikipedia.org/wiki/Harmonic_number harmonic number], which satisfies that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\ln n\le H(n)=\sum_{k=1}^n\frac{1}{k}\le 1+\ln n.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Therefore, the average number of comparisons used by the quicksort to sort lists of length &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is&lt;br /&gt;
:&amp;lt;math&amp;gt;T_n=2(n+1)H(n)-4n&amp;lt;/math&amp;gt;,&lt;br /&gt;
which is lower and upper bounded as &amp;lt;math&amp;gt;2n\ln n-4n\le T_n\le 2n\ln n-(2-o(1))n&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Reference ==&lt;br /&gt;
* &#039;&#039;Graham, Knuth, and Patashnik&#039;&#039;, Concrete Mathematics: A Foundation for Computer Science, Chapter 7.&lt;br /&gt;
* &#039;&#039;van Lin and Wilson&#039;&#039;, A course in combinatorics, Chapter 14.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13500</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13500"/>
		<updated>2026-03-11T08:37:47Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
# [[组合数学 (Spring 2026)/Generating functions|Generating functions | 生成函数]]&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13496</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13496"/>
		<updated>2026-03-09T08:59:21Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]] ([http://tcs.nju.edu.cn/slides/comb2026/BasicEnumeration.pdf slides])&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13495</id>
		<title>概率论与数理统计 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E6%A6%82%E7%8E%87%E8%AE%BA%E4%B8%8E%E6%95%B0%E7%90%86%E7%BB%9F%E8%AE%A1_(Spring_2026)&amp;diff=13495"/>
		<updated>2026-03-09T08:57:32Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lectures */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;&#039;&#039;&#039;概率论与数理统计&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Probability Theory&#039;&#039;&#039; &amp;lt;br&amp;gt; &amp;amp; &#039;&#039;&#039;Mathematical Statistics&#039;&#039;&#039;&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4  = office&lt;br /&gt;
|data4   = 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = liu@nju.edu.cn  &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = office&lt;br /&gt;
|data7   = 计算机系 516&lt;br /&gt;
|header8 = Class&lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &lt;br /&gt;
|header9 =&lt;br /&gt;
|label9  = Class meeting&lt;br /&gt;
|data9   = Wednesday, 9am-12am&amp;lt;br&amp;gt;&lt;br /&gt;
仙Ⅱ-212&lt;br /&gt;
|header10=&lt;br /&gt;
|label10 = Office hour&lt;br /&gt;
|data10  = TBA &amp;lt;br&amp;gt;计算机系 804（尹一通）&amp;lt;br&amp;gt;计算机系 516（刘景铖）&lt;br /&gt;
|header11= Textbook&lt;br /&gt;
|label11 = &lt;br /&gt;
|data11  = &lt;br /&gt;
|header12=&lt;br /&gt;
|label12 = &lt;br /&gt;
|data12  = [[File:概率导论.jpeg|border|100px]]&lt;br /&gt;
|header13=&lt;br /&gt;
|label13 = &lt;br /&gt;
|data13  = &#039;&#039;&#039;概率导论&#039;&#039;&#039;（第2版·修订版）&amp;lt;br&amp;gt; Dimitri P. Bertsekas and John N. Tsitsiklis&amp;lt;br&amp;gt; 郑忠国 童行伟 译；人民邮电出版社 (2022)&lt;br /&gt;
|header14=&lt;br /&gt;
|label14 = &lt;br /&gt;
|data14  = [[File:Grimmett_probability.jpg|border|100px]]&lt;br /&gt;
|header15=&lt;br /&gt;
|label15 = &lt;br /&gt;
|data15  = &#039;&#039;&#039;Probability and Random Processes&#039;&#039;&#039; (4E) &amp;lt;br&amp;gt; Geoffrey Grimmett and David Stirzaker &amp;lt;br&amp;gt;  Oxford University Press (2020)&lt;br /&gt;
|header16=&lt;br /&gt;
|label16 = &lt;br /&gt;
|data16  = [[File:Probability_and_Computing_2ed.jpg|border|100px]]&lt;br /&gt;
|header17=&lt;br /&gt;
|label17 = &lt;br /&gt;
|data17  = &#039;&#039;&#039;Probability and Computing&#039;&#039;&#039; (2E) &amp;lt;br&amp;gt; Michael Mitzenmacher and Eli Upfal &amp;lt;br&amp;gt;   Cambridge University Press (2017)&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Probability Theory and Mathematical Statistics&#039;&#039; (概率论与数理统计) class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 鞠哲：[mailto:juzhe@smail.nju.edu.cn &amp;lt;juzhe@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
** 祝永祺：[mailto:652025330045@smail.nju.edu.cn &amp;lt;652025330045@smail.nju.edu.cn&amp;gt;]，计算机系 426&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;:&lt;br /&gt;
** 周三：9am-12am，仙Ⅱ-212&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: &lt;br /&gt;
:* TBA, 计算机系 804（尹一通）&lt;br /&gt;
:* TBA, 计算机系 516（刘景铖）&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090092561（申请加入需提供姓名、院系、学号）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
课程内容分为三大部分：&lt;br /&gt;
* &#039;&#039;&#039;经典概率论&#039;&#039;&#039;：概率空间、随机变量及其数字特征、多维与连续随机变量、极限定理等内容&lt;br /&gt;
* &#039;&#039;&#039;概率与计算&#039;&#039;&#039;：测度集中现象 (concentration of measure)、概率法 (the probabilistic method)、离散随机过程的相关专题&lt;br /&gt;
* &#039;&#039;&#039;数理统计&#039;&#039;&#039;：参数估计、假设检验、贝叶斯估计、线性回归等统计推断等概念&lt;br /&gt;
&lt;br /&gt;
对于第一和第二部分，要求清楚掌握基本概念，深刻理解关键的现象与规律以及背后的原理，并可以灵活运用所学方法求解相关问题。对于第三部分，要求熟悉数理统计的若干基本概念，以及典型的统计模型和统计推断问题。&lt;br /&gt;
&lt;br /&gt;
经过本课程的训练，力求使学生能够熟悉掌握概率的语言，并会利用概率思维来理解客观世界并对其建模，以及驾驭概率的数学工具来分析和求解专业问题。&lt;br /&gt;
&lt;br /&gt;
=== 教材与参考书 Course Materials ===&lt;br /&gt;
* &#039;&#039;&#039;[BT]&#039;&#039;&#039; 概率导论（第2版·修订版），[美]伯特瑟卡斯（Dimitri P.Bertsekas）[美]齐齐克利斯（John N.Tsitsiklis）著，郑忠国 童行伟 译，人民邮电出版社（2022）。&lt;br /&gt;
* &#039;&#039;&#039;[GS]&#039;&#039;&#039; &#039;&#039;Probability and Random Processes&#039;&#039;, by Geoffrey Grimmett and David Stirzaker; Oxford University Press; 4th edition (2020).&lt;br /&gt;
* &#039;&#039;&#039;[MU]&#039;&#039;&#039; &#039;&#039;Probability and Computing: Randomization and Probabilistic Techniques in Algorithms and Data Analysis&#039;&#039;, by Michael Mitzenmacher, Eli Upfal; Cambridge University Press; 2nd edition (2017).&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grading Policy ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。符合规则的讨论与致谢将不会影响得分。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
&lt;br /&gt;
= Lectures =&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/Intro.pdf 课程简介]&lt;br /&gt;
# [http://tcs.nju.edu.cn/slides/prob2026/ProbSpace.pdf 概率空间]&lt;br /&gt;
#* 阅读：&#039;&#039;&#039;[BT] 第1章&#039;&#039;&#039; 或 &#039;&#039;&#039;[GS] Chapter 1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)/Basic_enumeration&amp;diff=13484</id>
		<title>组合数学 (Spring 2026)/Basic enumeration</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)/Basic_enumeration&amp;diff=13484"/>
		<updated>2026-03-03T08:58:03Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;== Basic Enumeration ==  The three basic rules for enumeration are: *&amp;#039;&amp;#039;&amp;#039;The sum rule&amp;#039;&amp;#039;&amp;#039;: for any &amp;#039;&amp;#039;&amp;#039;&amp;#039;&amp;#039;disjoint&amp;#039;&amp;#039;&amp;#039;&amp;#039;&amp;#039; finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, the cardinality of the union &amp;lt;math&amp;gt;|S\cup T|=|S|+|T|&amp;lt;/math&amp;gt;.  *&amp;#039;&amp;#039;&amp;#039;The product rule&amp;#039;&amp;#039;&amp;#039;: for any finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, the cardinality of the Cartesian product &amp;lt;math&amp;gt;|S\times T|=|S|\cdot|T|&amp;lt;/math&amp;gt;. *&amp;#039;&amp;#039;&amp;#039;The bijection rule&amp;#039;&amp;#039;&amp;#039;: if there exists a bijection between finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; a...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Basic Enumeration ==&lt;br /&gt;
&lt;br /&gt;
The three basic rules for enumeration are:&lt;br /&gt;
*&#039;&#039;&#039;The sum rule&#039;&#039;&#039;: for any &#039;&#039;&#039;&#039;&#039;disjoint&#039;&#039;&#039;&#039;&#039; finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, the cardinality of the union &amp;lt;math&amp;gt;|S\cup T|=|S|+|T|&amp;lt;/math&amp;gt;. &lt;br /&gt;
*&#039;&#039;&#039;The product rule&#039;&#039;&#039;: for any finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, the cardinality of the Cartesian product &amp;lt;math&amp;gt;|S\times T|=|S|\cdot|T|&amp;lt;/math&amp;gt;.&lt;br /&gt;
*&#039;&#039;&#039;The bijection rule&#039;&#039;&#039;: if there exists a bijection between finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;|S|=|T|&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Now we apply these rules to solve some basic enumeration problems.&lt;br /&gt;
&lt;br /&gt;
=== Tuples ===&lt;br /&gt;
We count the number of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-tuples of &amp;lt;math&amp;gt;[m]&amp;lt;/math&amp;gt;. Formally, we count the number of elements of &amp;lt;math&amp;gt;[m]^n&amp;lt;/math&amp;gt;. (Remember that &amp;lt;math&amp;gt;[m]=\{0,1,2,\ldots,m-1\}&amp;lt;/math&amp;gt;.)&lt;br /&gt;
&lt;br /&gt;
It is not very hard to see that this number is &amp;lt;math&amp;gt;m^n&amp;lt;/math&amp;gt;. That is, &amp;lt;math&amp;gt;|[m]^n|=m^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
To prove this rigorously, we use &#039;&#039;&amp;quot;the product rule&amp;quot;&#039;&#039;.&lt;br /&gt;
*&#039;&#039;&#039;The product rule&#039;&#039;&#039;: for any finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, the cardinality of the Cartesian product &amp;lt;math&amp;gt;|S\times T|=|S|\cdot|T|&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To count the size of &amp;lt;math&amp;gt;[m]^n\,&amp;lt;/math&amp;gt;, we write &amp;lt;math&amp;gt;[m]^n=[m]\times[m]^{n-1}&amp;lt;/math&amp;gt;, thus &amp;lt;math&amp;gt;|[m]^n|=m\cdot|[m]^{n-1}|\,&amp;lt;/math&amp;gt;. Solving the recursion, we have that &amp;lt;math&amp;gt;|[m]^n|=m^n\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
Consider the problem of counting the number of functions mapping from &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;[m]&amp;lt;/math&amp;gt;, i.e. we count the number of functions in the form &amp;lt;math&amp;gt;f:[n]\rightarrow [m]&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We claim that this is the same as counting the number of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-tuples of &amp;lt;math&amp;gt;[m]&amp;lt;/math&amp;gt;. To see this, for any &amp;lt;math&amp;gt;f:[n]\rightarrow [m]&amp;lt;/math&amp;gt;, we define a tuple &amp;lt;math&amp;gt;v_f\in[m]^n&amp;lt;/math&amp;gt; by letting &amp;lt;math&amp;gt;v_f(i)=f(i-1)&amp;lt;/math&amp;gt; for every &amp;lt;math&amp;gt;i=1,2,\ldots,n&amp;lt;/math&amp;gt;. It is easy to verify that &amp;lt;math&amp;gt;v&amp;lt;/math&amp;gt; defines a &#039;&#039;&#039;bijection&#039;&#039;&#039; (a 1-1 correspondence) between &amp;lt;math&amp;gt;\{f:[n]\rightarrow [m]\}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;[m]^n&amp;lt;/math&amp;gt;. (Consider this as an exercise.)&lt;br /&gt;
&lt;br /&gt;
Now we summon the &#039;&#039;&amp;quot;the bijection rule&amp;quot;&#039;&#039;.&lt;br /&gt;
*&#039;&#039;&#039;The bijection rule&#039;&#039;&#039;: if there exists a bijection between finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;|S|=|T|&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Applying this rule, we have that the number of functions from &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;[m]&amp;lt;/math&amp;gt; equals the number of tuples in &amp;lt;math&amp;gt;[m]^n&amp;lt;/math&amp;gt;, which is &amp;lt;math&amp;gt;m^n&amp;lt;/math&amp;gt; as we proved previously.&lt;br /&gt;
&lt;br /&gt;
=== Subsets ===&lt;br /&gt;
We count the number of subsets of a set.&lt;br /&gt;
&lt;br /&gt;
Let&amp;lt;math&amp;gt;S=\{x_1,x_2,\ldots,x_n\}&amp;lt;/math&amp;gt; be an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-element set, or &#039;&#039;&#039;&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set&#039;&#039;&#039; for short. &lt;br /&gt;
Let &amp;lt;math&amp;gt;2^S=\{T\mid T\subset S\}&amp;lt;/math&amp;gt; denote the set of all subset of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;. &amp;lt;math&amp;gt;2^S&amp;lt;/math&amp;gt; is called the &#039;&#039;&#039;power set&#039;&#039;&#039; of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We give a combinatorial proof that &amp;lt;math&amp;gt;|2^S|=2^n&amp;lt;/math&amp;gt;. We observe that every subset &amp;lt;math&amp;gt;T\in 2^S&amp;lt;/math&amp;gt; corresponds to a unique bit-vector &amp;lt;math&amp;gt;v\in\{0,1\}^S&amp;lt;/math&amp;gt;, such that each bit &amp;lt;math&amp;gt;v_i&amp;lt;/math&amp;gt; indicates whether &amp;lt;math&amp;gt;x_i\in S&amp;lt;/math&amp;gt;. Formally, define a map &amp;lt;math&amp;gt;\phi:2^S\rightarrow\{0,1\}^n&amp;lt;/math&amp;gt; by &amp;lt;math&amp;gt;\phi(T)=(v_1,v_2,\ldots,v_n)&amp;lt;/math&amp;gt;, where&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
v_i=\begin{cases}&lt;br /&gt;
1 &amp;amp; \mbox{if }x_i\in T\\&lt;br /&gt;
0 &amp;amp; \mbox{if }x_i\not\in T.&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
The map &amp;lt;math&amp;gt;\phi&amp;lt;/math&amp;gt; is a bijection. The proof that &amp;lt;math&amp;gt;\phi&amp;lt;/math&amp;gt; is a bijection is left as an exercise.&lt;br /&gt;
&lt;br /&gt;
Since there is a bijection between &amp;lt;math&amp;gt;2^S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\{0,1\}^n&amp;lt;/math&amp;gt;, it holds that &amp;lt;math&amp;gt;|2^S|=|\{0,1\}^n|=2^n\,&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
There are two elements of the proof:&lt;br /&gt;
* Find a 1-1 correspondence between subsets of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set and &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-bit vectors.&lt;br /&gt;
: An application of this in Computer Science is that we can use bit-array as a data structure for sets: any set defined over a &#039;&#039;&#039;universe&#039;&#039;&#039; &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; can be represented by an array of &amp;lt;math&amp;gt;|U|&amp;lt;/math&amp;gt; bits.&lt;br /&gt;
* The bijection rule: if there is a 1-1 correspondence between two sets, then their cardinalities are the same.&lt;br /&gt;
&lt;br /&gt;
Many counting problems are solved by establishing a bijection between the set to be counted and some easy-to-count set. This kind of proofs are usually called (non-rigorously) &#039;&#039;&#039;combinatorial proofs&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
We give an alternative proof that &amp;lt;math&amp;gt;|2^S|=2^n&amp;lt;/math&amp;gt;. The proof needs another basic counting rule:  &#039;&#039;&amp;quot;the sum rule&amp;quot;&#039;&#039;.&lt;br /&gt;
*&#039;&#039;&#039;The sum rule&#039;&#039;&#039;: for any &#039;&#039;&#039;&#039;&#039;disjoint&#039;&#039;&#039;&#039;&#039; finite sets &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;T&amp;lt;/math&amp;gt;, the cardinality of the union &amp;lt;math&amp;gt;|S\cup T|=|S|+|T|&amp;lt;/math&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Define the function &amp;lt;math&amp;gt;f(n)=|2^{S_n}|&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;S_n=\{x_1,x_2,\ldots,x_n\}&amp;lt;/math&amp;gt; is an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set. Our goal is to compute &amp;lt;math&amp;gt;f(n)&amp;lt;/math&amp;gt;. We prove the following recursion for &amp;lt;math&amp;gt;f(n)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Lemma|&lt;br /&gt;
:&amp;lt;math&amp;gt;f(n)=2f(n-1)\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Fix an element &amp;lt;math&amp;gt;x_n&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; be the set of subsets of &amp;lt;math&amp;gt;S_n&amp;lt;/math&amp;gt; that contain &amp;lt;math&amp;gt;x_n&amp;lt;/math&amp;gt; and let &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt; be the set of subsets of &amp;lt;math&amp;gt;S_n&amp;lt;/math&amp;gt; that do not contain &amp;lt;math&amp;gt;x_n&amp;lt;/math&amp;gt;. It is obvious that &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt; are disjoint (i.e. &amp;lt;math&amp;gt;U\cap V=\emptyset&amp;lt;/math&amp;gt;) and &amp;lt;math&amp;gt;2^{S_n}=U\cup V&amp;lt;/math&amp;gt;, because any subset of &amp;lt;math&amp;gt;S_n&amp;lt;/math&amp;gt; either contains &amp;lt;math&amp;gt;x_n&amp;lt;/math&amp;gt; or does not contain &amp;lt;math&amp;gt;x_n&amp;lt;/math&amp;gt; but not both.  &lt;br /&gt;
&lt;br /&gt;
Applying the sum rule, &lt;br /&gt;
:&amp;lt;math&amp;gt;f(n)=|U\cup V|=|U|+|V|&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The next observation is that &amp;lt;math&amp;gt;|U|=|V|=f(n-1)&amp;lt;/math&amp;gt;, because &amp;lt;math&amp;gt;V&amp;lt;/math&amp;gt; is exactly the &amp;lt;math&amp;gt;2^{S_{n-1}}&amp;lt;/math&amp;gt;, and &amp;lt;math&amp;gt;U&amp;lt;/math&amp;gt; is the set resulting from adding &amp;lt;math&amp;gt;x_n&amp;lt;/math&amp;gt; to every member of &amp;lt;math&amp;gt;2^{S_{n-1}}&amp;lt;/math&amp;gt;. Therefore, &lt;br /&gt;
:&amp;lt;math&amp;gt;f(n)=|U|+|V|=f(n-1)+f(n-1)=2f(n-1)\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
The elementary case &amp;lt;math&amp;gt;f(0)=1&amp;lt;/math&amp;gt;, because &amp;lt;math&amp;gt;\emptyset&amp;lt;/math&amp;gt; has only one subset &amp;lt;math&amp;gt;\emptyset&amp;lt;/math&amp;gt;. Solving the recursion, we have that &amp;lt;math&amp;gt;|2^S|=f(n)=2^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Subsets of fixed size ===&lt;br /&gt;
We then count the number of subsets of fixed size of a set. Again, let &amp;lt;math&amp;gt;S=\{x_1,x_2,\ldots,x_n\}&amp;lt;/math&amp;gt; be an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set. We define &amp;lt;math&amp;gt;{S\choose k}&amp;lt;/math&amp;gt; to be the set of all &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-elements subsets (or &#039;&#039;&#039;&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subsets&#039;&#039;&#039;) of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;. Formally, &amp;lt;math&amp;gt;{S\choose k}=\{T\subseteq S\mid |T|=k\}&amp;lt;/math&amp;gt;. The set &amp;lt;math&amp;gt;{S\choose k}&amp;lt;/math&amp;gt; is sometimes called the &#039;&#039;&#039;&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-uniform&#039;&#039;&#039; of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We denote that &amp;lt;math&amp;gt;{n\choose k}=\left|{S\choose k}\right|&amp;lt;/math&amp;gt;. The notation &amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt; is read &amp;quot;&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; choose &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:&amp;lt;math&amp;gt;{n\choose k}=\frac{n(n-1)\cdots(n-k+1)}{k(k-1)\cdots 1}=\frac{n!}{k!(n-k)!}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
The number of &#039;&#039;&#039;ordered&#039;&#039;&#039; &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subsets of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set is &amp;lt;math&amp;gt;n(n-1)\cdots(n-k+1)&amp;lt;/math&amp;gt;. Every &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subset has &amp;lt;math&amp;gt;k!=k(k-1)\cdots1&amp;lt;/math&amp;gt; ways to order it.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
;Some notations&lt;br /&gt;
* &amp;lt;math&amp;gt;n!&amp;lt;/math&amp;gt;, read &amp;quot;&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; factorial&amp;quot;, is defined as that &amp;lt;math&amp;gt;n!=n(n-1)(n-2)\cdots 1&amp;lt;/math&amp;gt;, with the convention that &amp;lt;math&amp;gt;0!=1&amp;lt;/math&amp;gt;.&lt;br /&gt;
* &amp;lt;math&amp;gt;n(n-1)\cdots(n-k+1)=\frac{n!}{(n-k)!}&amp;lt;/math&amp;gt; is usually denoted as &amp;lt;math&amp;gt;(n)_k\,&amp;lt;/math&amp;gt;, read &amp;quot;&amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; lower factorial &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== Binomial coefficient ===&lt;br /&gt;
The quantity &amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt; is called a &#039;&#039;&#039;binomial coefficient&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
# &amp;lt;math&amp;gt;{n\choose k}={n\choose n-k}&amp;lt;/math&amp;gt;;&lt;br /&gt;
# &amp;lt;math&amp;gt;\sum_{k=0}^n {n\choose k}=2^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
1. We give two proofs for the first equation:&lt;br /&gt;
:(1) (numerical proof)&lt;br /&gt;
::&amp;lt;math&amp;gt;{n\choose k}=\frac{n!}{k!(n-k)!}={n\choose n-k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
:(2) (combinatorial proof)&lt;br /&gt;
::Choosing &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; elements from an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set is equivalent to choosing the &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; elements to leave out. Formally, every &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subset &amp;lt;math&amp;gt;T\in{S\choose k}&amp;lt;/math&amp;gt; is uniquely specified by its complement &amp;lt;math&amp;gt;S\setminus T\in {S\choose n-k}&amp;lt;/math&amp;gt;, and the same holds for &amp;lt;math&amp;gt;(n-k)&amp;lt;/math&amp;gt;-subsets, thus we have a bijection between &amp;lt;math&amp;gt;{S\choose k}&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;{S\choose n-k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
2. The second equation can also be proved in different ways, but the combinatorial proof is much easier. For an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-element set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;, it is obvious that we can enumerate all subsets of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; by enumerating &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subsets for every possible size &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;, i.e. it holds that&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
2^S=\bigcup_{k=0}^n{S\choose k}.&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
For different &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;{S\choose k}&amp;lt;/math&amp;gt; are obviously disjoint. By the sum rule,&lt;br /&gt;
:&amp;lt;math&amp;gt;2^n=|2^S|=\left|\bigcup_{k=0}^n{S\choose k}\right|=\sum_{k=0}^n\left|{S\choose k}\right|=\sum_{k=0}^n {n\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt; is called binomial coefficient for a reason. The following celebrated &#039;&#039;&#039;Binomial Theorem&#039;&#039;&#039; states that if a power of a binomial is expanded, the coefficients in the resulting polynomial are the binomial coefficients.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem (Binomial theorem)|&lt;br /&gt;
:&amp;lt;math&amp;gt;(1+x)^n=\sum_{k=0}^n{n\choose k}x^k&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Write &amp;lt;math&amp;gt;(1+x)^n&amp;lt;/math&amp;gt; as the product of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; factors&lt;br /&gt;
:&amp;lt;math&amp;gt;(1+x)(1+x)\cdots (1+x)&amp;lt;/math&amp;gt;.&lt;br /&gt;
The term &amp;lt;math&amp;gt;x^k&amp;lt;/math&amp;gt; is obtained by choosing &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; from &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; factors and 1 from the rest &amp;lt;math&amp;gt;(n-k)&amp;lt;/math&amp;gt; factors. There are &amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt; ways of choosing these &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; factors, so the coefficient of &amp;lt;math&amp;gt;x^k&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The following proposition has an easy proof due to the binomial theorem.&lt;br /&gt;
{{Theorem| Proposition|&lt;br /&gt;
:For &amp;lt;math&amp;gt;n&amp;gt;0&amp;lt;/math&amp;gt;, the numbers of subsets of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set of even and of odd cardinality are equal.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Set &amp;lt;math&amp;gt;x=-1&amp;lt;/math&amp;gt; in the binomial theorem.&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
0=(1-1)^n=\sum_{k=0}^n{n\choose k}(-1)^k=\sum_{\overset{0\le k\le n}{k \text{ even}}}{n\choose k}-\sum_{\overset{0\le k\le n}{k \text{ odd}}}{n\choose k},&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
therefore&lt;br /&gt;
:&amp;lt;math&amp;gt;\sum_{\overset{0\le k\le n}{k \text{ even}}}{n\choose k}=\sum_{\overset{0\le k\le n}{k \text{ odd}}}{n\choose k}.&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
For counting problems, what we care about are &#039;&#039;numbers&#039;&#039;. In the binomial theorem, a formal &#039;&#039;variable&#039;&#039; &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; is introduced. It looks having nothing to do with our problem, but turns out to be very useful. This idea of introducing a formal variable is the basic idea of some advanced counting techniques, which will be discussed in future classes.&lt;br /&gt;
&lt;br /&gt;
=== Compositions of an integer ===&lt;br /&gt;
A &#039;&#039;&#039;composition&#039;&#039;&#039; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is an expression of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; as an &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;ordered&#039;&#039;&amp;lt;/font&amp;gt; sum of &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;positive&#039;&#039;&amp;lt;/font&amp;gt; integers. A &#039;&#039;&#039;&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition&#039;&#039;&#039; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is a composition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; with exactly &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; positive summands. &lt;br /&gt;
&lt;br /&gt;
Formally, a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-tuple &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_k)\in\{1,2,\ldots,n\}^k&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;a_1+a_2+\cdots+a_k=n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Suppose we have &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; identical balls in a line. A &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition partitions these &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; balls into &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; &#039;&#039;nonempty&#039;&#039; sets, illustrated as follows.&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{array}{c|cc|c|c|ccc|cc}&lt;br /&gt;
\bigcirc \,&amp;amp;\, \bigcirc \,&amp;amp; \bigcirc \,&amp;amp;\, \bigcirc \,&amp;amp;\, \bigcirc \,&amp;amp;\, \bigcirc &amp;amp;\, \bigcirc &amp;amp;\, \bigcirc \,&amp;amp;\, \bigcirc \,&amp;amp; \bigcirc&lt;br /&gt;
\end{array}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
So the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; equals the number of ways we put &amp;lt;math&amp;gt;k-1&amp;lt;/math&amp;gt; bars &amp;quot;&amp;lt;math&amp;gt;|&amp;lt;/math&amp;gt;&amp;quot; into &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; slots &amp;quot;&amp;lt;math&amp;gt;\sqcup&amp;lt;/math&amp;gt;&amp;quot;, where each slot has at most one bar (because all the summands &amp;lt;math&amp;gt;a_i&amp;gt;0&amp;lt;/math&amp;gt;):&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\bigcirc \sqcup \bigcirc \sqcup \bigcirc \sqcup \bigcirc \sqcup \bigcirc \sqcup \bigcirc \sqcup \bigcirc \sqcup \bigcirc \sqcup \bigcirc \sqcup \bigcirc&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
which is equal to the number of ways of choosing &amp;lt;math&amp;gt;k-1&amp;lt;/math&amp;gt; slots out of &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; slots, which is &amp;lt;math&amp;gt;{n-1\choose k-1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
This graphic argument can be expressed as a formal proof. We construct a bijection between the set of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;{\{1,2,\ldots,n-1\}\choose k-1}&amp;lt;/math&amp;gt; as follows. &lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;\phi&amp;lt;/math&amp;gt; be a mapping that given a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_k)&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\phi((a_1,a_2,\ldots,a_k))&lt;br /&gt;
&amp;amp;=\{a_1,\,\,a_1+a_2,\,\,a_1+a_2+a_3,\,\,\ldots,\,\,a_1+a_2+\cdots+a_{k-1}\}\\&lt;br /&gt;
&amp;amp;=\left\{\sum_{i=1}^ja_i\,\,\bigg|\,\, 1\le j&amp;lt;k\right\}.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&amp;lt;math&amp;gt;\phi&amp;lt;/math&amp;gt; maps every &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition to a &amp;lt;math&amp;gt;(k-1)&amp;lt;/math&amp;gt;-subset of &amp;lt;math&amp;gt;\{1,2,\ldots,n-1\}&amp;lt;/math&amp;gt;. It is easy to verify that &amp;lt;math&amp;gt;\phi&amp;lt;/math&amp;gt; is a bijection, thus the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;{n-1\choose k-1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
----&lt;br /&gt;
The number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is equal to the number of solutions to &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k=n&amp;lt;/math&amp;gt; in &#039;&#039;positive&#039;&#039; integers. This suggests us to relax the constraint and count the number of solutions to &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k=n&amp;lt;/math&amp;gt; in &#039;&#039;nonnegative&#039;&#039; integers. We call such a solution a &#039;&#039;&#039;weak &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition&#039;&#039;&#039; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Formally, a weak &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is a tuple &amp;lt;math&amp;gt;(x_1,x_2,\ldots,x_k)\in[n+1]^k&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k=n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Given a weak &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition &amp;lt;math&amp;gt;(x_1,x_2,\ldots,x_k)&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, if we set &amp;lt;math&amp;gt;y_i=x_i+1&amp;lt;/math&amp;gt; for every &amp;lt;math&amp;gt;1\le i\le k&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;y_i&amp;gt;0&amp;lt;/math&amp;gt; and &lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
y_1+y_2+\cdots +y_k&lt;br /&gt;
&amp;amp;=(x_1+1)+(x_2+1)+\cdots+(x_k+1)&amp;amp;=n+k,&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
i.e., &amp;lt;math&amp;gt;(y_1,y_2,\ldots,y_k)&amp;lt;/math&amp;gt; is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition of &amp;lt;math&amp;gt;n+k&amp;lt;/math&amp;gt;. It is easy to see that it defines a bijection between weak &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n+k&amp;lt;/math&amp;gt;. Therefore, the number of weak &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;{n+k-1\choose k-1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
----&lt;br /&gt;
We now count the number of solutions to &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k\le n&amp;lt;/math&amp;gt; in nonnegative integers. &lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;x_{k+1}=n-(x_1+x_2+\cdots+x_k)&amp;lt;/math&amp;gt;. Then &amp;lt;math&amp;gt;x_{k+1}\ge 0&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;x_1+x_2+\ldots+x_k+x_{k+1}=n&amp;lt;/math&amp;gt;. &lt;br /&gt;
The problem is transformed to that counting the number of solutions to the above equation in nonnegative integers. The answer is &amp;lt;math&amp;gt;{n+k\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Multisets ===&lt;br /&gt;
A &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subset of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is sometimes called a &#039;&#039;&#039;&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-combination of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; without repetitions&#039;&#039;&#039;. This suggests the problem of counting the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-combinations of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; &#039;&#039;&#039;&#039;&#039;with repetitions&#039;&#039;&#039;&#039;&#039;; that is, we choose &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; elements of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;, disregarding order and allowing repeated elements. &lt;br /&gt;
&lt;br /&gt;
;Example&lt;br /&gt;
:&amp;lt;math&amp;gt;S=\{1,2,3,4\}&amp;lt;/math&amp;gt;. All &amp;lt;math&amp;gt;3&amp;lt;/math&amp;gt;-combination without repetitions are &lt;br /&gt;
::&amp;lt;math&amp;gt;\{1,2,3\},\{1,2,4\},\{1,3,4\},\{2,3,4\}\,&amp;lt;/math&amp;gt;. &lt;br /&gt;
:Allowing repetitions, we also include the following 3-combinations:&lt;br /&gt;
::&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
&amp;amp;\{1,1,1\},\{1,1,2\},\{1,1,3\},\{1,1,4\},\{1,2,2\},\{1,3,3\},\{1,4,4\},\\&lt;br /&gt;
&amp;amp;\{2,2,2\},\{2,2,3\},\{2,2,4\},\{2,3,3\},\{2,4,4\},\\&lt;br /&gt;
&amp;amp;\{3,3,3\},\{3,3,4\},\{3,4,4\}\\&lt;br /&gt;
&amp;amp;\{4,4,4\}&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Combinations with repetitions can be formally defined as &#039;&#039;&#039;multisets&#039;&#039;&#039;. A multiset is a set with repeated elements. Formally, a multiset &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; on a set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is a function &amp;lt;math&amp;gt;m:S\rightarrow \mathbb{N}&amp;lt;/math&amp;gt;. For any element &amp;lt;math&amp;gt;x\in S&amp;lt;/math&amp;gt;, the integer &amp;lt;math&amp;gt;m(x)\ge 0&amp;lt;/math&amp;gt; is the number of repetitions of &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt;, called the &#039;&#039;&#039;multiplicity&#039;&#039;&#039; of &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt;. The sum of multiplicities &amp;lt;math&amp;gt;\sum_{x\in S}m(x)&amp;lt;/math&amp;gt; is called the &#039;&#039;&#039;cardinality&#039;&#039;&#039; of &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; and is denoted as &amp;lt;math&amp;gt;|M|&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
A &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multiset on a set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is a multiset &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; on &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;|M|=k&amp;lt;/math&amp;gt;. It is obvious that a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-combination of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; with repetition is simply a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multiset on &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The set of all &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is denoted &amp;lt;math&amp;gt;\left({S\choose k}\right)&amp;lt;/math&amp;gt;. Assuming that &amp;lt;math&amp;gt;n=|S|&amp;lt;/math&amp;gt;, denote &amp;lt;math&amp;gt;\left({n\choose k}\right)=\left|\left({S\choose k}\right)\right|&amp;lt;/math&amp;gt;, which is the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-combinations of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set with repetitions.&lt;br /&gt;
&lt;br /&gt;
Believe it or not: we have already evaluated the number  &amp;lt;math&amp;gt;\left({n\choose k}\right)&amp;lt;/math&amp;gt;. If &amp;lt;math&amp;gt;S=\{x_1,x_2,\ldots,x_n\}&amp;lt;/math&amp;gt;, let &amp;lt;math&amp;gt;z_i=m(x_i)&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;\left({n\choose k}\right)&amp;lt;/math&amp;gt; is the number of solutions to &amp;lt;math&amp;gt;z_1+z_2+\cdots+z_n=k&amp;lt;/math&amp;gt; in nonnegative integers, which is the number of weak &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;, which we have seen is &amp;lt;math&amp;gt;{n+k-1\choose n-1}={n+k-1\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
There is a direct combinatorial proof that &amp;lt;math&amp;gt;\left({n\choose k}\right)={n+k-1\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Given a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multiset &amp;lt;math&amp;gt;0\le a_0\le a_1\le\cdots\le a_{k-1}\le n-1&amp;lt;/math&amp;gt; on &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt;, then defining &amp;lt;math&amp;gt;b_i=a_i+i&amp;lt;/math&amp;gt;, we see that &amp;lt;math&amp;gt;\{b_0,b_1,\ldots,b_{k-1}\}&amp;lt;/math&amp;gt; is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subset of &amp;lt;math&amp;gt;[n+k-1]&amp;lt;/math&amp;gt;. Conversely, given a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-subset &amp;lt;math&amp;gt;0\le b_0\le b_1\le\cdots\le b_{k-1}\le n+k-2&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;[n+k-1]&amp;lt;/math&amp;gt;, then defining &amp;lt;math&amp;gt;a_i=b_i-i&amp;lt;/math&amp;gt;, we have that &amp;lt;math&amp;gt;\{a_0,a_1,\ldots,a_{k-1}\}&amp;lt;/math&amp;gt; is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multiset on &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt;. Therefore, we have a bijection between &amp;lt;math&amp;gt;\left({[n]\choose k}\right)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;{[n+k-1]\choose k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Multinomial coefficients ===&lt;br /&gt;
The binomial coefficient &amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt; may be interpreted as follows. Each element of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set is placed into two groups, with &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; elements in Group 1 and &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; elements in Group 2. The binomial coefficient &amp;lt;math&amp;gt;{n\choose k}&amp;lt;/math&amp;gt; counts the number of such placements.&lt;br /&gt;
&lt;br /&gt;
This suggests a generalization allowing more than two groups. Let &amp;lt;math&amp;gt;(a_1,a_2,\ldots,a_m)&amp;lt;/math&amp;gt; be a tuple of nonnegative integers summing to &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. Let &amp;lt;math&amp;gt;{n\choose a_1,a_2,\ldots,a_m}&amp;lt;/math&amp;gt; denote the number of ways of assigning each element of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set to one of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; groups &amp;lt;math&amp;gt;G_1,G_2,\ldots,G_m&amp;lt;/math&amp;gt; so that exactly &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; elements are assigned to &amp;lt;math&amp;gt;G_i&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The binomial coefficient is just the case when there are two groups, and &amp;lt;math&amp;gt;{n\choose k}={n\choose k,n-k}&amp;lt;/math&amp;gt;. The number &amp;lt;math&amp;gt;{n\choose a_1,a_2,\ldots,a_m}&amp;lt;/math&amp;gt; is called a &#039;&#039;&#039;multinomial coefficient&#039;&#039;&#039;. We can think of it as that &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; labeled balls are assigned to &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; labeled bins, and &amp;lt;math&amp;gt;{n\choose a_1,a_2,\ldots,a_m}&amp;lt;/math&amp;gt; is the number of assignments such that the &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;-th bin has &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; balls in it.&lt;br /&gt;
&lt;br /&gt;
The multinomial coefficient can also be interpreted as the number of &#039;&#039;permutations of multisets&#039;&#039;. A permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; can be defined in two equivalent ways:&lt;br /&gt;
* a bijection &amp;lt;math&amp;gt;\pi:S\rightarrow S&amp;lt;/math&amp;gt;;&lt;br /&gt;
* a tuple &amp;lt;math&amp;gt;\pi=(x_1,x_2,\ldots,x_n)\in S^n&amp;lt;/math&amp;gt; such that all &amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt; are distinct.&lt;br /&gt;
There are &amp;lt;math&amp;gt;n!&amp;lt;/math&amp;gt; permutations of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
A &#039;&#039;&#039;permutation of a multiset&#039;&#039;&#039; &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; is a tuple &amp;lt;math&amp;gt;\pi=(x_1,x_2,\ldots,x_n)&amp;lt;/math&amp;gt; such that every &amp;lt;math&amp;gt;x_i\in M&amp;lt;/math&amp;gt; appears in &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; for exactly &amp;lt;math&amp;gt;m(x_i)&amp;lt;/math&amp;gt; times, where &amp;lt;math&amp;gt;m(x_i)&amp;lt;/math&amp;gt; is the multiplicity of &amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
;Example&lt;br /&gt;
:We want to enumerate all the ways of reordering the word &amp;quot;multinomial&amp;quot;. Note that in this word, the letter &amp;quot;m&amp;quot;, &amp;quot;l&amp;quot; and &amp;quot;i&amp;quot; each appears twice. So the problem is to enumerate the permutations of the multiset &amp;lt;math&amp;gt;\{\text{a, i, i, l, l, m, m, n, o, t, u}\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; be a multiset of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; distinct elements &amp;lt;math&amp;gt;x_1,x_2,\ldots,x_m&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt; has multiplicity &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt;. A permutation &amp;lt;math&amp;gt;\pi&amp;lt;/math&amp;gt; of multiset &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; assigns &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; indices &amp;lt;math&amp;gt;1,2,\ldots,n&amp;lt;/math&amp;gt; to &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; groups, where each group corresponds to a distinct element &amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt;, such that &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; is assigned to group &amp;lt;math&amp;gt;j&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;\pi_i=x_j&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Therefore,&lt;br /&gt;
&amp;lt;math&amp;gt;{n\choose a_1,a_2,\ldots,a_m}&amp;lt;/math&amp;gt; is also the number of permutations of a multiset &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;|M|=n&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; has &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; distinct elements whose multiplicities are given by &amp;lt;math&amp;gt;a_1,a_2,\ldots,a_m&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:&amp;lt;math&amp;gt;{n\choose a_1,a_2,\ldots,a_m}=\frac{n!}{a_1!a_2!\cdots a_m!}.&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
There are &amp;lt;math&amp;gt;n!&amp;lt;/math&amp;gt; permutations of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; objects. Assume that these &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; objects are the elements of an multiset &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; distinct elements with &amp;lt;math&amp;gt;|M|=n&amp;lt;/math&amp;gt; and multiplicities &amp;lt;math&amp;gt;a_1,a_2,\ldots,a_m&amp;lt;/math&amp;gt;. Since &amp;lt;math&amp;gt;a_i!&amp;lt;/math&amp;gt; permutations of object &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; do not change the permutation of the multiset &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt;, every &amp;lt;math&amp;gt;a_1!a_2!\cdots a_m!&amp;lt;/math&amp;gt; permutations of these &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; objects correspond to the same permutation of the multiset &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt;. Thus, the number of permutations of &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;\frac{n!}{a_1!a_2!\cdots a_m!}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
We also have the Multinomial Theorem.&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:&amp;lt;math&amp;gt;{n\choose a_1,a_2,\ldots,a_m}&amp;lt;/math&amp;gt; is the coefficient of &amp;lt;math&amp;gt;x_1^{a_1}x_2^{a_2}\cdots x_m^{a_m}&amp;lt;/math&amp;gt; in &amp;lt;math&amp;gt;(x_1+x_2+\cdots +x_m)^n&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Write&lt;br /&gt;
:&amp;lt;math&amp;gt;(x_1+x_2+\cdots +x_m)^n=(x_1+x_2+\cdots +x_m)\cdots (x_1+x_2+\cdots +x_m)&amp;lt;/math&amp;gt;. &lt;br /&gt;
Each of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; factors corresponds to a distinct ball, and &amp;lt;math&amp;gt;x_1,x_2,\ldots,x_m&amp;lt;/math&amp;gt; correspond to &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; groups. The coefficient of &amp;lt;math&amp;gt;x_1^{a_1}x_2^{a_2}\cdots x_m^{a_m}&amp;lt;/math&amp;gt; equals the number of ways to put &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;distinct balls to &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; distinct groups so that group &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt; receives &amp;lt;math&amp;gt;a_i&amp;lt;/math&amp;gt; balls, which is exactly our first definition of &amp;lt;math&amp;gt;{n\choose a_1,a_2,\ldots,a_m}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Partitions of a set ===&lt;br /&gt;
A &#039;&#039;&#039;partition&#039;&#039;&#039; of finite set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; is a collection &amp;lt;math&amp;gt;P=\{S_1,S_2,\ldots,S_k\}&amp;lt;/math&amp;gt; of subsets of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; such that:&lt;br /&gt;
* &amp;lt;math&amp;gt;S_i\neq\emptyset&amp;lt;/math&amp;gt; for every &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;;&lt;br /&gt;
* &amp;lt;math&amp;gt;S_i\cap S_j=\emptyset&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;i\neq j&amp;lt;/math&amp;gt; (also called that blocks are pairwise &#039;&#039;&#039;disjoint&#039;&#039;&#039;);&lt;br /&gt;
* &amp;lt;math&amp;gt;S_1\cup S_2\cup\cdots\cup S_k=S&amp;lt;/math&amp;gt;.&lt;br /&gt;
Each &amp;lt;math&amp;gt;S_i&amp;lt;/math&amp;gt; is called a &#039;&#039;&#039;block&#039;&#039;&#039; of partition &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt;. We call &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; a &#039;&#039;&#039;&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition&#039;&#039;&#039; of &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;|P|=k&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Define &amp;lt;math&amp;gt;\left\{{n \atop k}\right\}&amp;lt;/math&amp;gt; to be the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partitions of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set. Note that since a partition &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is a set, the order of blocks &amp;lt;math&amp;gt;S_1,S_2,\ldots,S_k&amp;lt;/math&amp;gt; is disregarded when counting &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partitions.&lt;br /&gt;
&lt;br /&gt;
The number &amp;lt;math&amp;gt;\left\{{n \atop k}\right\}&amp;lt;/math&amp;gt; is called a &#039;&#039;&#039;Stirling number of the second kind&#039;&#039;&#039;.&lt;br /&gt;
:{|border=&amp;quot;1&amp;quot;&lt;br /&gt;
|&lt;br /&gt;
;Stirling number&lt;br /&gt;
: [http://en.wikipedia.org/wiki/Stirling_number Stirling numbers] are named after James Stirling.There are two kinds of Stirling numbers. [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_first_kind Stirling number of the first kind] is related to the number of permutations with fixed number of disjoint cycles. And [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind] counts the number of ways of partitioning a set into fixed number of disjoint blocks. Both numbers arise from important combinatorial problems and have various applications in combinatorics and other branches of Mathematics.&lt;br /&gt;
|}&lt;br /&gt;
Unlike previous identities, it is very difficult to give a determinant for &amp;lt;math&amp;gt;\left\{{n \atop k}\right\}&amp;lt;/math&amp;gt;. But we have the following recurrence:&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:&amp;lt;math&amp;gt;\left\{{n \atop k}\right\}=k\left\{{n-1 \atop k}\right\}+\left\{{n-1 \atop k-1}\right\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
To partition &amp;lt;math&amp;gt;\{1,2,\ldots,n\}&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; blocks,  &lt;br /&gt;
* we can partition &amp;lt;math&amp;gt;\{1,2,\ldots,{n-1}\}&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; blocks and place &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; into one of the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; blocks, which gives us &amp;lt;math&amp;gt;k\left\{{n-1 \atop k}\right\}&amp;lt;/math&amp;gt; ways to do so; &lt;br /&gt;
* or we can partition &amp;lt;math&amp;gt;\{1,2,\ldots,{n-1}\}&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;k-1&amp;lt;/math&amp;gt; blocks and let &amp;lt;math&amp;gt;\{n\}&amp;lt;/math&amp;gt; be a block by itself, which gives us &amp;lt;math&amp;gt;\left\{{n-1 \atop k-1}\right\}&amp;lt;/math&amp;gt; ways to do so.&lt;br /&gt;
&lt;br /&gt;
The partitions constructed by these two methods are different, since by the first method, &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is always in a block of cardinality &amp;lt;math&amp;gt;&amp;gt;1&amp;lt;/math&amp;gt;, and by the second method, &amp;lt;math&amp;gt;\{n\}&amp;lt;/math&amp;gt; is always a block. So the cases are disjoint. And any &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set must be constructible by one of the two methods, thus by the sum rule,&lt;br /&gt;
:&amp;lt;math&amp;gt;\,\left\{{n \atop k}\right\}=k\left\{{n-1 \atop k}\right\}+\left\{{n-1 \atop k-1}\right\}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;B_n=\sum_{k=1}^n \left\{{n \atop k}\right\}&amp;lt;/math&amp;gt;, which gives the total number of partitions of an &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-set. &amp;lt;math&amp;gt;B(n)&amp;lt;/math&amp;gt; is called the &#039;&#039;&#039;Bell number&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
=== Partitions of a number ===&lt;br /&gt;
We count the ways of partitioning &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; &#039;&#039;identical&#039;&#039; objects into &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; &#039;&#039;unordered&#039;&#039; groups. This is equivalent to counting the ways partitioning a number &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; unordered parts.&lt;br /&gt;
&lt;br /&gt;
A &#039;&#039;&#039;&amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition&#039;&#039;&#039; of a number &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is a multiset &amp;lt;math&amp;gt;\{x_1,x_2,\ldots,x_k\}&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;x_i\ge 1&amp;lt;/math&amp;gt; for every element &amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k=n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We define &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt; as the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For example, number 7 has the following partitions:&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot;&amp;gt;&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
&amp;amp;\{7\}&lt;br /&gt;
&amp;amp; p_1(7)=1\\&lt;br /&gt;
&amp;amp;\{1,6\},\{2,5\},\{3,4\}&lt;br /&gt;
&amp;amp; p_2(7)=3\\&lt;br /&gt;
&amp;amp;\{1,1,5\}, \{1,2,4\}, \{1,3,3\}, \{2,2,3\} &lt;br /&gt;
&amp;amp; p_3(7)=4\\&lt;br /&gt;
&amp;amp;\{1,1,1,4\},\{1,1,2,3\}, \{1,2,2,2\}&lt;br /&gt;
&amp;amp; p_4(7)=3\\&lt;br /&gt;
&amp;amp;\{1,1,1,1,3\},\{1,1,1,2,2\}&lt;br /&gt;
&amp;amp; p_5(7)=2\\&lt;br /&gt;
&amp;amp;\{1,1,1,1,1,2\}&lt;br /&gt;
&amp;amp; p_6(7)=1\\&lt;br /&gt;
&amp;amp;\{1,1,1,1,1,1,1\}&lt;br /&gt;
&amp;amp; p_7(7)=1&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Equivalently, we can also define that A &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of a number &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-tuple &amp;lt;math&amp;gt;(x_1,x_2,\ldots,x_k)&amp;lt;/math&amp;gt; with:&lt;br /&gt;
* &amp;lt;math&amp;gt;x_1\ge x_2\ge\cdots\ge x_k\ge 1&amp;lt;/math&amp;gt;;&lt;br /&gt;
* &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k=n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt; the number of integral solutions to the above system.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;p(n)=\sum_{k=1}^n p_k(n)&amp;lt;/math&amp;gt; be the total number of partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. The function &amp;lt;math&amp;gt;p(n)&amp;lt;/math&amp;gt; is called the &#039;&#039;&#039;partition number&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
We now try to determine &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;. Unfortunately, &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt; does not have a nice closed form formula. We now give a recurrence for &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
:&amp;lt;math&amp;gt;p_k(n)=p_{k-1}(n-1)+p_k(n-k)\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Suppose that &amp;lt;math&amp;gt;(x_1,\ldots,x_k)&amp;lt;/math&amp;gt; is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. Note that it must hold that&lt;br /&gt;
:&amp;lt;math&amp;gt;x_1\ge x_2\ge \cdots \ge x_k\ge 1&amp;lt;/math&amp;gt;.&lt;br /&gt;
There are two cases: &amp;lt;math&amp;gt;x_k=1&amp;lt;/math&amp;gt; or &amp;lt;math&amp;gt;x_k&amp;gt;1&amp;lt;/math&amp;gt;.&lt;br /&gt;
;Case 1.&lt;br /&gt;
:If &amp;lt;math&amp;gt;x_k=1&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;(x_1,\cdots,x_{k-1})&amp;lt;/math&amp;gt; is a distinct &amp;lt;math&amp;gt;(k-1)&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt;. And every &amp;lt;math&amp;gt;(k-1)&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n-1&amp;lt;/math&amp;gt; can be obtained in this way. Thus the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; in this case is &amp;lt;math&amp;gt;p_{k-1}(n-1)&amp;lt;/math&amp;gt;. &lt;br /&gt;
;Case 2.&lt;br /&gt;
:If &amp;lt;math&amp;gt;x_k&amp;gt;1&amp;lt;/math&amp;gt;, then &amp;lt;math&amp;gt;(x_1-1,\cdots,x_{k}-1)&amp;lt;/math&amp;gt; is a distinct &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt;. And every &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; can be obtained in this way. Thus the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; in this case is &amp;lt;math&amp;gt;p_{k}(n-k)&amp;lt;/math&amp;gt;. &lt;br /&gt;
In conclusion, the number of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is &amp;lt;math&amp;gt;p_{k-1}(n-1)+p_k(n-k)&amp;lt;/math&amp;gt;, i.e.&lt;br /&gt;
:&amp;lt;math&amp;gt;p_k(n)=p_{k-1}(n-1)+p_k(n-k)\,&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Use the above recurrence, we can compute the &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;  for some decent &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; by computer simulation.&lt;br /&gt;
&lt;br /&gt;
If we are not restricted ourselves to the precise estimation of &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;, the next theorem gives an asymptotic estimation of &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;. Note that it only holds for &#039;&#039;&#039;constant&#039;&#039;&#039; &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;, i.e. &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; does not depend on &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
For any fixed &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;,&lt;br /&gt;
:&amp;lt;math&amp;gt;p_k(n)\sim\frac{n^{k-1}}{k!(k-1)!}&amp;lt;/math&amp;gt;,&lt;br /&gt;
as &amp;lt;math&amp;gt;n\rightarrow \infty&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
Suppose that &amp;lt;math&amp;gt;(x_1,\ldots,x_k)&amp;lt;/math&amp;gt; is a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. Then &amp;lt;math&amp;gt;x_1+x_2+\cdots+x_k=n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;x_1\ge x_2\ge \cdots \ge x_k\ge 1&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;math&amp;gt;k!&amp;lt;/math&amp;gt; permutations of &amp;lt;math&amp;gt;(x_1,\ldots,x_k)&amp;lt;/math&amp;gt; yield at most &amp;lt;math&amp;gt;k!&amp;lt;/math&amp;gt; many &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions (the &#039;&#039;ordered&#039;&#039; sum of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; positive integers). There are &amp;lt;math&amp;gt;{n-1\choose k-1}&amp;lt;/math&amp;gt; many &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-compositions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, every one of which can be yielded in this way by permuting a partition. Thus,&lt;br /&gt;
:&amp;lt;math&amp;gt;k!p_k(n)\ge{n-1\choose k-1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;y_i=x_i+k-i&amp;lt;/math&amp;gt;. That is, &amp;lt;math&amp;gt;y_k=x_k, y_{k-1}=x_{k-1}+1, y_{k-2}=x_{k-2}+2,\ldots, y_{1}=x_{1}+k-1&amp;lt;/math&amp;gt;. Then, it holds that&lt;br /&gt;
* &amp;lt;math&amp;gt;y_1&amp;gt;y_2&amp;gt;\cdots&amp;gt;y_k\ge 1&amp;lt;/math&amp;gt;; and &lt;br /&gt;
* &amp;lt;math&amp;gt;y_1+y_2+\cdots+y_k=n+\frac{k(k-1)}{2}&amp;lt;/math&amp;gt;.&lt;br /&gt;
Each permutation of &amp;lt;math&amp;gt;(y_1,y_2,\ldots,y_k)&amp;lt;/math&amp;gt; yields a &#039;&#039;&#039;distinct&#039;&#039;&#039; &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-composition of &amp;lt;math&amp;gt;n+\frac{k(k-1)}{2}&amp;lt;/math&amp;gt;, because all &amp;lt;math&amp;gt;y_i&amp;lt;/math&amp;gt; are distinct.&lt;br /&gt;
Thus, &lt;br /&gt;
:&amp;lt;math&amp;gt;k!p_k(n)\le {n+\frac{k(k-1)}{2}-1\choose k-1}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Combining the two inequalities, we have&lt;br /&gt;
:&amp;lt;math&amp;gt;\frac{{n-1\choose k-1}}{k!}\le p_k(n)\le \frac{{n+\frac{k(k-1)}{2}-1\choose k-1}}{k!}&amp;lt;/math&amp;gt;.&lt;br /&gt;
The theorem follows.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Ferrers diagram ===&lt;br /&gt;
A partition of a number &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; can be represented as a diagram of dots (or squares), called a &#039;&#039;&#039;Ferrers diagram&#039;&#039;&#039; (the square version of Ferrers diagram is also called a &#039;&#039;&#039;Young diagram&#039;&#039;&#039;, named after a structured called Young tableaux). &lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;(x_1,x_2,\ldots,x_k)&amp;lt;/math&amp;gt; with that &amp;lt;math&amp;gt;x_1\ge x_2\ge \cdots x_k\ge 1&amp;lt;/math&amp;gt; be a partition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. Its Ferrers diagram consists of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; rows, where the &amp;lt;math&amp;gt;i&amp;lt;/math&amp;gt;-th row contains &amp;lt;math&amp;gt;x_i&amp;lt;/math&amp;gt; dots (or squares).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot;&amp;gt;&lt;br /&gt;
{|border=&amp;quot;0&amp;quot;&lt;br /&gt;
|&lt;br /&gt;
{|border=&amp;quot;0&amp;quot;&lt;br /&gt;
|[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess xot45.svg|22px]]||[[File:Chess xot45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess xot45.svg|22px]]&lt;br /&gt;
|}&lt;br /&gt;
|&lt;br /&gt;
[[File:Chess t45.svg|120px]]&lt;br /&gt;
|align=center|&lt;br /&gt;
{|border=&amp;quot;2&amp;quot;  cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;3&amp;quot; rules=&amp;quot;all&amp;quot; style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]&lt;br /&gt;
|}&lt;br /&gt;
|-&lt;br /&gt;
|align=center|Ferrers diagram (&#039;&#039;dot version&#039;&#039;) of (5,4,2,1)||&lt;br /&gt;
|align=center|Ferrers diagram (&#039;&#039;square version&#039;&#039;) of (5,4,2,1)&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Conjugate partition&lt;br /&gt;
The partition we get by reading the Ferrers diagram by column instead of rows is called the &#039;&#039;&#039;conjugate&#039;&#039;&#039; of the original partition.&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot;&amp;gt;&lt;br /&gt;
{|border=&amp;quot;0&amp;quot;&lt;br /&gt;
|align=center|&lt;br /&gt;
{|border=&amp;quot;2&amp;quot;  cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;3&amp;quot; rules=&amp;quot;all&amp;quot; style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]&lt;br /&gt;
|}&lt;br /&gt;
|&lt;br /&gt;
[[File:Chess t45.svg|120px]]&lt;br /&gt;
|align=center|&lt;br /&gt;
{|border=&amp;quot;2&amp;quot;  cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;3&amp;quot; rules=&amp;quot;all&amp;quot; style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]||[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]&lt;br /&gt;
|-&lt;br /&gt;
|[[File:Chess t45.svg|22px]]&lt;br /&gt;
|}&lt;br /&gt;
|-&lt;br /&gt;
|align=center|&amp;lt;math&amp;gt;(6,4,4,2,1)&amp;lt;/math&amp;gt;||&lt;br /&gt;
|align=center|conjugate: &amp;lt;math&amp;gt;(5,4,3,3,1,1)&amp;lt;/math&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Clearly, &lt;br /&gt;
* different partitions cannot have the same conjugate, and &lt;br /&gt;
* every partition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; is the conjugate of some partition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;,&lt;br /&gt;
so the conjugation mapping is a permutation on the set of partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. This fact is very useful in proving theorems for partitions numbers.&lt;br /&gt;
&lt;br /&gt;
Some theorems of partitions can be easily proved by representing partitions in Ferrers diagrams.&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
# The number of partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; which have largest summand &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;, is &amp;lt;math&amp;gt;p_k(n)&amp;lt;/math&amp;gt;. &lt;br /&gt;
# The number of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; parts equals the number of partitions of &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; into at most &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; parts. Formally,&lt;br /&gt;
::&amp;lt;math&amp;gt;p_k(n)=\sum_{j=1}^k p_j(n-k)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
# For every &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition, the conjugate partition has largest part &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;. And vice versa.&lt;br /&gt;
# For a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, remove the leftmost cell of every row of the Ferrers diagram. Totally &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; cells are removed and the remaining diagram is a partition of &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; into at most &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; parts. And for a partition of &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; into at most &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; parts, add a cell to each of the &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; rows (including the empty ones). This will give us a &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-partition of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;. It is easy to see the above mappings are 1-1 correspondences. Thus, the number of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; parts equals the number of partitions of &amp;lt;math&amp;gt;n-k&amp;lt;/math&amp;gt; into at most &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; parts.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== The twelvfold way ==&lt;br /&gt;
We now introduce a general framework for counting problems, called the [http://en.wikipedia.org/wiki/Twelvefold_way twelvefold way]. This framework is introduced by the great mathematician and also a great teacher, [http://en.wikipedia.org/wiki/Gian-Carlo_Rota Gian-Carlo Rota].&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; be finite sets with &amp;lt;math&amp;gt;|N|=n&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;|M|=m&amp;lt;/math&amp;gt;. We count the number of functions &amp;lt;math&amp;gt;f:N\rightarrow M&amp;lt;/math&amp;gt; subject to different restrictions. There are three restrictions regarding the mapping &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; itself:&lt;br /&gt;
# &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; is an &#039;&#039;&#039;arbitrary&#039;&#039;&#039; function;&lt;br /&gt;
# &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; is an &#039;&#039;&#039;injection&#039;&#039;&#039; (one-to-one);&lt;br /&gt;
# &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; is a &#039;&#039;&#039;surjection&#039;&#039;&#039; (onto).&lt;br /&gt;
&lt;br /&gt;
The elements of &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; can be regarded as &#039;&#039;&#039;distinguishable&#039;&#039;&#039; or &#039;&#039;&#039;indistinguishable&#039;&#039;&#039;. Think of &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt; as a set of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; balls and &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; as a set of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; bins. A function &amp;lt;math&amp;gt;f:N\rightarrow M&amp;lt;/math&amp;gt; is an assignment of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; balls into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; bins. The balls are &#039;&#039;distinguishable&#039;&#039; if each ball has a distinct label on it, and the balls are &#039;&#039;indistinguishable&#039;&#039; if they are identical. The same also applies to the bins. &lt;br /&gt;
&lt;br /&gt;
Three restrictions on the functions, with two restrictions on each of the domain and the range, together give us twelve counting problems, called the &#039;&#039;&#039;Twelvefold Way&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
The following table gives the solutions to the counting problems.&lt;br /&gt;
{|border=&amp;quot;2&amp;quot;  cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;10&amp;quot; rules=&amp;quot;all&amp;quot;  style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!bgcolor=&amp;quot;#A7C1F2&amp;quot; | Elements of &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt;&lt;br /&gt;
!bgcolor=&amp;quot;#A7C1F2&amp;quot; | Elements of &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; &lt;br /&gt;
!bgcolor=&amp;quot;#A7C1F2&amp;quot; | Any &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; &lt;br /&gt;
!bgcolor=&amp;quot;#A7C1F2&amp;quot; | Injective (1-1) &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; &lt;br /&gt;
!bgcolor=&amp;quot;#A7C1F2&amp;quot; | Surjective (on-to) &amp;lt;math&amp;gt;f&amp;lt;/math&amp;gt; &lt;br /&gt;
|-&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;distinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;distinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;m^n\,&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;\left(m\right)_n&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;m!\left\{{n\atop m}\right\}\,&amp;lt;/math&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;indistinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;distinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;\left({m\choose n}\right)&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;|&amp;lt;math&amp;gt;{m\choose n}&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;|&amp;lt;math&amp;gt;{n-1\choose m-1}&amp;lt;/math&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;distinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;indistinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;\sum_{k=1}^m \left\{{n\atop k}\right\}&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;\begin{cases}1 &amp;amp; \mbox{if }n\le m\\ 0&amp;amp; \mbox{if }n&amp;gt;m\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;\left\{{n\atop m}\right\}\,&amp;lt;/math&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;indistinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &#039;&#039;indistinguishable&#039;&#039;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;\sum_{k=1}^m p_k(n)&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;\begin{cases}1 &amp;amp; \mbox{if }n\le m\\ 0&amp;amp; \mbox{if }n&amp;gt;m\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;p_m(n)\,&amp;lt;/math&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
In the Volume 4A of Don Knuth&#039;s [http://www-cs-faculty.stanford.edu/~uno/taocp.html TAOCP], the twelvefold way is presented as the problems of counting the ways of assigning &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; balls into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; bins. The domain &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt; corresponds to a set of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; balls, the range &amp;lt;math&amp;gt;M&amp;lt;/math&amp;gt; corresponds to a set of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; bins, and each function corresponds to an assignment of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; balls into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; bins. Balls (or bins) are distinguishable if they are &#039;&#039;distinct&#039;&#039; and are indistinguishable if they are &#039;&#039;identical&#039;&#039;. An injective function corresponds to an assignment with &#039;&#039;at most&#039;&#039; one ball in each bin, and a surjective function corresponds to an assignment with &#039;&#039;at least&#039;&#039; one ball(s) in each bin.&lt;br /&gt;
&lt;br /&gt;
{|border=&amp;quot;2&amp;quot;  cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;10&amp;quot; rules=&amp;quot;all&amp;quot;  style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | balls per bin&lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | unrestricted &lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | ≤ 1&lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | ≥ 1&lt;br /&gt;
|-&lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct balls, &amp;lt;br&amp;gt;&amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; distinct bins&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-tuples &amp;lt;br&amp;gt;of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; things&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-permutations &amp;lt;br&amp;gt;of &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; things&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| partition of &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; &amp;lt;br&amp;gt; into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; ordered parts&lt;br /&gt;
|-&lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; identical balls, &amp;lt;br&amp;gt;&amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; distinct bins&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-combinations of &amp;lt;math&amp;gt;[m]&amp;lt;/math&amp;gt; &amp;lt;br&amp;gt;with repetitions&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;-combinations of &amp;lt;math&amp;gt;[m]&amp;lt;/math&amp;gt; &amp;lt;br&amp;gt; without repetitions&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt;-compositions &amp;lt;br&amp;gt;of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; distinct balls, &amp;lt;br&amp;gt;&amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; identical bins&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| partitions of &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; &amp;lt;br&amp;gt;into &amp;lt;math&amp;gt;\le m&amp;lt;/math&amp;gt; parts&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; pigeons &amp;lt;br&amp;gt;into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; holes&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| partitions of &amp;lt;math&amp;gt;[n]&amp;lt;/math&amp;gt; &amp;lt;br&amp;gt;into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; parts&lt;br /&gt;
|-&lt;br /&gt;
!align=&amp;quot;center&amp;quot; bgcolor=&amp;quot;#A7C1F2&amp;quot; | &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; identical balls, &amp;lt;br&amp;gt;&amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; identical bins&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; &amp;lt;br&amp;gt;into &amp;lt;math&amp;gt;\le m&amp;lt;/math&amp;gt; parts&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; pigeons &amp;lt;br&amp;gt;into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; holes&lt;br /&gt;
|align=&amp;quot;center&amp;quot;| partitions of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; &amp;lt;br&amp;gt;into &amp;lt;math&amp;gt;m&amp;lt;/math&amp;gt; parts&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Reference ==&lt;br /&gt;
* &#039;&#039;Stanley,&#039;&#039; Enumerative Combinatorics, Volume 1, Chapter 1.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13483</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13483"/>
		<updated>2026-03-03T08:57:28Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[组合数学 (Spring 2026)/Basic enumeration|Basic enumeration | 基本计数]]&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13482</id>
		<title>组合数学 (Spring 2026)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E7%BB%84%E5%90%88%E6%95%B0%E5%AD%A6_(Spring_2026)&amp;diff=13482"/>
		<updated>2026-03-03T08:56:46Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;{{Infobox |name         = Infobox |bodystyle    =  |title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt; Combinatorics&amp;lt;/font&amp;gt; |titlestyle   =   |image        =  |imagestyle   =  |caption      =  |captionstyle =  |headerstyle  = background:#ccf; |labelstyle   = background:#ddf; |datastyle    =   |header1 =Instructor |label1  =  |data1   =  |header2 =  |label2  =  |data2   = 尹一通 |header3 =  |label3  = Email |data3   = yinyt@nju.edu.cn   |header4 = |label4= office |data4=...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;组合数学  &amp;lt;br&amp;gt;&lt;br /&gt;
Combinatorics&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 尹一通&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn  &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = Wednesday, 2pm-4pm &amp;lt;br&amp;gt; 逸B-313&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = Tuesday, 2-3pm &amp;lt;br&amp;gt;计算机系 804&lt;br /&gt;
|header9 = Textbook&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = [[File:LW-combinatorics.jpeg|border|100px]]&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = van Lint and Wilson. &amp;lt;br&amp;gt; &#039;&#039;A course in Combinatorics, 2nd ed.&#039;&#039;, &amp;lt;br&amp;gt; Cambridge Univ Press, 2001.&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = [[File:Jukna_book.jpg|border|100px]]&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = &lt;br /&gt;
|data13   = Jukna. &#039;&#039;Extremal Combinatorics: &amp;lt;br&amp;gt; With Applications in Computer Science,&amp;lt;br&amp;gt;2nd ed.&#039;&#039;, Springer, 2011.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Combinatorics&#039;&#039; class of Spring 2026. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 尹一通 ([http://tcs.nju.edu.cn/yinyt/ homepage])&lt;br /&gt;
:*&#039;&#039;&#039;email&#039;&#039;&#039;: yinyt@nju.edu.cn&lt;br /&gt;
:*&#039;&#039;&#039;office&#039;&#039;&#039;: 计算机系 804 &lt;br /&gt;
* &#039;&#039;&#039;Teaching assistant&#039;&#039;&#039;:&lt;br /&gt;
** 丁天行&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: Wednesday, 2pm-4pm, 逸A-313.&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: TBA&lt;br /&gt;
:* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 1090691552 (加入时需报姓名、专业、学号)&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 离散数学（Discrete Mathematics）&lt;br /&gt;
* 线性代数（Linear Algebra）&lt;br /&gt;
* 概率论（Probability Theory）&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[组合数学 (Spring 2025)/Course materials|&amp;lt;font size=3&amp;gt;教材和参考书清单&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩 (≥ 60%) 和期末考试成绩 (≤ 40%) 综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
* TBA&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# &lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
* [http://math.mit.edu/~fox/MAT307.html Combinatorics course] by Jacob Fox&lt;br /&gt;
* [https://yufeizhao.com/pm/ Probabilistic Methods in Combinatorics] and [https://yufeizhao.com/gtacbook/ Graph Theory and Additive Combinatorics] by Yufei Zhao&lt;br /&gt;
* [https://www.math.uvic.ca/~noelj/combinatoricsLectures.html Combinatorics Lecture Videos online]&lt;br /&gt;
* [https://www.math.ucla.edu/~pak/lectures/Math-Videos/comb-videos.htm Collection of Combinatorics Videos]&lt;br /&gt;
&lt;br /&gt;
= Concepts =&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_coefficient Binomial coefficient]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Twelvefold_way The twelvefold way]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Composition_(number_theory) Composition of a number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multiset#Formal_definition Multiset]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Combination#Number_of_combinations_with_repetition Combinations with repetition], [http://en.wikipedia.org/wiki/Multiset#Counting_multisets &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-multisets on a set]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Multinomial_theorem#Multinomial_coefficients Multinomial coefficients]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind Stirling number of the second kind]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Partition_(number_theory) Partition of a number]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Young_tableau Young tableau]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Fibonacci_number Fibonacci number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Catalan_number Catalan number]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Generating_function Generating function] and [http://en.wikipedia.org/wiki/Formal_power_series formal power series]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Binomial_series Newton&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Inclusion-exclusion_principle The principle of inclusion-exclusion] (and more generally the [http://en.wikipedia.org/wiki/Sieve_theory sieve method])&lt;br /&gt;
* [http://en.wikipedia.org/wiki/M%C3%B6bius_inversion_formula Möbius inversion formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Derangement Derangement], and [http://en.wikipedia.org/wiki/M%C3%A9nage_problem Problème des ménages]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ryser%27s_formula#Ryser_formula Ryser&#039;s formula]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Euler_totient Euler totient function]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Burnside%27s_lemma Burnside&#039;s lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action Group action]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Group_action#Orbits_and_stabilizers Orbits]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem Pólya enumeration theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Permutation_group Permutation group]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Cycle_index Cycle index]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Cayley_formula Cayley&#039;s formula]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Prüfer_sequence Prüfer code for trees]&lt;br /&gt;
** [http://en.wikipedia.org/wiki/Kirchhoff%27s_matrix_tree_theorem Kirchhoff&#039;s matrix-tree theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Double_counting_(proof_technique) Double counting] and the [http://en.wikipedia.org/wiki/Handshaking_lemma handshaking lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Sperner&#039;s_lemma Sperner&#039;s lemma] and [http://en.wikipedia.org/wiki/Brouwer_fixed_point_theorem Brouwer fixed point theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Pigeonhole_principle Pigeonhole principle]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Dirichlet&#039;s_approximation_theorem Dirichlet&#039;s approximation theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Probabilistic_method The Probabilistic Method]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Lov%C3%A1sz_local_lemma Lovász local lemma]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93R%C3%A9nyi_model Erdős–Rényi model for random graphs]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Extremal_graph_theory Extremal graph theory]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Turan_theorem Turán&#039;s theorem], [http://en.wikipedia.org/wiki/Tur%C3%A1n_graph Turán graph]&lt;br /&gt;
* Two analytic inequalities: &lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Cauchy%E2%80%93Schwarz_inequality Cauchy–Schwarz inequality]&lt;br /&gt;
:* the [http://en.wikipedia.org/wiki/Inequality_of_arithmetic_and_geometric_means inequality of arithmetic and geometric means]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Stone_theorem Erdős–Stone theorem] (fundamental theorem of extremal graph theory)&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sunflower_(mathematics) Sunflower lemma and conjecture]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Ko%E2%80%93Rado_theorem Erdős–Ko–Rado theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sperner%27s_theorem Sperner&#039;s theorem]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Sperner_family Sperner system] or &#039;&#039;&#039;antichain&#039;&#039;&#039;&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Sauer%E2%80%93Shelah_lemma Sauer–Shelah lemma]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Vapnik%E2%80%93Chervonenkis_dimension Vapnik–Chervonenkis dimension]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Kruskal%E2%80%93Katona_theorem Kruskal–Katona theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Ramsey_theory Ramsey theory]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Ramsey&#039;s_theorem Ramsey&#039;s theorem]&lt;br /&gt;
:*[http://en.wikipedia.org/wiki/Happy_Ending_problem Happy Ending problem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem Van der Waerden&#039;s theorem]&lt;br /&gt;
:*[https://en.wikipedia.org/wiki/Hales%E2%80%93Jewett_theorem Hales–Jewett theorem]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Hall%27s_marriage_theorem Hall&#039;s theorem ] (the marriage theorem)&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Doubly_stochastic_matrix Birkhoff–Von Neumann theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/K%C3%B6nig&#039;s_theorem_(graph_theory) König-Egerváry theorem]&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Dilworth&#039;s_theorem Dilworth&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Erd%C5%91s%E2%80%93Szekeres_theorem Erdős–Szekeres theorem]&lt;br /&gt;
* The  [http://en.wikipedia.org/wiki/Max-flow_min-cut_theorem Max-Flow Min-Cut Theorem]&lt;br /&gt;
:* [https://en.wikipedia.org/wiki/Menger%27s_theorem Menger&#039;s theorem]&lt;br /&gt;
:* [http://en.wikipedia.org/wiki/Maximum_flow_problem Maximum flow]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Linear_programming Linear programming]&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Dual_linear_program Duality] &lt;br /&gt;
** [https://en.wikipedia.org/wiki/Unimodular_matrix Unimodularity]&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Matroid Matroid]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=Main_Page&amp;diff=13481</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Main_Page&amp;diff=13481"/>
		<updated>2026-03-03T07:47:24Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Home Pages for Courses and Seminars */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a course/seminar wiki run by the [http://tcs.nju.edu.cn theory group] in the Department of Computer Science and Technology at Nanjing University.&lt;br /&gt;
&lt;br /&gt;
== Home Pages for Courses and Seminars==&lt;br /&gt;
;Current semester&lt;br /&gt;
* [[高级算法 (Spring 2026)|高级算法 Advanced Algorithms (Spring 2026, Suzhou)]]&lt;br /&gt;
&lt;br /&gt;
* [[组合数学 (Spring 2026)|组合数学 Combinatorics (Spring 2026)]]&lt;br /&gt;
&lt;br /&gt;
* [[计算复杂性 (Spring 2026)|计算复杂性 Computational Complexity (Spring 2026)]]&lt;br /&gt;
&lt;br /&gt;
* [[计算方法 Numerical method (Spring 2026)|计算方法 Numerical method (Spring 2026)]]&lt;br /&gt;
&lt;br /&gt;
* [[概率论与数理统计 (Spring 2026)|概率论与数理统计 Probability Theory (Spring 2026)]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
;Past courses&lt;br /&gt;
&lt;br /&gt;
* Advanced Algorithms: [[高级算法 (Fall 2025)|Fall 2025]], [[高级算法 (Spring 2025)|Spring 2025(Suzhou)]], [[高级算法 (Fall 2024)|Fall 2024]], [[高级算法 (Fall 2023)|Fall 2023]], [[高级算法 (Fall 2022)|Fall 2022]], [[高级算法 (Fall 2021)|Fall 2021]], [[高级算法 (Fall 2020)|Fall 2020]], [[高级算法 (Fall 2019)|Fall 2019]], [[高级算法 (Fall 2018)|Fall 2018]], [[高级算法 (Fall 2017)|Fall 2017]], [[随机算法 \ 高级算法 (Fall 2016)|Fall 2016]].&lt;br /&gt;
&lt;br /&gt;
*Algorithm Design and Analysis: [https://tcs.nju.edu.cn/shili/courses/2024spring-algo/ Spring 2024]&lt;br /&gt;
&lt;br /&gt;
* Combinatorics: [[组合数学 (Spring 2025)|Spring 2025]], [[组合数学 (Spring 2024)|Spring 2024]], [[组合数学 (Spring 2023)|Spring 2023]], [[组合数学 (Fall 2019)|Fall 2019]], [[组合数学 (Fall 2017)|Fall 2017]], [[组合数学 (Fall 2016)|Fall 2016]], [[组合数学 (Fall 2015)|Fall 2015]], [[组合数学 (Spring 2014)|Spring 2014]], [[组合数学 (Spring 2013)|Spring 2013]], [[组合数学 (Fall 2011)|Fall 2011]], [[Combinatorics (Fall 2010)|Fall 2010]].&lt;br /&gt;
&lt;br /&gt;
* Computational Complexity: [[计算复杂性 (Spring 2025)|Spring 2025]], [[计算复杂性 (Spring 2024)|Spring 2024]], [[计算复杂性 (Spring 2023)|Spring 2023]], [[计算复杂性 (Fall 2019)|Fall 2019]], [[计算复杂性 (Fall 2018)|Fall 2018]].&lt;br /&gt;
&lt;br /&gt;
* Foundations of Data Science: [[数据科学基础 (Fall 2025)|Fall 2025]], [[数据科学基础 (Fall 2024)|Fall 2024]]&lt;br /&gt;
&lt;br /&gt;
* Numerical Method: [[计算方法 Numerical method (Spring 2025)|Spring 2025]], [[计算方法 Numerical method (Spring 2024)|Spring 2024]], [[计算方法 Numerical method (Spring 2023)|Spring 2023]], [https://liuexp.github.io/numerical.html Spring 2022].&lt;br /&gt;
&lt;br /&gt;
* Probability Theory: [[概率论与数理统计 (Spring 2025)|Spring 2025]], [[概率论与数理统计 (Spring 2024)|Spring 2024]], [[概率论与数理统计 (Spring 2023)|Spring 2023]].&lt;br /&gt;
&lt;br /&gt;
* Quantum Computation: [[量子计算 (Spring 2022)|Spring 2022]], [[量子计算 (Spring 2021)|Spring 2021]], [[量子计算 (Fall 2019)|Fall 2019]].&lt;br /&gt;
&lt;br /&gt;
* Randomized Algorithms:  [[随机算法 (Fall 2015)|Fall 2015]], [[随机算法 (Spring 2014)|Spring 2014]], [[随机算法 (Spring 2013)|Spring 2013]], [[随机算法 (Fall 2011)|Fall 2011]], [[Randomized Algorithms (Spring 2010)|Spring 2010]].&lt;br /&gt;
&lt;br /&gt;
;Past seminars, workshops and summer schools&lt;br /&gt;
*计算理论之美暑期学校: [[计算理论之美 (Summer 2025)|2025]], [[计算理论之美 (Summer 2024)|2024]], [[计算理论之美 (Summer 2023)|2023]], [[计算理论之美 (Summer 2021)|2021]]&lt;br /&gt;
*[[Theory Seminar|理论计算机科学讨论班]]&lt;br /&gt;
*[[Study Group|理论计算机科学学习小组]]&lt;br /&gt;
*[[TCSPhD2020| 理论计算机科学优秀博士生论坛2020]]&lt;br /&gt;
*[[Quantum|量子算法与物理实现研讨会]]&lt;br /&gt;
*Theory Day: [[Theory@Suzhou 2025 | 2025 (Suzhou)]],  [[Theory@Nanjing 2019|2019]], [[Theory@Nanjing 2018|2018]], [[Theory@Nanjing 2017|2017]]&lt;br /&gt;
*[[\Delta Seminar on Logic, Philosophy, and Computer Science|Δ Seminar on Logic, Philosophy, and Computer Science]]&lt;br /&gt;
*[[近似算法讨论班 (Fall 2011)|近似算法 Approximation Algorithms, Fall 2011.]]&lt;br /&gt;
&lt;br /&gt;
; 其它链接&lt;br /&gt;
* [[General Circulation(Fall 2025)|大气环流 General Circulation of the Atmosphere, Fall 2025]]&lt;br /&gt;
* [[General Circulation(Fall 2024)|大气环流 General Circulation of the Atmosphere, Fall 2024]]&lt;br /&gt;
&lt;br /&gt;
* [[概率论 (Summer 2014)| 概率与计算 (上海交大 Summer 2014)]]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=Main_Page&amp;diff=13480</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Main_Page&amp;diff=13480"/>
		<updated>2026-03-03T07:45:59Z</updated>

		<summary type="html">&lt;p&gt;Etone: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a course/seminar wiki run by the [http://tcs.nju.edu.cn theory group] in the Department of Computer Science and Technology at Nanjing University.&lt;br /&gt;
&lt;br /&gt;
== Home Pages for Courses and Seminars==&lt;br /&gt;
;Current semester&lt;br /&gt;
* [[高级算法 (Spring 2026)|高级算法 Advanced Algorithms (Spring 2026, Suzhou)]]&lt;br /&gt;
&lt;br /&gt;
* [[概率论与数理统计 (Spring 2026)|概率论与数理统计 Probability Theory (Spring 2026)]]&lt;br /&gt;
&lt;br /&gt;
* [[计算复杂性 (Spring 2026)|计算复杂性 Computational Complexity (Spring 2026)]]&lt;br /&gt;
&lt;br /&gt;
* [[计算方法 Numerical method (Spring 2026)|计算方法 Numerical method (Spring 2026)]]&lt;br /&gt;
&lt;br /&gt;
;Past courses&lt;br /&gt;
&lt;br /&gt;
* Advanced Algorithms: [[高级算法 (Fall 2025)|Fall 2025]], [[高级算法 (Spring 2025)|Spring 2025(Suzhou)]], [[高级算法 (Fall 2024)|Fall 2024]], [[高级算法 (Fall 2023)|Fall 2023]], [[高级算法 (Fall 2022)|Fall 2022]], [[高级算法 (Fall 2021)|Fall 2021]], [[高级算法 (Fall 2020)|Fall 2020]], [[高级算法 (Fall 2019)|Fall 2019]], [[高级算法 (Fall 2018)|Fall 2018]], [[高级算法 (Fall 2017)|Fall 2017]], [[随机算法 \ 高级算法 (Fall 2016)|Fall 2016]].&lt;br /&gt;
&lt;br /&gt;
*Algorithm Design and Analysis: [https://tcs.nju.edu.cn/shili/courses/2024spring-algo/ Spring 2024]&lt;br /&gt;
&lt;br /&gt;
* Combinatorics: [[组合数学 (Spring 2025)|Spring 2025]], [[组合数学 (Spring 2024)|Spring 2024]], [[组合数学 (Spring 2023)|Spring 2023]], [[组合数学 (Fall 2019)|Fall 2019]], [[组合数学 (Fall 2017)|Fall 2017]], [[组合数学 (Fall 2016)|Fall 2016]], [[组合数学 (Fall 2015)|Fall 2015]], [[组合数学 (Spring 2014)|Spring 2014]], [[组合数学 (Spring 2013)|Spring 2013]], [[组合数学 (Fall 2011)|Fall 2011]], [[Combinatorics (Fall 2010)|Fall 2010]].&lt;br /&gt;
&lt;br /&gt;
* Computational Complexity: [[计算复杂性 (Spring 2025)|Spring 2025]], [[计算复杂性 (Spring 2024)|Spring 2024]], [[计算复杂性 (Spring 2023)|Spring 2023]], [[计算复杂性 (Fall 2019)|Fall 2019]], [[计算复杂性 (Fall 2018)|Fall 2018]].&lt;br /&gt;
&lt;br /&gt;
* Foundations of Data Science: [[数据科学基础 (Fall 2025)|Fall 2025]], [[数据科学基础 (Fall 2024)|Fall 2024]]&lt;br /&gt;
&lt;br /&gt;
* Numerical Method: [[计算方法 Numerical method (Spring 2025)|Spring 2025]], [[计算方法 Numerical method (Spring 2024)|Spring 2024]], [[计算方法 Numerical method (Spring 2023)|Spring 2023]], [https://liuexp.github.io/numerical.html Spring 2022].&lt;br /&gt;
&lt;br /&gt;
* Probability Theory: [[概率论与数理统计 (Spring 2025)|Spring 2025]], [[概率论与数理统计 (Spring 2024)|Spring 2024]], [[概率论与数理统计 (Spring 2023)|Spring 2023]].&lt;br /&gt;
&lt;br /&gt;
* Quantum Computation: [[量子计算 (Spring 2022)|Spring 2022]], [[量子计算 (Spring 2021)|Spring 2021]], [[量子计算 (Fall 2019)|Fall 2019]].&lt;br /&gt;
&lt;br /&gt;
* Randomized Algorithms:  [[随机算法 (Fall 2015)|Fall 2015]], [[随机算法 (Spring 2014)|Spring 2014]], [[随机算法 (Spring 2013)|Spring 2013]], [[随机算法 (Fall 2011)|Fall 2011]], [[Randomized Algorithms (Spring 2010)|Spring 2010]].&lt;br /&gt;
&lt;br /&gt;
;Past seminars, workshops and summer schools&lt;br /&gt;
*计算理论之美暑期学校: [[计算理论之美 (Summer 2025)|2025]], [[计算理论之美 (Summer 2024)|2024]], [[计算理论之美 (Summer 2023)|2023]], [[计算理论之美 (Summer 2021)|2021]]&lt;br /&gt;
*[[Theory Seminar|理论计算机科学讨论班]]&lt;br /&gt;
*[[Study Group|理论计算机科学学习小组]]&lt;br /&gt;
*[[TCSPhD2020| 理论计算机科学优秀博士生论坛2020]]&lt;br /&gt;
*[[Quantum|量子算法与物理实现研讨会]]&lt;br /&gt;
*Theory Day: [[Theory@Suzhou 2025 | 2025 (Suzhou)]],  [[Theory@Nanjing 2019|2019]], [[Theory@Nanjing 2018|2018]], [[Theory@Nanjing 2017|2017]]&lt;br /&gt;
*[[\Delta Seminar on Logic, Philosophy, and Computer Science|Δ Seminar on Logic, Philosophy, and Computer Science]]&lt;br /&gt;
*[[近似算法讨论班 (Fall 2011)|近似算法 Approximation Algorithms, Fall 2011.]]&lt;br /&gt;
&lt;br /&gt;
; 其它链接&lt;br /&gt;
* [[General Circulation(Fall 2025)|大气环流 General Circulation of the Atmosphere, Fall 2025]]&lt;br /&gt;
* [[General Circulation(Fall 2024)|大气环流 General Circulation of the Atmosphere, Fall 2024]]&lt;br /&gt;
&lt;br /&gt;
* [[概率论 (Summer 2014)| 概率与计算 (上海交大 Summer 2014)]]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=Assignment_4,_Fall_2025&amp;diff=13419</id>
		<title>Assignment 4, Fall 2025</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Assignment_4,_Fall_2025&amp;diff=13419"/>
		<updated>2025-11-30T09:43:35Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;在第四章中，我们从准地转近似下的纬向平均风场、温度场的趋势方程出发，定义了E-P通量。但是该定义下的E-P通量并没有考虑到大气湿过程的影响。如果从第三章介绍的水汽方程出发，我们可以按照以下步骤定义出一个包含大气大尺度运动中湿过程作用的广义的E-P通量。   1）在准地转近似下，如果我们按照对热力学方程的简化方法，将比湿（specific humidity...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;在第四章中，我们从准地转近似下的纬向平均风场、温度场的趋势方程出发，定义了E-P通量。但是该定义下的E-P通量并没有考虑到大气湿过程的影响。如果从第三章介绍的水汽方程出发，我们可以按照以下步骤定义出一个包含大气大尺度运动中湿过程作用的广义的E-P通量。&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1）在准地转近似下，如果我们按照对热力学方程的简化方法，将比湿（specific humidity）&amp;lt;math&amp;gt;q&amp;lt;/math&amp;gt;， 分解成一个标准比湿 &amp;lt;math&amp;gt;q_s&amp;lt;/math&amp;gt;（reference specific humidity）和变化量&amp;lt;math&amp;gt;q&#039;&amp;lt;/math&amp;gt;，并且同样假设&amp;lt;math&amp;gt; \partial q /\partial p&amp;lt;/math&amp;gt;的水平变化很小，请证明在准地转近似下p坐标系下的纬向平均比湿&amp;lt;math&amp;gt;[q]&amp;lt;/math&amp;gt;的变化方程为：&lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;\dfrac{\partial [q&#039;]}{\partial t} + \dfrac{\partial q_s}{\partial p}[\omega]=-[C-S] -\dfrac{\partial}{\partial y}[v^*q^*]&amp;lt;/math&amp;gt;, &lt;br /&gt;
&lt;br /&gt;
其中&amp;lt;math&amp;gt;C-S&amp;lt;/math&amp;gt;为水汽方程在准地砖近似下的源汇项，表征由大尺度运动所带来的净凝结率。&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2）如果重新定义一个非绝热加热项&amp;lt;math&amp;gt;Q_m&amp;lt;/math&amp;gt;，使得&amp;lt;math&amp;gt;Q_m=Q-L[C-S](\frac{p}{p_o})^{R/c_p}&amp;lt;/math&amp;gt;，请推导出一个关于&amp;lt;math&amp;gt;[\theta+\frac{L}{c_p}q&#039;]&amp;lt;/math&amp;gt;的变化方程。&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3）根据以上推导出的新方程和准地转近似下&amp;lt;math&amp;gt;[u]&amp;lt;/math&amp;gt;的变化方程，请重新定义一个广义的E-P通量&amp;lt;math&amp;gt;\mathcal{F}_m&amp;lt;/math&amp;gt;，使得新的E-P通量中包含了eddy对水汽输送的作用；并且证明，在湿绝热&amp;lt;math&amp;gt;(Q_m=0)&amp;lt;/math&amp;gt;和无摩擦的情况下，平衡状态下的&amp;lt;math&amp;gt;\mathcal{F}_m&amp;lt;/math&amp;gt;满足&amp;lt;math&amp;gt;\nabla \cdot \mathcal{F}_m=0&amp;lt;/math&amp;gt;, 并请根据水汽输送的空间分布讨论：在实际大气中，新定义的E-P通量的&amp;lt;math&amp;gt;\nabla \cdot \mathcal{F}_m&amp;lt;/math&amp;gt;应该有怎样的变化？eddy 对水汽的输送作用将对维持 Ferrel 环流起到怎样的作用？&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4）请根据新定义出的E-P通量，定义出新的剩余环流(residual circulation, &amp;lt;math&amp;gt;[\tilde{v}_m]&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;[\tilde{\omega}_m]&amp;lt;/math&amp;gt;)，并讨论此时剩余环流的含义是什么？相对于新的剩余环流，新的TEM方程(Transformed Eulerian Mean Equations)应该是什么？同时，也请写出，如果用剩余环流来表述，(1)问中推导出的水汽方程将如何改写，eddy强迫项应变为什么？&lt;br /&gt;
&lt;br /&gt;
&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;quot;&amp;gt; 作业用到的[http://tcs.nju.edu.cn/yzhang/Chap_5_vq_ver.pdf eddy对水汽输送的空间分布]&amp;lt;/font&amp;gt;&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13418</id>
		<title>General Circulation(Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13418"/>
		<updated>2025-11-30T09:42:58Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Assignments */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = 大气环流 &amp;lt;br&amp;gt;&lt;br /&gt;
General Circulation of the Atmosphere&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 张洋&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yangzhang@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 仙林大气楼 B410&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = 周一 下午 2:00-4:00，仙II-110&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = 周五 下午13:00-2:00 &amp;lt;br&amp;gt;仙林大气楼B410 &lt;br /&gt;
|header9 = Reference book&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:James-Circulating.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = Introduction to Circulating Atmospheres, &amp;lt;br&amp;gt;&#039;&#039;I. James&#039;&#039;, Cambridge Press, 1995&lt;br /&gt;
|captionstyle = }}&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:Oort.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Physics of Climate, &#039;&#039;Peixoto, J. P.&#039;&#039; and &#039;&#039;A. H. Oort&#039;&#039;,  Springer-Verlag New York, 1992&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:geoff.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation, &#039;&#039;Vallis, G. K.&#039;&#039;, Cambridge University Press, 2006&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the page for the class &#039;&#039;General Circulation of the Atmosphere (大气环流)&#039;&#039; for the Fall 2025 semester. Students who take this class should check this page periodically for content updates and new announcements.&lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* 课程交流QQ群：631262169，请各位选课的同学入群。【2025.9.8】&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 张洋，&lt;br /&gt;
:*office: 仙林气象楼 B410&lt;br /&gt;
:*email: yangzhang@nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: 周一 下午 2:00-4:00；仙II-110&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: 周五 &amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;gt;下午1:00-2:00，仙林大气楼B410&amp;lt;/font&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Prerequisites&#039;&#039;&#039;: 动力气象，天气学，气候学&lt;br /&gt;
* &#039;&#039;&#039;Grading&#039;&#039;&#039;: 平时作业（50％）＋ 期末考试（50％）&lt;br /&gt;
本课程将大致布置4次作业，每次作业一二道题目左右。题目将选择每个课题最具有代表性、需要一定思维强度和动手能力的训练用题目,意在使学生通过顺利完成作业来建立环流系统的物理模型、以对课程内容得到深刻全面地理解和掌握。期末考试题目数量将会比平时作业多,覆盖面更广,但会比作业题目简单,只涉及对基本内容的掌握和对环流理论的直接应用。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
# [[Assignment 1, Fall 2025|Reanalysis data and the earth&#039;s climatology]] [Due:2025.10.13]&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;1.5&amp;quot;&amp;gt;请在本次作业的截止日期前将本次作业的图片部分和文字部分打包作为附件发送至邮箱 circulation_nju@126.com &amp;lt;/font&amp;gt;[[Namelist_Assignment_1_2025|上交作业人员名单]]&lt;br /&gt;
# [[Assignment 2, Fall 2025|Simple energy balance climate model]][Due:2025.10.27]&lt;br /&gt;
# [[Assignment 3, Fall 2025|Hadley Cell]] [Due:2025.11.10]&lt;br /&gt;
# [[Assignment 4, Fall 2025|A generalized E-P flux ]][Due:2025.12.15]&lt;br /&gt;
&lt;br /&gt;
= Course intro =&lt;br /&gt;
“大气环流”常指地球大气较大空间范围、较长时间尺度上的空气流动，及其对地球大气热量、动量、能量和水汽的全球输送。虽然从十七、十八世纪起人们就开始研究大尺度的大气运动(如Hadley在1735年提出的信风理论)，但大气环流真正发展成为一门较完备的学科方向却是近半个世纪的事情。随着四五十年代探空资料等高空气象要素的取得，以及六十年代卫星等覆盖全球的观测资料的加入，大气环流的空间结构和时间变化开始被系统、全面地揭示。与此同时，大气环流的数值模拟，也开始成为研究大气环流的一个主要方法，并发展至今成为了解和预估未来气候变化的主要手段。随着观测和模拟手段的进步，大气环流的理论研究也在近三十年开始快速地发展，人们对各种环流系统的维持和变化有了更全面、更深刻、也更为现代的理解。&lt;br /&gt;
&lt;br /&gt;
现代的大气环流是大气动力学、天气学和气候学相结合的产物。大气环流，既是各种天气现象产生的背景流场，又是各种气候状态形成的动力机制。大气环流在低频、季节、年际、年代际等时间尺度的变化，不但会引起天气现象的变化，也影响着气候状态的形成。而在大气科学领域面临着诸如全球暖化、气候变化、环流异常等重大科学问题的今天，大气环流研究的重要性被推到了前所未有的高度,大气环流也成为活跃发展又充满挑战的学科方向。&lt;br /&gt;
&lt;br /&gt;
本课程将讲述在过去几十年里大气环流在观测、理论和模拟上取得的进展。希望学生借此课程能熟悉大气环流的基本分布和形态，掌握各主要环流系统的维持和变化机制，建立各环流系统形成的物理模型，了解现阶段的大气环流模式，知道大气环流方向有待解决的科学问题。&lt;br /&gt;
&lt;br /&gt;
作为一门课程，大气环流内容的讲述常可以有两条线索。一条是全球尺度上大气热量、动量、能量和水汽的分布与输送，Lorenz（1967）和 Peixoto and Oort（1992）是按此线索介绍大气环流的优秀教材；另一条线索，是各纬度、各区域内大气环流系统的形成、维持和变化机制，James（1995）和 Vallis（2006）是按此线索介绍大气环流的经典讲义。根据现阶段大气环流方向的研究特点，本课程的讲述将主要按照后一种方式来展开，并辅以介绍各环流系统对大气各要素场的输送。在介绍各环流系统时，本课程将以观测、理论和模拟为顺序，从各大气环流系统的观测事实入手，介绍大气环流系统的分布特征和时空变化特征；着重介绍关于环流系统的各种动力学模型和现阶段对环流系统的理解；辅以对环流系统模拟研究的介绍；最后通过三者的对比，讨论各环流系统有待研究的问题。&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
本课程具体的内容安排如下：第一章为大气环流的概述，介绍大气环流发展的历史、包含的内容以及大气环流研究的常用观测资料和分析方法。第二章介绍大气环流产生的外部强迫：辐射强迫和下界面过程。第三至六章介绍大气环流中的各个环流系统及它们的动力机制。第七章详细介绍各复杂度的大气环流模式。第八章介绍大气环流领域现阶段最大的一个开放课题：全球暖化背景下的大气环流。这一章既是对前几章所介绍的大气环流理论的应用与检验，又是对未来大气环流研究方向的探讨。借此让学生熟悉并理解大气环流领域亟需解决的课题。具体课程安排和参考书目如下。&lt;br /&gt;
== Course schedule ==&lt;br /&gt;
*大气环流概述 (Introduction) （6课时）&lt;br /&gt;
*大气环流的外部强迫（3课时）&lt;br /&gt;
**辐射强迫 (Radiative forcing)&lt;br /&gt;
**下界面过程 (Surface boundaries)&lt;br /&gt;
*经向环流系统 (Zonally-averaged circulations)&lt;br /&gt;
**Hadley 环流（4课时）&lt;br /&gt;
**Ferrel 环流，急流，中纬度的波流相互作用（8课时）&lt;br /&gt;
*纬向环流系统（Non-zonal circulations）（6课时）&lt;br /&gt;
**Storm tracks&lt;br /&gt;
**Monsoon&lt;br /&gt;
**ENSO and Walker circulation&lt;br /&gt;
*能量和水汽循环 (Angular momentum, energy and water vapor)（2课时）&lt;br /&gt;
*不同复杂度的大气环流模式 (General circulation in a hierarchy of models)（2课时）&lt;br /&gt;
*全球暖化背景下的大气环流 (General circulation in the global warming scenario)（2课时）&lt;br /&gt;
&lt;br /&gt;
[[点击此处看详细课程安排 (click for more)]]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
*观测部分：Peixoto, J. P. and A. H. Oort, 1992: Physics of Climate. Springer-Verlag New York, Inc., 520 pp. 中文译本：气候物理学，1995，吴国雄、刘辉等译校，气象出版社。&lt;br /&gt;
*综合介绍：James, I., 1995: Introduction to circulating atmospheres. Cambridge University Press, 448 pp. &lt;br /&gt;
*理论部分：Vallis, G. K., 2006: Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation. Cambridge University Press. 745 pp.&lt;br /&gt;
* [[其它参考书目（点击看详情）]]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=Assignment_3,_Fall_2025&amp;diff=13338</id>
		<title>Assignment 3, Fall 2025</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Assignment_3,_Fall_2025&amp;diff=13338"/>
		<updated>2025-10-26T15:00:03Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;Held-Hou(1980) 讨论了当外部强迫的经向分布呈二次勒让德多项式，即&amp;lt;math&amp;gt;\dfrac{\Theta_E(\phi,z)}{\Theta_o}=1-\dfrac{2}{3}\Delta_H P_2(\sin \phi)+\Delta_v(\dfrac{z}{H}-\dfrac{1}{2})&amp;lt;/math&amp;gt;的情况下，哈德莱环流内的风场、温度场、环流的空间范围等将怎样随纬度和外力强迫的强度而变化。如果将外力强迫的空间分布改为&amp;lt;math&amp;gt;\dfrac{\Theta_E(\phi,z)}{\Theta_o}=1-\Delta_H(\sin \phi -\frac{1}{2})+\Delta_v(\dfra...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Held-Hou(1980) 讨论了当外部强迫的经向分布呈二次勒让德多项式，即&amp;lt;math&amp;gt;\dfrac{\Theta_E(\phi,z)}{\Theta_o}=1-\dfrac{2}{3}\Delta_H P_2(\sin \phi)+\Delta_v(\dfrac{z}{H}-\dfrac{1}{2})&amp;lt;/math&amp;gt;的情况下，哈德莱环流内的风场、温度场、环流的空间范围等将怎样随纬度和外力强迫的强度而变化。如果将外力强迫的空间分布改为&amp;lt;math&amp;gt;\dfrac{\Theta_E(\phi,z)}{\Theta_o}=1-\Delta_H(\sin \phi -\frac{1}{2})+\Delta_v(\dfrac{z}{H}-\dfrac{1}{2})&amp;lt;/math&amp;gt;，&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#请推导出哈德莱环流内的高空风场和垂直平均位温场&amp;lt;math&amp;gt;\dfrac{\tilde{\Theta}}{\Theta_o} &amp;lt;/math&amp;gt;将如何随纬度分布;&lt;br /&gt;
#同样利用小角度假设，请推导出环流的空间范围&amp;lt;math&amp;gt;\phi_H &amp;lt;/math&amp;gt; 的表达式。如果设 &amp;lt;math&amp;gt;r \equiv \dfrac{gH}{\Omega^2a^2}  &amp;lt;/math&amp;gt;, 请分别画出当 &amp;lt;math&amp;gt;\Delta_H=1/3&amp;lt;/math&amp;gt; 和 &amp;lt;math&amp;gt;\Delta_H=1/6&amp;lt;/math&amp;gt; 时, 与Held-Hou的情况相比，&amp;lt;math&amp;gt;\phi_H&amp;lt;/math&amp;gt; 怎样随 &amp;lt;math&amp;gt;r&amp;lt;/math&amp;gt; 而变化。&lt;br /&gt;
#&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;quot;&amp;gt;选做题目：&amp;lt;/font&amp;gt;在此情况下，近地面风场的分布有怎样变化。&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13337</id>
		<title>General Circulation(Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13337"/>
		<updated>2025-10-26T14:59:25Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Assignments */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = 大气环流 &amp;lt;br&amp;gt;&lt;br /&gt;
General Circulation of the Atmosphere&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 张洋&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yangzhang@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 仙林大气楼 B410&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = 周一 下午 2:00-4:00，仙II-110&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = 周五 下午13:00-2:00 &amp;lt;br&amp;gt;仙林大气楼B410 &lt;br /&gt;
|header9 = Reference book&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:James-Circulating.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = Introduction to Circulating Atmospheres, &amp;lt;br&amp;gt;&#039;&#039;I. James&#039;&#039;, Cambridge Press, 1995&lt;br /&gt;
|captionstyle = }}&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:Oort.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Physics of Climate, &#039;&#039;Peixoto, J. P.&#039;&#039; and &#039;&#039;A. H. Oort&#039;&#039;,  Springer-Verlag New York, 1992&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:geoff.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation, &#039;&#039;Vallis, G. K.&#039;&#039;, Cambridge University Press, 2006&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the page for the class &#039;&#039;General Circulation of the Atmosphere (大气环流)&#039;&#039; for the Fall 2025 semester. Students who take this class should check this page periodically for content updates and new announcements.&lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* 课程交流QQ群：631262169，请各位选课的同学入群。【2025.9.8】&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 张洋，&lt;br /&gt;
:*office: 仙林气象楼 B410&lt;br /&gt;
:*email: yangzhang@nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: 周一 下午 2:00-4:00；仙II-110&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: 周五 &amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;gt;下午1:00-2:00，仙林大气楼B410&amp;lt;/font&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Prerequisites&#039;&#039;&#039;: 动力气象，天气学，气候学&lt;br /&gt;
* &#039;&#039;&#039;Grading&#039;&#039;&#039;: 平时作业（50％）＋ 期末考试（50％）&lt;br /&gt;
本课程将大致布置4次作业，每次作业一二道题目左右。题目将选择每个课题最具有代表性、需要一定思维强度和动手能力的训练用题目,意在使学生通过顺利完成作业来建立环流系统的物理模型、以对课程内容得到深刻全面地理解和掌握。期末考试题目数量将会比平时作业多,覆盖面更广,但会比作业题目简单,只涉及对基本内容的掌握和对环流理论的直接应用。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
# [[Assignment 1, Fall 2025|Reanalysis data and the earth&#039;s climatology]] [Due:2025.10.13]&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;1.5&amp;quot;&amp;gt;请在本次作业的截止日期前将本次作业的图片部分和文字部分打包作为附件发送至邮箱 circulation_nju@126.com &amp;lt;/font&amp;gt;[[Namelist_Assignment_1_2025|上交作业人员名单]]&lt;br /&gt;
# [[Assignment 2, Fall 2025|Simple energy balance climate model]][Due:2025.10.27]&lt;br /&gt;
# [[Assignment 3, Fall 2025|Hadley Cell]] [Due:2025.11.10]&lt;br /&gt;
&lt;br /&gt;
= Course intro =&lt;br /&gt;
“大气环流”常指地球大气较大空间范围、较长时间尺度上的空气流动，及其对地球大气热量、动量、能量和水汽的全球输送。虽然从十七、十八世纪起人们就开始研究大尺度的大气运动(如Hadley在1735年提出的信风理论)，但大气环流真正发展成为一门较完备的学科方向却是近半个世纪的事情。随着四五十年代探空资料等高空气象要素的取得，以及六十年代卫星等覆盖全球的观测资料的加入，大气环流的空间结构和时间变化开始被系统、全面地揭示。与此同时，大气环流的数值模拟，也开始成为研究大气环流的一个主要方法，并发展至今成为了解和预估未来气候变化的主要手段。随着观测和模拟手段的进步，大气环流的理论研究也在近三十年开始快速地发展，人们对各种环流系统的维持和变化有了更全面、更深刻、也更为现代的理解。&lt;br /&gt;
&lt;br /&gt;
现代的大气环流是大气动力学、天气学和气候学相结合的产物。大气环流，既是各种天气现象产生的背景流场，又是各种气候状态形成的动力机制。大气环流在低频、季节、年际、年代际等时间尺度的变化，不但会引起天气现象的变化，也影响着气候状态的形成。而在大气科学领域面临着诸如全球暖化、气候变化、环流异常等重大科学问题的今天，大气环流研究的重要性被推到了前所未有的高度,大气环流也成为活跃发展又充满挑战的学科方向。&lt;br /&gt;
&lt;br /&gt;
本课程将讲述在过去几十年里大气环流在观测、理论和模拟上取得的进展。希望学生借此课程能熟悉大气环流的基本分布和形态，掌握各主要环流系统的维持和变化机制，建立各环流系统形成的物理模型，了解现阶段的大气环流模式，知道大气环流方向有待解决的科学问题。&lt;br /&gt;
&lt;br /&gt;
作为一门课程，大气环流内容的讲述常可以有两条线索。一条是全球尺度上大气热量、动量、能量和水汽的分布与输送，Lorenz（1967）和 Peixoto and Oort（1992）是按此线索介绍大气环流的优秀教材；另一条线索，是各纬度、各区域内大气环流系统的形成、维持和变化机制，James（1995）和 Vallis（2006）是按此线索介绍大气环流的经典讲义。根据现阶段大气环流方向的研究特点，本课程的讲述将主要按照后一种方式来展开，并辅以介绍各环流系统对大气各要素场的输送。在介绍各环流系统时，本课程将以观测、理论和模拟为顺序，从各大气环流系统的观测事实入手，介绍大气环流系统的分布特征和时空变化特征；着重介绍关于环流系统的各种动力学模型和现阶段对环流系统的理解；辅以对环流系统模拟研究的介绍；最后通过三者的对比，讨论各环流系统有待研究的问题。&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
本课程具体的内容安排如下：第一章为大气环流的概述，介绍大气环流发展的历史、包含的内容以及大气环流研究的常用观测资料和分析方法。第二章介绍大气环流产生的外部强迫：辐射强迫和下界面过程。第三至六章介绍大气环流中的各个环流系统及它们的动力机制。第七章详细介绍各复杂度的大气环流模式。第八章介绍大气环流领域现阶段最大的一个开放课题：全球暖化背景下的大气环流。这一章既是对前几章所介绍的大气环流理论的应用与检验，又是对未来大气环流研究方向的探讨。借此让学生熟悉并理解大气环流领域亟需解决的课题。具体课程安排和参考书目如下。&lt;br /&gt;
== Course schedule ==&lt;br /&gt;
*大气环流概述 (Introduction) （6课时）&lt;br /&gt;
*大气环流的外部强迫（3课时）&lt;br /&gt;
**辐射强迫 (Radiative forcing)&lt;br /&gt;
**下界面过程 (Surface boundaries)&lt;br /&gt;
*经向环流系统 (Zonally-averaged circulations)&lt;br /&gt;
**Hadley 环流（4课时）&lt;br /&gt;
**Ferrel 环流，急流，中纬度的波流相互作用（8课时）&lt;br /&gt;
*纬向环流系统（Non-zonal circulations）（6课时）&lt;br /&gt;
**Storm tracks&lt;br /&gt;
**Monsoon&lt;br /&gt;
**ENSO and Walker circulation&lt;br /&gt;
*能量和水汽循环 (Angular momentum, energy and water vapor)（2课时）&lt;br /&gt;
*不同复杂度的大气环流模式 (General circulation in a hierarchy of models)（2课时）&lt;br /&gt;
*全球暖化背景下的大气环流 (General circulation in the global warming scenario)（2课时）&lt;br /&gt;
&lt;br /&gt;
[[点击此处看详细课程安排 (click for more)]]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
*观测部分：Peixoto, J. P. and A. H. Oort, 1992: Physics of Climate. Springer-Verlag New York, Inc., 520 pp. 中文译本：气候物理学，1995，吴国雄、刘辉等译校，气象出版社。&lt;br /&gt;
*综合介绍：James, I., 1995: Introduction to circulating atmospheres. Cambridge University Press, 448 pp. &lt;br /&gt;
*理论部分：Vallis, G. K., 2006: Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation. Cambridge University Press. 745 pp.&lt;br /&gt;
* [[其它参考书目（点击看详情）]]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=Namelist_Assignment_1_2025&amp;diff=13327</id>
		<title>Namelist Assignment 1 2025</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Namelist_Assignment_1_2025&amp;diff=13327"/>
		<updated>2025-10-20T02:22:55Z</updated>

		<summary type="html">&lt;p&gt;Etone: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;学号     	姓名&lt;br /&gt;
&lt;br /&gt;
221830009	丁潘宇&lt;br /&gt;
&lt;br /&gt;
221840131	崔亚川&lt;br /&gt;
&lt;br /&gt;
221830192	张梓轩&lt;br /&gt;
&lt;br /&gt;
221830060	梁茗豪&lt;br /&gt;
&lt;br /&gt;
221840001	檀纯芳&lt;br /&gt;
&lt;br /&gt;
221840042	刘鑫磊&lt;br /&gt;
&lt;br /&gt;
221840183	胡峻滔&lt;br /&gt;
&lt;br /&gt;
221840252	徐玘&lt;br /&gt;
&lt;br /&gt;
221830079	余秀蓝&lt;br /&gt;
&lt;br /&gt;
221840217	于步涵&lt;br /&gt;
&lt;br /&gt;
221840063	樊瑾奕&lt;br /&gt;
&lt;br /&gt;
221840226	郑凯容&lt;br /&gt;
&lt;br /&gt;
221840163	周若冰&lt;br /&gt;
&lt;br /&gt;
221840204	张利荣&lt;br /&gt;
&lt;br /&gt;
652025280008	李俊霖&lt;br /&gt;
&lt;br /&gt;
502025280011	苟敏杰&lt;br /&gt;
&lt;br /&gt;
502025280051	吴雨涵&lt;br /&gt;
&lt;br /&gt;
502024280014	何昌霖&lt;br /&gt;
&lt;br /&gt;
502025280038	齐若彤&lt;br /&gt;
&lt;br /&gt;
502025280008	冯英飞&lt;br /&gt;
&lt;br /&gt;
502025280022	蒋妍&lt;br /&gt;
&lt;br /&gt;
502025280062	张艳&lt;br /&gt;
&lt;br /&gt;
502025280049	王彧喆&lt;br /&gt;
&lt;br /&gt;
502025280013	郭浩彬&lt;br /&gt;
&lt;br /&gt;
502025280006	陈俊任&lt;br /&gt;
&lt;br /&gt;
502025280001	边兆洋&lt;br /&gt;
&lt;br /&gt;
502025280060	虞越&lt;br /&gt;
&lt;br /&gt;
502025280032	刘毓晴&lt;br /&gt;
&lt;br /&gt;
502025280041	饶嘉祺&lt;br /&gt;
&lt;br /&gt;
502025280045	汪嘉斌&lt;br /&gt;
&lt;br /&gt;
502025280024	康育恺&lt;br /&gt;
&lt;br /&gt;
502025280035	骆建勋&lt;br /&gt;
&lt;br /&gt;
502025280053	夏瑞阳&lt;br /&gt;
&lt;br /&gt;
502025280010	葛雯菲&lt;br /&gt;
&lt;br /&gt;
502025280005	陈镜宇&lt;br /&gt;
&lt;br /&gt;
502025280026	李博彦&lt;br /&gt;
&lt;br /&gt;
502025280028	&lt;br /&gt;
&lt;br /&gt;
502025280029	刘辰昊&lt;br /&gt;
&lt;br /&gt;
502025280052	吴雨杭&lt;br /&gt;
&lt;br /&gt;
502025280002	蔡鸿雨&lt;br /&gt;
&lt;br /&gt;
502025280019	黄奏凯&lt;br /&gt;
&lt;br /&gt;
502025280039	钱福荣&lt;br /&gt;
&lt;br /&gt;
502025280043	宋丹阳&lt;br /&gt;
&lt;br /&gt;
502025280048	王弈博&lt;br /&gt;
&lt;br /&gt;
502025280017	黄扬&lt;br /&gt;
&lt;br /&gt;
502025280033	龙江羽恬&lt;br /&gt;
&lt;br /&gt;
502025280014	郭毅&lt;br /&gt;
&lt;br /&gt;
502025280063	张一鸣&lt;br /&gt;
&lt;br /&gt;
502025280059	尹志刚&lt;br /&gt;
&lt;br /&gt;
502025280020	霍星宏&lt;br /&gt;
&lt;br /&gt;
502025280023	开塞尔·克热米拉&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=Namelist_Assignment_1_2025&amp;diff=13326</id>
		<title>Namelist Assignment 1 2025</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Namelist_Assignment_1_2025&amp;diff=13326"/>
		<updated>2025-10-20T02:22:36Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;学号	姓名 221830009	丁潘宇  221840131	崔亚川  221830192	张梓轩  221830060	梁茗豪  221840001	檀纯芳  221840042	刘鑫磊  221840183	胡峻滔  221840252	徐玘  221830079	余秀蓝  221840217	于步涵  221840063	樊瑾奕  221840226	郑凯容  221840163	周若冰  221840204	张利荣  652025280008	李俊霖  502025280011	苟敏杰  502025280051	吴雨涵  502024280014	何昌霖  502025280038	齐若彤  502025280008	冯英飞  502025280022	蒋妍  50202...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;学号	姓名&lt;br /&gt;
221830009	丁潘宇&lt;br /&gt;
&lt;br /&gt;
221840131	崔亚川&lt;br /&gt;
&lt;br /&gt;
221830192	张梓轩&lt;br /&gt;
&lt;br /&gt;
221830060	梁茗豪&lt;br /&gt;
&lt;br /&gt;
221840001	檀纯芳&lt;br /&gt;
&lt;br /&gt;
221840042	刘鑫磊&lt;br /&gt;
&lt;br /&gt;
221840183	胡峻滔&lt;br /&gt;
&lt;br /&gt;
221840252	徐玘&lt;br /&gt;
&lt;br /&gt;
221830079	余秀蓝&lt;br /&gt;
&lt;br /&gt;
221840217	于步涵&lt;br /&gt;
&lt;br /&gt;
221840063	樊瑾奕&lt;br /&gt;
&lt;br /&gt;
221840226	郑凯容&lt;br /&gt;
&lt;br /&gt;
221840163	周若冰&lt;br /&gt;
&lt;br /&gt;
221840204	张利荣&lt;br /&gt;
&lt;br /&gt;
652025280008	李俊霖&lt;br /&gt;
&lt;br /&gt;
502025280011	苟敏杰&lt;br /&gt;
&lt;br /&gt;
502025280051	吴雨涵&lt;br /&gt;
&lt;br /&gt;
502024280014	何昌霖&lt;br /&gt;
&lt;br /&gt;
502025280038	齐若彤&lt;br /&gt;
&lt;br /&gt;
502025280008	冯英飞&lt;br /&gt;
&lt;br /&gt;
502025280022	蒋妍&lt;br /&gt;
&lt;br /&gt;
502025280062	张艳&lt;br /&gt;
&lt;br /&gt;
502025280049	王彧喆&lt;br /&gt;
&lt;br /&gt;
502025280013	郭浩彬&lt;br /&gt;
&lt;br /&gt;
502025280006	陈俊任&lt;br /&gt;
&lt;br /&gt;
502025280001	边兆洋&lt;br /&gt;
&lt;br /&gt;
502025280060	虞越&lt;br /&gt;
&lt;br /&gt;
502025280032	刘毓晴&lt;br /&gt;
&lt;br /&gt;
502025280041	饶嘉祺&lt;br /&gt;
&lt;br /&gt;
502025280045	汪嘉斌&lt;br /&gt;
&lt;br /&gt;
502025280024	康育恺&lt;br /&gt;
&lt;br /&gt;
502025280035	骆建勋&lt;br /&gt;
&lt;br /&gt;
502025280053	夏瑞阳&lt;br /&gt;
&lt;br /&gt;
502025280010	葛雯菲&lt;br /&gt;
&lt;br /&gt;
502025280005	陈镜宇&lt;br /&gt;
&lt;br /&gt;
502025280026	李博彦&lt;br /&gt;
&lt;br /&gt;
502025280028	&lt;br /&gt;
&lt;br /&gt;
502025280029	刘辰昊&lt;br /&gt;
&lt;br /&gt;
502025280052	吴雨杭&lt;br /&gt;
&lt;br /&gt;
502025280002	蔡鸿雨&lt;br /&gt;
&lt;br /&gt;
502025280019	黄奏凯&lt;br /&gt;
&lt;br /&gt;
502025280039	钱福荣&lt;br /&gt;
&lt;br /&gt;
502025280043	宋丹阳&lt;br /&gt;
&lt;br /&gt;
502025280048	王弈博&lt;br /&gt;
&lt;br /&gt;
502025280017	黄扬&lt;br /&gt;
&lt;br /&gt;
502025280033	龙江羽恬&lt;br /&gt;
&lt;br /&gt;
502025280014	郭毅&lt;br /&gt;
&lt;br /&gt;
502025280063	张一鸣&lt;br /&gt;
&lt;br /&gt;
502025280059	尹志刚&lt;br /&gt;
&lt;br /&gt;
502025280020	霍星宏&lt;br /&gt;
&lt;br /&gt;
502025280023	开塞尔·克热米拉&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13325</id>
		<title>General Circulation(Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13325"/>
		<updated>2025-10-20T02:08:00Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Assignments */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = 大气环流 &amp;lt;br&amp;gt;&lt;br /&gt;
General Circulation of the Atmosphere&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 张洋&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yangzhang@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 仙林大气楼 B410&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = 周一 下午 2:00-4:00，仙II-110&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = 周五 下午13:00-2:00 &amp;lt;br&amp;gt;仙林大气楼B410 &lt;br /&gt;
|header9 = Reference book&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:James-Circulating.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = Introduction to Circulating Atmospheres, &amp;lt;br&amp;gt;&#039;&#039;I. James&#039;&#039;, Cambridge Press, 1995&lt;br /&gt;
|captionstyle = }}&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:Oort.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Physics of Climate, &#039;&#039;Peixoto, J. P.&#039;&#039; and &#039;&#039;A. H. Oort&#039;&#039;,  Springer-Verlag New York, 1992&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:geoff.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation, &#039;&#039;Vallis, G. K.&#039;&#039;, Cambridge University Press, 2006&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the page for the class &#039;&#039;General Circulation of the Atmosphere (大气环流)&#039;&#039; for the Fall 2025 semester. Students who take this class should check this page periodically for content updates and new announcements.&lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* 课程交流QQ群：631262169，请各位选课的同学入群。【2025.9.8】&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 张洋，&lt;br /&gt;
:*office: 仙林气象楼 B410&lt;br /&gt;
:*email: yangzhang@nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: 周一 下午 2:00-4:00；仙II-110&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: 周五 &amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;gt;下午1:00-2:00，仙林大气楼B410&amp;lt;/font&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Prerequisites&#039;&#039;&#039;: 动力气象，天气学，气候学&lt;br /&gt;
* &#039;&#039;&#039;Grading&#039;&#039;&#039;: 平时作业（50％）＋ 期末考试（50％）&lt;br /&gt;
本课程将大致布置4次作业，每次作业一二道题目左右。题目将选择每个课题最具有代表性、需要一定思维强度和动手能力的训练用题目,意在使学生通过顺利完成作业来建立环流系统的物理模型、以对课程内容得到深刻全面地理解和掌握。期末考试题目数量将会比平时作业多,覆盖面更广,但会比作业题目简单,只涉及对基本内容的掌握和对环流理论的直接应用。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
# [[Assignment 1, Fall 2025|Reanalysis data and the earth&#039;s climatology]] [Due:2025.10.13]&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;1.5&amp;quot;&amp;gt;请在本次作业的截止日期前将本次作业的图片部分和文字部分打包作为附件发送至邮箱 circulation_nju@126.com &amp;lt;/font&amp;gt;[[Namelist_Assignment_1_2025|上交作业人员名单]]&lt;br /&gt;
# [[Assignment 2, Fall 2025|Simple energy balance climate model]][Due:2025.10.27]&lt;br /&gt;
&lt;br /&gt;
= Course intro =&lt;br /&gt;
“大气环流”常指地球大气较大空间范围、较长时间尺度上的空气流动，及其对地球大气热量、动量、能量和水汽的全球输送。虽然从十七、十八世纪起人们就开始研究大尺度的大气运动(如Hadley在1735年提出的信风理论)，但大气环流真正发展成为一门较完备的学科方向却是近半个世纪的事情。随着四五十年代探空资料等高空气象要素的取得，以及六十年代卫星等覆盖全球的观测资料的加入，大气环流的空间结构和时间变化开始被系统、全面地揭示。与此同时，大气环流的数值模拟，也开始成为研究大气环流的一个主要方法，并发展至今成为了解和预估未来气候变化的主要手段。随着观测和模拟手段的进步，大气环流的理论研究也在近三十年开始快速地发展，人们对各种环流系统的维持和变化有了更全面、更深刻、也更为现代的理解。&lt;br /&gt;
&lt;br /&gt;
现代的大气环流是大气动力学、天气学和气候学相结合的产物。大气环流，既是各种天气现象产生的背景流场，又是各种气候状态形成的动力机制。大气环流在低频、季节、年际、年代际等时间尺度的变化，不但会引起天气现象的变化，也影响着气候状态的形成。而在大气科学领域面临着诸如全球暖化、气候变化、环流异常等重大科学问题的今天，大气环流研究的重要性被推到了前所未有的高度,大气环流也成为活跃发展又充满挑战的学科方向。&lt;br /&gt;
&lt;br /&gt;
本课程将讲述在过去几十年里大气环流在观测、理论和模拟上取得的进展。希望学生借此课程能熟悉大气环流的基本分布和形态，掌握各主要环流系统的维持和变化机制，建立各环流系统形成的物理模型，了解现阶段的大气环流模式，知道大气环流方向有待解决的科学问题。&lt;br /&gt;
&lt;br /&gt;
作为一门课程，大气环流内容的讲述常可以有两条线索。一条是全球尺度上大气热量、动量、能量和水汽的分布与输送，Lorenz（1967）和 Peixoto and Oort（1992）是按此线索介绍大气环流的优秀教材；另一条线索，是各纬度、各区域内大气环流系统的形成、维持和变化机制，James（1995）和 Vallis（2006）是按此线索介绍大气环流的经典讲义。根据现阶段大气环流方向的研究特点，本课程的讲述将主要按照后一种方式来展开，并辅以介绍各环流系统对大气各要素场的输送。在介绍各环流系统时，本课程将以观测、理论和模拟为顺序，从各大气环流系统的观测事实入手，介绍大气环流系统的分布特征和时空变化特征；着重介绍关于环流系统的各种动力学模型和现阶段对环流系统的理解；辅以对环流系统模拟研究的介绍；最后通过三者的对比，讨论各环流系统有待研究的问题。&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
本课程具体的内容安排如下：第一章为大气环流的概述，介绍大气环流发展的历史、包含的内容以及大气环流研究的常用观测资料和分析方法。第二章介绍大气环流产生的外部强迫：辐射强迫和下界面过程。第三至六章介绍大气环流中的各个环流系统及它们的动力机制。第七章详细介绍各复杂度的大气环流模式。第八章介绍大气环流领域现阶段最大的一个开放课题：全球暖化背景下的大气环流。这一章既是对前几章所介绍的大气环流理论的应用与检验，又是对未来大气环流研究方向的探讨。借此让学生熟悉并理解大气环流领域亟需解决的课题。具体课程安排和参考书目如下。&lt;br /&gt;
== Course schedule ==&lt;br /&gt;
*大气环流概述 (Introduction) （6课时）&lt;br /&gt;
*大气环流的外部强迫（3课时）&lt;br /&gt;
**辐射强迫 (Radiative forcing)&lt;br /&gt;
**下界面过程 (Surface boundaries)&lt;br /&gt;
*经向环流系统 (Zonally-averaged circulations)&lt;br /&gt;
**Hadley 环流（4课时）&lt;br /&gt;
**Ferrel 环流，急流，中纬度的波流相互作用（8课时）&lt;br /&gt;
*纬向环流系统（Non-zonal circulations）（6课时）&lt;br /&gt;
**Storm tracks&lt;br /&gt;
**Monsoon&lt;br /&gt;
**ENSO and Walker circulation&lt;br /&gt;
*能量和水汽循环 (Angular momentum, energy and water vapor)（2课时）&lt;br /&gt;
*不同复杂度的大气环流模式 (General circulation in a hierarchy of models)（2课时）&lt;br /&gt;
*全球暖化背景下的大气环流 (General circulation in the global warming scenario)（2课时）&lt;br /&gt;
&lt;br /&gt;
[[点击此处看详细课程安排 (click for more)]]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
*观测部分：Peixoto, J. P. and A. H. Oort, 1992: Physics of Climate. Springer-Verlag New York, Inc., 520 pp. 中文译本：气候物理学，1995，吴国雄、刘辉等译校，气象出版社。&lt;br /&gt;
*综合介绍：James, I., 1995: Introduction to circulating atmospheres. Cambridge University Press, 448 pp. &lt;br /&gt;
*理论部分：Vallis, G. K., 2006: Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation. Cambridge University Press. 745 pp.&lt;br /&gt;
* [[其它参考书目（点击看详情）]]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13311</id>
		<title>高级算法 (Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13311"/>
		<updated>2025-10-16T04:18:51Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;高级算法 &lt;br /&gt;
&amp;lt;br&amp;gt;Advanced Algorithms&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;栗师&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = shili@nju.edu.cn &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7= office&lt;br /&gt;
|data7= 计算机系 605&lt;br /&gt;
|header8 = &lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header9 = &lt;br /&gt;
|label9  = Email&lt;br /&gt;
|data9   = liu@nju.edu.cn &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10= office&lt;br /&gt;
|data10= 计算机系 516&lt;br /&gt;
|header11 = Class&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = &lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = Class meetings&lt;br /&gt;
|data12   = Monday, 2pm-4pm &amp;lt;br&amp;gt; Thursday (双), 2pm-4pm &amp;lt;br&amp;gt;仙Ⅰ-320&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = Place&lt;br /&gt;
|data13   = &lt;br /&gt;
|header14 =&lt;br /&gt;
|label14  = Office hours&lt;br /&gt;
|data14   = TBD, &amp;lt;br&amp;gt;计算机系 804&amp;lt;br&amp;gt;&lt;br /&gt;
|header15 = Textbooks&lt;br /&gt;
|label15  = &lt;br /&gt;
|data15   = &lt;br /&gt;
|header16 =&lt;br /&gt;
|label16  = &lt;br /&gt;
|data16   = [[File:MR-randomized-algorithms.png|border|100px]]&lt;br /&gt;
|header17 =&lt;br /&gt;
|label17  = &lt;br /&gt;
|data17   = Motwani and Raghavan. &amp;lt;br&amp;gt;&#039;&#039;Randomized Algorithms&#039;&#039;.&amp;lt;br&amp;gt; Cambridge Univ Press, 1995.&lt;br /&gt;
|header18 =&lt;br /&gt;
|label18  = &lt;br /&gt;
|data18   = [[File:Approximation_Algorithms.jpg|border|100px]]&lt;br /&gt;
|header19 =&lt;br /&gt;
|label19  = &lt;br /&gt;
|data19   =  Vazirani. &amp;lt;br&amp;gt;&#039;&#039;Approximation Algorithms&#039;&#039;. &amp;lt;br&amp;gt; Springer-Verlag, 2001.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Advanced Algorithms&#039;&#039; class of fall 2025. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2025/9/10)&#039;&#039;&#039; 本周四（9月11日）课程时间地点不变，为第五、六节在仙I-320。从第四周（9月15日）开始，采用新的上课时间：每周一的第五、六节，以及双周四的第五、六节，地点仍在仙I-320。&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;（授课时间顺序）: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
:*[https://tcs.nju.edu.cn/shili/ 栗师]：[mailto:shili@nju.edu.cn &amp;lt;shili@nju.edu.cn&amp;gt;]，计算机系 605&lt;br /&gt;
* &#039;&#039;&#039;Teaching Assistant&#039;&#039;&#039;: &lt;br /&gt;
** 侯哲：houzhe@smail.nju.edu.cn&lt;br /&gt;
** 张弈垚：zhangyiyao@smail.nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: &lt;br /&gt;
** Monday, 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
** Thursday (双), 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: Wednesday 2pm-3pm, 计算机系 804&lt;br /&gt;
* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 524141453（加群请注明专业学号姓名）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
随着计算机算法理论的不断发展，现代计算机算法的设计与分析大量地使用非初等的数学工具以及非传统的算法思想。“高级算法”这门课程就是面向计算机算法的这一发展趋势而设立的。课程将针对传统算法课程未系统涉及、却在计算机科学各领域的科研和实践中扮演重要角色的高等算法设计思想和算法分析工具进行系统讲授。&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 必须：离散数学，概率论，线性代数。&lt;br /&gt;
* 推荐：算法设计与分析。&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[高级算法 (Fall 2025) / Course materials|&amp;lt;font size=3&amp;gt;教材和参考书&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
Late policy: In general, we will accomodate late submission requests ONLY IF you made such requests ahead of time. &lt;br /&gt;
&lt;br /&gt;
*[[高级算法 (Fall 2025)/Problem Set 1|Problem Set 1]]  请在 2025/10/30 上课之前(14:00 UTC+8) 提交到 [mailto:njuadvalg25@163.com njuadvalg25@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[高级算法 (Fall 2025)/Min Cut, Max Cut, and Spectral Cut|Min Cut, Max Cut, and Spectral Cut]] ([http://tcs.nju.edu.cn/slides/aa2025/Cut.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Probability Basics|Probability basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Fingerprinting| Fingerprinting]] ([http://tcs.nju.edu.cn/slides/aa2025/Fingerprinting.pdf slides]) &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Finite Field Basics|Finite field basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Hashing and Sketching|Hashing and Sketching]] ([http://tcs.nju.edu.cn/slides/aa2025/Hashing.pdf slides])   &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Limited independence|Limited independence]]&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Basic deviation inequalities|Basic deviation inequalities]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Concentration of measure|Concentration of measure]] ([http://tcs.nju.edu.cn/slides/aa2025/Concentration.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Conditional expectations|Conditional expectations]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Dimension Reduction|Dimension Reduction]] ([http://tcs.nju.edu.cn/slides/aa2025/NNS.pdf slides]) &lt;br /&gt;
#* [https://www.cs.princeton.edu/~hy2/teaching/fall22-cos521/notes/JL.pdf Professor Huacheng Yu&#039;s note on Johnson-Lindenstrauss Theorem]&lt;br /&gt;
#* [http://people.csail.mit.edu/gregory/annbook/introduction.pdf An introduction of LSH]&lt;br /&gt;
# &#039;&#039;Lovász&#039;&#039; Local Lemma   ([http://tcs.nju.edu.cn/slides/aa2025/LLL.pdf slides]) &lt;br /&gt;
#* [https://theory.stanford.edu/~jvondrak/MATH233A-2018/Math233-lec02.pdf Professor Jan Vondrák&#039;s Lecture Notes on LLL]&lt;br /&gt;
#* [https://www.cc.gatech.edu/~vigoda/6550/Notes/Lec16.pdf Professor Eric Vigoda&#039;s Lecture Notes on Algorithmic LLL]&lt;br /&gt;
&lt;br /&gt;
= Related Online Courses=&lt;br /&gt;
* [https://www.cs.cmu.edu/~15850/ Advanced Algorithms] by Anupam Gupta at CMU.&lt;br /&gt;
* [http://people.csail.mit.edu/moitra/854.html Advanced Algorithms] by Ankur Moitra at MIT.&lt;br /&gt;
* [http://courses.csail.mit.edu/6.854/current/ Advanced Algorithms] by David Karger and Aleksander Mądry at MIT.&lt;br /&gt;
* [http://web.stanford.edu/class/cs168/index.html The Modern Algorithmic Toolbox] by Tim Roughgarden and Gregory Valiant at Stanford.&lt;br /&gt;
* [https://www.cs.princeton.edu/courses/archive/fall18/cos521/ Advanced Algorithm Design] by Pravesh Kothari and Christopher Musco at Princeton.&lt;br /&gt;
* [http://www.cs.cmu.edu/afs/cs.cmu.edu/academic/class/15859-f11/www/ Linear and Semidefinite Programming (Advanced Algorithms)] by Anupam Gupta and Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://www.cs.cmu.edu/~odonnell/papers/cs-theory-toolkit-lecture-notes.pdf CS Theory Toolkit] by Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://cs.uwaterloo.ca/~lapchi/cs860/index.html Eigenvalues and Polynomials] by Lap Chi Lau at University of Waterloo.&lt;br /&gt;
* The [https://www.cs.cornell.edu/jeh/book.pdf &amp;quot;Foundations of Data Science&amp;quot; book] by Avrim Blum, John Hopcroft, and Ravindran Kannan.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13310</id>
		<title>高级算法 (Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13310"/>
		<updated>2025-10-16T04:03:49Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;高级算法 &lt;br /&gt;
&amp;lt;br&amp;gt;Advanced Algorithms&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;栗师&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = shili@nju.edu.cn &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7= office&lt;br /&gt;
|data7= 计算机系 605&lt;br /&gt;
|header8 = &lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header9 = &lt;br /&gt;
|label9  = Email&lt;br /&gt;
|data9   = liu@nju.edu.cn &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10= office&lt;br /&gt;
|data10= 计算机系 516&lt;br /&gt;
|header11 = Class&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = &lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = Class meetings&lt;br /&gt;
|data12   = Monday, 2pm-4pm &amp;lt;br&amp;gt; Thursday (双), 2pm-4pm &amp;lt;br&amp;gt;仙Ⅰ-320&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = Place&lt;br /&gt;
|data13   = &lt;br /&gt;
|header14 =&lt;br /&gt;
|label14  = Office hours&lt;br /&gt;
|data14   = TBD, &amp;lt;br&amp;gt;计算机系 804&amp;lt;br&amp;gt;&lt;br /&gt;
|header15 = Textbooks&lt;br /&gt;
|label15  = &lt;br /&gt;
|data15   = &lt;br /&gt;
|header16 =&lt;br /&gt;
|label16  = &lt;br /&gt;
|data16   = [[File:MR-randomized-algorithms.png|border|100px]]&lt;br /&gt;
|header17 =&lt;br /&gt;
|label17  = &lt;br /&gt;
|data17   = Motwani and Raghavan. &amp;lt;br&amp;gt;&#039;&#039;Randomized Algorithms&#039;&#039;.&amp;lt;br&amp;gt; Cambridge Univ Press, 1995.&lt;br /&gt;
|header18 =&lt;br /&gt;
|label18  = &lt;br /&gt;
|data18   = [[File:Approximation_Algorithms.jpg|border|100px]]&lt;br /&gt;
|header19 =&lt;br /&gt;
|label19  = &lt;br /&gt;
|data19   =  Vazirani. &amp;lt;br&amp;gt;&#039;&#039;Approximation Algorithms&#039;&#039;. &amp;lt;br&amp;gt; Springer-Verlag, 2001.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Advanced Algorithms&#039;&#039; class of fall 2025. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2025/9/10)&#039;&#039;&#039; 本周四（9月11日）课程时间地点不变，为第五、六节在仙I-320。从第四周（9月15日）开始，采用新的上课时间：每周一的第五、六节，以及双周四的第五、六节，地点仍在仙I-320。&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;（授课时间顺序）: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
:*[https://tcs.nju.edu.cn/shili/ 栗师]：[mailto:shili@nju.edu.cn &amp;lt;shili@nju.edu.cn&amp;gt;]，计算机系 605&lt;br /&gt;
* &#039;&#039;&#039;Teaching Assistant&#039;&#039;&#039;: &lt;br /&gt;
** 侯哲：houzhe@smail.nju.edu.cn&lt;br /&gt;
** 张弈垚：zhangyiyao@smail.nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: &lt;br /&gt;
** Monday, 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
** Thursday (双), 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: Wednesday 2pm-3pm, 计算机系 804&lt;br /&gt;
* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 524141453（加群请注明专业学号姓名）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
随着计算机算法理论的不断发展，现代计算机算法的设计与分析大量地使用非初等的数学工具以及非传统的算法思想。“高级算法”这门课程就是面向计算机算法的这一发展趋势而设立的。课程将针对传统算法课程未系统涉及、却在计算机科学各领域的科研和实践中扮演重要角色的高等算法设计思想和算法分析工具进行系统讲授。&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 必须：离散数学，概率论，线性代数。&lt;br /&gt;
* 推荐：算法设计与分析。&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[高级算法 (Fall 2025) / Course materials|&amp;lt;font size=3&amp;gt;教材和参考书&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
Late policy: In general, we will accomodate late submission requests ONLY IF you made such requests ahead of time. &lt;br /&gt;
&lt;br /&gt;
*[[高级算法 (Fall 2025)/Problem Set 1|Problem Set 1]]  请在 2025/10/30 上课之前(14:00 UTC+8) 提交到 [mailto:njuadvalg25@163.com njuadvalg25@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[高级算法 (Fall 2025)/Min Cut, Max Cut, and Spectral Cut|Min Cut, Max Cut, and Spectral Cut]] ([http://tcs.nju.edu.cn/slides/aa2025/Cut.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Probability Basics|Probability basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Fingerprinting| Fingerprinting]] ([http://tcs.nju.edu.cn/slides/aa2025/Fingerprinting.pdf slides]) &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Finite Field Basics|Finite field basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Hashing and Sketching|Hashing and Sketching]] ([http://tcs.nju.edu.cn/slides/aa2025/Hashing.pdf slides])   &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Limited independence|Limited independence]]&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Basic deviation inequalities|Basic deviation inequalities]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Concentration of measure|Concentration of measure]] ([http://tcs.nju.edu.cn/slides/aa2025/Concentration.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Conditional expectations|Conditional expectations]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Dimension Reduction|Dimension Reduction]] ([http://tcs.nju.edu.cn/slides/aa2025/NNS.pdf slides]) &lt;br /&gt;
#* [https://www.cs.princeton.edu/~hy2/teaching/fall22-cos521/notes/JL.pdf Professor Huacheng Yu&#039;s note on Johnson-Lindenstrauss Theorem]&lt;br /&gt;
#* [http://people.csail.mit.edu/gregory/annbook/introduction.pdf An introduction of LSH]&lt;br /&gt;
# &#039;&#039;Lovász&#039;&#039; Local Lemma   ([http://tcs.nju.edu.cn/slides/aa2024/LLL.pdf slides]) &lt;br /&gt;
#* [https://theory.stanford.edu/~jvondrak/MATH233A-2018/Math233-lec02.pdf Professor Jan Vondrák&#039;s Lecture Notes on LLL]&lt;br /&gt;
#* [https://www.cc.gatech.edu/~vigoda/6550/Notes/Lec16.pdf Professor Eric Vigoda&#039;s Lecture Notes on Algorithmic LLL]&lt;br /&gt;
&lt;br /&gt;
= Related Online Courses=&lt;br /&gt;
* [https://www.cs.cmu.edu/~15850/ Advanced Algorithms] by Anupam Gupta at CMU.&lt;br /&gt;
* [http://people.csail.mit.edu/moitra/854.html Advanced Algorithms] by Ankur Moitra at MIT.&lt;br /&gt;
* [http://courses.csail.mit.edu/6.854/current/ Advanced Algorithms] by David Karger and Aleksander Mądry at MIT.&lt;br /&gt;
* [http://web.stanford.edu/class/cs168/index.html The Modern Algorithmic Toolbox] by Tim Roughgarden and Gregory Valiant at Stanford.&lt;br /&gt;
* [https://www.cs.princeton.edu/courses/archive/fall18/cos521/ Advanced Algorithm Design] by Pravesh Kothari and Christopher Musco at Princeton.&lt;br /&gt;
* [http://www.cs.cmu.edu/afs/cs.cmu.edu/academic/class/15859-f11/www/ Linear and Semidefinite Programming (Advanced Algorithms)] by Anupam Gupta and Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://www.cs.cmu.edu/~odonnell/papers/cs-theory-toolkit-lecture-notes.pdf CS Theory Toolkit] by Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://cs.uwaterloo.ca/~lapchi/cs860/index.html Eigenvalues and Polynomials] by Lap Chi Lau at University of Waterloo.&lt;br /&gt;
* The [https://www.cs.cornell.edu/jeh/book.pdf &amp;quot;Foundations of Data Science&amp;quot; book] by Avrim Blum, John Hopcroft, and Ravindran Kannan.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13309</id>
		<title>高级算法 (Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13309"/>
		<updated>2025-10-16T04:00:32Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;高级算法 &lt;br /&gt;
&amp;lt;br&amp;gt;Advanced Algorithms&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;栗师&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = shili@nju.edu.cn &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7= office&lt;br /&gt;
|data7= 计算机系 605&lt;br /&gt;
|header8 = &lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header9 = &lt;br /&gt;
|label9  = Email&lt;br /&gt;
|data9   = liu@nju.edu.cn &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10= office&lt;br /&gt;
|data10= 计算机系 516&lt;br /&gt;
|header11 = Class&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = &lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = Class meetings&lt;br /&gt;
|data12   = Monday, 2pm-4pm &amp;lt;br&amp;gt; Thursday (双), 2pm-4pm &amp;lt;br&amp;gt;仙Ⅰ-320&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = Place&lt;br /&gt;
|data13   = &lt;br /&gt;
|header14 =&lt;br /&gt;
|label14  = Office hours&lt;br /&gt;
|data14   = TBD, &amp;lt;br&amp;gt;计算机系 804&amp;lt;br&amp;gt;&lt;br /&gt;
|header15 = Textbooks&lt;br /&gt;
|label15  = &lt;br /&gt;
|data15   = &lt;br /&gt;
|header16 =&lt;br /&gt;
|label16  = &lt;br /&gt;
|data16   = [[File:MR-randomized-algorithms.png|border|100px]]&lt;br /&gt;
|header17 =&lt;br /&gt;
|label17  = &lt;br /&gt;
|data17   = Motwani and Raghavan. &amp;lt;br&amp;gt;&#039;&#039;Randomized Algorithms&#039;&#039;.&amp;lt;br&amp;gt; Cambridge Univ Press, 1995.&lt;br /&gt;
|header18 =&lt;br /&gt;
|label18  = &lt;br /&gt;
|data18   = [[File:Approximation_Algorithms.jpg|border|100px]]&lt;br /&gt;
|header19 =&lt;br /&gt;
|label19  = &lt;br /&gt;
|data19   =  Vazirani. &amp;lt;br&amp;gt;&#039;&#039;Approximation Algorithms&#039;&#039;. &amp;lt;br&amp;gt; Springer-Verlag, 2001.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Advanced Algorithms&#039;&#039; class of fall 2025. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2025/9/10)&#039;&#039;&#039; 本周四（9月11日）课程时间地点不变，为第五、六节在仙I-320。从第四周（9月15日）开始，采用新的上课时间：每周一的第五、六节，以及双周四的第五、六节，地点仍在仙I-320。&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;（授课时间顺序）: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
:*[https://tcs.nju.edu.cn/shili/ 栗师]：[mailto:shili@nju.edu.cn &amp;lt;shili@nju.edu.cn&amp;gt;]，计算机系 605&lt;br /&gt;
* &#039;&#039;&#039;Teaching Assistant&#039;&#039;&#039;: &lt;br /&gt;
** 侯哲：houzhe@smail.nju.edu.cn&lt;br /&gt;
** 张弈垚：zhangyiyao@smail.nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: &lt;br /&gt;
** Monday, 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
** Thursday (双), 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: Wednesday 2pm-3pm, 计算机系 804&lt;br /&gt;
* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 524141453（加群请注明专业学号姓名）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
随着计算机算法理论的不断发展，现代计算机算法的设计与分析大量地使用非初等的数学工具以及非传统的算法思想。“高级算法”这门课程就是面向计算机算法的这一发展趋势而设立的。课程将针对传统算法课程未系统涉及、却在计算机科学各领域的科研和实践中扮演重要角色的高等算法设计思想和算法分析工具进行系统讲授。&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 必须：离散数学，概率论，线性代数。&lt;br /&gt;
* 推荐：算法设计与分析。&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[高级算法 (Fall 2025) / Course materials|&amp;lt;font size=3&amp;gt;教材和参考书&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
Late policy: In general, we will accomodate late submission requests ONLY IF you made such requests ahead of time. &lt;br /&gt;
&lt;br /&gt;
*[[高级算法 (Fall 2025)/Problem Set 1|Problem Set 1]]  请在 2025/10/30 上课之前(14:00 UTC+8) 提交到 [mailto:njuadvalg25@163.com njuadvalg25@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[高级算法 (Fall 2025)/Min Cut, Max Cut, and Spectral Cut|Min Cut, Max Cut, and Spectral Cut]] ([http://tcs.nju.edu.cn/slides/aa2025/Cut.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Probability Basics|Probability basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Fingerprinting| Fingerprinting]] ([http://tcs.nju.edu.cn/slides/aa2025/Fingerprinting.pdf slides]) &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Finite Field Basics|Finite field basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Hashing and Sketching|Hashing and Sketching]] ([http://tcs.nju.edu.cn/slides/aa2025/Hashing.pdf slides])   &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Limited independence|Limited independence]]&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Basic deviation inequalities|Basic deviation inequalities]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Concentration of measure|Concentration of measure]] ([http://tcs.nju.edu.cn/slides/aa2025/Concentration.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Conditional expectations|Conditional expectations]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Dimension Reduction|Dimension Reduction]] ([http://tcs.nju.edu.cn/slides/aa2025/NNS.pdf slides]) &lt;br /&gt;
#* [https://www.cs.princeton.edu/~hy2/teaching/fall22-cos521/notes/JL.pdf Professor Huacheng Yu&#039;s note on Johnson-Lindenstrauss Theorem]&lt;br /&gt;
#* [http://people.csail.mit.edu/gregory/annbook/introduction.pdf An introduction of LSH]&lt;br /&gt;
# &#039;&#039;Lovász&#039;&#039; Local Lemma   ([http://tcs.nju.edu.cn/slides/aa2025/LLL.pdf slides]) &lt;br /&gt;
#* [https://theory.stanford.edu/~jvondrak/MATH233A-2018/Math233-lec02.pdf Professor Jan Vondrák&#039;s Lecture Notes on LLL]&lt;br /&gt;
#* [https://www.cc.gatech.edu/~vigoda/6550/Notes/Lec16.pdf Professor Eric Vigoda&#039;s Lecture Notes on Algorithmic LLL]&lt;br /&gt;
&lt;br /&gt;
= Related Online Courses=&lt;br /&gt;
* [https://www.cs.cmu.edu/~15850/ Advanced Algorithms] by Anupam Gupta at CMU.&lt;br /&gt;
* [http://people.csail.mit.edu/moitra/854.html Advanced Algorithms] by Ankur Moitra at MIT.&lt;br /&gt;
* [http://courses.csail.mit.edu/6.854/current/ Advanced Algorithms] by David Karger and Aleksander Mądry at MIT.&lt;br /&gt;
* [http://web.stanford.edu/class/cs168/index.html The Modern Algorithmic Toolbox] by Tim Roughgarden and Gregory Valiant at Stanford.&lt;br /&gt;
* [https://www.cs.princeton.edu/courses/archive/fall18/cos521/ Advanced Algorithm Design] by Pravesh Kothari and Christopher Musco at Princeton.&lt;br /&gt;
* [http://www.cs.cmu.edu/afs/cs.cmu.edu/academic/class/15859-f11/www/ Linear and Semidefinite Programming (Advanced Algorithms)] by Anupam Gupta and Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://www.cs.cmu.edu/~odonnell/papers/cs-theory-toolkit-lecture-notes.pdf CS Theory Toolkit] by Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://cs.uwaterloo.ca/~lapchi/cs860/index.html Eigenvalues and Polynomials] by Lap Chi Lau at University of Waterloo.&lt;br /&gt;
* The [https://www.cs.cornell.edu/jeh/book.pdf &amp;quot;Foundations of Data Science&amp;quot; book] by Avrim Blum, John Hopcroft, and Ravindran Kannan.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13308</id>
		<title>高级算法 (Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13308"/>
		<updated>2025-10-16T03:59:46Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Assignments */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;高级算法 &lt;br /&gt;
&amp;lt;br&amp;gt;Advanced Algorithms&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;栗师&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = shili@nju.edu.cn &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7= office&lt;br /&gt;
|data7= 计算机系 605&lt;br /&gt;
|header8 = &lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header9 = &lt;br /&gt;
|label9  = Email&lt;br /&gt;
|data9   = liu@nju.edu.cn &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10= office&lt;br /&gt;
|data10= 计算机系 516&lt;br /&gt;
|header11 = Class&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = &lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = Class meetings&lt;br /&gt;
|data12   = Monday, 2pm-4pm &amp;lt;br&amp;gt; Thursday (双), 2pm-4pm &amp;lt;br&amp;gt;仙Ⅰ-320&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = Place&lt;br /&gt;
|data13   = &lt;br /&gt;
|header14 =&lt;br /&gt;
|label14  = Office hours&lt;br /&gt;
|data14   = TBD, &amp;lt;br&amp;gt;计算机系 804&amp;lt;br&amp;gt;&lt;br /&gt;
|header15 = Textbooks&lt;br /&gt;
|label15  = &lt;br /&gt;
|data15   = &lt;br /&gt;
|header16 =&lt;br /&gt;
|label16  = &lt;br /&gt;
|data16   = [[File:MR-randomized-algorithms.png|border|100px]]&lt;br /&gt;
|header17 =&lt;br /&gt;
|label17  = &lt;br /&gt;
|data17   = Motwani and Raghavan. &amp;lt;br&amp;gt;&#039;&#039;Randomized Algorithms&#039;&#039;.&amp;lt;br&amp;gt; Cambridge Univ Press, 1995.&lt;br /&gt;
|header18 =&lt;br /&gt;
|label18  = &lt;br /&gt;
|data18   = [[File:Approximation_Algorithms.jpg|border|100px]]&lt;br /&gt;
|header19 =&lt;br /&gt;
|label19  = &lt;br /&gt;
|data19   =  Vazirani. &amp;lt;br&amp;gt;&#039;&#039;Approximation Algorithms&#039;&#039;. &amp;lt;br&amp;gt; Springer-Verlag, 2001.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Advanced Algorithms&#039;&#039; class of fall 2025. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2025/9/10)&#039;&#039;&#039; 本周四（9月11日）课程时间地点不变，为第五、六节在仙I-320。从第四周（9月15日）开始，采用新的上课时间：每周一的第五、六节，以及双周四的第五、六节，地点仍在仙I-320。&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;（授课时间顺序）: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
:*[https://tcs.nju.edu.cn/shili/ 栗师]：[mailto:shili@nju.edu.cn &amp;lt;shili@nju.edu.cn&amp;gt;]，计算机系 605&lt;br /&gt;
* &#039;&#039;&#039;Teaching Assistant&#039;&#039;&#039;: &lt;br /&gt;
** 侯哲：houzhe@smail.nju.edu.cn&lt;br /&gt;
** 张弈垚：zhangyiyao@smail.nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: &lt;br /&gt;
** Monday, 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
** Thursday (双), 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: Wednesday 2pm-3pm, 计算机系 804&lt;br /&gt;
* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 524141453（加群请注明专业学号姓名）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
随着计算机算法理论的不断发展，现代计算机算法的设计与分析大量地使用非初等的数学工具以及非传统的算法思想。“高级算法”这门课程就是面向计算机算法的这一发展趋势而设立的。课程将针对传统算法课程未系统涉及、却在计算机科学各领域的科研和实践中扮演重要角色的高等算法设计思想和算法分析工具进行系统讲授。&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 必须：离散数学，概率论，线性代数。&lt;br /&gt;
* 推荐：算法设计与分析。&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[高级算法 (Fall 2025) / Course materials|&amp;lt;font size=3&amp;gt;教材和参考书&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
Late policy: In general, we will accomodate late submission requests ONLY IF you made such requests ahead of time. &lt;br /&gt;
&lt;br /&gt;
*[[高级算法 (Fall 2025)/Problem Set 1|Problem Set 1]]  请在 2025/10/30 上课之前(14:00 UTC+8) 提交到 [mailto:njuadvalg25@163.com njuadvalg25@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[高级算法 (Fall 2025)/Min Cut, Max Cut, and Spectral Cut|Min Cut, Max Cut, and Spectral Cut]] ([http://tcs.nju.edu.cn/slides/aa2025/Cut.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Probability Basics|Probability basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Fingerprinting| Fingerprinting]] ([http://tcs.nju.edu.cn/slides/aa2025/Fingerprinting.pdf slides]) &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Finite Field Basics|Finite field basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Hashing and Sketching|Hashing and Sketching]] ([http://tcs.nju.edu.cn/slides/aa2025/Hashing.pdf slides])   &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Limited independence|Limited independence]]&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Basic deviation inequalities|Basic deviation inequalities]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Concentration of measure|Concentration of measure]] ([http://tcs.nju.edu.cn/slides/aa2025/Concentration.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Conditional expectations|Conditional expectations]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Dimension Reduction|Dimension Reduction]] ([http://tcs.nju.edu.cn/slides/aa2025/NNS.pdf slides]) &lt;br /&gt;
#* [https://www.cs.princeton.edu/~hy2/teaching/fall22-cos521/notes/JL.pdf Professor Huacheng Yu&#039;s note on Johnson-Lindenstrauss Theorem]&lt;br /&gt;
#* [http://people.csail.mit.edu/gregory/annbook/introduction.pdf An introduction of LSH]&lt;br /&gt;
&lt;br /&gt;
= Related Online Courses=&lt;br /&gt;
* [https://www.cs.cmu.edu/~15850/ Advanced Algorithms] by Anupam Gupta at CMU.&lt;br /&gt;
* [http://people.csail.mit.edu/moitra/854.html Advanced Algorithms] by Ankur Moitra at MIT.&lt;br /&gt;
* [http://courses.csail.mit.edu/6.854/current/ Advanced Algorithms] by David Karger and Aleksander Mądry at MIT.&lt;br /&gt;
* [http://web.stanford.edu/class/cs168/index.html The Modern Algorithmic Toolbox] by Tim Roughgarden and Gregory Valiant at Stanford.&lt;br /&gt;
* [https://www.cs.princeton.edu/courses/archive/fall18/cos521/ Advanced Algorithm Design] by Pravesh Kothari and Christopher Musco at Princeton.&lt;br /&gt;
* [http://www.cs.cmu.edu/afs/cs.cmu.edu/academic/class/15859-f11/www/ Linear and Semidefinite Programming (Advanced Algorithms)] by Anupam Gupta and Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://www.cs.cmu.edu/~odonnell/papers/cs-theory-toolkit-lecture-notes.pdf CS Theory Toolkit] by Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://cs.uwaterloo.ca/~lapchi/cs860/index.html Eigenvalues and Polynomials] by Lap Chi Lau at University of Waterloo.&lt;br /&gt;
* The [https://www.cs.cornell.edu/jeh/book.pdf &amp;quot;Foundations of Data Science&amp;quot; book] by Avrim Blum, John Hopcroft, and Ravindran Kannan.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13306</id>
		<title>General Circulation(Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13306"/>
		<updated>2025-10-12T09:26:02Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Assignments */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = 大气环流 &amp;lt;br&amp;gt;&lt;br /&gt;
General Circulation of the Atmosphere&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 张洋&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yangzhang@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 仙林大气楼 B410&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = 周一 下午 2:00-4:00，仙II-110&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = 周五 下午13:00-2:00 &amp;lt;br&amp;gt;仙林大气楼B410 &lt;br /&gt;
|header9 = Reference book&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:James-Circulating.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = Introduction to Circulating Atmospheres, &amp;lt;br&amp;gt;&#039;&#039;I. James&#039;&#039;, Cambridge Press, 1995&lt;br /&gt;
|captionstyle = }}&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:Oort.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Physics of Climate, &#039;&#039;Peixoto, J. P.&#039;&#039; and &#039;&#039;A. H. Oort&#039;&#039;,  Springer-Verlag New York, 1992&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:geoff.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation, &#039;&#039;Vallis, G. K.&#039;&#039;, Cambridge University Press, 2006&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the page for the class &#039;&#039;General Circulation of the Atmosphere (大气环流)&#039;&#039; for the Fall 2025 semester. Students who take this class should check this page periodically for content updates and new announcements.&lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* 课程交流QQ群：631262169，请各位选课的同学入群。【2025.9.8】&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 张洋，&lt;br /&gt;
:*office: 仙林气象楼 B410&lt;br /&gt;
:*email: yangzhang@nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: 周一 下午 2:00-4:00；仙II-110&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: 周五 &amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;gt;下午1:00-2:00，仙林大气楼B410&amp;lt;/font&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Prerequisites&#039;&#039;&#039;: 动力气象，天气学，气候学&lt;br /&gt;
* &#039;&#039;&#039;Grading&#039;&#039;&#039;: 平时作业（50％）＋ 期末考试（50％）&lt;br /&gt;
本课程将大致布置4次作业，每次作业一二道题目左右。题目将选择每个课题最具有代表性、需要一定思维强度和动手能力的训练用题目,意在使学生通过顺利完成作业来建立环流系统的物理模型、以对课程内容得到深刻全面地理解和掌握。期末考试题目数量将会比平时作业多,覆盖面更广,但会比作业题目简单,只涉及对基本内容的掌握和对环流理论的直接应用。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
# [[Assignment 1, Fall 2025|Reanalysis data and the earth&#039;s climatology]] [Due:2025.10.13]&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;1.5&amp;quot;&amp;gt;请在本次作业的截止日期前将本次作业的图片部分和文字部分打包作为附件发送至邮箱 circulation_nju@126.com &amp;lt;/font&amp;gt;&lt;br /&gt;
# [[Assignment 2, Fall 2025|Simple energy balance climate model]][Due:2025.10.27]&lt;br /&gt;
&lt;br /&gt;
= Course intro =&lt;br /&gt;
“大气环流”常指地球大气较大空间范围、较长时间尺度上的空气流动，及其对地球大气热量、动量、能量和水汽的全球输送。虽然从十七、十八世纪起人们就开始研究大尺度的大气运动(如Hadley在1735年提出的信风理论)，但大气环流真正发展成为一门较完备的学科方向却是近半个世纪的事情。随着四五十年代探空资料等高空气象要素的取得，以及六十年代卫星等覆盖全球的观测资料的加入，大气环流的空间结构和时间变化开始被系统、全面地揭示。与此同时，大气环流的数值模拟，也开始成为研究大气环流的一个主要方法，并发展至今成为了解和预估未来气候变化的主要手段。随着观测和模拟手段的进步，大气环流的理论研究也在近三十年开始快速地发展，人们对各种环流系统的维持和变化有了更全面、更深刻、也更为现代的理解。&lt;br /&gt;
&lt;br /&gt;
现代的大气环流是大气动力学、天气学和气候学相结合的产物。大气环流，既是各种天气现象产生的背景流场，又是各种气候状态形成的动力机制。大气环流在低频、季节、年际、年代际等时间尺度的变化，不但会引起天气现象的变化，也影响着气候状态的形成。而在大气科学领域面临着诸如全球暖化、气候变化、环流异常等重大科学问题的今天，大气环流研究的重要性被推到了前所未有的高度,大气环流也成为活跃发展又充满挑战的学科方向。&lt;br /&gt;
&lt;br /&gt;
本课程将讲述在过去几十年里大气环流在观测、理论和模拟上取得的进展。希望学生借此课程能熟悉大气环流的基本分布和形态，掌握各主要环流系统的维持和变化机制，建立各环流系统形成的物理模型，了解现阶段的大气环流模式，知道大气环流方向有待解决的科学问题。&lt;br /&gt;
&lt;br /&gt;
作为一门课程，大气环流内容的讲述常可以有两条线索。一条是全球尺度上大气热量、动量、能量和水汽的分布与输送，Lorenz（1967）和 Peixoto and Oort（1992）是按此线索介绍大气环流的优秀教材；另一条线索，是各纬度、各区域内大气环流系统的形成、维持和变化机制，James（1995）和 Vallis（2006）是按此线索介绍大气环流的经典讲义。根据现阶段大气环流方向的研究特点，本课程的讲述将主要按照后一种方式来展开，并辅以介绍各环流系统对大气各要素场的输送。在介绍各环流系统时，本课程将以观测、理论和模拟为顺序，从各大气环流系统的观测事实入手，介绍大气环流系统的分布特征和时空变化特征；着重介绍关于环流系统的各种动力学模型和现阶段对环流系统的理解；辅以对环流系统模拟研究的介绍；最后通过三者的对比，讨论各环流系统有待研究的问题。&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
本课程具体的内容安排如下：第一章为大气环流的概述，介绍大气环流发展的历史、包含的内容以及大气环流研究的常用观测资料和分析方法。第二章介绍大气环流产生的外部强迫：辐射强迫和下界面过程。第三至六章介绍大气环流中的各个环流系统及它们的动力机制。第七章详细介绍各复杂度的大气环流模式。第八章介绍大气环流领域现阶段最大的一个开放课题：全球暖化背景下的大气环流。这一章既是对前几章所介绍的大气环流理论的应用与检验，又是对未来大气环流研究方向的探讨。借此让学生熟悉并理解大气环流领域亟需解决的课题。具体课程安排和参考书目如下。&lt;br /&gt;
== Course schedule ==&lt;br /&gt;
*大气环流概述 (Introduction) （6课时）&lt;br /&gt;
*大气环流的外部强迫（3课时）&lt;br /&gt;
**辐射强迫 (Radiative forcing)&lt;br /&gt;
**下界面过程 (Surface boundaries)&lt;br /&gt;
*经向环流系统 (Zonally-averaged circulations)&lt;br /&gt;
**Hadley 环流（4课时）&lt;br /&gt;
**Ferrel 环流，急流，中纬度的波流相互作用（8课时）&lt;br /&gt;
*纬向环流系统（Non-zonal circulations）（6课时）&lt;br /&gt;
**Storm tracks&lt;br /&gt;
**Monsoon&lt;br /&gt;
**ENSO and Walker circulation&lt;br /&gt;
*能量和水汽循环 (Angular momentum, energy and water vapor)（2课时）&lt;br /&gt;
*不同复杂度的大气环流模式 (General circulation in a hierarchy of models)（2课时）&lt;br /&gt;
*全球暖化背景下的大气环流 (General circulation in the global warming scenario)（2课时）&lt;br /&gt;
&lt;br /&gt;
[[点击此处看详细课程安排 (click for more)]]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
*观测部分：Peixoto, J. P. and A. H. Oort, 1992: Physics of Climate. Springer-Verlag New York, Inc., 520 pp. 中文译本：气候物理学，1995，吴国雄、刘辉等译校，气象出版社。&lt;br /&gt;
*综合介绍：James, I., 1995: Introduction to circulating atmospheres. Cambridge University Press, 448 pp. &lt;br /&gt;
*理论部分：Vallis, G. K., 2006: Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation. Cambridge University Press. 745 pp.&lt;br /&gt;
* [[其它参考书目（点击看详情）]]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)/Dimension_Reduction&amp;diff=13304</id>
		<title>高级算法 (Fall 2025)/Dimension Reduction</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)/Dimension_Reduction&amp;diff=13304"/>
		<updated>2025-09-29T03:45:17Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;= Metric Embedding= A &amp;#039;&amp;#039;&amp;#039;metric space&amp;#039;&amp;#039;&amp;#039; is a pair &amp;lt;math&amp;gt;(X,d)&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; is a set and &amp;lt;math&amp;gt;d&amp;lt;/math&amp;gt; is a &amp;#039;&amp;#039;&amp;#039;metric&amp;#039;&amp;#039;&amp;#039; (or &amp;#039;&amp;#039;&amp;#039;distance&amp;#039;&amp;#039;&amp;#039;) on &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;, i.e., a function :&amp;lt;math&amp;gt;d:X^2\to\mathbb{R}_{\ge 0}&amp;lt;/math&amp;gt;  such that for any &amp;lt;math&amp;gt;x,y,z\in X&amp;lt;/math&amp;gt;, the following axioms hold: # (identity of indiscernibles) &amp;lt;math&amp;gt;d(x,y)=0\Leftrightarrow x=y&amp;lt;/math&amp;gt; # (symmetry) &amp;lt;math&amp;gt;d(x,y)=d(y,x)&amp;lt;/math&amp;gt; # (triangle inequality) &amp;lt;math&amp;gt;d(x,z)\le d(x,y)+d(y,z)&amp;lt;/ma...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Metric Embedding=&lt;br /&gt;
A &#039;&#039;&#039;metric space&#039;&#039;&#039; is a pair &amp;lt;math&amp;gt;(X,d)&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; is a set and &amp;lt;math&amp;gt;d&amp;lt;/math&amp;gt; is a &#039;&#039;&#039;metric&#039;&#039;&#039; (or &#039;&#039;&#039;distance&#039;&#039;&#039;) on &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt;, i.e., a function&lt;br /&gt;
:&amp;lt;math&amp;gt;d:X^2\to\mathbb{R}_{\ge 0}&amp;lt;/math&amp;gt; &lt;br /&gt;
such that for any &amp;lt;math&amp;gt;x,y,z\in X&amp;lt;/math&amp;gt;, the following axioms hold:&lt;br /&gt;
# (identity of indiscernibles) &amp;lt;math&amp;gt;d(x,y)=0\Leftrightarrow x=y&amp;lt;/math&amp;gt;&lt;br /&gt;
# (symmetry) &amp;lt;math&amp;gt;d(x,y)=d(y,x)&amp;lt;/math&amp;gt;&lt;br /&gt;
# (triangle inequality) &amp;lt;math&amp;gt;d(x,z)\le d(x,y)+d(y,z)&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;(X,d_X)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;(Y,d_Y)&amp;lt;/math&amp;gt; be two metric spaces. A mapping&lt;br /&gt;
:&amp;lt;math&amp;gt;\phi:X\to Y&amp;lt;/math&amp;gt;&lt;br /&gt;
is called an &#039;&#039;&#039;embedding&#039;&#039;&#039; of metric space &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; into &amp;lt;math&amp;gt;Y&amp;lt;/math&amp;gt;. The embedding is said to be with &#039;&#039;&#039;distortion&#039;&#039;&#039;  &amp;lt;math&amp;gt;\alpha\ge1&amp;lt;/math&amp;gt; if for any &amp;lt;math&amp;gt;x,y\in X&amp;lt;/math&amp;gt; it holds that&lt;br /&gt;
:&amp;lt;math&amp;gt;\frac{1}{\alpha}\cdot d(x,y)\le d(\phi(x),\phi(y))\le \alpha\cdot d(x,y)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
In Computer Science, a typical scenario for the metric embedding is as follows. We want to solve some difficult computation problem on a metric space &amp;lt;math&amp;gt;(X,d)&amp;lt;/math&amp;gt;. Instead of solving this problem directly on the original metric space, we embed the metric into a new metric space &amp;lt;math&amp;gt;(Y,d_Y)&amp;lt;/math&amp;gt; (with low distortion) where the computation problem is much easier to solve.&lt;br /&gt;
&lt;br /&gt;
One particular important case for the metric embedding is to embed a high-dimensional metric space to a new metric space whose dimension is much lower. This is called dimension reduction. This can be very helpful because various very common computation tasks can be very hard to solve on high-dimensional space due to the [https://en.wikipedia.org/wiki/Curse_of_dimensionality curse of dimensionality].&lt;br /&gt;
&lt;br /&gt;
= The Johnson-Lindenstrauss Theorem =&lt;br /&gt;
The &#039;&#039;&#039;Johnson-Lindenstrauss Theorem&#039;&#039;&#039; or &#039;&#039;&#039;Johnson-Lindenstrauss Transformation&#039;&#039;&#039; (both shorten as &#039;&#039;&#039;JLT&#039;&#039;&#039;) is a fundamental result for dimension reduction in Euclidian space.&lt;br /&gt;
&lt;br /&gt;
Recall that in Euclidian space &amp;lt;math&amp;gt;\mathbf{R}^d&amp;lt;/math&amp;gt;, for any two points &amp;lt;math&amp;gt;x,y\in\mathbf{R}^d&amp;lt;/math&amp;gt;, the Euclidian distance between them is given by &amp;lt;math&amp;gt;\|x-y\|=\sqrt{(x_1-y_1)^2+(x_2-y_2)^2+\cdots +(x_d-y_d)^2}&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;\|\cdot\|=\|\cdot\|_2&amp;lt;/math&amp;gt; denotes the Euclidian norm (a.k.a. the &amp;lt;math&amp;gt;\ell_2&amp;lt;/math&amp;gt;-norm).&lt;br /&gt;
&lt;br /&gt;
The JLT says that in Euclidian space, it is always possible to embed a set of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; points in &#039;&#039;arbitrary&#039;&#039; dimension to &amp;lt;math&amp;gt;O(\log n)&amp;lt;/math&amp;gt; dimension with constant distortion. The theorem itself is stated formally as follows.&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Johnson-Lindenstrauss Theorem, 1984|&lt;br /&gt;
:For any &amp;lt;math&amp;gt;0&amp;lt;\epsilon&amp;lt;1/2&amp;lt;/math&amp;gt; and any positive integer &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, there is a positive integer &amp;lt;math&amp;gt;k=O(\epsilon^{-2}\log n)&amp;lt;/math&amp;gt; such that the following holds:&lt;br /&gt;
:For any set &amp;lt;math&amp;gt;S\subset\mathbf{R}^d&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;|S|=n&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;d&amp;lt;/math&amp;gt; is arbitrary, there is an embedding &amp;lt;math&amp;gt;\phi:\mathbf{R}^d\rightarrow\mathbf{R}^k&amp;lt;/math&amp;gt; such that&lt;br /&gt;
::&amp;lt;math&amp;gt;\forall x,y\in S,\quad (1-\epsilon)\|x-y\|^2\le\|\phi(x)-\phi(y)\|^2\le(1+\epsilon)\|x-y\|^2&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The Johnson-Lindenstrauss Theorem is usually stated for the &amp;lt;math&amp;gt;\ell_2^2&amp;lt;/math&amp;gt;-norm &amp;lt;math&amp;gt;\|\cdot\|^2&amp;lt;/math&amp;gt; instead of the Euclidian norm &amp;lt;math&amp;gt;\|\cdot\|&amp;lt;/math&amp;gt; itself. Note that this does not change anything other than the constant faction in &amp;lt;math&amp;gt;k=O(\epsilon^{-2}\log n)&amp;lt;/math&amp;gt; because &amp;lt;math&amp;gt;(1\pm\epsilon)^{\frac{1}{2}}=1\pm\Theta(\epsilon)&amp;lt;/math&amp;gt;. The reason for stating the theorem in &amp;lt;math&amp;gt;\ell_2^2&amp;lt;/math&amp;gt;-norm is because &amp;lt;math&amp;gt;\|\cdot\|^2&amp;lt;/math&amp;gt; is a sum (rather than a square root) which is easier to analyze.&lt;br /&gt;
&lt;br /&gt;
In fact, the embedding &amp;lt;math&amp;gt;\phi:\mathbf{R}^d\rightarrow\mathbf{R}^k&amp;lt;/math&amp;gt; can be as simple as a linear transformation &amp;lt;math&amp;gt;A\in\mathbf{R}^{k\times d}&amp;lt;/math&amp;gt; so that &amp;lt;math&amp;gt;\phi(x)=Ax&amp;lt;/math&amp;gt; for any &amp;lt;math&amp;gt;x\in\mathbf{R}^{d}&amp;lt;/math&amp;gt;.&lt;br /&gt;
Therefore, the above theorem can be stated more precisely as follows.&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Johnson-Lindenstrauss Theorem (linear embedding)|&lt;br /&gt;
:For any &amp;lt;math&amp;gt;0&amp;lt;\epsilon&amp;lt;1/2&amp;lt;/math&amp;gt; and any positive integer &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt;, there is a positive integer &amp;lt;math&amp;gt;k=O(\epsilon^{-2}\log n)&amp;lt;/math&amp;gt; such that the following holds:&lt;br /&gt;
:For any set &amp;lt;math&amp;gt;S\subset\mathbf{R}^d&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;|S|=n&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;d&amp;lt;/math&amp;gt; is arbitrary, there is a linear transformation &amp;lt;math&amp;gt;A\in\mathbf{R}^{k\times d}&amp;lt;/math&amp;gt; such that&lt;br /&gt;
::&amp;lt;math&amp;gt;\forall x,y\in S,\quad (1-\epsilon)\|x-y\|^2\le\|Ax-Ay\|^2\le(1+\epsilon)\|x-y\|^2&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
The theorem is proved by the probabilistic method. Specifically, we construct a random matrix &amp;lt;math&amp;gt;A\in\mathbf{R}^{k\times d}&amp;lt;/math&amp;gt; and show that with high probability (&amp;lt;math&amp;gt;1-O(1/n)&amp;lt;/math&amp;gt;) it is a good embedding satisfying:&lt;br /&gt;
:&amp;lt;math&amp;gt;\forall x,y\in S,\quad (1-\epsilon)\|x-y\|\le\|Ax-Ay\|\le(1+\epsilon)\|x-y\|&amp;lt;/math&amp;gt;.&lt;br /&gt;
Therefore, if such random matrix &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; is efficient to construct, it immediately gives us an efficient randomized algorithm for dimension reduction in the Euclidian space.&lt;br /&gt;
&lt;br /&gt;
There are several such constructions of the random matrix &amp;lt;math&amp;gt;A\in\mathbf{R}^{k\times d}&amp;lt;/math&amp;gt;, including:&lt;br /&gt;
* projection onto uniform random &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt;-dimensional subspace of &amp;lt;math&amp;gt;\mathbf{R}^{d}&amp;lt;/math&amp;gt;; (the original construction of Johnson and Lindenstrauss in 1984; a simplified analysis due to [https://cseweb.ucsd.edu/~dasgupta/papers/jl.pdf Dasgupta and Gupta in 1999])&lt;br /&gt;
* random matrix with i.i.d. Gaussian entries; (due to [https://www.cs.princeton.edu/courses/archive/spr04/cos598B/bib/IndykM-curse.pdf Indyk and Motwani in 1998])&lt;br /&gt;
* random matrix with i.i.d. -1/+1 entries; (due to [https://www.sciencedirect.com/science/article/pii/S0022000003000254?via%3Dihub#BIB8 Achlioptas in 2003])&lt;br /&gt;
&lt;br /&gt;
It was proved by [https://arxiv.org/abs/1609.02094 Kasper Green Larsen and Jelani Nelson in 2016] that the JLT is optimal: there is a set of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; points from &amp;lt;math&amp;gt;\mathbf{R}^d&amp;lt;/math&amp;gt; such that any embedding &amp;lt;math&amp;gt;\phi:\mathbf{R}^d\rightarrow\mathbf{R}^k&amp;lt;/math&amp;gt; having the distortion asserted in the JLT must have dimension &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; of the target space satisfy &amp;lt;math&amp;gt;k=\Omega(\epsilon^{-2}\log n)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
==JLT via Gaussian matrix==&lt;br /&gt;
Here we prove the Johnson-Lindenstrauss theorem with the second construction, by the random matrix &amp;lt;math&amp;gt;A\in\mathbf{R}^{k\times d}&amp;lt;/math&amp;gt; with i.i.d. Gaussian entries. The construction of &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; is very simple:&lt;br /&gt;
:{|border=&amp;quot;2&amp;quot; width=&amp;quot;100%&amp;quot; cellspacing=&amp;quot;4&amp;quot; cellpadding=&amp;quot;3&amp;quot; rules=&amp;quot;all&amp;quot; style=&amp;quot;margin:1em 1em 1em 0; border:solid 1px #AAAAAA; border-collapse:collapse;empty-cells:show;&amp;quot;&lt;br /&gt;
|&lt;br /&gt;
*Each entry of &amp;lt;math&amp;gt;A\in\mathbf{R}^{k\times d}&amp;lt;/math&amp;gt; is drawn independently from the Gaussian distribution &amp;lt;math&amp;gt;\mathcal{N}(0,1/k)&amp;lt;/math&amp;gt;.&lt;br /&gt;
|}&lt;br /&gt;
Recall that a [https://en.wikipedia.org/wiki/Normal_distribution Gaussian distribution] &amp;lt;math&amp;gt;\mathcal{N}(\mu,\sigma^2)&amp;lt;/math&amp;gt; is specified by its mean &amp;lt;math&amp;gt;\mu&amp;lt;/math&amp;gt; and standard deviation &amp;lt;math&amp;gt;\sigma&amp;lt;/math&amp;gt; such that for a random variable &amp;lt;math&amp;gt;X&amp;lt;/math&amp;gt; distributed as &amp;lt;math&amp;gt;\mathcal{N}(\mu,\sigma^2)&amp;lt;/math&amp;gt;, we have&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbf{E}[X]=\mu&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\mathbf{Var}[X]=\sigma^2&amp;lt;/math&amp;gt;,&lt;br /&gt;
and the probability density function is given by &amp;lt;math&amp;gt;p(x)=\frac{1}{\sqrt{2\pi\sigma^2}}\mathrm{e}^{-\frac{(x-\mu)^2}{2\sigma^2}}&amp;lt;/math&amp;gt;, therefore&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr[X\le t]=\int_{-\infty}^t\frac{1}{\sqrt{2\pi\sigma^2}}\mathrm{e}^{-\frac{(x-\mu)^2}{2\sigma^2}}\,\mathrm{d}x&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Fix any two points &amp;lt;math&amp;gt;x,y&amp;lt;/math&amp;gt; out of the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; points in &amp;lt;math&amp;gt;S\subset \mathbf{R}^d&amp;lt;/math&amp;gt;, if we can show that&lt;br /&gt;
:&amp;lt;math&amp;gt;\Pr\left[(1-\epsilon)\|x-y\|^2\le\|Ax-Ay\|^2\le(1+\epsilon)\|x-y\|^2\right]\ge 1-\frac{1}{n^3}&amp;lt;/math&amp;gt;,&lt;br /&gt;
then by the union bound, the following event&lt;br /&gt;
:&amp;lt;math&amp;gt;\forall x,y\in S,\quad (1-\epsilon)\|x-y\|^2\le\|Ax-Ay\|^2\le(1+\epsilon)\|x-y\|^2&amp;lt;/math&amp;gt;&lt;br /&gt;
holds with probability &amp;lt;math&amp;gt;1-O(1/n)&amp;lt;/math&amp;gt;. The Johnson-Lindenstrauss theorem follows.&lt;br /&gt;
&lt;br /&gt;
Furthermore, dividing both sides of the inequalities &amp;lt;math&amp;gt;(1-\epsilon)\|x-y\|^2\le\|Ax-Ay\|^2\le(1+\epsilon)\|x-y\|^2&amp;lt;/math&amp;gt; by the factor &amp;lt;math&amp;gt;\|x-y\|^2&amp;lt;/math&amp;gt; gives us&lt;br /&gt;
:&amp;lt;math&amp;gt;(1-\epsilon)\le\frac{\|Ax-Ay\|^2}{\|x-y\|^2}=\left\|A\frac{(x-y)}{\|x-y\|^2}\right\|^2\le(1+\epsilon)&amp;lt;/math&amp;gt;,&lt;br /&gt;
where &amp;lt;math&amp;gt;\frac{(x-y)}{\|x-y\|^2}&amp;lt;/math&amp;gt; is a unit vector.&lt;br /&gt;
&lt;br /&gt;
Therefore, the Johnson-Lindenstrauss theorem is proved once the following theorem on the unit vector is proved.&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Theorem (JLT on unit vector)|&lt;br /&gt;
:For any positive &amp;lt;math&amp;gt;\epsilon,\delta&amp;lt;1/2&amp;lt;/math&amp;gt; there is a positive integer &amp;lt;math&amp;gt;k=O\left(\epsilon^{-2}\log \frac{1}{\delta}\right)&amp;lt;/math&amp;gt; such that for the random matrix &amp;lt;math&amp;gt;A\in\mathbf{R}^{k\times d}&amp;lt;/math&amp;gt; with each entry drawn independently from the Gaussian distribution &amp;lt;math&amp;gt;\mathcal{N}(0,1/k)&amp;lt;/math&amp;gt;, for any unit vector &amp;lt;math&amp;gt;u\in\mathbf{R}^d&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;\|u\|=1&amp;lt;/math&amp;gt;, &lt;br /&gt;
::&amp;lt;math&amp;gt;\Pr\left[\left|\|Au\|^2-1\right|&amp;gt;\epsilon\right]&amp;lt;\delta&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
For any &amp;lt;math&amp;gt;u\in\mathbf{R}^d&amp;lt;/math&amp;gt;, we have &amp;lt;math&amp;gt;\|Au\|^2=\sum_{i=1}^k(Au)_i^2&amp;lt;/math&amp;gt;, where the &amp;lt;math&amp;gt;(Au)_i&amp;lt;/math&amp;gt;&#039;s are independent of each other, because each &lt;br /&gt;
:&amp;lt;math&amp;gt;(Au)_i=\langle A_{i\cdot},u\rangle=\sum_{j=1}^dA_{ij}u_j&amp;lt;/math&amp;gt;&lt;br /&gt;
is determined by a distinct row vector &amp;lt;math&amp;gt;A_{i\cdot}&amp;lt;/math&amp;gt; of the matrix &amp;lt;math&amp;gt;A&amp;lt;/math&amp;gt; with independent entries. &lt;br /&gt;
&lt;br /&gt;
Moreover, since each entry &amp;lt;math&amp;gt;A_{ij}\sim\mathcal{N}(0,1/k)&amp;lt;/math&amp;gt; independently and recall that for any two independent Gaussian random variables &amp;lt;math&amp;gt;X_1\sim \mathcal{N}(\mu_1,\sigma_1^2)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;X_2\sim \mathcal{N}(\mu_2,\sigma_2^2)&amp;lt;/math&amp;gt;, their weighted sum &amp;lt;math&amp;gt;aX_1+bX_2&amp;lt;/math&amp;gt; follows the Gaussian distribution &amp;lt;math&amp;gt;\mathcal{N}(a\mu_1+b\mu_2,a^2\sigma_1^2+b^2\sigma_2^2)&amp;lt;/math&amp;gt;, therefore &amp;lt;math&amp;gt;(Au)_i=\langle A_{i\cdot},u\rangle=\sum_{j=1}^dA_{ij}u_j&amp;lt;/math&amp;gt; follows the Gaussian distribution&lt;br /&gt;
:&amp;lt;math&amp;gt;(Au)_i\sim\mathcal{N}\left(0,\sum_{j=1}^d\frac{u_j^2}{k}\right)&amp;lt;/math&amp;gt;,&lt;br /&gt;
which is precisely &amp;lt;math&amp;gt;\mathcal{N}\left(0,\frac{1}{k}\right)&amp;lt;/math&amp;gt; if &amp;lt;math&amp;gt;u\in\mathbf{R}^d&amp;lt;/math&amp;gt; is a unit vector, i.e. &amp;lt;math&amp;gt;\|u\|^2=\sum_{j=1}^du_j^2=1&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
In summary, the random variable &amp;lt;math&amp;gt;\|Au\|^2&amp;lt;/math&amp;gt; that we are interested in, can be represented as a sum-of-square form&lt;br /&gt;
:&amp;lt;math&amp;gt;\|Au\|^2=\sum_{i=1}^kY_i^2&amp;lt;/math&amp;gt;,&lt;br /&gt;
where each &amp;lt;math&amp;gt;Y_i=(Au)_i&amp;lt;/math&amp;gt; independently follows the Gaussian distribution &amp;lt;math&amp;gt;\mathcal{N}\left(0,\frac{1}{k}\right)&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
==Concentration of &amp;lt;math&amp;gt;\chi^2&amp;lt;/math&amp;gt;-distribution ==&lt;br /&gt;
By the above argument, the Johnson-Lindenstrauss theorem is proved by the following concentration inequality for the sum of the squares of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; Gaussian distributions.&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Chernoff bound for sum-of-squares of Gaussian distributions|&lt;br /&gt;
:For any positive &amp;lt;math&amp;gt;\epsilon,\delta&amp;lt;1/2&amp;lt;/math&amp;gt; there is a positive integer &amp;lt;math&amp;gt;k=O\left(\epsilon^{-2}\log \frac{1}{\delta}\right)&amp;lt;/math&amp;gt; such that for i.i.d. Gaussian random variables &amp;lt;math&amp;gt;Y_1,Y_2,\ldots,Y_k\sim\mathcal{N}(0,1/k)&amp;lt;/math&amp;gt;, &lt;br /&gt;
::&amp;lt;math&amp;gt;\Pr\left[\left|\sum_{i=1}^kY_i^2-1\right|&amp;gt;\epsilon\right]&amp;lt;\delta&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
First, we see that this is indeed a concentration inequality that bounds the deviation of a random variable from its mean.&lt;br /&gt;
&lt;br /&gt;
For each &amp;lt;math&amp;gt;Y_i\sim\mathcal{N}\left(0,\frac{1}{k}\right)&amp;lt;/math&amp;gt;, we know that &amp;lt;math&amp;gt;\mathbf{E}[Y_i]=0&amp;lt;/math&amp;gt; and  &amp;lt;math&amp;gt;\mathbf{Var}[Y_i]=\mathbf{E}[Y_i^2]-\mathbf{E}[Y_i]^2=\frac{1}{k}&amp;lt;/math&amp;gt;, thus&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbf{E}[Y_i^2]=\mathbf{Var}[Y_i]+\mathbf{E}[Y_i]^2=\frac{1}{k}&amp;lt;/math&amp;gt;.&lt;br /&gt;
By linearity of expectation, it holds that&lt;br /&gt;
:&amp;lt;math&amp;gt;\mathbf{E}\left[\sum_{i=1}^kY_i^2\right]=\sum_{i=1}^k\mathbf{E}\left[Y_i^2\right]=1&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
We prove an equivalent concentration bound stated for the [https://en.wikipedia.org/wiki/Chi-squared_distribution &#039;&#039;&#039;&amp;lt;math&amp;gt;\chi^2&amp;lt;/math&amp;gt;-distribution&#039;&#039;&#039;] (sum of the squares of &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; &#039;&#039;&#039;standard&#039;&#039;&#039; Gaussian distributions).&lt;br /&gt;
&lt;br /&gt;
{{Theorem&lt;br /&gt;
|Chernoff bound for the &amp;lt;math&amp;gt;\chi^2&amp;lt;/math&amp;gt;-distribution|&lt;br /&gt;
:For i.i.d. standard Gaussian random variables &amp;lt;math&amp;gt;X_1,X_2,\ldots,X_k\sim\mathcal{N}(0,1)&amp;lt;/math&amp;gt;, for &amp;lt;math&amp;gt;0&amp;lt;\epsilon&amp;lt;1&amp;lt;/math&amp;gt;,&lt;br /&gt;
:*&amp;lt;math&amp;gt;\Pr\left[\sum_{i=1}^kX_i^2&amp;gt;(1+\epsilon)k\right]&amp;lt;\mathrm{e}^{-\epsilon^2k/8}&amp;lt;/math&amp;gt;,&lt;br /&gt;
:*&amp;lt;math&amp;gt;\Pr\left[\sum_{i=1}^kX_i^2&amp;lt;(1-\epsilon)k\right]&amp;lt;\mathrm{e}^{-\epsilon^2k/8}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Note that this indeed implies the above concentration bound by setting &amp;lt;math&amp;gt;X_i=\sqrt{k}\cdot Y_i&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;\delta\ge\mathrm{e}^{-\epsilon^2k/8}&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{Proof|&lt;br /&gt;
We first prove the upper tail. Let &amp;lt;math&amp;gt;\lambda&amp;gt;0&amp;lt;/math&amp;gt; be a parameter to be determined.&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr\left[\sum_{i=1}^kX_i^2&amp;gt;(1+\epsilon)k\right]&lt;br /&gt;
&amp;amp;=\Pr\left[\mathrm{e}^{\lambda \sum_{i=1}^kX_i^2}&amp;gt;\mathrm{e}^{(1+\epsilon)\lambda k}\right]\\&lt;br /&gt;
&amp;amp;&amp;lt; \mathrm{e}^{-(1+\epsilon)\lambda k}\cdot \mathbf{E}\left[\mathrm{e}^{\lambda \sum_{i=1}^kX_i^2}\right] &amp;amp;&amp;amp; \text{(Markov&#039;s inequality)}\\&lt;br /&gt;
&amp;amp;= \mathrm{e}^{-(1+\epsilon)\lambda k}\cdot \prod_{i=1}^k \mathbf{E}\left[\mathrm{e}^{\lambda X_i^2}\right]. &amp;amp;&amp;amp; \text{(independence)}&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
{{Theorem|Proposition|&lt;br /&gt;
:For standard Gaussian &amp;lt;math&amp;gt;X\sim\mathcal{N}(0,1)&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;\mathbf{E}\left[\mathrm{e}^{\lambda X^2}\right]=\frac{1}{\sqrt{1-2\lambda}}&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
{{Proof|&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\mathbf{E}\left[\mathrm{e}^{\lambda X^2}\right]&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty}\mathrm{e}^{\lambda x^2}\mathrm{e}^{-x^2/2}\,\mathrm{d}x\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty}\mathrm{e}^{-(1-2\lambda)x^2/2}\,\mathrm{d}x\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\frac{1}{\sqrt{1-2\lambda}}\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty}\mathrm{e}^{-y^2/2}\,\mathrm{d}y &amp;amp;&amp;amp;(\text{set }y=\sqrt{1-2\lambda}x)\\&lt;br /&gt;
&amp;amp;=\frac{1}{\sqrt{1-2\lambda}}.&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
The last equation is because &amp;lt;math&amp;gt;\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty}\mathrm{e}^{-y^2/2}\,\mathrm{d}y&amp;lt;/math&amp;gt; is the total probability mass of a standard Gaussian distribution (which is obviously 1).&lt;br /&gt;
}}&lt;br /&gt;
Then continue the above calculation:&lt;br /&gt;
:&amp;lt;math&amp;gt;&lt;br /&gt;
\begin{align}&lt;br /&gt;
\Pr\left[\sum_{i=1}^kX_i^2&amp;gt;(1+\epsilon)k\right]&lt;br /&gt;
&amp;amp;&amp;lt; &lt;br /&gt;
\mathrm{e}^{-(1+\epsilon)\lambda k}\cdot \left(\frac{1}{\sqrt{1-2\lambda}}\right)^k\\&lt;br /&gt;
&amp;amp;= &lt;br /&gt;
\mathrm{e}^{-\epsilon\lambda k}\cdot \left(\frac{\mathrm{e}^{-\lambda}}{\sqrt{1-2\lambda}}\right)^k\\&lt;br /&gt;
&amp;amp;\le &lt;br /&gt;
\mathrm{e}^{-\epsilon\lambda k + 2\lambda^2 k} &amp;amp;&amp;amp; (\text{for }\lambda&amp;lt;1/4)\\&lt;br /&gt;
&amp;amp;=&lt;br /&gt;
\mathrm{e}^{-\epsilon k/8}. &amp;amp;&amp;amp; (\text{by setting the stationary point }\lambda=\epsilon/4)&lt;br /&gt;
\end{align}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
This proved the upper tail. The lower tail can be symmetrically proved by optimizing over a parameter &amp;lt;math&amp;gt;\lambda&amp;lt;0&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
As we argued above, this finishes the proof of the Johnson-Lindenstrauss Theorem.&lt;br /&gt;
&lt;br /&gt;
= Nearest Neighbor Search (NNS)=&lt;br /&gt;
{{Theorem|Nearest Neighbor Search (NNS)|&lt;br /&gt;
*&#039;&#039;&#039;Data&#039;&#039;&#039;: a set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; points &amp;lt;math&amp;gt;y_1,y_2,\ldots,y_n\in X&amp;lt;/math&amp;gt; from a metric space &amp;lt;math&amp;gt;(X,\mathrm{dist})&amp;lt;/math&amp;gt;; &lt;br /&gt;
*&#039;&#039;&#039;Query&#039;&#039;&#039;: a point &amp;lt;math&amp;gt;x\in X&amp;lt;/math&amp;gt;;&lt;br /&gt;
*&#039;&#039;&#039;Answer&#039;&#039;&#039;: a nearest neighbor of the query point &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; among all data points, i.e. a data point &amp;lt;math&amp;gt;y_{i^*}\in S&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;\mathrm{dist}(x,y_{i^*})=\min_{y_i\in S}\mathrm{dist}(x,y_i)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Theorem|&amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt;-ANN (Approximate Nearest Neighbor)|&lt;br /&gt;
:&amp;lt;math&amp;gt;c&amp;gt;1&amp;lt;/math&amp;gt; is an approximate ratio.&lt;br /&gt;
*&#039;&#039;&#039;Data&#039;&#039;&#039;: a set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; points &amp;lt;math&amp;gt;y_1,y_2,\ldots,y_n\in X&amp;lt;/math&amp;gt; from a metric space &amp;lt;math&amp;gt;(X,\mathrm{dist})&amp;lt;/math&amp;gt;; &lt;br /&gt;
*&#039;&#039;&#039;Query&#039;&#039;&#039;: a point &amp;lt;math&amp;gt;x\in X&amp;lt;/math&amp;gt;;&lt;br /&gt;
*&#039;&#039;&#039;Answer&#039;&#039;&#039;: a &amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt;-approximate nearest neighbor of the query point &amp;lt;math&amp;gt;x&amp;lt;/math&amp;gt; among all data points, i.e. a data point &amp;lt;math&amp;gt;y_{i^*}\in S&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;\mathrm{dist}(x,y_{i^*})\le c\, \min_{y_i\in S}\mathrm{dist}(x,y_i)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Theorem|&amp;lt;math&amp;gt;(c,r)&amp;lt;/math&amp;gt;-ANN (Approximate &#039;&#039;Near&#039;&#039; Neighbor)|&lt;br /&gt;
:&amp;lt;math&amp;gt;c&amp;gt;1&amp;lt;/math&amp;gt; is an approximate ratio; &amp;lt;math&amp;gt;r&amp;gt;0&amp;lt;/math&amp;gt; is a radius;&lt;br /&gt;
*&#039;&#039;&#039;Data&#039;&#039;&#039;: a set &amp;lt;math&amp;gt;S&amp;lt;/math&amp;gt; of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; points &amp;lt;math&amp;gt;y_1,y_2,\ldots,y_n\in X&amp;lt;/math&amp;gt; from a metric space &amp;lt;math&amp;gt;(X,\mathrm{dist})&amp;lt;/math&amp;gt;; &lt;br /&gt;
*&#039;&#039;&#039;Query&#039;&#039;&#039;: a point &amp;lt;math&amp;gt;x\in X&amp;lt;/math&amp;gt;;&lt;br /&gt;
*&#039;&#039;&#039;Answer&#039;&#039;&#039;: &amp;lt;math&amp;gt;&lt;br /&gt;
\begin{cases}&lt;br /&gt;
\text{a data point }y_{i^*}\in S\text{ such that }\mathrm{dist}(x,y_{i^*})\le c\cdot r &amp;amp; \text{if }\exists y_i\in S,  \mathrm{dist}(x,y_{i})\le r,\\&lt;br /&gt;
\bot &amp;amp; \text{if }\forall y_i\in S, \mathrm{dist}(x,y_{i})&amp;gt;c\cdot r,\\&lt;br /&gt;
\text{arbitrary} &amp;amp; \text{otherwise}.&lt;br /&gt;
\end{cases}&lt;br /&gt;
&amp;lt;/math&amp;gt;&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{Theorem|Theorem|&lt;br /&gt;
:For any instance &amp;lt;math&amp;gt;S=\{y_1,y_2,\ldots,y_n\}&amp;lt;/math&amp;gt; of the nearest neighbor problem, let &amp;lt;math&amp;gt;D_{\min}\triangleq\min_{y_i,y_j\in S}\mathrm{dist}(y_i,y_j)&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;D_{\max}\triangleq\max_{y_i,y_j\in S}\mathrm{dist}(y_i,y_j)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;R\triangleq \frac{D_{\max}}{D_{\min}}&amp;lt;/math&amp;gt;. &lt;br /&gt;
:Suppose that for any &amp;lt;math&amp;gt;r&amp;gt;0&amp;lt;/math&amp;gt; there always exists a data structure for the &amp;lt;math&amp;gt;(c,r)&amp;lt;/math&amp;gt;-ANN problem, using space at most &amp;lt;math&amp;gt;s&amp;lt;/math&amp;gt;, answering each query in time &amp;lt;math&amp;gt;t&amp;lt;/math&amp;gt;, correctly with probability &amp;lt;math&amp;gt;1-\delta&amp;lt;/math&amp;gt;. &lt;br /&gt;
:Then there exists a data structure for the &amp;lt;math&amp;gt;c&amp;lt;/math&amp;gt;-ANN problem, using space &amp;lt;math&amp;gt;O(s\log_c R)&amp;lt;/math&amp;gt;, answering each query in time &amp;lt;math&amp;gt;O(t\log\log_c R)&amp;lt;/math&amp;gt;, correctly with probability &amp;lt;math&amp;gt;1-O(\delta\log\log_c R)&amp;lt;/math&amp;gt;.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Solving ANN by dimension reduction==&lt;br /&gt;
&lt;br /&gt;
= Locality-Sensitive Hashing (LSH)=&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13303</id>
		<title>高级算法 (Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13303"/>
		<updated>2025-09-29T03:44:50Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;高级算法 &lt;br /&gt;
&amp;lt;br&amp;gt;Advanced Algorithms&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;栗师&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = shili@nju.edu.cn &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7= office&lt;br /&gt;
|data7= 计算机系 605&lt;br /&gt;
|header8 = &lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header9 = &lt;br /&gt;
|label9  = Email&lt;br /&gt;
|data9   = liu@nju.edu.cn &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10= office&lt;br /&gt;
|data10= 计算机系 516&lt;br /&gt;
|header11 = Class&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = &lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = Class meetings&lt;br /&gt;
|data12   = Monday (单), 2pm-4pm &amp;lt;br&amp;gt; Thursday, 2pm-4pm &amp;lt;br&amp;gt;仙Ⅰ-320&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = Place&lt;br /&gt;
|data13   = &lt;br /&gt;
|header14 =&lt;br /&gt;
|label14  = Office hours&lt;br /&gt;
|data14   = TBD, &amp;lt;br&amp;gt;计算机系 804&amp;lt;br&amp;gt;&lt;br /&gt;
|header15 = Textbooks&lt;br /&gt;
|label15  = &lt;br /&gt;
|data15   = &lt;br /&gt;
|header16 =&lt;br /&gt;
|label16  = &lt;br /&gt;
|data16   = [[File:MR-randomized-algorithms.png|border|100px]]&lt;br /&gt;
|header17 =&lt;br /&gt;
|label17  = &lt;br /&gt;
|data17   = Motwani and Raghavan. &amp;lt;br&amp;gt;&#039;&#039;Randomized Algorithms&#039;&#039;.&amp;lt;br&amp;gt; Cambridge Univ Press, 1995.&lt;br /&gt;
|header18 =&lt;br /&gt;
|label18  = &lt;br /&gt;
|data18   = [[File:Approximation_Algorithms.jpg|border|100px]]&lt;br /&gt;
|header19 =&lt;br /&gt;
|label19  = &lt;br /&gt;
|data19   =  Vazirani. &amp;lt;br&amp;gt;&#039;&#039;Approximation Algorithms&#039;&#039;. &amp;lt;br&amp;gt; Springer-Verlag, 2001.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Advanced Algorithms&#039;&#039; class of fall 2025. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2025/9/10)&#039;&#039;&#039; 本周四（9月11日）课程时间地点不变，为第五、六节在仙I-320。从第四周（9月15日）开始，采用新的上课时间：每周一的第五、六节，以及双周四的第五、六节，地点仍在仙I-320。&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;（授课时间顺序）: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
:*[https://tcs.nju.edu.cn/shili/ 栗师]：[mailto:shili@nju.edu.cn &amp;lt;shili@nju.edu.cn&amp;gt;]，计算机系 605&lt;br /&gt;
* &#039;&#039;&#039;Teaching Assistant&#039;&#039;&#039;: &lt;br /&gt;
** 侯哲：houzhe@smail.nju.edu.cn&lt;br /&gt;
** 张弈垚：zhangyiyao@smail.nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: &lt;br /&gt;
** Monday (单), 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
** Thursday, 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: Wednesday 2pm-3pm, 计算机系 804&lt;br /&gt;
* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 524141453（加群请注明专业学号姓名）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
随着计算机算法理论的不断发展，现代计算机算法的设计与分析大量地使用非初等的数学工具以及非传统的算法思想。“高级算法”这门课程就是面向计算机算法的这一发展趋势而设立的。课程将针对传统算法课程未系统涉及、却在计算机科学各领域的科研和实践中扮演重要角色的高等算法设计思想和算法分析工具进行系统讲授。&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 必须：离散数学，概率论，线性代数。&lt;br /&gt;
* 推荐：算法设计与分析。&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[高级算法 (Fall 2025) / Course materials|&amp;lt;font size=3&amp;gt;教材和参考书&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
Late policy: In general, we will accomodate late submission requests ONLY IF you made such requests ahead of time. &lt;br /&gt;
&lt;br /&gt;
*[[高级算法 (Fall 2025)/Problem Set 1|Problem Set 1]]  请在 TBD前 提交到 [mailto:njuadvalg25@163.com njuadvalg25@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[高级算法 (Fall 2025)/Min Cut, Max Cut, and Spectral Cut|Min Cut, Max Cut, and Spectral Cut]] ([http://tcs.nju.edu.cn/slides/aa2025/Cut.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Probability Basics|Probability basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Fingerprinting| Fingerprinting]] ([http://tcs.nju.edu.cn/slides/aa2025/Fingerprinting.pdf slides]) &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Finite Field Basics|Finite field basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Hashing and Sketching|Hashing and Sketching]] ([http://tcs.nju.edu.cn/slides/aa2025/Hashing.pdf slides])   &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Limited independence|Limited independence]]&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Basic deviation inequalities|Basic deviation inequalities]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Concentration of measure|Concentration of measure]] ([http://tcs.nju.edu.cn/slides/aa2025/Concentration.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Conditional expectations|Conditional expectations]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Dimension Reduction|Dimension Reduction]] ([http://tcs.nju.edu.cn/slides/aa2025/NNS.pdf slides]) &lt;br /&gt;
#* [https://www.cs.princeton.edu/~hy2/teaching/fall22-cos521/notes/JL.pdf Professor Huacheng Yu&#039;s note on Johnson-Lindenstrauss Theorem]&lt;br /&gt;
#* [http://people.csail.mit.edu/gregory/annbook/introduction.pdf An introduction of LSH]&lt;br /&gt;
&lt;br /&gt;
= Related Online Courses=&lt;br /&gt;
* [https://www.cs.cmu.edu/~15850/ Advanced Algorithms] by Anupam Gupta at CMU.&lt;br /&gt;
* [http://people.csail.mit.edu/moitra/854.html Advanced Algorithms] by Ankur Moitra at MIT.&lt;br /&gt;
* [http://courses.csail.mit.edu/6.854/current/ Advanced Algorithms] by David Karger and Aleksander Mądry at MIT.&lt;br /&gt;
* [http://web.stanford.edu/class/cs168/index.html The Modern Algorithmic Toolbox] by Tim Roughgarden and Gregory Valiant at Stanford.&lt;br /&gt;
* [https://www.cs.princeton.edu/courses/archive/fall18/cos521/ Advanced Algorithm Design] by Pravesh Kothari and Christopher Musco at Princeton.&lt;br /&gt;
* [http://www.cs.cmu.edu/afs/cs.cmu.edu/academic/class/15859-f11/www/ Linear and Semidefinite Programming (Advanced Algorithms)] by Anupam Gupta and Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://www.cs.cmu.edu/~odonnell/papers/cs-theory-toolkit-lecture-notes.pdf CS Theory Toolkit] by Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://cs.uwaterloo.ca/~lapchi/cs860/index.html Eigenvalues and Polynomials] by Lap Chi Lau at University of Waterloo.&lt;br /&gt;
* The [https://www.cs.cornell.edu/jeh/book.pdf &amp;quot;Foundations of Data Science&amp;quot; book] by Avrim Blum, John Hopcroft, and Ravindran Kannan.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13302</id>
		<title>高级算法 (Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13302"/>
		<updated>2025-09-29T03:44:40Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Lecture Notes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;高级算法 &lt;br /&gt;
&amp;lt;br&amp;gt;Advanced Algorithms&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;栗师&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = shili@nju.edu.cn &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7= office&lt;br /&gt;
|data7= 计算机系 605&lt;br /&gt;
|header8 = &lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header9 = &lt;br /&gt;
|label9  = Email&lt;br /&gt;
|data9   = liu@nju.edu.cn &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10= office&lt;br /&gt;
|data10= 计算机系 516&lt;br /&gt;
|header11 = Class&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = &lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = Class meetings&lt;br /&gt;
|data12   = Monday (单), 2pm-4pm &amp;lt;br&amp;gt; Thursday, 2pm-4pm &amp;lt;br&amp;gt;仙Ⅰ-320&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = Place&lt;br /&gt;
|data13   = &lt;br /&gt;
|header14 =&lt;br /&gt;
|label14  = Office hours&lt;br /&gt;
|data14   = TBD, &amp;lt;br&amp;gt;计算机系 804&amp;lt;br&amp;gt;&lt;br /&gt;
|header15 = Textbooks&lt;br /&gt;
|label15  = &lt;br /&gt;
|data15   = &lt;br /&gt;
|header16 =&lt;br /&gt;
|label16  = &lt;br /&gt;
|data16   = [[File:MR-randomized-algorithms.png|border|100px]]&lt;br /&gt;
|header17 =&lt;br /&gt;
|label17  = &lt;br /&gt;
|data17   = Motwani and Raghavan. &amp;lt;br&amp;gt;&#039;&#039;Randomized Algorithms&#039;&#039;.&amp;lt;br&amp;gt; Cambridge Univ Press, 1995.&lt;br /&gt;
|header18 =&lt;br /&gt;
|label18  = &lt;br /&gt;
|data18   = [[File:Approximation_Algorithms.jpg|border|100px]]&lt;br /&gt;
|header19 =&lt;br /&gt;
|label19  = &lt;br /&gt;
|data19   =  Vazirani. &amp;lt;br&amp;gt;&#039;&#039;Approximation Algorithms&#039;&#039;. &amp;lt;br&amp;gt; Springer-Verlag, 2001.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Advanced Algorithms&#039;&#039; class of fall 2025. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2025/9/10)&#039;&#039;&#039; 本周四（9月11日）课程时间地点不变，为第五、六节在仙I-320。从第四周（9月15日）开始，采用新的上课时间：每周一的第五、六节，以及双周四的第五、六节，地点仍在仙I-320。&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;（授课时间顺序）: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
:*[https://tcs.nju.edu.cn/shili/ 栗师]：[mailto:shili@nju.edu.cn &amp;lt;shili@nju.edu.cn&amp;gt;]，计算机系 605&lt;br /&gt;
* &#039;&#039;&#039;Teaching Assistant&#039;&#039;&#039;: &lt;br /&gt;
** 侯哲：houzhe@smail.nju.edu.cn&lt;br /&gt;
** 张弈垚：zhangyiyao@smail.nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: &lt;br /&gt;
** Monday (单), 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
** Thursday, 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: Wednesday 2pm-3pm, 计算机系 804&lt;br /&gt;
* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 524141453（加群请注明专业学号姓名）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
随着计算机算法理论的不断发展，现代计算机算法的设计与分析大量地使用非初等的数学工具以及非传统的算法思想。“高级算法”这门课程就是面向计算机算法的这一发展趋势而设立的。课程将针对传统算法课程未系统涉及、却在计算机科学各领域的科研和实践中扮演重要角色的高等算法设计思想和算法分析工具进行系统讲授。&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 必须：离散数学，概率论，线性代数。&lt;br /&gt;
* 推荐：算法设计与分析。&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[高级算法 (Fall 2025) / Course materials|&amp;lt;font size=3&amp;gt;教材和参考书&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
Late policy: In general, we will accomodate late submission requests ONLY IF you made such requests ahead of time. &lt;br /&gt;
&lt;br /&gt;
*[[高级算法 (Fall 2025)/Problem Set 1|Problem Set 1]]  请在 TBD前 提交到 [mailto:njuadvalg25@163.com njuadvalg25@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[高级算法 (Fall 2025)/Min Cut, Max Cut, and Spectral Cut|Min Cut, Max Cut, and Spectral Cut]] ([http://tcs.nju.edu.cn/slides/aa2025/Cut.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Probability Basics|Probability basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Fingerprinting| Fingerprinting]] ([http://tcs.nju.edu.cn/slides/aa2025/Fingerprinting.pdf slides]) &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Finite Field Basics|Finite field basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Hashing and Sketching|Hashing and Sketching]] ([http://tcs.nju.edu.cn/slides/aa2025/Hashing.pdf slides])   &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Limited independence|Limited independence]]&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Basic deviation inequalities|Basic deviation inequalities]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Concentration of measure|Concentration of measure]] ([http://tcs.nju.edu.cn/slides/aa2025/Concentration.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Conditional expectations|Conditional expectations]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Dimension Reduction|Dimension Reduction]] ([http://tcs.nju.edu.cn/slides/aa2025/NNS.pdf slides]) &lt;br /&gt;
#* [https://www.cs.princeton.edu/~hy2/teaching/fall22-cos521/notes/JL.pdf Professor Huacheng Yu&#039;s note on Johnson-Lindenstrauss Theorem]&lt;br /&gt;
#* [http://people.csail.mit.edu/gregory/annbook/introduction.pdf An introduction of LSH]&lt;br /&gt;
# Greedy Algorithms ([http://tcs.nju.edu.cn/slides/aa2024/Greedy.pdf slides], [http://tcs.nju.edu.cn/slides/aa2024/Greedy-handout.pdf slides-handout])&lt;br /&gt;
&lt;br /&gt;
= Related Online Courses=&lt;br /&gt;
* [https://www.cs.cmu.edu/~15850/ Advanced Algorithms] by Anupam Gupta at CMU.&lt;br /&gt;
* [http://people.csail.mit.edu/moitra/854.html Advanced Algorithms] by Ankur Moitra at MIT.&lt;br /&gt;
* [http://courses.csail.mit.edu/6.854/current/ Advanced Algorithms] by David Karger and Aleksander Mądry at MIT.&lt;br /&gt;
* [http://web.stanford.edu/class/cs168/index.html The Modern Algorithmic Toolbox] by Tim Roughgarden and Gregory Valiant at Stanford.&lt;br /&gt;
* [https://www.cs.princeton.edu/courses/archive/fall18/cos521/ Advanced Algorithm Design] by Pravesh Kothari and Christopher Musco at Princeton.&lt;br /&gt;
* [http://www.cs.cmu.edu/afs/cs.cmu.edu/academic/class/15859-f11/www/ Linear and Semidefinite Programming (Advanced Algorithms)] by Anupam Gupta and Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://www.cs.cmu.edu/~odonnell/papers/cs-theory-toolkit-lecture-notes.pdf CS Theory Toolkit] by Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://cs.uwaterloo.ca/~lapchi/cs860/index.html Eigenvalues and Polynomials] by Lap Chi Lau at University of Waterloo.&lt;br /&gt;
* The [https://www.cs.cornell.edu/jeh/book.pdf &amp;quot;Foundations of Data Science&amp;quot; book] by Avrim Blum, John Hopcroft, and Ravindran Kannan.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13301</id>
		<title>高级算法 (Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=%E9%AB%98%E7%BA%A7%E7%AE%97%E6%B3%95_(Fall_2025)&amp;diff=13301"/>
		<updated>2025-09-29T03:42:31Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Course info */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = &amp;lt;font size=3&amp;gt;高级算法 &lt;br /&gt;
&amp;lt;br&amp;gt;Advanced Algorithms&amp;lt;/font&amp;gt;&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|image        = &lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = &lt;br /&gt;
|captionstyle = &lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = &#039;&#039;&#039;尹一通&#039;&#039;&#039;&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yinyt@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 计算机系 804&lt;br /&gt;
|header5 = &lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &#039;&#039;&#039;栗师&#039;&#039;&#039;&lt;br /&gt;
|header6 = &lt;br /&gt;
|label6  = Email&lt;br /&gt;
|data6   = shili@nju.edu.cn &lt;br /&gt;
|header7 =&lt;br /&gt;
|label7= office&lt;br /&gt;
|data7= 计算机系 605&lt;br /&gt;
|header8 = &lt;br /&gt;
|label8  = &lt;br /&gt;
|data8   = &#039;&#039;&#039;刘景铖&#039;&#039;&#039;&lt;br /&gt;
|header9 = &lt;br /&gt;
|label9  = Email&lt;br /&gt;
|data9   = liu@nju.edu.cn &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10= office&lt;br /&gt;
|data10= 计算机系 516&lt;br /&gt;
|header11 = Class&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = &lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = Class meetings&lt;br /&gt;
|data12   = Monday (单), 2pm-4pm &amp;lt;br&amp;gt; Thursday, 2pm-4pm &amp;lt;br&amp;gt;仙Ⅰ-320&lt;br /&gt;
|header13 =&lt;br /&gt;
|label13  = Place&lt;br /&gt;
|data13   = &lt;br /&gt;
|header14 =&lt;br /&gt;
|label14  = Office hours&lt;br /&gt;
|data14   = TBD, &amp;lt;br&amp;gt;计算机系 804&amp;lt;br&amp;gt;&lt;br /&gt;
|header15 = Textbooks&lt;br /&gt;
|label15  = &lt;br /&gt;
|data15   = &lt;br /&gt;
|header16 =&lt;br /&gt;
|label16  = &lt;br /&gt;
|data16   = [[File:MR-randomized-algorithms.png|border|100px]]&lt;br /&gt;
|header17 =&lt;br /&gt;
|label17  = &lt;br /&gt;
|data17   = Motwani and Raghavan. &amp;lt;br&amp;gt;&#039;&#039;Randomized Algorithms&#039;&#039;.&amp;lt;br&amp;gt; Cambridge Univ Press, 1995.&lt;br /&gt;
|header18 =&lt;br /&gt;
|label18  = &lt;br /&gt;
|data18   = [[File:Approximation_Algorithms.jpg|border|100px]]&lt;br /&gt;
|header19 =&lt;br /&gt;
|label19  = &lt;br /&gt;
|data19   =  Vazirani. &amp;lt;br&amp;gt;&#039;&#039;Approximation Algorithms&#039;&#039;. &amp;lt;br&amp;gt; Springer-Verlag, 2001.&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
This is the webpage for the &#039;&#039;Advanced Algorithms&#039;&#039; class of fall 2025. Students who take this class should check this page periodically for content updates and new announcements. &lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* &#039;&#039;&#039;(2025/9/10)&#039;&#039;&#039; 本周四（9月11日）课程时间地点不变，为第五、六节在仙I-320。从第四周（9月15日）开始，采用新的上课时间：每周一的第五、六节，以及双周四的第五、六节，地点仍在仙I-320。&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;（授课时间顺序）: &lt;br /&gt;
:* [http://tcs.nju.edu.cn/yinyt/ 尹一通]：[mailto:yinyt@nju.edu.cn &amp;lt;yinyt@nju.edu.cn&amp;gt;]，计算机系 804 &lt;br /&gt;
:* [https://liuexp.github.io 刘景铖]：[mailto:liu@nju.edu.cn &amp;lt;liu@nju.edu.cn&amp;gt;]，计算机系 516 &lt;br /&gt;
:*[https://tcs.nju.edu.cn/shili/ 栗师]：[mailto:shili@nju.edu.cn &amp;lt;shili@nju.edu.cn&amp;gt;]，计算机系 605&lt;br /&gt;
* &#039;&#039;&#039;Teaching Assistant&#039;&#039;&#039;: &lt;br /&gt;
** 侯哲：houzhe@smail.nju.edu.cn&lt;br /&gt;
** 张弈垚：zhangyiyao@smail.nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: &lt;br /&gt;
** Monday (单), 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
** Thursday, 2pm-4pm, 仙Ⅰ-320&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: Wednesday 2pm-3pm, 计算机系 804&lt;br /&gt;
* &#039;&#039;&#039;QQ群&#039;&#039;&#039;: 524141453（加群请注明专业学号姓名）&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
随着计算机算法理论的不断发展，现代计算机算法的设计与分析大量地使用非初等的数学工具以及非传统的算法思想。“高级算法”这门课程就是面向计算机算法的这一发展趋势而设立的。课程将针对传统算法课程未系统涉及、却在计算机科学各领域的科研和实践中扮演重要角色的高等算法设计思想和算法分析工具进行系统讲授。&lt;br /&gt;
&lt;br /&gt;
=== 先修课程 Prerequisites ===&lt;br /&gt;
* 必须：离散数学，概率论，线性代数。&lt;br /&gt;
* 推荐：算法设计与分析。&lt;br /&gt;
&lt;br /&gt;
=== Course materials ===&lt;br /&gt;
* [[高级算法 (Fall 2025) / Course materials|&amp;lt;font size=3&amp;gt;教材和参考书&amp;lt;/font&amp;gt;]]&lt;br /&gt;
&lt;br /&gt;
=== 成绩 Grades ===&lt;br /&gt;
* 课程成绩：本课程将会有若干次作业和一次期末考试。最终成绩将由平时作业成绩和期末考试成绩综合得出。&lt;br /&gt;
* 迟交：如果有特殊的理由，无法按时完成作业，请提前联系授课老师，给出正当理由。否则迟交的作业将不被接受。&lt;br /&gt;
&lt;br /&gt;
=== &amp;lt;font color=red&amp;gt; 学术诚信 Academic Integrity &amp;lt;/font&amp;gt;===&lt;br /&gt;
学术诚信是所有从事学术活动的学生和学者最基本的职业道德底线，本课程将不遗余力的维护学术诚信规范，违反这一底线的行为将不会被容忍。&lt;br /&gt;
&lt;br /&gt;
作业完成的原则：署你名字的工作必须是你个人的贡献。在完成作业的过程中，允许讨论，前提是讨论的所有参与者均处于同等完成度。但关键想法的执行、以及作业文本的写作必须独立完成，并在作业中致谢（acknowledge）所有参与讨论的人。不允许其他任何形式的合作——尤其是与已经完成作业的同学“讨论”。&lt;br /&gt;
&lt;br /&gt;
本课程将对剽窃行为采取零容忍的态度。在完成作业过程中，对他人工作（出版物、互联网资料、其他人的作业等）直接的文本抄袭和对关键思想、关键元素的抄袭，按照 [http://www.acm.org/publications/policies/plagiarism_policy ACM Policy on Plagiarism]的解释，都将视为剽窃。剽窃者成绩将被取消。如果发现互相抄袭行为，&amp;lt;font color=red&amp;gt; 抄袭和被抄袭双方的成绩都将被取消&amp;lt;/font&amp;gt;。因此请主动防止自己的作业被他人抄袭。&lt;br /&gt;
&lt;br /&gt;
学术诚信影响学生个人的品行，也关乎整个教育系统的正常运转。为了一点分数而做出学术不端的行为，不仅使自己沦为一个欺骗者，也使他人的诚实努力失去意义。让我们一起努力维护一个诚信的环境。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
Late policy: In general, we will accomodate late submission requests ONLY IF you made such requests ahead of time. &lt;br /&gt;
&lt;br /&gt;
*[[高级算法 (Fall 2025)/Problem Set 1|Problem Set 1]]  请在 TBD前 提交到 [mailto:njuadvalg25@163.com njuadvalg25@163.com] (文件名为&#039;&amp;lt;font color=red &amp;gt;学号_姓名_A1.pdf&amp;lt;/font&amp;gt;&#039;).&lt;br /&gt;
&lt;br /&gt;
= Lecture Notes =&lt;br /&gt;
# [[高级算法 (Fall 2025)/Min Cut, Max Cut, and Spectral Cut|Min Cut, Max Cut, and Spectral Cut]] ([http://tcs.nju.edu.cn/slides/aa2025/Cut.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Probability Basics|Probability basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Fingerprinting| Fingerprinting]] ([http://tcs.nju.edu.cn/slides/aa2025/Fingerprinting.pdf slides]) &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Finite Field Basics|Finite field basics]]&lt;br /&gt;
#  [[高级算法 (Fall 2025)/Hashing and Sketching|Hashing and Sketching]] ([http://tcs.nju.edu.cn/slides/aa2025/Hashing.pdf slides])   &lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Limited independence|Limited independence]]&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Basic deviation inequalities|Basic deviation inequalities]]&lt;br /&gt;
# [[高级算法 (Fall 2025)/Concentration of measure|Concentration of measure]] ([http://tcs.nju.edu.cn/slides/aa2025/Concentration.pdf slides])&lt;br /&gt;
#*  [[高级算法 (Fall 2025)/Conditional expectations|Conditional expectations]]&lt;br /&gt;
&lt;br /&gt;
= Related Online Courses=&lt;br /&gt;
* [https://www.cs.cmu.edu/~15850/ Advanced Algorithms] by Anupam Gupta at CMU.&lt;br /&gt;
* [http://people.csail.mit.edu/moitra/854.html Advanced Algorithms] by Ankur Moitra at MIT.&lt;br /&gt;
* [http://courses.csail.mit.edu/6.854/current/ Advanced Algorithms] by David Karger and Aleksander Mądry at MIT.&lt;br /&gt;
* [http://web.stanford.edu/class/cs168/index.html The Modern Algorithmic Toolbox] by Tim Roughgarden and Gregory Valiant at Stanford.&lt;br /&gt;
* [https://www.cs.princeton.edu/courses/archive/fall18/cos521/ Advanced Algorithm Design] by Pravesh Kothari and Christopher Musco at Princeton.&lt;br /&gt;
* [http://www.cs.cmu.edu/afs/cs.cmu.edu/academic/class/15859-f11/www/ Linear and Semidefinite Programming (Advanced Algorithms)] by Anupam Gupta and Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://www.cs.cmu.edu/~odonnell/papers/cs-theory-toolkit-lecture-notes.pdf CS Theory Toolkit] by Ryan O&#039;Donnell at CMU.&lt;br /&gt;
* [https://cs.uwaterloo.ca/~lapchi/cs860/index.html Eigenvalues and Polynomials] by Lap Chi Lau at University of Waterloo.&lt;br /&gt;
* The [https://www.cs.cornell.edu/jeh/book.pdf &amp;quot;Foundations of Data Science&amp;quot; book] by Avrim Blum, John Hopcroft, and Ravindran Kannan.&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=Assignment_2,_Fall_2025&amp;diff=13300</id>
		<title>Assignment 2, Fall 2025</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=Assignment_2,_Fall_2025&amp;diff=13300"/>
		<updated>2025-09-29T03:07:58Z</updated>

		<summary type="html">&lt;p&gt;Etone: Created page with &amp;quot;&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;quot;&amp;gt;请在题目一和题目二中任选一题作为本章的作业题目。另外的一题可作为选做题。&amp;lt;/font&amp;gt;  ==Question 1== 假设在大气层顶（TOA），在多年全年平均的情况下，入射的太阳辐射随纬度的分布满足 &amp;lt;math&amp;gt;Q=Q_o \cdot s(x)&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;s(x)=s_o \cdot P_o(x)+ s_2 \cdot P_2(x)&amp;lt;/math&amp;gt;，  其中，&amp;lt;math&amp;gt;P_o(x)=1&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;P_2(x)=\frac{1}{2}(3x^2-1)&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;s_o=1&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;s_2=-0.473&amp;lt;/ma...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;quot;&amp;gt;请在题目一和题目二中任选一题作为本章的作业题目。另外的一题可作为选做题。&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Question 1==&lt;br /&gt;
假设在大气层顶（TOA），在多年全年平均的情况下，入射的太阳辐射随纬度的分布满足 &amp;lt;math&amp;gt;Q=Q_o \cdot s(x)&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;s(x)=s_o \cdot P_o(x)+ s_2 \cdot P_2(x)&amp;lt;/math&amp;gt;， &lt;br /&gt;
其中，&amp;lt;math&amp;gt;P_o(x)=1&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;P_2(x)=\frac{1}{2}(3x^2-1)&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;s_o=1&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;s_2=-0.473&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;x=sin \phi&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;\phi&amp;lt;/math&amp;gt; 为纬度。&lt;br /&gt;
&lt;br /&gt;
如果假设大气层顶的向外净长波辐射为&amp;lt;math&amp;gt;I&amp;lt;/math&amp;gt;，行星反照率为&amp;lt;math&amp;gt;\alpha&amp;lt;/math&amp;gt;，且忽略它们随纬度和经度的变化:&lt;br /&gt;
#请写出在能量平衡的情况下，大气和海洋的总经向能量输送应满足什么条件？&lt;br /&gt;
#按（1）中的条件，大气和海洋的总经向能量输送的最大值应出现在什么纬度？&lt;br /&gt;
#请与实际情况的大气海洋的能量输送相比较，讨论（2）结果是否与实际状况相符合？&lt;br /&gt;
&lt;br /&gt;
==Question 2==&lt;br /&gt;
&lt;br /&gt;
在第二章中，我们学习了Budyko的能量平衡气候模型（Simple Energy Balance Climate Model），并用此模型来讨论了存在冰雪线的情况下，气候系统的稳定性问题。冰雪线的南北移动会引起行星反照率及热量的动力输送的变化。我们发现这两种过程的相互作用能够引起气候系统的不稳定。如果使用同样的参数，即&amp;lt;math&amp;gt;A=211.1  W/m^{2}\,&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;B=1.55 W/(m^{2}{^{\circ}\text{C}})&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;Q_o=340 W/m^2\,&amp;lt;/math&amp;gt;， &amp;lt;math&amp;gt;T_{\text{snow}}=-10^{\circ}\text{C}&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;s(x)=1-0.241(3x^2-1)\,&amp;lt;/math&amp;gt;, 并同样假设:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;\mathcal{A}(T)=&lt;br /&gt;
\begin{cases}&lt;br /&gt;
\alpha&amp;amp; T&amp;lt;T_{\text{snow}},\\&lt;br /&gt;
\beta &amp;amp; T&amp;gt;T_{\text{snow}},\\&lt;br /&gt;
\dfrac{\alpha+\beta}{2} &amp;amp; T=T_{\text{snow}}.&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
如果行星反照率发生了改变，使得&amp;lt;math&amp;gt;\alpha=0.43 &amp;lt;/math&amp;gt;， 请讨论：&lt;br /&gt;
# 为了保持全球平均温度&amp;lt;math&amp;gt;\bar{T}&amp;lt;/math&amp;gt;不变，对于当前的&amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt;和冰雪线, &amp;lt;math&amp;gt;\beta&amp;lt;/math&amp;gt;应该取多少？&lt;br /&gt;
# 对于新的 &amp;lt;math&amp;gt;\alpha&amp;lt;/math&amp;gt;和&amp;lt;math&amp;gt;\beta&amp;lt;/math&amp;gt;值，&amp;lt;math&amp;gt;C&amp;lt;/math&amp;gt;的取值应该为多少？&lt;br /&gt;
# 请计算出新的&amp;lt;math&amp;gt;Q(x_s)&amp;lt;/math&amp;gt;.&lt;br /&gt;
# 请与课堂上所讲的&amp;lt;math&amp;gt;\alpha=0.4&amp;lt;/math&amp;gt;, &amp;lt;math&amp;gt;\beta=0.7&amp;lt;/math&amp;gt;的情况相比较（请将两种情况下&amp;lt;math&amp;gt;Q(x_s)&amp;lt;/math&amp;gt;的曲线画在同一张图上），讨论两种情况的异同，尤其是气候稳定性在&amp;lt;math&amp;gt;\alpha&amp;lt;/math&amp;gt;和&amp;lt;math&amp;gt;\beta&amp;lt;/math&amp;gt;值改变后发生了何种变化，请讨论为什么会发生这些变化？&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
	<entry>
		<id>https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13299</id>
		<title>General Circulation(Fall 2025)</title>
		<link rel="alternate" type="text/html" href="https://tcs.nju.edu.cn/wiki/index.php?title=General_Circulation(Fall_2025)&amp;diff=13299"/>
		<updated>2025-09-29T03:07:04Z</updated>

		<summary type="html">&lt;p&gt;Etone: /* Assignments */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Infobox&lt;br /&gt;
|name         = Infobox&lt;br /&gt;
|bodystyle    = &lt;br /&gt;
|title        = 大气环流 &amp;lt;br&amp;gt;&lt;br /&gt;
General Circulation of the Atmosphere&lt;br /&gt;
|titlestyle   = &lt;br /&gt;
&lt;br /&gt;
|headerstyle  = background:#ccf;&lt;br /&gt;
|labelstyle   = background:#ddf;&lt;br /&gt;
|datastyle    = &lt;br /&gt;
&lt;br /&gt;
|header1 =Instructor&lt;br /&gt;
|label1  = &lt;br /&gt;
|data1   = &lt;br /&gt;
|header2 = &lt;br /&gt;
|label2  = &lt;br /&gt;
|data2   = 张洋&lt;br /&gt;
|header3 = &lt;br /&gt;
|label3  = Email&lt;br /&gt;
|data3   = yangzhang@nju.edu.cn &lt;br /&gt;
|header4 =&lt;br /&gt;
|label4= office&lt;br /&gt;
|data4= 仙林大气楼 B410&lt;br /&gt;
|header5 = Class&lt;br /&gt;
|label5  = &lt;br /&gt;
|data5   = &lt;br /&gt;
|header6 =&lt;br /&gt;
|label6  = Class meetings&lt;br /&gt;
|data6   = 周一 下午 2:00-4:00，仙II-110&lt;br /&gt;
|header7 =&lt;br /&gt;
|label7  = Place&lt;br /&gt;
|data7   = &lt;br /&gt;
|header8 =&lt;br /&gt;
|label8  = Office hours&lt;br /&gt;
|data8   = 周五 下午13:00-2:00 &amp;lt;br&amp;gt;仙林大气楼B410 &lt;br /&gt;
|header9 = Reference book&lt;br /&gt;
|label9  = &lt;br /&gt;
|data9   = &lt;br /&gt;
|header10 =&lt;br /&gt;
|label10  = &lt;br /&gt;
|data10   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:James-Circulating.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      = Introduction to Circulating Atmospheres, &amp;lt;br&amp;gt;&#039;&#039;I. James&#039;&#039;, Cambridge Press, 1995&lt;br /&gt;
|captionstyle = }}&lt;br /&gt;
|header11 =&lt;br /&gt;
|label11  = &lt;br /&gt;
|data11   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:Oort.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Physics of Climate, &#039;&#039;Peixoto, J. P.&#039;&#039; and &#039;&#039;A. H. Oort&#039;&#039;,  Springer-Verlag New York, 1992&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|header12 =&lt;br /&gt;
|label12  = &lt;br /&gt;
|data12   = {{Infobox&lt;br /&gt;
|name         = &lt;br /&gt;
|bodystyle  = &lt;br /&gt;
|title        = &lt;br /&gt;
|titlestyle   = &lt;br /&gt;
|image        = [[File:geoff.jpg|border|100px]]&lt;br /&gt;
|imagestyle   = &lt;br /&gt;
|caption      =Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation, &#039;&#039;Vallis, G. K.&#039;&#039;, Cambridge University Press, 2006&lt;br /&gt;
|captionstyle = &lt;br /&gt;
}}&lt;br /&gt;
|belowstyle = background:#ddf;&lt;br /&gt;
|below = &lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is the page for the class &#039;&#039;General Circulation of the Atmosphere (大气环流)&#039;&#039; for the Fall 2025 semester. Students who take this class should check this page periodically for content updates and new announcements.&lt;br /&gt;
&lt;br /&gt;
= Announcement =&lt;br /&gt;
* 课程交流QQ群：631262169，请各位选课的同学入群。【2025.9.8】&lt;br /&gt;
&lt;br /&gt;
= Course info =&lt;br /&gt;
* &#039;&#039;&#039;Instructor &#039;&#039;&#039;: 张洋，&lt;br /&gt;
:*office: 仙林气象楼 B410&lt;br /&gt;
:*email: yangzhang@nju.edu.cn&lt;br /&gt;
* &#039;&#039;&#039;Class meeting&#039;&#039;&#039;: 周一 下午 2:00-4:00；仙II-110&lt;br /&gt;
* &#039;&#039;&#039;Office hour&#039;&#039;&#039;: 周五 &amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;2&amp;gt;下午1:00-2:00，仙林大气楼B410&amp;lt;/font&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Prerequisites&#039;&#039;&#039;: 动力气象，天气学，气候学&lt;br /&gt;
* &#039;&#039;&#039;Grading&#039;&#039;&#039;: 平时作业（50％）＋ 期末考试（50％）&lt;br /&gt;
本课程将大致布置4次作业，每次作业一二道题目左右。题目将选择每个课题最具有代表性、需要一定思维强度和动手能力的训练用题目,意在使学生通过顺利完成作业来建立环流系统的物理模型、以对课程内容得到深刻全面地理解和掌握。期末考试题目数量将会比平时作业多,覆盖面更广,但会比作业题目简单,只涉及对基本内容的掌握和对环流理论的直接应用。&lt;br /&gt;
&lt;br /&gt;
= Assignments =&lt;br /&gt;
# [[Assignment 1, Fall 2025|Reanalysis data and the earth&#039;s climatology]] [Due:2025.10.13]&amp;lt;font color=&amp;quot;red&amp;quot; size=&amp;quot;1.5&amp;quot;&amp;gt;请在本次作业的截止日期前将本次作业的图片部分和文字部分打包作为附件发送至邮箱 circulation_nju@126.com &amp;lt;/font&amp;gt;&lt;br /&gt;
# [[Assignment 2, Fall 2025|Simple energy balance climate model]]&lt;br /&gt;
&lt;br /&gt;
= Course intro =&lt;br /&gt;
“大气环流”常指地球大气较大空间范围、较长时间尺度上的空气流动，及其对地球大气热量、动量、能量和水汽的全球输送。虽然从十七、十八世纪起人们就开始研究大尺度的大气运动(如Hadley在1735年提出的信风理论)，但大气环流真正发展成为一门较完备的学科方向却是近半个世纪的事情。随着四五十年代探空资料等高空气象要素的取得，以及六十年代卫星等覆盖全球的观测资料的加入，大气环流的空间结构和时间变化开始被系统、全面地揭示。与此同时，大气环流的数值模拟，也开始成为研究大气环流的一个主要方法，并发展至今成为了解和预估未来气候变化的主要手段。随着观测和模拟手段的进步，大气环流的理论研究也在近三十年开始快速地发展，人们对各种环流系统的维持和变化有了更全面、更深刻、也更为现代的理解。&lt;br /&gt;
&lt;br /&gt;
现代的大气环流是大气动力学、天气学和气候学相结合的产物。大气环流，既是各种天气现象产生的背景流场，又是各种气候状态形成的动力机制。大气环流在低频、季节、年际、年代际等时间尺度的变化，不但会引起天气现象的变化，也影响着气候状态的形成。而在大气科学领域面临着诸如全球暖化、气候变化、环流异常等重大科学问题的今天，大气环流研究的重要性被推到了前所未有的高度,大气环流也成为活跃发展又充满挑战的学科方向。&lt;br /&gt;
&lt;br /&gt;
本课程将讲述在过去几十年里大气环流在观测、理论和模拟上取得的进展。希望学生借此课程能熟悉大气环流的基本分布和形态，掌握各主要环流系统的维持和变化机制，建立各环流系统形成的物理模型，了解现阶段的大气环流模式，知道大气环流方向有待解决的科学问题。&lt;br /&gt;
&lt;br /&gt;
作为一门课程，大气环流内容的讲述常可以有两条线索。一条是全球尺度上大气热量、动量、能量和水汽的分布与输送，Lorenz（1967）和 Peixoto and Oort（1992）是按此线索介绍大气环流的优秀教材；另一条线索，是各纬度、各区域内大气环流系统的形成、维持和变化机制，James（1995）和 Vallis（2006）是按此线索介绍大气环流的经典讲义。根据现阶段大气环流方向的研究特点，本课程的讲述将主要按照后一种方式来展开，并辅以介绍各环流系统对大气各要素场的输送。在介绍各环流系统时，本课程将以观测、理论和模拟为顺序，从各大气环流系统的观测事实入手，介绍大气环流系统的分布特征和时空变化特征；着重介绍关于环流系统的各种动力学模型和现阶段对环流系统的理解；辅以对环流系统模拟研究的介绍；最后通过三者的对比，讨论各环流系统有待研究的问题。&lt;br /&gt;
&lt;br /&gt;
= Syllabus =&lt;br /&gt;
本课程具体的内容安排如下：第一章为大气环流的概述，介绍大气环流发展的历史、包含的内容以及大气环流研究的常用观测资料和分析方法。第二章介绍大气环流产生的外部强迫：辐射强迫和下界面过程。第三至六章介绍大气环流中的各个环流系统及它们的动力机制。第七章详细介绍各复杂度的大气环流模式。第八章介绍大气环流领域现阶段最大的一个开放课题：全球暖化背景下的大气环流。这一章既是对前几章所介绍的大气环流理论的应用与检验，又是对未来大气环流研究方向的探讨。借此让学生熟悉并理解大气环流领域亟需解决的课题。具体课程安排和参考书目如下。&lt;br /&gt;
== Course schedule ==&lt;br /&gt;
*大气环流概述 (Introduction) （6课时）&lt;br /&gt;
*大气环流的外部强迫（3课时）&lt;br /&gt;
**辐射强迫 (Radiative forcing)&lt;br /&gt;
**下界面过程 (Surface boundaries)&lt;br /&gt;
*经向环流系统 (Zonally-averaged circulations)&lt;br /&gt;
**Hadley 环流（4课时）&lt;br /&gt;
**Ferrel 环流，急流，中纬度的波流相互作用（8课时）&lt;br /&gt;
*纬向环流系统（Non-zonal circulations）（6课时）&lt;br /&gt;
**Storm tracks&lt;br /&gt;
**Monsoon&lt;br /&gt;
**ENSO and Walker circulation&lt;br /&gt;
*能量和水汽循环 (Angular momentum, energy and water vapor)（2课时）&lt;br /&gt;
*不同复杂度的大气环流模式 (General circulation in a hierarchy of models)（2课时）&lt;br /&gt;
*全球暖化背景下的大气环流 (General circulation in the global warming scenario)（2课时）&lt;br /&gt;
&lt;br /&gt;
[[点击此处看详细课程安排 (click for more)]]&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
*观测部分：Peixoto, J. P. and A. H. Oort, 1992: Physics of Climate. Springer-Verlag New York, Inc., 520 pp. 中文译本：气候物理学，1995，吴国雄、刘辉等译校，气象出版社。&lt;br /&gt;
*综合介绍：James, I., 1995: Introduction to circulating atmospheres. Cambridge University Press, 448 pp. &lt;br /&gt;
*理论部分：Vallis, G. K., 2006: Atmospheric and Oceanic Fluid Dynamics: Fundamentals and Large-scale Circulation. Cambridge University Press. 745 pp.&lt;br /&gt;
* [[其它参考书目（点击看详情）]]&lt;/div&gt;</summary>
		<author><name>Etone</name></author>
	</entry>
</feed>