avewright/proofwiki-math huggingface dataset:
Theorem: Necessary Condition for Integral Functional to have Extremum/Two Variables/Lemma

Let $D \subset \R^2$.
Let $\Gamma$ be the boundary of $D$.
Let $\alpha : D \to \R$ be a continuous mapping.
Let $h : D \to \R$ be a twice differentiable mapping such that $\map h \Gamma = 0$.
Suppose for every $h$ we have that:
:$\ds \iint_D \map \alpha {x, y} \map h {x,y} \rd x \rd y = 0$.
Then:
:$\ds \forall x, y \in D : \map \alpha {x, y} = 0$

Proof:
{{AimForCont}} that:
:$\ds \exists x_0,y_0 \in D : \map \alpha {x_0,y_0} > 0$
$\alpha$ is continuous in $D$. 
Therefore, there exists a closed ball $B^-_{\epsilon}$ defined by:
:$\map {B^-_{\epsilon}} {x_0, y_0} := \set {\tuple{x,y} \in D : \paren {x - x_0}^2 + \paren {y - y_0}^2 \le \epsilon^2}$
such that:
:$\forall x,y \in B^-_{\epsilon} : \map \alpha {x,y} > 0$
Choose $\map h {x, y}$ in the following way:
:$\map h {x,y} = \begin {cases} 0, \forall x, y \notin B^-_{\epsilon} \\ \sqbrk {\epsilon^2 - \paren {x - x_0}^2 - \paren {y - y_0}^2}^3, \forall x,y \in B^-_{\epsilon} \end{cases}$
Such a choice for $\map h {x,y}$ satisfies the conditions of the lemma.
But then both $\alpha$ and $h$ are positive inside this ball.
Hence, the integral is positive.
This contradicts assumptions of the lemma.
Hence:
:$\ds \forall x, y \in D : \map \alpha {x,y} = 0$
{{qed}}
Theorem: Number of Different n-gons that can be Inscribed in Circle

Let $C$ be a circle on whose circumference $n$ points are placed which divide $C$ into $n$ equal arcs.
The number of different $n$-gons (either stellated or otherwise) that can be described on $C$ whose vertices are those $n$ points is:
:$S_n = \dfrac {\paren {n - 1}!} 2$

Proof:
An $n$-gon (either stellated or otherwise) is constructed by connecting all $n$ points in some order.
From Number of Permutations, there are ${}^n P_n = n!$ ways of ordering $n$ points.
However, for each $n$-gon formed in this way, we have:
:$n$ ways of choosing the first vertex
:$2$ different sides from that vertex to use as the first one (starting off either clockwise or anticlockwise).
and all of these end up describing the same $n$-gon.
Thus there are $\dfrac {n!} {2 n} = \dfrac {\paren {n - 1}!} 2$ different $n$-gons.
{{qed}}
Theorem: Number of Regular Stellated Odd n-gons

Let $n \in \Z_{>0}$ be a strictly positive odd integer.
Then there are $\dfrac {n - 1} 2$ distinct regular stellated $n$-gons.

Proof:
Let $P$ be a regular stellated $n$-gons.
Let the $n$ vertices of $P$ be $p_1, p_2, \dotsc, p_n$.
These will be arranged on the circumference of a circle $C$, dividing $C$ into $n$ arcs of equal length.
Once we have chosen the first side of $P$, the others are all the same length and are completely determined by that first side.
{{WLOG}}, the first vertex of $P$ is chosen to be $p_1$
We can choose that first side as follows:
:$p_1 p_2, p_1 n_3, \ldots, p_1 p_{n - 1}, p_1 p_n$
But we have that:
:$\size {p_1 p_2} = \size {p_1 p_n}$
:$\size {p_1 p_3} = \size {p_1 p_{n - 1} }$
and so on, down to:
:$\size {p_1 p_{\paren {n - 1} / 2} }= \size {p_1 p_{\paren {n + 1} / 2} }$
where $\size {p_a p_b}$ denotes the length of the line $p_1 p_b$.
So for the $n - 1$ lines that are chosen for the first side of $P$, each is paired with another of the same length.
Hence there are $\dfrac {n - 1} 2$ ways of choosing the first side of $P$.
Thus there are $\dfrac {n - 1} 2$ distinct regular stellated $n$-gons.
{{qed}}
Theorem: Wilson's Theorem/Corollary 1

