Calculus/Derivatives

Derivative of a function f at a number a

Notation

We denote the derivative of a function ${\displaystyle f}$  at a number ${\displaystyle a}$  as ${\displaystyle f'(a)\,\!}$ .

Definition

The derivative of a function ${\displaystyle f}$  at a number ${\displaystyle a}$  a is given by the following limit (if it exists):

${\displaystyle f'(a)=\lim _{h\rightarrow 0}{\frac {f(a+h)-f(a)}{h}}}$

An analagous equation can be defined by letting ${\displaystyle x=(a+h)}$ . Then ${\displaystyle h=(x-a)}$ , which shows that when ${\displaystyle x}$  approaches ${\displaystyle a}$ , ${\displaystyle h}$  approaches ${\displaystyle 0}$ :

${\displaystyle f'(a)=\lim _{x\rightarrow a}{\frac {f(x)-f(a)}{x-a}}}$

Interpretations

As the slope of a tangent line

Given a function ${\displaystyle y=f(x)\,\!}$ , the derivative ${\displaystyle f'(a)\,\!}$  can be understood as the slope of the tangent line to ${\displaystyle f(x)}$  at ${\displaystyle x=a}$ :

Example

Find the equation of the tangent line to ${\displaystyle y=x^{2}}$  at ${\displaystyle x=1}$ .

Solution

To find the slope of the tangent, we let ${\displaystyle y=f(x)}$  and use our first definition:

${\displaystyle f'(a)=\lim _{h\rightarrow 0}{\frac {f(a+h)-f(a)}{h}}\Rightarrow \lim _{h\rightarrow 0}{\frac {\color {Blue}(a+h)^{2}-(a)^{2}}{h}}\Rightarrow \lim _{h\rightarrow 0}{\frac {\color {Blue}a^{2}+2ah+h^{2}-a^{2}}{h}}\Rightarrow \lim _{h\rightarrow 0}{\frac {\color {Blue}h(2a+h)}{h}}\Rightarrow \lim _{h\rightarrow 0}{\color {Blue}(2a+h)}}$

It can be seen that as ${\displaystyle h}$  approaches ${\displaystyle 0}$ , we are left with ${\displaystyle f'(a)={\color {Blue}2a}\,\!}$ . If we plug in ${\displaystyle 1}$  for ${\displaystyle a}$ :

${\displaystyle f'({\color {Red}1})=2({\color {Red}1})\Rightarrow {\color {Red}2}}$

So our preliminary equation for the tangent line is ${\displaystyle y={\color {Red}2}x+b}$ . By plugging in our tangent point ${\displaystyle (1,1)}$  to find ${\displaystyle b}$ , we can arrive at our final equation:

${\displaystyle {\color {Red}1}=2({\color {Red}1})+b\Rightarrow -1=b}$

So our final equation is ${\displaystyle y=2x-1\,\!}$ .

As a rate of change

The derivative of a function ${\displaystyle f(x)}$  at a number ${\displaystyle a}$  can be understood as the instantaneous rate of change of ${\displaystyle f(x)}$  when ${\displaystyle x=a}$ .

The derivative as a function

So far we have only examined the derivative of a function ${\displaystyle f}$  at a certain number ${\displaystyle a}$ . If we move from the constant ${\displaystyle a}$  to the variable ${\displaystyle x}$ , we can calculate the derivative of the function as a whole, and come up with an equation that represents the derivative of the function ${\displaystyle f}$  at any arbitrary ${\displaystyle x}$  value. For clarification, the derivative of ${\displaystyle f}$  at ${\displaystyle a}$  is a number, whereas the derivative of ${\displaystyle f}$  is a function.

Notation

Likewise to the derivative of ${\displaystyle f}$  at ${\displaystyle a}$ , the derivative of the function ${\displaystyle f(x)}$  is denoted ${\displaystyle f'(x)\,\!}$ .

Definition

The derivative of the function ${\displaystyle f}$  is defined by the following limit:

${\displaystyle f'(x)=\lim _{h\rightarrow 0}{\frac {f(x+h)-f(x)}{h}}}$

Also,

${\displaystyle f'(x)=\lim _{h\rightarrow x}{\frac {f(x)-f(h)}{x-h}}}$

or

${\displaystyle f'(x)=\lim _{h\rightarrow 0}{\frac {f(x+h)-f(x-h)}{2h}}}$

d(x^n)/dx

 Consider the sequences: ${\displaystyle y=x^{2};\ y+\Delta y=(x+h)^{2}=x^{2}+2xh+h^{2}}$  ${\displaystyle y=x^{3};\ y+\Delta y=(x+h)^{3}=x^{3}+3x^{2}h+3xh^{2}+h^{3}}$  ${\displaystyle y=x^{4};\ y+\Delta y=(x+h)^{4}=x^{4}+4x^{3}h+6x^{2}h^{2}+4xh^{3}+h^{4}}$  ${\displaystyle y=x^{5};\ y+\Delta y=(x+h)^{5}=x^{5}+5x^{4}h+10x^{3}h^{2}+10x^{2}h^{3}+5xh^{4}+h^{5}}$  ${\displaystyle y=x^{6};\ y+\Delta y=(x+h)^{6}=x^{6}+6x^{5}h\ +}$  many terms containing ${\displaystyle h^{2}}$  ${\displaystyle y=x^{n};\ y+\Delta y=(x+\Delta x)^{n}=x^{n}+nx^{n-1}\Delta x\ +}$  many terms containing ${\displaystyle (\Delta x)^{2}}$  ${\displaystyle \Delta y=nx^{n-1}\Delta x\ +}$  many terms containing ${\displaystyle (\Delta x)^{2}}$  Therefore: ${\displaystyle {\frac {\Delta y}{\Delta x}}=nx^{n-1}\ +}$  many terms with each and every term containing ${\displaystyle \Delta x}$  ${\displaystyle {\frac {dy}{dx}}=\lim _{\Delta x\rightarrow 0}{\frac {\Delta y}{\Delta x}}}$  ${\displaystyle {\frac {d(x^{n})}{dx}}=nx^{n-1}}$  read as "derivative with respect to ${\displaystyle x}$  of ${\displaystyle x}$  to the power ${\displaystyle n}$ ." Later it will be shown that this is valid for all real ${\displaystyle n}$ , positive or negative, integer or fraction.

Examples

 ${\displaystyle {\frac {d(x^{4})}{dx}}=4x^{(4-1)}=4x^{3}}$  ${\displaystyle {\frac {d(7x^{5})}{dx}}=7{\frac {d(x^{5})}{dx}}=7(5x^{4})=35x^{4}}$  ${\displaystyle {\frac {d(p^{3})}{dx}}={\frac {d(p^{3})}{dp}}}$ ⋅${\displaystyle {\frac {dp}{dx}}=3p^{2}}$ ⋅${\displaystyle {\frac {dp}{dx}}}$  ${\displaystyle {\frac {d(2t^{2}-7T^{3}+x^{7})}{dx}}=4t}$ ⋅${\displaystyle {\frac {dt}{dx}}-7(3T^{2})}$ ⋅${\displaystyle {\frac {dT}{dx}}+7x^{6}}$  ${\displaystyle {\frac {d(x^{\frac {1}{3}})}{dx}}={\frac {1}{3}}x^{{\frac {1}{3}}-1}={\frac {1}{3}}x^{-{\frac {2}{3}}}}$

Without Using Calculus

Derivative of cubic function

 Graph of cubic function illustrating use of associated quadratic. When ${\displaystyle x==7.5,}$  there is exactly 1 value of ${\displaystyle x}$  that gives ${\displaystyle f(x)=f(7.5).}$  When ${\displaystyle x==3,}$  there are 3 values of ${\displaystyle x}$  that give ${\displaystyle f(x)=f(3).}$  When ${\displaystyle x==p,}$  there are exactly 2 values of ${\displaystyle x}$  that give ${\displaystyle f(x)=f(p).}$  Point ${\displaystyle (p,f(p))}$  is a stationary point.In the diagram there is a stationary point at ${\displaystyle x=p.}$  When ${\displaystyle x=p,}$  there are exactly 2 values of ${\displaystyle x}$  that produce ${\displaystyle f(x)=f(p).}$  Aim of this section is to derive the condition that produces exactly 2 values of ${\displaystyle x.}$  See Cubic function as product of linear function and quadratic. The associated quadratic when ${\displaystyle x=p:}$  ${\displaystyle A=a}$  ${\displaystyle B=Ap+b=ap+b}$  ${\displaystyle C=Bp+c=app+bp+c.}$  Divide ${\displaystyle g(x)=ax^{2}+(ap+b)x+(ap^{2}+bp+c)}$  by ${\displaystyle (x-p).}$  This division gives a quotient of ${\displaystyle ax+(2ap+b)}$  and remainder of ${\displaystyle h(p)=3ap^{2}+2bp+c.}$  Factor ${\displaystyle (x-p)}$  divides ${\displaystyle g(x)}$  exactly. Therefore, remainder ${\displaystyle h(p)=0,}$  the desired condition. When ${\displaystyle x=p,\ h(x)=3ax^{2}+2bx+c,}$  the derivative of ${\displaystyle f(x).}$

Derivative of quartic function

The quartic function: ${\displaystyle y=f(x)=ax^{4}+bx^{3}+cx^{2}+dx+e\ \dots \ (1)}$

In ${\displaystyle (1)}$  substitute ${\displaystyle (p+q)}$  for ${\displaystyle x\ \dots \ (2a).}$

In ${\displaystyle (1)}$  substitute ${\displaystyle (p-q)}$  for ${\displaystyle x\ \dots \ (3a).}$

${\displaystyle (2a)+(3a):\ +2apppp+12appqq+2aqqqq+2bppp+6bpqq+2cpp+2cqq+2dp+2e\ \dots \ (4)}$

${\displaystyle (2a)-(3a):\ +8apppq+8apqqq+6bppq+2bqqq+4cpq+2dq\ \dots \ (5)}$

Reduce (4) and (5) and substitute Q for qq:

${\displaystyle +apppp+6appQ+aQQ+bppp+3bpQ+cpp+cQ+dp+e\ \dots \ (4a)}$

${\displaystyle +4appp+4apQ+3bpp+bQ+2cp+d\ \dots \ (5a)}$

Combine (4a) and (5a) to eliminate p and produce a function in Q:

 ${\displaystyle C_{11}Q^{11}+C_{10}Q^{10}+C_{9}Q^{9}+\ \cdots \ +C_{2}Q^{2}+C_{1}Q+C_{0}}$  where: ${\displaystyle C_{11}=(-65536aaaaaaaaaabb)}$  ${\displaystyle C_{10}=(-131072aaaaaaaaaabd-229376aaaaaaaaabbc+94208aaaaaaaabbbb)}$  ${\displaystyle \cdots \cdots }$  ${\displaystyle C_{2}=(-8192aaaaaabdeeee+20480aaaaaacddeee\cdots -288aabbbccccddd+32aabbccccccdd)}$  ${\displaystyle C_{1}=(-4096aaaaaaddeeee-4096aaaaabcdeeee\cdots +64aabbcccccdde-20aabbccccdddd)}$  C0 = (- 2048aaaaacddeeee + 768aaaaaddddeee + 1536aaaabcdddeee - 576aaaabdddddee + 1024aaaacccddeee - 1536aaaaccddddee + 648aaaacdddddde - 81aaaadddddddd - 1152aaabbccddeee + 480aaabbcddddee - 18aaabbdddddde + 640aaabcccdddee - 384aaabccddddde + 54aaabcddddddd - 128aaacccccddee + 80aaaccccdddde - 12aaacccdddddd + 216aabbbbcddeee - 81aabbbbddddee - 144aabbbccdddee + 86aabbbcddddde - 12aabbbddddddd + 32aabbccccddee - 20aabbcccdddde + 3aabbccdddddd)

Coefficient of interest is ${\displaystyle C_{0}}$  which is in fact the value ${\displaystyle Rs-Sr.}$  See Equal Roots of Quartic Function.

If ${\displaystyle C_{0}==0,\ q=Q=0}$  is a solution and ${\displaystyle f(x)}$  contains at least 2 roots of format ${\displaystyle p+0,p-0.}$  In other words 2 equal roots where ${\displaystyle x=p.}$

If ${\displaystyle Q==0,\ (4a)}$  and ${\displaystyle (5a)}$  become:

${\displaystyle ap^{4}+bp^{3}+cp^{2}+dp+e\ \dots \ (4b)}$

${\displaystyle 4ap^{3}+3bp^{2}+2cp+d\ \dots \ (5b)}$

${\displaystyle (4b)}$  is equivalent to ${\displaystyle f(x)}$  and ${\displaystyle (5b)}$  is derivative of ${\displaystyle (4b).}$

Product Rule

Let ${\displaystyle y=u}$ ${\displaystyle v}$  where ${\displaystyle u=U(x);\ v=V(x)}$

${\displaystyle y+\Delta y=(u+\Delta u)}$ ${\displaystyle (v+\Delta v)=u}$ ${\displaystyle v+u}$ ${\displaystyle \Delta v+v}$ ${\displaystyle \Delta u+\Delta u}$ ${\displaystyle \Delta v}$

${\displaystyle \Delta y=u}$ ${\displaystyle \Delta v+v}$ ${\displaystyle \Delta u+\Delta u}$ ${\displaystyle \Delta v}$

${\displaystyle {\frac {\Delta y}{\Delta x}}=u}$ ${\displaystyle {\frac {\Delta v}{\Delta x}}+v}$ ${\displaystyle {\frac {\Delta u}{\Delta x}}+{\frac {(\Delta u)(\Delta v)}{\Delta x}}}$

${\displaystyle {\frac {dy}{dx}}=u}$ ${\displaystyle {\frac {dv}{dx}}+v}$ ${\displaystyle {\frac {du}{dx}}}$

Examples

 Let ${\displaystyle y=x^{\frac {m}{n}}.}$  Calculate ${\displaystyle {\frac {dy}{dx}}}$  ${\displaystyle y^{n}=x^{m}}$  Differentiate both sides. ${\displaystyle ny^{n-1}\cdot {\frac {dy}{dx}}=mx^{m-1}}$  ${\displaystyle {\frac {dy}{dx}}={\frac {mx^{m-1}}{ny^{n-1}}}}$  ${\displaystyle ={\frac {mx^{m-1}}{n(x^{\frac {m}{n}})^{n-1}}}}$  ${\displaystyle ={\frac {mx^{m-1}}{nx^{m-{\frac {m}{n}}}}}}$  ${\displaystyle ={\frac {m}{n}}\cdot x^{m-1-m+{\frac {m}{n}}}}$  ${\displaystyle ={\frac {m}{n}}\cdot x^{{\frac {m}{n}}-1}}$  This shows that ${\displaystyle {\frac {d(x^{n})}{dx}}}$  as above is valid when ${\displaystyle n}$  is a positive fraction.
 Let ${\displaystyle y=x^{-n}={\frac {1}{x^{n}}}}$ . Calculate ${\displaystyle {\frac {dy}{dx}}}$ . ${\displaystyle yx^{n}=1}$  Differentiate both sides. ${\displaystyle ynx^{n-1}+x^{n}{\frac {dy}{dx}}=0}$  ${\displaystyle {\frac {dy}{dx}}=-{\frac {ynx^{n-1}}{x^{n}}}=-{\frac {nx^{n-1}}{x^{n}x^{n}}}=-nx^{n-1}x^{-2n}=-nx^{-n-1}}$  This shows that ${\displaystyle {\frac {d(x^{n})}{dx}}}$  as above is valid for negative ${\displaystyle n}$ .
 Let ${\displaystyle y=x^{-{\frac {m}{n}}}}$ . Calculate ${\displaystyle {\frac {dy}{dx}}}$ . ${\displaystyle y^{n}=x^{-m}}$  Differentiate both sides. ${\displaystyle ny^{n-1}{\frac {dy}{dx}}=-mx^{-m-1}}$  ${\displaystyle {\frac {dy}{dx}}=-{\frac {mx^{-m-1}}{ny^{n-1}}}=-{\frac {mx^{-m-1}}{n(x^{-{\frac {m}{n}}})^{n-1}}}}$  ${\displaystyle =-{\frac {mx^{-m-1}}{nx^{-m+{\frac {m}{n}}}}}}$  ${\displaystyle =-{\frac {m}{n}}x^{-m-1+m-{\frac {m}{n}}}}$  ${\displaystyle =-{\frac {m}{n}}x^{-{\frac {m}{n}}-1}}$  This shows that ${\displaystyle {\frac {d(x^{n})}{dx}}}$  as above is valid when ${\displaystyle n}$  is a negative fraction.

Quotient rule

Used where ${\displaystyle y={\frac {U(x)}{V(x)}}}$

${\displaystyle y={\frac {u}{v}}}$

${\displaystyle yv=u}$

${\displaystyle yv'+vy'=u'}$

${\displaystyle vy'=u'-yv'=u'-{\frac {uv'}{v}}}$

${\displaystyle y'={\frac {u'}{v}}-{\frac {uv'}{v^{2}}}={\frac {vu'}{v^{2}}}-{\frac {uv'}{v^{2}}}={\frac {vu'-uv'}{v^{2}}}}$

Derivatives of trigonometric functions

sine(x)

${\displaystyle y=\sin(x)}$

${\displaystyle y+\Delta y=\sin(x+\Delta x)=\sin(x)\cos(\Delta x)+\cos(x)\sin(\Delta x)}$

${\displaystyle \Delta y=\sin(x)\cos(\Delta x)+\cos(x)\sin(\Delta x)-\sin(x)}$

${\displaystyle {\frac {\Delta y}{\Delta x}}=\sin(x)}$ ${\displaystyle {\frac {\cos(\Delta x)-1}{\Delta x}}+\cos(x)}$ ${\displaystyle {\frac {\sin(\Delta x)}{\Delta x}}}$

The value ${\displaystyle {\frac {\cos(\Delta x)-1}{\Delta x}}}$ :

>>> # python code
>>> [ (math.cos(Δx)-1)/Δx for Δx in (.1,.01,.001,.0001,.0000_1,.0000_01,.0000_001,.0000_0001,.0000_0000_1) ]
[-0.049958347219742905, -0.004999958333473664, -0.0004999999583255033,
-4.999999969612645e-05, -5.000000413701855e-06, -5.000444502911705e-07,
-4.9960036108132044e-08, 0.0, 0.0]
>>>


${\displaystyle \lim _{\Delta x\rightarrow 0}{\frac {\cos(\Delta x)-1}{\Delta x}}=\lim _{\Delta x\rightarrow 0}{\frac {-\sin(\Delta x)}{1}}=0}$  by L'Hôpital's rule.

The value ${\displaystyle {\frac {\sin(\Delta x)}{\Delta x}}}$ :

>>> # python code
>>> [ math.sin(Δx)/Δx for Δx in (.1,.01,.001,.0001,.0000_1,.0000_01,.0000_001,.0000_0001,.0000_0000_1) ]
[0.9983341664682815, 0.9999833334166665, 0.9999998333333416,
0.9999999983333334, 0.9999999999833332, 0.9999999999998334,
0.9999999999999983, 1.0, 1.0]
>>>


${\displaystyle \lim _{\Delta x\rightarrow 0}{\frac {\sin(\Delta x)}{\Delta x}}=\lim _{\Delta x\rightarrow 0}{\frac {\cos(\Delta x)}{1}}=1}$  by L'Hôpital's rule.

${\displaystyle {\frac {dy}{dx}}=\sin(x)}$ ${\displaystyle 0+\cos(x)}$ ${\displaystyle 1=\cos(x)}$

Proof of 2 limits

 Figure 1: ${\displaystyle \lim _{\theta \rightarrow 0}{\frac {\sin(\theta )}{\theta }}:}$  Area of sector ${\displaystyle AOB\ \geq }$  area of triangle ${\displaystyle COB.}$  Area of triangle ${\displaystyle COB\ \geq }$  area of sector ${\displaystyle COD.}$ ${\displaystyle \lim _{\theta \rightarrow 0}{\frac {\sin(\theta )}{\theta }}:}$  In the diagram ${\displaystyle OA=OB=1.}$  ${\displaystyle OC=OD=\cos(\theta ).}$  ${\displaystyle CB=\sin(\theta ).}$  Let ${\displaystyle S}$  be the area of a sector of a circle. Then ${\displaystyle {\frac {S}{\pi r^{2}}}={\frac {\theta }{2\pi }}}$  and ${\displaystyle S={\frac {\theta r^{2}}{2}}.}$  Area of sector ${\displaystyle COD={\frac {\theta \cos ^{2}(\theta )}{2}}.}$  Area of triangle ${\displaystyle OCB={\frac {\sin(\theta )\cos(\theta )}{2}}.}$  Area of sector ${\displaystyle AOB={\frac {\theta \cdot 1^{2}}{2}}={\frac {\theta }{2}}.}$  Therefore ${\displaystyle {\frac {\theta }{2}}\ \geq \ {\frac {\sin(\theta )\cos(\theta )}{2}}\ \geq \ {\frac {\theta \cos ^{2}(\theta )}{2}}.}$  ${\displaystyle \theta \ \geq \ \sin(\theta )\cos(\theta )\ \geq \ \theta \cos ^{2}(\theta ).}$  ${\displaystyle {\frac {\theta }{\theta \cos(\theta )}}\ \geq \ {\frac {\sin(\theta )\cos(\theta )}{\theta \cos(\theta )}}\ \geq \ {\frac {\theta \cos ^{2}(\theta )}{\theta \cos(\theta )}}}$  ${\displaystyle {\frac {1}{\cos(\theta )}}\ \geq \ {\frac {\sin(\theta )}{\theta }}\ \geq \ \cos(\theta )}$  ${\displaystyle \lim _{\theta \rightarrow 0}{\frac {1}{\cos(\theta )}}\ \geq \ \lim _{\theta \rightarrow 0}{\frac {\sin(\theta )}{\theta }}\ \geq \ \lim _{\theta \rightarrow 0}\cos(\theta )}$  ${\displaystyle 1\ \geq \ \lim _{\theta \rightarrow 0}{\frac {\sin(\theta )}{\theta }}\ \geq \ 1}$  Therefore ${\displaystyle \lim _{\theta \rightarrow 0}{\frac {\sin(\theta )}{\theta }}=1.}$
 ${\displaystyle \lim _{\theta \rightarrow 0}{\frac {\cos(\theta )-1}{\theta }}:}$  ${\displaystyle {\frac {\cos(\theta )-1}{\theta }}}$  ${\displaystyle =(-1)\cdot {\frac {1-\cos(\theta )}{\theta }}}$  ${\displaystyle =(-1)\cdot {\frac {1-\cos(\theta )}{\theta }}\cdot {\frac {1+\cos(\theta )}{1+\cos(\theta )}}}$  ${\displaystyle =(-1)\cdot {\frac {\sin(\theta )}{\theta }}\cdot {\frac {\sin(\theta )}{1+\cos(\theta )}}}$  ${\displaystyle \lim _{\theta \rightarrow 0}{\frac {\cos(\theta )-1}{\theta }}}$  ${\displaystyle =\lim _{\theta \rightarrow 0}(-1)\cdot {\frac {\sin(\theta )}{\theta }}\cdot {\frac {\sin(\theta )}{1+\cos(\theta )}}}$  ${\displaystyle =(-1)\cdot \lim _{\theta \rightarrow 0}{\frac {\sin(\theta )}{\theta }}\cdot \lim _{\theta \rightarrow 0}{\frac {\sin(\theta )}{1+\cos(\theta )}}}$  ${\displaystyle =(-1)\cdot 1\cdot {\frac {0}{1+1}}=0.}$

cosine(x)

${\displaystyle y=\cos(x)={\sqrt {1-\sin ^{2}(x)}}}$

${\displaystyle y^{2}=1-\sin(x)}$ ${\displaystyle \sin(x)}$

Differentiate both sides:

${\displaystyle 2y}$ ${\displaystyle {\frac {dy}{dx}}=-(2\sin(x)\cos(x))}$

${\displaystyle {\frac {dy}{dx}}=-{\frac {\sin(x)\cos(x)}{\cos(x)}}=-\sin(x).}$

tan(x)

${\displaystyle y=\tan(x)={\frac {\sin(x)}{\cos(x)}}}$

${\displaystyle y\cos(x)=\sin(x)}$

Differentiate both sides:

${\displaystyle y(-\sin(x))+\cos(x)}$ ${\displaystyle {\frac {dy}{dx}}=\cos(x)}$

${\displaystyle \cos(x)}$ ${\displaystyle {\frac {dy}{dx}}=\cos(x)+y\sin(x)}$

${\displaystyle {\frac {dy}{dx}}={\frac {\cos(x)+\tan(x)\sin(x)}{\cos(x)}}=1+\tan ^{2}(x)=\sec ^{2}(x)}$

Derivatives of inverse trigonometric functions

arcsine(x)

 Figure 2: Graph of ${\displaystyle y=\arcsin(x)}$  and associated curves. ${\displaystyle y=\arcsin(x);\|x\|<=1}$  ${\displaystyle x=\sin(y)}$  ${\displaystyle {\frac {dx}{dy}}=\cos(y)}$  ${\displaystyle {\frac {dy}{dx}}={\frac {1}{\cos(y)}}={\frac {1}{\sqrt {1-\sin ^{2}(y)}}}={\frac {1}{\sqrt {1-x^{2}}}}}$  In the figure to the right you can see that the curves ${\displaystyle y=\arcsin(x),\ x=\sin(y)}$  are the same curve. However curve ${\displaystyle y=\arcsin(x)}$  is limited to ${\displaystyle {\frac {\pi }{2}}>=y>={\frac {-\pi }{2}}.}$  The derivative ${\displaystyle {\frac {dy}{dx}}={\frac {1}{\sqrt {1-x^{2}}}}}$  shows that the slope of ${\displaystyle y=\arcsin(x)}$  is ${\displaystyle 1}$  when ${\displaystyle x=0}$  and infinite when ${\displaystyle x=\pm 1.}$

arccosine(x)

 Figure 3: Graph of ${\displaystyle y=\arccos(x)}$  and associated curves. ${\displaystyle y=\arccos(x);\|x\|<=1}$  ${\displaystyle x=\cos(y)}$  ${\displaystyle {\frac {dx}{dy}}=-\sin(y)}$  ${\displaystyle {\frac {dy}{dx}}={\frac {-1}{\sin(y)}}={\frac {-1}{\sqrt {1-\cos ^{2}(y)}}}={\frac {-1}{\sqrt {1-x^{2}}}}}$  In the figure to the right you can see that the curves ${\displaystyle y=\arccos(x),\ x=\cos(y)}$  are the same curve. However curve ${\displaystyle y=\arccos(x)}$  is limited to ${\displaystyle \pi >=y>=0.}$  The derivative ${\displaystyle {\frac {dy}{dx}}={\frac {-1}{\sqrt {1-x^{2}}}}}$  shows that the slope of ${\displaystyle y=\arccos(x)}$  is ${\displaystyle -1}$  when ${\displaystyle x=0}$  and infinite when ${\displaystyle x=\pm 1.}$

arctan(x)

 Figure 4: Graph of ${\displaystyle y=\arctan(x)}$  and associated curves. ${\displaystyle y=\arctan(x)}$  ${\displaystyle x=\tan(y)}$  ${\displaystyle {\frac {dx}{dy}}=\sec ^{2}(y)}$  ${\displaystyle {\frac {dy}{dx}}={\frac {1}{\sec ^{2}(y)}}=\cos ^{2}(y)={\frac {1}{1+x^{2}}}}$  In the figure to the right you can see that the curves ${\displaystyle y=\arctan(x),\ x=\tan(y)}$  are the same curve. However curve ${\displaystyle y=\arctan(x)}$  is limited to ${\displaystyle {\frac {\pi }{2}}>y>{\frac {-\pi }{2}}.}$  The derivative ${\displaystyle {\frac {dy}{dx}}={\frac {1}{\sqrt {1+x^{2}}}}}$  shows that the slope of ${\displaystyle y=\arctan(x)}$  is ${\displaystyle 1}$  when ${\displaystyle x=0}$  and ${\displaystyle 0}$  when ${\displaystyle x=\pm \infty }$

Derivatives of logarithmic functions

a^x or ${\displaystyle a^{x}}$

${\displaystyle y=a^{x}}$

${\displaystyle y+\Delta y=a^{x+\Delta x}=a^{x}a^{\Delta x}}$

${\displaystyle \Delta y=a^{x}a^{\Delta x}-a^{x}=a^{x}(a^{\Delta x}-1)}$

${\displaystyle {\frac {\Delta y}{\Delta x}}=a^{x}\cdot {\frac {a^{\Delta x}-1}{\Delta x}}}$

Consider the value ${\displaystyle {\frac {a^{\Delta x}-1}{\Delta x}}}$  specifically ${\displaystyle \lim _{\Delta x\rightarrow 0}{\frac {a^{\Delta x}-1}{\Delta x}}}$ . L'Hôpital's rule cannot be used here because ${\displaystyle {\frac {d(a^{x})}{dx}}}$  is what we are trying to find.

${\displaystyle a^{\frac {1}{2}}={\sqrt {a}}}$

${\displaystyle (a^{\frac {1}{2}})^{\frac {1}{2}}={\sqrt {\sqrt {a}}}}$

${\displaystyle a^{\frac {1}{2^{3}}}={\sqrt {\sqrt {\sqrt {a}}}}}$

${\displaystyle a^{\frac {1}{2^{n}}}={\sqrt {a}}}$  taken ${\displaystyle n}$  times.

We will look at the expression ${\displaystyle {\frac {a^{\Delta x}-1}{\Delta x}}}$  for different values of ${\displaystyle a}$  with ${\displaystyle \Delta x={\frac {1}{2^{70}}}=8.5e-22}$  (approx) in which case the expression becomes ${\displaystyle (a^{1/2^{70}}-1)*(2^{70})}$  where ${\displaystyle a^{1/2^{70}}}$  is ${\displaystyle {\sqrt[{70}]{a}}}$  or ${\displaystyle {\sqrt {a}}}$  taken ${\displaystyle 70}$  times. This approach is used here because function sqrt() can be written so that it does not depend on logarithmic or exponential operations.

>>> # python code
>>> N=Decimal(2)
>>> v2 = ( [ n for n in (N,) for p in range (0,70) for n in (n.sqrt(),) ][-1] -1 )*(2**70) ; v2
Decimal('0.69314718055994530941743560122437474084363865015406919942144')
>>>
>>> N=Decimal(8)
>>> v8 = ( [ n for n in (N,) for p in range (0,70) for n in (n.sqrt(),) ][-1] -1 )*(2**70) ; v8
Decimal('2.07944154167983592825352768227031325913255072732801782513664')
>>>
>>> N=Decimal(32)
>>> v32 = ( [ n for n in (N,) for p in range (0,70) for n in (n.sqrt(),) ][-1] -1 )*(2**70) ; v32
Decimal('3.46573590279972654709124760144583715956091114572543812435968')
>>>
>>> N=Decimal(128)
>>> v128 = ( [ n for n in (N,) for p in range (0,70) for n in (n.sqrt(),) ][-1] -1 )*(2**70) ; v128
Decimal('4.85203026391961716593059535875094644210510807293198187102208')
>>>


Compare the values v8, v32, v128 with v2:

>>> v8/v2; v32/v2; v128/v2
Decimal('3.00000000000000000000176135549769209744528640235368520610520')
Decimal('5.00000000000000000000587118499230699148996545343403093128046')
Decimal('7.00000000000000000001232948848384468209997247971055570994695')
>>>


We know that ${\displaystyle 8=2^{3};\ 32=2^{5};\ 128=2^{7}}$ . The values v2, v8, v32, v128 are behaving like logarithms. In fact ${\displaystyle \lim _{\Delta x\rightarrow 0}{\frac {a^{\Delta x}-1}{\Delta x}}}$  is the natural logarithm of ${\displaystyle a}$  written as ${\displaystyle \ln(a).}$

 Figure 5: Graphs of ${\displaystyle {\frac {a^{x}-1}{x}}}$  for a = ${\displaystyle 2,\ 8,\ 32,\ 128}$  . Figure 5 contains graphs of ${\displaystyle {\frac {a^{x}-1}{x}}}$  for ${\displaystyle a=2,\ 8,\ 32,\ 128}$  with graph of ${\displaystyle {\frac {e^{x}-1}{x}}}$  included for reference. All values of ${\displaystyle x}$  are valid for all curves except where ${\displaystyle x=0.}$

The correct value of ${\displaystyle \ln(2)}$  is:

>>> Decimal(2).ln()
Decimal('0.693147180559945309417232121458176568075500134360255254120680')
>>>


Our calculation produced:

Decimal('0.69314718055994530941743560122437474084363865015406919942144')


accurate to 21 places of decimals, not bad for one line of simple python code using high-school math.

 This method for calculation of ${\displaystyle \ln(a)}$  supposes that function sqrt() is available. Programming language python interprets expression a**b as ${\displaystyle a^{b}.}$  Therefore, in python, ${\displaystyle \ln(2)}$  can be calculated in accordance with the basic definition above: # python code >>> getcontext().prec 101 # Precision of 101. >>> dx = Decimal('1E-50') >>> (2**dx - 1)/dx Decimal('0.69314718055994530941723212145817656807550013436026') # ln(2) >>> (2**(-dx) - 1)/(-dx) Decimal('0.693147180559945309417232121458176568075500134360253') # ln(2) >>> 

When ${\displaystyle y=a^{x},{\frac {dy}{dx}}=a^{x}\cdot \ln(a).}$

The base of natural logarithms is the value of ${\displaystyle a}$  that gives ${\displaystyle \lim _{\Delta x\rightarrow 0}{\frac {a^{\Delta x}-1}{\Delta x}}=1.}$

This value of ${\displaystyle a}$ , usually called ${\displaystyle e,=2.718281828459045235360287471352662497757247093699959574.....}$

>>> # python code
>>> N=e=Decimal(1).exp();N
Decimal('2.71828182845904523536028747135266249775724709369995957496697')
>>> ( [ n for n in (N,) for p in range (0,70) for n in (n.sqrt(),) ][-1] -1 )*(2**70)
Decimal('1.0000_0000_0000_0000_0000_0423_51647362715016770651530003719651328')
>>> # ln(e) = 1. Our calculation of ln(e) is accurate to 21 places of decimals.


When ${\displaystyle a=e,{\frac {d(e^{x})}{dx}}=e^{x}}$ ${\displaystyle \ln(e)=e^{x}}$ ${\displaystyle 1=e^{x}.}$

ln(x)

${\displaystyle y=ln(x)}$

${\displaystyle x=e^{y}}$

${\displaystyle {\frac {dx}{dy}}=e^{y}}$

${\displaystyle {\frac {dy}{dx}}={\frac {1}{e^{y}}}={\frac {1}{x}}}$

Examples

 ${\displaystyle y=\ln(ax)}$  ${\displaystyle {\frac {dy}{dx}}={\frac {d}{dx}}\ln(ax)={\frac {d}{dx}}(\ln(a)+\ln(x))={\frac {d}{dx}}\ln(a)+{\frac {d}{dx}}\ln(x)={\frac {1}{x}}}$
 ${\displaystyle y=\ln(x^{a})}$  ${\displaystyle {\frac {dy}{dx}}={\frac {d}{dx}}\ln(x^{a})={\frac {d}{dx}}(a\cdot \ln(x))=a\cdot {\frac {d}{dx}}\ln(x)={\frac {a}{x}}}$
 ${\displaystyle y=x^{\frac {m}{n}}}$  Calculate ${\displaystyle {\frac {dy}{dx}}}$  ${\displaystyle y^{n}=x^{m}}$  ${\displaystyle n\cdot \ln(y)=m\cdot \ln(x)}$  ${\displaystyle n\cdot {\frac {1}{y}}\cdot {\frac {dy}{dx}}=m\cdot {\frac {1}{x}}}$  ${\displaystyle {\frac {dy}{dx}}=m\cdot {\frac {1}{x}}\cdot {\frac {y}{n}}}$  ${\displaystyle ={\frac {m}{n}}\cdot {\frac {x^{\frac {m}{n}}}{x}}}$  ${\displaystyle ={\frac {m}{n}}\cdot x^{{\frac {m}{n}}-1}}$  Careful manipulation of logarithms converts exponents into simple constants.

Chain rule

Used where ${\displaystyle y=G(H(I(x)))}$

Examples

 ${\displaystyle y=\cos(2x)}$  Let ${\displaystyle y=\cos(u)}$  where ${\displaystyle u=2x}$ . {\displaystyle {\begin{aligned}{\frac {dy}{dx}}=&{\frac {dy}{du}}\cdot {\frac {du}{dx}}\\=&-\sin(u)\cdot 2\\=&-2\sin(2x)\\\end{aligned}}}
 ${\displaystyle y=\sin ^{2}(\ln(5x))}$  Let ${\displaystyle y=u^{2}}$  where ${\displaystyle u=\sin(v);\ v=\ln(w);\ w=5x}$ . {\displaystyle {\begin{aligned}{\frac {dy}{dx}}=&{\frac {dy}{du}}\cdot {\frac {du}{dv}}\cdot {\frac {dv}{dw}}\cdot {\frac {dw}{dx}}\\=&2u\cdot \cos(v)\cdot {\frac {1}{w}}\cdot 5\\=&2\sin(v)\cdot \cos(\ln(w))\cdot {\frac {1}{5x}}\cdot 5\\=&2\sin(\ln(w))\cdot \cos(\ln(5x))\cdot {\frac {1}{x}}\\=&2\sin(\ln(5x))\cdot \cos(\ln(5x))\cdot {\frac {1}{x}}\\\end{aligned}}}

Applications of the Derivative

Shape of curves

The first derivative of ${\displaystyle f(x)=y'}$  or ${\displaystyle f'(x).}$  As shown above, ${\displaystyle f'(x)}$  at any point ${\displaystyle x_{1}}$  gives the slope of ${\displaystyle f(x)}$  at point ${\displaystyle x_{1}.}$

${\displaystyle f'(x_{1})}$  is the slope of ${\displaystyle f(x)}$  when ${\displaystyle x=x_{1}.}$

 Figure 1: Diagram illustrating relationship between ${\displaystyle f(x)=x^{2}-x-2}$ and ${\displaystyle f'(x)=2x-1.}$ When ${\displaystyle x=0.5,}$  both ${\displaystyle f'(x)}$  and slope of ${\displaystyle f(x)=0.}$ When ${\displaystyle x=0,}$  both ${\displaystyle f'(x)}$  and slope of ${\displaystyle f(x)=-1.}$ When ${\displaystyle x=1,}$  both ${\displaystyle f'(x)}$  and slope of ${\displaystyle f(x)=1.}$ Point ${\displaystyle (0.5,-2.25)}$  is absolute minimum.In the example to the right, ${\displaystyle y=f(x)=x^{2}-x-2}$  and ${\displaystyle y'=f'(x)=2x-1.}$  Of special interest is the point at which ${\displaystyle f'(x)}$  or slope of ${\displaystyle f(x)=0.}$  When ${\displaystyle f'(x)=0,\ x=0.5}$  and ${\displaystyle f(x)=0.5^{2}-0.5-2=-2.25.}$  The point ${\displaystyle (0.5,-2.25)}$  is called a critical point or stationary point of ${\displaystyle f(x).}$  Because ${\displaystyle y'}$  has exactly one solution for ${\displaystyle y'=0,\ f(x)}$  has exactly one critical point. The value of ${\displaystyle y}$  at point ${\displaystyle (0.5,-2.25)}$  is less than ${\displaystyle y}$  at both ${\displaystyle (0,-2),\ (1,-2).}$  Therefore the critical point ${\displaystyle (0.5,-2.25)}$  is a minimum of ${\displaystyle f(x).}$  In this curve ${\displaystyle y=x^{2}-x-2,}$  the point ${\displaystyle (0.5,-2.25)}$  is both local minimum and absolute minimum.
 Figure 1: Diagram illustrating relationship between ${\displaystyle f(x)={\frac {2x^{3}+3x^{2}-12x-8}{8}}}$  and ${\displaystyle f'(x)={\frac {6x^{2}+6x-12}{8}}.}$  When ${\displaystyle x=-2}$  or ${\displaystyle x=1,}$  both ${\displaystyle f'(x)}$  and slope of ${\displaystyle f(x)=0.}$  When ${\displaystyle x=-3,}$  both ${\displaystyle f'(x)}$  and slope of ${\displaystyle f(x)=3.}$  When ${\displaystyle x=-1,}$  both ${\displaystyle f'(x)}$  and slope of ${\displaystyle f(x)=-1.5.}$  When ${\displaystyle x=2,}$  both ${\displaystyle f'(x)}$  and slope of ${\displaystyle f(x)=3.}$  Point ${\displaystyle (-2,1.5)}$  is local maximum. Point ${\displaystyle (1,-1{\frac {7}{8}})}$  is local minimum.In the example to the right, ${\displaystyle y=f(x)={\frac {2x^{3}+3x^{2}-12x-8}{8}}}$  and ${\displaystyle y'=f'(x)={\frac {6x^{2}+6x-12}{8}}.}$  Of special interest are the points at which ${\displaystyle f'(x)}$  or slope of ${\displaystyle f(x)=0.}$  When ${\displaystyle f'(x)=0,\ x=-2}$  and ${\displaystyle f(x)=1.5}$  or When ${\displaystyle f'(x)=0,\ x=1}$  and ${\displaystyle f(x)=-1{\frac {7}{8}}.}$  The points ${\displaystyle (-2,1.5),\ (1,-1{\frac {7}{8}})}$  are critical or stationary points of ${\displaystyle f(x).}$  Because ${\displaystyle y'}$  has exactly two real solutions for ${\displaystyle y'=0,\ f(x)}$  has exactly two critical points. Slope of ${\displaystyle f(x)}$  to the left of ${\displaystyle (-2,1.5)}$  is positive and adjacent slope of ${\displaystyle f(x)}$  to the right of ${\displaystyle (-2,1.5)}$  is negative. Therefore point ${\displaystyle (-2,1.5)}$  is local maximum. Point ${\displaystyle (-2,1.5)}$  is not absolute maximum. Adjacent slope of ${\displaystyle f(x)}$  to the left of ${\displaystyle (1,-1{\frac {7}{8}})}$  is negative and slope of ${\displaystyle f(x)}$  to the right of ${\displaystyle (1,-1{\frac {7}{8}})}$  is positive. Therefore point ${\displaystyle (1,-1{\frac {7}{8}})}$  is local minimum. Point ${\displaystyle (1,-1{\frac {7}{8}})}$  is not absolute minimum.

Maxima and Minima

Electric water heater

 Figure 1(a): Graph of ${\displaystyle V=f(r)}$  and ${\displaystyle {\frac {dV}{dr}}}$  for ${\displaystyle S=100}$  with ${\displaystyle y}$  axis compressed. For maximum ${\displaystyle V,\ r={\sqrt {\frac {S}{3\pi }}}=3.257\dots }$  and ${\displaystyle V=108.578\dots }$ A cylindrical water heater is standing on its base on a hard rubber pad that is a perfect thermal insulator. The vertical curved surface and the top are exposed to the free air. The design of the cylinder requires that the volume of the cylinder should be maximum for a given surface area exposed to the free air. What is the shape of the cylinder? Let the height of the cylinder be ${\displaystyle h}$  and let ${\displaystyle h=Kr}$  where ${\displaystyle r}$  is the radius and ${\displaystyle K}$  is a constant. Surface of cylinder ${\displaystyle =S=\pi r^{2}+2\pi rh=\pi r^{2}+2\pi r(Kr)=\pi r^{2}+2\pi r^{2}K}$  Volume of cylinder ${\displaystyle =V=\pi r^{2}h=\pi r^{2}(Kr)=\pi r^{3}K}$  ${\displaystyle K={\frac {S-\pi r^{2}}{2\pi r^{2}}}}$  ${\displaystyle V=\pi r^{3}\cdot {\frac {S-\pi r^{2}}{2\pi r^{2}}}={\frac {r(S-\pi r^{2})}{2}}={\frac {rS-\pi r^{3}}{2}}}$  ${\displaystyle {\frac {dV}{dr}}={\frac {S-3\pi r^{2}}{2}}}$  For maximum volume, ${\displaystyle {\frac {dV}{dr}}=0}$  Therefore ${\displaystyle S-3\pi r^{2}=0}$  ${\displaystyle S=3\pi r^{2};\ \pi r^{2}(1+2K)=3\pi r^{2};\ 1+2K=3;\ K=1.}$  The height of the cylinder equals the radius.

Square and triangle

 Figure 1(b): Graph of parabola ${\displaystyle A=f(s)}$  with ${\displaystyle y}$  axis compressed. A square of side ${\displaystyle h}$  has perimeter ${\displaystyle P_{s}=4h}$  and area ${\displaystyle A_{s}=h^{2}.}$  An equilateral triangle of side ${\displaystyle s}$  has perimeter ${\displaystyle P_{t}=3s}$  and area ${\displaystyle A_{t}={\frac {\sqrt {3}}{4}}s^{2}.}$  ${\displaystyle P_{s}+P_{t}=50.}$  Total area ${\displaystyle A=A_{s}+A_{t}}$  and ${\displaystyle A}$  must be minimum. What is the value of ${\displaystyle s}$ ? ${\displaystyle 4h+3s=50}$  ${\displaystyle h={\frac {50-3s}{4}}}$  ${\displaystyle A_{s}=h^{2}=({\frac {50-3s}{4}})^{2}}$  ${\displaystyle ={\frac {2500-300s+9s^{2}}{16}}}$  ${\displaystyle A=A_{s}+A_{t}}$  ${\displaystyle ={\frac {2500-300s+9s^{2}}{16}}+{\frac {\sqrt {3}}{4}}s^{2}}$  ${\displaystyle ={\frac {1}{16}}(2500-300s+9s^{2}+4{\sqrt {3}}s^{2})}$  For minimum ${\displaystyle A,\ {\frac {dA}{ds}}=0.}$  ${\displaystyle -300+2(9+4{\sqrt {3}})s=0}$  ${\displaystyle (9+4{\sqrt {3}})s=150}$  ${\displaystyle s={\frac {150}{9+4{\sqrt {3}}}}}$  ${\displaystyle =9.417\dots }$

 Figure 1(c): Plan of county road between Town A and Town B to be constructed so that cost is minimum. Town B is 40 miles East and 50 miles North of Town A. The county is going to construct a road from Town A to Town B. Adjacent to Town A the cost to build a road is $500k/mile. Adjacent to Town B the cost to build a road is$200k/mile. The dividing line runs East-West 30 miles North of Town A. Calculate the position of point C so that the cost of the road from Town A to Town B is minimum. Let point ${\displaystyle C=(x,30).}$  Then distance from Town A to point ${\displaystyle C={\sqrt {x^{2}+30^{2}}}={\sqrt {x^{2}+900}}.}$  Distance from Town B to point ${\displaystyle C={\sqrt {(40-x)^{2}+20^{2}}}}$  ${\displaystyle ={\sqrt {1600-80x+x^{2}+400}}}$  ${\displaystyle ={\sqrt {2000-80x+x^{2}}}.}$
 Figure 1(d): Graphs showing cost of county road ${\displaystyle (f(x))}$  and ${\displaystyle f'(x).}$  Curve showing ${\displaystyle (f(x))}$  is actually ${\displaystyle {\frac {f(x)}{10}}}$ . Cost is minimum where ${\displaystyle x=10.523\dots }$ Cost ${\displaystyle =5{\sqrt {x^{2}+900}}+2{\sqrt {2000-80x+x^{2}}}}$  in units of \$100k. For minimum cost ${\displaystyle f'(x)=0.}$  ${\displaystyle 5\cdot {\frac {1}{2}}\cdot {\frac {2x}{\sqrt {x^{2}+900}}}+2\cdot {\frac {1}{2}}\cdot {\frac {-80+2x}{\sqrt {2000-80x+x^{2}}}}=0}$  ${\displaystyle {\frac {5x}{\sqrt {x^{2}+900}}}+{\frac {-80+2x}{\sqrt {2000-80x+x^{2}}}}=0}$  ${\displaystyle 5x{\sqrt {2000-80x+x^{2}}}+(-80+2x){\sqrt {x^{2}+900}}=0}$

${\displaystyle x=10.52322823517\dots }$

Cardboard box

 Figure 1(e): Sheet of cardboard to be cut and folded to make box of maximum possible volume. Cut on purple lines, fold on red lines. Design of box includes top.A piece of cardboard of length ${\displaystyle 4\ ft}$  and width ${\displaystyle 3\ ft}$  will be used to make a box with a top. Some waste will be cut out of the piece of cardboard and the remaining cardboard will be folded to make a box so that the volume of the box is maximum. What is the height of the box?
 Figure 1(f): Curves associated with design of cardboard box. ${\displaystyle {\frac {dV}{dh}}=0}$  and ${\displaystyle V}$  is maximum when ${\displaystyle h={\frac {7-{\sqrt {13}}}{6}}}$ ${\displaystyle 2h+l=3}$  ${\displaystyle 2w+2h=4;\ w+h=2}$  ${\displaystyle V=lwh=(3-2h)(2-h)h=2h^{3}-7h^{2}+6h}$  For maximum volume ${\displaystyle {\frac {dV}{dh}}=6h^{2}-14h+6=0.}$  ${\displaystyle 3h^{2}-7h+3=0}$  ${\displaystyle h={\frac {7-{\sqrt {13}}}{6}}=6.788\dots }$  inches.

Solving ellipse at origin

An ellipse with center at origin has equation: ${\displaystyle Ax^{2}+Bxy+Cy^{2}+F=0\ \dots \ (1)}$

Given values ${\displaystyle A,B,C,F}$  calculate:

• length of major axis
• length of minor axis.

In Figure 1 ${\displaystyle t}$  is any line from origin to ellipse and ${\displaystyle \theta }$  is angle between ${\displaystyle X}$  axis and ${\displaystyle t.}$

Aim of this section is to calculate ${\displaystyle \theta }$  so that length of ${\displaystyle t}$  is maximum, in which case length of major axis = ${\displaystyle 2t.}$

 Let ${\displaystyle c=\cos(\theta )}$  and ${\displaystyle s=\sin(\theta ).}$  Then ${\displaystyle x=t\cos(\theta )=tc,}$  and ${\displaystyle y=t\sin(\theta )=ts.}$  Substitute these values in ${\displaystyle (1):}$  ${\displaystyle Attcc+Bttcs+Cttss+F=0\ \dots \ (2)}$  Calculate ${\displaystyle t'={\frac {dt}{d\theta }}}$  ${\displaystyle A(tt(-2cs)+cc2tt')+B(tt(cc-ss)+cs2tt')+C(tt(2sc)+ss2tt')=0}$  ${\displaystyle Att(-2cs)+Acc2tt'+Btt(cc-ss)+Bcs2tt'+Ctt(2sc)+Css2tt'=0}$  ${\displaystyle -2Attcs+Acc2tt'+Bttcc-Bttss+Bcs2tt'+2Cttsc+2Csstt'=0}$  ${\displaystyle +Acc2tt'+2Bcstt'+2Csstt'-2Attcs+Bttcc-Bttss+2Cttsc=0}$  ${\displaystyle +t'(Acc2t+2Bcst+2Csst)=+2Attcs-Bttcc+Bttss-2Cttsc}$  ${\displaystyle t'={\frac {+2Attcs-Bttcc+Bttss-2Cttsc}{(Acc2t+2Bcst+2Csst)}}}$  For maximum or minimum ${\displaystyle t:}$  ${\displaystyle 2Attcs-Bttcc+Bttss-2Cttsc=0}$  ${\displaystyle 2Acs-Bcc+Bss-2Csc=0}$  ${\displaystyle 2Acs-2Csc=Bcc-Bss}$  Square both sides, substitute ${\displaystyle 1-ss}$  for ${\displaystyle cc}$  and result is: ${\displaystyle aS^{2}+bS+c=0\ \dots \ (3)}$  where: ${\displaystyle S=\sin ^{2}(\theta )}$  ${\displaystyle a=(+4AA-8AC+4BB+4CC)}$  ${\displaystyle b=-a}$  ${\displaystyle c=BB}$
An example

Let equation of ellipse be: ${\displaystyle 55x^{2}-24xy+48y^{2}-2496=0}$

# python code
>>> A,B,C = 55,-24,48
>>> a = (+ 4*A*A - 8*A*C + 4*B*B + 4*C*C);a
2500
>>> b = -a;b
-2500
>>> c = B*B;c
576
>>>
>>> a,b,c = [v/4 for v in (a,b,c)] ; a,b,c
(625.0, -625.0, 144.0)
>>> S = .36
>>> a*S*S + b*S + c
0.0
>>> S = .64
>>> a*S*S + b*S + c
0.0
>>>


The solutions of quadratic equation ${\displaystyle (3)}$  are ${\displaystyle .36}$  or ${\displaystyle .64}$ .

Therefore ${\displaystyle \sin(\theta )=\pm 0.6}$  or ${\displaystyle \sin(\theta )=\pm 0.8}$ .

From ${\displaystyle (2)}$  above: ${\displaystyle t={\sqrt {\frac {-F}{Acc+Bcs+Css}}}}$

 # python code A,B,C,F = 55,-24,48, -2496 t1 = (0.6, 0.8) dict1 = dict() for v1 in (t1, t1[::-1]) : c1,s1 = v1 for c in (c1,-c1) : for s in (s1,-s1) : t = (-F/( A*c*c + B*c*s + C*s*s ))**.5 if t in dict1 : dict1[t] += ((c,s),) else : dict1[t] = ((c,s),) L1 = [ (v, dict1[v]) for v in sorted([ v for v in dict1 ]) ] for v in L1 : print (v) 
 (6.244997998398398, ((0.8, -0.6), (-0.8, 0.6))) (6.34287855135306, ((0.6, -0.8), (-0.6, 0.8))) (7.806247497997998, ((0.8, 0.6), (-0.8, -0.6))) (7.999999999999999, ((0.6, 0.8), (-0.6, -0.8)))

Minimum value of ${\displaystyle t=6.244997998398398.}$  Length of minor axis ${\displaystyle =2*6.244997998398398}$

Maximum value of ${\displaystyle t=7.999999999999999.}$  Length of major axis ${\displaystyle =8*2}$

Gallery
 When line ${\displaystyle t}$  has direction cosines ${\displaystyle [0.8,-0.6],}$ ${\displaystyle \tan(\theta )={\frac {-3}{4}}}$  and length of ${\displaystyle t}$  is minimum.   When line ${\displaystyle t}$  has direction cosines ${\displaystyle [0.6,0.8],}$ ${\displaystyle \tan(\theta )={\frac {4}{3}}}$  and length of ${\displaystyle t}$  is maximum.

Rates of Change

The car jack

 Figure 2: Photo of car jack illustrating horizontal ${\displaystyle (BC)}$  and vertical ${\displaystyle (CA)}$  rates of change.In triangle ${\displaystyle ABC}$  to the right: length ${\displaystyle AB=10}$  inches,length ${\displaystyle BC=x}$  inches and is horizontal,length ${\displaystyle CA=y}$  inches and is vertical,${\displaystyle \angle ABC=\theta .}$ Point ${\displaystyle B}$  is moving towards point ${\displaystyle C}$  at the rate of ${\displaystyle 5}$  inches${\displaystyle /}$ minute.
Vertical motion
 Figure 3: Curves and values associated with car jack. When ${\displaystyle x=1,\ {\frac {dy}{dx}}=0.1\dots }$  When ${\displaystyle \theta =45^{\circ },\ {\frac {dy}{dx}}=1}$  When ${\displaystyle x=9,\ {\frac {dy}{dx}}=2.06\dots }$ At what rate is point ${\displaystyle A}$  moving upwards: (a) when ${\displaystyle x=9}$ ? (b) when ${\displaystyle x=1}$ ? (c) when ${\displaystyle \theta =45^{\circ }}$ ? We have to calculate ${\displaystyle {\frac {dy}{dt}}}$  when ${\displaystyle {\frac {dx}{dt}}}$  is given. ${\displaystyle {\frac {dy}{dt}}={\frac {dy}{dx}}\cdot {\frac {dx}{dt}}}$  ${\displaystyle x^{2}+y^{2}=10^{2}}$  (equation of circle) ${\displaystyle y={\sqrt {100-x^{2}}}}$  ${\displaystyle y^{2}=100-x^{2}}$  ${\displaystyle 2y\cdot {\frac {dy}{dx}}=-2x}$  ${\displaystyle {\frac {dy}{dx}}={\frac {-2x}{2y}}={\frac {-x}{\sqrt {100-x^{2}}}}}$  For convenience we'll use the negative value of the square root and say that ${\displaystyle {\frac {dy}{dx}}={\frac {x}{\sqrt {100-x^{2}}}}.}$  Relative to line ${\displaystyle BC:}$  When ${\displaystyle x=9,\ {\frac {dy}{dx}}=2.06,\ {\frac {dy}{dt}}=2.06\cdot 5=10.3}$  inches${\displaystyle /}$ minute. When ${\displaystyle x=1,\ {\frac {dy}{dx}}=0.1,\ {\frac {dy}{dt}}=0.1\cdot 5=0.5}$  inches${\displaystyle /}$ minute. When ${\displaystyle \theta =45^{\circ },x=10\cdot \cos 45^{\circ }=7.071}$  and ${\displaystyle {\frac {dy}{dt}}=1\cdot 5=5}$  inches${\displaystyle /}$ minute. This example highlights the mechanical advantage of this simple but effective tool. When the top of the jack is low, it moves quickly. As the jack takes more and more weight, the top of the jack moves more slowly.
Change of area
 Figure 4: Graph of ${\displaystyle a}$  and ${\displaystyle {\frac {da}{dx}}}$ . Area of ${\displaystyle \Delta ABC}$  is maximum when ${\displaystyle b=h={\sqrt {50}}=10\cos(45^{\circ })}$ At what rate is the area of ${\displaystyle \Delta ABC}$  changing when (i) ${\displaystyle x=9}$ ? (ii) ${\displaystyle x=1}$ ? (iii) ${\displaystyle \theta =45^{\circ }}$ ? ${\displaystyle {\frac {da}{dt}}={\frac {da}{dx}}\cdot {\frac {dx}{dt}}}$  where ${\displaystyle a}$  is area of ${\displaystyle \Delta ABC}$  and ${\displaystyle {\frac {dx}{dt}}=5}$  inches ${\displaystyle /}$  minute.