问:
Let the focus S of parabola divide one of its focal chord in the ratio 2:1. If the tangent at Q cuts directrix at R such that RQ=6...

Let the focus S of parabola divide one of its focal chord in the ratio 2:1. If the tangent at Q cuts directrix at R such that RQ=6, find distance of focus from tangent at P.

Let P and Q be $(at^2,2at)$ and $(\frac{a}{t^2}, \frac{-2a}{t})$ respectively, for parabola $y^2=4ax$

So $$0= 2(-\frac{2a}{t})+2at$$
$$\implies t^2=2$$

Now tangent at Q is

$$\frac{y}{\sqrt 2} =x+\frac a2$$

So point R is $(-a, -\frac{a}{\sqrt 2})$

Then $$QR^2 = 36$$
$$\implies a=\frac{12}{\sqrt {11}}$$

So now, tangent at P is $$\sqrt 2y=x+2a$$ whose distance from $(a,0)$ is
$$d=\left | \frac{a+2a}{\sqrt 3}\right|$$
$$d=\sqrt 3 a$$
$$d=\frac{\sqrt 3 \times 12}{\sqrt {11}}$$

But given answer is 4

Where am I going wrong?

答:
You don't need to use coordinates for this problem. Line $PR$ is the tangent at $P$ and triangle $PQR$ is right-angled at $R$. Distance $FH$ is thus parallel to $QR$. By similar triangles:
$$
FH:QR=FP:QP=2:3,
\quad\text{hence:}\quad
FH={2\over3}QR=4.
$$


问:
Proof of discontinuity at a point
I am trying to prove that the function $f(x) = \frac{1}{x}$ for $x \neq 0$ and $0$ if $x = 0$ is continuous everywhere except $x = 0$. Here is my attempt.

We first prove continuity. Let $x_0 > 0$ and $\epsilon > 0$. Set $\delta = \min\left(\frac{x_0}{2}, \frac{\epsilon x_0^2}{2}\right)$. Then $|x - x_0| < \delta$ implies
\begin{align*}
|f(x) - f(x_0)| & = \left \lvert \frac{1}{x} - \frac{1}{x_0} \right \rvert \\
& = \frac{|x-x_0|}{xx_0} \\
& < \frac{\frac{x_0^2}{2} \epsilon}{\frac{x_0}{2}} \\
& = \epsilon.
\end{align*}

I'm stuck on the $x < 0$ case. In the above work, the step $|xx_0| = xx_0$ breaks down in that case unless $x < 0$, but $\delta$ can't depend on $x$.

To prove discontinuity at $x = 0$, I need to find $\epsilon > 0$. so that $\forall \delta > 0$, there exists $y$ such that $|y| < \delta$ and $|f(x) - f(y)| \geq \epsilon$. Here is my attempt.

Let $\epsilon = 0$, $\delta > 0$, and pick $0 > y > \delta$. Then $|y| = -y < \delta$. Also:
$$f(x) - f(y)| = \left \lvert f(0) - \frac{1}{y} \right \rvert = \frac{1}{y} < \delta.$$

This fails because $\delta$ has to be arbitrary, unless I can begin with the case where $\delta < 1$ and then take the case where $\delta \geq 1$.

答:
Let
$$x_n=\frac 1n \text{ and }\; y_n=-\frac 1n$$

We have

$$\lim_{n\to+\infty}x_n=\lim_{n\to+\infty}y_n=\color{red}{0}$$

$$f(x_n)=n\;\text{ and }\; f(y_n)=-n$$
So
$$\lim_{n\to+\infty}f(x_n)\ne\lim_{n\to+\infty}f(y_n)$$

thus, by the sequential catacterisation of the limit, we conclude that
$$\lim_{x\to\color{red}{0}}f(x)\;\text{ doesn't exist}$$

ContentLicense: CC BY-SA 4.0

Title: Proof of discontinuity at a point


问:
The "range" and "image" of a transformation refer to the same thing, right?
I'm hoping this is true because I've been told that "the rank of a transformation is the dimension of its image", and also that "the rank of a transformation is the dimension of its range". This doesn't make sense if range and image aren't the same thing, so I'm just wanting to be completely sure.

Furthermore, does codomain refer to the image of the transformation or to the vector space to which the images of the transformation are brought?

答: Most definitions I've seen hold that the codomain is the type of value that could come out of a function. For example, a polynomial function has the set of all Reals as the domain and since only real numbers can result from a polynomial function, the codomain is all Reals, too. (You cannot get imaginary numbers as the output of a polynomial function; all coefficients are Real and so is the domain.) However, polynomials, primarily even-degree ones, do NOT use all the Real numbers as outputs. The outputs a particular function actually uses from the set of all Reals is the image, also sometimes called the range. Thus, what could come out of a function is the codomain, but what actually comes out is the image (or range).


问:
Why is an alternating multilinear map called "alternating"?
I know it's just a small detail, but it's kind of bothering me... A multilinear map is called "alternating" if having two equal arguments makes it zero.

Why use the word "alternating" then? What precisely is alternating?

答:
A $k$-Tensor $\omega\in\mathcal{T}^{k}(V)$ is called alternating if
$$\omega(v_{1},\cdots ,v_i,\cdots v_j,\cdots, v_n)=-\omega(v_{1},\cdots ,v_j,\cdots v_i,\cdots, v_n)$$
for $v_1,\cdots v_{n} \quad in \quad V$.

As such, that is the definition that it is altered that the multilinear application changed the position coordinates and fixed the rest


答:
$x_0<0$ sets up the same way.

Suppose $x_0<0$

Let $\delta = \min (\frac {|x_0|}{2},\frac {|x_0|^2}{2})$

$|\frac {1}{x} - \frac {1}{x_0}| = |\frac {x_0-x}{xx_0}| < \epsilon $

$|x-x_0|<\delta \implies x_0<x<0 \implies xx_0 > 0$

$|\frac {1}{x} - \frac {1}{x_0}|< \frac {\delta}{xx_0} \le \epsilon$

In the next step, we must show that there exists an $\epsilon > 0$ such that for any $\delta$ there is an $x$ with $|x-0|<\delta$ such that $|f(x) - f(0)| > \epsilon$

Note we can not choose $\epsilon = 0$ as in the work above.  But we can choose $\epsilon  = 1$

Then with $x = \min (\frac 12, \frac {\delta}{2}), |f(x) - f(0)|>\epsilon$

Title: Proof of discontinuity at a point

Body:
I am trying to prove that the function $f(x) = \frac{1}{x}$ for $x \neq 0$ and $0$ if $x = 0$ is continuous everywhere except $x = 0$. Here is my attempt.

We first prove continuity. Let $x_0 > 0$ and $\epsilon > 0$. Set $\delta = \min\left(\frac{x_0}{2}, \frac{\epsilon x_0^2}{2}\right)$. Then $|x - x_0| < \delta$ implies
\begin{align*}
|f(x) - f(x_0)| & = \left \lvert \frac{1}{x} - \frac{1}{x_0} \right \rvert \\
& = \frac{|x-x_0|}{xx_0} \\
& < \frac{\frac{x_0^2}{2} \epsilon}{\frac{x_0}{2}} \\
& = \epsilon.
\end{align*}

I'm stuck on the $x < 0$ case. In the above work, the step $|xx_0| = xx_0$ breaks down in that case unless $x < 0$, but $\delta$ can't depend on $x$.

To prove discontinuity at $x = 0$, I need to find $\epsilon > 0$. so that $\forall \delta > 0$, there exists $y$ such that $|y| < \delta$ and $|f(x) - f(y)| \geq \epsilon$. Here is my attempt.

Let $\epsilon = 0$, $\delta > 0$, and pick $0 > y > \delta$. Then $|y| = -y < \delta$. Also:
$$f(x) - f(y)| = \left \lvert f(0) - \frac{1}{y} \right \rvert = \frac{1}{y} < \delta.$$

This fails because $\delta$ has to be arbitrary, unless I can begin with the case where $\delta < 1$ and then take the case where $\delta \geq 1$.


问:
Does there exist an infinite $\sigma-$algebra which has only countably many members?
Problem Statement: Does there exist an infinite $\sigma-$algebra which has only countably many members?

Solution: Denote our $\sigma-$algebra by $M$. If $A$ is a finite collection of disjoint members of $M$, i.e. $A=\{m_1,...,m_n\}$ w/ $m_i\cap m_j=\varnothing$, then for $M$ to be infinite we WLOG may find some $m'\in M$ such that $m'\not\subset \cup A$. Since $M$ is closed under set difference, union, and intersection we may form a novel collection of disjoint members of $M$:

$A'=\{m_1-m',m_1\cap m',...,m_n-m',m_n\cap m',m'-\cup A\}$

which due to the properties of $m'$ has at least one more member than $A$.

Consequently, there exists a countably infinite set $S$ of disjoint members of $M$. If we take $P(S)$, the power set of $S$, then $P$ will be uncountably infinite. But each member $x$ of $P$ will correspond to a unique member of $M$, namely $\cup x$, the union of all members of $x$. Thus $M$ contains uncountably many terms.

答:
I see two minor things wrong with this argument as it stands. First, the claim that there exists without loss of generality some $m' \in M$ that is not a subset of $\bigcup A$. This is false: consider the $\sigma$-algebra of open sets on $\mathbb{R} \setminus \{0\}$, and let $A = \{(-\infty,0), (0,\infty)\}$. $A$ is a finite collection of disjoint sets in the $\sigma$-algebra, but it also covers the whole space, so every member of that $\sigma$-algebra is a subset of $\bigcup A$. I suspect you want just $m' \notin A$.

Also, there's a minor issue at the end: if $\emptyset$ is in the $\sigma$-algebra, then the unions aren't unique. That's an easy enough fix, though -- you might as well just exclude $\emptyset$ from $S$.


答:
To prove it is continuous at $x_0\ne 0$ let $\delta < |x_0|$.

Then if $|x-x_0| < \delta$ then

either $x_0 - \delta < x<  x_0 +\delta < 0$ if $x_0 < 0$. or $0 < x_0-\delta < x < x_0 + \delta$ if $x_0> 0$.

Either way you have $x,x_0$ are the same sign.  And $xx_0 > 0$.

Title: Proof of discontinuity at a point


问:
A question in Reidemeister–Schreier rewriting process
I am reading about Reidemeister–Schreier rewriting process and I have the following question.

After we find a set of generators for the subgroup we find the set of its relators which are of the form $trt^{-1}$, where $t\in T$ (Schreier transversal) and $r$ are the relators of the group rewritten in terms of the generators of the subgroup.

My question is in the process where we rewrite these relators are we allowed to use that these relations hold in the group and thus in the subgroup?

For example if I have a group $G$ which has a relator $r=[a,b]$ and let $H$ be a subgroup that has as set of generators $S=\{a^{2},b^{2}\}$.

Now in order to write $r$ in terms of $S$ can I use that $a$ and $b$ commute with each other?

答:
No. You may not use identities in the group (as they just might be a consequence of the relator that is rewritten).
Formally, the rewriting process takes place in the free group and expresses normal subgroup generators of the kernel generated by relations.

In your example, the rewriting process to $x=a^2,y=b^2$ of rewriting the rule $[a,b]$ should result in a rule that $x$ and $y$ commute, and once you have stored that rule you may use it.

Indeed, when doing rewriting on the computer, what is done is to apply a heuristic of Tietze transformations to the resulting presentation to eliminate redundancies and possibly make use of some dependencies amonst the new generators that were found.


问:
Spectrum of a unitary
I have a unitary element $v$ in $C(S^{1}, \mathbb{C})$ with full spectrum (the whole circle). Is it possible to construct another unitary $u$ in $C(S^{1}, \mathbb{C})$ out of $v$ such that the spectrum of $u$ is not full (i.e. a unitary with smaller range)? </p>

答:
If I understand correctly, you have a surjective continuous map $v:S^1\to S^1$ and would like to construct a non-surjective continuous map $u:S^1\to S^1$ out of it. One way to do so is to let $u=f\circ v$ where $f:S^1\to S^1$ is continuous and not surjective. For example, $f(x+iy)=x+i|y|$ and $f(x+iy)=|x|+iy$ both do the job. So does a constant $f$, of course. </p>

<p>If you'd like to have some specific relation between $u$ and $v$, you should clarify the equation.  </p>

ContentLicense: CC BY-SA 3.0

Title: Spectrum of a unitary

Body:
If I understand correctly, you have a surjective continuous map $v:S^1\to S^1$ and would like to construct a non-surjective continuous map $u:S^1\to S^1$ out of it. One way to do so is to let $u=f\circ v$ where $f:S^1\to S^1$ is continuous and not surjective. For example, $f(x+iy)=x+i|y|$ and $f(x+iy)=|x|+iy$ both do the job. So does a constant $f$, of course.

If you'd like to have some specific relation between $u$ and $v$, you should clarify the equation.


问:
How to show $\mathbb{Z}[w]/(2,w) \simeq \mathbb{Z}_2$?
Let $\mathbb{Z}[w]=\mathbb{Z}[\frac{1+\sqrt{-15}}{2}]$ be the quadratic integers.

I want to show that $\mathbb{Z}[w]/(2,w) \simeq \mathbb{Z}_2$. It seems very clear, but how can I show the isomorphism rigorously by isomorphism? I found somewhat similar using 3rd isomorphism theorem(here). But I think there will be much easier way.

