Skip to content

Instantly share code, notes, and snippets.

@VincentTam
Created July 28, 2025 01:24
Show Gist options
  • Save VincentTam/e1ebcf869e64058cc4eea942e49f395c to your computer and use it in GitHub Desktop.
Save VincentTam/e1ebcf869e64058cc4eea942e49f395c to your computer and use it in GitHub Desktop.
Cantor–Schröeder–Berstein Theorem

First attempt

Theoretical settings

  • $A = A_0 = \lbrace x^2 + y^2 \le 1 \rbrace$ ← unit circle
  • $B = B_0 = \lbrace \max(|x|,|y|) \le 1 \rbrace$ ← unit square
  • $f(x,y) = (x,y)/\sqrt2$ ← injection from $A$ to $B$ (shrinking by $1/\sqrt2$)
  • $g(x,y) = (x,y)/\varphi$ ← injection from $B$ to $A$ (shrinking by $1/\varphi$, where $\varphi$ is the golden ratio)

This gives a decreasing sequence of subsets of $A$ and $B$

  • $A_n = g(B_{n-1})$ is
    • a circle with radius $(\sqrt2)^{-k} \varphi^{-k}$ if $n = 2k$
    • a square with side length $(\sqrt2)^{-k} \varphi^{-(k+1)}$ if $n = 2k + 1$
  • $B_n = f(A_{n-1})$ is
    • a square with side length $(\sqrt2)^{-k} \varphi^{-k}$ if $n = 2k$
    • a circle with radius $(\sqrt2)^{-(k+1)} \varphi^{-k}$ if $n = 2k + 1$

Desmos illustration

Desmos illustration with nonempty $\bigcap_{n=0}^\infty A_n$ and $\bigcap_{n=0}^\infty B_n$: https://www.desmos.com/calculator/mtzagokbth

Technical adaptations:

  • use implicit functions of the form $F(x,y) - C = 0$ ($F(x,y) = C$ won't work) to avoid repeating equations of circle and square. fewer repeat → fewer typo
  • shift $(B_n)_n$ to the right by 3 units for easier visualization
  • use $s$ and $t$ as the reciprocal of the scaling factors for $f$ and $g$ respectively, so that they (and their $n$-th power) can be put inside the arguments in the implicit functions $A$ and $B$

Observation: Note that the shaded regions in the illustration won't include the origin.

Questions

  1. In Lemma 6 in https://web.williams.edu/Mathematics/lg5/CanBer.pdf, how can we know that " $g(f(x)) = x$ " doesn't hold in general?
  2. Is it possible that $\bigcap_{n=0}^\infty A_n$ and $\bigcap_{n=0}^\infty B_n$ contain at least two distinct members?

These questions have motivated me to slightly modify this example.

Second attempt

To add more members to ⋂ₙ Aₙ and ⋂ₙ Bₙ

  1. adjoin both A and B with three points: (0,0), (0,2) and (0,4)
  2. extend both f and g to cyclic permutation of these three points: ((0,0), (0,2), (0,4)), i.e. f((0,0)) = g((0,0)) = (0,2), … Note that on ⋂ₙ Aₙ and ⋂ₙ Bₙ (i.e. these three points), neither f ∘ g nor g ∘ f is identity function, but we have f(⋂ₙ Aₙ) = ⋂ₙ Bₙ and g(⋂ₙ Bₙ) = f(⋂ₙ Aₙ)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment