Highlights of Calculus

Published

August 7, 2024

\(\epsilon, \delta\) for Limits

Danger case:

\[ \begin{aligned} \infty - \infty \\ 0 \cdot \infty \\ \frac{0}{0} \\ 0^0 \text{ or } 1^\infty \end{aligned} \]

L’Hospital Rule:

\[ \frac{f(x)}{g(x)} \rightarrow \frac{\frac{\Delta{f}}{\Delta{x}}}{\frac{\Delta{g}}{\Delta{x}}} \rightarrow \frac{f'}{g'} \]

For any small \(\epsilon\) chosen, we can find \(\delta > 0\), so that if \(|f(x) - f(a)| < \epsilon\), then \(|f(x) - f(a)| < \delta\)

Fundamental Theorem of Calculus

\[ \begin{aligned} f'(x) &= \frac{f(x + \Delta{x}) - f(x)}{\Delta{x}} \\ &= \frac{df}{dx}, \text{When} \space \Delta{x} \rightarrow 0 \end{aligned} \]

Here, \(\Delta{x}\) means two point difference in \(x\), \(df\) means difference in function value caused by the differenc in \(x\)\(\Delta{x} \rightarrow 0\) 就是代数到微积分的过程。

考虑函数值 \(x\) 在 点 \(x_1, x_2, ..., x_n\) 的函数值 \(f_1, f_2, ..., f_n\), 进而考虑其两者之间的差值 \((f_2 - f_1) + (f_3 - f_2) + \dots + (f_n - f_{n-1)} = f_n - f_1\)。从这里可以简单的理解为,你可以将一个函数,利用其差值累加还原为原函数的值,这就是积分的过程;

\[ \begin{aligned} \sum{\Delta{y}} &= y_{\text{last}} - y_{\text{first}} \\ f(x) &= \int{f'(x)dx} = \sum{\frac{\Delta{y}}{\Delta{x}} \cdot \Delta{x}} , \text{Where} \space f'(x)dx = df, \text{when} \Delta{x} \rightarrow 0 \end{aligned} \]

从这里可以看出,对于导函数可将其视为用高度函数表示原函数的函数,其高度与其底部“面积”的乘积表示了其空间大小,即原函数的差值。

对于微分还有另一种理解为变换的视角,即从一个函数变换到另一个函数-线性映射,这个映射操作的符号记做 \(\frac{d}{dx}\), 它将 \(y\) 进行变换到 \(y'\), \(y' = \frac{d}{dx} \cdot y\)

二阶导数的定义如下:

\[ y'' = \frac{d^2y}{dx^2} \]

对于这里的符号解释如下:

对于 \(dx^2\), 只是对于 \(x\) 只是进行了两次除法操作即 \(\frac{\Delta{\Delta{f}}}{\Delta{x} \cdot \Delta{x}}\),但是对于 \(y\) 而言则是在第一次的\(df\)之上再次取差值即 \(d(df)\),也就是求差值这个操作 \(d\)(diffence) 重复了两次。

\[ \begin{aligned} f''(x) > 0 &\rightarrow \text{convex function} \\ f''(x) < 0 &\rightarrow \text{concave function} \end{aligned} \]

关于一阶,以及二阶导数的主要应用在于寻找各个特殊的点。

\[ \begin{aligned} f'(x) &\rightarrow \text{stationary point} \\ f''(x) & \rightarrow \text{inflection point} \\ f'(x) = 0, \text{and} f''(x) > 0 &\rightarrow \text{Local max} \\ f'(x) = 0, \text{and} f''(x) < 0 &\rightarrow \text{Local min} \end{aligned} \]

对于函数的最值,则需要比较所有极值点以及边界点确定。

Derivatives of \(e^x, \sin{x}, \cos{x}, x^n\)

Exponential Function

Key: Which function’s derivatives are equal to the function itself?

\[ \frac{df}{dx} = y \rightarrow \text{first differential equation} \]

Construction:

\[ \begin{aligned} y(x) = 1 + x + \frac{1}{2}x^2 + \frac{1}{3 \cdot{2} \cdot{1}}x^3 + \dots + \frac{1}{n!}x^n + \dots \\ \frac{df}{dx} = 1 + x + \frac{1}{2}x^2 + \frac{1}{3 \cdot{2} \cdot{1}}x^3 + \dots + \frac{1}{n!}x^n + \dots \end{aligned} \]

这里思想在于当 \(\text{when} \space x = 0, e^x = 1\), 那么其导数也为 \(1\); 导数为 \(1\),原函数为什么其导数才为 \(1\) 呢?如此反复迭代;显然当 \(n \rightarrow \infty\), 两式才相等。该级数称之为指数级数。

\[ e^x = 1 + x + \frac{1}{2}x^2 + \frac{1}{3 \cdot{2} \cdot{1}}x^3 + \dots + \frac{1}{n!}x^n + \dots \]

set \(x = 0\), \(e = 1 + 1 + \dots = 2.71828... \rightarrow \text{Euler's Number}\)

用指数级数可证明指数函数下面的性质

\[ e^{a} \cdot e^{b} = e^{a + b} \]

Euler’s Number 也可以通过如下方式计算得到

\[ e = (1 + \frac{1}{N + 1})^N, \text{When} \space N \rightarrow \infty \]

对于该式子的展开基于二项式定理(Binomial Theorem).

\[ \frac{dy}{dx} = y \]

\[ y = f(x) = 1 + x + \frac{1}{2}x^2 + ... + \frac{1}{n!}x^n + ... = e \]

Trigonometric Function

三角函数起源于勾股定理

\[ \begin{aligned} a^2 + b^2 &= c^2 \\ (\frac{a}{c})^2 + (\frac{b}{c})^2 &= 1\\ (\sin{\theta})^2 + (\cos{\theta})^2 &= 1 \end{aligned} \]

三角函数求导关键在于用半径为1的圆描述周期运动,以及其中的三角形。

下面给两个重要的极限

\[ \begin{aligned} \sin{\theta} &< \theta \rightarrow \frac{\sin{\theta}}{\theta} < 1 \\ \tan{\theta} &> \theta \rightarrow \frac{\sin{\theta}}{\theta} > \cos{\theta} \\ \frac{\sin{\theta}}{\theta} &= 1, \text{when} \space \theta \rightarrow 0 \end{aligned} \]

前两个式子可由弧度制的弧长和面积证明,该极限可认为是 \(\sin{0}\) 处的导数, 由上面两个式子夹逼准则定义。

下面给出另一个重要的极限。

\[ \frac{\cos{\theta} - 1}{\theta} = 1, \text{when} \space \theta \rightarrow 0 \]

该极限可认为是 \(\cos{0}\) 处的导数。

\[ \begin{aligned} \frac{\Delta{\sin{x}}}{\Delta{x}} &= \frac{\sin{(x + \Delta{x})} - \sin {x}}{\Delta{x}} \\ &= \frac{\sin{x}(\cos{\Delta{x} - 1})}{\Delta{x}} + \frac{\sin\Delta{x} \cos{x}}{\Delta{x}} \\ &= \cos{x} \end{aligned} \]

仿照上例子可得到 \(\cos{\theta}\) 的导数;下面不加证明地给出 \(\cos{x}\) 的导数

\[ \frac{d\cos{x}}{dx} = - \sin{x} \]

Product Rule, Quotient Rule, Derivaitives to Power Function

\(q(x) = f(x)g(x)\)

考虑边长分别为 \(f(x), g(x)\), 的长方形,当两边分别改变 \(\Delta x\), 其面积的变化:

\[ \Delta\text{area} = f(x)g(x + \Delta{x}) - g(x)) + g(x)(f(x + \Delta{x} - f(x))) + \Delta{x}^2 \]

When \(\Delta{x} \rightarrow 0\),

\[ \begin{aligned} dq &= f(x)dg + g(x)df \\ \frac{dq}{dx} &= f(x)\frac{dg}{dx} + g(x)\frac{df}{dx} \end{aligned} \]

Quation rule 可由乘法法则推导得到。

\[ \frac{f(x)}{g(x)} = \frac{f(x)g' - g(x)f'}{g(x)^2} \]

Chain Rule, and Derivatives of Inverse Function \(\ln{x}, \sin^{-1}x, \cos^{-1}x\)

Chain Rule

\[ f'(y(x)) = \frac{df}{dx} = \frac{df}{dy}\frac{dy}{dx} \]

对于偶函数,其导数为奇函数。对于奇函数,其导数为偶函数。

\[ y = f(x) \rightarrow x = f^{-1}(y) \]

需要注意的是只有在单调区间内,才有逆函数,且 \(f\)\(f^{-1}\) 的函数图像关于原点对称。

Logarithmic Function

指数函数的逆函数为对数函数,其求的是指数的值。

\[ x = \ln{y} \]

其具有如下性质

\[ \begin{aligned} \ln{ab} &= \ln{a} + \ln{b} \\ \ln{y^n} &= n\ln{y} \end{aligned} \]

Derivatives for \(\ln{x}, \sin^{-1}{x}, \cos^{-1}{x}\)

set

\[ \begin{aligned} y &= e^x \\ x &= \ln{y} \end{aligned} \]

Then \[ \begin{aligned} y = e^x \rightarrow e^{\ln{y}} = y \\ e^{\ln{y}} \cdot \frac{d\ln{y}}{dy} = 1, \text{Where} \space e^{\ln{y}} = y\\ \end{aligned} \]

set

\[ \begin{aligned} y &= \sin{x} \\ x &= \sin^{-1}{y} \end{aligned} \]

Then

\[ \begin{aligned} \sin{\sin^{-1}{y}} &= y\\ \cos{\sin^{-1}{y}} \cdot \frac{d \sin^{-1}y}{y} &= 1, \text{Where} \cos{\sin^{-1}{y}} = \frac{1}{\sqrt{1 - y^2}} \end{aligned} \]

Note that the \(\sin^{-1}y\) is an angle.

Give the \(\frac{d\cos^{-1}y}{dy}\) without proof.

\[ \frac{d\cos^{-1}y}{dy} = -\frac{1}{\sqrt{1 - y^2}} \]

Note that:

\[ \frac{d\cos^{-1}y}{dy} + \frac{d\sin^{-1}y}{dy} = 0 \]

Where \(\theta + \alpha = \frac{\pi}{2}\) is a constant.

Some other deritivites:

\[ \begin{aligned} \frac{d\arctan{x}}{x} = \frac{1}{1 + x^2} \\ \frac{d \space \text{acrcot} \space {x}}{x} = -\frac{1}{1 + x^2} \\ \frac{d{a^x}}{x} = a^{x} \ln{a} \end{aligned} \]

Converion between different base. \[ \begin{aligned} \log_a{|x|} &= \frac{1}{x\ln{a}} \\ \log_{a}{b} &= \frac{\ln{b}}{\ln{a}} = \frac{\log_n{b}}{\log_n{a}} \end{aligned} \]

Growth Rate and Logarithmic Plot

各函数的增长速度如下,其倒数就是减慢的速度。 \[ \begin{aligned} &CX\dots \space &x^2, x^3 \dots \space &2^x, e^x, 10^x \dots &x! \space x^x \\ &\text{Linear} &\text{Polynomial} \space &\text{Exponential} &\text{Factorial} \end{aligned} \]

对数尺度能够处理极大或者极小( \(x \rightarrow 0\) )的值, 但是该尺度下是没有 \(0\) 的。

对数尺度能够将非线性问题转换为线性问题

\[ \begin{aligned} y = AX^n \rightarrow \log{y} = \log{A} + n\log{X}, \text{logarithmic plot} \\ y = B10^{Cx} \rightarrow \log{y} = \log{B} + Cx, \text{semi-logarithmic plot} \end{aligned} \]

Linear Approximation/Newton’s Method

\[ f(x) = f(a) + f'(a)(x - a) \]

\[ F(x) = 0 \rightarrow x - a = \frac{F(a)}{F'(a)} \]

The core of Newton’s method is iteration.

Power Series/Euler’s Great Formula

幂级数的核心在于用多项式进行函数的近似,用多项式近似的好处在于其 \(n\) 阶导数只和第 \(n\) 阶项有关,其它在此之前的多项式都为0,第 \(n\) 阶项的系数为 \(n!\)

考虑指数级数,在 \(0\) 处的 \(0, 1, 2, \dots, n\) 导数值。

\[ 1, 1, 1, \dots, 1 \]

为了匹配这个系数,对于幂函数的 \(n\) 阶项的导数系数 \(n!\)\(n!\) 则可匹配每一阶的系数。

\[ e^x = 1 + x + \frac{1}{2}x^2 + \dots + \frac{1}{n!}x^n + \dots \]

仿照上例,给出 \(\sin{x}, \cos{x}\) 的幂级数

\[ \begin{aligned} \sin x &= \sum_{n=0}^{\infty} (-1)^n \frac{x^{2n+1}}{(2n+1)!} \\ \cos x &= \sum_{n=0}^{\infty} (-1)^n \frac{x^{2n}}{(2n)!} \end{aligned} \]

对于欧拉公式,可由上面三个级数给出

\[ e^{i\theta} = 1 + ix + \frac{1}{2}(ix)^2 + \frac{1}{6}(ix)^3 + \dots \]

整理之后可见,右边即为 \(\sin{x},\cos{x}\) 的幂级数。

\[ e^{i\theta} = \cos{x} + i \sin{x} \]

欧拉公式给出了在横轴为实数,纵轴为复数的复平面上,数据之间的关系。

下面给出两个其它重要的幂级数

\[ \begin{aligned} &\text{Geometrix series} \space \frac{1}{1 -x} = 1 + x + x^2 + \dots + x^n + \dots, \text{Where} \space 0 < |x| < 1 \\ &\text{Integrated from the above equation} - \ln{(1 - x)} = x + \frac{1}{2}x^2 + \frac{1}{3}x^3 + \dots \text{Where } x < 1 \end{aligned} \]

Differential Equations

Differential Equations of Motion

Linear, and Second order equation.

\[ m\frac{d^2y}{dt^2} + 2r\frac{dy}{dt} + ky = 0 \]

When \(m = 0\)

\[ \frac{dy}{dt} = ay \rightarrow y = ce^{at} \]

When \(r = 0\)

\[ \frac{d^2y}{dt^2} = \frac{k}{m}y = -\omega^2y \rightarrow y = C\cos{\omega{t}} + D\sin{\omega{t}} \]

When \(m = r = 0\)

\[ \frac{d^2y}{dt^2} = 0 \rightarrow y = C + Dt \]

General solutaion - Try \(y = e^{\lambda{t}}\)

\[ m\lambda^2 + 2r\lambda + K = 0 \]

Three Cases:

\[ \begin{aligned} y'' + 6y' + 8y = 0 &\rightarrow y(t) = Ce^{-2t} + De^{-4t} \\ y'' + 6y' + 10y = 0 &\rightarrow y(t) = Ce^{(-3 - i)t} + De^{(-3 + i)t} \\ y'' + 6y' + 9 = 0 &\rightarrow y(t) = Ce^{-3t} + Dte^{-3t} \end{aligned} \]

Differential Equations of Growth

The growth rate proportional to itself. \[ \begin{aligned} \frac{dy}{dt} &= cy \\ y(0) &\rightarrow \text{Given start} \\ y(t) &= y(0)e^{ct} \end{aligned} \]

Add source term:

\[ \begin{aligned} \frac{dy}{dt} &= cy + s \space \text{Where} \space s \space \text{is source term} \\ \frac{d{(y + \frac{s}{c}})}{dt} &= c(y + \frac{s}{c}) \\ y + \frac{s}{c} &= (y(0) + \frac{s}{c})e^{ct} \end{aligned} \]

For Linear eq, the solutions to eq have form below

\[ y(t) = y_{\text{particular}}(t) + y_{\text{right side 0}}(t) \]

Specially for \(\frac{dy}{dt} = cy + s\)

\[ \begin{aligned} y_{\text{particular}} = -\frac{s}{c} \\ y_{\text{set s = 0}} = Ae^{ct} \end{aligned} \]

Then

\[ y = -\frac{s}{c} + Ae^{ct} \]

To find \(A\), put \(t = 0\), \(y(0) = \frac{s}{c} + A\)

Non-linear equation for population:

\[ \frac{dp}{dt} = cp - sp^2 \]

To solve this equation, set \(y = \frac{1}{p}\) to turn this equation to linear equation.

Equation for predators and prey

\[ \begin{aligned} \frac{du}{dt} &= - cu + suv \\ \frac{dv}{dt} &= cv - suv \end{aligned} \]

Six Functions, Six Rules, and Six Theorems

Six Functions \[ \begin{aligned} \frac{1}{n + 1}x^{n + 1} &\rightarrow x^n &\rightarrow (n-1)x^{n-1} \\ -\cos{x} &\rightarrow \sin{x} &\rightarrow \cos{x} \\ \sin{x} &\rightarrow \cos{x} &\rightarrow -\sin{x} \\ \frac{1}{c}e^{cx} &\rightarrow e^{cx} &\rightarrow ce^{cx} \\ x\ln{x} -x &\rightarrow \ln{x} &\rightarrow \frac{1}{x} \text{power -1} \\ \text{Ramp Function} \end{aligned} \]

Six Rules \[ \begin{aligned} af(x) + bg(x) &\rightarrow a\frac{df}{dx} + b\frac{dg}{dx} \\ f(x)g(x) &\rightarrow f(x)\frac{dg}{dx} + \frac{df}{dx}(gx) \\ \frac{f(x)}{g(x)} &\rightarrow \frac{gf' - fg'}{g^2} \\ x = f^{-1}(y) &\rightarrow \frac{dx}{dy} = \frac{1}{\frac{dy}{dx}} \\ f(g(x)) &\rightarrow \frac{df}{dy}\cdot \frac{dy}{dx} \\ \text{L'Hospital} \space \frac{f}{g} = \frac{\frac{df}{dx}}{\frac{dg}{dx}} \text{When} \space x &\rightarrow a, f(a), g(a) \rightarrow 0 \end{aligned} \]

Six Theorems

  • Fundamental Theorem of Calculus
  • Mean Values Theorem
  • Taylors Series/Theorem
  • Bionomial Theorem - Taylor at a = 0 \(\rightarrow\) Pascal triangle

\[ f(x) = (1 + x)^p = 1 + px + \frac{p(p-1)}{2\cdot 1}x^2 + \dots \]