I tried $\mathbb{Z}[w]/(2,w) \simeq (\mathbb{Z}(X)/(f(X))/(2+f(X),X+f(X))$ but I'm not sure then it is isomorphic to $\mathbb{Z}(X)/(2,X)\simeq \mathbb{Z}_2$.

I also tried $\mathbb{Z}[X] \to \mathbb{Z}[w] \to \mathbb{Z}[w]/(2,w)$, but not sure what the kernel is. Obviousely $2,w$ goes to $0$ but isn't it possible that $1 \mapsto 0$?

答:
If it's not obvious that $\mathbb{Z}[X]/(2,X) \cong \mathbb{F}_2$, then quotient out by one element at a time:

$$ \mathbb{Z}[X]/(2,X) = \left( \mathbb{Z}[X] / (2) \right) / (X) $$

or

$$ \mathbb{Z}[X]/(2,X) = \left( \mathbb{Z}[X] / (X) \right) / (2) $$

and maybe it will be easier.


问:
Limit $a_n = \frac{n!}{\sqrt{(2n+1)!}}, \quad n\in\mathbb{N}$
How do I show that the result is zero?

$\lim(a_n)= \frac{n!}{\sqrt{(2n+1)!}}, \quad n\in\mathbb{N}$

$\frac{(n+1)!}{\sqrt{(2(n+1)+1)!}}/
\frac{n!}{\sqrt{(2n+1)!}}
$

$\frac{(n+1)}{\sqrt{(2n+3)!}}*
{\sqrt{(2n+1)!}}
$

I will use the ratio test, but in the calculations I will get to the result 1/2 which is quite wrong, see the previous procedure.

答: From $\binom{2n}{n} \ge 1$ we obtain $\sqrt{(2n)!} \ge n!,$ hence $\frac{n!}{\sqrt{(2n+1)!}} \le \frac{1}{\sqrt{2n+1}} \to 0.$


问:
If $\int f=0$ then $f=0$ a.e. using Inequality
I am really stuck on the last bit, but also want to know if my solutions is correct, there may be others out there but I fully understand my own solutions and would like proof verification I guess. And every step I take I want to know if I gave the correct reason why, I am very picky about understanding fully every step of my solutions.

Let $f$ be a function. Assume $f$ is integrable and non-negative on some Lebesgue measurable set $E$. Here measure is given by $m$. For $\alpha>0$ define
$$E_\alpha:=\{x \in E : f(x) > \alpha \}.$$
Prove then that
$$m(E_\alpha) \le \frac{1}{\alpha} \int_E f dm. $$

Here is my attempt:

First we define the simple function
$$g(x)=\alpha \chi_{E_\alpha}(x).$$
As $f$ is defined on all of $E$ where as $g$ is defined over $E_\alpha$ together with zero product property we have that
$$0 \le g(x) \le f(x).$$
Thus by monotonicity of the Lebesgue integral we have that
\begin{align*}
     \alpha m(E_\alpha) &= \int_{E_\alpha} g(x) dm \\
     &\le \int_E f(x) dm
 \end{align*}
And as $\alpha$ is non-zero we can divide by it and we get the desired result.

Furthermore, assuming $\int_E f=0$ we can use the inequality to show $f=0$ a.e. on $E$. Take $\alpha = \frac{1}{n}$ for some (this is some $n$ correct??) $n \in \mathbb{N}$. Next compute the measure of $E_{\frac{1}{n}}$ using the inequality. \begin{align*}
     m(E_{\frac{1}{n}}) &\le \frac{1}{\frac{1}{n}} \int_E f dm \\
     &= n \int_E f dm \\
     &= n (0) \\
     &=0
 \end{align*}
Thus $m(E_{\frac{1}{n}})=0.$ Before we continue note that $\bigcup_{n \in \mathbb{N}} E_{\frac{1}{n}}=E_0$. And we can compute
\begin{align*}
     m(E_0) &= m(\{x \in E : f(x) >0\}) \\
     &= m (\bigcup_{n \in \mathbb{N}} \{x \in E : f(x) > \frac{1}{n}\}),
 \end{align*}
which is a countable union of measure zero sets thus by countable sub-additivity we have that $m(E_0)=0$. I get stuck showing that $m(E_0)=0$ gives me $m(E)=0$ and thus $f$ is identically zero a.e. on $E$.

答:
You don't want $m(E) = 0$ (it's not true in any interesting case).

For $f$ non-negative, $E_0 = \{x \in E : f(x) \neq 0\}$, so $m(E_0) = 0$ is precisely $f=0$ a.e.


答:
Split it up into:

