Implement pow(x, n).
原题链接:https://oj.leetcode.com/problems/powx-n/
public double pow(double x, int n) {
if(n== 0)
return 1;
if(n == 1)
return x;
if(n % 2 ==0)
return pow(x*x,n/2);
...
分类:
其他好文 时间:
2014-11-19 01:19:41
阅读次数:
157
If $A$ is a contraction, show that $$\bex A^*(I-AA^*)^{1/2}=(I-A^*A)^{1/2}A^*. \eex$$ Use this to show that if $A$ is a contraction on $\scrH$, then t...
分类:
其他好文 时间:
2014-11-19 00:10:53
阅读次数:
315
Let $A=A_1\oplus A_2$. Show that
(1). $W(A)$ is the convex hull of $W(A_1)$ and $W(A_2)$; i.e., the smallest convex set containing $W(A_1)\cup...
分类:
其他好文 时间:
2014-11-19 00:04:31
阅读次数:
272
For every matrix $A$, the matrix $$\bex \sex{\ba{cc} I&A\\ 0&I \ea} \eex$$ is invertible and its inverse is $$\bex \sex{\ba{cc} I&-A\\ 0&I \ea}. \eex$...
分类:
其他好文 时间:
2014-11-18 23:49:24
阅读次数:
217
(1). When $A$ is normal, the set $W(A)$ is the convex hull of the eigenvalues of $A$. For nonnormal matrices, $W(A)$ may be bigger than the convex hul...
分类:
其他好文 时间:
2014-11-18 23:41:26
阅读次数:
243
(1). The numerical radius defines a norm on $\scrL(\scrH)$.
分类:
其他好文 时间:
2014-11-18 23:39:33
阅读次数:
193
(1). The singular value decomposition leads tot eh polar decomposition: Every operator $A$ can be written as $A=UP$, where $U$ is unitary and $P$ is p...
分类:
其他好文 时间:
2014-11-18 13:20:04
阅读次数:
211
Show that the following statements are equivalent:
(1). $A$ is positive.
分类:
其他好文 时间:
2014-11-18 13:17:56
阅读次数:
186
For any matrix $A$ the series $$\bex \exp A=I+A+\frac{A^2}{2!}+\cdots+\frac{A^n}{n!}+\cdots \eex$$ converges. This is called the exponential of $A$. T...
分类:
其他好文 时间:
2014-11-18 13:14:41
阅读次数:
199
The set of all invertible matrices is a dense open subset of the set of all $n\times n$ matrices. The set of all unitary matrices is a compact subset ...
分类:
其他好文 时间:
2014-11-18 13:09:44
阅读次数:
120