问:
Matrix derivative of trace(AB) and ln(det(A)) with respect to a vector
I am confused by myself on matrix derivation with respect to a vector. I
wish to get some help from all of you. Thanks in advance!

Both $A\left( \mathbf{\theta }%
\right) $ and $B\left( \mathbf{\theta }\right) $ are nonsingular square
matrices of a vector $\mathbf{\theta ,}$ I am looking for the following
matrix derivative:
$\frac{\partial tr\left(
A\left( \mathbf{\theta }\right) ^{-1}B\left( \mathbf{\theta }\right) \right)
}{\partial \mathbf{\theta }}.$

As an example, $A\left( \mathbf{\theta }%
\right) =\left( \mathbf{I}+\mathbf{\theta \theta }^{\prime }\right) $ where $%
\mathbf{I}$ is an identity matrix, and $B\left( \mathbf{\theta }\right)
=\left( \mathbf{C}+\mathbf{a\mathbf{\theta }^{\prime }+\theta b}^{\prime }+%
\mathbf{\theta \theta }^{\prime }\right) $ where $\mathbf{C}$ is a matrix
of constants, both $\mathbf{a}$ and $\mathbf{b}$ are vectors of constants assuming the dimension matches. Is there any chain rule for the derivatives? Thanks

答:
The Matrix Cookbook contains many useful formulas like the following
$$\eqalign{
\frac{\partial\log(\det(X))}{\partial X} &= X^{-T}
 \quad&\implies\quad&d\log(\det(X)) = X^{-T}:dX \\
\frac{\partial{\,\rm Tr}(X)}{\partial X} &= I
 \quad&\implies\quad&d{\,\rm Tr}(X) = I:dX \\
}$$
Substituting the given variables
$$\eqalign{
A &= I+\theta\theta^T
 \quad&\implies\quad
&dA = (d\theta\,\theta^T+\theta\,d\theta^T) \\
I &= A^{-1}A
 \quad&\implies\quad
&0 = dA^{-1}A + A^{-1}\,dA \\
&&&dA^{-1} = -A^{-1}dA\,A^{-1} \\
\\
(B-C) &= \theta\theta^T + a\theta^T + \theta b^T
 \quad&\implies\quad&dB = dA + a\,d\theta^T + d\theta\,b^T \\
\\
X &\doteq A^{-1}B
 \quad&\implies\quad&dX = A^{-1}dB + dA^{-1}B \\
}$$
yields
$$\eqalign{
d{\,\rm Tr}(X) &= I:dX \\
 &= I:(A^{-1}\,dB - A^{-1}dA\,A^{-1}B) \\
 &= A^{-T}:(dA+a\,d\theta^T + d\theta\,b^T) - A^{-T}B^TA^{-T}:dA \\
 &= A^{-T}:(a\,d\theta^T + d\theta\,b^T)
  +(A^{-T}-A^{-T}B^TA^{-T}):(d\theta\,\theta^T+\theta\,d\theta^T) \\
 &= \big(A^{-T}b + A^{-1}a\big):d\theta
  + \big(A^{-T}+A^{-1}-A^{-T}B^TA^{-T}-A^{-1}BA^{-1}\big)\theta:d\theta \\
\\
\frac{\partial{\rm Tr}(X)}{\partial\theta}
 &= A^{-T}b + A^{-1}a
  + \Big(A^{-T}+A^{-1}-A^{-T}B^TA^{-T}-A^{-1}BA^{-1}\Big)\theta \\
\\
}$$

In some of the steps above, a colon is used to denote
the trace/Frobenius product, i.e.
$$\eqalign{
A:B = {\rm Tr}(A^TB) = {\rm Tr}(B^TA) = B:A
}$$
The properties of the trace under transposition and cyclic permutation of its argument, allows the terms in such a product to be rearranged in several equivalent ways, e.g.
$$\eqalign{
A:BC &= AC^T:B = B^TA:C &= \ldots \\
A:B &= A^T:B^T = I:A^TB &= \ldots \\
}$$


问:
Positive integral implies positive function?
Let $f:I\to\mathbb{R}$ be a nonnegative, bounded, integrable and continuous function with $I\subseteq\mathbb{R}$ being an interval.

If $\int_I f d\mu=1$, does $\mu(f>0)>0$ hold, where $\mu$ is the Lebesgue measure?

答:
Suppose $\mu \{f>0\}=0.$ Observe

$$\int_I f\,d\mu = \int_{f>0} f\,d\mu + \int_{f=0} f\,d\mu.$$

The first integral on the right is $0$ because integrating over a set of measure $0$ gives $0.$ The second integral is $0$ because the integral of the zero function over any measurable is $0.$ Thus $\int_I f\,d\mu=0,$ contradiction.

ContentLicense: CC BY-SA 4.0


问:
How do I prove that a DAG with the maximum of edges + one edge must have a cycle?
Question: How do I prove that a DAG with A($n$) edges + one edge must have a cycle?

$\begin{equation}
    \text{A}(n)=\frac{n\cdot(n-1)}{2}
\end{equation}$

My answer: What happens if we add another edge to a DAG with A($n$) edges. Well, the only nodes that we can still add edges to are just previous nodes, which means that we will get a cycle if we add an edge.

The thing I need help with is to enforce my answer with the pigonhole-principle, but I dont know how.

答:
Here's an idea/ hint: Show that a digraph of order $n$ with $A(n) + 1$ edges must have a $2$-cycle.

Click below for a proof outline:

 There are $A(n) = \binom{n}{2} = \frac{n(n-1)}{2}$ pairs of vertices in the digraph, but $A(n)+1$ edges. So by the pigeonhole principle, at least one pair of vertices, say $u$ and $v$, has both directed edges $uv$ and $vu$ between it. Which means the digraph has a $2$-cycle.


问:
Primes 5 mod 8 can be written in the form $(2x+y)^2 + 4y^2$
I am stuck trying to prove the theorem using an algebraic approach, please could someone give me a hint(preferably not the whole answer)

Primes 5 mod 8 can be written in the form $(2x+y)^2 + 4y^2$

I am told to assume and make use of the fact that primes 1 mod 4 can be written as $p=m^2+n^2$. WLOG I let $m^2$ be even and $n$ be odd($m=2a, n^2=8q+1$) So,

$$8k+5= (2a)^2+(8q+1)$$
$$\iff 8(k-q)+4=4a^2$$
$$\iff 2(k-q)+1 = a^2$$
$$\implies a=2v+1$$
$$2(k-q)+1=4v^2+4v+1$$
$$(k-q)=2v(v+1)$$

At this point I feel completely lost and alienated from my original goal. I can say that 4|k-q but I don't think this is useful. Could someone give me a nudge in the right direction?

答:
Hint: $(2x+y)^2 + 4y^2 = 4(x^2+xy)+5y^2$.

$y$ has to be odd for the expression to be a prime number. Now regardless of $x$ is odd or even, what happens to $x^2+xy$? Also if $y$ is odd, $5y^2$ can be written $5(2n+1)^2 = 20(n^2 + n) + 5$


问:
If $x_n\in l^1(\mathbb{K})$ and $x_n\rightarrow 0$ in $X_p$, then $x_n\rightarrow 0$ in $X_1$?
Is it true that if $x_n\in l^1(\mathbb{K})$ and $x_n\rightarrow 0$ in $X_p$, then $x_n\rightarrow 0$ in $X_1$?

Where $X_1= (l^1(\mathbb{K}),\|.\|_1)$ and
$X_p=(l^1(\mathbb{K}),\|.\|_p)$

I know that $l^1(\mathbb{K})$ is subspace of $l^p(\mathbb{K})$.

答:
(I assume $p\in \mathbb{N}$ and $p \geq 2$)

It is not true. Let $x_n \in \ell^1$ be the sequence
$$
x_{n,k} :=
\begin{cases}
n^{-\frac{2}{p}} & , ~k \leq n \\
0 &, ~k > n
\end{cases}.
$$
Then
$$
\lVert x_n \rVert_p^p = \sum_{k = 1}^{\infty} \lvert x_{n, k} \rvert^p = \frac{1}{n} \overset{n \rightarrow \infty}{\longrightarrow}0.
$$
But:
$$
\lVert x_n \rVert_1 = n^{1 - \frac{2}{p}} \geq 1
$$


问:
Probability of flopping a royal flush
I have no stats training, so I am asking if I am attacking this simple statistical problem correctly.

What are the chances of flopping a royal flush in Texas hold’em?

My attempt: The first card dealt to the player must be either a $10,J,Q,K,$ or $A$, any suit.  So the probability of the first card deal would be $\frac{5}{13}$.  Then the second card dealt to the player must be the same suit, and one of the values mentioned above, meaning the probability is $\frac{4}{51}$.  It follows that the next three cards on the flop must be the three remaining cards needed to complete the royal flush, with probabilities: $(\frac{3}{50})(\frac{2}{49})(\frac{1}{48})$.  Therefore I believe the odds of flopping a royal flush is: $\frac{5!}{13\cdot 51\cdot 50\cdot 49\cdot 48}$

I would think that this probability would be independent of how many players are in the game.  The odds of the deck the be stacked in the perfect way according to how many players there are to give you the royal flush on the flop seem to be the same.

Have I made any mistakes?  Thanks in advance.

答:
You are correct.

$\dfrac {5!} {(13 \cdot 51 \cdot 50 \cdot 49 \cdot 48)} =
\dfrac {1}{13} \cdot \dfrac {5 \cdot 4 \cdot 3 \cdot 2 \cdot 1}{51 \cdot 50 \cdot 49 \cdot 48} = \dfrac {52}{13} \dfrac {5 \cdot 4 \cdot 3 \cdot 2 \cdot 1}{51 \cdot 50 \cdot 49 \cdot 48} = \dfrac {4}{C(52,5)} = \dfrac {C(4, 1)} {C(52, 5)} = 0.000001539.$

Most of the time, you'll see the probability in terms of the binomial coefficients,
$C(n, k)$.

ContentLicense: CC BY-SA 3.0

Title: Probability of flopping a royal flush


问:
Find last two digits of $302^{46}$
I need to find the last two digits of $302^{46}$ without resorting to Euler's theorem or Chinese remainder theorem (they have not been introduce so far in the course; I can user Fermat's little theorem though). This is what I tried:

We have to work $\pmod{100}$ and it is easy to see that:

$302 = 2 \pmod{100}$

So I can write

$302^{46} = 2^{46} \pmod{100}$

I'm stuck here I don't know know to further reduce $2^{46}$.

答:
Consider the multiplicative semigroup

contained in $\mathbb {Z} / \text{100} \mathbb {Z}$.

Using the table we see that

$\quad 16^5 = 76 \pmod{100}$

So

$\quad 2^{46} = 4 \, (2^4)^{11} \equiv 4 \, (16)^{11} \equiv 4 \cdot 16 \cdot (76 \cdot 76) \equiv 4 \cdot (16 \cdot 76) \equiv 4 \cdot 16 \equiv 64 \pmod{100}$

For more details on this technique/theory, see this.

Title: Find last two digits of $302^{46}$


问:
"Short exact sequences", longer than classical one
A standard short exact sequence is a complex $$0\to A\to B\to C \to 0$$ Based on this concept we get a lot of new concept in homological algebras. For example  left exactness, right exactness, derived functor, etc.
And we get some applications in other areas e.g algebraic topology.

Now let'us consider an exact sequence with more than 3 terms. For example 4 object or more as follows:

$$0\to A\to B\to C\to D \to 0$$

Do we get some thing new with these new concept of short exact sequence? Can we find some non trivial applications in homological algebra or algebraic topology?

Note that in this setting some concepts as left or right exactness have the obvious modifications.

答:
The short exact sequence is more fundamental, because every longer chain complex can be obtained by "splicing" SES.

In your example, we have

$$0 \to A \to_f B \to \operatorname{coker} f \to 0$$
and
$$ 0 \to \ker h \to C \to_h D \to 0$$

Now let $g:B \to C$ be the middle map in your exact sequence. Note however that $\operatorname{coker} f=B/\ker g \cong\operatorname{im} g$ while $\ker h = \operatorname{im} g$ as well by exactness. Thus, we can use these identifications to "splice" our SES back together. See here for mode details and here for the "other direction."

One possible generalization is the notion of SES in an abelian category, which for example gives SES of chain complexes $0 \to A_\bullet \to B_\bullet \to C_\bullet \to 0$. This also gives a LES in homology by the snake lemma.


问:
non-null rows of the row space of a RREF matrix are linearly idependent.
I'm trying to prove that, given a RREF matrix $B$ with components in $\mathbb{R}$, if you take its row space, all the non-null rows are linearly independent vectors. I have this:

Let $B$ be a RREF matrix. We can assume that, for each non-null row, we have:

\begin{align*}
    v_{1} &= \begin{pmatrix} \alpha_{11} & \alpha_{12} & ... & \alpha_{1n} \end{pmatrix}\\
    v_{2} &= \begin{pmatrix} 0 & \alpha_{22} & ... & \alpha_{2n} \end{pmatrix}\\
    v_{3} &= \begin{pmatrix} 0 & 0 & ... & \alpha_{3n} \end{pmatrix}\\
        &.\\
        &.\\
        &.\\
    v_{m} &= \begin{pmatrix} 0 & 0 & ... & \alpha_{mm} & \alpha_{m(m+1)} & ... & \alpha_{mn} \end{pmatrix}\\
\end{align*}

with $v_{i}$ being the vector given by the i-th row.

But I don't really know how to prove that any vector $v_{i}$ can't be a linear combination from all the others. I know I can prove that any given vector $v_{i}$ can't be generated by the vectors below it, but I don't know how to prove it can be generated by those beneath it.

答:
Let the coefficients $c_1,\dots,c_n$ be such that $c_1v_1 + \cdots + c_n v_n = 0$. Let $j$ be the smallest index $i$ for which $c_i \neq 0$. We can then rewrite
$$
c_1v_1 + \cdots + c_n v_n = 0 \implies v_j = - \frac{c_{j+1}}{c_j}v_{j+1} - \cdots - \frac{c_n}{c_j} v_n.
$$
However, as you say in your post, this is impossible.


答:
Length 4 exact sequences are pretty boring because, in normal abelian categories, they correspond to ordinary morphisms. We can extend $f:X\to Y$ to an exact sequence
$$
0 \xrightarrow{} \operatorname{ker}f \to X \xrightarrow{f} Y \to \operatorname{coker}f \to 0.
$$
Similarly, every exact sequence of length four will arise this way. Passing to length 5 sequences isn't going to be terribly interesting either because the sequences now look like this
$$
0 \xrightarrow{} \operatorname{ker}f \to X \xrightarrow{f} Y \xrightarrow{g} Z \to\operatorname{coker}g \to 0.
$$
There's nothing new going on here. In fact, as a different poster has mentioned all these longer exact sequences can be produced by splicing together short exact sequences. The natural way to generalise left exactness, right exactness and derived functors turns out to involve weakening the notion of a abelian category, to obtain an $n$-abelian category. This is called Higher Homological Algebra and you can read more about it in this paper of Gustavo Jasso.

Title: "Short exact sequences", longer than classical one