(n / sqrt ((2n + 1) (2n))) * ((n-1) / sqrt ((2n-2)(2n-3)) * ((n-2) / sqrt((2n-4)(2n-5)) ...

Each factor is slightly smaller than 1/2, so the total is slightly smaller than (1/2)^n.

Title: Limit $a_n = \frac{n!}{\sqrt{(2n+1)!}}, \quad n\in\mathbb{N}$

Body:
How do I show that the result is zero?

$\lim(a_n)= \frac{n!}{\sqrt{(2n+1)!}}, \quad n\in\mathbb{N}$

$\frac{(n+1)!}{\sqrt{(2(n+1)+1)!}}/
\frac{n!}{\sqrt{(2n+1)!}}
$

$\frac{(n+1)}{\sqrt{(2n+3)!}}*
{\sqrt{(2n+1)!}}
$

I will use the ratio test, but in the calculations I will get to the result 1/2 which is quite wrong, see the previous procedure.


问:
Identifying the quotient ring
I'm trying to apply exactly the same technique as demonstrated in this example from Artin's Algebra --  -- to the ring $\mathbb Z[x]/(5,x^2+3)$. In my case the top arrow from Artin's figure (11.4.6) corresponds to $\mathbb Z[x]\to \mathbb Z, x\mapsto 5$, and the residue of $x^2+3$ is $5^2+3=28$ (which corresponds to Artin's $2^2+1=5$). Shouldn't I get $\mathbb Z_{28}$ then? I was told that this answer isn't correct. But I don't get why I got the wrong answer by following exactly the same process as in Artin's example.

答:
Artin's situation and yours are very different.

You can either first kill $5$ and then $x^2+3$ or conversely.

In the former case you first get $\mathbb{F}_5[x]$ and then $\mathbb{F}_{25}$, because the polynomial $x^2+3$ is irreducible over $\mathbb{F}_5$.

If you first kill $x^2+3$, you get $\mathbb{Z}[i\sqrt{3}]$ and here you need to find the quotient modulo the ideal generated by $5$. This adds a few complications, because $\mathbb{Z}[i\sqrt{3}]$ is not a PID, see Is $\mathbb Z[\sqrt{-3}]$ Euclidean under some other norm?

Title: Identifying the quotient ring


问:
A sum of determinants
Let n be a positive integer, $n \ge 2$ and $ A \in \mathcal{M}_{n}(\mathbb{C}) $. $M$ is the set of matrices which are obtained by swapping exactly $2$ elements of the same row or column of $A$. Calculate $ \sum_{X \in M} det X$, depending on A.

I saw that for $n = 2$ the sum is $0$ and my intuition(verified on small numbers) would be that for $n > 2$, the sum should be equal to $2n\binom{n-1}{2}detA$ (for $n=3$ the sum is $6detA$). The reason is that I think that for the products that don't appear by expanding in the original determinant A, we can find their opposite in other matrices from $M$. Now, by switching elements and counting, we can see that the products we find by expanding $detA$ appear $2n\binom{n-1}{2}$ times. However, i don't have a clear proof of the fact that other products find their opposite.

By product, i was referring to something of the type of $sgn(\sigma)a_{1\sigma(1)}...a_{n\sigma(n)}$ that show up in all the matrices from $M$, since $detA = \sum_{\sigma \in S(n)} sgn(\sigma)a_{1\sigma(1)}...a_{n\sigma(n)}$ and we consider $A = (a_{ij})_{n×n}$.

Can you help me on this one?

答:
You can define a function $F(v_1,..., v_n) = \sum_{X\in M} \det(X)$, where the $M$ is built out of the matrix whose columns are the vectors $v_1,..., v_n$.

This function is clearly multilinear as the operations of scaling or adding two vectors in a single row or column commute with swapping a specific two elements in a specific row or column.

We want to see that this is alternating, so suppose that $v_i = v_j$ and for concreteness let us suppose $v_i = v_j = (a_1, a_2,..., a_n)^T$. When you consider the value of $F(v_1,..., v_n)$ in this case several things can happen:

If the swap occurs and no term from the column $i$ or $j$ is moved then the resulting matrix has $0$ determinant since it has repeated columns.

If the swaps changes the two elements in some row that correspond to coumns $i$ and $j$ then again we end up with something that has repeated columns and so determinant $0$.

This tells us that the changes either occur within column $i$ or $j$, or it swaps an element of some row involving exactly one of these columns. We will see in either case we end up having cancelations in the value of $F$.

If the swap occurs within column $i$, swapping to elements, say WLOG the ones of the first two rows, then there is also another matrix in $M$ corresponding to making this same swap but instead in the column $j$. Consider then the vector $w= (a_1 + a_2, a_1 + a_2, 2a_3,..., 2a_n)^T$ and realize that

$\det(v_1,..., v_{i-1}, w, v_{i + 1},..., v_{j-1}, w, v_{j + 1},..., v_n) = 0$

because it has repeated columns. On the other hand, by the linearity of determinant we get that this same determinant is the same as distributing the sums. Concretely if $w_1 = (a_2, a_1, a_3,..., a_n)^T then the determinant is

$0 = \det(v_1,..., v_{i-1}, w_1, v_{i + 1},..., v_{j-1}, w_1, v_{j + 1},..., v_n)\\+ \det(v_1,..., v_{i-1}, w_1, v_{i + 1},..., v_{j-1}, v_2, v_{j + 1},..., v_n)\\ + \det(v_1,..., v_{i-1}, v_1, v_{i + 1},..., v_{j-1}, w_1, v_{j + 1},..., v_n)\\+ \det(v_1,..., v_{i-1}, w_1, v_{i + 1},..., v_{j-1}, w_1, v_{j + 1},..., v_n)\\=
\det(v_1,..., v_{i-1}, w_1, v_{i + 1},..., v_{j-1}, v_2, v_{j + 1},..., v_n)\\ + \det(v_1,..., v_{i-1}, v_1, v_{i + 1},..., v_{j-1}, w_1, v_{j + 1},..., v_n)$
and this last expression are two terms corresponding to the aforementioned swaps, so they cancel out.[More succintly, the two resulting matrices have two columns exchanged.]

Finally, if the swap involves changing two elements of a row and exactly one of them is ins row $i$, then of course we have the corresponding swap but changing instead the element in the column $j$. The two obtained matrices, after these swaps, are almost the same, except that they have column $i$ and $j$ are interchanged. This implies the determinant of one is minus the determinant of the other, and so when you do the sum in $F$ they also cancel out. [These cancelling outs are the ones you say you expect, but in the expansion version of the determinant is hard to keep track of them.]

These are all possibilities, so we get $F$ is alternating. Since the determinant generated the multilinear alternating forms we get $F(X) = c\det(X)$ for some contant $c$. To evaluate the constant we plug in for $X$ the identity matrix (i.e. the standard vectors).

Notice that no swap can involve two ones, since they appear in different columns and different rows so, either we exchange two zeroes or one $1$ with a $0$. In the latter case, we create a matrix that has a row or column consisting of only $0$'s so its determinant is 0.

This implies that $F(I)$ is exactly the number of ways of swapping two zeroes that are in the same row or the same column. There are $2n$ of picking the row/column, and $\binom{n-1}{2}$ ways of picking the two zeroes. Furhtermore, each obtained matrix is still the identity so its determinant is $1$. We conclude $c = F(I) = 2n\binom{n - 1}{2}$, that is

$F(X) = 2n\binom{n - 1}{2}\det(X)$

as claimed.

Title: A sum of determinants


问:
Finding the characteristic polynomial of this matrix
I have a question about this post.

How can we know that the geometric multiplicity of the eigenvalue $\lambda=0$ is $n-1$?
I get that $0$ is an eigenvalue of $A$ because $\textrm{det}A=0$, but I can't get why its geometric multiplicity is $n-1$.

答:
Because $(1, -\frac{1}{2}, 0, ..., 0)$, $(1, 0, -\frac{1}{3}, 0, ..., 0)$, ..., $(1, 0,..., 0, -\frac{1}{n})$ are linearly independent engenvectors.

Another way of seeing it is by simply noting that all the rows are equal. (The thing written in the paragraph above illustrates why it is enough to note this).


问:
Find $\mathbb{P}(X>6\;|\;X>2)$
Let $X$ be a random variable with density:

\begin{equation}
  f(x) =
    \begin{cases}
      \frac{1}{4}e^{-\frac{x}{4}}, &  x\geq0\\
      0, & \text{elsewhere}\\
    \end{cases}
\end{equation}

Find $\mathbb{P}(X>3)$.

Find $\mathbb{P}(1\geq X<10)$.

Find $\mathbb{P}(X>6\;|\;X>2)$.

My attempt:

I know how to do the first two problems but I don't know how to do the third one. Is there a formula I should use to convert the conditional probability into individual ones?

$\mathbb{P}(X>3)=\int_3^\infty\frac{1}{4}e^{-\frac{x}{4}}dx=[-e^{-\frac{x}{4}}]^\infty_3=e^{-\frac{3}{4}}$

$\mathbb{P}(1\geq X<10)=\int^{10}_1\frac{1}{4}e^{-\frac{x}{4}}=[-e^{-\frac{x}{4}}]^{10}_1=e^{-\frac{1}{4}}-e^{-\frac{5}{2}}$

答:
Hint.

In general, the conditional probability is given by

$$P(A|B)=\frac{P(A\cap B)}{P(B)}\;.$$

For (3), let $A=\{X>6\}$ and $B=\{X>2\}$. Note that $A\cap B=A$.

So you basically calculate $P(X>6)$ and $P(X>2)$ and then divide.

Alternatively, you may use the memorylessness of the exponential distribution so that you only need $P(X>4)$.

Title: Find $\mathbb{P}(X>6\;|\;X>2)$


问:
distance point to affine subspace
I have $n$ points $x_i\in\mathbb{R}^N$, $n \le N$. Is there a general formula for the (squared) distance of another point $b$ to the subspace defined by the $x_i$? (Note that I'm not only looking for hyperplanes; the codimension can be larger than 1.)

答:
As suggested in a comment we may assume that the point $\tilde{x}$ is the origin of coordinates, the coordinates of the other $k+1$ points being $x_0,x_1,\dots x_{k}$. I will assume that the given $k+1$ points span the subspace of dimension $k$ (otherwise the excessive points are removed until the points are linearly independent).

Introducing the vectors
$$
v_0=x_0,\quad\forall i=1\dots k:\ v_i=x_i-x_0,
$$
an arbitrary point of the subspace defined by $x_i$ can be written as:
$$
r=v_0+a_1v_1+\cdots+a_k v_k
$$
where $a_i$ are arbitrary real numbers.

We are seeking the vector $a=(a_1,\dots,a_k)$ which minimizes:
$$
r^2=(v_0+a_1v_1+\cdots+a_k v_k)^2=a^T Ua+2a^T V+v_0^2,\tag1
$$
where $U$ is symmetric positive definite  matrix with elements $U_{ij}=v_i\cdot v_j$ and $V$ is the vector with elements $V_i=v_0\cdot v_i$. As well known the form (1) is minimized by the vector
$$
a=-U^{-1}V.
$$
Substituting the value into expression (1) one obtains the squared distance to the subspace:
$$
r^2=v_0^2-V^TU^{-1}V.\tag2
$$

Title: distance point to affine subspace


问:
Elementary proof of the Fourier series of $f(x)=x$
Is there an elementary proof or an intuitive explanation of the following formula that can be understood if you know the definition of sin?

$$x = -2\sum_{n=1}^{\infty}\frac{(-1)^n}{n}\sin(nx)$$

答:
Let $ n\in\mathbb{N} $, and $ x\in\left[0,\pi\right) $, (Since $ \sin $ is odd, the result can be generalised for all $ x\in\left(-\pi,\pi\right) $, but for now let us work with positive $ x $s) we have the following : \begin{aligned} \sum_{k=1}^{n}{\frac{\left(-1\right)^{k}}{k}\sin{\left(kx\right)}}&=2\int_{0}^{\frac{x}{2}}{\sum_{k=1}^{n}{\left(-1\right)^{k}\cos{\left(2ky\right)}}\,\mathrm{d}y}\\ &=\int_{0}^{\frac{x}{2}}{\left(\left(-1\right)^{n}\frac{\cos{\left(2n+1\right)y}}{\cos{y}}-1\right)\,\mathrm{d}y}\\ \sum_{k=1}^{n}{\frac{\left(-1\right)^{k}}{k}\sin{\left(kx\right)}}&=-\frac{x}{2}+\left(-1\right)^{n}\int_{0}^{\frac{x}{2}}{\sec{y}\cos{\left(2n+1\right)y}\,\mathrm{d}y} \end{aligned}

Since $ \varphi = \sec $ is $ \mathcal{C}^{1} $ on $ \left[0,\frac{x}{2}\right] $, then $ \int_{0}^{\frac{x}{2}}{\varphi\left(y\right)\cos{\left(2n+1\right)y}\,\mathrm{d}y}\underset{n\to +\infty}{\longrightarrow}0 $, thus : $$ \sum_{n=1}^{+\infty}{\frac{\left(-1\right)^{n}}{n}\sin{\left(nx\right)}}=\lim_{n\to +\infty}{\sum_{k=1}^{n}{\frac{\left(-1\right)^{k}}{k}\sin{\left(kx\right)}}}=-\frac{x}{2} $$

Hence, for all $ x\in\left(-\pi,\pi\right),\ \sum\limits_{n=1}^{+\infty}{\frac{\left(-1\right)^{n}}{n}\sin{\left(nx\right)}}=-\frac{x}{2} $.


问:
commutative ring to boolean algebra
Let X be a set. We know that $(P(X),\triangle, \cap )$ is a commutative ring with the zero-element $ \emptyset $ and the one-element $X$. $P(X)$ is the power set, $\triangle$ the symmetrical difference (as addition) and $\cap$ the intersection (as multiplication).

Now we define scalar multiplication as: $\mathbb{F}_2 \times P(X) \rightarrow P(X)$

$0 \cdot A = \emptyset$

$1 \cdot A = A$
for every $A \in P(X)$

prove that because of the scaler multiplication, $(P(X),\triangle, \cap, \cdot )$ is an algebra over $\mathbb{F}_2$

Im pretty much lost on this one. I looked in the script and on the internet for clues on how to solve this, but Im pretty desperate, so Im posting this without any progress. I would appreciate if you could give me any hints on how to get started with this

答:
Follow the axioms of algebras:

You know that $(P(X),\triangle,\cap)$ is a commutative ring;

Show that for every $a,b\in\mathbb{F}_2$ and $A\in P(X)$,
\begin{align*}
(a+b)\cdot A&=a\cdot A+b\cdot A; \tag{1}\\
a\cdot(b\cdot A)&=(ab)\cdot A.\tag{2}
\end{align*}

Show that for every $a\in\mathbb{F}_2$ and $A,B\in P(X)$,
\begin{align*}
a\cdot(A\triangle B)&=(a\cdot A)\triangle(a\cdot B); \tag{3}\\
a\cdot(A\cap B)&=(a\cdot A)\cap B=A\cap(a\cdot B). \tag{4}
\end{align*}

Since there are only two elements in $\mathbb{F}_2$, you simply exhaust all possible cases.

Title: commutative ring to boolean algebra


问:
Hypothesis testing: testing the claim that the EV of one die is greater than the EV of another die
Greg and Fyodor are playing a game. To play the game they each bring their own die with numbers $1$ to $6$ on them. It is not known what the probability distributions are of either die. One round involves: each person rolling their die; whoever gets the highest number wins, and if they roll the same number then they roll again until someone wins.

They play a game of $200$ rounds and only keep track of the number of wins and losses, but not the numbers on the dice in each round.

Fyodor wins $87$ rounds and Greg wins the other $113.$

Angry, Fyodor calls BS and tells Greg to his face, "No way, you were cheating."

I'm not sure that the statement "you were cheating" corresponds to a single hypothesis test claim. However, there are two seemingly similar but different claims I would like to carry out on Fyodor's behalf.

The first claim is: "(at the 5% significance level) The EV of Greg's die is not equal to the EV of Fyodor's die". Now assuming Fyodor and Greg's EVs are equal, then this implies that the probability of Fyodor winning a round is exactly $\frac{1}{2}.$ Then let $X$ is the random variable, "number of rounds Fyodor wins out of $200$", then $X\sim B(200, \frac{1}{2}). P(X \leq 87) = 0.0384 < 0.05,\ $ so at the $5$% significance level, there is evidence to suggest that the EV of Fyodor's die is not equal to the EV of Greg's die.

Now my second claim is: "(at the 5% significance level) The EV of Greg's die is greater than the EV of Fyodor's die". Now I'm not sure how to calculate this. I think this is much more difficult, if not impossible without further information. Maybe with some further information we could do a double integral of all the possible EV values of Greg's die and all the possible EV values of Fyodor's die, although maybe this will have to be weighted in some way depending on how the dice are made and what the probability of different values of EV different dice can have. Is my thinking that we need more information to answer my second claim correct? Or am I overthinking it and it's just some sort of one-tailed hypothesis test?

I came up with this question because I was thinking about how we could test claims of whether or not someone was cheating in a game - or whether the house or a player is cheating in a casino - and ultimately I think what you conclude depends on what your hypothesis test is.

答:
No, you cannot perform the hypothesis test based on the expectations of each die, because "win" and "loss" are solely determined by which die rolled higher, not the extent to which one was higher.  For an extreme example, Greg's die could have the distribution $$\Pr[X = x] = \begin{cases} 1/6, & x = 1 \\ 0, & x \in \{2, 3, 4, 5\} \\ 5/6, & x = 6 \end{cases}$$ in which case the expected value is $31/6$, and Fyodor's die could have the distribution $$\Pr[Y = y] = \begin{cases}0, & x \in \{1, 2, 3, 4\}, \\ 5/6, & x = 5 \\ 1/6, & x = 6 \end{cases}$$ with the same expected value, but Greg wins more than half the time because with probability $(5/6)^2 = 25/36 > 1/2$, Greg rolls a $6$ and Fyodor rolls a $5$.

Instead, the correct parameter on which to test the hypothesis that Greg cheated is the proportion of times Greg's die beats Fyodor's die.  Fortunately, the relevant information captured in the sample is the number of outcomes in which one die beat the other--this is a sufficient statistic for the parameter.

Again to illustrate with the above example.  Both $X$ and $Y$ are categorical random variables; specifically $$X \sim \operatorname{Categorical}(\pi_{x1} = 1/6, \pi_{x2} = \pi_{x3} = \pi_{x4} = \pi_{x5} = 0, \pi_{x6} = 5/6), \\ Y \sim \operatorname{Categorical}(\pi_{y1} = \pi_{y2} = \pi_{y3} = \pi_{y4} = 0, \pi_{y5} = 5/6, \pi_{y6} = 1/6),$$ are are in a sense location-scale generalizations of Bernoulli variables because all but two of the parameters in each case equal $0$.  The number of times each variable equals one of the six outcomes is a multinomial random variable, which are vector-valued generalizations of a binomial random variable.  However, you would need to write a complicated function that relates the $\pi_{ij}$ to the proportion $p$ of outcomes where $X$ beats $Y$.  Again, this is not necessary because what ultimately matters is testing the hypothesis $$H_0 : p = 1/2 \quad \text{vs.} \quad H_1 : p \ne 1/2,$$ where the number of times $X$ beats $Y$ in $n$ outcomes (where an outcome may require multiple rolls to determine a winner), is a binomial random variable $B \sim \operatorname{Binomial}(n, p)$.  Therefore, under the null hypothesis, for a sufficiently large sample size $n$, the test statistic $$Z \mid H_0 = \frac{\hat p - 1/2}{\sqrt{1/2 (1-1/2)/n}}, \quad \hat p = \frac{B}{n}$$ is approximately standard normal.

To use this test for your example, we have $B = 113$ and $n = 200$.  Then $$Z \mid H_0 = \frac{\frac{113}{200} - \frac{1}{2}}{\sqrt{1/2(1 - 1/2)/200}} \approx 1.83848.$$  The $2$-sided $p$-value for this test is approximately $\Pr[|Z| > 1.83848] \approx 0.0659921$.  Note that this value is twice what you calculated because the test should be two-tailed, not one.  You tested a single-tailed hypothesis in which you would allow for Fyodor's die to win more frequently than Greg's, and this is of course just as unfair as the other way round.  So if we are to use a $5\%$ significance level, the allocation of overall Type I error $\alpha$ must be equal on each tail, meaning that the critical value for the test is $z^*_{\alpha/2} \approx 1.95996$ and we cannot reject $H_0$.


问:
Beginner help: need help on finding the Matrix A of the linear transformation
Find the matrix A of the linear transformation T from R2 to R2 that rotates any vector through an angle of 30∘ in the clockwise direction.

Heres what I did so far :
I plugged in 30 into the general matrix
\begin{bmatrix}\cos \theta &-\sin \theta \\\sin \theta &\cos \theta \\\end{bmatrix}
which turns into this:
\begin{bmatrix}\cos 30&-\sin 30\\\sin 30 &\cos 30 \\\end{bmatrix}
resulting in:

\begin{bmatrix}\sqrt{\frac{3}{2}}&-\frac{1}{2}\\ \frac{1}{2}&\frac{\sqrt{3}}{2}\end{bmatrix}

now, since a clockwise rotation is: \begin{bmatrix}0&1\\ -1&0\end{bmatrix}, I set up a matrix multiplication like this and multiplied the two matrices together which ends up with this:

\begin{bmatrix}\frac{1}{2}&\frac{\sqrt{3}}{2}\\ -\frac{\sqrt{3}}{2}&\frac{1}{2}\end{bmatrix}:

However I got it wrong, can anyone help?

答:
Hint.

You should not multiply the two matrices together. Your result is essentially firstly rotating counterclockwise by $\pi/6$, then clockwise by $\pi/2$; it ends up with rotating counterclockwise through the angle $\pi/6-\pi/2$.

Instead, note that rotating clockwise $\theta$ is the same as rotating counterclockwise $2\pi-\theta$.

Your "general matrix" is rotating counterclockwise by $\theta$.


问:
Showing $SL(2,\mathbb{C})$ double covers $SO(1,3)$
I have seen some proofs showing $SL(2,\mathbb{C})$ double covers $SO(1,3)$ that go like this:

An arbitrary hermitian $2 \times 2$ matrix $X$ can be written as $X=X^\mu\sigma_{\mu}$, where $\sigma_{\mu}=(I,\sigma_i)$, from which follows that $\text{det} X=(X^0)^2-(X^1)^2-(X^2)^2-(X^3)^2$.
We can define the action of $A\in SL(2,\mathbb{C})$ on $X$ via $X'=AXA^{\dagger}$, which leaves the determinant invariant and therefore can be identified with a $SO(1,3)$ transformation. Computing the kernel via $AXA^{\dagger}=X$ it follows by existence of the inverse that $AX=XA$ and by Schur's Lemma that $A=\lambda I$. Since $\text{det}A=1$ we deduce $A=\pm I$, thus obtaining the double cover.

My Question: Where is it used, that $A\in SL(2,\mathbb{C})$? I mean, the steps would still be correct if $A\in SU(2)$. The latter obviously doesn't make sense since there are only four and not six independent real components. But this should be used in the proof, right?

答:
Where is it used, that $A\in SL(2,\mathbb C)$?

In the last step, you assume $\det A =1$ which is true by definition iff $A \in SL(2,\mathbb C)$

the steps would still be correct if $A\in SU(2)$

Yes, they still are, and it makes perfect sense because $SU(2)\subset SL(2,\mathbb C)$, or in other words if $A\in SU(2)$ then $A \in SL(2,\mathbb C)$ and a fortiori the steps are still correct.


问:
Number of ways to get a full house in Poker
I'm trying to understand how to represent the number of ways to get a full house in poker without using the combinations method. I read that this is true:

$\frac{52\times3\times2\times48\times3}{3!2!}=3744$

I understand where the numerator comes from but I'm not sure why we divide by "$3!2!$". I'm assuming it's because we have 3 cards of the same value and 2 others with the same value? But I don't really understand why the division...

I am also questioning why we couldn't start by doing $52\times51\times...$ because we could really pick any card to start with and then pick any of the remaining 51 as a second card (either same value as the first or any other)? I guess the third number in the calculation would depend on if we picked two same values or two different values but I'm all a bit confused about this.

Thanks for your help!

答:
I guess the third number in the calculation would depend on if we picked two same values or two different values

With that approach, yes, that's something we would have to take into account. And even moreso with the fourth and fifth cards. It's a mess. Which is why that's not the approach used. Instead of picking one card, and then the next, and then the next, and keeping track of how many possible options would keep the possibility of a full house open, they build the full house out of one three-of-a-kind and one pair separately.

First we take the three-of-a-kind. How many ways can that be done? Well, the first card can be anything, so that's $52$ possibilities. The next two cards must have the same value, so this gives ${}\times3\times2$.

However, in a poker hand order doesn't matter. So picking first the ace of spades, then hearts then clubs is considered the exact same three-of-a-kind as ace of hearts, then clubs, then spades, and so on. All in all, our original count counts each distinct three-of-a-kind exactly $3!$ times. So the number of distinct three-of-a-kinds is $$\frac{52\times3\times2}{3!}$$

Next, we just do the pairs in exactly an analogous way to get $$\frac{48\times3}{2!}$$Finally, the number of ways to get a full house is the number of ways to get one three-of-a-kind and one pair, so we multiply the two together.


问:
Transforming region y-x>0 to the upper half plane through change of variables
I am dealing with the region $y-x>0$. I would like to transform this region by rotating it to end up with the upper half plane.

So far I have tried to create the new region by taking $\tilde{y}=y-x$. Then the transformed region would be $\tilde{y} >0$ which is what I want. However, I'm confused on how to deal with the $\tilde{x}$ in this new transformed space. All I know so far about this coordinate is that $\tilde{x}=y-x=0$ and that it is essentially just the original $x$ axis rotated by 45 degrees. I am looking for help explicitly defining $\tilde{x}$. If there is something obvious I am missing please let me know.
Thanks!

答:
To make computations simpler the point $(x,y)$ in the plane before transforming can be sent to the point $(u,v)=(y+x,y-x).$ This is in fact the result of rotating by $-\pi/4$ but then stretching by a factor of $\sqrt{2}.$

Then if originally $y-x>0$ then the altered second coordinate $v$ is greater than $0$ as desired. The fact that the new first coordinate is $y+x$ might make one think it must be positive, but if one finds the inverse of our map it is $(x,y)=((u-v)/2,(u+v)/2.)$ So for example the point $(x,y)=(-2,-1)$ maps to the point $(u,v)=(-3,1)$ showing a case where the new first coordinate is negative.

To explain how I got my $(u,v)$ : First I used complex numbers to do a rotation through $-\pi/4$ using the fact that angles add when complex numbers multiply, so that multiplying $x+i y$ by $e^{-i \pi/4}$ gives the complex number $(u,v)=(y+x)/\sqrt{2}+i(y-x)/\sqrt{2}.$ [to do this i wrote $e^{i (-\pi/4)}$ in the form $1/\sqrt{2}-i(1/\sqrt{2}).$]

Then thinking the squareroot of two made it complicated I just dropped it, hence the stretch by that factor.


问:
Function inverse notation
I've stumbled across this seemingly easy problem.
Prove that for every continuous bijective rising function, this is true:
$$(c\cdot f)^{-1}(x)=f^{-1}(\frac{x}{c})$$
where c $\in$ (0,$\infty)$.

My question is this - I know that this is true:
$$(c\cdot f)(x)=c\cdot f(x)$$
But I have no idea how this equation behaves when dealing with inverse functions. Suppose I have a rising invertible function like this:
$$f(x)=x$$
Let c=2.
What does this -> $(c\cdot f)^{-1}(x)$ <- return? Or rather, how do I read the notation? Do I first invert the function? (and get the same function?) and then multiply by two (getting y=2x) or do I multiply it by two (and make it 2x) and then invert (getting y=0.5x)?

Edit:
Another question of mine is: What does multiplying a function by a constant even mean? If I had a function f(x)=x+1, then (2*f)(x) is 2x+1 or 2x+2?

答:
Hint: try to prove this: if $f : \Bbb{R} \to \Bbb{R}$ is monotone increasing and continuous, then for any $c$, $f^{-1}(c)$ is well-defined and $f^{-1}(c) = \inf\{x \mid f(x) \ge c\}$.

As for the other question you added: the result of multiplying a function $f$ by a constant $c$ is the function $x \mapsto c\cdot f(x)$. It's the composition of $f$ with multiplication by $c$ - as in the correct statement in the second displayed equation in your question.

Title: Function inverse notation


问:
Sum of convex sets is convex (What have i done wrong?)
While studying convex analysis/optimization i encountered the following problem:

Problem:

Let $S_{1}$ and $S_{2}$ be convex sets in $R^{n}$. Then: $$
S_{1} + S_{2}=\left\{\mathbf{x}_{1}+\mathbf{x}_{2}: \mathbf{x}_{1} \in S_{1}, \mathbf{x}_{2} \in S_{2}\right\} \text { is convex. }
$$

Relevant Definitions:

A set $S$ in $R^{n}$ is convex if given $x_{1}$ and $x_{2}$ in S, then $\lambda x_{1}+(1-\lambda) x_{2},$ must also belong to $S$ for each $\lambda \in[0,1].$

My attempt(draft):

Let $s_{1}$ and $s_{2}$ in $S_{1}$ and $S_{2}$ respectively. By observing that $$s_{1} + s_{2} = \lambda s_{1} + \lambda s_{2} + s_{1} + s_{2} - \lambda s_{1} - \lambda s_{2} = $$

$$=\lambda(s_{1} + s_{2}) + (1 - \lambda)(s_{1} + s_{2})$$

We conclude that: $$\lambda(s_{1} + s_{2}) + (1 - \lambda)(s_{1} + s_{2}) \in S_{1} + S_{2}$$ since it equals $s_{1} + s_{2}$, which belongs to $S_{1} + S_{2}$

Questions:

I think the proof is wrong, since i have not used the fact that both $S_{1}$ and $S_{2}$ are convex sets. However, i have not been able to spot the mistake. Can someone help?

Thanks in advance, Lucas

Related:

The Minkowski sum of two convex sets is convex

答:
On the right track, but not quite there yet. With this definition of convexity, we need to first fix some arbitrary $s\in (S_1+S_2)$, $z\in(S_1+ S_2)$, and $\lambda\in[0,1]$.
Then, we must show that $$\lambda s+(1-\lambda)z \in S_1+S_2\tag{*}$$.

Using the definition of the Minkowski sum, we can say $s=s_1+s_2$, where $s_1\in S_1$ and $s_2\in S_2$. Likewise, we can say (without loss of generality) that $z=z_1+z_2$, where $z_1\in S_1$ and $z_2\in S_2$. Now, rephrasing (*), we need to show that

$$\lambda(s_1+s_2) + (1-\lambda)(\mathbf{z_1+z_2}) \in S_1+S_2.$$
However, the current form of your proof has shown that $\lambda(s_1+s_2)+(1-\lambda)(\mathbf{s_1+s_2})\in S_1+S_2$, so it is not quite right.

On the other hand, I say you are on the right track, because you have already found the trick that $s_1=\lambda s_1 + (1-\lambda )s_1$. This is a very common "trick" used in convex analysis, and I think it will help you find the right proof :-)


问:
Counterexample of Borsuk-Ulam theorem (Discontinuous Functions)
I'm looking to build a function $f:S^2 \to \mathbb R^2$ such that $f(x)\neq f(−x)$ for all $x\in S^2$.

By Borsuk-Ulam Theorem, this function must be discontinuous. I was trying to build a not too complicated function, but I always encountered a problem.

I appreciate any help.

Body:
In that case you could try with: $$(x_1,x_2,x_3)\in\mathbb{S}^1\longmapsto f(x_1,x_2,x_3):=\begin{cases}(x_1,x_2) &\text{ if } (x_1,x_2,x_3)\neq (0,0,1) \\ (2,2) &\text{ if } (x_1,x_2,x_3)=(0,0,1) \end{cases}$$

Then obviously $f(x_1,x_2,x_3)=-f(-(x_1,x_2,x_3))$ for all $(x_1,x_2,x_3)\in\mathbb{S}^1\setminus\{(0,0,1),(0,0,-1)\}$. Also, $f(0,0,1)=(2,2)\neq(0,0)=f(0,0,-1)$.


问:
Convex functions on real vector spaces
So I'm trying to solve the following problem,

Suppose that $f$ is a non-zero convex real-valued function on a real vector space $V$ with $f(0) = 0$

Show that there is a linear functional $g$ on $V$ such that $g(x) \leq f(x)$ $\forall x \in V$

Help would be much appreciated.

答:
The statement of the problem should remind you of the Hahn-Banach theorem. Of course, the given functional $f$ does not necessarily have the homogeneity that the theorem requires. Let's build it it by letting
$$F(x)=\inf_{t\ge 0} \frac{f(tx)}{t}$$
You should check that the infimum is finite (using the convexity of $f$), and that $F$ satisfies the subadditivity assumption. Then apply the Hahn-Banach theorem. (The subspace on which $g$ is defined initially can be as small as $\{0\}$.)</p>

Title: Convex functions on real vector spaces


问:
Solve for 2D translation, rotation and scale given two touch point movements
For a phone app I need to let users translate, rotate and scale a rectangle on the 2D plane using "pinch" gesture.

Suppose the rectangle already has TRS = $t, \theta, s $; and the user has their fingers on two touch points $p_1, p_2$.  The user then moves the touch points to  $q_1, q_2$. What is the new TRS that will map $p_1 \rightarrow q_1, p_2 \rightarrow q_2$.  In other words, the user should feel that their fingers are "stuck" to the rectangle. The scale is always the same for $x$ and $y$.

The scale is easy. Let $p=p_1 - p_2$ and  $q=q_1 - q_2$, then  $s' = s \cdot  \dfrac{||q||}{||p||}  $

I think rotation is can use the arcSine of the cross product. Let $q_\bot = (-q_y, q_x)$ and
$\Delta\theta = arcSine \dfrac{q_\bot\cdot p}{||q||\cdot||p||}$, then $\theta' = \theta + \Delta\theta$

I think the translation should preserve the midpoint. So: $t' = t +  \frac{1}{2}((q_1 - p_1)+(q_2 - p_2))$.

But when I implement this, it doesn't work very well. The rotation is not around the correct point so the rectangle seems to slide away strangely.  Any advice please?

答:
For those who are interested in a less rigorous, but more practical answer, here is the source code that I used with the android.graphics.Canvas.

First I made a class called Transform as follows (Vec2 is just two floats)

```<code>public class Transform
{
    Vec2 translation;
    Vec2 center;
    float rotation;
    float scale;

    Matrix getMatrix()
    {
        Matrix m = new Matrix();
        m.setTranslate(center.x, center.y);
        m.preRotate(degrees(rotation));
        m.preScale(scale, scale);
        m.preTranslate(translation.x - center.x, translation.y - center.y);
        return m;
    }
}
</code>```

Then I made an OnTouchListener that captures two vectors, p and q at the start and end of the pinch gesture.

The method OnTouchListener.getTransform returns a Transform with translation (the green vector), center (the red vector), rotation (the angle from p to q), scale (length of q over p). Both vectors are in device coordinates (blue).

In the MainView.onDraw(Canvas) method I apply the transform as follows:

```<code>    transform = touchListener.getTransform();
    canvas.save();
    canvas.translate(transform.center.x, transform.center.y);
    canvas.rotate(degrees(transform.rotation));
    canvas.scale(transform.scale, transform.scale);
    canvas.translate(transform.translation.x - transform.center.x,
                     transform.translation.y - transform.center.y);
    mainWorld.onDraw(canvas);
    canvas.restore();
</code>```

If I want, I can instead use the matrix as follows,

```<code>    transform = touchListener.getTransform();
    currentMatrix = transform.getMatrix();
    canvas.save();
    canvas.setMatrix(currentMatrix);
    mainWorld.onDraw(canvas);
    canvas.restore();
</code>```

During the gesture, I may want to keep the current matrix separate from the previous matrix. In that case I would apply both of them as follows,

```<code>    canvas.save();
    canvas.setMatrix(currentMatrix);
    canvas.concat(previousMatrix);
    mainWorld.onDraw(canvas);
    canvas.restore();
</code>```

At the end of the gesture, I merge the current into the previous matrix,

```<code>    previousMatrix.postConcat(currentMatrix);
</code>```

Here are some utilities to extract the transform from a matrix.

```<code>public static float getAngleFromMatrix(Matrix matrix)
{
    float[] m = new float[9];
    matrix.getValues(m);
    float c = m[0] + m[4];
    float s = m[3] - m[1];
    return MathUtils.atan2(s,c);
}

public static float getScaleFromMatrix(Matrix matrix)
{
    float[] m = new float[9];
    matrix.getValues(m);
    return 0.5f * (MathUtils.sqrt(m[0]*m[0] + m[1]*m[1]) + MathUtils.sqrt(m[3]*m[3] + m[4]*m[4]));
}

public static Vec2 getTranslationFromMatrix(Matrix matrix)
{
    float[] m = new float[9];
    matrix.getValues(m);
    return new Vec2(m[2], m[5]);
}
</code>```

Body:
For those who are interested in a less rigorous, but more practical answer, here is the source code that I used with the android.graphics.Canvas.

First I made a class called Transform as follows (Vec2 is just two floats)

public class Transform
{
    Vec2 translation;
    Vec2 center;
    float rotation;
    float scale;

    Matrix getMatrix()
    {
        Matrix m = new Matrix();
        m.setTranslate(center.x, center.y);
        m.preRotate(degrees(rotation));
        m.preScale(scale, scale);
        m.preTranslate(translation.x - center.x, translation.y - center.y);
        return m;
    }
}

Then I made an OnTouchListener that captures two vectors, p and q at the start and end of the pinch gesture.

The method OnTouchListener.getTransform returns a Transform with translation (the green vector), center (the red vector), rotation (the angle from p to q), scale (length of q over p). Both vectors are in device coordinates (blue).

In the MainView.onDraw(Canvas) method I apply the transform as follows:

    transform = touchListener.getTransform();
    canvas.save();
    canvas.translate(transform.center.x, transform.center.y);
    canvas.rotate(degrees(transform.rotation));
    canvas.scale(transform.scale, transform.scale);
    canvas.translate(transform.translation.x - transform.center.x,
                     transform.translation.y - transform.center.y);
    mainWorld.onDraw(canvas);
    canvas.restore();

If I want, I can instead use the matrix as follows,

    transform = touchListener.getTransform();
    currentMatrix = transform.getMatrix();
    canvas.save();
    canvas.setMatrix(currentMatrix);
    mainWorld.onDraw(canvas);
    canvas.restore();

During the gesture, I may want to keep the current matrix separate from the previous matrix. In that case I would apply both of them as follows,

    canvas.save();
    canvas.setMatrix(currentMatrix);
    canvas.concat(previousMatrix);
    mainWorld.onDraw(canvas);
    canvas.restore();

At the end of the gesture, I merge the current into the previous matrix,

    previousMatrix.postConcat(currentMatrix);

Here are some utilities to extract the transform from a matrix.

public static float getAngleFromMatrix(Matrix matrix)
{
    float[] m = new float[9];
    matrix.getValues(m);
    float c = m[0] + m[4];
    float s = m[3] - m[1];
    return MathUtils.atan2(s,c);
}

public static float getScaleFromMatrix(Matrix matrix)
{
    float[] m = new float[9];
    matrix.getValues(m);
    return 0.5f * (MathUtils.sqrt(m[0]*m[0] + m[1]*m[1]) + MathUtils.sqrt(m[3]*m[3] + m[4]*m[4]));
}

public static Vec2 getTranslationFromMatrix(Matrix matrix)
{
    float[] m = new float[9];
    matrix.getValues(m);
    return new Vec2(m[2], m[5]);
}


问:
Row-wise derivative of a vector with respect to a matrix
Consider a column $n\times 1$ vector $\overline
{z}$ and an $n\times m$ matrix $W$. What would one call and denote an $n\times m$ matrix of derivatives defined by $M_{ij}=\frac{\partial z_i}{\partial W_{ij}}$?

To provide some context, this matrix appears when deriving the matrix form of backpropagation updates for neural networks, whereby $\overline
{z}$ is the vector of inputs to a particular layer (which are linear combinations of actions received from the previous layer) and a particular training instance, and $W$ is the matrix of weights at that layer.

答:
Suppose z is nx1 and W is nxm. The derivative of z wrt W is given by a three-D array with $$F_{ijk}=\frac{dz_i}{dW_{jk}}$$

For example the derivative of z1 wrt W is given by the matrix

$$F_{1jk}=\begin{pmatrix}[\frac{dz_1}{dW_{11}}&...&\frac{dz_1}{dW_{1m}}]\\...\\\frac{dz_1}{dW_{n1}}&...&\frac{dz_1}{dW_{nm}}\end{pmatrix}$$

and you are only taking the first row. There are n total of these $F_{ijk}$'s for i from 1 to n, and in each, you take the ith row, giving you your matrix that is "derivative of z with respect to the corresponding row of W." If $F_{ijk}$ is the derivative of z wrt W, you can represent your matrix by

$$G_{ik}=F_{iik}$$

There may be reasons why you want to ignore the derivatives of z wrt rows other than the row in W that is the current index of z, e.g. they could all be 0's. Here is an example, suppose that z=Wx with x an mx1 vector:

$\underbrace{z}_{\begin{pmatrix}z_1\\...\\z_n\end{pmatrix}}=\underbrace{W}_{\begin{pmatrix}W_{11}&...&W_{1m}\\...\\W_{n1}&...&W_{nm}\end{pmatrix}}\underbrace{x}_{\begin{pmatrix}x_1\\...\\x_m\end{pmatrix}}$ Notice that $z_i=\sum_{j=1}^m W_{ij}xj$ for i=1,...,n. Therefore the derivative of $z_i$ wrt $W_{jk}$ is 0 for $j\ne i$. Take an example: $z_3=\sum_{j=1}^m W_{3j}x_j$. We have $\frac{dz_3}{dW_{41}}=0$. Anyway the derivative of z3 wrt W would look like $$\begin{pmatrix}0&0&...&0\\0&0&...&0\\ [x_1&x_2&...&x_m]\\0&0&...&0\\...\\0&0&...&0\end{pmatrix}$$

that is, $F_{33k}=x_k$ but $F_{3jk}=0$ for $j\ne 3$. In this case, again you can represent the otherwise 3-D array as a 2-D matrix without loss of information with

$$G_{ik}=F_{iik}$$

and in this particular case

$$G_{ik}=x_{k}$$

that is,

$$G=\begin{pmatrix}x_1&x_2&...&x_m\\x_1&x_2&...&x_m\\...\\x_1&x_2&...&x_m\end{pmatrix}$$

capturing all the information that the derivative wrt W would have had. Maybe the fact that you mentioned "linear combinations" means that something like this, but not as simple as just z=Wx, is happening with your matrix derivatives.


问:
How to solve the Richard differential equation? (analytical solution)
I would like to solve the Richard differential equation, i.e. getting the the generalised logistic function. I tried to calculate it,

$$
\frac{dy}{dt} = \beta y \biggl( 1 - \biggl( \frac{y}{L} \biggr)^a \biggr)
$$

getting:

$$
\beta (t - t_0) = \int \frac{dy}{y\big(1-\big(\frac{y}{L}\big)^a\big)}
$$

but I am stuck at that integral. Any idea how to solve it? Thanks!

答:
Hint.

$$
\frac{dy}{y\left(1-\left(\frac yL\right)^a\right)} = \frac{dy}{y}+\frac{\left(\frac{y}{L}\right)^{a-1}dy}{L \left(1-\left(\frac{y}{L}\right)^a\right)}
$$


问:
Uniform convergence of difference quotients to the derivative
I remember being assigned the following homework problem a few years back.

Let $f:[0,1] \to \mathbb{R}$ be continuously differentiable. Prove that, for every $\epsilon > 0$, there exists $\delta > 0$ such that $0 < |h| < \delta$ implies $\left| \frac{f(x+h) - f(x)}{h} - f'(x) \right| < \epsilon$ for all appropriate $x$.

I also remember how I solved it.

Fix $\epsilon > 0$. Since $f'$ is a continuous function on a compact interval, it is uniformly continuous and we can find a $\delta > 0$ such that $|x-y| < \delta$ implies $|f'(x) - f'(y)| < \epsilon$ for $x ,y \in [0,1]$. Suppose $0 < |h| < \delta$ and that $x$ is such that $x,x+h \in [0,1]$. By the Mean Value Theorem, there is an $a$ between $x$ and $x+h$ such that $f'(a) = \frac{f(x+h) - f(x)}{h}$. Note $|x - a| < \delta$ clearly holds. So,
  $\left|\frac{f(x+h) - f(x)}{h} - f'(x) \right| = |f'(a) - f'(x)| < \epsilon$ and we are finished.

What had me baffled was that this: we had not covered the MVT at the time the problem was assigned! This suggests there should be a way to prove it without using the MVT. Can anybody think of a way? I don't think I ever did. Thanks.

答:
Some activity on the post reminded me of this 8 year old question. I guess one can add in that the desired statement follows pretty easily from the fundamental theorem of calculus. Choose $\epsilon>0$. Since $f'$ is uniformly continuous, you can choose $\delta>0$ such that $x \in [0,1]$, $|t|<\delta$ implies $|f'(x)-f'(x+t)|<\epsilon$. Then, if $x \in [0,1]$ and $0<|h|<\delta$ we get
\begin{align*}
\left|\frac{f(x+h)-f(x)}{h}-f'(x)\right| &= \left|\frac{1}{h} \int_0^h (f'(x+t) - f'(x)) \ dt \right| \\
 &\leq \frac{1}{|h|} \int_0^h |f'(x+t) - f'(x)| \ dt \\
&\leq \epsilon.
\end{align*}
This gives another argument, but isn't really a great answer to the question since I'm pretty sure the fundamental theorem of calculus would not have been covered yet either.


问:
How do you respond to "I was always bad at math"?
Here in the U.S., it is my experience that over 75% of adults I meet socially will volunteer that phrase or a variation upon learning that I am a mathematician.  I find this frustrating, since almost nobody would  brag about being bad at history or English or really any other subject.   Normally I change the subject, or perhaps say they must have had a bad classroom experience, but that feels unsatisfying and turns the conversation in an ugly direction.

Surely some of the bright minds here on Math.SE have found a good response. Note that I'm not looking to  alienate a new acquaintance, so let's keep it positive.

答:
Finding some practical application for math can get people quite a lot more interested; helping them to feel like they have a mastery of the numbers; and thus of the world around them.

That most likely sounded like a paragraph of BS though, so what I'm really trying to advertise is the LOGO Programming Language; the story of Seymour Papert's Lisp-like language for small children is filled with numerous instances of kids who were "never good at math" finding that they had really just been keeping away from it due to adverse learning experiences. Here's the book that I did my final term paper on. Here you have kids below 3rd grade, learning systems of geometry, degrees, and even programming idioms like subroutines, simply through the ability to experiment with them.

Applying those kind of ideas universally in a school system would be a huge undertaking, but it could apply very well in a private learning environment. Also: LOGO is old as disco, but the basic principles mentioned in the book are available in the 'turtle' library of Python.


问:
What is wrong with my PDF?
The question is suppose that in a certain year, an alien attack will happen at a uniformly random time on July 4th. Let X be a continuous random variable representing the time of the attack in hours after midnight.

For 0 < x < 24, what's the value of the PDF, f(x)?

I started by doing

```<code>x=0    .1
x=1    .1
x=2    .1
</code>```

all the way to 24 (because there are 24 hours in a day)

I have realized this is most likely incorrect and would like some help starting.

The second question is what's the probability the aliens attack before 6 am?

I thought of it like this

```<code>12am - 6 am - the time they can attack
6:01am - 11:59 pm - time they cannot attack

P(cannot attack/can attack) = 6/16 = 37.5% chance
</code>```

Please let me know if I am correct, thank you in advance!

答:
X is continuous, not discrete, so it's not right to assign P(x=0)=.1
(in any case, it would make more sense to assign 1/24 to this
probability, if it were discrete). Instead, the pdf must integrate to
1 from 0 to 24. $\int_0^{24}\frac 1 {24}dx=1$, so the pdf is
$f_X(X)=\begin{cases}\frac 1 {24}&0\le x\le
   24\\0&\text{otherwise}\end{cases}$. The probability that an attack
happens between 12 am and 6 am is 6/24, because it's uniform. In
math: $\int_0^6 f_X(x)dx=\int_0^6\frac 1 {24}dx=\frac 6 {24}$

Your calculation is called an odds ratio of an attack, 6/18. You
want the probability of an alien attack.

Title: What is wrong with my PDF?


问:
SVD and best rank-$k$ approximation
I do not understand several parts of the proof in this answer: Proof of Eckart-Young-Mirsky theorem.

How does the statement "we have that there exists an $x \in \mathcal{N}(B) \cap \mathcal{R}(V_{k+1}), \left\lVert x\right\rVert_{2} = 1$" follow from what has come before? The prior statements about the dimensions of $\mathcal{N}(B)$ and $\mathcal{R}(V_{k+1})$ do not seem to clearly indicate anything about their intersection.

How do the equalities "$\left\lVert Ax\right\rVert_{2}^{2} = \sum_{i=1}^{k+1}\sigma_{i}^{2}\left\lvert v_{i}^{*}x\right\rvert^2$" and "$\sigma_{k+1}^{2}\sum_{i=1}^{k+1}\left\lvert v_{i}^{*}x\right\rvert^2 = \sigma_{k+1}^{2}$" follow from what has come before? What is $v_{i}^{*}$ and how does it become involved? And what are these sums? Why is the latter sum apparently equal to $1$?

It says "from $\left\lVert A−A_k\right\rVert^2=\sigma_{k+1}$" - how is that result proved?

Thanks very much for assistance.

答:
In general for two subspaces $U,W$ we have $\dim(U+W) = \dim(U) + \dim(W) - \dim(U \cap W)$. $N(B)$ and $R(V_{k+1})$ are subspaces of $\mathbb{R}^n$ whose dimensions sum to $n+1$, so $$\dim(\mathbb{R}^n) \ge \dim(N(B) + R(V_{k+1}))  = \dim(N(B)) + \dim(R(V_{k+1}) - \dim(N(B) \cap R(V_{k+1})$$
implies $\dim(N(B) \cap R(V_{k+1})) \ge 1$.

The answerer is using the asterisk $*$ to denote conjugate transpose. If you are working only with real numbers, you can just think of it as the transpose $\top$.

It may be more helpful to just write out the SVD of $A$.

$$\|A^\top x\|_2^2 = x^\top A^\top A x = x^\top V \Sigma^\top U^\top U \Sigma V^\top x
= x^\top V\Sigma^\top \Sigma V^\top x.$$

$V^\top x$ is a vector whose entries are $v_i^\top x$ for $i=1,\ldots,n$. Note further that because $x \in R(V_{k+1})$, it must be orthogonal to $v_i$ when $i > k+1$, due to orthogonality of $v_1,\ldots, v_n$. So the entries of $V^\top x$ are $v_1^\top x, v_2^\top x, \ldots, v_{k+1}^\top x, 0, \ldots, 0$.

$\Sigma^\top \Sigma$ is a $n \times n$ diagonal matrix with diagonal entries $\sigma_1^2, \sigma_2^2, \ldots$. Thinking about the matrix multiplication $(V^\top x)^\top (\Sigma^\top \Sigma) (V^\top x)$, you will see that this quantity can be written as $\sum_{i=1}^n \sigma_i^2 (v_i^\top x)^2$. Since the addend is zero for $i > k+1$, this equals $\sum_{i=1}^{k+1} \sigma_i^2 (v_i^\top x)^2$.

$\sum_{i=1}^{k+1} (v_i^\top x)^2$ equals $\sum_{i=1}^n (v_i^\top x)^2$ which can be written as $x^\top V V^\top x = x^\top x = \|x\|_2^2=1$.

By definition, $A-A_k = \sum_{i=k+1}^n \sigma_i u_iv_i^\top$, i.e. $A-A_k = U\tilde{\Sigma} V^\top$ where $\tilde{\Sigma}$ is obtained by changing the first $k$ singular values in $\Sigma$ to zero. Recalling that the operator norm $\|M\|_2$ is the largest singular value of $M$, we can simply note that the largest singular value of $A-A_k$ is $\sigma_{k+1}$ to conclude $\|A-A_k\|_2 = \sigma_{k+1}$.

Title: SVD and best rank-$k$ approximation


问:
Is stratified sampling useful for volume estimation via Monte Carlo integration?
In the Wikipedia article on Monte Carlo integration, they give an example of stratified sampling for integrating the function

$$
f(x,y) = \begin{cases} 1 \;,\; x^2+y^2 < 1 \\ 0 \;,\; x^2+y^2 \geq 1\end{cases}
$$

over the unit square $x,y \in [-1, 1]$. This integral basically represents the area of the unit circle.

So I was wondering whether stratified sampling is even useful for such volume estimations, also in higher dimensions. The standard error for the Monte Carlo integral of binary functions (i.e. either $1$ or $0$), which represents the volume of the region where $f \equiv 1$, can be expressed in the following way:

$$
\begin{aligned}
\sigma_N^2 &= \frac{1}{N-1}\sum_{i=1}^{N}\left[f_i - \langle f\rangle \right]^2 \\
         &= \frac{1}{N-1}\left[\sum_i f_i^2 - 2N\langle f\rangle^2 + N\langle f\rangle^2 \right] \\
         &= \frac{1}{N-1}\left[\sum_i f_i^2 - N\langle f\rangle^2\right] \\
         &= \frac{N}{N-1}\left[\langle f\rangle - \langle f\rangle^2\right] \\
\Rightarrow \mathrm{standard\,error\,of\,}\langle f\rangle &= \frac{\sigma_N}{\sqrt{N}} = \sqrt{\frac{\langle f\rangle - \langle f\rangle^2}{N-1}}
\end{aligned}
$$

where $f_i$ is the $i$-th Monte Carlo sample and $\sum_i f_i = N\langle f\rangle$ and $f_i^2 = f_i$ has been used.

The function $\langle f\rangle - \langle f\rangle^2$ behaves in the following way, so the maximum error is obtained for $\langle f\rangle = \frac{1}{2}$:

The error relative to the actual estimate, i.e.

$$
\frac{\mathrm{standard\,error}}{\langle f\rangle} = \sqrt{\frac{\frac{1}{\langle f\rangle} - 1}{N-1}}
$$

is largest for $\langle f\rangle \ll 1$.

How does stratified sampling help in this case to reduce the standard error of the volume estimate?

答:
As can be seen from the formula

$$
\frac{\mathrm{standard\ error}}{\langle f\rangle} = \sqrt{\frac{\frac{1}{\langle f\rangle}-1}{N-1}}
$$

the error relative to the estimate $\langle f\rangle$ increases for smaller $\langle f\rangle$. This is where stratified sampling helps. It samples on a subspace (stratum) that is effectively much smaller and hence manages to achieve much larger values of $\langle f\rangle$. Note that the actual estimate of the integral remains the same because in fact $\langle f\rangle$ needs to be multiplied by $V$, the sampled volume. Without stratified sampling, $V$ is the entire domain and hence $\langle f\rangle$ might be very small. For stratified sampling, however, only relevant regions of the domain are sampled and hence the effective $V$ is much smaller while one obtains a proportionally increased $\langle f\rangle$ with the same number of samples $N$. This decreases the error estimate while the estimate of the integral, the product $V\langle f\rangle$, remains similar.


问:
Prove $\int_0^\infty\frac{\ln x}{x^3-1}\mathrm{d}x=\frac{4\pi^2}{27}$
Proof of the integral
$$\int_0^\infty\frac{\ln x}{x^3-1}\mathrm{d}x=\frac{4\pi^2}{27}$$
I try to substitute $u = \ln x$. Then $x = e^u,\>\mathrm{d}x = e^u\mathrm{d}u$ and the limits $(0,\infty)\to (-\infty,\infty)$.
The integral becomes $$\int_{-\infty}^\infty \frac{ue^u}{e^{3u}-1}\mathrm{d}u.$$

答:
Let $\displaystyle I = \int_0^\infty\frac{\ln x}{x^3-1}\mathrm{d}x= \int_0^1\frac{\ln x}{x^3-1}\mathrm{d}x + \int_1^\infty\frac{\ln x}{x^3-1}\mathrm{d}x.$

Let $\displaystyle x \mapsto \frac{1}{x}$ in the last integral then:

$\displaystyle I =  \int_0^1\frac{\ln x}{x^3-1}\mathrm{d}x - \int_0^1\frac{\ln \frac{1}{x}}{1/x^3-1} \cdot \frac{1}{x^2}\mathrm{d}x =\int_0^1\frac{\ln x}{x^3-1}\mathrm{d}x - \int_0^1\frac{\ln x}{\frac{1}{x}-x^2} \mathrm{d}x$

$\displaystyle I  =\int_0^1\frac{\ln x}{x^3-1}\mathrm{d}x - \int_0^1\frac{\ln x}{\frac{1}{x}-x^2} \,\mathrm{d}x = \int_0^1\frac{(x+1)\ln x}{x^3-1}\,\mathrm{d}x$.

Consider the geometric series expansion:

$\displaystyle \frac{(x+1)\ln{x}}{x^3-1} = (x+1) \ln{x} \sum_{k \ge 0} x^{3k} = \sum_{k \ge 0} x^{3k+1}\ln{x}+\sum_{k \ge 0} x^{3k}\ln{x}$

Since $x \in (0, 1)$ we can write  $I = \displaystyle \sum_{k \ge 0}  \int_0^1 x^{3k+1}\ln{x}\,\mathrm{d}x+\sum_{k \ge 0} \int_0^1 x^{3k}\ln{x}\,\mathrm{d}x$

Consider $\displaystyle f(m) = \int_0^1 x^m \,{dx} = \frac{1}{1+m}.$ Then $\displaystyle f^{(n)}(m) = \int_0^1 x^m \ln^{n}{x} \,{dx} = \frac{(-1)^n n! }{(1+m)^{n+1}}.$

Applying this result with $n=1, ~m=3k, ~m=3k+1$ we have

$\displaystyle I = \sum_{k \ge 0} \frac{1}{(2 + 3 k)^2}+\sum_{k \ge 0}  \frac{1}{(1 + 3 k)^2} := S_1 + S_2 $; separating odd/even terms:

$$\displaystyle S_1 = \sum_{k \ge 0} \frac{1}{(2 + 3 k)^2}= \sum_{k \ge 0} \frac{1}{(2 + 6 k)^2}+\sum_{k \ge 0}  \frac{1}{(5 + 6 k)^2} \\ $$

$$\displaystyle S_2 = \sum_{k \ge 0} \frac{1}{(1 + 3 k)^2}= \sum_{k \ge 0} \frac{1}{(1+6k)^2}+\sum_{k \ge 0}  \frac{1}{(4 + 6 k)^2} \\ $$

Therefore $\displaystyle I =\sum_{k \ge 0} \frac{1}{(2+ 6 k)^2}+\sum_{k \ge 0}  \frac{1}{(5 + 6 k)^2}+\sum_{k \ge 0} \frac{1}{(1 + 6 k)^2}+\sum_{k \ge 0}  \frac{1}{(4 + 6 k)^2}$

Let $\displaystyle \mu(m) = \sum_{k \ge 0} \frac{1}{(m+6k)^2}.$ Then $\displaystyle \zeta(2) =  \sum_{k \ge 0} \frac{1}{(1+k)^2} $ can be rewritten as $\displaystyle \sum_{1 \le m\le 6}\mu(m)$.

But we seek this sum, with terms for $m=3,6$ removed, which tells us that

$$\begin{aligned} \displaystyle I & = \sum_{k \ge 0}\frac{1}{(k+1)^2}-\sum_{k \ge 0}\frac{1}{(6k+3)^2} -\sum_{k \ge 0}\frac{1}{(6k+6)^2} \\& = \left(1-\frac{1}{36}\right)\sum_{k \ge 0}\frac{1}{(k+1)^2}-\frac{1}{9}\sum_{k \ge 0}\frac{1}{(2k+1)^2}  \end{aligned}$$

But $\displaystyle \sum_{k \ge 0} \frac{1}{(2k+1)^2} = \sum_{k \ge 0} \frac{1}{(k+1)^2}- \sum_{k \ge 0} \frac{1}{(2k+2)} =  \sum_{k \ge 0} \frac{1}{(k+1)^2}- \frac{1}{4}\sum_{k \ge 0} \frac{1}{(k+1)^2}$

Putting this altogether $\displaystyle I = \left(1-\frac{1}{36}\right)\zeta(2)-\frac{1}{9}\cdot \left(\zeta(2)-\frac{1}{4} \zeta(2)\right) = \frac{8}{9} \zeta(2).$

Therefore $$I = \frac{4\pi^2}{27}.$$


问:
If $K\subset \mathbb{R}^n$ compact and $U\subset \mathbb{R}^n$ open, $K \subset U$.Prove that $U \cap \left(\mathbb{R}^n -K \right) \neq \emptyset$

Let $K\subset \mathbb{R}^n$ be compact subspace and let $\ U\subset \mathbb{R}^n\ $ be open, non-empty and containing $\ K.\ $ Prove that $\ U \cap \left(\mathbb{R}^n -K \right) \neq \emptyset$

Attempt

The first idea that comes to my mind was start to compare $U$ with $\left(\mathbb{R}^n -K \right)$ and see if is possible that the sets have a intersecton.

Let $U$ open notice that $\mathbb{R}^n-U \subset \mathbb{R}^n-K$ since $U$ is open
then $\mathbb{R}^n-U$ is closed. Now since $K \subset U$ then $U-K \neq \emptyset $ and
in fact $U-K \subset \mathbb{R}^n-K$.From here I affirm that $U\cap  \mathbb{R}^n-K$. The problem is that   I never use that $K$ is compact.
Someone can give me a hint or advice at the moment of prove future propositions that involve Complements.

答:
How do you know that $U-K$ is not empty? That is where compactness of $K$ and conncetedness of $\mathbb R^{n}$ come in.

Here is a complete argument:

If $U \cap (\mathbb R^{n}-K)$ is the empty set than $U \subseteq K$. But it is given that $K \subseteq U$ so we get $U=K$. But $\mathbb R^{n}$ is connected, so the only open and closed sets are the empty set and $\mathbb R^{n}$. Since $U$ is given to be non-empty we get $K=U=\mathbb R^{n}$. But this contradicts the fact that $\mathbb R^{n}$ is not compact.


问:
How can I prove this closed form for $\sum_{n=1}^\infty\frac{(4n)!}{\Gamma\left(\frac23+n\right)\,\Gamma\left(\frac43+n\right)\,n!^2\,(-256)^n}$
How can I prove the following conjectured identity?
$$\mathcal{S}=\sum_{n=1}^\infty\frac{(4\,n)!}{\Gamma\left(\frac23+n\right)\,\Gamma\left(\frac43+n\right)\,n!^2\,(-256)^n}\stackrel?=\frac{\sqrt3}{2\,\pi}\left(2\sqrt{\frac8{\sqrt\alpha}-\alpha}-2\sqrt\alpha-3\right),$$
where
$$\alpha=2\sqrt[3]{1+\sqrt2}-\frac2{\sqrt[3]{1+\sqrt2}}.$$
The conjecture is equivalent to saying that $\pi\,\mathcal{S}$ is the root of the polynomial
$$256 x^8-6912 x^6-814752 x^4-13364784 x^2+531441,$$
belonging to the interval $-1<x<0$.

The summand came as a solution to the recurrence relation
$$\begin{cases}a(1)=-\frac{81\sqrt3}{512\,\pi}\\\\a(n+1)=-\frac{9\,(2n+1)(4n+1)(4 n+3)}{32\,(n+1)(3n+2)(3n+4)}a(n)\end{cases}.$$
The conjectured closed form was found using computer based on results of numerical summation. The approximate numeric result is $\mathcal{S}=-0.06339748327393640606333225108136874...$ (click to see 1000 digits).

答:
According to Mathematica, the sum is
$$ \frac{3}{\Gamma(\frac13)\Gamma(\frac23)}\left( -1 + {}_3F_2\left(\frac14,\frac12,\frac34; \frac23,\frac43; -1\right) \right). $$

This form is actually quite straightforward if you write out $(4n)!$ as
$$ 4^{4n}n!(1/4)_n (1/2)_n (3/4)_n $$
using rising powers ("Pochhammer symbols") and then use the definition of a hypergeometric function.

The hypergeometric function there can be handled with equation 25 here: http://mathworld.wolfram.com/HypergeometricFunction.html:
$$ {}_3F_2\left(\frac14,\frac12,\frac34; \frac23,\frac43; y\right)=\frac{1}{1-x^k},$$
where $k=3$, $0\leq x\leq (1+k)^{-1/k}$ and
$$ y = \left(\frac{x(1-x^k)}{f_k}\right)^k, \qquad f_k = \frac{k}{(1+k)^{(1+1/k)}}. $$

Now setting $y=-1$, we get the polynomial equation in $x$
$$ \frac{256}{27} x^3 \left(1-x^3\right)^3 = -1,$$
which has two real roots, neither of them in the necessary interval $[0,(1+k)^{-1/k}=4^{-1/3}]$, since one is $-0.43\ldots$ and the other $1.124\ldots$. However, one of those roots, $x_1=-0.436250\ldots$ just happens to give the (numerically at least) right answer, so never mind that.

Also, note that
$$ \Gamma(1/3)\Gamma(2/3) = \frac{2\pi}{\sqrt{3}}. $$

The polynomial equation above is in terms of $x^3$, so we can simplify that too a little,
so the answer is that the sum equals
$$ \frac{3^{3/2}}{2\pi} \left(-1+(1-z_1)^{-1}\right), $$
where $z_1$ is a root of the polynomial equation
$$ 256z(1-z)^3+27=0, \qquad z_1=-0.0830249175076244\ldots $$
(The other real root is $\approx 1.42$.)

How did you find the conjectured closed form?


问:
$\sup_n |X_n|^p$ in $L^1$ implies convergence
Say $X_n$ is a martingale. By the martingale convergence theorem we know that if $\sup_n E[|X_n|^p] \lt \infty$, $X_n$ converges P-a.s. to some $X_{\infty}$. But why does $E[\sup_n |X_n|^p] \lt \infty$ imply $X_n$ converges in $L^p$? In general $E[\sup_n |X_n|^p ] \leq \left(\frac{p}{p-1}\right)^p\sup_n E[|X_n|^p]$, so knowing the left hand side is finite doesn't tell me much about the right hand side.

答:
$|X_k| \leq \sup_n |X_n|$. Hence, $E|X_k| \leq E\sup_n |X_n|$ and $\sup_k E|X_k| \leq E\sup_n |X_n|$. Hence, the martinagle converge $P-$ a.s.

$|X_n-X_{\infty}|^{p} \leq 2^{p} (|X_n|^{p}+|X_{\infty}|^{p})\leq 2^{p+1} \sup_n |X_n|^{p}$. Now apply DCT.


问:
How many terms of the geometric sequence $2, 8, 32, 128,\dots $are required to give a sum of $174,762$?

How many terms of the geometric sequence $2, 8, 32, 128,\dots $are required to give a sum of $174,762$?

My attempt

$a = 2$ (the first term)

$r = 4$ (the common ratio)

$S_n = 174,762$ (sum to $n$ terms)

Using the formula

$$S_n=a\bigg(\frac{r^n-1}{r-1}\bigg)$$

Therefore

\begin{align*}
S_n&=2\bigg(\frac{4^n-1}{4-1}\bigg)\\[5pt]
S_n&=174,762\\[5pt]
  4^n-1&= \frac{174,762\cdot3}{2} \\[5pt]
  4^n &= 262,144 \\[5pt]
n &= \log_4(262,144) \\[5pt]
n & =\frac{\ln(262,144)}{\ln(4)}\\[5pt]
n &= \frac{12.476...}{1.386...} \\[5pt]
n & = 9
\end{align*}

There 9 terms are required. Is there a better way go about this? Is this process succinct?

答:
Once you reach
$$
4^n = 262,144
$$
I would proceed with arithmetic, not logarithms. You know
$$
4^5 = 2^{10} = 1,024
$$
so
$$
4^{10} = 2^{20} \approx 1,000,000
$$
is nearly four times too big. So   $4^9 = 262,144$ and you need $9$ terms.


答:
Hint
Supose $U \cap \left(\mathbb{R}^n-K\right)=\emptyset$

Title: If $K\subset \mathbb{R}^n$ compact and $U\subset \mathbb{R}^n$ open, $K \subset U$.Prove that $U \cap \left(\mathbb{R}^n -K \right) \neq \emptyset$

Body:
Let $K\subset \mathbb{R}^n$ be compact subspace and let $\ U\subset \mathbb{R}^n\ $ be open, non-empty and containing $\ K.\ $ Prove that $\ U \cap \left(\mathbb{R}^n -K \right) \neq \emptyset$

Attempt

The first idea that comes to my mind was start to compare $U$ with $\left(\mathbb{R}^n -K \right)$ and see if is possible that the sets have a intersecton.

Let $U$ open notice that $\mathbb{R}^n-U \subset \mathbb{R}^n-K$ since $U$ is open
then $\mathbb{R}^n-U$ is closed. Now since $K \subset U$ then $U-K \neq \emptyset $ and
in fact $U-K \subset \mathbb{R}^n-K$.From here I affirm that $U\cap  \mathbb{R}^n-K$. The problem is that   I never use that $K$ is compact.
Someone can give me a hint or advice at the moment of prove future propositions that involve Complements.


问:
conditions for which matrix has all eigenvalues inside unit circle or on the unit circle
$\mathbf{M}=\begin{bmatrix}
\mathbf{y}&0&0&\cdots&0&0&\mathbf{x}\\
\mathbf{I}&0&0&\cdots&0&0&0\\
0&\mathbf{I}&0&0&0&0&0\\
0&0&\mathbf{I}&0&0&0&0\\
\vdots&\vdots&\vdots&\vdots&\vdots&\vdots&\vdots\\
0&0&0&\cdots&\mathbf{I}&0&0\\
0&0&0&0&0&\mathbf{I}&0\\
\end{bmatrix}$

Given that $\mathbf{y}=\operatorname{diag}\left(y_i\right)$ and $\mathbf{x}=\operatorname{diag}\left(x_i\right) $ where each $i=1,2,\dots, N$, $y_i$ are $N\times N$ matrices whose eigenvalues are strictly less inside unit circle. $I$ are $N\times N$. For each $i$, $x_i$ are also $N\times N$.

Could anyone help me to find out under what condition(s) this matrix $\mathbf{M}$  has the property that modulus of its all eigenvalues strictly less than $1$ given that each block matrix in $\mathbf{y}$ are given that they all have eigenvalues less than $1$, for all $i$?

Thank you.

答:
We could deduce the conditions, given an approximate solution for eigenvector correspondent to the maximum eigenvalue, so, we could reformulate our objective into a simpler one.

When the maximum eigenvalue is a strictly less than 1 ?

Assuming than $M$ is a $(n, n)$ block matrix.

If $M$ is a diagonalizable matrix, then we could use the power iteration method.

\begin{equation} \label{eq1}
\mathbf{v_{k + 1}} = \mathbf{\frac{Mv_{K}}{||Mv_{K}||}},
\end{equation}

where $v_{k+i}$, is the best approximation for eigenvector correspondent to the maximum eigenvalue.

\begin{equation} \label{eq2}
\mathbf{v_{0}} = \begin{bmatrix}a_{0}\\a_{1}\\\vdots\\a_{n}\end{bmatrix}
\end{equation}

$a_{0},\ ... \ , a_{i}, \quad$  are vectors

Assuming we have started with $\mathbf{v_{0}} \succ 0$, then

\begin{equation} \label{eq3}
\mathbf{Mv_{0}} = \begin{bmatrix}a_{0} * x + a_{n} * y\\a_{1}\\\vdots\\a_{n}\end{bmatrix}
\end{equation}

We are able to make a variety of assumptions on $x$ and $y$, to guarantee that the recursive relation is decreasing.


答: That is correct and it is a reasonable way to solve the problem. Of course you may add up the terms until you get to the answer due to fast growth of the terms.</p>

Body:
How many terms of the geometric sequence $2, 8, 32, 128,\dots $are required to give a sum of $174,762$?

My attempt

$a = 2$ (the first term)

$r = 4$ (the common ratio)

$S_n = 174,762$ (sum to $n$ terms)

Using the formula

$$S_n=a\bigg(\frac{r^n-1}{r-1}\bigg)$$

Therefore

\begin{align*}
S_n&=2\bigg(\frac{4^n-1}{4-1}\bigg)\\[5pt]
S_n&=174,762\\[5pt]
  4^n-1&= \frac{174,762\cdot3}{2} \\[5pt]
  4^n &= 262,144 \\[5pt]
n &= \log_4(262,144) \\[5pt]
n & =\frac{\ln(262,144)}{\ln(4)}\\[5pt]
n &= \frac{12.476...}{1.386...} \\[5pt]
n & = 9
\end{align*}

There 9 terms are required. Is there a better way go about this? Is this process succinct?


问:
The minimum distance traveled to move hypothetical point balls?
Consider the following diagram.

We are asked to move each point ball one at a time until all the balls are collected at the pole (indicated by a blue circle). Find the minimum traveled distance. The total distance we travel back and forth to carry the balls must be minimized and it is the question. We start moving the ball from the most left.

My Attempt

I am not sure my attempt below is guaranteed to be the minimum.

Consider there are $i$ balls left at a certain point along the path to the pole. Let $f(i,d)$ be the traveled distance to move $i$ balls to the adjacent point to the right or
\begin{align}
f(i,d) &= (i+i-1)\times d\\
       &= d(2i-1)
\end{align}

Edit:  We need to move forward $i$ times and backward $i-1$ times in order to move $i$  balls from the point under consideration to its adjacent point (on the right side).

Let $S(N,d)$ be the total distance traveled to move 1 ball from the most left to a certain point with $N+1$ balls. So

\begin{align}
S(N,d) &= \sum_{i=1}^N f(i,d)\\
       &= \sum_{i=1}^N d(2i-1)\\
       &= dN^2
\end{align}

For the given problem, the final answer is
\begin{align}
\text{the minimum distance} &= S(11,3) + f(12,5) \\
                            &= 3 \times 11^2 + 5(2 \times 12 -1)\\
                            &= 478
\end{align}

How to prove that my answer above is the minimum?

答:
I'm going to write an answer in my own words, but I think the details you have put in your own solution within the question are equivalent to what I write below and you have already proved that you have found the minimum total distance traveled.
I can't even take credit for this, since every bit of it was anticipated in your solution. But I hope this explanation gives more confidence to your solution.

Given that you must travel right and left in a continuous motion (no "jumps"),
that you can only move the balls by carrying them, and
that you can only carry one ball at a time,
for any point that sits between the flagpole on the right and $n$ balls on the left
you must pass that point $n$ times going to the right.
In order to pass a point $n$ times going to the right you must pass it at least
$n-1$ times going to the left in order to be able to walk past it again
in the rightward direction.

That makes $1$ trip over the $3$-meter space between the leftmost ball and the ball to its right, $3$ trips over the next $3$-meter gap between balls,
$5$ trips over the next gap after that, then $7$ trips, then $9$, and so forth.

That's $1 + 2 + 3 + \cdots + (2n - 1) = n^2$ trips across a gap for the $n$ gaps
between the leftmost $n + 1$ balls.
Since each trip across a gap is $3$ m, that's $3n^2$ m total travel.

Let $n = 11$ to account for the gaps between all $12$ balls.

There must also be $23$ trips across the remaining $5$-meter gap to move all $12$
balls the final $5$ meters to the flagpole.

So the final total is

$$
3(11^2) + 5(23) = 3\cdot 121 + 115 = 478.
$$


问:
Is inversion continuous on normed (not necessarily Banach) algebras?
There is a nice proof here that the map $x\mapsto x^{-1}$ is continuous on the group of invertible elements in a Banach algebra.

I am wondering if the same result holds for normed algebras only? In particular, if $X$ is a normed algebra and $G(X)$ denotes the group of invertible elements in $X$, then for any sequence $(x_n)$ where $G(X)\supset(x_n)_{n\in\mathbb N}\to x\in X$, is it true (1) that $x$ is invertible, and (2) that $({x_n}^{-1})\to x^{-1}?$ Also, are my conditions (1) and (2) equivalent to continuity of $x\mapsto x^{-1}$ on $G(X)$? I think yes, but I'm a bit confused because we are talking about a subspace topology on $G(X)$ induced by a not-necessarily complete norm.

The proof in the linked answer explicitly uses completion in the assumption that a series converges, so it is not sufficient to guarantee continuity in general normed algebras.

Edit: After more thought, I think my condition (1) is equivalent to $G(X)$ being a topologically closed subset of $X$, and (2) is equivalent to continuity of the inverse map, if we only consider cases where $(x_n)$ converges in $G(X)$. At any rate, I would still like to know whether both (1) and (2) are satisfied.

答:
The question has a trivial answer for (2): yes.

Let $A$ be a unital norm algebra. Then the completion of $A$ becomes a Banach algebra so that $A\subset B$ and $A$ is dense in $B$. Indeed, we already know that the completion of a normed space is a Banach space which contains the initial space as a dense subset, so all one should do is check that multiplication is extended to the completion, which is easy, and then verify the submultiplicativity of the norm on the completion, which again is easy.

Note that since $A$ is unital $B$ is also unital and $1_B=1_A$, because $A$ is dense in $B$. Now let $(x_n)\subset A$ be a sequence of invertible elements in $A$. Then they are invertible in $B$. If $(x_n)$ converges to $x\in A$ and $x$ is invertible, then using the fact that inversion is continuous on Banach algebras, one has that $x_n^{-1}\to x^{-1}$.


问:
Loan and Annuity problem - finding X
I am new in finance math, and I am working on this problem. I was wondering if someone could help me solve it.

A loan of $10,000$ is to be repaid with annual payments, at the end of
each year, for the next $21$ years. For the first $7$ years the payments
are $X$ per year, the second $7$ years they are $2X$ per year, and for the
third $7$ years they are $3X$ per year.

a) Find $X$ if $i^{(2)} =10% $

b) Find $X$ if $i^{(2)} = 8%$ for the first 10 years and $i^{(2)} = 12%$ afterwards.

My attempt was

a) My timeline looked like $7$ Xs starting from $t=1$ to $7$, then $2X$ from $8$ to $14$ and then $3X$ from $15$ to $21$.

