Proving the Gradient of f(x) in Matrix Notation

Click For Summary

Homework Help Overview

The discussion revolves around proving the gradient of the function f(x) defined as f(x)=(1/2)*(x^T)*(A)*(x)-(x^T)*(b), where A is a real n*n matrix and b is a column matrix. Participants are exploring the gradient in matrix notation and its derivation.

Discussion Character

  • Exploratory, Mathematical reasoning, Problem interpretation

Approaches and Questions Raised

  • Participants suggest rewriting the function in index notation and applying the product rule. There are inquiries about the implications of the derivative and how to handle the matrix terms. Some express uncertainty about the steps involved in the derivation.

Discussion Status

There is an ongoing exploration of different approaches to derive the gradient. Some participants have provided guidance on using index notation and the product rule, while others are questioning the assumptions and steps necessary to proceed. The conversation indicates a mix of understanding and confusion, with no explicit consensus reached.

Contextual Notes

Some participants mention constraints related to their familiarity with matrix calculus and LU factorization, indicating a potential gap in knowledge that may affect their ability to engage with the problem fully.

oxxiissiixxo
Messages
27
Reaction score
0

Homework Statement


f(x)=(1/2)*(x^T)*(A)*(x)-(x^T)*(b)

Show that the gradient of f(x) is (1/2)*[((A^T)+A)*x]-(b)

where x^transpose is transpose of x and A^transpose is transpose of A.

Note: A is real matrix n*n and b is a column matrix n


Homework Equations





The Attempt at a Solution


I need to kinda proof that.
 
Physics news on Phys.org
Write it in index notation. (1/2)*x_i*A_ij*x_j+x_i*b_i. All indices summed. Now dx_i/dx_k=delta(i,k). You kinda knew that, right? Use the product rule on the A part.
 
Dick said:
Write it in index notation. (1/2)*x_i*A_ij*x_j+x_i*b_i. All indices summed. Now dx_i/dx_k=delta(i,k). You kinda knew that, right? Use the product rule on the A part.

All indices summed. Now dx_i/dx_k=delta(i,k).

what do you mean by that?
 
Can you write it in index notation? By dx_i/dx_k=delta(i,k) I mean the derivative is 1 if i=k and 0 if i is not equal k.
 
I think that I may be able to make the function into index notation form.
If I make the equation to be (1/2)*x_i*A_ij*x_j+x_i*b_i, I then take the derivative respect with x_k? How this will work?
If k=i, after taking the derivative the equation will become (1/2)*1*A_ij*x_j+1*b_i. What I will have to do for the A_ij? I have not learned how to do the product rule of a matrix yet.
Will k=i and j so that I will have to do 2 derivative of i and j? if so how this works?
 
You don't have a matrix anymore once you indexed everything out. There are two x's on the first term one on the right and one on the left which is why you are getting A+A^T.
 
would you mind to show me the steps to get from f(x)=(1/2)*(x^T)*(A)*(x)-(x^T)*(b) to (1/2)*[((A^T)+A)*x]-(b).

I did a lot of research about this problem these days. I found a relation: D[f(x)^Tg(x)] = g(x)^Tf'(x) + f(x)^Tg'(x). however i am not convinced. I am sorry this is the first time i do this kinda proof. I can't handle it.
 
I can't do that until you at least make a try at the problem. I've told you what to do. The gradient of f(x) is the vector (df(x)/dx_1,df(x)/dx_2,...df(x)/dx_n). Write out the expression as a summation over indices and take d/dx_k of it.
 
hi dick thankz i think that i got it YEAH! XD

I have another question if i want to find all the matrices for X that satisfies this equation A*X*B^T = C. How should I deal with this problem? should i also make that into index notation?

B^T is the transpose of B.
 
  • #10
Are A or B invertible?
 
  • #11
It doesn't really say. This is the original question:
Find all matrices X that satisfy the equation A*X*B^T = C, in terms of the LU
factorizations of A and B. State the precise conditions under which there are no
solutions.
 
  • #12
I'm really not an expert on LU factorization stuff. I think you should post this in a new thread so other people can take a crack at it.
 
  • #13
Thanks Man anyway. You are my big help.
 

Similar threads

  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
Replies
2
Views
1K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 2 ·
Replies
2
Views
3K
Replies
3
Views
2K
  • · Replies 11 ·
Replies
11
Views
3K
Replies
5
Views
2K