Body:
A standard short exact sequence is a complex $$0\to A\to B\to C \to 0$$ Based on this concept we get a lot of new concept in homological algebras. For example  left exactness, right exactness, derived functor, etc.
And we get some applications in other areas e.g algebraic topology.

Now let'us consider an exact sequence with more than 3 terms. For example 4 object or more as follows:

$$0\to A\to B\to C\to D \to 0$$

Do we get some thing new with these new concept of short exact sequence? Can we find some non trivial applications in homological algebra or algebraic topology?

Note that in this setting some concepts as left or right exactness have the obvious modifications.


问:
Identity Element of an Elliptic Curve in Cryptography
The Group for Elliptic Curve Cryptography doesn't actually seem to have an identity element. You have just randomly defined an element at Infinity as an identity element and said that any other element when added to that element is the same element.

Let us say I have a set & an operator which satisfies all other properties of a group except for the identity element property. Can I convert into a group by creating my own definition of a new element & say it that it is an identity element.

Doesn't this make the whole definition of a Group & the properties it must satisfy meaningless? I could just create my own definitions & create my own imaginary definitions just so it satisfies the property which it otherwise doesn't.

答:
We can think of the point at infinity as an extra point created so that the curve works out as a group, but that's unsatisfactory: the point of infinity has no place in the geometric picture and in the algebraic construction we magically add one with no coordinates.

$$E := \{ (x, y) \in k^2 \mid y^2 = x^3 - x + 1 \} \cup \{\mathcal O\}$$

An Elliptic Curve cannot be easily understood without the projective plane.

The projective plane is the set $\mathbb{P}^2(k)$ all nonzero triples $(x,y,z)$ in $k^3$ modulo the equivalence relation $(x,y,z) \sim (\lambda x,\lambda  y,\lambda  z)$

With this definition, we can define a projective point $(x:y:z)$ is the equivalence class of $(x,y,z)$

Now can we turn these points into Affine point?

Points of the form $(x:y:1)$ are called the affine points They form an affine plane ( Euclidean plane) $\mathbb{A}^2(k)$ and that is embedded in the $\mathbb{P}^2(k)$. This is a natural embedding. One can define some other embedding too that can change the point at infinity.

What is not mapped into the $\mathbb{A}^2(k)$ is the points of the form $(x:y:0)$ and they are called point at infinity.

These point include $(x:y:0)$ and $(1:0:0)$ and they form the line at infinity that is a copy of  $\mathbb{P}^1(k)$ embeded in  $\mathbb{P}^2(k)$

The group needs and an identity element and the group law works perfectly with the simple law

$$\texttt{Three points on a line sum to zero, which is the point at infinity.}$$