$$PV = 10000 $$

$$PV = X a_{\overline{7} \rceil.05} + (1.05)^{-7} *2X a_{\overline{14} \rceil.05} + (1.05)^{-14} * 3X a_{\overline{21} \rceil.05} $$

$$10000 = \frac{X[1-(1.05)^{-7}]}{\frac{0.05}{1.05}} + (1.05)^{-7}\frac{2X[1-(1.05)^{-14}]}{\frac{0.05}{1.05}} + (1.05)^{-14}\frac{3X[1-(1.05)^{-21}]}{\frac{0.05}{1.05}}  $$

When I calculate it I got $243.70$

I wasn't sure if $(1.05)^{-7}$ for example was needed since I am starting at year 8 and bring it to time 0 , where the present value of 2X is 7 payments. Same for $(1.05)^{-14}$

I appreciate your help

答:
$\require{enclose}$
$\def \annuity #1{a_{\enclose{actuarial}{#1}}}$
The formula should be

$$PV = X \annuity7 + (1.05)^{-7} *2X \annuity7 + (1.05)^{-14} * 3X \annuity7$$

In each case you have $7$ years of payments. For example, $$2X\annuity7$$ is the present value of the $7$ payments of $2X$ as of the end of the seventh year.  We then multiply by $(1.05)^{-7}$ to bring it back to the date of the loan, so that we compute all present values as of the same date.