Let $p$ be a prime number.
Then $p$ is the smallest prime number which divides $\paren {p - 1}! + 1$.

Proof:
From Wilson's Theorem, $p$ divides $\paren {p - 1}! + 1$.
Let $q$ be a prime number less than $p$.
Then $q$ is a divisor of $\paren {p - 1}!$ and so does not divide $\paren {p - 1}! + 1$.
{{qed}}
Theorem: Generating Function for Natural Numbers/Corollary

Let $\sequence {a_n}$ be the sequence defined as:
:$\forall n \in \N_{> 0}: a_n = n - 1$
That is:
:$\sequence {a_n} = 1, 2, 3, 4, \ldots$
Then the generating function for $\sequence {a_n}$ is given as:
:$H \paren z = \dfrac z {\paren {1 - z}^2}$

Proof:
From Generating Function for Natural Numbers:
:$\sequence {a_n} = 0, 1, 2, 3, 4, \ldots$
has the generating function:
:$G \paren z = \dfrac 1 {\paren {1 - z}^2}$
Then by Generating Function by Power of Parameter:
:$z G \paren z = \dfrac z {\paren {1 - z}^2}$
is the generating function for the sequence defined as:
:$\forall n \in \N_{> 0}: a_{n - 1} = n - 1$
that is:
:$0, a_1, a_2, \ldots$
where:
:$a_1 = 1, a_2 = 2, \ldots$
That is:
:$\sequence {a_n} = 1, 2, 3, 4, \ldots$
{{qed}}
Theorem: Generating Function for Triangular Numbers/Corollary

Let $\sequence {b_n}$ be the sequence defined as:
:$\forall n \in \N_{> 0}: b_n = \dfrac {\paren {n + 1} \paren {n + 2} } 2$
That is:
:$\sequence {b_n}_{n \mathop \ge 0} = 1, 3, 6, 10, \ldots, \dbinom {n + 2} 2, \ldots$
Then the generating function for $\sequence {b_n}$ is given as:
:$H \paren z = \dfrac 1 {\paren {1 - z}^3}$

Proof:
From Generating Function for Triangular Numbers:
:$H \paren z = \dfrac z {\paren {1 - z}^3}$
is the generating function for $\sequence {a_n}$ as given by:
:$\sequence {a_n} = 1, 3, 6, 10, \ldots, \dbinom {n + 1} 2, \ldots$
that is, such that:
:$a_1 = 1, a_2 = 3, a_3 = 6, \ldots$
The result follows from Generating Function Divided by Power of Parameter.
{{qed}}
Theorem: Square Modulo n Congruent to Square of Inverse Modulo n

Let $n \in \Z_{>0}$ be a (strictly) positive integer.
Then:
:$a^2 \equiv \paren {n - a}^2 \pmod n$
where the notation denotes congruence modulo $n$.

Proof:
{{begin-eqn}}
{{eqn | l = \paren {n - a}^2
      | r = n^2 - 2 n - a^2
      | c = 
}}
{{eqn | o = \equiv
      | r = a^2
      | rr= \pmod n
      | c = 
}}
{{end-eqn}}
{{qed}}
Category:Modulo Arithmetic
oaexkl44pkr2mnoa7jpv1g88idzc81s
Theorem: Partition of Integer into Powers of 2 for Consecutive Integers

Let $n \in \Z_{>0}$ be a (strictly) positive integer.
Let $\map b n$ denote the number of ways $n$ can be partitioned into (integer) powers of $2$.
Then:
:$\map b {2 n} = \map b {2 n + 1}$

Proof:
We prove the theorem by establishing a bijection between the set of partitions of $2 n$ with that of $2 n + 1$, under the constraint where each partition is an integer power of $2$.
We have that $2^k$ is even for all $k > 0$.
Also, we have that $2 n + 1$ is odd for all $n$.
So, for each partition of $2 n + 1$ into integer powers of $2$, there is at least one part of size $1$.
Removing this part gives a partition of $2 n$ into integer powers of $2$.
The inverse of this is adding a part of size $1$ to a partition of $2 n$.
This will give a partition of $2 n + 1$ into integer powers of $2$.
Hence both removing and adding are well-defined mappings.
Thus they are bijections.
Therefore:
:$\map b {2 n} = \map b {2 n + 1}$
{{qed}}
Theorem: Number of Partitions with no Multiple of 3 equals Number of Partitions where Parts appear No More than Twice