In the short Weierstrass form $y^2 = x^3 +A x + B$ the point at infinity is $O =(0:1:0)$ Reason; consider it homogeneous equation $E : y^2 z = x^3 + Axz^2 + Bz^3$. This point is the unique point on the line $z=0$ at infinity. ( if $z=0$ then $x=0$ then we get $(0:y:0)$ and scale it with $1/y$. Note that by definition $(0:0:0)$ is not a projective plane.

Identity element Edwards curves? It is $(0,1)$ They can still embed into Projective Plane. That is very useful in Cryptography. Can you define the identity element as any element up to isomorphism!.


问:
Is it true that $D_{KL}[q_1 \| p]\leq D_{KL}[q_2 \| p] \Rightarrow D_{KL}[p\|q_1]\leq D_{KL}[p \| q_2]$?
The KL divergence between two probability measures $p, q$ on a Polish space $E$ is defined as

$$D_{KL}[q \| p] = \int_E \log \left(\frac{dq}{dp}\right)dq$$

provided that $q \ll p$.

Now is it true that $D_{KL}[q_1 \| p]\leq D_{KL}[q_2 \| p] \Rightarrow D_{KL}[p\|q_1]\leq D_{KL}[p \| q_2]$ provided that $p,q_1,q_2$ are equivalent in the sense of measures?

答:
The answer is no.

I'll explicitly construct a triple $(p,q_1,q_2)$ on four points that violates the relation. This can be extended to however rich a Polish space you like (as long as it has at least $4$ points) by convolving with appropriately thin densities.

Let $$p = \frac{(1,1,1,1)}{4}\\  q_1^x =  \frac{(2-x, 2-x, x,x)}{4}\\ q_2 = \frac{(3, 1, 1, 1)}{6},$$ where $x \in (0,2)$ will be chosen in the following.

To construct a counterexample, we need to find an $x$ such that $D(q_1^x \|p) < D(q_2\|p)$ and $D(p\|q_1^x ) > D(p\|q_2)$. By direct computation, this boils down to finding an $x$ such that \begin{align} (2-x) \log(2-x) + x \log x &< \log(4/3)\\ 2\log(2-x) + 2\log(x) &< \log(16/27) \end{align}

The easiest way to find an appropriate $x$ is to simply use a CAS. Wolfram alpha suggests that $x = 1/2$ is good enough. Indeed, $$ (3/2) \log(3/2) +(1/2) \log(1/2) = \log(\sqrt{27}/4) \le \log(5.22/4) = \log(1.305) < \log(4/3)\\
2\log(3/2) + 2\log(1/2) = \log(9/16) < \log(16/27),$$ where the first line uses that $\sqrt{3} < 1.74,$ and the second line follows since $9 \times 27 = 243 < 256 = 16^2$.

Process for finding the above - I started with $p$ being a uniform law because that makes $D(q\|p)$ and $D(p\|q)$ both have simple forms. $D(q_1\|p) < D(q_2\|p)$ is then equivalent to $H(q_1)>H(q_2),$ which led me to think about $q_1$ that is a little more spread out than $q_2$ - to simplify I chose $q_1$ peaked on half the space and $q_2$ on a quarter. $D(p\|q_1) > D(p\|q_2)$ is equivalent to $\sum \log(1/q_1(i)) > \sum \log(1/q_2(i))$. At this point I realised that I might as well take just $4$ points, and ran a CAS for $q_1$ and $q_2$ parametrised. Finally I just set the parameter of $q_2$ somewhere in the middle to make calculations easy.


问:
A proof for If $a>0$ AND $r<s$ then: $a>1⇔a^r<a^s$ without using the natural logarithm function?
We have $a$ is a real positive number different than zero.

$r$ and $s$ belong both to $\mathbb{Q}$

$(r<s)$ AND $(a^r<a^s)$
⇔ $(r<s)$ AND $(ln(a^r)<ln(a^s))$
⇔ $(r<s)$ AND $(r.ln(a)<s.ln(a))$

On the other hand we have:

$a>1⇔ln(a)>ln(1)⇔ln(a)>0$

which means that:

r.$ln(a)<s.ln(a) ⇔ r<s$ because $ln(a)>0$

This can be summarized as follows:

If $a>0$ AND $r<s$ then:

$a>1⇔a^r<a^s$

Is there any other proof for:
If $a>0$ AND $r<s$ then: $a>1⇔a^r<a^s$
without using the natural logarithm function $ln$?

This was my answer for someone asking for a proof here

Unfortunately he needed a proof without using the $ln$ function.

答:
You ask for a proof without logarithmic function. However, we must know if $r$ is real or not.

If it is, then we cannot define $a^r$ without logarithm function same is for $a^s$ if $s$ is real too.

EDIT:
Since we know that $r$ and $s$ are rational number, instead of using logarithmic function we can just use $f: x \mapsto \sqrt[q]{a^x}$. This function is defined for all $x, q$ natural integers.

So this simply equivalent to prove that $f$ parametric $a$ is increasing for parameter $a > 1$. This can be done recursively by proving the ratio of two consecutive terms is greater than 1 if and only if $a>1$.


问:
Does there exist such a sequence?
Does there exist a infinite sequence of positive integers $a_n$. Such that $ ((n|a_n) | \forall n)$ and $\left(\sum_{n=1}^\infty \frac {1}{a_n} =1\right)$ , what if we replace 1 with a positive real number r ?

if we weaken $\left(\sum_{n=1}^\infty \frac {1}{a_n} =1\right)$  to $\left(\sum_{n\in S} \frac{1}{a_n} =1\right)$  for some infinite subset $S$ of naturals. We have an example $S = (2^n |n\in \Bbb N)$ and $(a_n=n)$ , Can we classify all such examples? Are there infinitely many?

What if $S$ is finite? We have the example $S=(2,3,6)$ and $(a_n = n)$ i.e. $\left(\frac 12 +\frac 13 +\frac 16 = 1\right)$ , So what are all such examples? Certainly there are infinitely many, as we can multiply each term in the finite sum $\left(\frac 12 +\frac 13 +\frac 16 \right)$ by $\left(\frac 12\right)$ and add $\left(\frac 12\right)$ to get 1, and repeat the process.

What happens if we weaken $( (n|a_n ) |(\forall n))$ to $( (n|a_n )| (\forall n>n_0))$ for some $n_0$?

答:
Does there exist a infinite sequence of positive integers $a_n$ such that $ ((n|a_n) | \forall n)$ and $\left(\sum_{n=1}^\infty \frac {1}{a_n} =1\right)$

$a_n = n(n+1)$.

if we weaken $\left(\sum_{n=1}^\infty \frac {1}{a_n} =1\right)$  to $\left(\sum_{n\in S} \frac{1}{a_n} =1\right)$  for some infinite subset $S$ of naturals.

A necessary condition is that the sum of $1/n$ restricted to $S$ is at least $1$.

When $S$ is finite the problem falls under the name "Egyptian fractions" and more information can be found by searching on that term.

Title: Does there exist such a sequence?


答:
This should probably just be a comment, but note that, restricting attention to complexes of finite-dimensional vector spaces, a short exact sequence
$$0 \to A \to B \to C \to 0$$
satisfies the dimensional relation
$$ \dim(A) +\dim(C)= \dim(B).$$
In the case of a four-term sequence
$$0 \to A \to B \to C \to D \to 0,$$
we get
$$\dim(A) + \dim(C) = \dim(B) +\dim(D).$$
This keeps working for exact sequences of any finite length
$$0 \to A_0 \to A_1 \to \cdots \to A_n \to 0.$$
You would usually write the associated dimensional condition as
$$\sum_k (-1)^k \dim(A_k)=0$$
and say something like "the Euler characteristic of the exact complex is zero".


问:
How to prove a recursive equation with mathematical induction?

Let the sequence $\{a_n\}_{n\ge0}$ be recursively defined as follows:
$$a_0=0,\,\forall k\ge1(a_k=a_{k-1}+2k+1).$$ Using mathematical induction, prove that this sequence satisfies the following equation:$$\forall n\ge0(a_n=n(n+2)).$$

I have done the basis step as shown below, but still struggling to solve the inductive step.

Basis step: for $n=0$, $a_0=0=0(0+2)$.

答: We want to prove if $a_{k-1}=(k-1)(k+1)$ then $a_k=k(k+2)$. By the inductive hypothesis,$$a_k=(k-1)(k+1)+2k+1=\cdots$$


问:
Can you please explain this formula to me?
I am reading a paper about the spreading of something and the author added a formula to sum it up. My problem is, that I never saw a formula in that way of design. I got what the variables mean, but I do not get how to read that. Is the curly bracket meaning, that it is a group of formulas and the variables on the right are dependencies?

Thanks a lot!

答:
The curly brackets mean that it is a piecewise function. Essentially, a piecewise function is a function made out of other functions. You know when to apply each function inside the bracket by looking at the interval provided to the right of each function.

Also, $\exp(x)$ is another way of writing $e^x$


问:
How to prove $\int_0^\infty e^{-x^2}cos(2bx) dx = \frac{\sqrt{\pi}}{2} e^{-b^2}$
I've been grappling for a few hours with this problem ($b$ is a parameter)

$\int_0^\infty e^{-x^2}cos(2bx) dx = \frac{\sqrt{\pi}}{2} e^{-b^2}$

Tried direct integration by parts, differentiation w.r.t. $b$, then integrating... all to no avail.
I think the second approach is the way... Pls help

答:
Contour Integral Method
$$
\begin{align}
\int_0^\infty e^{-x^2}\cos(2bx)\,\mathrm{d}x
&=\frac12\int_{-\infty}^\infty e^{-x^2}\cos(2bx)\,\mathrm{d}x\\
&=\frac12\int_{-\infty}^\infty e^{-x^2}e^{i2bx}\,\mathrm{d}x\\
&=\frac12\int_{-\infty}^\infty e^{-(x-ib)^2}e^{-b^2}\,\mathrm{d}x\\
&=\frac12e^{-b^2}\int_{-\infty-ib}^{\infty-ib}e^{-x^2}\,\mathrm{d}x\\
&=\frac12e^{-b^2}\int_{-\infty}^\infty e^{-x^2}\,\mathrm{d}x\tag{$\ast$}\\
&=\frac{\sqrt\pi}{2}e^{-b^2}
\end{align}
$$
$(\ast)$ is valid since $e^{-z^2}$ has no poles and the integral along the two ends of the infinitely long rectangle between the paths vanishes at $\infty$.

Differential Equation Method
$$
\begin{align}
\frac{\mathrm{d}}{\mathrm{d}b}\int_0^\infty e^{-x^2}\cos(2bx)\,\mathrm{d}x
&=-\int_0^\infty e^{-x^2}2x\sin(2bx)\,\mathrm{d}x\\
&=\int_0^\infty\sin(2bx)\,\mathrm{d}e^{-x^2}\\
&=-2b\int_0^\infty e^{-x^2}\cos(2bx)\,\mathrm{d}x
\end{align}
$$
The solution to $\frac{\mathrm{d}}{\mathrm{d}b}f(b)=-2bf(b)$ is $f(b)=Ce^{-b^2}$. Evaluating at $b=0$ yields $C=\frac{\sqrt\pi}{2}$. Therefore,
$$
\int_0^\infty e^{-x^2}\cos(2bx)\,\mathrm{d}x=\frac{\sqrt\pi}{2}e^{-b^2}
$$


问:
Closed-form of $\mathbb E(\|G\|_\infty)$ where $G\sim\mathcal N(0,\mathbf{Id}_n)$.
Let $I_n = \mathbb E(\|G\|_\infty)$, i.e.
$$I_n = (2\pi)^{-\frac{n}{2}}\int_{x\in\mathbb R^n}\|x\|_\infty e^{-\frac{1}{2}\|x\|_2^2}\,dx.$$
I wonder if I can get its closed-form. By symmetry I got
$$I_n = 2n\sqrt{\frac{2}{\pi}}\int_0^\infty xe^{-x^2}\operatorname{erf}(x)^{n-1}\,dx,$$
and then by integration by parts, for $n\ge2$,
$$I_n = \frac{2\sqrt2}{\pi}n(n-1)\int_0^\infty e^{-2x^2}\operatorname{erf}(x)^{n-2}\,dx,$$
where $\operatorname{erf}$ is the error function.

These two formulas give me

$$I_1 = \sqrt{\frac{2}{\pi}},\quad I_2 = 2\sqrt{\frac{1}{\pi}},\quad I_3 = \frac{12}{\pi\sqrt\pi}\arctan\frac{\sqrt2}{2}.$$

In this step, I think a general closed-form is almost impossible, so I post here to see if anyone has a better approach (at least for $I_4$).

Update

Series expansion of $I_4$:
$$I_4 = \frac{8\sqrt2}{\pi^2}\sum_{n=0}^{\infty}\left(\frac43\right)^n\frac{n!}{(2n+1)!}\,\Gamma(n+3/2)\,{}_2F_1(1/2,-n;3/2;1/4).$$

By the way
$$I_n = \sqrt2n\int_0^1t^{n-1}\operatorname{erf}^{-1}(t)\,dt \,=\!\!\!?\; \sqrt2n\sum_{k=0}^\infty a_k \left(\frac{\sqrt\pi}{2}\right)^{2k+1}\frac1{2k+n+1},$$
where $a_k$ is the $k$-th coefficient of the Maclaurin series of $\operatorname{erf}^{-1}(2x/\sqrt\pi)$ (see InverseErf).

Well, I don't really know the behavior of $(a_k)$, but numerically the series does converge. I don't think this will lead to anything though.

Let me explain a little about this problem.

Imagine we have $n$ points to throw at 0 at the real axis, and the resulted position of one point is determined by $\mathcal N(0,1)$. We want to study the behavior of the farthest distance from 0.

This distance $D = \|G\|_\infty$ is determined by the density function defined below

$$f:x \mapsto n\sqrt{\frac2\pi}\,\exp\left(-\frac{x^2}2\right) \operatorname{erf}^{n-1}\frac{x}{\sqrt2} \mathbb1_{x\ge0}.$$

(For fun one can check that $\int_0^\infty f(x)\,dx=1$.)

And now, what we want to know is, how to calculate $\mathbb E(D)$ (at least when $n=4$)?

@YuriNegometyanov has given a formula for $\mathbb E(\|G\|_2)$. Even though it's not quite the topic, let's write it down as well:

$$\mathbb E(\|G\|_2) =\sqrt2\,\frac{\Gamma\left(\dfrac{n+1}2\right)}{\Gamma\left(\dfrac n2\right)}.$$

A jupyter notebook to calculate numerical results.

So from the series expansion of $I_4$ mentioned above (and tons of calculation), I got:
$$I_4 = \frac{24}{\pi\sqrt\pi}\arctan\frac{1}{2\sqrt2}.$$
This is kind of interesting since the form is similar to $I_3$. Maybe a general closed-form is in fact possible?

答:
$\color{brown}{\textbf{The task statement.}}$

By the symmetry, such integrals can be calculated via integrals over the hyper-octant, i.e. in the forms of
$$M_n = E\big(\|G\|_2\big) = \left(\dfrac2\pi\right)^{\large\frac n2} \int\limits_0^\infty\int\limits_0^\infty\dots\int\limits_0^\infty\int\limits_0^\infty r\, e^{^{\large-\frac12r^2}}\,\text dx_1\,\text dx_2\dots\text dx_{n-1}\text dx_n,\tag1$$

$$I_n = E\big(\|G\|_\infty\big) = \left(\dfrac2\pi\right)^{\large\frac n2} \int\limits_0^\infty\int\limits_0^\infty\dots\int\limits_0^\infty\int\limits_0^\infty \max\limits_{j=1\dots n}\{x_j\}\, e^{^{\large-\frac12r^2}}\,\text dx_1\,\text dx_2\dots\text dx_{n-1}\text dx_n,$$

$$I_n = n!\left(\dfrac2\pi\right)^{\large\frac n2} \int\limits_0^\infty\int\limits_0^\infty\dots\int\limits_0^\infty\int\limits_0^\infty \prod\limits_{j=2\dots n}h(x_{j-1}-x_j) x_1\, e^{^{\large-\frac12r^2}}\,\text dx_1\,\text dx_2\dots\text dx_{n-1}\text dx_n,\tag{2}$$
where $\;h(t)\;$ is the Heaviside transition function.

$\color{brown}{\textbf{The hyperspherical coordinate system.}}$

In the hyperspherical coordinate system
\begin{cases}
x_n=r\cos\varphi_{n-1}\\
x_{n-1} = r\sin\varphi_{n-1}\cos\varphi_{n-2}\\
\dots\\
x_{2} = r\sin\varphi_{n-1}\dots\sin\varphi_{2}\cos\varphi_{1}\\
x_{1} = r\sin\varphi_{n-1}\dots\sin\varphi_{2}\sin\varphi_{1},\tag3
\end{cases}
or
\begin{cases}
x_1=rp_1,\quad x_j=rc_{j-1}p_j,\quad x_n=rc_{n-1},\quad c_j =\cos\varphi_{j},\quad s_j=\sin\varphi_j,\\[4pt]
p_j =\sin\varphi_j\sin\varphi_{j+1}\dots\sin\varphi_{n-1}=q_{j,n-1}, \quad
j=1\dots n-1,\\[4pt]
q^\,_{kl} =\sin\varphi_k\sin\varphi_{k+1}\dots\sin\varphi_l,\quad
\\[4pt]
p^\,_{jk}=(p_j)'_{\varphi_k}=q^\,_{j,k-1}\,c_kp^\,_{j+1},\quad k=j\dots n-1.\tag4
\end{cases}

The Jacobian equals to
$$J=\begin{vmatrix}
rp_{11} & rp_{12} & rp_{13} & rp_{14} & \dots & rp_{1,n-1} & p_1\\
-rp_{1} & rc_1p_{22} & rc_1p_{23} & rc_1p_{24} & \dots & rc_1p_{2,n-1} & c_1p_2\\
0 & -rp_{2} & rc_2p_{33} & rc_2p_{34} & \dots & rc_2p_{3,n-1} & c_2p_3\\
0 & 0 & -rp_{3} & rc_3p_{44} & \dots & rc_3p_{4,n-1} & c_3p_4\\
 & \dots & & & \dots & & \dots\\
0 & 0 & 0 & 0 & \dots & rc_{n-2}p_{n-1,n-1} & c_{n-2}p_{n-1}\\
0 & 0 & 0 & 0 & \dots & -rp_{n-1} & c_{n-1}\tag5
\end{vmatrix},$$
then
$$J= \dfrac{r^{n-1}}{c_1}\prod\limits_{j=1}^{n-2}p_{j+1}
\begin{vmatrix}
c_1 & s_1c_2& q_{12}c_3 &  q_{13}c_4 & \dots & q_{1,n-2}c_{n-1} & p_1\\
-s_1c_1 & c^2_1c_2 & c^2_1s_2c_{3} & c^2_1q_{23}c_4 & \dots & c^2_1q_{2,n-2}c_{n-1} & c_1^2p_2\\
0 & -s_2 & c_2c_3 & c_2s_3c_{4} & \dots & c_2q_{3,n-2}c_{n-1} & c_2p_3\\
0 & 0 & -s_{3} & c_3c_{4} & \dots & c_3q_{4,n-2}c_{n-1} & c_3p_4\\
 & \dots & & & \dots & & \dots\\
0 & 0 & 0 & 0 & \dots & c_{n-2}c_{n-1} & c_{n-2}p_{n-1}\\
0 & 0 & 0 & 0 & \dots & -s_{n-1} & c_{n-1}\\
\end{vmatrix}$$

$$= \dfrac{r^{n-1}}{c_1}\prod\limits_{j=1}^{n-2}p_{j+1}
\begin{vmatrix}
c_1 & s_1c_2& q_{12}c_3 &  q_{13}c_4 & \dots & q_{1,n-2}c_{n-1} & p_1\\
0 & c_2 & s_2c_{3} & q_{23}c_4 & \dots & q_{2,n-2}c_{n-1} & p_2\\
0 & -s_2 & c_2c_3 & c_2s_3c_{4} & \dots & c_2q_{3,n-2}c_{n-1} & c_2p_3\\
0 & 0 & -s_{3} & c_3c_{4} & \dots & c_3q_{4,n-2}c_{n-1} & c_3p_4\\
 & \dots & & & \dots & & \dots\\
0 & 0 & 0 & 0 & \dots & c_{n-2}c_{n-1} & c_{n-2}p_{n-1}\\
0 & 0 & 0 & 0 & \dots & -s_{n-1} & c_{n-1}\\
\end{vmatrix}$$
$$= \dots = r^{n-1}\prod\limits_{j=1}^{n-2}p_{j+1},$$
$$J = r^{n-1}\prod\limits_{j=1}^{n-1}\sin\varphi_j^{j-1}.\tag6$$

$\color{brown}{\textbf{The first integral.}}$

Since
$$A(n)=\int\limits_0^\infty r^n e^{-\frac12r^2}\text dr
= 2^{^{\large\frac{n-1}2}}\Gamma\left(\dfrac{n+1}2\right),\tag7$$

$$\Phi_2(k) = \int\limits_0^{^{\large \frac\pi2}}\,\sin^k\varphi\,\text d\varphi
=\dfrac{\sqrt\pi\, \Gamma\left(\dfrac{k+1}2\right)}{2 \Gamma\left(\dfrac{k+2}2\right)},\tag8$$

then
$$M_n = \left(\dfrac2\pi\right)^{^{\large\frac n2}}A(n)\prod\limits_{k=1}^{n-1}\Phi_2(k-1) = \sqrt2\,\dfrac{\Gamma\left(\dfrac{n+1}2\right)}{\Gamma\left(\dfrac n2\right)}.\tag9$$

$\color{brown}{\mathbf{The\ second\ integral,\ n=1\dots 4.}}$

From $(2),(6)$ should
$$I_1 = \sqrt{\frac2\pi}\,\int\limits_0^\infty xe^{-\frac12x^2}\,\text dx
 = \sqrt{\frac2\pi}\,.\tag{10a}$$
$$I_n = {n!}\left(\dfrac2\pi\right)^{^{\large\frac n2}} A(n)\Phi_\infty(n-1),\tag{11}$$
where
$$\Phi_\infty(k) = \int\limits_{\large ^\pi/_4}^{\large^\pi/_2}
\int\limits_{\text{ arccot }c_1}^{\large^\pi/_2}\;\dots
\int\limits_{\text{ arccot }c_{k-1}}^{\large^\pi/_2} s_1s^2_2\dots s^k_k
\,\text d\varphi_k\dots\,\text d\varphi_2\,\text d\varphi_1, \tag{12}$$
$$\text{ arccot }c_j = \arccos\dfrac{c_j}{\sqrt{1+c_j^2}}
 = \dfrac12 \arccos\dfrac{c_j^2-1}{c_j^2+1}
 = \dfrac12 \arcsin\dfrac{2c_j}{c_j^2+1},\tag{13a}$$
$$\text{ arccot }\dfrac1{\sqrt 2} = \arctan\sqrt 2 = \arccos\dfrac1{\sqrt3} = \dfrac12 \arccos\dfrac13 = \dfrac12 \arcsin\dfrac{2\sqrt2}3,\tag{13b}$$

$$\int \sin^k \varphi \,\text d\varphi =
\begin{cases}
\dfrac{2\varphi-\sin 2\varphi}4\,,\;k=2\\[4pt]
\dfrac{\cos^3\varphi-3\cos\varphi}3\,,\;k=3\\[4pt]
\dfrac{\sin 2\varphi \cos 2\varphi -4\sin 2\varphi+6\varphi}{16}\,,\;k=4.\tag{13c}
\end{cases}
$$

The angle limits should provide the integration over all non-increasing sequences $\;\{x_j\}.$

Then
$$\Phi_\infty(2) = \int\limits_{\large^\pi/_4}^{\large^\pi/_2}\sin\varphi\,\text d\varphi = \dfrac1{\sqrt2},\tag{14b}$$
$$\Phi_\infty(3) = \int\limits_{\large^\pi/_4}^{\large^\pi/_2}
\int\limits_{\text{arccot }c_1}^{\large^\pi/_2}
\sin\varphi_1\sin^2\varphi_2\,\text d\varphi_2\,\text d\varphi_1 \\[4pt] = \int\limits_{\large^\pi/_4}^{\large^\pi/_2}
\dfrac{2\varphi_2 -\sin 2\varphi_2}4
\bigg|_{\text{arccot }c_1}^{\large^\pi/_2}
\sin\varphi_1\,\text d\varphi_1\\[4pt]
= \dfrac12\int\limits_0^{\large^1/_{\sqrt2}}\left(\arctan c_1 + \dfrac {c_1}{1+c_1^2}\right)\,\text dc_1
= \dfrac12 c_1 \arctan c_1\bigg|_0^{\large ^1/{\sqrt2}},$$
$$\Phi_\infty(3)= \dfrac{\text{ arccot }\sqrt2}{2\sqrt2}\tag{14c}$$
(see also WA result),

$$\Phi_\infty(4) = \int\limits_{\large^\pi/_4}^{\large^\pi/_2}
\int\limits_{\text{arccot }c_1}^{\large^\pi/_2}\;
\int\limits_{\text{arccot }c_2}^{\large^\pi/_2}
\sin\varphi_1\sin^2\varphi_2\sin^3\varphi_3
\,\text d\varphi_3\,\text d\varphi_2\,\text d\varphi_1 \\[4pt]
= \int\limits_{\arctan\sqrt2}^{\large^\pi/_2}
\int\limits_{\large^\pi/_4}^{\arccos\cot\varphi_2}\;
\int\limits_{\text{arccot }c_2}^{\large^\pi/_2}
\sin\varphi_1\sin^2\varphi_2\sin^3\varphi_3
\,\text d\varphi_3\,\text d\varphi_1\,\text d\varphi_2\\[4pt]
= \int\limits_{\arctan\sqrt2}^{\large^\pi/_2}
\left(\dfrac1{\sqrt2}-\cot\varphi_2\right)
\dfrac13\left(\cos^3\varphi_3-3\cos\varphi_3\right)\bigg|_{\large \arccos\frac{\cos\varphi_2}{\sqrt{1+\cos^2\varphi_2}}}^{\large^\pi/_2}
\sin^2\varphi_2 \,\text d\varphi_2\\[4pt]
= \dfrac{\sqrt2}6 \left(\arctan\dfrac{\sin y}{\sqrt{2-\sin^2 y}} - \dfrac{\cos^2 y (\sin y - \sqrt2 \cos y)}{\sqrt{2-\sin^2 y}}\right) \bigg|_{\arctan\sqrt2}^{\large^\pi/_2},$$
$$\Phi_\infty(4)= \dfrac{\pi - 4\text{ arccot }\sqrt2}{12\sqrt2}
= \dfrac{\text{arccot }(2\sqrt2)}{6\sqrt2}\tag{14d}$$
(see also WA result).

Therefore,

$$I_2 = 2!\cdot\frac2\pi\,A(2)\Phi_\infty(2)
 = \frac{4}\pi\cdot\sqrt{\frac\pi2}\,\frac1{\sqrt2} = \frac2{\sqrt\pi},\tag{10b}$$

$$I_3 = 3!\cdot\sqrt{\frac8{\pi^3}}\,A(3)\Phi_\infty(3)
 = 12\sqrt{\frac2{\pi^3}}\cdot2\,\dfrac{\text{ arccot }\sqrt2}{2\sqrt2} = \frac{12\text{ arccot }\sqrt2}{\pi\sqrt\pi},\tag{10c}$$

$$I_4 = 4!\cdot\frac4{\pi^2}\,A(4)\Phi_\infty(4)
 = \frac{96}{\pi^2}\cdot3\sqrt{\dfrac\pi2}\,\dfrac{\text{arccot }(2\sqrt2)}{6\sqrt2},$$
$$I_4 = \frac{24\text{ arccot }(2\sqrt2)}{\pi\sqrt\pi}.\tag{10d}$$

$\color{brown}{\mathbf{The\ second\ integral,\ n=5.}}$

Taking in account $(13a-c),$ one can get
$$\Phi_\infty(5) = \int\limits_{\large^\pi/_4}^{\large^\pi/_2}
\int\limits_{\text{arccot }c_1}^{\large^\pi/_2}\;
\int\limits_{\text{arccot }c_2}^{\large^\pi/_2}\;
\int\limits_{\text{arccot }c_3}^{\large^\pi/_2}
\sin\varphi_1\sin^2\varphi_2\sin^3\varphi_3\sin^4\varphi_4
\,\text d\varphi_4\,\text d\varphi_3\,\text d\varphi_2\,\text d\varphi_1 \\[4pt]
= \int\limits_{\arctan\sqrt2}^{\large^\pi/_2}
\int\limits_{\large^\pi/_4}^{\arccos\cot\varphi_2}
\int\limits_{\text{arccot }c_2}^{\large^\pi/_2}\quad
\int\limits_{\text{arccot }c_3}^{\large^\pi/_2}
\sin\varphi_1\sin^2\varphi_2\sin^3\varphi_3\sin^4\varphi_4
\,\text d\varphi_4\,\text d\varphi_3\,\text d\varphi_1\,\text d\varphi_2 \\[4pt]
= \int\limits_{\arctan\sqrt2}^{\large^\pi/_2}\quad
\int\limits_{\text{arccot }c_2}^{\large^\pi/_2}\;
\left(\dfrac1{\sqrt2}-\cot\varphi_2\right)
\dfrac1{16}\left(\sin2\varphi_4\cos2\varphi_4 - 4\sin2\varphi_4 + 6\varphi_4\right)\bigg|_{\text{arccot }c_3}^{\large^\pi/_2}\\
\times\sin^2\varphi_2\sin^3\varphi_3
\,\text d\varphi_3\,\text d\varphi_2\\[4pt]
= \int\limits_{\arctan\sqrt2}^{\large^\pi/_2}\quad
\int\limits_{\text{arccot }c_2}^{\large^\pi/_2}\;
\dfrac{\sqrt2\,\sin^2\varphi_2-\sin2\varphi_2}{16}\\
\times\left(3\arctan\cos\varphi_3+\dfrac{4\cos\varphi_3}{1+\cos^2\varphi_3}
+\dfrac{3\cos\varphi_3\sin^2\varphi_3}{(1+\cos^2\varphi_3)^2}\right) \sin^3\varphi_3\,\text d\varphi_3\,\text d\varphi_2\\[4pt]
= \int\limits_{\large^\pi/_3}^{\large^\pi/_2}\quad
\int\limits_{\arctan\sqrt2}^{\arccos\cot\varphi_3}\;
\dfrac{\sqrt2\,\sin^2\varphi_2-\sin2\varphi_2}{16}\\
\times\left(3\arctan\cos\varphi_3+\dfrac{3\cos\varphi_3}{1+\cos^2\varphi_3}
+\dfrac{2\cos\varphi_3}{(1+\cos^2\varphi_3)^2}\right) \sin^3\varphi_3\,\text d\varphi_2\,\text d\varphi_3\\[4pt]
= \dfrac{\sqrt2}{64}\int\limits_{\large^\pi/_3}^{\large^\pi/_2}\quad
\left(2\varphi_2 - \sin 2\varphi_2 + \sqrt2 \cos 2\varphi_2\right)
\bigg|_{\arctan\sqrt2}^{\arccos\cot\varphi_3}\;
\times\left(3\arctan\cos\varphi_3+\dfrac{3\cos\varphi_3}{1+\cos^2\varphi_3}
+\dfrac{2\cos\varphi_3}{(1+\cos^2\varphi_3)^2}\right) \sin^3\varphi_3\,\text d\varphi_3\\[4pt]
= \dfrac{\sqrt2}{32}\int\limits_{\large^\pi/_3}^{\large^\pi/_2}\quad
\left(\sqrt2\cot^2\varphi_3 - \cot\varphi_3 \sqrt{1-\cot^2\varphi_3} + \arccos \cot\varphi_3 -\arctan\sqrt2\right)
\times\left(3\arctan\cos\varphi_3+\dfrac{3\cos\varphi_3}{1+\cos^2\varphi_3}
+\dfrac{2\cos\varphi_3}{(1+\cos^2\varphi_3)^2}\right) \sin^3\varphi_3\,\text d\varphi_3\\[4pt]
= \dfrac{\sqrt2}{64}\int\limits_{\large^\pi/_3}^{\large^\pi/_2}\quad
\left(\sqrt2\cot^2\varphi_3 - \cot\varphi_3 \sqrt{1-\cot^2\varphi_3} + \arccos \cot\varphi_3 -\arctan\sqrt2\right)
\times\,\text d\left(\cos 2\varphi_3 + 2(\cos^3\varphi_3-3\cos\varphi_3)\arctan\cos\varphi_3+\dfrac{4}{1+\cos^2\varphi_3}\right)$$

(see also WA check),

$$\Phi_\infty(5) \;\overset{\text{IBP}}{=\!=} \;
\dfrac{3\sqrt2 \text{ arccot}\sqrt2}{64} + \dfrac{\sqrt2}{32} \int\limits_{\large^\pi/_3}^{\large^\pi/_2}\quad
\left(\sqrt2\cot\varphi_3 - \sqrt{1-\cot^2\varphi_3}\right)
\times \left(2\cos^2\varphi_3 -1 + 2(\cos^3\varphi_3-3\cos\varphi_3) \arctan\cos\varphi_3+\dfrac{4}{1+\cos^2\varphi_3}\right)\dfrac{\text d\varphi_3}{\sin^2\varphi_3}\\[4pt]
= \dfrac{3\sqrt2 \text{ arccot}\sqrt2}{64} + \dfrac{\sqrt2}{32} \int\limits_0^{\large^1/_2}\quad
\left(\sqrt2c_3 - \sqrt{1-2c^2_3}\right)\\
\times \left(2c^2_3 -1 + 2(c^3_3-3c_3) \arctan c_3+\dfrac{4}{1+c^2_3}\right)\dfrac{\text dc_3}{(1-c^2_3)^2}\\[4pt]
= \dfrac{12\pi + 18\sqrt2 \text{ arccot}\sqrt2 - 8\text{ arccot }2 - 15\sqrt2 \arctan(2\sqrt2) -12\sqrt6 \arctan\sqrt{^3/_2}}{384}\\
 - \dfrac{\sqrt2}{16} \int\limits_0^{\large^1/_2}\quad
\sqrt{1-2c^2_3}(c^3_3-3c_3) \arctan c_3
\dfrac{\text dc_3}{(1-c^2_3)^2},
$$

wherein
$$\int\limits_0^{\large^1/_2}\quad
\sqrt{1-2t^2}(t^3_3-3t) \arctan t
\dfrac{\text dt}{(1-t^2)^2}\\[4pt]
\;\overset{\text{IBP}}{=\!=}
-\dfrac{11\sqrt2\text{ arccot }2}{12} + \dfrac18 ((4\sqrt3-\sqrt2)\pi - 2\arctan(2\sqrt2) - 4\sqrt3\arctan(2\sqrt6))
+ \int\limits_0^{\large^1/_2} \dfrac{t(3 t^2-4)\arctan t}{\sqrt{1 - 2 t^2}(1-t^2)}\,\text dt
=-\dfrac{11\sqrt2\text{ arccot }2}{12} + \dfrac14 ((2\sqrt3+\sqrt2)\pi - \arctan(2\sqrt2) - 2\sqrt3\arctan(2\sqrt6))
 + \dfrac34 (\sqrt2 \text{ arccot }2 - 2\sqrt3 \arctan\sqrt{\dfrac32} - \int \limits_0^{\large^1/_2} \dfrac{t \arctan t}{\sqrt{1 - 2 t^2}(1-t^2)}\,\text dt
,$$

=

$$- \int\limits_0^{\large^1/_2} \dfrac{t \arctan t}{\sqrt{1 - 2 t^2}(1-t^2)}\,\text dt
= \int\limits_{\large^1/_{\sqrt2}}^1 \dfrac{\arctan\sqrt{\dfrac{1-u^2}2}}
{1+u^2}\,\text du
= \int\limits_{\large^1/_{\sqrt2}}^1 \int\limits_{0}^{\large\sqrt{\frac{1-u^2}2}} \dfrac{\text dv\,\text du}{(1+v^2)(1+u^2)}\\[4pt]
= \int\limits_0^{\text{arccot}\sqrt2} \int\limits_{{\large^1/_{\sqrt2}}\sec\psi}^{\large^1/_{\sqrt{\cos^2\psi + 2\sin^2\psi}}} \dfrac{\rho\,\text d\rho\,\text d\psi}{(1+\rho^2\cos^2\psi)(1+\rho^2\sin^2\psi)}\\[4pt]
=\left|\genfrac{}{}{0}{}{s=\rho^{-2},}{w = 2\psi}\right|
= \int\limits_0^{2\text{ arccot}\sqrt2} \int\limits_{\frac12(3-\cos w)}^{1+\cos w} \dfrac{\text ds\,\text dw}{(1+2s)^2-\cos^2w}\\[4pt]
= \dfrac14\int\limits_0^{2\text{ arccot}\sqrt2} (\ln4 - \ln(4-2\cos w) + \ln(3+\cos w)-\ln(3+3\cos w)) \dfrac{\text dw}{\cos w}\\[4pt]
= \dfrac14\int\limits_0^{2\text{ arccot}\sqrt2} (- \ln(1-\frac12\cos w) + \ln(1+\frac13\cos w)-\ln(1+\cos w)) \dfrac{\text dw}{\cos w}\\[4pt]
=|w=2\arctan q|
=\int\limits_0^{\large^1/_{\sqrt2}} (\ln(1+q^2)+\ln(2+q^2)+\ln 2-\ln(3+q^2)-\ln 3)\dfrac{dq}{2-2q^2}\\[4pt]
=J\left(\dfrac1{\sqrt2}\right)- J(0)\approx 0.05721\,19956\,66783\,53930\,89922\,14090\,04283\,86906\,04
,$$
wherein splitting both of the numerator and the denominator leads to the heavy  closed form of the antiderivative $\;J(q),$

Therefore,
$$\Phi_\infty(5)\approx 0.00505\,68737\,62649\,75165\,77798\,44133\,63992\,99350\,04542,\tag{14e}$$

$$I_5 = 5!\cdot\sqrt{\frac{32}{\pi^5}}\,A(5)\Phi_\infty(5)
 = 480\sqrt{\frac2{\pi^5}}\cdot8\,\Phi_\infty(5),$$
$$I_5\approx 1.56983\,37172\,15214\,46376\,24670\,41826\,20871\,99091.\tag{10e}$$


答: If $r$ and $s$ are rational numbers and $r<s$, there are integers $k$ and $l$ and a natural number $t$ such that $r=\frac kt$, that $s=\frac lt$, and that $k<l$. So$$a^r=a^{k/t}=\sqrt[t]{a^r}\quad\text{and}\quad a^s=a^{k/t}=\sqrt[t]{a^l}.$$And, since $k<l$, $a^r<a^l$, and therefore $\sqrt[t]{a^r}<\sqrt[t]{a^l}$.

Title: A proof for If $a>0$ AND $r<s$ then: $a>1⇔a^r<a^s$ without using the natural logarithm function?

Body:
We have $a$ is a real positive number different than zero.

$r$ and $s$ belong both to $\mathbb{Q}$

$(r<s)$ AND $(a^r<a^s)$
⇔ $(r<s)$ AND $(ln(a^r)<ln(a^s))$
⇔ $(r<s)$ AND $(r.ln(a)<s.ln(a))$

On the other hand we have:

$a>1⇔ln(a)>ln(1)⇔ln(a)>0$

which means that:

r.$ln(a)<s.ln(a) ⇔ r<s$ because $ln(a)>0$

This can be summarized as follows:

If $a>0$ AND $r<s$ then:

$a>1⇔a^r<a^s$

Is there any other proof for:
If $a>0$ AND $r<s$ then: $a>1⇔a^r<a^s$
without using the natural logarithm function $ln$?

This was my answer for someone asking for a proof here

Unfortunately he needed a proof without using the $ln$ function.


问:
Subordiance of $\ell_{\infty}$ norm: $\Vert Ax \Vert_{\infty} \leq \Vert A\Vert_{\infty}\Vert x\Vert_{\infty}$
For a matrix $A \in \mathbb{R}^{n\times n}$ (if it matters, is invertible) and a vector $x \in \mathbb{R}^{n}$, do we have in general that $\Vert Ax \Vert_{\infty} \leq \Vert A\Vert_{\infty}\Vert x\Vert_{\infty}$? From this page I think the answer is no for entry-wise matrix norm and yes for the induced matrix norm.

I came upon a paper that suggests this inequality holds (without specifying whether the matrix norm used is the induced norm or the entry-wise norm) to prove a lemma but skipped some steps. The vector $x$ here is in the interior of the norm ball $\mathcal{B} = \{v \in \mathbb{R}^n \,\vert \, \Vert v \Vert_{\infty} \leq 1\}$.

答:
$$A=\begin{bmatrix} 1 & 1 \\
1 &1 \end{bmatrix}$$
And $x= \begin{bmatrix} 1 \ 1 \end{bmatrix}$$

Show that this is not true for the entrywise matrix norm.

The definition of the operator norm is $\| A \|_\infty$ is the smallest number such that for all $x$ you have
$$\Vert Ax \Vert_{\infty} \leq \Vert A\Vert_{\infty}\Vert x\Vert_{\infty}$$
so yes, the inequality holds for the operator norm. When written in this inequality form, it usually means the operator norm.


问:
Fundamental group of a bouquet of circles
Consider a bouquet of $n$ circles, centered at $(1,0), (2,0),...,(n,0)$ $$ W_n= \bigcup_1^nC_r$$ with $$C_r:(x-r)^2+y^2=r^2$$

I want to compute the fundamental group of this space.

$W_n$ is path connected. Moreover I know
$\pi_1(W_1)=\pi_1(C_1)=\mathbb{Z}.$ Seeing $W_n= W_{n-1}\cup C_n$ we
have both $W_{n-1}$ and $C_n$ are path connected and open. Moreover
$W_{n-1} \cap C_n $ is just the origin which has trivial fundamental
group. Hence
$$\pi(W_n)=\pi(W_{n-1})*\pi(C_1)=\pi(W_{n-1})*\mathbb{Z}=...=\pi_1(W_1)*\mathbb{Z}...*\mathbb{Z}=$$$$\pi(C_1)*\mathbb{Z}*...*\mathbb{Z}=\mathbb{Z}*...*\mathbb{Z}$$
so it is the $n$-times free product of $\mathbb{Z}$ with itself.

Does it work? First I want to know if my solution is correct and only secondly a different one thanks.

答: Your answer is wrong, for example, it is not very difficult to see that this fundamental group is not abelian. A way to compute that is to show that the space $W_n$ is homotopy equivalent to the wedge sum of $n$ circles and then use the Seifert-Van Kampen theorem to show that its fundamental group is the free group with $n$ generators.


问:
Basic Mathematics. Trouble with proof, powers and odd numbers.
Greets,

In the exercises, at the end of chapter 1.4, Basic Mathematics, Serge Lang

6) Prove: If $n$ is odd, then $\quad (-1)^n = -1$

How?
The working I did

$$\begin{align}( -1)^n &= ( -1 )^{2m+1}\\
  &= ( ( -1)^2 )^{m+1}\\
  &= ( ( -1 )( -1 ) )^{m+1}\\
  &= ( 1 )^{m+1} \end{align}$$

Can it get from here to $-1$?

The book shows

Let  $n =  2k + 1$. Then

$$\begin{align}(-1)^n  &= (-1)^{2k+1}\\
   &= (-1)^{2k}(-1)\\
   &= 1 \cdot (-1)\\
   &= -1 \end{align}$$

I'm having trouble with how $(-1)^{2k+1}$ became $(-1)^{2k}(-1)$.

答:
$( -1)^n = ( -1 )^{2m+1}
  \color{red}= ( ( -1)^2 )^{m+1}$

Wrong. Note that $2(m+1)=2m+2$.

$(-1)^n  = (-1)^{2k+1}
   \color{blue}= (-1)^{2k}(-1)$, for the blue equality, answer this question: how do you define $p^q$, where $p,q\in \Bbb Z$ and $q>0$?


问:
Two questions of first and second category sets in complete metric spaces
On the proof of

If $X$ is a complete metric space, then any dense $G_\delta$ in $X$ is residual in $X$.

I'm confused on how to prove this statement. $G_\delta = \cap_{n=1}^\infty U_n$ where every $U_n$ is an open set. If every $U_n$ where dense, then it would be easy to see that the complement of $G_\delta$ is of first category. However, if $X=\overline{G}_{\delta}=\overline{\cap_{n=1}^\infty U_n}$, it doesn't seem correct to conclude that every $U_n$ by itself is dense.

On the proof of

Let $X$ be a (nonvoid) complete metric space and $E$ a residual set in $X$. Then $E$ is of second category in $X$. IN particular, $X$ is of second category in itself.

Proof: Assume that $E$ is of first category in $X$. Then $X = E\cup E^c$, being a countable union of nowhere dense sets (proof continues)

Why $E^c$ has to be of first category in this case? For example in $\mathbb{R}$, the rationals are of first category but the irrationals are of second category and they are the complement of $\mathbb{Q}$.

Perhaps what is meant is  $E\cup \lbrace {\rm limit\; points\; of\; } E\rbrace$? In this case either why these limit points could be a nowhere dense set?

答:
If $D\subseteq E\subseteq X$, and $D$ is dense in $X$, then $E$ is dense in $X$: if $x\in X$, and $U$ is an open nbhd of $x$, then $U\cap E\supseteq U\cap D\ne\varnothing$, so $x\in\operatorname{cl}E$, and hence $\operatorname{cl}E=X$. (This is even easier to see if you realize that a set $D$ is dense in $X$ iff $U\cap D\ne\varnothing$ for each non-empty open $U\subseteq X$.) Thus, all of the open sets $U_n$ in your setting are dense in $X$.

For your second question, the residual sets are by definition the complements of first category sets, and $E$ is residual, so $X\setminus E$ is first category. You’re quite right that in this setting $X\setminus E$ cannot in fact be of first category, but that is the point of the proof: we assume that $E$ is of first category and derive a contradiction.


问:
Z-test and Chi squared test producing different p-values
Given that I'm doing A/B testing for conversion rate on two groups, where group A has 6000 samples of which 90 are conversions, and group B has 4000 samples of which 80 are conversions. I want to know if group B has a statistically higher conversion rate.

I seemingly get a different answer depending on if I use a Z-test or Chi squared test and alpha = 0.5. Z-test returns a p-value of 0.0327 whereas Chi squared gives a p-value of 0.058.

The problem originates from https://towardsdatascience.com/the-art-of-a-b-testing-5a10c9bb70a4 , and trying it on my own I get the same values as in the article. The author attempts to explain the discrepancy by saying the Z-test doesn't take into account that the random variable of the difference of the mean is restricted to [-1, 1] but I don't really follow.

I was under the impression that these tests are equivalent for this type of problem, so why do they return different p-values?

Thanks.

Edit: As @BruceET suspected I was doing a two sided chi squared test, which obviously doesn't give the same p-value as the Z-test (or T-test to be more accurate..) for proportions. As was also pointed out I wasn't clear in how i was estimating the variances which was another problem. The method used in the article I followed was Welch's T-test (i.e. T-test without pooling variances). If I use the "exact" variance=mean*(1-mean)*(1/n_A + 1/n_B) where the mean is over both A and B, the p-value is 0.29, exactly half of that of the Chi squared test. I suspect I'll get something close to it if I use a pooled variance, but not tried it.

答:
I realize that this is not a direct answer to your question. However, using two fundamentally different procedures that I trust, I do not find any
conflict in the results. [My guess is that your 'z-test' may be one-sided and your 'chi-squared test' two-sided.]

Data:

```<code>conv = c(90,80)
size = c(6000, 4000)
nonc = size - conv
MAT = rbind(conv,nonc)

MAT
     [,1] [,2]
conv   90   80
nonc 5910 3920
</code>```

One-sided Fisher Exact test:

```<code>fisher.test(MAT, alt="less")

         Fisher's Exact Test for Count Data

data:  MAT
p-value = 0.03543
alternative hypothesis:
  true odds ratio is less than 1
95 percent confidence interval:
 0.00000 0.97505
sample estimates:
odds ratio
 0.7462279
</code>```

One-sided test of $p_A = p_B$ against $p_A < p_B:$

```<code>prop.test(conv, size, alt="less")

        2-sample test for equality of proportions
        with continuity correction

data:  conv out of size
X-squared = 3.2975, df = 1, p-value = 0.03469
alternative hypothesis: less
95 percent confidence interval:
 -1.0000000000 -0.0003285328    # Does not incl 0

sample estimates:
prop 1 prop 2
 0.015  0.020
</code>```

Two-sided chi-squared contingency test. (Irrelevant because you say you want a one-sided test, but this test is inherently two-sided.)

```<code>chisq.test(MAT, cor=F)

        Pearson's Chi-squared test

data:  MAT
X-squared = 3.5904, df = 1, p-value = 0.05811
</code>```

Body:
I realize that this is not a direct answer to your question. However, using two fundamentally different procedures that I trust, I do not find any
conflict in the results. [My guess is that your 'z-test' may be one-sided and your 'chi-squared test' two-sided.]

Data:

conv = c(90,80)
size = c(6000, 4000)
nonc = size - conv
MAT = rbind(conv,nonc)

MAT
     [,1] [,2]
conv   90   80
nonc 5910 3920

One-sided Fisher Exact test:

fisher.test(MAT, alt="less")

         Fisher's Exact Test for Count Data

data:  MAT
p-value = 0.03543
alternative hypothesis:
  true odds ratio is less than 1
95 percent confidence interval:
 0.00000 0.97505
sample estimates:
odds ratio
 0.7462279

One-sided test of $p_A = p_B$ against $p_A < p_B:$

prop.test(conv, size, alt="less")

        2-sample test for equality of proportions
        with continuity correction

data:  conv out of size
X-squared = 3.2975, df = 1, p-value = 0.03469
alternative hypothesis: less
95 percent confidence interval:
 -1.0000000000 -0.0003285328    # Does not incl 0

sample estimates:
prop 1 prop 2
 0.015  0.020

Two-sided chi-squared contingency test. (Irrelevant because you say you want a one-sided test, but this test is inherently two-sided.)

chisq.test(MAT, cor=F)

        Pearson's Chi-squared test

data:  MAT
X-squared = 3.5904, df = 1, p-value = 0.05811


问:
Can we rely on Confidence Intervals?
Suppose the mean is in (7.6,8.4) with 95% confidence. I understand that this means 95% of the confidence intervals from different samples will contain the population mean. But, what is the significance of this particular interval on its own. Since I am sure that 95% of sampling intervals will contain the mean can I be somewhat certain that this interval is one of them? If not, how is this interval useful at all to me?

In other words, how sure can I be that mean is in (7.6,8.4) and if I can't be sure then what's the use of this?

答:
I'd like to question your premise. What does "somewhat certain" mean to you? $95\%$ confidence that your interval contains the mean? What about $99\%?$ $99.99999\%?$

To answer your question, we can find the interval containing the mean to any arbitrary degree of confidence. However, there's a cost you need to pay for an increased probability. Either you can:

$\textbf{1.}$ Increase the sample size $n$, or

$\textbf{2.}$ Increase the radius of your confidence interval.

In particular, we achieve precisely $100\%$ confidence when either:

$\textbf{1)}$ $n$ equals the population size, or