Notice the way that I was able to get better-looking annuity symbols.  I got the idea from here.  Look a the first two lines of my answer in the editor.  The first line says we need the "enclose" library.  The second line defines an \annuity macro which we can use line a pre-defined macro such as \sqrt.

The linked source also shows an example of a much more complicated life annuity.  You probably haven't gotten up to this yet.

EDIT

I made a mistake earlier, in that I forgot that then interest rate is $5\%$ every $6$ months.  The formula should actually be

$$PV = X \annuity7 + (1.05)^{-14} *2X \annuity7 + (1.05)^{-28} * 3X \annuity7$$ because there are two compounding periods a year.  Since the payments are made annually, the annuities are computed at the equivalent annual rate, namely $$i=(1.05)^2-1=10.25\%$$

As to your comment, you've made the same mistake with the exponents, but otherwise I think you've got it right.

Title: Loan and Annuity problem - finding X


答: Consider a fixed interval $(i,i+1)$ of the floor that begins with $k$ balls to the left of it. You have to cross this interval from left to right at least $k$ times, and therefore from right to left at least $k-1$ times, so your distance traveled in this interval is at least $2k-1$. Adding this quantity up over all the floor intervals gives you a lower bound of 478 on the distance traveled by any solution.

Title: The minimum distance traveled to move hypothetical point balls?

