Check the differentiability of the given function.
$begingroup$
Let $M_n(mathbb{R})$ denote the space of all $ntimes n $ real
matrices identified with Euclidean space $mathbb{R^{n^2}}$. Fixed
a column vector $x neq 0$ in $mathbb{ R^n}$. Define $f :
M_n(mathbb{R}) rightarrow mathbb{R}$ by $f(A) = langle A^2x,x
rangle$. Check whether given function is differntiable or not?
When I took $
A=
left[ {begin{array}{cc}
x_1 & x_2 \
x_3 & x_4\
end{array} } right]
$ and $x=left[ {begin{array}{cc}
a \
b\
end{array} } right]$. I got $f(A)$ as a polynomial of four variables. I know that the polynomial function is always differentiable. How do I prove it for $ntimes n$ matrix case?Without expanding the inner product How do I prove the given function is differentiable?
multivariable-calculus derivatives operator-theory
$endgroup$
add a comment |
$begingroup$
Let $M_n(mathbb{R})$ denote the space of all $ntimes n $ real
matrices identified with Euclidean space $mathbb{R^{n^2}}$. Fixed
a column vector $x neq 0$ in $mathbb{ R^n}$. Define $f :
M_n(mathbb{R}) rightarrow mathbb{R}$ by $f(A) = langle A^2x,x
rangle$. Check whether given function is differntiable or not?
When I took $
A=
left[ {begin{array}{cc}
x_1 & x_2 \
x_3 & x_4\
end{array} } right]
$ and $x=left[ {begin{array}{cc}
a \
b\
end{array} } right]$. I got $f(A)$ as a polynomial of four variables. I know that the polynomial function is always differentiable. How do I prove it for $ntimes n$ matrix case?Without expanding the inner product How do I prove the given function is differentiable?
multivariable-calculus derivatives operator-theory
$endgroup$
$begingroup$
... differentiable where? In a specific point, interval or the whole domain?
$endgroup$
– manooooh
Dec 1 '18 at 8:30
1
$begingroup$
@manooooh must be the whole of $mathbb{R}^{n^2}$
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
some hints can be found here
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
add a comment |
$begingroup$
Let $M_n(mathbb{R})$ denote the space of all $ntimes n $ real
matrices identified with Euclidean space $mathbb{R^{n^2}}$. Fixed
a column vector $x neq 0$ in $mathbb{ R^n}$. Define $f :
M_n(mathbb{R}) rightarrow mathbb{R}$ by $f(A) = langle A^2x,x
rangle$. Check whether given function is differntiable or not?
When I took $
A=
left[ {begin{array}{cc}
x_1 & x_2 \
x_3 & x_4\
end{array} } right]
$ and $x=left[ {begin{array}{cc}
a \
b\
end{array} } right]$. I got $f(A)$ as a polynomial of four variables. I know that the polynomial function is always differentiable. How do I prove it for $ntimes n$ matrix case?Without expanding the inner product How do I prove the given function is differentiable?
multivariable-calculus derivatives operator-theory
$endgroup$
Let $M_n(mathbb{R})$ denote the space of all $ntimes n $ real
matrices identified with Euclidean space $mathbb{R^{n^2}}$. Fixed
a column vector $x neq 0$ in $mathbb{ R^n}$. Define $f :
M_n(mathbb{R}) rightarrow mathbb{R}$ by $f(A) = langle A^2x,x
rangle$. Check whether given function is differntiable or not?
When I took $
A=
left[ {begin{array}{cc}
x_1 & x_2 \
x_3 & x_4\
end{array} } right]
$ and $x=left[ {begin{array}{cc}
a \
b\
end{array} } right]$. I got $f(A)$ as a polynomial of four variables. I know that the polynomial function is always differentiable. How do I prove it for $ntimes n$ matrix case?Without expanding the inner product How do I prove the given function is differentiable?
multivariable-calculus derivatives operator-theory
multivariable-calculus derivatives operator-theory
asked Dec 1 '18 at 7:52
Unknown xUnknown x
2,53311026
2,53311026
$begingroup$
... differentiable where? In a specific point, interval or the whole domain?
$endgroup$
– manooooh
Dec 1 '18 at 8:30
1
$begingroup$
@manooooh must be the whole of $mathbb{R}^{n^2}$
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
some hints can be found here
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
add a comment |
$begingroup$
... differentiable where? In a specific point, interval or the whole domain?
$endgroup$
– manooooh
Dec 1 '18 at 8:30
1
$begingroup$
@manooooh must be the whole of $mathbb{R}^{n^2}$
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
some hints can be found here
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
... differentiable where? In a specific point, interval or the whole domain?
$endgroup$
– manooooh
Dec 1 '18 at 8:30
$begingroup$
... differentiable where? In a specific point, interval or the whole domain?
$endgroup$
– manooooh
Dec 1 '18 at 8:30
1
1
$begingroup$
@manooooh must be the whole of $mathbb{R}^{n^2}$
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
@manooooh must be the whole of $mathbb{R}^{n^2}$
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
some hints can be found here
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
some hints can be found here
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
add a comment |
2 Answers
2
active
oldest
votes
$begingroup$
The first step is to have differentiability definition in mind. From wikipedia
A function of several real variables $f: R^m → R^n$ is said to be
differentiable at a point $x_0$ if there exists a linear map $J: R^m → R^n$
such that
$$
lim_{hto 0}frac{|f(x_0+h)-f(x_0)-Jh|}{|h|}=0
$$
Now your application. Take any matrix $H$ and do the following computation:
begin{align*}
f(A+H)=&langle (A+H)^2x,x rangle \
=&langle (A^2+AH+HA+H^2)x,x rangle \
=&langle A^2x,x rangle+langle (AH+HA)x,x rangle+langle H^2x,x rangle
end{align*}
Now consider:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|f(A+H)-f(A)-langle (AH+HA)x,x rangle|}{|H|}
end{align*}
From the first computation this is also equal to:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}
end{align*}
However like
$$
frac{|langle H^2x,x rangle|}{|H|}lefrac{|H^2x||x|}{|H|}le|H||x|
$$
where we have used Cauchy-Schwarz and $|H^2x|le|H^2||x|$ (we assume that we have taken a matrix norm consistent with the vector norm)
it is clear that the limit $mathcal{l}$ is zero:
begin{align*}
0le mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}lelim_{Hto 0}|H||x|=0
end{align*}
This means that the linear application:
$$
Hmapsto df(A)cdot H =langle (AH+HA)x,x rangle
$$
is your differential at point $A$
Answer to comments. To find the differential, I have proceeded by direct identification after algebra manipulation of $f(A+H)$:
$$
f(A+H)=langle (A+H)^2x,x rangle=underbrace{langle A^2x,x rangle}_{f(A)}+underbrace{langle (AH+HA)x,x rangle}_{df(A)cdot H}+underbrace{langle H^2x,x rangle}_{text{reminder that vanishes when H}to 0}
$$
This direct approach was possible because your example involved only matrix/vector products, scalar products etc.
Sometimes expressions are more complex. You must first find a candidate for the differential (you can use partial derivatives, chain rule etc...) then, in case of doubt, you must prove that the limit (the first equation of my post, from wikipedia) exists.
An useful result is that existence of the previous limit is equivalent to the continuity of the partial derivatives in a neighborhood of $A$.
Example: $f:mathbb{R}^nni xto|x|_2=sqrt{sum_i x_i^2}$.
A candidate for the differential at point $ainmathbb{R}^n$ is:
$$
df(a)cdot h=sum_{i=1}^n frac{partial f}{partial x_i}(a)h_i=frac{1}{|a|_2}sum_{i=1}^n a_ih_i
$$
It is clear that the function $xto|x|_2$ is differentiable at any point $ainmathbb{R}^n-{0}$. However the point $a=0_{mathbb{R}^n}$ is suspicious. To prove differentiability we must prove that in a neighborhood of $0_{mathbb{R}^n}$ all partial derivatives are continuous.
$$
frac{partial f}{partial x_i}(a)=frac{a_i}{|a|_2}
$$
Unfortunately these functions are not continuous at $a=0_{mathbb{R}^n}$. To see that, we will find two different paths approaching $0_{mathbb{R}^n}$ but with two different values for the function (thus the function is not continuous).
Define a curve $gamma_i:tinmathbb{R}to gamma_i(t):=t mathbf{e}_i$, observe that $gamma_i(0)=0_{mathbb{R}^n}$
Now observe that:
$$
frac{partial f}{partial x_i}(gamma_i(t))=frac{t}{sqrt{t^2}}=left{begin{array}{rl}+1, t>0 \ -1, t<0end{array}right.
$$
clearly the partial derivative is not continuous, hence the function $xto|x|_2$ is not differentiable at $a=0$ (but it is differentiable at any other point of $mathbb{R}^n$).
Concerning good reference: I personally really like Henri Cartan book Differential Calculus On Normed Spaces a wonderful book to learn differential calculus. However everything in done in Banach spaces, not sure it is the right choice for a primer book on the subject. At a lower level I have no suggestion for the moment sorry.
One last thing I also answered this question which was quite similar to ours. Emphasis is done on the difference between the differential $df$ and the gradient $nabla f$.
$endgroup$
$begingroup$
fantastic answer! I hope you could also prove by induction on $n$ and the homogenous nature of quadratic forms. But, how did you come to know beforehand that $langle (AH+HA)x, xrangle$ is the derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:10
$begingroup$
thanks, happy if it helps. To find the expression of the derivative, simply look at the first computation: the idea is just to expand f(A+H) you get f(A)+df(A).H that is the linear approximation, which is the intuitive idea of differential (=linearization around a point A). Is it clear now? (I will update my post)
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:16
$begingroup$
I get the point. But, could you give an example of a linear transformation which is not differentiable, like say an inner product which does not have a derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:22
$begingroup$
@vidyarthi I promise I will complete the answer and let you know when it is done, however I have to leave for the moment.
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:40
$begingroup$
Can you give a reference for this kind of questions and theory?@PicaudVincent
$endgroup$
– Unknown x
Dec 1 '18 at 13:53
|
show 2 more comments
$begingroup$
Differentiability of a matrix function can be broken to mean differentiability in individual varibles(column vectors) using kronecker product. See [here]. So since the given inner product corresponds to certain vector-matrix multiplication, it can be seen to be differentiable since products usually are. Another way to see differentiability is by observing that the inner product corresponds to a quadratic form, which usually a homogenous polynomial in $n$ variables. Again, differentiability would be easy. Yet another way is to prove by induction considering the linearity of the inner product and its symmetry, as in the case of determinant or trace. See here and here for additional links
$endgroup$
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3021102%2fcheck-the-differentiability-of-the-given-function%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
The first step is to have differentiability definition in mind. From wikipedia
A function of several real variables $f: R^m → R^n$ is said to be
differentiable at a point $x_0$ if there exists a linear map $J: R^m → R^n$
such that
$$
lim_{hto 0}frac{|f(x_0+h)-f(x_0)-Jh|}{|h|}=0
$$
Now your application. Take any matrix $H$ and do the following computation:
begin{align*}
f(A+H)=&langle (A+H)^2x,x rangle \
=&langle (A^2+AH+HA+H^2)x,x rangle \
=&langle A^2x,x rangle+langle (AH+HA)x,x rangle+langle H^2x,x rangle
end{align*}
Now consider:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|f(A+H)-f(A)-langle (AH+HA)x,x rangle|}{|H|}
end{align*}
From the first computation this is also equal to:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}
end{align*}
However like
$$
frac{|langle H^2x,x rangle|}{|H|}lefrac{|H^2x||x|}{|H|}le|H||x|
$$
where we have used Cauchy-Schwarz and $|H^2x|le|H^2||x|$ (we assume that we have taken a matrix norm consistent with the vector norm)
it is clear that the limit $mathcal{l}$ is zero:
begin{align*}
0le mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}lelim_{Hto 0}|H||x|=0
end{align*}
This means that the linear application:
$$
Hmapsto df(A)cdot H =langle (AH+HA)x,x rangle
$$
is your differential at point $A$
Answer to comments. To find the differential, I have proceeded by direct identification after algebra manipulation of $f(A+H)$:
$$
f(A+H)=langle (A+H)^2x,x rangle=underbrace{langle A^2x,x rangle}_{f(A)}+underbrace{langle (AH+HA)x,x rangle}_{df(A)cdot H}+underbrace{langle H^2x,x rangle}_{text{reminder that vanishes when H}to 0}
$$
This direct approach was possible because your example involved only matrix/vector products, scalar products etc.
Sometimes expressions are more complex. You must first find a candidate for the differential (you can use partial derivatives, chain rule etc...) then, in case of doubt, you must prove that the limit (the first equation of my post, from wikipedia) exists.
An useful result is that existence of the previous limit is equivalent to the continuity of the partial derivatives in a neighborhood of $A$.
Example: $f:mathbb{R}^nni xto|x|_2=sqrt{sum_i x_i^2}$.
A candidate for the differential at point $ainmathbb{R}^n$ is:
$$
df(a)cdot h=sum_{i=1}^n frac{partial f}{partial x_i}(a)h_i=frac{1}{|a|_2}sum_{i=1}^n a_ih_i
$$
It is clear that the function $xto|x|_2$ is differentiable at any point $ainmathbb{R}^n-{0}$. However the point $a=0_{mathbb{R}^n}$ is suspicious. To prove differentiability we must prove that in a neighborhood of $0_{mathbb{R}^n}$ all partial derivatives are continuous.
$$
frac{partial f}{partial x_i}(a)=frac{a_i}{|a|_2}
$$
Unfortunately these functions are not continuous at $a=0_{mathbb{R}^n}$. To see that, we will find two different paths approaching $0_{mathbb{R}^n}$ but with two different values for the function (thus the function is not continuous).
Define a curve $gamma_i:tinmathbb{R}to gamma_i(t):=t mathbf{e}_i$, observe that $gamma_i(0)=0_{mathbb{R}^n}$
Now observe that:
$$
frac{partial f}{partial x_i}(gamma_i(t))=frac{t}{sqrt{t^2}}=left{begin{array}{rl}+1, t>0 \ -1, t<0end{array}right.
$$
clearly the partial derivative is not continuous, hence the function $xto|x|_2$ is not differentiable at $a=0$ (but it is differentiable at any other point of $mathbb{R}^n$).
Concerning good reference: I personally really like Henri Cartan book Differential Calculus On Normed Spaces a wonderful book to learn differential calculus. However everything in done in Banach spaces, not sure it is the right choice for a primer book on the subject. At a lower level I have no suggestion for the moment sorry.
One last thing I also answered this question which was quite similar to ours. Emphasis is done on the difference between the differential $df$ and the gradient $nabla f$.
$endgroup$
$begingroup$
fantastic answer! I hope you could also prove by induction on $n$ and the homogenous nature of quadratic forms. But, how did you come to know beforehand that $langle (AH+HA)x, xrangle$ is the derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:10
$begingroup$
thanks, happy if it helps. To find the expression of the derivative, simply look at the first computation: the idea is just to expand f(A+H) you get f(A)+df(A).H that is the linear approximation, which is the intuitive idea of differential (=linearization around a point A). Is it clear now? (I will update my post)
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:16
$begingroup$
I get the point. But, could you give an example of a linear transformation which is not differentiable, like say an inner product which does not have a derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:22
$begingroup$
@vidyarthi I promise I will complete the answer and let you know when it is done, however I have to leave for the moment.
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:40
$begingroup$
Can you give a reference for this kind of questions and theory?@PicaudVincent
$endgroup$
– Unknown x
Dec 1 '18 at 13:53
|
show 2 more comments
$begingroup$
The first step is to have differentiability definition in mind. From wikipedia
A function of several real variables $f: R^m → R^n$ is said to be
differentiable at a point $x_0$ if there exists a linear map $J: R^m → R^n$
such that
$$
lim_{hto 0}frac{|f(x_0+h)-f(x_0)-Jh|}{|h|}=0
$$
Now your application. Take any matrix $H$ and do the following computation:
begin{align*}
f(A+H)=&langle (A+H)^2x,x rangle \
=&langle (A^2+AH+HA+H^2)x,x rangle \
=&langle A^2x,x rangle+langle (AH+HA)x,x rangle+langle H^2x,x rangle
end{align*}
Now consider:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|f(A+H)-f(A)-langle (AH+HA)x,x rangle|}{|H|}
end{align*}
From the first computation this is also equal to:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}
end{align*}
However like
$$
frac{|langle H^2x,x rangle|}{|H|}lefrac{|H^2x||x|}{|H|}le|H||x|
$$
where we have used Cauchy-Schwarz and $|H^2x|le|H^2||x|$ (we assume that we have taken a matrix norm consistent with the vector norm)
it is clear that the limit $mathcal{l}$ is zero:
begin{align*}
0le mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}lelim_{Hto 0}|H||x|=0
end{align*}
This means that the linear application:
$$
Hmapsto df(A)cdot H =langle (AH+HA)x,x rangle
$$
is your differential at point $A$
Answer to comments. To find the differential, I have proceeded by direct identification after algebra manipulation of $f(A+H)$:
$$
f(A+H)=langle (A+H)^2x,x rangle=underbrace{langle A^2x,x rangle}_{f(A)}+underbrace{langle (AH+HA)x,x rangle}_{df(A)cdot H}+underbrace{langle H^2x,x rangle}_{text{reminder that vanishes when H}to 0}
$$
This direct approach was possible because your example involved only matrix/vector products, scalar products etc.
Sometimes expressions are more complex. You must first find a candidate for the differential (you can use partial derivatives, chain rule etc...) then, in case of doubt, you must prove that the limit (the first equation of my post, from wikipedia) exists.
An useful result is that existence of the previous limit is equivalent to the continuity of the partial derivatives in a neighborhood of $A$.
Example: $f:mathbb{R}^nni xto|x|_2=sqrt{sum_i x_i^2}$.
A candidate for the differential at point $ainmathbb{R}^n$ is:
$$
df(a)cdot h=sum_{i=1}^n frac{partial f}{partial x_i}(a)h_i=frac{1}{|a|_2}sum_{i=1}^n a_ih_i
$$
It is clear that the function $xto|x|_2$ is differentiable at any point $ainmathbb{R}^n-{0}$. However the point $a=0_{mathbb{R}^n}$ is suspicious. To prove differentiability we must prove that in a neighborhood of $0_{mathbb{R}^n}$ all partial derivatives are continuous.
$$
frac{partial f}{partial x_i}(a)=frac{a_i}{|a|_2}
$$
Unfortunately these functions are not continuous at $a=0_{mathbb{R}^n}$. To see that, we will find two different paths approaching $0_{mathbb{R}^n}$ but with two different values for the function (thus the function is not continuous).
Define a curve $gamma_i:tinmathbb{R}to gamma_i(t):=t mathbf{e}_i$, observe that $gamma_i(0)=0_{mathbb{R}^n}$
Now observe that:
$$
frac{partial f}{partial x_i}(gamma_i(t))=frac{t}{sqrt{t^2}}=left{begin{array}{rl}+1, t>0 \ -1, t<0end{array}right.
$$
clearly the partial derivative is not continuous, hence the function $xto|x|_2$ is not differentiable at $a=0$ (but it is differentiable at any other point of $mathbb{R}^n$).
Concerning good reference: I personally really like Henri Cartan book Differential Calculus On Normed Spaces a wonderful book to learn differential calculus. However everything in done in Banach spaces, not sure it is the right choice for a primer book on the subject. At a lower level I have no suggestion for the moment sorry.
One last thing I also answered this question which was quite similar to ours. Emphasis is done on the difference between the differential $df$ and the gradient $nabla f$.
$endgroup$
$begingroup$
fantastic answer! I hope you could also prove by induction on $n$ and the homogenous nature of quadratic forms. But, how did you come to know beforehand that $langle (AH+HA)x, xrangle$ is the derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:10
$begingroup$
thanks, happy if it helps. To find the expression of the derivative, simply look at the first computation: the idea is just to expand f(A+H) you get f(A)+df(A).H that is the linear approximation, which is the intuitive idea of differential (=linearization around a point A). Is it clear now? (I will update my post)
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:16
$begingroup$
I get the point. But, could you give an example of a linear transformation which is not differentiable, like say an inner product which does not have a derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:22
$begingroup$
@vidyarthi I promise I will complete the answer and let you know when it is done, however I have to leave for the moment.
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:40
$begingroup$
Can you give a reference for this kind of questions and theory?@PicaudVincent
$endgroup$
– Unknown x
Dec 1 '18 at 13:53
|
show 2 more comments
$begingroup$
The first step is to have differentiability definition in mind. From wikipedia
A function of several real variables $f: R^m → R^n$ is said to be
differentiable at a point $x_0$ if there exists a linear map $J: R^m → R^n$
such that
$$
lim_{hto 0}frac{|f(x_0+h)-f(x_0)-Jh|}{|h|}=0
$$
Now your application. Take any matrix $H$ and do the following computation:
begin{align*}
f(A+H)=&langle (A+H)^2x,x rangle \
=&langle (A^2+AH+HA+H^2)x,x rangle \
=&langle A^2x,x rangle+langle (AH+HA)x,x rangle+langle H^2x,x rangle
end{align*}
Now consider:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|f(A+H)-f(A)-langle (AH+HA)x,x rangle|}{|H|}
end{align*}
From the first computation this is also equal to:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}
end{align*}
However like
$$
frac{|langle H^2x,x rangle|}{|H|}lefrac{|H^2x||x|}{|H|}le|H||x|
$$
where we have used Cauchy-Schwarz and $|H^2x|le|H^2||x|$ (we assume that we have taken a matrix norm consistent with the vector norm)
it is clear that the limit $mathcal{l}$ is zero:
begin{align*}
0le mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}lelim_{Hto 0}|H||x|=0
end{align*}
This means that the linear application:
$$
Hmapsto df(A)cdot H =langle (AH+HA)x,x rangle
$$
is your differential at point $A$
Answer to comments. To find the differential, I have proceeded by direct identification after algebra manipulation of $f(A+H)$:
$$
f(A+H)=langle (A+H)^2x,x rangle=underbrace{langle A^2x,x rangle}_{f(A)}+underbrace{langle (AH+HA)x,x rangle}_{df(A)cdot H}+underbrace{langle H^2x,x rangle}_{text{reminder that vanishes when H}to 0}
$$
This direct approach was possible because your example involved only matrix/vector products, scalar products etc.
Sometimes expressions are more complex. You must first find a candidate for the differential (you can use partial derivatives, chain rule etc...) then, in case of doubt, you must prove that the limit (the first equation of my post, from wikipedia) exists.
An useful result is that existence of the previous limit is equivalent to the continuity of the partial derivatives in a neighborhood of $A$.
Example: $f:mathbb{R}^nni xto|x|_2=sqrt{sum_i x_i^2}$.
A candidate for the differential at point $ainmathbb{R}^n$ is:
$$
df(a)cdot h=sum_{i=1}^n frac{partial f}{partial x_i}(a)h_i=frac{1}{|a|_2}sum_{i=1}^n a_ih_i
$$
It is clear that the function $xto|x|_2$ is differentiable at any point $ainmathbb{R}^n-{0}$. However the point $a=0_{mathbb{R}^n}$ is suspicious. To prove differentiability we must prove that in a neighborhood of $0_{mathbb{R}^n}$ all partial derivatives are continuous.
$$
frac{partial f}{partial x_i}(a)=frac{a_i}{|a|_2}
$$
Unfortunately these functions are not continuous at $a=0_{mathbb{R}^n}$. To see that, we will find two different paths approaching $0_{mathbb{R}^n}$ but with two different values for the function (thus the function is not continuous).
Define a curve $gamma_i:tinmathbb{R}to gamma_i(t):=t mathbf{e}_i$, observe that $gamma_i(0)=0_{mathbb{R}^n}$
Now observe that:
$$
frac{partial f}{partial x_i}(gamma_i(t))=frac{t}{sqrt{t^2}}=left{begin{array}{rl}+1, t>0 \ -1, t<0end{array}right.
$$
clearly the partial derivative is not continuous, hence the function $xto|x|_2$ is not differentiable at $a=0$ (but it is differentiable at any other point of $mathbb{R}^n$).
Concerning good reference: I personally really like Henri Cartan book Differential Calculus On Normed Spaces a wonderful book to learn differential calculus. However everything in done in Banach spaces, not sure it is the right choice for a primer book on the subject. At a lower level I have no suggestion for the moment sorry.
One last thing I also answered this question which was quite similar to ours. Emphasis is done on the difference between the differential $df$ and the gradient $nabla f$.
$endgroup$
The first step is to have differentiability definition in mind. From wikipedia
A function of several real variables $f: R^m → R^n$ is said to be
differentiable at a point $x_0$ if there exists a linear map $J: R^m → R^n$
such that
$$
lim_{hto 0}frac{|f(x_0+h)-f(x_0)-Jh|}{|h|}=0
$$
Now your application. Take any matrix $H$ and do the following computation:
begin{align*}
f(A+H)=&langle (A+H)^2x,x rangle \
=&langle (A^2+AH+HA+H^2)x,x rangle \
=&langle A^2x,x rangle+langle (AH+HA)x,x rangle+langle H^2x,x rangle
end{align*}
Now consider:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|f(A+H)-f(A)-langle (AH+HA)x,x rangle|}{|H|}
end{align*}
From the first computation this is also equal to:
begin{align*}
mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}
end{align*}
However like
$$
frac{|langle H^2x,x rangle|}{|H|}lefrac{|H^2x||x|}{|H|}le|H||x|
$$
where we have used Cauchy-Schwarz and $|H^2x|le|H^2||x|$ (we assume that we have taken a matrix norm consistent with the vector norm)
it is clear that the limit $mathcal{l}$ is zero:
begin{align*}
0le mathcal{l}=lim_{Hto 0}frac{|langle H^2x,x rangle|}{|H|}lelim_{Hto 0}|H||x|=0
end{align*}
This means that the linear application:
$$
Hmapsto df(A)cdot H =langle (AH+HA)x,x rangle
$$
is your differential at point $A$
Answer to comments. To find the differential, I have proceeded by direct identification after algebra manipulation of $f(A+H)$:
$$
f(A+H)=langle (A+H)^2x,x rangle=underbrace{langle A^2x,x rangle}_{f(A)}+underbrace{langle (AH+HA)x,x rangle}_{df(A)cdot H}+underbrace{langle H^2x,x rangle}_{text{reminder that vanishes when H}to 0}
$$
This direct approach was possible because your example involved only matrix/vector products, scalar products etc.
Sometimes expressions are more complex. You must first find a candidate for the differential (you can use partial derivatives, chain rule etc...) then, in case of doubt, you must prove that the limit (the first equation of my post, from wikipedia) exists.
An useful result is that existence of the previous limit is equivalent to the continuity of the partial derivatives in a neighborhood of $A$.
Example: $f:mathbb{R}^nni xto|x|_2=sqrt{sum_i x_i^2}$.
A candidate for the differential at point $ainmathbb{R}^n$ is:
$$
df(a)cdot h=sum_{i=1}^n frac{partial f}{partial x_i}(a)h_i=frac{1}{|a|_2}sum_{i=1}^n a_ih_i
$$
It is clear that the function $xto|x|_2$ is differentiable at any point $ainmathbb{R}^n-{0}$. However the point $a=0_{mathbb{R}^n}$ is suspicious. To prove differentiability we must prove that in a neighborhood of $0_{mathbb{R}^n}$ all partial derivatives are continuous.
$$
frac{partial f}{partial x_i}(a)=frac{a_i}{|a|_2}
$$
Unfortunately these functions are not continuous at $a=0_{mathbb{R}^n}$. To see that, we will find two different paths approaching $0_{mathbb{R}^n}$ but with two different values for the function (thus the function is not continuous).
Define a curve $gamma_i:tinmathbb{R}to gamma_i(t):=t mathbf{e}_i$, observe that $gamma_i(0)=0_{mathbb{R}^n}$
Now observe that:
$$
frac{partial f}{partial x_i}(gamma_i(t))=frac{t}{sqrt{t^2}}=left{begin{array}{rl}+1, t>0 \ -1, t<0end{array}right.
$$
clearly the partial derivative is not continuous, hence the function $xto|x|_2$ is not differentiable at $a=0$ (but it is differentiable at any other point of $mathbb{R}^n$).
Concerning good reference: I personally really like Henri Cartan book Differential Calculus On Normed Spaces a wonderful book to learn differential calculus. However everything in done in Banach spaces, not sure it is the right choice for a primer book on the subject. At a lower level I have no suggestion for the moment sorry.
One last thing I also answered this question which was quite similar to ours. Emphasis is done on the difference between the differential $df$ and the gradient $nabla f$.
edited Dec 1 '18 at 23:15
answered Dec 1 '18 at 10:49
Picaud VincentPicaud Vincent
1,52439
1,52439
$begingroup$
fantastic answer! I hope you could also prove by induction on $n$ and the homogenous nature of quadratic forms. But, how did you come to know beforehand that $langle (AH+HA)x, xrangle$ is the derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:10
$begingroup$
thanks, happy if it helps. To find the expression of the derivative, simply look at the first computation: the idea is just to expand f(A+H) you get f(A)+df(A).H that is the linear approximation, which is the intuitive idea of differential (=linearization around a point A). Is it clear now? (I will update my post)
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:16
$begingroup$
I get the point. But, could you give an example of a linear transformation which is not differentiable, like say an inner product which does not have a derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:22
$begingroup$
@vidyarthi I promise I will complete the answer and let you know when it is done, however I have to leave for the moment.
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:40
$begingroup$
Can you give a reference for this kind of questions and theory?@PicaudVincent
$endgroup$
– Unknown x
Dec 1 '18 at 13:53
|
show 2 more comments
$begingroup$
fantastic answer! I hope you could also prove by induction on $n$ and the homogenous nature of quadratic forms. But, how did you come to know beforehand that $langle (AH+HA)x, xrangle$ is the derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:10
$begingroup$
thanks, happy if it helps. To find the expression of the derivative, simply look at the first computation: the idea is just to expand f(A+H) you get f(A)+df(A).H that is the linear approximation, which is the intuitive idea of differential (=linearization around a point A). Is it clear now? (I will update my post)
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:16
$begingroup$
I get the point. But, could you give an example of a linear transformation which is not differentiable, like say an inner product which does not have a derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:22
$begingroup$
@vidyarthi I promise I will complete the answer and let you know when it is done, however I have to leave for the moment.
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:40
$begingroup$
Can you give a reference for this kind of questions and theory?@PicaudVincent
$endgroup$
– Unknown x
Dec 1 '18 at 13:53
$begingroup$
fantastic answer! I hope you could also prove by induction on $n$ and the homogenous nature of quadratic forms. But, how did you come to know beforehand that $langle (AH+HA)x, xrangle$ is the derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:10
$begingroup$
fantastic answer! I hope you could also prove by induction on $n$ and the homogenous nature of quadratic forms. But, how did you come to know beforehand that $langle (AH+HA)x, xrangle$ is the derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:10
$begingroup$
thanks, happy if it helps. To find the expression of the derivative, simply look at the first computation: the idea is just to expand f(A+H) you get f(A)+df(A).H that is the linear approximation, which is the intuitive idea of differential (=linearization around a point A). Is it clear now? (I will update my post)
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:16
$begingroup$
thanks, happy if it helps. To find the expression of the derivative, simply look at the first computation: the idea is just to expand f(A+H) you get f(A)+df(A).H that is the linear approximation, which is the intuitive idea of differential (=linearization around a point A). Is it clear now? (I will update my post)
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:16
$begingroup$
I get the point. But, could you give an example of a linear transformation which is not differentiable, like say an inner product which does not have a derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:22
$begingroup$
I get the point. But, could you give an example of a linear transformation which is not differentiable, like say an inner product which does not have a derivative?
$endgroup$
– vidyarthi
Dec 1 '18 at 11:22
$begingroup$
@vidyarthi I promise I will complete the answer and let you know when it is done, however I have to leave for the moment.
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:40
$begingroup$
@vidyarthi I promise I will complete the answer and let you know when it is done, however I have to leave for the moment.
$endgroup$
– Picaud Vincent
Dec 1 '18 at 11:40
$begingroup$
Can you give a reference for this kind of questions and theory?@PicaudVincent
$endgroup$
– Unknown x
Dec 1 '18 at 13:53
$begingroup$
Can you give a reference for this kind of questions and theory?@PicaudVincent
$endgroup$
– Unknown x
Dec 1 '18 at 13:53
|
show 2 more comments
$begingroup$
Differentiability of a matrix function can be broken to mean differentiability in individual varibles(column vectors) using kronecker product. See [here]. So since the given inner product corresponds to certain vector-matrix multiplication, it can be seen to be differentiable since products usually are. Another way to see differentiability is by observing that the inner product corresponds to a quadratic form, which usually a homogenous polynomial in $n$ variables. Again, differentiability would be easy. Yet another way is to prove by induction considering the linearity of the inner product and its symmetry, as in the case of determinant or trace. See here and here for additional links
$endgroup$
add a comment |
$begingroup$
Differentiability of a matrix function can be broken to mean differentiability in individual varibles(column vectors) using kronecker product. See [here]. So since the given inner product corresponds to certain vector-matrix multiplication, it can be seen to be differentiable since products usually are. Another way to see differentiability is by observing that the inner product corresponds to a quadratic form, which usually a homogenous polynomial in $n$ variables. Again, differentiability would be easy. Yet another way is to prove by induction considering the linearity of the inner product and its symmetry, as in the case of determinant or trace. See here and here for additional links
$endgroup$
add a comment |
$begingroup$
Differentiability of a matrix function can be broken to mean differentiability in individual varibles(column vectors) using kronecker product. See [here]. So since the given inner product corresponds to certain vector-matrix multiplication, it can be seen to be differentiable since products usually are. Another way to see differentiability is by observing that the inner product corresponds to a quadratic form, which usually a homogenous polynomial in $n$ variables. Again, differentiability would be easy. Yet another way is to prove by induction considering the linearity of the inner product and its symmetry, as in the case of determinant or trace. See here and here for additional links
$endgroup$
Differentiability of a matrix function can be broken to mean differentiability in individual varibles(column vectors) using kronecker product. See [here]. So since the given inner product corresponds to certain vector-matrix multiplication, it can be seen to be differentiable since products usually are. Another way to see differentiability is by observing that the inner product corresponds to a quadratic form, which usually a homogenous polynomial in $n$ variables. Again, differentiability would be easy. Yet another way is to prove by induction considering the linearity of the inner product and its symmetry, as in the case of determinant or trace. See here and here for additional links
edited Dec 1 '18 at 10:16
answered Dec 1 '18 at 10:03
vidyarthividyarthi
2,9641832
2,9641832
add a comment |
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3021102%2fcheck-the-differentiability-of-the-given-function%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
$begingroup$
... differentiable where? In a specific point, interval or the whole domain?
$endgroup$
– manooooh
Dec 1 '18 at 8:30
1
$begingroup$
@manooooh must be the whole of $mathbb{R}^{n^2}$
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21
$begingroup$
some hints can be found here
$endgroup$
– vidyarthi
Dec 1 '18 at 9:21