$\textbf{2)}$ Your confidence interval is the interval $(-\infty, \infty).$

You can probably see though why these scenarios are not ideal in practice. It defeats the purpose of using statistics. The beauty of statistics is that it can tell us  useful information about what we don't know, rather than what we already do.

If you'd like to use statistics to determine the mean with perfect certainty, then you are in fact using the wrong tool, because statistics is the study of uncertainty.

Title: Can we rely on Confidence Intervals?


问:
Equivalence relation on the disjoint union of all sections of a presheaf - verify transitivity
Let $X$ be a topological space and associate to each open subset $U \subset X$ a set $S(U)$ in such a way that whenever $V \subset U$ is another open subset the so called restriction maps $\rho_V^U \colon S(U) \to S(V)$ satisfy the condition $$\rho_W^V \circ \rho_V^U = \rho_V^U \qquad \rho_U^U = \text{id}_U$$ for all open $W \subset V \subset U$. The collection $S = \{S(U), \rho_V^U\}$ is then called a presheaf on $X$. Now given a presheaf $S = \{S(U), \rho_V^U\}$ we may consider the disjoint union $$\mathcal{U}_x = \bigsqcup\limits_{U \ni x} S(U)$$ where the union is taken over all open subsets $U$ which contain $x \in X$. For $f \in S(U)$ and $g \in S(V)$ define the relation $$f \sim g \iff \exists x \in W \subset U \cap V \colon \rho_W^U(f) = \rho_W^V(g)$$
Quite evidently this relation is reflexive and symmetric. However, why does it satisfy transitivity? If $h \in S(N)$ such that $f \sim g$ and $g \sim h$, then by assumption there are open neighborhoods $W_1, W_2 \subset X$ of $x$ such that $\rho_{W_1}^U(f) = \rho_{W_1}^V(g)$ and $\rho_{W_2}^V(g) = \rho_{W_2}^N(h)$. Setting $W = W_1 \cap W_2$, I guess the idea would be $$\rho_W^U(f) = \rho_W^{W_1} \circ \rho_{W_1}^U(f) = \rho_W^{W_1}(\rho_{W_2}^V(g)) \underset{\text{Is this valid?}}{=} \rho_W^{W_2} \circ \rho_{W_2}^{V}(g) = \rho_W^{W_2} \circ \rho_{W_2}^{N}(h) = \rho_W^N(h)$$ I don't quite see how one could justify the transition from $W_1$ to $W_2$ in the upper index of $\rho$. I either probably overlook something completely trivial, or I am just mistaken (or both), so I guess the question is:

