0

I want to differentiate the following equation

$$ x \mapsto \|x\|^2 + \lambda{\|Ax - b\|}^2 $$

where the real symmetric matrix $A$ is not invertible. I have decomposed $A$ using the spectral theorem, but stuck on how to then differentiate the function w.r.t to $x$. The function then looks like

$$ x \mapsto \|x\|^2 + \lambda {\left\| Q B Q^{-1} x - b \right\|}^2 $$

How do I differentiate this now?

julie
  • 1

1 Answers1

0

$ \def\l{\lambda} \def\LR#1{\left(#1\right)} \def\op#1{\operatorname{#1}} \def\trace#1{\op{Tr}\LR{#1}} \def\frob#1{\left\| #1 \right\|_F} \def\qiq{\quad\implies\quad} \def\p{\partial} \def\grad#1#2{\frac{\p #1}{\p #2}} \def\c#1{\color{red}{#1}} \def\CLR#1{\c{\LR{#1}}} \def\fracLR#1#2{\LR{\frac{#1}{#2}}} \def\gradLR#1#2{\LR{\grad{#1}{#2}}} $For typing convenience, introduce the variable $$\eqalign{ w &= \LR{Ax-b} \qiq dw = A\:dx \\ }$$ and the Frobenius product $(:)$ which has the following properties $$\eqalign{ A:B &= \sum_{i=1}^m\sum_{j=1}^n A_{ij}B_{ij} \;=\; \trace{A^TB} \\ A:A &= \frob{A}^2 \qquad \{ {\rm Frobenius\;norm} \}\\ A:B &= B:A \;=\; B^T:A^T \\ C:\LR{AB} &= \LR{CB^T}:A \;=\; \LR{A^TC}:B \\ }$$ Use the above notation to rewrite the objective function $(\phi)$ and calculate its gradient. $$\eqalign{ \phi &= x:x + \l w:w \\ d\phi &= 2x:dx + 2\l w:\c{dw} \\ &= 2x:dx + 2\l\LR{Ax}:\CLR{A\:dx} \\ &= 2\LR{x+\l A^TAx} : dx \\ \grad{\phi}{x} &= 2\LR{x+\l A^TAx} \\ }$$ Note that $A^{-1}$ is not needed, only $A^TA,$ which always exists.

greg
  • 35,825