Calculus Review
Limit and Continuity
Let \(f, g\) be functions \(\mathbb R^n \rightarrow \mathbb R\)
Claim 1
If \(f\) is continuous and \(g\) is discontinuous at \(a\in \mathbb R^n\), then \(f+g\) must be discontinuous at \(a\).
proof. Assume \(f\) is continuous and \(g\) is discontinuous at \(a\in \mathbb R^n\).
Let \(L\in\mathbb R\) be arbitrary.
By the definition of discontinuity, take \(\epsilon_g > 0\) s.t. \(\forall \delta > 0. \exists x\in \mathbb R^n. |x-a|<\delta \land |g(x) -g(a)| \geq \epsilon_g\).
By the definition of continuity, take \(\delta_f > 0\) s.t. \(\forall x\in \mathbb R^n. |x-a| < \delta_f\Rightarrow |f(x) -f(a)| < \epsilon_g/2\)
Then, take \(\epsilon = \epsilon_g/2\). Let \(\delta > 0\) be arbitrary. Take \(x\in\mathbb R^n. |x-a| < \min(\delta, \delta_f)\). Therefore,
Therefore, we prove that
Claim 2
If both \(f, g\) are discontinuous at \(a\in \mathbb R^n\), then \(f+g\) can be either continuous or discontinuous.
proof. Consider the following examples,
Take \(f_1(x) := \begin{cases}1 &x = a\\0&x\neq a\end{cases}\) and \(g_1(x):= \begin{cases}-1 &x = a\\0&x\neq a\end{cases}\). Obviously \(f_1+g_1\) is continuous at \(a\).
Take \(f_2(x) := \begin{cases}1 &x = a\\0&x\neq a\end{cases}\) and \(g_2(x):= \begin{cases}1 &x = a\\0&x\neq a\end{cases}\). Obviously \(f_2+g_2\) is discontinuous at \(a\).
Claim 3
If \(f\) is continuous and \(g\) is discontinuous at \(a\in \mathbb R^n\), then \(f\times g\) can be either continuous or discontinuous.
proof. Consider the following examples,
One of \(f, g\) is continuous:
Take \(f_1(x) := 0\) and \(g_1(x):= \begin{cases}1 &x = a\\0&x\neq a\end{cases}\). \(f_1(x) g_1(x) = 0\) is continuous at \(a\).
Take \(f_2(x) := 1\) and \(g_2(x):= \begin{cases}1 &x = a\\0&x\neq a\end{cases}\). \(f_2(x)g_2(x) = g_2(x)\) is discontinuous at \(a\).
Both \(f\) and \(g\) are discontinuous:
Take \(f_3(x) := \begin{cases}1 &x = a\\0&x\neq a\end{cases}\) and \(g_3(x):= \begin{cases}0 &x = a\\1&x\neq a\end{cases}\). Obviously \(f_1(x)g_1(x) = 0\) is continuous at \(a\).
Take \(f_4(x) := \begin{cases}1 &x = a\\0&x\neq a\end{cases}\) and \(g_4(x):= \begin{cases}1 &x = a\\0&x\neq a\end{cases}\). Obviously \(f_4(x)g_4(x) = f_4(x)\) is continuous at \(a\).
Claim 4
if \(f:\mathbb R^n\rightarrow \mathbb R\) is continuous, then \(S = \{x\in\mathbb R^n:f(x)>0\}\) is open.
proof. Let \(f:\mathbb R^n\rightarrow \mathbb R\) be continuous.
Let \(x_0\in\mathbb R^n\) be arbitrary, assume \(f(x_0) = L > 0\).
By continuity of \(f\), take \(\delta > 0\) s.t. \(\forall x\in\mathbb R^n. |x-x_0| < \delta \Rightarrow |f(x) - f(x_0)| < L/2\).
Then, note that \(|f(x) - f(x_0)| < L/2 \Rightarrow f(x) > f(x_0) - L/2 = L/2 > 0\).
This implies that \(\forall x \in B(\delta, x_0). x\in S\).
Therefore, we have shown that \(\forall x_0 \in S. \exists \delta > 0. s.t. B(\delta, x_0) \subset S\), which means \(S\) is open.
Examples 1
Find \(a\) s.t. \(\forall \delta > 0, \exists x \in S. 0 < |x-a| < \delta\)
Examples 1.1
\(S = \{(x, y)\in\mathbb R^2. x^2 +y^2 < 1\}\cup\{(0, 2)\}\).
Claim. \(\forall a\in \{(x, y)\in\mathbb R^2. x^2 +y^2 < 1\}\), the condition is satisfied.
proof. Let \(a = (x_0, y_0)\) s.t. \(x_0^2 + y_0^2 = c < 1\) be arbitrary. Take \(\epsilon_0 = 1-c, 0 < \epsilon_0 < 1\).
Let \(\delta > 0\) be arbitrary.
Take \(\epsilon = \min(\frac{\epsilon_0}4, \frac{\epsilon_0}{4|x_0 + y_0|}, \frac{\delta}2)\), then note that
so that
Also,
Therefore, \(\forall a\in S_1. \forall \delta > 0, \exists x\in S. |x-a| < \delta\)
Claim. \(a = (0, 2)\) does not satisfy the condition.
proof. Let \((x_0, y_0)\in S - \{(0, 2)\} = \{(x, y)\in\mathbb R^2: x^2 +y^2 < 1\}\). Note that \(0 < x_0^2 + y_0^2 < 1\), so that \(-\sqrt1 < y_0 < \sqrt 1\).
Therefore, \((y_0-2)^2 > (1-2)^2 = 1\)
Therefore, \(\forall x\in S. |x-(0, 2)| \leq 0 \lor |x-(0, 2)|\geq 1\)
Examples 1.2
\(S = \{(x, y)\in\mathbb R^2. x^2 +y^2 < 1\}\cup\{(0, 1)\}\).
Claim. \(\forall a\in S\), the condition is satisfied.
proof. We only need to show that
The rest are proven in (1).
Let \(\delta > 0\). Take \(\delta_0 = \min(0.1, \delta/2)\).
Then,
Note that \(\delta_0 \leq 2/\delta < \delta\) and \(0 + (1-\delta_0)^2 = 1 - 2\delta_0 + \delta_0^2 \leq 1 - 0.2 + 0.01 < 1\) Therefore, \((0, 1-\delta_0)\in S\) and \(0 < |(0, 1-\delta_0) - (0, 1)| < \delta\).
Examples 1.3
\(S = \{(0, 2^{-n})\in\mathbb R^2:n\in\mathbb N\}\)
Claim. \(\forall a\in S\), the condition does NOT satisfy.
proof. Let \(a = (0, 2^{-n})\in S\) for some \(n\in\mathbb N\).
Take \(\delta = 2^{-(n+1)} > 0\).
Then, let \(m\in\mathbb N, m\neq n\).
Suppose \(m > n\), then \(2^{n-m} \leq 2^{-1}, |1-2^{n-m}|\geq 1/2\).
Suppose \(n > m\), then \(2^{n-m} \geq 2, |1-2^{n-m}| \geq 1\).
Therefore, \(|(0, 2^{-n}) - (0, 2^{-m})| \geq 2^{-n}/2 = 2^{-(n+1)}\)
Examples 1.4
\(S = \{(0, 2^{-n})\in\mathbb R^2:n\in \mathbb N\}\cup \{(0, 0)\}\)
Claim. \(a = (0, 0)\) satisfies the condition
proof. For any \(\delta > 0\), we can find some \(n\in\mathbb N\) s.t. \(2^{-n} < \delta\) so that \(0 < |(0, 2^{-n}) - (0, 0)| = 2^{-n} < \delta\)
Claim. \(\forall a\in \{(0, 2^{-n})\in\mathbb R^2. n\in\mathbb N\}, a\) does not satisfy the condition.
proof. In addition to points in (3), further notice that \(\forall n\in\mathbb N\). \(|(0, 2^{-n}) - (0, 0)| = 2^{-n} > 2^{-(n+1)}\)
Claim 5
For \(f:\mathbb R^n\rightarrow \mathbb R^k\) and \(g: \mathbb R^k\rightarrow\mathbb R^l\), if \(f\) is continuous at \(a\in\mathbb R^n\) and \(g\) is continuous at \(f(a)\), then \(g\circ f\) is continuous at \(a\).
proof. Let \(\epsilon > 0\).
Because \(g\) is continuous at \(f(a)\), take \(\delta_1 > 0\) s.t. \(\forall y\in\mathbb R^k. |y-f(a)| < \delta_1 \Rightarrow |g(y) - g(f(a))| < \epsilon\).
Because \(f\) is continuous at \(a\), take \(\delta_2 > 0\) s.t. \(\forall x\in\mathbb R^n. |x - a| < \delta_2 \Rightarrow |f(x) - f(a)| < \delta_1\)
Therefore, for any \(x\in\mathbb R^n. |x-a| <\delta_2\Rightarrow |f(x) - f(a)| < \delta_1\Rightarrow |g(f(x)) - g(f(a))| < \epsilon\).
Sequences and completeness
Claim 1
\(\vec a_j\rightarrow \vec a \land \vec b_j\rightarrow \vec b\Rightarrow \vec a_j\cdot \vec b_j \rightarrow \vec a \cdot \vec b\)
proof. First note that \(\vec a_j \rightarrow \vec a\Rightarrow \forall i\in \{1, 2, ..., n\}. a_{ij}\rightarrow a_{i\cdot}, b_{ij}\rightarrow b_{i\cdot}\), where \(a_{ij}\) is the \(i\)th component of \(\vec a_j\) and \(a_{i\cdot}\) is the \(i\)th component of \(\vec a\). Then, note that
Therefore, apply limit laws for addition and multiplication for 1-D case,
Claim 2
For \(\{a_j\}_j\subset \mathbb R^n\) and function \(f:\mathbb R^n\rightarrow\mathbb R^k\). If \(a_j\rightarrow a\) and \(f\) continuous and \(a\), then \(f(a_j)\rightarrow f(a)\).
proof. Let \(\epsilon > 0\) be arbitrary.
Since \(f\) is continuous at \(a\), take \(\delta > 0\) s.t. \(\forall x\in\mathbb R^n. |x-a|<\delta\Rightarrow |f(x)-f(a)| < \epsilon\).
Since \(a_j\rightarrow a\), take \(N\in\mathbb N^+\) s.t. \(\forall n \in\mathbb N^+. n > N\Rightarrow |a_n - a| < \delta\).
Therefore, \(|a_n - a| < \delta \Rightarrow |f(a_n) - f(a)| < \epsilon\).
We have proven that \(\forall \epsilon > 0. \exists N\in\mathbb N^+. \forall n \in\mathbb N^+ . n > N \Rightarrow |f(a_n) - f(a)| < \epsilon\). By definition of convergence, \(\lim_{j\rightarrow \infty}f(a_j) = f(a)\)
Compactness and applications
Claim 1
If \(S \subseteq \mathbb R^n\) is closed and \(\{x_j\}_j \subseteq\mathbb R^n\) converges to \(x\not\in S\), then \(\exists j\in\mathbb N^+. x_j\not\in S\).
proof. First, note that \(x\not\in S\Rightarrow x\in S^c\) and \(S\) is closed \(\Rightarrow S^c\) is open.
By the definition of open set, take \(\epsilon > 0\) s.t. \(B(\epsilon, x) \subset S^c\).
Then, note that \(x_j\rightarrow x\), by the definition of convergent sequence, take \(N\in\mathbb N^+\) s.t. \(\forall n \in\mathbb N^+. n \geq N\Rightarrow |x_n - x| < \epsilon\).
Therefore, note that \(|x_N - x|< \epsilon \Rightarrow x_N \in B(\epsilon, x) \subset S^c\Rightarrow x_N\not\in S\)
Claim 2
If \(S\) is unbounded, then exists some \(\{x_j\}_j\subset S\) that has no convergent subsequence.
proof. Construct \(\{x_j\}_j\) by the following recursive procedure.
Let \(x_1\in S, x_1\neq 0\) be arbitrary, let \(r_1 = \|x_1\|\).
Given \(x_n, r_n\), let \(x_{n+1} \in S - B(2r_n, 0), r_{n+1} = \|x_{n+1}\|\).
Note that such \(x_{n+1}\) always exists since \(S\) is unbounded.
Also, note that \(r_{n+1} = \|x_{n+1}\| \geq 2r_n \geq 2^{n-1} r_1\).
Then, we will show such sequence has no convergent subsequence.
Given any subsequence \(\{x_{k_j}\}_j\),
Let \(L\in S\) be arbitrary, let \(J > 0\) be arbitrary.
Take some \(j \geq J\) s.t. \(2^{k_j-1}r_1 \geq 1 + \|L\|\), since \(r_1 > 0\) we can always find such \(j\).
Therefore,
Therefore, \(\{x_{k_j}\}_j\) diverges.
Lemma 3
Any subsequence of convergent sequence will also converge to the same limit.
proof. Let \(\{a_j\}_j\) be convergent to some \(L\). Let \(\{a_{k_j}\}_j\) be some subsequence.
Let \(\epsilon > 0\) be arbitrary, take \(J\in\mathbb N^+\) s.t. \(\forall j > J. \|a_j-L\| < \epsilon\).
Take \(J_2 \in \mathbb N^+\) s.t. \(k_{J_2} \geq J\) so that \(\forall j > J_2. k_j > k_{J_2} \geq J\).
Therefore, \(\forall j > J_2. \|a_{k_j}- L\| < \epsilon\).
Claim 4
The Cartesian Product of two compact sets is compact.
proof. Let \(K_1 \subseteq \mathbb R^n, K_2 \subseteq \mathbb R^m\) be compact.
Let \(\{(x_j, y_j)\}_j\) be a sequence in \(K_1\times K_2\) so that \(\{x_j\}_j\in K_1, \{y_j\}_j \in K_2\).
By compactness of \(K_1\), take subsequence \(\{x_{k_j}\}_j\) that converge to some \(L_1\in K_1\).
By compactness of \(K_2\), further take \(\{y_{l_{k_j}}\}_j\) be a subsequence of \(\{y_{k_j}\}_j\) that converge to some \(L_2\in K_2\).
Then, since \(\{x_{l_{k_j}}\}_j\) is a subsequence of \(\{x_{k_j}\}_j\), \(\{x_{l_{k_j}}\}_j\) will also converge to \(L_1\) (using lemma above).
Therefore, \(\{(x_{l_{k_j}}, y_{l_{k_j}})\}_{j}\rightarrow (L_1, L_2) \in K_1\times K_2\)
By definition of compactness, \(K_1\times K_2\) is compact.
Claim 5
The closed subset of a compact set is compact.
proof 1. If \(S\) is compact, then by BW theorem \(S\) is closed and bounded. so that \(\forall s\in S. s\in B(R, 0)\) for some \(R > 0\). Then, for any closed subset \(A \subseteq S\), \(s\in A\Rightarrow s\in S\Rightarrow s\in B(R, 0)\) so that \(A\) is also bounded. Therefore, \(A\) is also closed and bounded, hence compact.
Chain Rule
Claim 1
\(q(x): = |x|^2. \nabla q(x) = 2x\)
proof For any \(x\in\mathbb R^n\),
Therefore, by the definition of derivative \(\nabla q = 2x\)
Example 1
Prove chain rule for \(g: \mathbb R\rightarrow \mathbb R^2, f: \mathbb R^2 \rightarrow \mathbb R. \phi = f\circ g\)
Given that
First, write \(g(x)=f(x, y)\) so that
by MVT, where \(\theta_{11}, \theta_{12}\in (0, 1)\). Similarly,
Therefore,
Then, by our assumption, \(x, y\) are differentiable, hence continuous, by continuous mapping theorem,
In addition, \(\theta_{11}, \theta_{12}, \theta_{21}, \theta_{22}\in (0, 1)\). Therefore, the limit above exists and equals to