Let $n \in \Z_{>0}$ be a (strictly) positive integer.
Let $\map t n$ denote the number of ways $n$ can be partitioned into parts which are specifically not multiples of $3$.
Let $\map v n$ denote the number of ways $n$ can be partitioned such that no part appears twice.
Then:
:$\forall n \in \Z_{>0}: \map t n = \map v n$

Proof:
{{ProofWanted|Chapter $12$ of {{BookReference|Number Theory|1971|George E. Andrews}} }}
Theorem: Congruent Numbers are not necessarily Equal

Let $x, y, z \in \R$ be real numbers such that:
:$x \equiv y \pmod z$
where $x \equiv y \pmod z$ denotes congruence modulo $z$.
Then it is not necessarily the case that $x = y$.

Proof:
Proof by Counterexample:
We have that:
:$11 - 5 = 6 = 3 \times 2$
and so by definition of congruence modulo $2$:
:$10 \equiv 4 \pmod 2$
But $11 \ne 5$.
{{qed}}
Theorem: Congruence Modulo Negative Number

Let $a, b, c \in \R$ be real numbers.
Then:
:$a \equiv b \pmod c \iff a \equiv b \pmod {-c}$

Proof:
{{begin-eqn}}
{{eqn | l = a
      | o = \equiv
      | r = b
      | rr= \pmod c
      | c = 
}}
{{eqn | ll= \leadstoandfrom
      | l = \paren {a - b} 
      | r = k c
      | c = {{Defof|Congruence (Number Theory)|Congruence Modulo $c$}}: for some $k \in \Z$
}}
{{eqn | ll= \leadstoandfrom
      | l = \paren {a - b} 
      | r = -k \paren {-c}
      | c = 
}}
{{eqn | ll= \leadstoandfrom
      | l = a
      | o = \equiv
      | r = b
      | rr= \pmod {-c}
      | c = {{Defof|Congruence (Number Theory)|Congruence Modulo $-c$}}
}}
{{end-eqn}}
{{Qed}}
Theorem: P-adic Norm and Absolute Value are Not Equivalent

Let $\norm {\,\cdot\,}_p$ be the $p$-adic norm on the rationals $\Q$ for some prime number $p$.
Let $\size{\,\cdot\,}$ be the absolute value on the rationals $\Q$.
Then $\norm {\,\cdot\,}_p$ and $\size{\,\cdot\,}$ are not equivalent norms.
That is, the topology induced by $\norm {\,\cdot\,}_p$ does not equal the topology induced by $\size {\,\cdot\,}$.

Proof:
By definition of the $p$-adic norm:
:$\norm p_p = \dfrac 1 p < 1$
By definition of the absolute value:
:$\size p = p > 1$
By definition of open unit ball equivalence, $\norm {\,\cdot\,}_p$ and $\size {\,\cdot\,}$ are not equivalent norms.
By Equivalence of Definitions of Equivalent Division Ring Norms and the definition of topologically equivalent norms then the topology induced by $\norm {\,\cdot\,}_p$ does not equal the topology induced by $\size{\,\cdot\,}$.
{{qed}}
Theorem: P-adic Norm and Absolute Value are Not Equivalent

Let $\norm {\,\cdot\,}_p$ be the $p$-adic norm on the rationals $\Q$ for some prime number $p$.
Let $\size{\,\cdot\,}$ be the absolute value on the rationals $\Q$.
Then $\norm {\,\cdot\,}_p$ and $\size{\,\cdot\,}$ are not equivalent norms.
That is, the topology induced by $\norm {\,\cdot\,}_p$ does not equal the topology induced by $\size {\,\cdot\,}$.

Proof:
It is noted that:
:$\sup \set {\size n: n \in \Z} = +\infty$
By {{Corollary|Characterisation of Non-Archimedean Division Ring Norms|3}}, $\size {\,\cdot\,}$ is Archimedean.
From P-adic Norm on Rational Numbers is Non-Archimedean Norm, $\norm {\,\cdot\,}_p$ is non-Archimedean.
By Equivalent Norms are both Non-Archimedean or both Archimedean, $\norm {\,\cdot\,}_p$ and $\size {\,\cdot\,}$ are not equivalent norms.
{{qed}}
Theorem: P-adic Norms are Not Equivalent