How to properly show transitivity of this relation?

答:
You missed a single step:
$$\begin{align}\rho^U_W(f)&=\rho^{W_1}_W(\rho^U_{W_1}(f))&\text{composition of restrictions}\\
&=\rho^{W_1}_W(\rho^V_{W_1}(g))&\text{assumption $f\sim g$}\\
&\color{red}{=\rho^{V}_W(g)}&\text{composition of restrictions}\\
&=\rho^{W_2}_W(\rho^V_{W_2}(g))&\text{composition of restrictions}\\
&=\rho^{W_2}_W(\rho^N_{W_2}(h))&\text{assumption $g\sim h$}\\
&=\rho^N_{W}(h)&\text{composition of restrictions}\\
\end{align}$$

In fact, one clearly has that sections that are equal after restriction are still equal after stronger restriction.


问:
Showing that $45083$ is prime
The question is:

Does $\;x^2 + 10x + 15 = 0\pmod{45083}\;$ have a solution?

I can rearrange this to $(x+5)^2 = 10\pmod {45083} \;$ so if I can show that $10$ has a  square root mod 45083, I'm done.

If I can show that $45083$ is prime then I can use Legendre symbols and the Law of Quadratic Reciprocity to complete the question.

I don't know how to show that 45083 is prime. I don't think Wilson's theorem is practical. Trial division takes a very long time.

Maybe there is another way?

Title: Showing that $45083$ is prime

Body:
Indeed $\,45,083\,$ is a prime, so by the QRT:

$$\left(\frac{10}{45083}\right)=\left(\frac{2}{45083}\right)\left(\frac{5}{45083}\right)\stackrel{45083\neq\pm 1\pmod 8}=-\left(\frac{3}5\right)=-(-1)=1$$


问:
What is the logic-level interpretation of $r<s<t$?
Consider the two following statements, where $\epsilon$ is a positive real number and $a,b \in \mathbb R$.

$|a-b| \leq \epsilon$

$|a-b| \geq \epsilon$

The absolute value function $|*|$ is defined as $$
|x|=
\begin{cases}
-x&\text{if } x < 0\\
x&\text{if } x\geq 0
\end{cases}
$$

Applying the definition of the absolute value function to the first statement (1), we produce two sub-statements:

A1) $a-b \geq 0 \implies a-b \leq \epsilon$

B1) $a-b \lt 0 \implies -(a-b) \leq \epsilon \iff a-b \geq -\epsilon$

In the same manner, we can produce two sub-statements for the second statement (2):

A2) $a-b \geq 0 \implies a-b \geq \epsilon$

B2) $a-b \lt 0 \implies -(a-b) \geq \epsilon \iff a-b \leq -\epsilon$

In the case of A1 and B1, I often see these two sub-statements combined in the following manner:

$-\epsilon \leq a-b \leq \epsilon$

In the case of A2 and B2, I have only seen the phrase: "Either $a-b \geq \epsilon \ $ OR $\ a-b \leq -\epsilon$."

I have always interpreted a structure like $r<s<t$ to mean that $s$ is greater than $r$ AND $s$ is less than $t$. However, should I instead be reading "$-\epsilon \leq a-b \leq \epsilon$" as $a-b$ is less than or equal to $\epsilon$ OR $a-b$ is greater than or equal to $-\epsilon$...such as is done with the second statement?

I can visualize the picture of the solution sets for the first statement (1) being "continuous" (i.e. the two solution sets for $a-b \geq 0$ and $a-b \lt 0$ touch each other )...and I can visualize the picture of the solution sets for the second statement (2) being disjoint (i.e. the two solution sets do not touch each other and are separated by $2\epsilon$)...but I'm not really sure if this is useful.

My question is thus: At the logic level, how should I interpret the inequality: $r<s<t$?

答:
Notation like "$u<v<w$" does indeed mean a conjunction of inequalities. But this doesn't cause any tension with $(2)$: the expression in $(2)$ simply can't be put in that form, because it doesn't describe the right "shape."

