9 Commits

Author SHA1 Message Date
2de7ee0c22 Generating Functions edits (#26)
All checks were successful
CI / Typos (push) Successful in 9s
CI / Typst formatting (push) Successful in 7s
CI / Build (push) Successful in 5m0s
Reviewed-on: #26
2026-02-15 11:03:57 -08:00
dbe44d9797 Add "Cosa Nostra" (#28)
All checks were successful
CI / Typst formatting (push) Successful in 8s
CI / Typos (push) Successful in 10s
CI / Build (push) Successful in 5m12s
Reviewed-on: #28
2026-02-15 10:55:35 -08:00
af2d065cb6 Mockingbird edits (#27)
Some checks failed
CI / Typst formatting (push) Successful in 6s
CI / Typos (push) Successful in 8s
CI / Build (push) Has been cancelled
Reviewed-on: #27
2026-02-15 10:50:51 -08:00
664f2218c0 Add "Bugs on a Log" (#29)
Some checks failed
CI / Typst formatting (push) Successful in 20s
CI / Typos (push) Successful in 27s
CI / Build (push) Has been cancelled
Reviewed-on: #29
2026-02-15 10:49:26 -08:00
e689af6106 Add "Cosa Nostra"
All checks were successful
CI / Typos (pull_request) Successful in 18s
CI / Typst formatting (pull_request) Successful in 13s
CI / Build (pull_request) Successful in 8m57s
2026-02-15 10:44:25 -08:00
1b17553891 Generating Functions edits
All checks were successful
CI / Typst formatting (pull_request) Successful in 12s
CI / Typos (pull_request) Successful in 13s
CI / Build (pull_request) Successful in 7m12s
2026-02-15 10:44:23 -08:00
d4e08c3a25 Mockingbird edits
All checks were successful
CI / Typos (pull_request) Successful in 39s
CI / Typst formatting (pull_request) Successful in 43s
CI / Build (pull_request) Successful in 5m21s
2026-02-15 10:44:18 -08:00
e9a8441a7b Add "Bugs on a Log"
All checks were successful
CI / Typst formatting (pull_request) Successful in 18s
CI / Typos (pull_request) Successful in 16s
CI / Build (pull_request) Successful in 5m4s
2026-02-15 10:43:47 -08:00
629a03944b fix typos (#30)
Some checks failed
CI / Typst formatting (push) Successful in 12s
CI / Typos (push) Successful in 15s
CI / Build (push) Has been cancelled
Reviewed-on: #30
2026-02-15 10:42:45 -08:00
12 changed files with 141 additions and 10 deletions

View File

@@ -1,7 +1,7 @@
% use [nosolutions] flag to hide solutions. % use [nosolutions] flag to hide solutions.
% use [solutions] flag to show solutions. % use [solutions] flag to show solutions.
\documentclass[ \documentclass[
solutions, %solutions,
singlenumbering singlenumbering
]{../../../lib/tex/handout} ]{../../../lib/tex/handout}
\usepackage{../../../lib/tex/macros} \usepackage{../../../lib/tex/macros}
@@ -19,4 +19,5 @@
\input{parts/01 fibonacci.tex} \input{parts/01 fibonacci.tex}
\input{parts/02 dice.tex} \input{parts/02 dice.tex}
\input{parts/03 coins.tex} \input{parts/03 coins.tex}
\input{parts/04 bonus.tex}
\end{document} \end{document}

View File

@@ -77,7 +77,7 @@ A \textit{rational function} $f$ is a function that can be written as a quotient
That is, $f(x) = \frac{p(x)}{q(x)}$ where $p$ and $q$ are polynomials. That is, $f(x) = \frac{p(x)}{q(x)}$ where $p$ and $q$ are polynomials.
\problem{} \problem{}
Solve the equation from \ref<fibo> for $F(x)$, expressing it as a rational function. Solve the equation from \ref{fibo} for $F(x)$, expressing it as a rational function.
\begin{solution} \begin{solution}
\begin{align*} \begin{align*}
@@ -99,8 +99,8 @@ Solve the equation from \ref<fibo> for $F(x)$, expressing it as a rational funct
\definition{} \definition{}
\textit{Partial fraction decomposition} is an algebreic technique that works as follows: \par \textit{Partial fraction decomposition} is an algebraic technique that works as follows: \par
If $p(x)$ is a polynomial and $a$ and $b$ are constants, If $p(x)$ is a polynomial of degree 1 and $a$ and $b$ are constants,
we can rewrite the rational function $\frac{p(x)}{(x-a)(x-b)}$ as follows: we can rewrite the rational function $\frac{p(x)}{(x-a)(x-b)}$ as follows:
\begin{equation*} \begin{equation*}
\frac{p(x)}{(x-a)(x-b)} = \frac{c}{x-a} + \frac{d}{x-b} \frac{p(x)}{(x-a)(x-b)} = \frac{c}{x-a} + \frac{d}{x-b}
@@ -131,7 +131,7 @@ find a closed-form expression for its coefficients using partial fraction decomp
\problem{} \problem{}
Using problems from the introduction and \ref{pfd}, find an expression Using problems from the introduction and \ref{pfd}, find an expression
for the coefficients of $F(x)$ (and this, for the Fibonacci numbers). for the coefficients of $F(x)$ (and thus, for the Fibonacci numbers).
\begin{solution} \begin{solution}

View File

@@ -76,7 +76,7 @@ the probability that the sum of the two dice is $k$.
\problem{} \problem{}
Using generating functions, find two six-sided dice whose sum has the same Using generating functions, find two six-sided dice whose sum has the same
distribution as the sum of two standard six-sided dice? \par distribution as the sum of two standard six-sided dice. \par
That is, for any integer $k$, the number if ways that the sum of the two That is, for any integer $k$, the number if ways that the sum of the two
nonstandard dice rolls as $k$ is equal to the number of ways the sum of nonstandard dice rolls as $k$ is equal to the number of ways the sum of

View File

@@ -9,7 +9,7 @@ using pennies, nickels, dimes, quarters and half-dollars?}
\vspace{2mm} \vspace{2mm}
Most ways of solving this involve awkward brute-force Most ways of solving this involve awkward brute-force
approache that don't reveal anything interesting about the problem: approaches that don't reveal anything interesting about the problem:
how can we change our answer if we want to make change for how can we change our answer if we want to make change for
\$0.51, or \$1.05, or some other quantity? \$0.51, or \$1.05, or some other quantity?

View File

@@ -0,0 +1,57 @@
\section{Extra Problems}
\problem{USAMO 1996 Problem 6}
Determine (with proof) whether there is a subset $X$ of
the nonnegative integers with the following property: for any nonnegative integer $n$ there is exactly
one solution of $a + 2b = n$ with $a, b \in X$.
(The original USAMO question asked about all integers, not just nonnegative - this is harder,
but still approachable with generating functions.)
\vfill
\problem{IMO Shortlist 1998}
Let $a_0, a_1, ...$ be an increasing sequence of nonnegative integers
such that every nonnegative integer can be
expressed uniquely in the form $a_i + 2a_j + 4a_k$,
where $i, j, k$ are not necessarily distinct.
Determine $a_1998$.
\vfill
\problem{USAMO 1986 Problem 5}
By a partition $\pi$ of an integer $n \geq 1$, we mean here a
representation of $n$ as a sum of one or more positive integers where the summands must be put in
nondecreasing order. (e.g., if $n = 4$, then the partitions $\pi$ are
$1 + 1 + 1 + 1$, $1 + 1 + 2$, $1 + 3, 2 + 2$, and $4$).
For any partition $\pi$, define $A(\pi)$ to be the number of ones which appear in $\pi$, and define $B(\pi)$
to be the number of distinct integers which appear in $\pi$ (e.g, if $n = 13$ and $\pi$ is the partition
$1 + 1 + 2 + 2 + 2 + 5$, then $A(\pi) = 2$ and $B(\pi) = 3$).
Show that for any fixed $n$, the sum of $A(\pi)$ over all partitions of $\pi$ of $n$ is equal to the sum of
$B(\pi)$ over all partitions of $\pi$ of $n$.
\vfill
\problem{USAMO 2017 Problem 2}
Let $m_1, m_2, ..., m_n$ be a collection of $n$ distinct positive
integers. For any sequence of integers $A = (a_1, ..., a_n)$ and any permutation $w = w_1, ..., w_n$ of
$m_1, ..., m_n$, define an $A$-inversion of $w$ to be a pair of entries $w_i, w_j$ with $i < j$ for which one of the
following conditions holds:
\begin{itemize}
\item $ai \geq wi > wj$
\item $wj > ai \geq wi$
\item $wi > wj > ai$
\end{itemize}
Show that for any two sequences of integers $A = (a_1, ..., a_n)$ and $B = (b_1, ..., b_n)$ and for any
positive integer $k$, the number of permutations of $m_1, ..., m_n$ having exactly $k$ $A$-inversions is equal
to the number of permutations of $m_1, ..., m_n$ having exactly $k$ $B$-inversions.
(The original USAMO problem allowed the numbers $m_1, ..., m_n$ to not necessarily be distinct.)
\vfill

View File

@@ -230,7 +230,7 @@ The \textit{tensor product} of two vectors is defined as follows:
That is, we take our first vector, multiply the second That is, we take our first vector, multiply the second
vector by each of its components, and stack the result. vector by each of its components, and stack the result.
You could think of this as a generalization of scalar You could think of this as a generalization of scalar
mulitiplication, where scalar mulitiplication is a multiplication, where scalar multiplication is a
tensor product with a vector in $\mathbb{R}^1$: tensor product with a vector in $\mathbb{R}^1$:
\begin{equation*} \begin{equation*}
a a

View File

@@ -251,7 +251,7 @@ What is it, and what is its color? \par
\textbf{Part 4:} \textbf{Part 4:}
The promoted black bishop on H2 must have been promoted on G1. The pawn which was promoted must have come from G7, The promoted black bishop on H2 must have been promoted on G1. The pawn which was promoted must have come from G7,
since neither of the pawns from F6 or H6 could make a capture to get to the G-file (all six missing white pieces have been accouted for). since neither of the pawns from F6 or H6 could make a capture to get to the G-file (all six missing white pieces have been accounted for).
The Pawn from E7 has promoted to the bishop on A2. The Pawn from E7 has promoted to the bishop on A2.
What happened was this: the white pawn from G2 made its capture on H3 while the pawn on G3 was still on H2. This allowed the black pawn What happened was this: the white pawn from G2 made its capture on H3 while the pawn on G3 was still on H2. This allowed the black pawn

View File

@@ -331,7 +331,7 @@
representing all four cubes. \\ representing all four cubes. \\
\begin{center} \begin{small} \begin{center} \begin{small}
\begin{tikzpicture} \label{pic:II_comfiguration} \begin{tikzpicture} \label{pic:II_configuration}
\filldraw [blue] (0,5) -- (1,5) -- (1,6) -- \filldraw [blue] (0,5) -- (1,5) -- (1,6) --
(0,6) -- (0,5); (0,6) -- (0,5);
\draw [line width = 1.5pt] (0,5) -- \draw [line width = 1.5pt] (0,5) --

View File

@@ -0,0 +1,11 @@
#import "@local/handout:0.1.0": *
#show: handout.with(
title: [Warm-Up: Bugs on a Log],
by: "Mark",
)
#problem()
2013 bugs are on a meter-long line. Each walks to the left or right at a constant speed. \
If two bugs meet, both turn around and continue walking in opposite directions. \
What is the longest time it could take for all the bugs to walk off the end of the log?

View File

@@ -0,0 +1,6 @@
[metadata]
title = "Bugs on a Log"
[publish]
handout = true
solutions = true

View File

@@ -0,0 +1,50 @@
#import "@local/handout:0.1.0": *
#show: handout.with(
title: [Warm-Up: Cosa Nostra],
by: "Mark",
)
#problem()
There are 36 gangsters in a certain district of Chicago.
Some pairs of gangsters have feuds.
- Each gangster is part of at least one outfit, and no two outfits share the same members.
- If two gangsters are both in one outfit, there is no feud between them.
- A gangster that is not in a certain outfit must have a feud with at least one if its members.
What is the maximum number of outfits that can exist in this district?
#solution[
*Definition:* Let the _authority_ of a gangster be the number of oufits they are a part of.
#v(5mm)
*Lemma:* Say two gangsters have a feud. Label them $x$ and $y$ so that $#text(`authority`) (x) > #text(`authority`) (y)$. \
Then, replacing $y$ with a clone of $x$ will strictly increase the number of outfits. \
If $#text(`authority`) (x) = #text(`authority`) (y)$, replacing $y$ with $x$ will not change the number of outfits.
#v(5mm)
*Proof:*
Let $A$ be the set of outfits that $y$ is a part of, and $B$ its complement (that is, all outfits that $a$ is _not_ a part of). If we delete $y$...
- all outfits in $B$ remain outfits.
- some outfits in $A$ cease to be outfits (as they are no longer maximal)
Also, no new outfits are formed. If a new outfit $o$ contains any enemies of $y$, it existed previously and is a member of $B$. If $o$ contains no enemies of $y$, it must have contained $y$ prior to deletion, and is thus a member of $A$. Therefore, the number of outfits is reduced by at most `authority(y)` when $y$ is deleted.
If we add a clone of $x$ after deleting $y$ (this clone has a feud with $x$), All previous outfits remain outfits, and `authority(x)` new outfits are created.
Therefore, replacing $y$ with a clone of $x$ strictly increases the number of outfits that exist.
We thus conclude that in the maximal case, all pairs of feuding gangsters have equal authority.
#v(5mm)
*Solution:* Consider an arbitrary gangster $g$. By the previous lemma, we can replace all gangsters $g$ has a feud with clones of itself. Repeat this for all gangsters, and we are left with groups of feuding gangsters who are friends with everyone outside their group. The total number of outfits is the product of the sizes of these groups.
#v(5mm)
This problem is now equivalent to the "Partition Products" warm-up. We want the list of numbers whose sum is 36 and whose product is maximal. The solution is to form 12 groups of three gangsters for a total of $3^12$ outfits.
]

View File

@@ -0,0 +1,6 @@
[metadata]
title = "Cosa Nostra"
[publish]
handout = true
solutions = true