Let $p_1$ and $p_2$ be prime numbers such that $p_1 \ne p_2$.
Let $\norm {\,\cdot\,}_{p_1}$ and $\norm {\,\cdot\,}_{p_2}$ be the $p$-adic norms on the rationals $\Q$.
Then $\norm {\,\cdot\,}_{p_1}$ and $\norm {\,\cdot\,}_{p_2}$ are not equivalent norms.
That is, the topology induced by $\norm {\,\cdot\,}_{p_1}$ does not equal the topology induced by $\norm {\,\cdot\,}_{p_2}$.

Proof:
Consider $p_1/p_2 \in \Q$. 
With $\norm {\,\cdot\,}_{p_1}$:
{{begin-eqn}}
{{eqn | l = \norm {p_1/p_2}_{p_1}
      | r = \norm {p_1}_{p_1} \norm {1/p_2}_{p_1}
      | c = {{NormAxiomNonArch|2}}
}}
{{eqn | r = \norm {p_1}_{p_1} \times 1
      | c = $p_1$ does not divide $p_2$
}}
{{eqn | r = 1 / {p_1}
}}
{{eqn | o = \lt
      | r = 1
}}
{{end-eqn}}
On the other hand, with $\norm {\,\cdot\,}_{p_2}$:
{{begin-eqn}}
{{eqn | l = \norm {p_1/p_2}_{p_2}
      | r = \norm {p_1}_{p_2} \norm {1/p_2}_{p_2}
      | c = {{NormAxiomNonArch|2}}
}}
{{eqn | r = 1 \times \norm {1/p_2}_{p_2}
      | c = $p_2$ does not divide $p_1$
}}
{{eqn | r = p_2
}}
{{eqn | o = >
      | r = 1
}}
{{end-eqn}}
By open unit ball equivalence, $\norm {\,\cdot\,}_{p_1}$ and $\norm {\,\cdot\,}_{p_2}$ are not equivalent norms.
By Equivalence of Definitions of Equivalent Division Ring Norms and topological equivalence then the topology induced by $\norm {\,\cdot\,}_{p_1}$ does not equal the topology induced by $\norm {\,\cdot\,}_{p_2}$.
{{qed}}
Theorem: Polynomials of Congruent Integers are Congruent

Let $x, y, m \in \Z$ be integers where $m \ne 0$.
Let:
:$x \equiv y \pmod m$
where the notation indicates congruence modulo $m$.
Let $a_0, a_1, \ldots, a_r$ be integers.
Then:
:$\ds \sum_{k \mathop = 0}^r a_k x^k \equiv \sum_{k \mathop = 0}^r a_k y^k \pmod m$

Proof:
We have that:
:$x \equiv y \pmod m$
From Congruence of Powers:
:$x^k \equiv y^k \pmod m$
From Modulo Multiplication is Well-Defined:
:$\forall k \in \set {0, 2, \ldots, r}: a_k x^k \equiv a_k y^k \pmod m$
The result follows from Modulo Addition is Well-Defined.
{{qed}}
Theorem: Congruent Integers less than Half Modulus are Equal

Let $k \in \Z_{>0}$ be a strictly positive integer.
Let $a, b \in \Z$ such that $\size a < \dfrac k 2$ and $\size b < \dfrac k 2$.
Then:
:$a \equiv b \pmod k \implies a = b$
where $\equiv$ denotes congruence modulo $k$.

Proof:
We have that:
:$-\dfrac k 2 < a < \dfrac k 2$
and:
:$-\dfrac k 2 < -b < \dfrac k 2$
Thus:
:$-k < a - b < k$
Let $a \equiv b \pmod k$
Then:
:$a - b = n k$
for some $n \in \Z$.
But as $-k < n k < k$ it must be the case that $n = 0$.
Thus $a - b = 0$ and the result follows.
{{qed}}
Theorem: Complete Residue System Modulo m has m Elements

Let $m \in \Z_{\ne 0}$ be a non-zero integer.
Let $S := \set {r_1, r_2, \dotsb, r_s}$ be a complete residue system modulo $m$.
Then $s = m$.