I'm going to get rid of the $a-b$ stuff in the interests of simplicity. Let's just consider the statements "$\vert x\vert\le y$" and "$\vert x\vert \ge y$," which I'll call "$(1)$" and "$(2)$" respectively.

We have, assuming $y>0$, that:

$(1)$ is equivalent to "if $x\ge 0$ then $x\le y$ and if $x<0$ then $x\ge -y$."

$(2)$ is equivalent to "if $x\ge 0$ then $x\ge y$ and if $x<0$ then $x\le -y$."

You've correctly observed this. However, despite their apparent similarity they do not actually behave similarly.

To see this, let's write them in terms of intervals:

$(1)$ is equivalent to "Either $x\in [0,y]$ or $x\in [-y,0)$."

$(2)$ is equivalent to "Either $x\in [y,\infty)$ or $x\in (-\infty, -y]$."

That is, each of $(1)$ and $(2)$ picks out a "possibility set" for $x$ in terms of $y$. But these two possibility sets are quite different: the former is $[0,y]\cup [-y,0)=[-y,y]$, whereas the latter is $(-\infty, -y]\cup[y,\infty)$ which is not simplifiable to a single interval. Notation like "$u\le v\le w$" says "$v$ is in the interval $[u,w]$," but that notation isn't applicable in $(2)$ since the possibility set isn't an interval.


问:
What is $1 \div 2 \times 2$?
In the UK, the abbreviation BIDMAS/BODMAS is used to remember the order of mathematical calculations:

Brackets

Indices / Others

Division

Multiplication

Addition

Subtraction

In the USA, the abbreviation PEMDAS is used instead:

Parenthesis

Exponents

Multiplication

Division

Addition

Subtraction

In the UK, division is first, followed by multiplication, but this order is reversed in the USA.

It seems to me that this can result in different answers for the same question, for example

What is $1 \div 2 \times 2$?

In the UK, with BIDMAS/BODMAS, division is performed first:

\begin{align}
1 \div 2 \times 2 &= 0.5 \times 2 \\
&= 1
\end{align}

Whereas in the USA, with PEMDAS, multiplication is performed first:

\begin{align}
1 \div 2 \times 2 &= 1 \div 4 \\
&= 0.25
\end{align}

So what is the actual value of $1 \div 2 \times 2$? Or am I misunderstanding something?

答: In the USA, the M/D and A/S in PEMDAS are treated as single entities. They should be calculated from left to right, as they would be in the UK. PEMDAS is not a perfect method of understanding order of operations, and it can be confusing for those who are first learning it.</p>

Title: What is $1 \div 2 \times 2$?


问:
Is there a sequence of vertices for which this greedy coloring algorithm works?
Let $G$ be a finite graph and $X$ be a set of $\chi(G)$ colors.

Consider the following algorithm:

In the $i-$th step, we color the $i-$th vertex of $G$ with a random color of $X$ different of the colors of it's neighbors.

If any of the steps cannot be performed, the algorithm fails. If all vertices can be colored, the algorithm succeeds

Is it possible to order the vertices of $G$ in such a way that this algorithm always succeeds? What if $X$ has $\chi(G)+1$ colors?

This post is an attempt to generalize this problem.

答:
The triangular prism graph is a counterexample.

By Brooks' theorem, the triangular prism graph $G$ has $\chi(G)=3$. However, no matter which vertex $v$ is left for last in the ordering, there is a proper coloring of $G-v$ that gives $v$'s three neighbors different colors, leaving no color for $v$. (And no matter how the vertices before $v$ are ordered, that proper coloring of $G-v$ is one of the possible outcomes of coloring them.)

Since $G$ is vertex-transitive, it's enough to demonstrate this for one choice of $v$, which I've done below:

For a counterexample if $\chi(G)+1$ colors are available, consider the circulant graph below, with $9$ vertices arranged in a circle, and edges between vertices $1$ or $2$ steps apart.

This has chromatic number $3$ (by a mod $3$ coloring around the circle). However, if $4$ colors are available, then it's possible to color the first $8$ vertices (no matter which $8$ vertices they are) so that all $4$ colors are used on the neighbors of the last vertex.

Again, since the graph is vertex-transitive, it's enough to demonstrate this for one choice of last vertex, which I've done below:

One final note: this problem is not really equivalent to the $2$-player game in the linked question about planar graphs.

In the $2$-player game, the sequence is not specified in advance: player A can look at the first few colors chosen by player B, and then decide which vertex to ask player B to color next. This makes the game easier for player A (and harder for player B).

If the sequence had to be specified in advance, player A would lose on some planar graphs, even with $5$ colors available. For example, here is a proof in the same style as above for the icosahedral graph:

However, all planar graphs have a sequence which guarantees a $6$-coloring, by putting the vertices in an order such that each vertex has at most $5$ predecessors.


答:
You made an error in the 2nd equality. The relevant property of exponentiation here is:
$$
a^{m+n}=a^m a^n
$$</p>

Title: Basic Mathematics. Trouble with proof, powers and odd numbers.

Body:
Greets,

In the exercises, at the end of chapter 1.4, Basic Mathematics, Serge Lang

6) Prove: If $n$ is odd, then $\quad (-1)^n = -1$

How?
The working I did

$$\begin{align}( -1)^n &= ( -1 )^{2m+1}\\
  &= ( ( -1)^2 )^{m+1}\\
  &= ( ( -1 )( -1 ) )^{m+1}\\
  &= ( 1 )^{m+1} \end{align}$$

Can it get from here to $-1$?

The book shows

Let  $n =  2k + 1$. Then

$$\begin{align}(-1)^n  &= (-1)^{2k+1}\\
   &= (-1)^{2k}(-1)\\
   &= 1 \cdot (-1)\\
   &= -1 \end{align}$$

I'm having trouble with how $(-1)^{2k+1}$ became $(-1)^{2k}(-1)$.


问:
Does $\mathbb{Q}^n$ have larger cardinality than the set $\{(a_1,a_2,...) : a_i ∈ \mathbb{Z}\}$?
Define $A = \{(a_1,a_2,...) : a_i ∈ \mathbb{Z}\ , \forall \ i\}$, which represents the set of integer sequences, and let $\mathbb{Q}^n$ represet the set of size $n$ tuples of the rationals

Both are uncountable, but does one of these sets have cardinality greater than the other set?

答: $\mathbb{Q}^n$ is countable and $A$ is uncountable.


问:
Show $X(1)<\infty$ given $X'(t) = \sigma(K(t)X(t) + b(t))$, and $\sigma(x)\leq C\Vert x \Vert$.
Given that $\sigma(x)\leq C\Vert x \Vert$ (Lipschitz continuous) I want to show that $\Vert X(1)\Vert<\infty$. We know that $X(t)$ satisfies
$$
X'(t) = \sigma(K(t)X(t) + b(t)),
$$

where $X: [0,1] \to \mathbb{R}^d, K\in H^1([0,1],\mathbb{R}^{d\times d}), b\in H^1([0,1], \mathbb{R}^d)$ and $X(0)=x\in\mathbb{R}^d$.

I heard about Picard-Lindelöf, and it seems similar, but it doesn't quite fit, since we have that $\sigma(K(t)X(t)+b(t) \leq C\Big\Vert K(t)X(t)+b(t)\Big\Vert$. So if we would rewrite as $X'(t)=f(t, X(t))$, we don't have that the Lipschitz constant only depends on $X(t)$, but also on $t$ (in $K$ and $b$).

I'm also not even sure if I need the differential equation, since I only need to know that $\Vert X(1)\Vert <\infty$.

答:
Integrating the equation gives
$$
X(t)-X(0) = \int_0^t\sigma(K(s)X(s) + b(s))ds
$$
and hence
$$ \|X(t)\|\le\|X(0)\|+C\int_0^t\bigg[\|K(s)\|\|X(s)\|+\|b(s)\|\bigg]ds. \tag{1} $$
Let
$$ u(t)=\|X(t)\|, \alpha=\|X(0)\|+\int_0^t \|b(s)\|ds, \beta(t)=\|K(s)\| $$
and then (1) becomes
$$ u(t)\le \alpha(t)+\int_0^t\beta(s)u(s)ds. \tag{2}$$
It is easy to see that $\alpha(t)$ is non-decreasing. By Gronwall's Inequality https://en.wikipedia.org/wiki/Gr%C3%B6nwall%27s_inequality, one has
$$ u(t)\le \alpha(t)\exp\left(\int_0^t\beta(s)ds\right) $$
and hence
$$ \|X(1)\|\le\left(\|X(0)\|+\int_0^1 \|b(s)\|ds\right) \exp\left(\int_0^1\|K(s)\|(s)ds\right)<\infty.$$


问:
If $φ:\mathbb R^d→ℂ∖\{0\}$ is continuous and $\varphi(0)=1$, then there is an unique continuous $f:\mathbb R^d→ℂ$ with $f(0)=0$ and $\varphi=e^f$
It's been a long time, since I thought about complex analysis, so please bear with me, if this is a rather trivial question.

I've read that if $\varphi:\mathbb R^d\to\mathbb C\setminus\{0\}$ is continuous and $\varphi(0)=1$, then there is an unique continuous $f:\mathbb R^d\to\mathbb C$ with $f(0)=0$ and $\varphi=e^f$. How can we prove that?

I vaguely remember branches of the complex logarithm from complex analysis, but I don't know whether or not this concept is needed here.

答:
Since $\mathbb{R}^d$ is simply connected, it suffices to note that $(\mathbb{C},e^z)$ is a covering (actually the universal covering) of $\mathbb{C}-\{0\}$. Once you've done that, the result follows from the lifting lemma.

One does not need it to prove uniqueness though: it suffices to note that given two different functions $f_1,f_2$ such that $\varphi=e^{f_1}=e^{f_2}; f_1(0)=f_2(0)=0$, then $f_1-f_2\in 2\pi i\mathbb{Z}$, which is discrete, and since $f_1-f_2$ is continuous on $\mathbb{R}^d$ (connected) it must be constant and thus $0$


问:
Find the $\frac{\mathrm{d} y}{\mathrm{d} x}$ of $ \arcsin (x \sqrt{1-x} - \sqrt{x}\sqrt{1-x^2})$
I tried to solve this question first by trigonometric substitution like putting $x =\sin^2{\theta}$ but this complicated the calculation. Is there any simple technique to solve this question. The answer to this problem is $\frac{1}{\sqrt{1-x^2}}-\frac{1}{2\sqrt{x-x^2}}$

答:
I wouldn't call this much of a shortcut, but it does make the computation a bit cleaner.

Let $\cos\alpha=x$ and $\sin\alpha=\sqrt{1-x^2}$. So

$$x\sqrt{1-x}-\sqrt x\sqrt{1-x^2}=\cos\alpha\sqrt{1-\cos\alpha}-\sqrt{\cos\alpha}\sin\alpha$$

Now, let $\sin\beta=\sqrt{1-\cos\alpha}$ and $\cos\beta=\sqrt{\cos\alpha}$. Notice that $\sin^2\beta+\cos^2\beta=1$ holds. So really, we have

$$\begin{align}
x\sqrt{1-x}-\sqrt x\sqrt{1-x^2}&=\cos\alpha\sin\beta-\cos\beta\sin\alpha\\[1ex]
&=\sin(\beta-\alpha)
\end{align}$$

which reduces the original function to $y=\beta-\alpha$ (on an appropriate domain). Thus

$$\frac{\mathrm dy}{\mathrm dx}=\frac{\mathrm d\beta}{\mathrm dx}-\frac{\mathrm d\alpha}{\mathrm dx}$$

Compute the remaining derivatives using $\cos\beta=\sqrt{\cos\alpha}=\sqrt x$ and $\cos\alpha=x$ along with the chain rule:

$$\begin{align}
\cos\alpha=x\implies-\sin\alpha\frac{\mathrm d\alpha}{\mathrm dx}&=1\\[1ex]\frac{\mathrm d\alpha}{\mathrm dx}&=-\csc\alpha\\[1ex]
\frac{\mathrm d\alpha}{\mathrm dx}&=-\frac1{\sqrt{1-x^2}}\end{align}$$

$$\begin{align}\cos\beta=\sqrt x\implies-\sin\beta\frac{\mathrm d\beta}{\mathrm dx}&=\frac1{2\sqrt x}\\[1ex]\frac{\mathrm d\beta}{\mathrm dx}&=-\frac{\csc\beta}{2\sqrt x}\\[1ex]\frac{\mathrm d\beta}{\mathrm dx}&=-\frac1{2\sqrt x\sqrt{1-x^2}}\end{align}$$


问:
Compute the PVM (Projection Valued Measure) of Parity Operator
This question is duplicate of the question Find projection-valued measure associated with parity operator.\

But in that question @Jacky Chong does not state how he found the operator
\begin{align}
P_\pi(\lambda) =P_{\pi}((-\infty,\lambda]) =\delta(\lambda-1)P_\text{even}+\delta(\lambda+1)P_\text{odd}
\end{align}

Also we know that $P(R)=Id \enspace$ or we should have $P(\lambda_1)\leq P(\lambda_2)$  for  $\lambda_1 < \lambda _2$ but if we put 2 and 1 into the $P_{\pi}$ we get $0:L^2\rightarrow L^2$ and $P_{even}$ resp.

My question is could someone explain me how to find $P_{\pi}$ explicitly using maybe Stieltjes inversion formula or something else

Notes:

(1) I need 50 reps to comment on the problem i linked

(2) I already found the spectrum and resolvent of parity operator.They're  $$\sigma(\Pi)=\{1,-1\} \enspace R_{\Pi}(z)=\frac{\Pi+zI}{1-z^2}$$
(3) This is Problem 3.2 from Teschl G. - Mathematical methods in quantum mechanics

答:
This is simply the standard way of writing a finite sum as an integral relative to a corresponding atomic measure. In particular: if the operator in question can be written as a countable sum
$$
A = \sum_i \lambda_i P_i
$$
(with the $P_i$ equal to spectral projectors and hence mutually orthogonal and "complete"), then the measure associated with $A$ can be written as
$$
P_A(\lambda) = \sum_i \delta(\lambda - \lambda_i)P_i.
$$
To see that this works, it suffices to show that for a Borel function $f$, $f(A)$ is indeed equal to $\int_{\Bbb R} f(\lambda) \,dP_{A}(\lambda)$. In other words, this is simply a consequence of the fact that
$$
f\left(\sum_i \lambda_i P_i\right) = \sum_i f(\lambda_i) P_i.
$$


问:
Substitution/change of variable in integration
Integration techniques are newbies to me right now, and I was assigned this integral. My professor recommend to use substitution/change of variable to integrate this function.

$$\int (x^6+x^3)\sqrt[3]{x^3+2} dx$$

He gave me a hint after asking him for help and told me ¨Look at what is inside the cubic root, so that when you take the derivative of what is in the inside, you get what is on the outside of the cubic root. So that this works, you could try to factorize something out of x^3+2, that way when you derivee it , the outcome can help you with everything that is on the outside of the cubic root.¨
I was thinking for example x^3+2 = x^3(1+2x^-3)

答:
I would rewrite the integral as

$$\int x\color{red}{x^2}(x^3+1)\sqrt[3]{\color{red}{x^3+1}+1}\,\mathrm dx$$

