# Gradient and mean value theorem

1. Oct 23, 2005

Hi
please , can someone help me with this problem.
I need to know the procedure.

Let f(x,y)=x^3-xy. set a(0,1) and b(1,3).
Find a point c on the line sement[ab] for which

Thank you
B.

2. Oct 23, 2005

### HallsofIvy

The "procedure" is to calculate everything you can there, then solve the equation for c. Since a= (0,1), f(a)= f(0,1)= 0^3- 0(1)= 0. Since b= (1, 3), f(b)= f(1,3)= 1^3- 1(3)= -2. f(b)- f(a)= -2- 0= -2.
I'm not particularly happy with the notation on the right side! a and b are points but you have to treat "b-a" as a vector subtraction: b- a= i+3j- (j)= i+ 2j. grad f= (3x- y)i- xj. Now that product "*" is a dot product:
grad f*b-a= ((3x-y)i- xj).(i+ 2j)= 3x-y- 2x= x- y= -2.
That's one equation for two unknown values, x and y. To get the other, use that fact that c= (x,y) is on the line between a and b. One way to do that is to write the line between a and b ((0,1) and (1,3)) as y= 2x+ 1 (do you see how I got that?) and solve the two equations x- y= 2 and y= 2x+ 1 for x and y. Another is to write parametric equations for the line: since b-a= i+ 3j, x= t, y= 2t+ 1. Replace x- y= 2 with those, solve for t and use that value of t to find x and y.

3. Jan 4, 2010

### kmac

Where did you find the solutions for this? i'm writing a paper and struggling to find info for use!

4. Jan 4, 2010

### HallsofIvy

What do you mean "where did you find the solutions for this?" I solved it myself!

5. Jan 5, 2010

### kmac

I guess I'm confused as to how you learned this. I couldn't find a lot of stuff online about it. As I said I'm working on a project involving this and I can't find anywhere to learn this stuff.

6. Jan 5, 2010

### kmac

I just copied what you wrote and I'll write comments in red of where I'm confused.

The "procedure" is to calculate everything you can there, then solve the equation for c. Since a= (0,1), f(a)= f(0,1)= 0^3- 0(1)= 0. Since b= (1, 3), f(b)= f(1,3)= 1^3- 1(3)= -2. f(b)- f(a)= -2- 0= -2.

I'm not particularly happy with the notation on the right side! a and b are points but you have to treat "b-a" as a vector subtraction: b- a= i+3j- (j)= i+ 2j. grad f= (3xshould this be squared?- y)i- xj. Now that product "*" is a dot product:
grad f*b-a= ((3x-y)i- xj).(i+ 2j)= 3x-y- 2x= x- y= -2.

How do you know that x-y=-2??

That's one equation for two unknown values, x and y. To get the other, use that fact that c= (x,y) is on the line between a and b. One way to do that is to write the line between a and b ((0,1) and (1,3)) as y= 2x+ 1 (do you see how I got that?) and solve the two equations x- y= 2

Why is x-y=2 now?

and y= 2x+ 1 for x and y. Another is to write parametric equations for the line: since b-a= i+ 3j, x= t, y= 2t+ 1. Replace x- y= 2 with those, solve for t and use that value of t to find x and y.

7. Jan 5, 2010

### HallsofIvy

Yes, that was, I hope, a typo on my part.

I just made a really dumb mistake! The derivative of $x^3- xy$ with respect to x is $3x^2- y$, not "3x- y"! I hope thoat was just a typo on my part and I am not really losing my mind.
Now $grad f\cdot(b-a)= (3x^2- y)\vec{i}- x\vec{j})\cdot(\vec{i}+ 2\vec{j})$$= 3x^2- y- 2x$ and that must be equal to -2: 3x^2- y- 2x= -2.

That was the mistaken equation I got before. It should be $3x^2- y- 2x= -2$

So $3x^2- y- 2x= 2$ and y= 2x+1. Replace y in the first equation by 2x+1 and we have $3x^2- 2x-1- 2x= -2$ or $3x^2- 4x+ 1= 0$. By the quadratic formula, the roots of that are
[tex]\frac{4\pm\sqrt{16- 9}}{6}= \frac{4\pm\sqrt{7}}{6}[/itex].

Since 7 is just a little less than 9, $\sqrt{7}$ is just a little less than 3. If we were to take the positive, we would have $4+ \sqrt{7}$ a little bit more than 7 and $(4+ \sqrt{7})/6$ a little bit larger than 1. If we take the negative, we have $4- \sqrt{7}$ a little smaller than 1 and $(4-\sqrt{7})/6$ between 0 and 1. In order that (x,y) be between (0,1) and (1,3) x must be between 0 and 1 and so $x= (4- \sqrt{7})/6$. Then, of course, $y= 2x+ 1= (4- \sqrt{7}}/3+ 1= (7- \sqrt{7})/3$ which is a little larger than 1 and so between 1 and 3.