Proof:
Let:
:$t_0 = 0, t_1 = 1, \dots, t_{m - 1} = m - 1$
Let $n \in \Z$.
Then from the Division Theorem there exist unique integers $q$ and $u$ such that:
:$n = m q + u$
such that $0 \le u < m$.
That is:
:$n \equiv u \pmod m$
and $u$ is one of $t_0, t_1, \ldots, t_{m - 1}$.
Also, since $\size {t_i - t_j} < m$, no two elements of $\set {t_0, t_1, \ldots, t_{m - 1} }$ are congruent.
Thus $\set {t_0, t_1, \ldots, t_{m - 1} }$ is a complete residue system modulo $m$.
So each $r_i$ is congruent to exactly one element of $\set {t_0, t_1, \ldots, t_{m - 1} }$.
So:
:$s \le m$
And since $\set {r_1, r_2, \dotsb, r_s}$ forms a complete residue system modulo $m$, every element of $\set {t_0, t_1, \ldots, t_{m - 1} }$ is congruent to exactly one element of $S$.
So:
:$m \le s$
Hence the result.
{{qed}}
Theorem: Initial Segment of Natural Numbers forms Complete Residue System

Let $m \in \Z_{\ne 0}$ be a non-zero integer.
Let $\N_m = \set {0, 1, 2, \ldots, m - 1}$ denote the initial segment of $\N$
Then $\N_m$ is a complete residue system modulo $m$.

Proof:
Let $n \in \Z$.
From the Division Theorem there exist unique integers $q$ and $u$ such that:
:$n = m q + u$
such that $0 \le u < m$.
That is:
:$n \equiv u \pmod m$
and $u$ is one of $0, 1, \ldots, m - 1$.
Also, since $\forall i, j \in \N_m: \size {i - j} < m$, no two elements of $\N_m$ are congruent.
Thus $\N_m = \set {0, 1, 2, \ldots, m - 1}$ is a complete residue system modulo $m$.
{{qed}}
Theorem: Congruence Modulo Power of p as Linear Combination of Congruences Modulo p

Let $p$ be a prime number.
Let $S = \set {a_1, a_2, \ldots, a_p}$ be a complete residue system modulo $p$.
Then for all integers $n \in \Z$ and non-negative integer $s \in \Z_{\ge 0}$, there exists a congruence of the form:
:$n \equiv \ds \sum_{j \mathop = 0}^s b_j p^j \pmod {p^{s + 1} }$
where $b_j \in S$.

Proof:
Proof by induction on $s$:
Theorem: Number of Non-Dividing Primes Less than n is Less than Euler Phi Function of n

Let $n \in \Z_{>0}$ be a strictly positive integer.
Let $\map w n$ denote the number of primes strictly less than $n$ which are not divisors of $n$.
Let $\map \phi n$ denote the Euler $\phi$ function of $n$.
Then:
:$\map w n < \map \phi n$

Proof:
Let $P = \set {p < n: p \text { prime}, p \nmid n}$.
Let $Q = \set {0 < q < n: q \perp n}$, where $q \perp n$ denotes that $q$ and $n$ are coprime.
Let $p \in P$.
From Prime not Divisor implies Coprime, $p$ is coprime to $n$.
That is:
:$p \in Q$
So, by definition of subset:
:$P \subseteq Q$
From Integer is Coprime to 1:
:$1 \in Q$
But as One is not Prime:
:$1 \notin P$
Thus $P \subsetneq Q$ and so:
:$\card P < \card Q$
By definition of $\map w n$:
:$\card P = \map w n$
and by definition of Euler $\phi$ function:
:$\card Q = \map \phi n$
Hence the result.
{{qed}}
Theorem: Schatunowsky's Theorem

Let $n \in \Z_{>0}$ be a strictly positive integer.
Let $\map w n$ denote the number of primes strictly less than $n$ which are not divisors of $n$.
Let $\map \phi n$ denote the Euler $\phi$ function of $n$.
Then $30$ is the largest integer $n$ such that:
:$\map w n = \map \phi n - 1$