then substitute $u=x^3+1$ (which gives $x=\sqrt[3]{u-1}$)  and $\mathrm du=3x^2\,\mathrm dx$ to get

$$\frac13\int\sqrt[3]{u-1}u\sqrt[3]{u+1}\,\mathrm du=\frac13\int u\sqrt[3]{u^2-1}\,\mathrm du$$

Then another substitution, $v=u^2-1$ and $\mathrm dv=2u\,\mathrm du$, leaving you with

$$\frac16\int\sqrt[3]{v}\,\mathrm dv$$


问:
$\|x\|_{\infty}\leq \|x\|_{2}$ for all $x\in l_2$ and $\|x\|_2 \leq \|x\|_1$ for $x\in l_1$
I'm getting ready for a midterm in my analysis class and was trying to solve this problem as part of my review. I was looking around, but couldn't find any solutions so I figured I'd ask here.

The definitions I'm working with are:

$l_p$ is the collection of sequences such that $x\in l_p$ if $\sum_{n=1}^{\infty}|x|^{p}<\infty$ and we have the the $p$-norm defined as $\|x\|_p = \left(\sum_{n=1}^{\infty}|x|^{p}\right)^{1/p}$

We define $l_{\infty}$ as the collection of all bounded sequences under the norm $\|x\|_{\infty} = \sup_{n\geq 1}\{|x_n|\}$.

Thanks for the help!

答:
For the first case, note that $$\sum_{i=1}^\infty |x_i|^2 = |x_{i^\star}|^2+\sum_{i\neq i^\star}|x_i|^2 \geq |x_{i^\star}|^2\,,$$ where $i^\star$ is any fixed index. If you choose $i^\star$ to be the index such that $|x_{i^\star}|\geq |x_i|$ for all $i$, then you've just to take the square root.

The second case is equivalent to show that $$\sum_{i=1}^\infty |x_i|^2\leq \left(\sum_{i=1}^\infty |x_i|\right)^2.$$ Can you see why is it so?

First notice that for any $a\geq 0$, $b\geq 0$, $$(a+b)^2=a^2+b^2+2ab\geq a^2+b^2\,.$$

Now fix $N>1$, can you generalise the previous result as
$$\sum_{i=1}^N |x_i|^2\leq \left(\sum_{i=1}^N |x_i|\right)^2?$$

Maybe induction can help...

Once you've done so, it is enough to take the limit $N\to\infty$...


问:
Prove log composite function is Lebesgue integrable
Let $g:X \rightarrow \mathbb{R}$ be a measurable function on the measure space $(X,A,\mu)$ where $\mu(X)< \infty$. If $g$ is Lebesgue integrable, how can I show $[log(1+|g(x)|)]^8$ is Lebesgue integrable?

I most likely need to make use of the comparison test but I’m struggling to use it for this problem.

答:
Let $X=(0,1)$ and $g(x) = e^{1 \over \sqrt[8]{x}} -1$. Then $g$ is measurable , $\mu X $ is finite, but $x \mapsto (\log(1+|g(x)|))^8 = { 1\over x}$ is clearly not integrable.

If we let $\phi(x) = (\log (1+x))^8$ on $[0,\infty]$ it is not too difficult to show that $|\phi(x)| \le L=6588344 \ e^{-7}$, in particular $\phi$ is Lipschitz with rank $L$.

Hence $|\phi(g(x))| \le |\phi(g(0)) | + L  |g(x)| + L|g(0)|$ and so
$\int | \phi \circ g | \le \mu X (|\phi(g(0)) | + L  |g(0)|) + L\int |g|$,
hence $\phi \circ g$ is integrable.


问:
Proving that a repeating decimal equals a fraction
I'm having some trouble with this question:
Prove that 0.1636363636...=9/55, using infinite series.  I'd appreciate any help you can give me.  Thanks!</p>

Body: You can do this: \begin{align*} 0.1636363\cdots &= \frac{1}{10} + \biggl[ 63 \times 10^{-3} + 63\times 10^{-5} + 63 \times 10^{-7} + \cdots\biggr] \\ &= \frac{1}{10} + 63 \cdot \Bigl[ 10^{-3} + 10^{-5} + 10^{-7} + \cdots \Bigr] \\ &= \frac{1}{10} + 63 \cdot \frac{10^{-3}}{1-10^{-2}} \\ &= \frac{1}{10} + \frac{7}{110}=\frac{9}{55}\end{align*}


问:
Sample Pearson's R Covariance and Standard Deviation Missing $\frac{1}{n-1}$
When calculating the Pearson's R for a sample set, the formula is given as:

$r_{xy} = \frac{\sum_{i=1}^n (x_i - \bar{x})(y_i - \bar{y})}{\sqrt{\sum_{i=1}^n (x_i - \bar{x})^2}\sqrt{\sum_{i=1}^n (y_i - \bar{y})^2 }} $

Wikipedia

But for a population we have the following formula:

$\rho_{x,y} = \frac{\text{cov}(X,Y)}{\sigma_x \sigma_y}$

And of course since we are using a sample (not a population), definitions of $\text{cov}(X,Y)$, $\sigma_x$ and $\sigma_y$ include a factor of $\frac{1}{n-1}$.

For example, sample covariance is defined:

$\text{cov}(X,Y) = \frac{\sum_{i=1}^n (x_i-\bar{x}) (y_i - \bar{y})}{n-1}$

And a similar definition exists for $\sigma_x$ and $\sigma_y$.

I'm sure my algebra is missing a step somewhere.  My question is:

In the defenition of Pearson's R for a sample set, where did the $\frac{1}{n-1}$ go?

答: For the sample, if you define$$\text{cov}(X,Y)=\frac{\sum_{i=1}^n(x_i-\bar x)(y_i-\bar y)}{n-1}$$then the sample variance for either samples is$$\sigma_x^2=\text{cov(X,X)}=\frac{\sum_{i=1}^n(x_i-\bar x)^2}{n-1}\\\sigma_y^2=\text{cov(Y,Y)}=\frac{\sum_{i=1}^n(y_i-\bar y)^2}{n-1}$$and thus$$\rho_{xy}=\frac{\frac{\sum_{i=1}^n(x_i-\bar x)(y_i-\bar y)}{n-1}}{\sqrt{\frac{\sum_{i=1}^n(x_i-\bar x)^2}{n-1}}\sqrt{\frac{\sum_{i=1}^n(y_i-\bar y)^2}{n-1}}}$$and you can see the denominators still cancel off, giving the required expression for $r_{xy}$.


问:
Binary sequences with even places not less than immediate neighbors

How many $n$-length binary sequences, $(x_1,x_2,\ldots x_n)$, are there such that $x_1 ≤ x_2 ≥ x_3 ≤ x_4 ≥ x_5 \le \ldots$ ?

My attempt but I am not sure it is correct (finding pattern):
My attempt

How to find out the solution to this problem? Any hint/reference would be also appreciated.

Thanks in advance.

答:
HINT: A good start would be to list the acceptable $n$-bit sequences for $n=1,2,3,4$:

$$\begin{array}{c|c}
n&\text{sequences}\\\hline
0&\text{empty sequence}\\
1&0\quad 1\\
2&00\quad 01\quad \color{red}{11}\\
3&000\quad 010\quad 011\quad \color{red}{110\quad 111}\\
4&0000\quad 0001\quad 0100\quad 0101\quad 0111\quad \color{red}{1100\quad 1101\quad 1111}
\end{array}$$

If $a_n$ is the number of acceptable $n$-bit sequences, we now know that $a_0=1$, $a_1=2$, $a_2=3$, $a_3=5$, and $a_4=8$. The sequence $1,2,3,5,8$ should be recognizable as the Fibonacci numbers $F_2,F_3,F_4,F_5$, and $F_6$; this suggests the conjecture that $a_n=F_{n+2}$. One way to prove this would be to show that $a_n=a_{n-1}+a_{n-2}$ for $n\ge 2$.

I’ve added color to the table to suggest how this might be done: the coloring suggests that there might in general be $a_{n-1}$ acceptable $n$-bit sequences that start with $0$ and $a_{n-2}$ that start with $11$. The latter conjecture is quite easy to prove. The former is a little trickier: you have to recognize and prove that $b_1\ldots b_{n-1}$ is an acceptable $(n-1)$-bit sequence if and only if $0\bar b_1\ldots\bar b_{n-1}$ is an acceptable $n$-bit sequence, where $\bar 0=1$ and $\bar 1=0$.


答:
Hint: Consider this problem in cases!

Define $f(n)$ to be the number of binary sequences of length $n$.

Define $f_1(n)$ to be the number of binary sequences of length $n$ beginning with $1$.

Define $f_0(n)$ to be the number of binary sequences of length $n$ beginning with $0$.

C1: We begin with $x_1=1$, $x_2=1$

If that's the case, then the number of combinations is given by $f(n-2)$ ($x_3$ can be either $1$ or $0$ and $x_3 \leq x_4$, so the conditions mirror the relationship between $x_1$ and $x_2$)

C2: $x_1=1$, $x_2=0$

This is impossible because the rules says that $x_1 \leq x_2$

Therefore, $f_1(n) = f(n-2)$

C3: $x_1=0$, $x_2=1$

The number of combinations is given by $f(n-2)$ (for the same reasons as C1)

C4: $x_1=0$, $x_2=0$

The number of combinations is given by $f_0(n-2)$ ($x_3$ has to be $0$, so it's not the same as C1 or C3)

Therefore, $f_0(n) = f(n-2) + f_0(n-2)$

Putting it all together:
$$f(n) = f_1(n) + f_0(n) = 2f(n-2) + f_0(n-2)$$
$$= 2(2f(n-4) + f_0(n-4)) + (f(n-4) + f_0(n-4)) = 5f(n-4) + 3f_0(n-4)$$
$$= 5(2f(n-6) + f_0(n-6)) + 3(f(n-6) + f_0(n-6)) = 13f(n-6) + 8f_0(n-6)$$
$$...$$

There's a pattern to the coefficients! Find that pattern (maybe look at Brian M. Scott's hint!) and express f(n) in terms of something you know like f(2), which we showed to be 3 (the coefficients will be in terms of n).

Title: Binary sequences with even places not less than immediate neighbors

Body:
How many $n$-length binary sequences, $(x_1,x_2,\ldots x_n)$, are there such that $x_1 ≤ x_2 ≥ x_3 ≤ x_4 ≥ x_5 \le \ldots$ ?

My attempt but I am not sure it is correct (finding pattern):
My attempt

How to find out the solution to this problem? Any hint/reference would be also appreciated.

Thanks in advance.


问:
How to determine if a point is on a line in 4-dimensional space?
Suppose there is the 4-dimensional Euclidean space $\cal{E}^4$. Let there be the line $\overset{\leftrightarrow}{l}$ that intersects the points $\left(x_1,y_1,z_1,u_1\right)$ and $\left(x_2,y_2,z_2,u_2\right)$.

How would one determine (in the realm of linear algebra) if the point $p$, defined as $\left(a,b,c,d\right)$, lies on $\overset{\leftrightarrow}{l}$?

答:
Look for a solution $t$ of the vector equation
$$(a,b,c,d) = (1-t) \cdot (x_1,y_1,z_1,y_1) + t (x_2,y_2,z_2,u_2)
$$


问:
How to solve this derivative question?
I am in a bit over my head with a math course I joined voluntarily. This is the first question. I am learning but not as fast as it seems.

Q: If $f:(-{\displaystyle \pi }/6,{\displaystyle \pi }/6) \rightarrow \Bbb R$ is defined by $f(x)=2^x\tan(3x)$ for every $x {\displaystyle \in } (-{\displaystyle \pi }/6,{\displaystyle \pi }/6)$, then $f'(0)$ will be equal to (a) $\ln 2$ (b) $0$ (c) $2{\displaystyle \pi }$ (d) $3$

I want to know how to solve this, and what the chapter this is from and whats the exact resource that can help me learn this. I have figured this is linear approximation. Is that right ?

(And Boy, I just learned Latex, that was so much fun :)

答:
It's just rules of derivatives, like product and chain;

evaluate $f'(x)=\ln2\cdot2^x\tan(3x)+2^x\sec^2(3x)\cdot3$ at $x=0$.

Title: How to solve this derivative question?


问:
is this equality of serie right?
Consider the following:  $$\sum_{n=1}^{\infty} |a_n|=L<\infty $$
I want to bound the series $\sum_{n=1}|a_n/n^2|$, I know that $\sum_{n=1}\frac{1}{n^2}=\frac{\pi^2}{6}$, so my intuition tells me that: $$\sum_{n=1}^{\infty}|\frac{a_n}{n^2}|=L\frac{\pi^2}{6} $$ or at  least change this equality for a $\leq$, but I am not sure if this is right. Can you help me with this?

答:
Noting that
$$\sum_{n=1}^{\infty} |a_n|=L<\infty $$
implies $|a_n|\le L$. Hence
$$\sum_{n=1}^{\infty}|\frac{a_n}{n^2}|\le\sum_{n=1}^{\infty}\frac{L}{n^2}= L\frac{\pi^2}{6} .$$

Title: is this equality of serie right?


问:
$P(X_1+X_2<0)=???$
Let $X_1$ and $X_2$ be random variables i.i.d  $\mathcal{N}(2,5)$. What is $P(X_1+X_2<0)$?

My attempt:
X$=X_1+X_2$ has distribution $\mathcal{N}(4,10)$

$P(\textbf{X}<0)=0.3446$

Is it correct?

答:
Your thought process is correct but your calculation is not.

If $5$ is the variance of each $X_1$, $X_2$, then the sum $X = X_1 + X_2$ has variance $10$ as you wrote.  But then the correct probability is $$\Pr[X < 0] = \Pr\left[\frac{X - 4}{\sqrt{10}} < \frac{0 - 4}{\sqrt{10}} \right] \approx \Pr[Z < -1.26491] \approx 0.102952.$$  If $5$ is the standard deviation, then the standard deviation of the sum is $\sqrt{5^2 + 5^2} = 5 \sqrt{2} \approx 7.07107$, and then $$\Pr[X < 0] = \Pr\left[\frac{X - 4}{5 \sqrt{2}} < \frac{0 - 4}{5 \sqrt{2}}\right] \approx \Pr[Z < -0.565685] \approx 0.285804.$$  Which calculation you intend depends on whether $5$ is a variance or a standard deviation, but you cannot mix them up as you have done.

Title: $P(X_1+X_2<0)=???$


Title: $P(X_1+X_2<0)=???$

Body:
Let $X_1$ and $X_2$ be random variables i.i.d  $\mathcal{N}(2,5)$. What is $P(X_1+X_2<0)$?

My attempt:
X$=X_1+X_2$ has distribution $\mathcal{N}(4,10)$

$P(\textbf{X}<0)=0.3446$

Is it correct?

Body:
No.

$P(X_1+X_2<0)=P\left(\frac{X_1+X_2-4}{\sqrt{10}}<-4/\sqrt{10}\right)\\=\frac12-P(0<Z<4/\sqrt{10})\\\approx0.5-0.3962\\=0.1038.$


答:
By Cauchy–Schwarz inequality we have