Body:
Consider the following diagram.

We are asked to move each point ball one at a time until all the balls are collected at the pole (indicated by a blue circle). Find the minimum traveled distance. The total distance we travel back and forth to carry the balls must be minimized and it is the question. We start moving the ball from the most left.

My Attempt

I am not sure my attempt below is guaranteed to be the minimum.

Consider there are $i$ balls left at a certain point along the path to the pole. Let $f(i,d)$ be the traveled distance to move $i$ balls to the adjacent point to the right or
\begin{align}
f(i,d) &= (i+i-1)\times d\\
       &= d(2i-1)
\end{align}

Edit:  We need to move forward $i$ times and backward $i-1$ times in order to move $i$  balls from the point under consideration to its adjacent point (on the right side).

Let $S(N,d)$ be the total distance traveled to move 1 ball from the most left to a certain point with $N+1$ balls. So

\begin{align}
S(N,d) &= \sum_{i=1}^N f(i,d)\\
       &= \sum_{i=1}^N d(2i-1)\\
       &= dN^2
\end{align}

For the given problem, the final answer is
\begin{align}
\text{the minimum distance} &= S(11,3) + f(12,5) \\
                            &= 3 \times 11^2 + 5(2 \times 12 -1)\\
                            &= 478
\end{align}

How to prove that my answer above is the minimum?


