# Find the derivative of the given function from first principle : $\cos \bigg( x - \large\frac{\pi}{8} \bigg)$

Let $f(x) = \cos \bigg( x - \large\frac{\pi}{8} \bigg)$. Accordingly, $f(x+h) = \cos \bigg( x + h - \large\frac{\pi}{8} \bigg)$
By first principle
$f'(x) = \lim\limits_{ h \to 0} \large\frac{f(x+h)-f(x)}{h}$
$= \lim\limits_{ h \to 0} \large\frac{1}{h}$$\bigg[ \cos \bigg(x+h - \large\frac{\pi}{8} \bigg)$$ - \cos \bigg( x - \large\frac{\pi}{8} \bigg) \bigg]$
$= \lim\limits_{ h \to 0} \large\frac{1}{h}$$\bigg[-2\sin \large\frac{\bigg(x+h-\Large\frac{\pi}{8}+x-\Large\frac{\pi}{8} \bigg)}{2}$$\sin \large\frac{\bigg(x+h-\Large\frac{\pi}{8}-x+\Large\frac{\pi}{8} \bigg)}{2} \bigg]$
$= \lim\limits_{ h \to 0} \large\frac{1}{h}$$\bigg[-2\sin\bigg( \large\frac{2x+h-\Large\frac{\pi}{4}}{2}\bigg)$$\sin \large\frac{h}{2} \bigg]$
$= \lim\limits_{ h \to 0} \bigg[-\sin \bigg(\large\frac{2x+h-\Large\frac{\pi}{4} }{2}\bigg)$$\large\frac{\sin \bigg(\large\frac{h}{2}\bigg)}{\bigg(\Large\frac{h}{2}\bigg) }\bigg] = \lim\limits_{ h \to 0} \bigg[-\sin\bigg( \large\frac{2x+h-\Large\frac{\pi}{4} }{2}\bigg)\bigg]$$\lim\limits_{ \large\frac{h}{2} \to 0}\large\frac{\sin \bigg(\large\frac{h}{2}\bigg)}{\bigg(\Large\frac{h}{2}\bigg) }\qquad \bigg[ As \: h \to 0 \Rightarrow \large\frac{h}{2} \to 0 \bigg]$
$= -\sin \bigg(\large\frac{2x+0-\Large\frac{\pi}{4} }{2}\bigg)$$.1$
$= -\sin \bigg( x - \large\frac{\pi}{8} \bigg)$