$$\sum_{n=1}^{\infty}\left|\frac{a_n}{n^2}\right|\le \sqrt{\sum_{n=1}^{\infty}a_n^2} \cdot \sqrt{\sum_{n=1}^{\infty}\frac1{n^4}}\le L\frac{\pi^2}{\sqrt{90}}<L\frac{\pi^2}{6}$$

Title: is this equality of serie right?

Body:
Consider the following:  $$\sum_{n=1}^{\infty} |a_n|=L<\infty $$
I want to bound the series $\sum_{n=1}|a_n/n^2|$, I know that $\sum_{n=1}\frac{1}{n^2}=\frac{\pi^2}{6}$, so my intuition tells me that: $$\sum_{n=1}^{\infty}|\frac{a_n}{n^2}|=L\frac{\pi^2}{6} $$ or at  least change this equality for a $\leq$, but I am not sure if this is right. Can you help me with this?


问:
Difference between topologies generated by a basis and a subbasis
I am looking for examples where topologies generated by a subbasis and a basis yield to the same topologies, preferably in a finite topological space.

For instance let $X=\{1,2,3\}$. The collection $\mathcal{S} = \{\{1\}, \{2\}, \{1,3\} \}$ is a subbasis as the union of elements equals $X$. The topology generated by this subbasis is all unions of finite intersections of elements of $\mathcal{S}$ which gives us $\mathcal{T} = \{\phi, \{1\}, \{2\}, \{1,2\}, \{1,3\}, \{1,2,3\} \}$.

Moreover $\mathcal{S}$ is itself a basis as it satisfies the conditions of being a basis. So we can generate a topology with finding the collection of all unions of elements of $\mathcal{S}$, which is worded differently compared to the case where we generate a topology on $\mathcal{S}$ as a subbasis. In this case the generated topology on $\mathcal{S}$ as a basis is $\mathcal{T'} = \{\phi, \{1\}, \{2\}, \{1,2\}, \{1,3\}, \{1,2,3\} \}$. We note $\mathcal{T} = \mathcal{T'}$.

Is it always the case that a topology generated by a subbasis yield to a same topology when the topology is generated by the same collection $\mathcal{S}$ but as a basis and not as a subbasis? What are other differences/similarities between the topologies in these case? I understand similar questions have been asked before but I am specifically asking about the differences/similarities that the same collection of sets $\mathcal{S}$ make when it is viewed as a subbasis and when viewed as a basis.

答: No, they're not always different. For instance, in your example, the set $T'$ can be taken as both a basis and as a subbasis, and when you generate a topology from each of these (in its own way), you get $T'$ back again.


问:
Are there any trivial examples of languages that cannot be produced by formal grammars?
Since the cardinality of the set of all languages that can be produced by a grammar is smaller (countably infinite) than the cardinality of the set of all languages (which is uncountable infinite) I'm wondering if there is an easy example for a language that cannot be produced by a grammar.</p>

答:
Any set which isn't recursively enumerable, I think.

To find such a set, you can e.g. look for a set which is recursively enumerable, but which isn't recursive. This corresponds to a set where you can write a program which outputs the elements of the set, one after another, but where you cannot decide (in finite time) whether a certain element is part of the set. The complement of such a set then cannot be recursively enumerable, because that'd make the original set recursive. (Because you could then start enumerating both the original set and its complement in parallel, and wait for the element in question to pop up on one of the two lists. It'd have to pop up eventually, so this algorithm always terminated)

The set of all eventually terminating programs in any turing-complete language is such a recursively enumerable set which isn't recursive, and thus the set of all non-terminating programs can not be recursively enumerable.

You can list all this programs via diagonalization, i.e. by first listing all one-character programs which terminate in at most one step, then all programs two-character programs which terminate in at most two steps, and so on. This makes the set of all eventually terminating programs recursively enumerable. Because of the undeciability of the halting problem, however, it cannot be recursive.


答:
The topology generated by the subbase $\mathcal{S}$ is not $\mathcal{T}$, but rather $\mathcal{T}'$: in the second paragraph you failed to take the union of $\{1\}$ and $\{2\}$.

If a family $\mathcal{S}$ of subsets of $X$ is a base for a topology, that is also the topology generated by $\mathcal{S}$ as a subbase: it is already closed under finite intersections, so whichever way you view it, you’re just taking the closure under arbitrary unions. That is, every base for a topology is a subbase for that same topology.

Title: Difference between topologies generated by a basis and a subbasis

Body:
I am looking for examples where topologies generated by a subbasis and a basis yield to the same topologies, preferably in a finite topological space.

For instance let $X=\{1,2,3\}$. The collection $\mathcal{S} = \{\{1\}, \{2\}, \{1,3\} \}$ is a subbasis as the union of elements equals $X$. The topology generated by this subbasis is all unions of finite intersections of elements of $\mathcal{S}$ which gives us $\mathcal{T} = \{\phi, \{1\}, \{2\}, \{1,2\}, \{1,3\}, \{1,2,3\} \}$.

Moreover $\mathcal{S}$ is itself a basis as it satisfies the conditions of being a basis. So we can generate a topology with finding the collection of all unions of elements of $\mathcal{S}$, which is worded differently compared to the case where we generate a topology on $\mathcal{S}$ as a subbasis. In this case the generated topology on $\mathcal{S}$ as a basis is $\mathcal{T'} = \{\phi, \{1\}, \{2\}, \{1,2\}, \{1,3\}, \{1,2,3\} \}$. We note $\mathcal{T} = \mathcal{T'}$.

Is it always the case that a topology generated by a subbasis yield to a same topology when the topology is generated by the same collection $\mathcal{S}$ but as a basis and not as a subbasis? What are other differences/similarities between the topologies in these case? I understand similar questions have been asked before but I am specifically asking about the differences/similarities that the same collection of sets $\mathcal{S}$ make when it is viewed as a subbasis and when viewed as a basis.


问:
Extrapolation using Taylor series - giving negative results for increasing positive inputs
I would like to use a 2nd order Taylor series expansion to perform an extrapolation to predict points outside of a known range. I am using the following formulation:

\begin{equation*}
 d(N+ \Delta N) = d\bigr|_{@N} +
 \Delta N \frac{\partial d}{\partial N}\Bigr|_{@N}  +
 \frac{(\Delta N)^2}{2} \frac{\partial^2 d}{\partial N^2}\Bigr|_{@N}
 \end{equation*}

where, d is an increasing function ($d_N > d_{N-1} > d_{N-2}$) and the differentials are discretized as follows:

\begin{align*}
\frac{\partial d}{\partial N}\Bigr|_N &= d_N - d_{N-1}\\\\
\frac{\partial^2 d}{\partial N^2}\Bigr|_N &=
\frac{\partial d}{\partial N}\Bigr|_N - \frac{\partial d}{\partial N}\Bigr|_{N-1}   \\ \\
&= (d_N - d_{N-1}) - (d_{N-1} - d_{N-2}) \\
&= d_N - 2 d_{N-1} + d_{N-2}
\end{align*}

Hence the extrapolation equation is reduced to:
\begin{equation*}
d_{N+\Delta N} = d_N + \Delta N (d_N - d_{N-1}) +
\frac{(\Delta N)^2}{2}(d_N - 2 d_{N-1} + d_{N-2})
\end{equation*}

My question is, for all positive and increasing values of d, is it possible that the extrapolated value $d_{N+\Delta N}$ could be less than $d_N$ or even worse, negative?

Consider the following example where,
\begin{align*}
 d_{N-2} &= 0.3737 &\\
 d_{N-1} &= 0.5185 &\\
 d_N &= 0.6153 & \\
 \Delta N &= 10
\end{align*}

It can be seen that the slope from $d_{N-2}$ to $d_{N-1}$ and $d_{N-1}$ to $d_{N}$ are both positive. But after extrapolation using the above equation, I get a value $ {d_{N+ \Delta N} = -0.8167}$.

I understand that $d_{N-1}$ is closer to $d_{N}$ than $d_{N-2}$. But still, since the inputs are all increasing and positive, why is the Taylor expansion giving a negative value? I am failing to find an explanation to this. If not for a fix or a correction, it would be really helpful if someone could atleast comment on this and help me understand why this is happening. Please feel free to correct me if I am wrong. Many thanks! Cheers!

P.S. I cannot use higher order terms in the approximation since the extrapolation is part of a bigger implementation and using higher order terms would complicate things a lot.

Edit 1

In my problem, d is a strictly non decreasing function in [0,1]. A negative value for $d$ doesnt make physical sense.

I am looking for an extrapolation scheme using 3 past values ($d_N, d_{N-1}, d_{N-2}$) (hence with quadratic terms). What would be one of the better schemes that I can use to give me positive extrapolated values with larger $\Delta N$'s?

Using a first order Taylor expansion gave higher error in the predicted value. And using higher order terms than 2nd order would be difficult with the already existing solution methodology that I have. Any suggestion would be helpful. Thanks a lot..

答:
Note that $d_N - 2d_{N-1} + d_{N-2}$ is negative, so your approximation is a quadratic function with a $\cap$-shape. As with any Taylor approximation, the approximation is good near the reference point (i.e. $\Delta N$ near zero) and worsens as you get farther away. Note that in this particular case (where you know your function is increasing), a quadratic is particularly bad because no quadratic is globally increasing. (It may be a good local approximation though.)

You can check that when $\Delta N$ is small, you see an increase due to the positive slope. But when $\Delta N$ is large, the quadratic tends to negative infinity, so you will always see smaller values.


问:
The limit of the improper integral $\lim_{r\to 0} \int_{0}^{r} \log(1-e^{ix})dx$
I wonder how to rigorously show

$$\lim_{r\to 0} \int_{0}^{r} \log(1-e^{ix})dx=0$$

(let me know if it is not zero or the limit does not exist)

By the "intemediate value theorem" of  integrals, we know
$ \int_{s}^{r} \log(1-e^{ix})dx$ can be bounded by $(r-s)|\log(1-e^{ix_s})|$ for some $x_s\in [s,r]$. But the hard part is that $x_s$ can go to zero much faster when $s$ tends to 0. So I don't know how to deal with this.

答:
since we are talking about $r$ being "small" we can also see $x$ as small, and so we can make the approximation:
$$1-e^{ix}=(1-\cos(x))-i\sin(x)\approx-ix$$
so we can redefine our integral as:
$$I(r)=\int_0^r\log(-ix)dx=\int_0^r\left[\log(-i)+\log(x)\right]dx=\log(-i)r+r(\ln r-1)$$
and now take the limit as $r\to0$, obviously the first term vanishes and it can be shown using L'Hopital that the second term $\to0$


问:
Showing a subset is open with respect to a topology
I have asked and read similar questions, but I am still somewhat confused on the notion of "a set being open with respect to some topology". My task is concerning the box topology and the product topology on the infinite product space of the real line.

The goal is to show that a subset (call this subset S) of the infinite product space is open with respect to the box topology but not open with respect to the product topology. For more information, the subset S is a set of infinite-tuples of elements in the real line (ie just numbers). In each tuple, each succeeding tuple element is greater than the previous one. An example of an element of S would be (1, 2, 3, 4, ....) or (1.01, 1.02, 1.03, ...). I imagine that to prove this, we will need to use the slight difference in the bases that generate each topology.

My question is: how can we leverage the basis for each topology to show that some subset of the infinite product space is open/not open with respect to that topology? Put in other words: If we consider just the box topology, how does a subset S have to "relate" to the basis that generates the box topology in order for the subset S to be considered open in the box topology.

My original thought was to show that all elements of S can be represented as the union or finite intersection of base elements for the box topology, but the same does not go for the product topology. I am not sure how I would prove this exactly, or if that is even the correct procedure to follow.

Finally, I want to emphasize I am not looking for a clear cut answer, but to be pointed in the right direction for this proof.

Tl;dr How can we classify a subset of the infinite product space of the real line as open/not open with respect to the box topology/product topology.

答:
HINT: So

$$S=\left\{\langle x_n:n\in\Bbb N\rangle\in\Bbb R^{\Bbb N}:x_n<x_{n+1}\text{ for all }n\in\Bbb N\right\}\,.$$

To show that $S$ is open in the box topology, let $\langle x_n:n\in\Bbb N\rangle\in S$, and try to find open intervals $U_n$ around each $x_n$ such that $\prod_{n\in\Bbb N}U_n\subseteq S$.

To show that $S$ is not open in the product topology, show that no basic open set in the product topology is a subset of $S$; i.e., show that every basic open set in the product topology contains a sequence that is not strictly increasing.


问:
Locating the set in the arithmetic hierarchy
Let $W_x$ be the domain of a program (number) $x$. Let $S=\{x:\exists y (y\in W_x\land W_y\text{ is infinite})\}$. The exercise consists in determining of where this set belongs in arithmetic  hierarchy.

Here's what I got: $$x\in S\iff\exists y(\exists z T(x,y,z)\land \forall N\exists t > N \exists w T(x,t,w))$$

($T$ is the Kleene $T$-predicate). Now I guess I can "factor out" either $\exists z$ or $\forall N$ (and I'm free to choose any option in my understanding). Let's factor out $\exists z$:

$$\iff \exists y\exists z(T(x,y,z)\land \forall N\exists t(t>N\to \exists w T(x,t,w))$$

Now I can factor out $\exists w$:

$$\iff \exists y\exists z(T(x,y,z)\land \forall N\exists t\exists w(t>N\to  T(x,t,w))$$

Now I can factor out the group of quantifiers $\forall N\exists t\exists w$ (officially, one by one):

$$\iff \exists y\exists z \forall N\exists t\exists w(T(x,y,z)\land (t>N\to  T(x,t,w))$$

So it looks like the answer is $\Sigma_3$.

Is this reasoning correct? And is there an easy way to show that $\Sigma_3$ is the best that we can get (if this is so)?

答:
It is indeed $\Sigma^0_3$. In natural language, it's:

The set of $y$ such that at some point $y$ appears in $W_x$ and for each $z$ there is some $w>$ which sometime appears in $W_y$.

This is of the form $\Sigma^0_1(\Sigma^0_1\wedge\Pi^0_2)$, so $\Sigma^0_3$. (Obviously that's not a proof, but it's a good outline of how to do the rewriting.)

As to optimality, this is optimal in a very strong sense: the set $S$ in question is $\Sigma^0_3$-complete, meaning that any other $\Sigma^0_3$ set $A$ is many-one reducible to $S$. As a consequence, not only is it not $\Sigma^0_2$, it's not even $\Pi^0_3$.

This last bit uses the fact that the arithmetical hierarchy does not collapse: for every $n>0$ we have $\Sigma^0_n\not\subseteq \Pi^0_n$ and $\Pi^0_n\not\subseteq\Sigma^0_n$, and so a fortiori $\Sigma^0_n\supsetneq\Pi^0_{n-1}\cup\Sigma^0_{n-1}$ and $\Pi^0_n\supsetneq\Pi^0_{n-1}\cup\Sigma^0_{n-1}$.

Soare's old book has quite a bit of material on this. The arguments can get a bit technical, especially for higher levels of the arithmetic hierarchy, but aren't too bad. One way to make them simpler is to think "modularly:" e.g. in the proof that $S$ is $\Sigma^0_3$-complete you'll want to use the idea of the proof that the set of infinite c.e. sets is $\Pi^0_2$-complete.