MHB What is the Gradient of a Function at a Given Point?

  • Thread starter Thread starter JProgrammer
  • Start date Start date
  • Tags Tags
    Direction
Click For Summary
To find the direction of steepest ascent for the function f(x, y) = x^2 - 4y^2 - 9 at the point (1, -2), the gradient is essential. The user encountered issues with Wolfram Alpha misinterpreting the input, leading to confusion about the gradient's output. It is suggested that the user should manually calculate the gradient instead of relying solely on the tool. Understanding the gradient's calculation is crucial for accurately determining the direction of steepest ascent.
JProgrammer
Messages
20
Reaction score
0
I am trying to find the direction of steepest ascent of this function with this given point:

f(x) = x^2 - 4y^2 - 9

(1,-2)

I have the understanding that the steepest ascent or in some cases descent can be measured by the gradient. So in wolfram alpha I type in: gradient f(x) = x^2 - 4y^2 - 9, (1,-2) it says it interprets my input as: grad(-9+x^2-4 y^2, 18+x^2-4 y^2)
and gives me: grad(-9+x^2-4 y^2, 18+x^2-4 y^2) = ({2 x, 2 x}, {-8 y, -8 y}).

It interprets my input wrong and does not give me a direction. If someone could tell me what I am doing wrong and what I need to do instead, I would appreciate.

Thank you.
 
Physics news on Phys.org
Shouldn't that be f(x, y)?
 
JProgrammer said:
I am trying to find the direction of steepest ascent of this function with this given point:

f(x) = x^2 - 4y^2 - 9

(1,-2)

I have the understanding that the steepest ascent or in some cases descent can be measured by the gradient. So in wolfram alpha I type in: gradient f(x) = x^2 - 4y^2 - 9, (1,-2) it says it interprets my input as: grad(-9+x^2-4 y^2, 18+x^2-4 y^2)
and gives me: grad(-9+x^2-4 y^2, 18+x^2-4 y^2) = ({2 x, 2 x}, {-8 y, -8 y}).

It interprets my input wrong and does not give me a direction. If someone could tell me what I am doing wrong and what I need to do instead, I would appreciate.

Thank you.
Really? I got this. But it's so simple a problem, why are you using W|A to do it? Do you know how to take the gradient?

-Dan
 
There are probably loads of proofs of this online, but I do not want to cheat. Here is my attempt: Convexity says that $$f(\lambda a + (1-\lambda)b) \leq \lambda f(a) + (1-\lambda) f(b)$$ $$f(b + \lambda(a-b)) \leq f(b) + \lambda (f(a) - f(b))$$ We know from the intermediate value theorem that there exists a ##c \in (b,a)## such that $$\frac{f(a) - f(b)}{a-b} = f'(c).$$ Hence $$f(b + \lambda(a-b)) \leq f(b) + \lambda (a - b) f'(c))$$ $$\frac{f(b + \lambda(a-b)) - f(b)}{\lambda(a-b)}...

Similar threads

  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 17 ·
Replies
17
Views
3K
  • · Replies 16 ·
Replies
16
Views
3K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 8 ·
Replies
8
Views
742
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 3 ·
Replies
3
Views
1K