Gradient function using matrix notation

Click For Summary

Discussion Overview

The discussion revolves around finding the gradient of a quadratic function expressed in matrix notation, specifically for the function f(x) = 1/2 xTQx + qTx. Participants are exploring the derivation of the gradient and clarifying the use of matrix calculus terminology.

Discussion Character

  • Exploratory
  • Technical explanation
  • Conceptual clarification
  • Debate/contested
  • Homework-related

Main Points Raised

  • One participant expresses confusion about deriving the gradient and arrives at df = (xTQ + qT)dx but is unsure how to proceed to grad f = Qx + q.
  • Another participant suggests using the sum notation for the quadratic form, indicating that xTQx can be expressed as a double summation.
  • A different participant calculates the gradient using the definition of the derivative and arrives at grad(f) = ½(Qx + xQ) + q, noting that if Q is symmetric, this simplifies to grad(f) = Qx + q.
  • One participant mentions their struggle with matrix notation and the terminology used in their calculus classes, indicating a need for clearer resources.
  • Some participants express confusion regarding the terminology and suggest looking for alternative references that might be more understandable.

Areas of Agreement / Disagreement

Participants do not seem to reach a consensus on the terminology and resources for understanding matrix calculus. There is a mix of confusion and differing preferences for learning materials.

Contextual Notes

Some participants mention their unfamiliarity with matrix notation and terminology, which may affect their understanding of the discussion. There is also a reference to a specific online resource that may not be universally accepted or understood.

hotvette
Homework Helper
Messages
1,001
Reaction score
11
I think I'm having a brain freeze. I'm trying to determine grad f where f(x) = 1/2 xTQx + qTx. I can get to the point where df = (xTQ + qT)dx, but I don't know how to get to the final result grad f = Qx + q.

Can someone explain it?
 
Last edited:
Physics news on Phys.org
hi hotvette! :smile:

Hint: use xTQx = ∑ij Qijxixj, qTx = ∑i qixi :wink:
 
What is df = (xTQ + qT)dx supposed to mean?

Using the definition of the derivative Df, I calculated that the matrix of Df (that is, grad(f)) is, is ½(Qx+xQ)+q. If Q is a symmetric matrix, then xQ=Qx and we find your result grad(f)=Qx+q.
 
tiny-tim and quasar987,

Thanks for your replies. The calculus classes I had (l-o-n-g time a go) never used matrix notation, so I'm trying to learn it on my own. I've been using this:

http://www.ee.ic.ac.uk/hp/staff/dmb/matrix/calculus.html#deriv_linear

as a guide and was following the terminology in the link. I'm treating dx as a vector quantity (e.g. dx = [dx1, dx2, ..., dxn]T). I'm just having a hard time deriving the expression for grad f based on the info in the link. Also, sorry, but I don't see where the sum notation leads.
 
tiny-tim said:
eugh! I've never come across that terminology before, and I find it really confusing

I don't follow it very well either. I'd be delighted to use an understandable alternative. Are there any online references you'd recommend?
 

Similar threads

  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 36 ·
2
Replies
36
Views
7K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 14 ·
Replies
14
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 2 ·
Replies
2
Views
3K