答:
$
\newcommand{\Res}[1]{\underset{#1}{\operatorname{Res}}}
$For completeness, I feel that I should post a complex solution. The exponential substitution in the question makes this problem more amenable to contour integration, because it means that we don't have to work around branch cuts.

Let $f(z)=\dfrac{z^2e^z}{e^{3z}-1}$ (yes, $z^2$ and not $z$). We'll integrate $f(z)$ around the indented rectangular contour shown below:

We'll take the limit as the left and right sides $L$ and $R$ of the rectangle move out to infinity and the indentations $I_1$ and $I_2$ shrink to zero radius. The top and bottom sides ($T_+,T_-,B_+,B_-$) will always have imaginary parts $\pm 2\pi$.

It's not too hard to see that $\int_L f(z) \, dz$ and $\int_R f(z) \, dz$ vanish in the limit. By a standard indented contour argument, we have $\int_{I_1} f(z) \, dz \to -\pi i \Res{z=2\pi i} f(z)$ and $\int_{I_2} f(z) \, dz \to -\pi i \Res{z=-2\pi i}f(z)$ (because we're going clockwise around both poles). Finally, in the limit we have

$$
\int_{T_-+T_+} f(z) \, dz \to -\textrm{p.v.}\int_{-\infty}^\infty \frac{(u+2\pi i)^2e^u}{e^{3u}-1} \, du
$$

and

$$
\int_{B_-+B_+} f(z) \, dz \to \textrm{p.v.}\int_{-\infty}^\infty \frac{(u-2\pi i)^2e^u}{e^{3u}-1} \, du
$$

By the residue theorem we have therefore have:

$$
\textrm{p.v.}\int_{-\infty}^\infty \left[\frac{(u-2\pi i)^2e^u}{e^{3u}-1} -\frac{(u+2\pi i)^2e^u}{e^{3u}-1}\right] \, du=\pi i \left[\Res{z=2\pi i} f(z)+\Res{z=-2\pi i} f(z)\right]+2\pi i \left[\Res{z=2\pi i/3} f(z)+\Res{z=-2\pi i/3} f(z)+\Res{z=4\pi i/3}f(z)+\Res{z=-4\pi i/3}f(z)\right] \, .
$$

Canceling terms on the left-hand side gives

$$
-8 \pi i \int_{-\infty}^\infty \frac{ue^u}{e^{3u}-1} \, du=\pi i \left[\Res{z=2\pi i} f(z)+\Res{z=-2\pi i} f(z)\right]+2\pi i \left[\Res{z=2\pi i/3} f(z)+\Res{z=-2\pi i/3} f(z)+\Res{z=4\pi i/3}f(z)+\Res{z=-4\pi i/3}f(z)\right]
$$

Note that this integral is legitimately convergent so we no longer need to be considering principal values. It follows that

$$
\int_{-\infty}^\infty \frac{ue^u}{e^{3u}-1}\, du=-\frac{1}{8}\left[\Res{z=2\pi i} f(z)+\Res{z=-2\pi i} f(z)\right]-\frac{1}{4} \left[\Res{z=2\pi i/3} f(z)+\Res{z=-2\pi i/3} f(z)+\Res{z=4\pi i/3}f(z)+\Res{z=-4\pi i/3}f(z)\right] \, .
$$

So we just need to compute these residues! Letting $\omega=e^{2\pi i/3}$ be a primitive cube root of unity and letting $k$ be a nonzero integer (so that $f$ has a simple pole at $\dfrac{2\pi i k}{3}$), we have:

$$
\begin{align*}
\Res{z=2\pi i k / 3} f(z)&=\lim_{z \to 2\pi i k / 3} \left(z-\frac{2\pi i k}{3}\right)\frac{z^2e^z}{e^{3z}-1}\\
&=\left(\frac{2\pi i k}{3}\right)^2\omega^k\lim_{z \to 2\pi i k/3} \frac{z-2 \pi i k/3}{e^{3z}-1}&&\\
&=\left(\frac{2\pi i k}{3}\right)^2\omega^k\left(\frac{1}{3}\right)&&\text{(by L'Hôpital)}\\
&=-\frac{4}{27}\pi^2 k^2 \omega^k \, .
\end{align*}
$$

Now, the residues in the expression for the integral can be combined in pairs symmetric about $z=0$:

\begin{align*}
\Res{z=2\pi i} f(z)+\Res{z=-2\pi i}f(z)&=-\frac{4}{27}\pi^2 \cdot 9\omega^3-\frac{4}{27}\pi^2 \cdot 9\omega^3\\
&=-\frac{8}{3}\pi^2&&\text{(}\omega\text{ is a cube root of unity)}\\
\Res{z=2\pi i/3} f(z)+\Res{z=-2\pi i/3} f(z)&=-\frac{4}{27}\pi^2\omega-\frac{4}{27}\pi^2\omega^{-1}\\
&=-\frac{4}{27}\pi^2(\omega+\omega^{-1})\\
&=\frac{4}{27}\pi^2&&\text{(}\omega+\omega^{-1}=-1\text{)}\\
\Res{z=4\pi i/3} f(z)+\Res{z=-4\pi i/3} f(z)&=-\frac{4}{27}\pi^2\cdot 4\omega^2-\frac{4}{27}\pi^2\cdot 4\omega^{-2}\\
&=-\frac{16}{27}\pi^2(\omega^{-1}+\omega)&&\text{(}\omega^2=\omega^{-1}\text{)}\\
&=\frac{16}{27}\pi^2 \, .
\end{align*}

Putting all this together, we have

\begin{align*}
\int_{-\infty}^\infty \frac{ue^u}{e^{3u}-1} \, du &= -\frac{1}{8}\left(-\frac{8}{3}\pi^2\right)-\frac{1}{4}\left(\frac{4}{27}\pi^2\right)-\frac{1}{4}\left(\frac{16}{27}\pi^2\right)\\
&=\frac{1}{3}\pi^2-\frac{1}{27}\pi^2-\frac{4}{27}\pi^2\\
&=\frac{4}{27}\pi^2
\end{align*}

as desired.

Title: Prove $\int_0^\infty\frac{\ln x}{x^3-1}\mathrm{d}x=\frac{4\pi^2}{27}$

Body:
Proof of the integral
$$\int_0^\infty\frac{\ln x}{x^3-1}\mathrm{d}x=\frac{4\pi^2}{27}$$
I try to substitute $u = \ln x$. Then $x = e^u,\>\mathrm{d}x = e^u\mathrm{d}u$ and the limits $(0,\infty)\to (-\infty,\infty)$.
The integral becomes $$\int_{-\infty}^\infty \frac{ue^u}{e^{3u}-1}\mathrm{d}u.$$


问:
Proof of matrix inequality involving trace and max-operator
Let $C\in\mathbb R^{N\times N}$ be a real positive-semidefinite matrix, $I\in\mathbb R^{N\times N}$ the identity matrix and $W,V\in\mathbb R^{N\times N}$ two real-valued random matrices. Is it true that

$$tr\left[(C-I)WCV^T\right]\leq max\left\{tr\left[(C-I)WCW^T\right],tr\left[(C-I)VCV^T\right]\right\}$$

holds for all $W, V$? My simulations suggests the inequality is true, but I have no idea how to proof it.

Any comments and ideas are greatly appreciated! Thanks!

答:
The inequality does not hold in general.

Let
$$
C=1/2\,I=\begin{bmatrix}1/2&0\\0&1/2\end{bmatrix},\ \ W=\begin{bmatrix}0&0\\1&0\end{bmatrix},\ \ V=W^T=\begin{bmatrix}0&1\\0&0\end{bmatrix}.
$$
Then
$$
\mbox{tr}((C-I)WCV^T)=-\frac14\,\mbox{tr}(WV^T)=-\frac14\mbox{tr}(W^2)=0.
$$
And
$$
\mbox{tr}((C-I)WCW^T)=-\frac14\,\mbox{tr}(WW^T)=-\frac14,
$$$$
\mbox{tr}((C-I)VCV^T)=-\frac14\,\mbox{tr}(VV^T)=-\frac14,
$$


问:
Good General Strategy For Solving For The Core In A Coalitional Game?
Does anyone have a good general approach to solving for the core of a coalitional game (or finding that there is no core)?</p>

答:
There may be approaches for specific instances of cooperative games. In general, it is unlikely that there is a good and easy approach for computing the core. Deciding whether the core is non-empty is $\textsf{NP}$-complete.

See for instance:

http://www.cs.cmu.edu/~sandholm/core_complexity.ijcai03.pdf

https://www.cs.cmu.edu/~sandholm/computing_shapley.aaai04.pdf

https://www.mimuw.edu.pl/~oski/atgk/slides/ATGK_6_Representations.pdf

The Nucleolus may be of interest. The key idea is that the Nucleolus allocates resources in a way that minimizes the unhappines of each coalition. The Nucleolus is unique and polynomial-time computable. If the core is non-empty, then the Nucleolus belongs to the core.

There are other solution concepts in cooperative games, such as the Shapley Value, the Kernel, and Bargaining Sets. See for instance (http://lcm.csa.iisc.ernet.in/gametheory/ln/web-cp6-othertopics.pdf).

Note that the Shapley Value (which is the most common solution concept to discuss in Game Theory courses) is $\textsf{NP}$-hard to compute in general, as well as $\textsf{#P}$-hard for many classes of games (https://arxiv.org/ftp/arxiv/papers/1402/1402.0567.pdf).


问:
Confusion about definition of differential manifold
I'm reading a spanish book which has the following definition of whats called (variedad diferenciable) that I think is the spanish name for differential manifold.

Definition $M \subset \mathbb{R}^n$ non empty. $M$ is a manifold of dimension $m$ $1 \leq m \lt n$ of class $C^q$, if for each $x^0 \in M$, there exists a open neighbourhood $W_{x^0}$ of $x^0$ in $\mathbb{R}^n$ and a function: $\phi_{x^0} \in C^q ( W_{x^0}, \mathbb{R}^{n - m})$, such that $D \phi_{x^0}(x)$ has maximum rank, $n - m$, for all $x \in W_{x^0}$ and:

$$ M \cap W_{x^0} = \{x \in W_{x^0} : \phi_{x^0}(x) = 0\}$$

The above definition is called a m-manifold.

I have found a similar definition in Wendell's Fleming book Functions of Several Variables. But I haven't found this definition anywhere else, all the definitions I find elsewhere use the concept of chart. Is the concept of chart underlying in the definition? Is it $\phi_{x^0}$?

Is this definition equivalent to the concept explained in the wikipedia page about Differentiable manifold?

答:
What happens is the following: to define a differentiable manifold in an abstract sense you have to put on it a differentiable atlas, consisting of charts that tell you how to put coordinates on regions of the manifold, and in such a way that the change of coordinates is as smooth as you require.

In the case you give you are not in the most abstract possible case, but rather you are already inside $\mathbb{R}^n$ which has its own standard differentiable structure. In this definition, then, it makes sense to do not ignore this fact and that is why you require the existence of a neighborhood $W_{x_0}$ of $\mathbb{R}^n$ and a function $\phi\in C^q(W_{x_0}, \mathbb{R}^{n - m})$ with the given conditions.

When you do this, a set of open neighborhoods of $M$ appears in a natural way, and it consists of $M\cap W_{x_0}$ as $x_0$ varies. By the definition of subspace topology, these are actually open in $M$. The only thing you are missing to obtain the classical definition of chart is to understand what happens when you change of coordinates.

In order to do this you need to invoke the implicit function theorem, that guarantees you the existence of a function $g: U\subset\mathbb{R^m}\rightarrow \mathbb{R}^{n - m}$ such that $\phi_{x_0}(x, g(x)) = 0$ for any $x\in U$. And this, by the condition you put, means that $(x, g(x))$ is actually in $M$. (In here we maybe relabel the coordinates as to make the last $n - m$ correspond to those that will give you the maximal rank).

The chart thus becomes projecting onto the first $m$ coordinates and the condition of the rank and the dimension $n - m$, is to make sure that you obtain an inverse of a chart in M that can be composed with another projection, which is smooth globally, and give a differentiable map between open sets of $\mathbb{R}^m$.

The main point of this definition then, is that there exist coordinates of $\mathbb{R}^n$ so that fixing the value of some of them gives you coordinates of $M$ and so you get, varying the possible fixing values, layers of diffeomorphic subsets (like sheets one on top of another).

The reason why you don't see this as the standard definition of manifold is because in order to do this you need $M$ to be inside another manifold $N$ to begin with, so that it makes sense to talk about a neighborgood in $N$ (what we called $W_{x_0})$. This concept appears after we have defined differentiable structures and is the concept of regular submanifold. To see the difference, think of the x axis and of the graph of the absolute value as sets in $\mathbb{R}^2$. Abstractly, as sets, these two admit a differentiable structure, but as subsets of $\mathbb{R}^2$ only the $x-$axis is a regular submanifold.