Proof:
The above equation is equivalent to the property that all numbers greater than $1$ that are coprime to it but less are prime.
For an integer to have this property:
If it is greater than $p^2$ for some prime $p$, then it must be divisible by $p$.
If not, it will be coprime to $p^2$, a composite number.
Let $p_n$ denote the $n$th prime.
Suppose $N$ has this property.
By the argument above, if $p_{n + 1}^2 \ge N > p_n^2$, we must have $p_1 p_2 \cdots p_n \divides N$.
By Absolute Value of Integer is not less than Divisors, we have $p_1 p_2 \cdots p_n \le N$.
Bertrand-Chebyshev Theorem asserts that there is a prime between $p_n$ and $2 p_n$.
Thus we have $2 p_n > p_{n + 1}$.
Hence for $n \ge 5$:
{{begin-eqn}}
{{eqn | l = N
      | o = \ge
      | r = p_1 p_2 \cdots p_n
}}
{{eqn | r = 2 \times 3 \times 5 p_4 \cdots p_n
}}
{{eqn | o = >
      | r = 8 p_{n - 1} p_n
}}
{{eqn | o = >
      | r = 4 p_n^2
      | c = Bertrand-Chebyshev Theorem
}}
{{eqn | o = >
      | r = p_{n + 1}^2
      | c = Bertrand-Chebyshev Theorem
}}
{{eqn | o = \ge
      | r = N
      | c = From assumption
}}
{{end-eqn}}
This is a contradiction. 
Hence we must have $N \le p_5^2 = 121$.
From the argument above we also have:
:$2 \divides N$ for $4 < N \le 9$
:$2, 3 \divides N$ for $9 < N \le 25$
:$2, 3, 5 \divides N$ for $25 < N \le 49$
:$2, 3, 5, 7 \divides N$ for $49 < N \le 121$
So we end up with the list $N = 1, 2, 3, 4, 6, 8, 12, 18, 24, 30$.
This list is verified in Integers such that all Coprime and Less are Prime.
{{qed}}
Theorem: Position of Card after n Modified Perfect Faro Shuffles

Let $D$ be a deck of cards $D$ of size $2 r$.
Let $C$ be a card in position $x$ of $D$.
Let $n$ modified perfect faro shuffles be performed on $C$.
Then $C$ will be in position $w$, where:
:$w \equiv 2^n x \pmod {2 r + 1}$

Proof:
The proof proceeds by induction.
For all $n \in \Z_{\ge 1}$, let $\map P n$ be the proposition:
:After $n$ modified perfect faro shuffles, $C$ will be in position $a_n$ where $a_n \equiv 2^n x \pmod  {2 r + 1}$
Theorem: Number of Modified Perfect Faro Shuffles to return Deck of Cards to Original Order

Let $D$ be a deck of $2 m$ cards.
Let $D$ be given a sequence of modified perfect faro shuffles.
Then the cards of $D$ will return to their original order after $n$ such shuffles, where:
:$2^n \equiv 1 \pmod {2 m + 1}$

Proof:
From Position of Card after n Modified Perfect Faro Shuffles, after $n$ shuffles a card in position $x$ will be in position $2^n x \pmod {m + 1}$.
So for all $2 m$ cards in $D$, we need to find $n$ such that:
:$2^n x \equiv x \pmod {2 m + 1}$
Because $2 m + 1$ is odd, we have:
:$\gcd \set {2, 2 m + 1}$
and so from Cancellability of Congruences:
:$2^n \equiv 1 \pmod {2 m + 1}$
{{qed}}
Theorem: Number of Modified Perfect Faro Shuffles to return Deck of Cards to Original Order/Examples/Deck of 62 Cards

Let $D$ be a deck of $62$ cards.
Let $D$ be given a sequence of modified perfect faro shuffles.
Then after $6$ such shuffles, the cards of $D$ will be in the same order they started in.

Proof:
From Number of Modified Perfect Faro Shuffles to return Deck of Cards to Original Order, the cards of $D$ will return to their original order after $n$ such shuffles, where:
:$2^n \equiv 1 \pmod {63}$
We have that:
:$63 = 2^6 - 1$
and so:
:$2^6 \equiv 1 \pmod {63}$
Hence the result.
{{qed}}
Theorem: Number of Modified Perfect Faro Shuffles to return Deck of Cards to Original Order/Examples/Deck of 8 Cards

Let $D$ be a deck of $8$ cards.
Let $D$ be given a sequence of modified perfect faro shuffles.
Then after $6$ such shuffles, the cards of $D$ will be in the same order they started in.

