# Thread: Using formal definition to find derivative

1. ## Using formal definition to find derivative

Hi

I have to find the derivative of the following function: xsinx
Using formal definition. I have tried to start this but am stuck. Can someone give me a hint to help me complete it?

What I have done so far..

lim as h approaches 0

(x+h)(sinx+h) - (xsinx)/h <---- is this correct? or have I missed something?

2. ## Re: Using formal definition to find derivative

Strictly speaking, what you have is NOT correct but only because you are missing parentheses. The derivative is given by the limit of ((x+h)sinx+h- xsinx)/h. What you wrote would be (x+y)sinx+h- (xsinx/h). Even clearer would be ((x+h)sin(x+h)- xsin(x))/h. Now I would recommend that you use "-a+ a" to isolate the changes:
((x+h)sin(x+h)- xsin(x+h)+ xsin(x+h)- xsin(x))/h and separate into (((x+h)- x)/h)sin(x)+ x((sin(x+h)- sin(x))/h.
The first you should recognise as the derivative of x and the second as the derivative of sine.

3. ## Re: Using formal definition to find derivative

Thank you very much

4. ## Re: Using formal definition to find derivative

using the definition:

$\displaystyle f'(x) = \lim_{h \to 0} \frac{f(x+h) - f(x)}{h}$

for f(x) = xsin(x), we get:

$\displaystyle f'(x) = \lim_{h \to 0} \frac{(x+h)\sin(x+h) - x\sin(x)}{h}$

$\displaystyle = \lim_{h \to 0}\left[\frac{x\sin(x+h)- x\sin(x)}{h} + \frac{h\sin(x+h)}{h} \right]$

can you continue?

5. ## Re: Using formal definition to find derivative

Thank you Deveno!!!

Yes I can

6. ## Re: Using formal definition to find derivative

Hello, zzizi!

I just had to try this myself . . .

We need two theorems:

. . $\displaystyle \lim_{h\to0}\frac{\sin h}{h} \:=\:1 \qquad \lim_{h\to0}\frac{\cos h - 1}{h} \:=\:0$

Using the formal definition, differentiate: $\displaystyle f(x) \,=\,x\sin x$

$\displaystyle f(x+h) - f(x) \;=\;(x+h)\sin(x+h) - x\sin x$

. . . . . . . . . . . .$\displaystyle =\;x\sin(x+h) + h\sin(x+h) - x\sin x$

. . . . . . . . . . . .$\displaystyle =\;x\big[\sin(x+h) - \sin x\big] + h\sin(x+h)$

. . . . . . . . . . . .$\displaystyle =\;x(\sin x\cos h + \cos x\sin h - \sin x) + h(\sin x\cos h + \cos x\sin h)$

. . . . . . . . . . . .$\displaystyle =\;x\big[\sin x(\cos h -1) + \cos x\sin h\big] + h\left(\sin x\cos h + \cos x\sin h\right)$

$\displaystyle \frac{f(x+h)-f(x)}{h} \:=\:x\left[\sin x\!\cdot\!\frac{\cos h - 1}{h} + \cos x\!\cdot\!\frac{\sin h}{h}\right] +\sin x\cos h+\cos x\sin h$

$\displaystyle \lim_{h\to0}\frac{f(x+h)-f(x)}{h} \;=\;x\left[\sin x\left(\lim_{h\to0}\frac{\cos h-1}{h}\right) + \cos x\left(\lim_{h\to0}\frac{\sin h}{h}\right)\right]$

. . . . . . . . . . . . . . . . . . . $\displaystyle + \sin x\left(\lim_{h\to0}\cos h\right) + \cos x\left(\lim_{h\to0}\sin h\right)$

Therefore: .$\displaystyle f'(x) \;=\;x\big[\sin x\cdot 0 + \cos x \cdot 1\big] + \sin x\cdot 1 + \cos x\cdot 0$

. . . . . . . . .$\displaystyle f'(x) \;=\;x\cos x + \sin x$ . . ta-DAA!

Edit: Ah, too slow again!
. . . .Oh well, I simply refuse to delete all this typing.

7. ## Re: Using formal definition to find derivative

Originally Posted by Soroban
Hello, zzizi!

I just had to try this myself . . .

We need two theorems:

. . $\displaystyle \lim_{h\to0}\frac{\sin h}{h} \:=\:1 \qquad \lim_{h\to0}\frac{\cos h - 1}{h} \:=\:0$

$\displaystyle f(x+h) - f(x) \;=\;(x+h)\sin(x+h) - x\sin x$

. . . . . . . . . . . .$\displaystyle =\;x\sin(x+h) + h\sin(x+h) - x\sin x$

. . . . . . . . . . . .$\displaystyle =\;x\big[\sin(x+h) - \sin x\big] + h\sin(x+h)$

. . . . . . . . . . . .$\displaystyle =\;x(\sin x\cos h + \cos x\sin h - \sin x) + h(\sin x\cos h + \cos x\sin h)$

. . . . . . . . . . . .$\displaystyle =\;x\big[\sin x(\cos h -1) + \cos x\sin h\big] + h\left(\sin x\cos h + \cos x\sin h\right)$

$\displaystyle \frac{f(x+h)-f(x)}{h} \:=\:x\left[\sin x\!\cdot\!\frac{\cos h - 1}{h} + \cos x\!\cdot\!\frac{\sin h}{h}\right] +\sin x\cos h+\cos x\sin h$

$\displaystyle \lim_{h\to0}\frac{f(x+h)-f(x)}{h} \;=\;x\left[\sin x\left(\lim_{h\to0}\frac{\cos h-1}{h}\right) + \cos x\left(\lim_{h\to0}\frac{\sin h}{h}\right)\right]$

. . . . . . . . . . . . . . . . . . . $\displaystyle + \sin x\left(\lim_{h\to0}\cos h\right) + \cos x\left(\lim_{h\to0}\sin h\right)$

Therefore: .$\displaystyle f'(x) \;=\;x\big[\sin x\cdot 0 + \cos x \cdot 1\big] + \sin x\cdot 1 + \cos x\cdot 0$

. . . . . . . . .$\displaystyle f'(x) \;=\;x\cos x + \sin x$ . . ta-DAA!

Edit: Ah, too slow again!
. . . .Oh well, I simply refuse to delete all this typing.
That's wonderful Soroban! But why was it slow? what happened?

8. ## Re: Using formal definition to find derivative

Apparently it took soroban over two hours to type his response...

9. ## Re: Using formal definition to find derivative

Originally Posted by MarkFL2
Apparently it took soroban over two hours to type his response...
All those god damn brackets and parenthesis.

10. ## Re: Using formal definition to find derivative

He is the man when it comes to $\displaystyle \LaTeX$!!!

11. ## Re: Using formal definition to find derivative

Oh right! Thank you very much Soroban for the effort, it has helped me understand

12. ## Re: Using formal definition to find derivative

If I was to do this using first principles, I'd evaluate the derivatives of \displaystyle \displaystyle \begin{align*} x \end{align*} and \displaystyle \displaystyle \begin{align*} \sin{x} \end{align*} by first principles, then prove the product rule using first principles and apply it

\displaystyle \displaystyle \begin{align*} f_1(x) &= x \\ f_1 ' (x) &= \lim_{h \to 0}\frac{f_1(x + h) - f_1(x)}{h} \\ &= \lim_{h \to 0}\frac{x + h - x}{h} \\ &= \lim_{h \to 0}\frac{h}{h} \\ &= \lim_{h \to 0} 1 \\ &= 1 \\ \\ f_2(x) &= \sin{(x)} \\ f_2 '(x) &= \lim_{h \to 0}\frac{f_2(x + h) - f_2(x)}{h} \\ &= \lim_{h \to 0}\frac{\sin{(x+h)} - \sin{(x)}}{h} \\ &= \lim_{h \to 0}\frac{\sin{(x)}\cos{(h)} + \cos{(x)}\sin{(h)} - \sin{(x)}}{h} \\ &= \sin{(x)}\lim_{h \to 0}\frac{\cos{(h)} - 1}{h} + \cos{(x)}\lim_{h \to 0}\frac{\sin{(h)}}{h} \\ &= \sin{(x)} \cdot 0 + \cos{(x)} \cdot 1 \\ &= \cos{(x)} \end{align*}

Now as for the product rule...

\displaystyle \displaystyle \begin{align*} \left[ u(x) v(x) \right]' &= \lim_{h \to 0}\frac{u(x + h)v(x + h) - u(x)v(x)}{h} \\ &= \lim_{h \to 0}\frac{u(x+h)v(x+h) - u(x +h)v(x) + u(x +h)v(x) - u(x)v(x)}{h} \\ &= \lim_{h \to 0}u(x+h) \cdot \lim_{h \to 0}\frac{v(x+h) - v(x)}{h} + v(x)\cdot \lim_{h \to 0}\frac{u(x+h) - u(x)}{h} \\ &= u(x) v'(x) + u'(x) v(x) \end{align*}

So that means

\displaystyle \displaystyle \begin{align*} \left[ x\sin{(x)} \right]' &= x \left[ \sin{(x)} \right]' + (x)' \sin{(x)} \\ &= x\cos{(x)} + \sin{(x)} \end{align*}

13. ## Re: Using formal definition to find derivative

Originally Posted by Prove It
If I was to do this using first principles, I'd evaluate the derivatives of \displaystyle \displaystyle \begin{align*} x \end{align*} and \displaystyle \displaystyle \begin{align*} \sin{x} \end{align*} by first principles, then prove the product rule using first principles and apply it

\displaystyle \displaystyle \begin{align*} f_1(x) &= x \\ f_1 ' (x) &= \lim_{h \to 0}\frac{f_1(x + h) - f_1(x)}{h} \\ &= \lim_{h \to 0}\frac{x + h - x}{h} \\ &= \lim_{h \to 0}\frac{h}{h} \\ &= \lim_{h \to 0} 1 \\ &= 1 \\ \\ f_2(x) &= \sin{(x)} \\ f_2 '(x) &= \lim_{h \to 0}\frac{f_2(x + h) - f_2(x)}{h} \\ &= \lim_{h \to 0}\frac{\sin{(x+h)} - \sin{(x)}}{h} \\ &= \lim_{h \to 0}\frac{\sin{(x)}\cos{(h)} + \cos{(x)}\sin{(h)} - \sin{(x)}}{h} \\ &= \sin{(x)}\lim_{h \to 0}\frac{\cos{(h)} - 1}{h} + \cos{(x)}\lim_{h \to 0}\frac{\sin{(h)}}{h} \\ &= \sin{(x)} \cdot 0 + \cos{(x)} \cdot 1 \\ &= \cos{(x)} \end{align*}

Now as for the product rule...

\displaystyle \displaystyle \begin{align*} \left[ u(x) v(x) \right]' &= \lim_{h \to 0}\frac{u(x + h)v(x + h) - u(x)v(x)}{h} \\ &= \lim_{h \to 0}\frac{u(x+h)v(x+h) - u(x +h)v(x) + u(x +h)v(x) - u(x)v(x)}{h} \\ &= \lim_{h \to 0}u(x+h) \cdot \lim_{h \to 0}\frac{v(x+h) - v(x)}{h} + v(x)\cdot \lim_{h \to 0}\frac{u(x+h) - u(x)}{h} \\ &= u(x) v'(x) + u'(x) v(x) \end{align*}

So that means

\displaystyle \displaystyle \begin{align*} \left[ x\sin{(x)} \right]' &= x \left[ \sin{(x)} \right]' + (x)' \sin{(x)} \\ &= x\cos{(x)} + \sin{(x)} \end{align*}
Thank you very much for your input Prove it - much appreciated!

,

,

,

,

,

,

,

,

,

,

,

,

,

,

# the derivative of xsinx by first principle

Click on a term to search for related topics.