Proof:
From Number of Modified Perfect Faro Shuffles to return Deck of Cards to Original Order, the cards of $D$ will return to their original order after $n$ such shuffles, where:
:$2^n \equiv 1 \pmod 9$
Inspecting $2^n$ for $n$ from $1$:
{{begin-eqn}}
{{eqn | l = 2^1
      | o = \equiv
      | r = 2
      | rr= \pmod 9
      | c = 
}}
{{eqn | l = 2^2
      | o = \equiv
      | r = 4
      | rr= \pmod 9
      | c = 
}}
{{eqn | l = 2^3
      | o = \equiv
      | r = 8
      | rr= \pmod 9
      | c = 
}}
{{eqn | l = 2^4
      | o = \equiv
      | r = 7
      | rr= \pmod 9
      | c = 
}}
{{eqn | l = 2^5
      | o = \equiv
      | r = 5
      | rr= \pmod 9
      | c = 
}}
{{eqn | l = 2^6
      | o = \equiv
      | r = 1
      | rr= \pmod 9
      | c = 
}}
{{end-eqn}}
Hence the result.
{{qed}}
Theorem: Number of Modified Perfect Faro Shuffles to return Deck of Cards to Original Order/Examples/Deck of 12 Cards

Let $D$ be a deck of $12$ cards.
Let $D$ be given a sequence of modified perfect faro shuffles.
Then after $12$ such shuffles, the cards of $D$ will be in the same order they started in.

Proof:
From Number of Modified Perfect Faro Shuffles to return Deck of Cards to Original Order, the cards of $D$ will return to their original order after $n$ such shuffles, where:
:$2^n \equiv 1 \pmod {13}$
From Fermat's Little Theorem:
:$2^{12} \equiv 1 \pmod {13}$
so we know that $n$ is at most $12$.
But $n$ may be smaller, so it is worth checking the values:
Inspecting $2^n$ for $n$ from $1$:
{{begin-eqn}}
{{eqn | l = 2^1
      | o = \equiv
      | r = 2
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^2
      | o = \equiv
      | r = 4
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^3
      | o = \equiv
      | r = 8
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^4
      | o = \equiv
      | r = 3
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^5
      | o = \equiv
      | r = 6
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^6
      | o = \equiv
      | r = 12
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^7
      | o = \equiv
      | r = 11
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^8
      | o = \equiv
      | r = 9
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^9
      | o = \equiv
      | r = 5
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^{10}
      | o = \equiv
      | r = 10
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^{11}
      | o = \equiv
      | r = 7
      | rr= \pmod {13}
      | c = 
}}
{{eqn | l = 2^{12}
      | o = \equiv
      | r = 1
      | rr= \pmod {13}
      | c = 
}}
{{end-eqn}}
Hence the result.
{{qed}}
Theorem: Difference of Two Fourth Powers

:$x^4 - y^4 = \paren {x - y} \paren {x + y} \paren {x^2 + y^2}$

Proof:
{{begin-eqn}}
{{eqn | l = x^4 - y^4
      | r = \paren {x^2}^2 - \paren {y^2}^2
      | c = 
}}
{{eqn | r = \paren {x^2 - y^2} \paren {x^2 + y^2}
      | c = Difference of Two Squares
}}
{{eqn | r = \paren {x - y} \paren {x + y} \paren {x^2 + y^2}
      | c = Difference of Two Squares
}}
{{end-eqn}}
{{qed}}
Theorem: Sum of Two Odd Powers

Let $\F$ be one of the standard number systems, that is $\Z, \Q, \R$ and so on.
Let $n \in \Z_{\ge 0}$ be a positive integer.
Then:
{{begin-eqn}}
{{eqn | l = a^{2 n + 1} + b^{2 n + 1}
      | r = \paren {a + b} \sum_{j \mathop = 0}^{2 n} \paren {-1}^j a^{2 n - j} b^j
      | c = 
}}
{{eqn | r = \paren {a + b} \paren {a^{2 n} - a^{2 n - 1} b + a^{2 n - 2} b^2 - \dotsb - a b^{2 n - 1} + b^{2 n} }
      | c = 
}}
{{end-eqn}}

Proof:
{{begin-eqn}}
{{eqn | l = a^{2 n + 1} + b^{2 n + 1}
      | r = a^{2 n + 1} - \paren {-\paren {b^{2 n + 1} } }
      | c = 
}}
{{eqn | r = a^{2 n + 1} - \paren {-b}^{2 n + 1}
      | c = as $n$ is odd
}}
{{eqn | r = \paren {a - \paren {-b} } \sum_{j \mathop = 0}^{2 n} a^{2 n - j} \paren {-b}^j
      | c = Difference of Two Powers
}}
{{eqn | r = \paren {a + b} \sum_{j \mathop = 0}^{2 n} \paren {-1}^j a^{2 n - j} b^j
      | c = simplifying
}}
{{end-eqn}}
{{qed}}