tag
stringclasses
9 values
question_body
stringlengths
61
12.9k
accepted_answer
stringlengths
38
36.4k
second_answer
stringlengths
63
33k
logic
<p>I am trying to understand <a href="http://en.wikipedia.org/wiki/Russell%27s_paradox">Russells's paradox</a></p> <p>How can a set contain itself? Can you show example of set which is not a set of all sets and it contains itself.</p>
<p>In modern set theory (read: ZFC) there is no such set. The axiom of foundation ensures that such sets do not exist, which means that the class defined by Russell in the paradox is in fact the collection of all sets.</p> <p>It is possible, however, to construct a model of all the axioms except the axiom of foundation, and generate sets of the form $x=\{x\}$. Alternatively there are stronger axioms such as the Antifoundation axiom which also imply that there are sets like $x=\{x\}$. Namely, sets for which $x\in x$.</p> <p>For the common mathematics one can assume the foundation is based on ZFC or not (because there is a model of ZFC within a model of ZFC-Foundation), so there is no way to point out at a particular set for which it is true.</p> <p><strong>Also interesting:</strong></p> <ol> <li><a href="https://math.stackexchange.com/questions/200255/is-the-statement-a-in-a-true-or-false/">Is the statement $A \in A$ true or false?</a></li> <li><a href="https://math.stackexchange.com/questions/213639/where-is-axiom-of-regularity-actually-used/">Where is axiom of regularity actually used?</a></li> </ol>
<p>$x = \{ x \}$ ... </p> <p>... but actually <a href="http://en.wikipedia.org/wiki/Axiom_of_regularity">one</a> of the axioms of <a href="http://en.wikipedia.org/wiki/Zermelo%E2%80%93Fraenkel_set_theory">ZFC</a> (the "usual" axioms of set theory) has the immediate consequence that no set has itself as a member.</p>
matrices
<p>What is the difference between a matrix and a tensor? Or, what makes a tensor, a tensor? I know that a matrix is a table of values, right? But, a tensor? </p>
<p>Maybe to see the difference between rank 2 tensors and matrices, it is probably best to see a concrete example. Actually this is something which back then confused me very much in the linear algebra course (where we didn't learn about tensors, only about matrices).</p> <p>As you may know, you can specify a linear transformation <span class="math-container">$a$</span> between vectors by a matrix. Let's call that matrix <span class="math-container">$A$</span>. Now if you do a basis transformation, this can also be written as a linear transformation, so that if the vector in the old basis is <span class="math-container">$v$</span>, the vector in the new basis is <span class="math-container">$T^{-1}v$</span> (where <span class="math-container">$v$</span> is a column vector). Now you can ask what matrix describes the transformation <span class="math-container">$a$</span> in the new basis. Well, it's the matrix <span class="math-container">$T^{-1}AT$</span>.</p> <p>Well, so far, so good. What I memorized back then is that under basis change a matrix transforms as <span class="math-container">$T^{-1}AT$</span>.</p> <p>But then, we learned about quadratic forms. Those are calculated using a matrix <span class="math-container">$A$</span> as <span class="math-container">$u^TAv$</span>. Still, no problem, until we learned about how to do basis changes. Now, suddenly the matrix did <em>not</em> transform as <span class="math-container">$T^{-1}AT$</span>, but rather as <span class="math-container">$T^TAT$</span>. Which confused me like hell: how could one and the same object transform differently when used in different contexts?</p> <p>Well, the solution is: because we are actually talking about different objects! In the first case, we are talking about a tensor that takes vectors to vectors. In the second case, we are talking about a tensor that takes two vectors into a scalar, or equivalently, which takes a vector to a <em>covector</em>.</p> <p>Now both tensors have <span class="math-container">$n^2$</span> components, and therefore it is possible to write those components in a <span class="math-container">$n\times n$</span> matrix. And since all operations are either linear or bilinear, the normal matrix-matrix and matrix-vector products together with transposition can be used to write the operations of the tensor. Only when looking at basis transformations, you see that both are, indeed, <em>not</em> the same, and the course did us (well, at least me) a disservice by not telling us that we are really looking at two different objects, and not just at two different uses of the same object, the matrix.</p> <p>Indeed, speaking of a rank-2 tensor is not really accurate. The rank of a tensor has to be given by <em>two</em> numbers. The vector to vector mapping is given by a rank-(1,1) tensor, while the quadratic form is given by a rank-(0,2) tensor. There's also the type (2,0) which also corresponds to a matrix, but which maps two covectors to a number, and which again transforms differently.</p> <p>The bottom line of this is:</p> <ul> <li>The components of a rank-2 tensor can be written in a matrix.</li> <li>The tensor is not that matrix, because different types of tensors can correspond to the same matrix.</li> <li>The differences between those tensor types are uncovered by the basis transformations (hence the physicist's definition: &quot;A tensor is what transforms like a tensor&quot;).</li> </ul> <p>Of course, another difference between matrices and tensors is that matrices are by definition two-index objects, while tensors can have any rank.      </p>
<p>Indeed there are some &quot;confusions&quot; some people do when talking about tensors. This happens mainly on Physics where tensors are usually described as &quot;objects with components which transform in the right way&quot;. To really understand this matter, let's first remember that those objects belong to the realm of linear algebra. Even though they are used a lot in many branches of mathematics the area of mathematics devoted to the systematic study of those objects is really linear algebra.</p> <p>So let's start with two vector spaces <span class="math-container">$V,W$</span> over some field of scalars <span class="math-container">$\Bbb F$</span>. Now, let <span class="math-container">$T : V \to W$</span> be a linear transformation. I'll assume that you know that we can associate a matrix with <span class="math-container">$T$</span>. Now, you might say: so linear transformations and matrices are all the same! And if you say that, you'll be wrong. The point is: one <em>can</em> associate a matrix with <span class="math-container">$T$</span> only when one fix some basis of <span class="math-container">$V$</span> and some basis of <span class="math-container">$W$</span>. In that case we will get <span class="math-container">$T$</span> represented on those bases, but if we don't introduce those, <span class="math-container">$T$</span> will be <span class="math-container">$T$</span> and matrices will be matrices (rectangular arrays of numbers, or whatever definition you like).</p> <p>Now, the construction of tensors is much more elaborate than just saying: &quot;take a set of numbers, label by components, let they transform in the correct way, you get a tensor&quot;. In truth, this &quot;definition&quot; is a consequence of the actual definition. Indeed the actual definition of a tensor is meant to introduce what we call &quot;Universal Property&quot;.</p> <p>The point is that if we have a collection of <span class="math-container">$p$</span> vector spaces <span class="math-container">$V_i$</span> and another vector space <span class="math-container">$W$</span> we can form functions of several variables <span class="math-container">$f: V_1\times \cdots \times V_p \to W$</span>. A function like this will be called multilinear if it's linear in each argument with the others held fixed. Now, since we know how to study linear transformations we ask ourselves: is there a construction of a vector space <span class="math-container">$S$</span> and one <em>universal</em> multilinear map <span class="math-container">$T : V_1 \times \cdots \times V_p \to S$</span> such that <span class="math-container">$f = g \circ T$</span> for some <span class="math-container">$g : S \to W$</span> linear and such that this holds for all <span class="math-container">$f$</span>? If that's always possible we'll reduce the study of multilinear maps to the study of linear maps.</p> <p>The happy part of the story is that this is always possible, the construction is well defined and <span class="math-container">$S$</span> is denoted <span class="math-container">$V_1 \otimes \cdots \otimes V_p$</span> and is called the <em>tensor product</em> of the vector spaces and the map <span class="math-container">$T$</span> is the tensor product of the vectors. An element <span class="math-container">$t \in S$</span> is called a tensor. Now it's possible to prove that if <span class="math-container">$V_i$</span> has dimension <span class="math-container">$n_i$</span> then the following relation holds:</p> <p><span class="math-container">$$\dim(V_1\otimes \cdots \otimes V_p)=\prod_{i=1}^p n_i$$</span></p> <p>This means that <span class="math-container">$S$</span> has a basis with <span class="math-container">$\prod_{i=1}^p n_i$</span> elements. In that case, as we know from basic linear algebra, we can associate with every <span class="math-container">$t \in S$</span> its components in some basis. Now, those components are what people usually call &quot;the tensor&quot;. Indeed, when you see in Physics people saying: &quot;consider the tensor <span class="math-container">$T^{\alpha \beta}$</span>&quot; what they are really saying is &quot;consider the tensor <span class="math-container">$T$</span> whose components in some basis understood by context are <span class="math-container">$T^{\alpha \beta}$</span>&quot;.</p> <p>So if we consider two vector spaces <span class="math-container">$V_1$</span> and <span class="math-container">$V_2$</span> with dimensions respectivly <span class="math-container">$n$</span> and <span class="math-container">$m$</span>, by the result I've stated <span class="math-container">$\dim(V_1 \otimes V_2)=nm$</span>, so for every tensor <span class="math-container">$t \in V_1 \otimes V_2$</span> one can associate a set of <span class="math-container">$nm$</span> scalars (the components of <span class="math-container">$t$</span>), and we are obviously allowed to plug those values into a matrix <span class="math-container">$M(t)$</span> and so there's a correspondence of tensors of rank <span class="math-container">$2$</span> with matrices.</p> <p>However, exactly as in the linear transformation case this correspondence is only possible when we have selected bases on the vector spaces we are dealing with. Finally, with every tensor it is possible to associate also a multilinear map. So tensors can be understood in their fully abstract and algebraic way as elements of the tensor product of vector spaces, and can also be understood as multilinear maps (this is better for intuition) and we can associate matrices to those.</p> <p>So after all this hassle with linear algebra, the short answer to your question is: matrices are matrices, tensors of rank 2 are tensors of rank 2, however there's a correspondence between them whenever you fix a basis on the space of tensors.</p> <p>My suggestion is that you read Kostrikin's &quot;Linear Algebra and Geometry&quot; chapter <span class="math-container">$4$</span> on multilinear algebra. This book is hard, but it's good to really get the ideas. Also, you can see about tensors (constructions in terms of multilinear maps) in good books of multivariable Analysis like &quot;Calculus on Manifolds&quot; by Michael Spivak or &quot;Analysis on Manifolds&quot; by James Munkres.</p>
logic
<p>If i have a formula: $((a \wedge b) \vee (q \wedge r )) \vee z$, am I right in thinking the CNF for this formula would be $(a\vee q \vee r \vee z) \wedge (b \vee q \vee r \vee z) $? Or is there some other method I must follow?</p>
<p>To convert to conjunctive normal form we use the following rules:</p> <p>Double Negation:</p> <p>1. $P\leftrightarrow \lnot(\lnot P)$</p> <p>De Morgan's Laws</p> <p>2. $\lnot(P\bigvee Q)\leftrightarrow (\lnot P) \bigwedge (\lnot Q)$</p> <p>3. $\lnot(P\bigwedge Q)\leftrightarrow (\lnot P) \bigvee (\lnot Q)$</p> <p>Distributive Laws </p> <p>4. $(P \bigvee (Q\bigwedge R))\leftrightarrow (P \bigvee Q) \bigwedge (P\bigvee R)$</p> <p>5. $(P \bigwedge (Q\bigvee R))\leftrightarrow (P \bigwedge Q) \bigvee (P\bigwedge R)$</p> <p>So let’s expand the following: (equivalent to the expression in question)</p> <p>1. $(((A \bigwedge B) \bigvee (C \bigwedge D)) \bigvee E)$ Now using 4. we get:</p> <p>2. $((A \bigwedge B) \bigvee C)\bigwedge ((A \bigwedge B) \bigvee D)) \bigvee E$ And using 4. again</p> <p>3. $((((A\bigvee C) \bigwedge (B \bigvee C))\bigwedge ((A\bigvee D) \bigwedge B\bigvee D))) \bigvee E)$ which gives:</p> <p>4. $(((A\bigvee C) \bigwedge (B \bigvee C))\bigvee E)\bigwedge ((A\bigvee D) \bigwedge B\bigvee D))\bigvee E) $</p> <p>5. $(A\bigvee C\bigvee E) \bigwedge (B \bigvee C\bigvee E)\bigwedge (A\bigvee D\bigvee E) \bigwedge (B\bigvee D\bigvee E)$</p> <p>Which is now in CNF. You can use things like Wolfram Alpha to check these as well if you wish.</p>
<p>Another possibility is to make a truth table (Note, in my symantics $1=T$ and $0=F$); it is longer but this method is fail safe. $\phi=((a\wedge b)\vee(q \wedge r))\vee z$ then:</p> <p>$$\begin{array}{ccccc|c} a &amp; b &amp; q &amp; r &amp; z &amp; \phi\\\hline 0 &amp; 0 &amp; 0 &amp; 0 &amp; 0 &amp; 0 \\ 0 &amp; 0 &amp; 0 &amp; 0 &amp; 1 &amp; 1 \\ 0 &amp; 0 &amp; 0 &amp; 1 &amp; 0 &amp; 0 \\ \end{array}$$</p> <p>And so on, and for every row in which $ \phi=0 $ you get a "Clause" by putting the literal in the clause if he takes 0 in that row and his "not" if the literal takes 1.</p> <p>For example the clause for the first line is $(x \vee y\vee q \vee r \vee z)$. the clause for the third line is $(x \vee y\vee q \vee \bar r \vee z)$. There is no clause for the second line because $ \phi=1 $.</p> <p>For the line $\begin{array}{ccccc|c}0&amp;1&amp;0&amp;1&amp;0&amp;0\end{array}$ you get the clause $(x \vee \bar y \vee q \vee \bar r \vee z)$.</p> <p>Finally you put a $\wedge $ between the clauses.</p>
probability
<p>I was doing some software engineering and wanted to have a thread do something in the background to basically just waste CPU time for a certain test.</p> <p>While I could have done something really boring like <code>for(i &lt; 10000000) { j = 2 * i }</code>, I ended up having the program start with <span class="math-container">$1$</span>, and then for a million steps choose a random real number <span class="math-container">$r$</span> in the interval <span class="math-container">$[0,R]$</span> (uniformly distributed) and multiply the result by <span class="math-container">$r$</span> at each step.</p> <ul> <li>When <span class="math-container">$R = 2$</span>, it converged to <span class="math-container">$0$</span>.</li> <li>When <span class="math-container">$R = 3$</span>, it exploded to infinity. </li> </ul> <p>So of course, the question anyone with a modicum of curiosity would ask: for what <span class="math-container">$R$</span> do we have the transition. And then, I tried the first number between <span class="math-container">$2$</span> and <span class="math-container">$3$</span> that we would all think of, Euler's number <span class="math-container">$e$</span>, and sure enough, this conjecture was right. Would love to see a proof of this. </p> <p>Now when I should be working, I'm instead wondering about the behavior of this script. </p> <p>Ironically, rather than wasting my CPUs time, I'm wasting my own time. But it's a beautiful phenomenon. I don't regret it. <span class="math-container">$\ddot\smile$</span></p>
<p><strong>EDIT:</strong> I saw that you solved it yourself. Congrats! I'm posting this anyway because I was most of the way through typing it when your answer hit. </p> <p>Infinite products are hard, in general; infinite sums are better, because we have lots of tools at our disposal for handling them. Fortunately, we can always turn a product into a sum via a logarithm.</p> <p>Let <span class="math-container">$X_i \sim \operatorname{Uniform}(0, r)$</span>, and let <span class="math-container">$Y_n = \prod_{i=1}^{n} X_i$</span>. Note that <span class="math-container">$\log(Y_n) = \sum_{i=1}^n \log(X_i)$</span>. The eventual emergence of <span class="math-container">$e$</span> as important is already somewhat clear, even though we haven't really done anything yet.</p> <p>The more useful formulation here is that <span class="math-container">$\frac{\log(Y_n)}{n} = \frac 1 n \sum \log(X_i)$</span>, because we know from the Strong Law of Large Numbers that the right side converges almost surely to <span class="math-container">$\mathbb E[\log(X_i)]$</span>. We have <span class="math-container">$$\mathbb E \log(X_i) = \int_0^r \log(x) \cdot \frac 1 r \, \textrm d x = \frac 1 r [x \log(x) - x] \bigg|_0^r = \log(r) - 1.$$</span></p> <p>If <span class="math-container">$r &lt; e$</span>, then <span class="math-container">$\log(Y_n) / n \to c &lt; 0$</span>, which implies that <span class="math-container">$\log(Y_n) \to -\infty$</span>, hence <span class="math-container">$Y_n \to 0$</span>. Similarly, if <span class="math-container">$r &gt; e$</span>, then <span class="math-container">$\log(Y_n) / n \to c &gt; 0$</span>, whence <span class="math-container">$Y_n \to \infty$</span>. The fun case is: what happens when <span class="math-container">$r = e$</span>?</p>
<p>I found the answer! One starts with the uniform distribution on <span class="math-container">$ [0,R] $</span>. The natural logarithm pushes this distribution forward to a distribution on <span class="math-container">$ (-\infty, \ln(R) ] $</span> with density function given by <span class="math-container">$ p(y) = e^y / R, y \in (-\infty, \ln(R)] $</span>. The expected value of this distribution is <span class="math-container">$$ \int_{-\infty}^{\ln(R)}\frac{y e^y}{R} \,\mathrm dy = \ln(R) - 1 .$$</span> Solving for zero gives the answer to the riddle! Love it! </p>
differentiation
<p>There is a famous example of a function that has no derivative: the Weierstrass function:</p> <p><a href="https://i.sstatic.net/puevr.png" rel="noreferrer"><img src="https://i.sstatic.net/puevr.png" alt="enter image description here" /></a></p> <p>But just by looking at this equation - I can't seem to understand why exactly the Weierstrass Function does not have a derivative?</p> <p>I tried looking at a few articles online (e.g. <a href="https://www.quora.com/Why-isnt-the-Weierstrass-function-differentiable" rel="noreferrer">https://www.quora.com/Why-isnt-the-Weierstrass-function-differentiable</a>), but I still can't seem to understand what prevents this function from having a derivative?</p> <p>For example, if you expand the summation term for some very large (finite) value of <span class="math-container">$n$</span>: <span class="math-container">$$ f(x) = a \cos(b\pi x) + a^2\cos(b^2\pi x) + a^3\cos(b^3\pi x) + ... + a^{100}\cos(b^{100}\pi x) $$</span> What is preventing us from taking the derivative of <span class="math-container">$f(x)$</span>? Is the Weierstrass function non-differentiable only because it has &quot;infinite terms&quot; - and no function with infinite terms can be differentiated?</p> <p>For a finite value of <span class="math-container">$n$</span>, is the Weierstrass function differentiable?</p> <p>Thank you!</p>
<p>Nothing is preventing us from taking the derivative of any finite partial sum of this series. This is a trigonometric polynomial and it has derivatives of all orders.</p> <p>However, this infinite sum represents the pointwise <strong>limit</strong> of such trigonometric polynomials. A pointwise limit of differentiable functions has no obligation to be differentiable.</p> <p>On the other hand, the sheer fact that this function is an infinite sum doesn’t automatically imply that it’s nowhere differentiable. An infinite power series or infinite trigonometric series may be differentiable everywhere, differentiable nowhere, or differentiable in some places and not others.</p> <p>To check if a function is differentiable at a point <span class="math-container">$x_0$</span>, you must determine if the limit <span class="math-container">$\lim_{h\to 0}(f(x_0+h)-f(x_0))/h$</span> exists. If it doesn’t, the function isn’t differentiable at <span class="math-container">$x_0$</span>.</p> <p>There are various theorems which help us bypass the need for doing this directly. For example, we can show that the composition of differentiable functions is differentiable, and that various elementary functions are differentiable everywhere, which lets us conclude that things like <span class="math-container">$\cos(17x^2)-e^x$</span> are differentiable everywhere.</p> <p>One of these shortcuts applies when you have infinite sums with <strong>uniformly convergent</strong> derivatives. This very important result allows us to conclude that many functions defined by infinite series do indeed have derivatives, and those derivatives are what you’d expect. But this doesn’t apply here, since this sum does <strong>not</strong> have uniformly convergent derivatives.</p> <p>And once again, this fact alone isn’t enough to show that the function is nowhere differentiable. To show that, you have to roll up your sleeves and work out inequalities that apply everywhere and prevent the limit above from existing. This is done carefully <a href="https://math.berkeley.edu/%7Ebrent/files/104_weierstrass.pdf" rel="noreferrer">here</a>, for example.</p>
<p>In order to calculate the derivative of a function at a given point (e.g. <span class="math-container">$x=0$</span>), you just need to <a href="https://math.stackexchange.com/a/2833438/386794">keep zooming</a> on this point until the curve gets smooth:</p> <p><img src="https://download.ericduminil.com/weierstrass_zoom.gif" alt="https://download.ericduminil.com/weierstrass_zoom.gif" /></p> <p>Oh, wait...</p>
combinatorics
<p>What is the proof that given a set of $n$ elements there are $2^n$ possible subsets (including the empty-set and the original set).</p>
<p>Suppose you want to choose a subset. For each element, you have two choices: either you put it in your subset, or you don't; and these choices are all independent.</p> <p><strong>Remark</strong>: this works also for the empty set. An empty set has exactly one subset, namely the empty set. And the fact that $2^0=1$ reflects the fact that there is only one way to pick no elements at all!</p>
<p>Here is a proof by induction on $n$. This proof assumes that we have defined $2^n$ by recursion as $2^0 = 1$ and $2^{n+1} = 2^n \cdot 2$.</p> <p>This is true for $n=0$ because $\emptyset$ has exactly one subset, namely $\emptyset$ itself.</p> <p>Now assume that the claim is true for sets with $n$ many elements. Given a set $Y$ with $n+1$ many elements, we can write $Y = X \cup \{p\}$ where $X$ is a set with $n$ many elements and $p \notin X$. There are $2^n$ many subsets $A \subset X$, and each subset $A \subset X$ gives rise to two subsets of $Y$, namely $A \cup \{p\}$ and $A$ itself. Moreover, every subset of $Y$ arises in this manner. Therefore the number of subsets of $Y$ is equal to $2^n \cdot 2$, which in turn is equal to $2^{n+1}$.</p>
probability
<p>Of course, we've all heard the colloquialism "If a bunch of monkeys pound on a typewriter, eventually one of them will write Hamlet."</p> <p>I have a (not very mathematically intelligent) friend who presented it as if it were a mathematical fact, which got me thinking... Is this really true? Of course, I've learned that dealing with infinity can be tricky, but my intuition says that time is countably infinite while the number of works the monkeys could produce is uncountably infinite. Therefore, it isn't necessarily given that the monkeys would write Hamlet.</p> <p>Could someone who's better at this kind of math than me tell me if this is correct? Or is there more to it than I'm thinking?</p>
<p>I found online the claim (which we may as well accept for this purpose) that there are $32241$ words in Hamlet. Figuring $5$ characters and one space per word, this is $193446$ characters. If the character set is $60$ including capitals and punctuation, a random string of $193446$ characters has a chance of $1$ in $60^{193446}$ (roughly $1$ in $10^{344000}$) of being Hamlet. While very small, this is greater than zero. So if you try enough times, and infinity times is certainly enough, you will probably produce Hamlet. But don't hold your breath. It doesn't even take an infinite number of monkeys or an infinite number of tries. Only a product of $10^{344001}$ makes it very likely. True, this is a very large number, but most numbers are larger.</p>
<p>Some references (I am mildly surprised that no one has done this yet). This is called the <a href="http://en.wikipedia.org/wiki/Infinite_monkey_theorem">infinite monkey theorem</a> in the literature. It follows from the second <a href="http://en.wikipedia.org/wiki/Borel%E2%80%93Cantelli_lemma">Borel-Cantelli lemma</a> and is related to <a href="http://en.wikipedia.org/wiki/Kolmogorov%27s_zero-one_law">Kolmogorov's zero-one law</a>, which is the result that provides the intuition behind general statements like this. (The zero-one law tells you that the probability of getting Hamlet is either zero or one, but doesn't tell you which. This is usually the hard part of applying the zero-one law.) Since others have addressed the practical side, I am telling you what the mathematical idealization looks like.</p> <blockquote> <p>my intuition says that time is countably infinite while the number of works the monkeys could produce is uncountably infinite.</p> </blockquote> <p>This is a good idea! Unfortunately, the number of finite strings from a finite alphabet is countable. This is a good exercise and worth working out yourself.</p> <p>Edit: also, regarding some ideas which have come up in the discussions on other answers, Jorge Luis Borges' short story <a href="http://en.wikipedia.org/wiki/The_Library_of_Babel">The Library of Babel</a> is an interesting read.</p>
combinatorics
<p>The <a href="http://en.wikipedia.org/wiki/Catalan_number" rel="nofollow noreferrer">Catalan numbers</a> have a reputation for turning up everywhere, but the occurrence described below, in the analysis of an (incorrect) algorithm, is still mysterious to me, and I'm curious to find an explanation.</p> <hr /> <p>For situations where a quadratic-time sorting algorithm is fast enough, I usually use the following:</p> <pre><code>//Given array a[1], ... a[n] for i = 1 to n: for j = i+1 to n: if a[i] &gt; a[j]: swap(a[i],a[j]) </code></pre> <p>It looks like bubble sort, but is closer to selection sort. It is easy to see why it works: in each iteration of the outer loop, <code>a[i]</code> is set to be the smallest element of <code>a[i…n]</code>.</p> <p>In a programming contest many years ago, one of the problems essentially boiled down to sorting:</p> <blockquote> <p>Given a list of distinct values <span class="math-container">$W_1, W_2, \dots, W_n$</span>, find the indices when it is sorted in ascending order. In other words, find the permutation <span class="math-container">$(S_1, S_2, \dots, S_n)$</span> for which <span class="math-container">$W_{S_1} &lt; W_{S_2} &lt; \dots &lt; W_{S_n}$</span>.</p> </blockquote> <p>This is simply a matter of operating on the indices rather than on the array directly, so the correct code would be:</p> <pre><code>//Given arrays S[1], ..., S[n] (initially S[i]=i ∀i) and W[1], ..., W[n] for i = 1 to n: for j = i+1 to n: if W[S[i]] &gt; W[S[j]]: swap(S[i],S[j]) </code></pre> <p>But in the heat of the contest, I instead coded a program that did, incorrectly:</p> <pre><code>for i = 1 to n: for j = i+1 to n: if W[i] &gt; W[j]: swap(S[i],S[j]) </code></pre> <p>I realised the mistake after the contest ended, and later while awaiting the results, with desperate optimism I tried to figure out the odds that for some inputs, my program would accidentally give the right answer anyway. Specifically, I counted the number of permutations of an arbitrary list <span class="math-container">$W_1, \dots, W_n$</span> with distinct values (since only their <em>order</em> matters, not their actual values) for which the incorrect algorithm above gives the correct answer, for each n:</p> <pre><code>n Number of &quot;lucky&quot; permutations 0 1 1 1 2 2 3 5 4 14 5 42 6 132 7 429 8 1430 9 4862 10 16796 11 58786 12 208012 </code></pre> <p>These are the Catalan numbers! But why? I've tried to prove this occasionally in my free time, but never succeeded.</p> <hr /> <p>What I've tried:</p> <ul> <li><p>The (pseudo)algorithm can be represented in more formal notation as the product of all inversions in a permutation. That is, we want to prove that the number of permutations <span class="math-container">$\sigma \in S_n$</span> such that <span class="math-container">$$\prod_{i=1}^{n}\prod_{\substack{j \in \left\{i+1,i+2,\ldots,n\right\}; \\ \sigma_i &gt; \sigma_j}}(i,j) = \sigma^{-1}$$</span> (with the convention that multiplication is done left to right) is <span class="math-container">$C_n$</span>. This change of notation does not make the problem any simpler.</p> </li> <li><p>I briefly skimmed through <a href="http://www-math.mit.edu/%7Erstan/ec/" rel="nofollow noreferrer">Stanley's famous list of Catalan problems</a>, but this does not seem to be (directly) in the list. :-)</p> </li> <li><p>Some computer experimentation suggests that the lucky permutations are those that avoid the <a href="http://en.wikipedia.org/wiki/Permutation_pattern" rel="nofollow noreferrer">pattern</a> 312, the number of which is apparently the Catalan numbers. But I have no idea how to prove this, and it may not be the best approach...</p> </li> </ul>
<p>Your suspicions are correct. Let's show that a permutation is lucky iff it avoids the pattern 312.</p> <p>For an injection <span class="math-container">$W$</span> from <span class="math-container">$\{1,\ldots,k\}$</span> to <span class="math-container">$\{n-k+1,\ldots,n\}$</span>, let <span class="math-container">$N(W)$</span> denote the result of removing <span class="math-container">$W(1)$</span> and increasing all elements below <span class="math-container">$W(1)$</span> by <span class="math-container">$1$</span>. For example, <span class="math-container">$N(32514) = N(3524)$</span>.</p> <p><b>Lemma 1.</b> If <span class="math-container">$W$</span> avoids <span class="math-container">$312$</span> then so does <span class="math-container">$N(W)$</span>.</p> <p><b>Proof.</b> Clear since the relative order of elements in <span class="math-container">$N(W)$</span> is the same as the corresponding elements in <span class="math-container">$W$</span>.</p> <p><b>Lemma 2.</b> Suppose <span class="math-container">$W$</span> avoids <span class="math-container">$312$</span>. After running one round of the algorithm, <span class="math-container">$S(1)$</span> contains the index of the minimal element in <span class="math-container">$W$</span>, and <span class="math-container">$W \circ S = N(W)$</span>.</p> <p><b>Proof.</b> The lemma is clear if <span class="math-container">$W(1)$</span> is the minimal element. Otherwise, since <span class="math-container">$W$</span> avoids <span class="math-container">$312$</span>, all elements below <span class="math-container">$W(1)$</span> form a decreasing sequence <span class="math-container">$W(1) = W(i_1) &gt; \cdots &gt; W(i_k)$</span>. The algorithm puts the minimal one <span class="math-container">$W(i_k)$</span> at <span class="math-container">$S(1)$</span>, and puts <span class="math-container">$W(i_t)$</span> at <span class="math-container">$W(i_{t+1})$</span>.</p> <p><b>Theorem 1.</b> If <span class="math-container">$W$</span> avoids <span class="math-container">$312$</span> then <span class="math-container">$W$</span> is lucky.</p> <p><b>Proof.</b> Apply Lemma 2 repeatedly. Lemma 1 ensures that the injection always avoids <span class="math-container">$312$</span>.</p> <p>For the other direction, we need to be slightly more careful.</p> <p><b>Lemma 3.</b> If <span class="math-container">$W$</span> contains a pattern <span class="math-container">$312$</span> in which <span class="math-container">$3$</span> doesn't correspond to <span class="math-container">$W(1)$</span> then <span class="math-container">$N(W)$</span> contains a pattern <span class="math-container">$312$</span>.</p> <p><b>Proof.</b> The pattern survives in <span class="math-container">$N(W)$</span> since all relative positions are maintained.</p> <p><b>Lemma 4.</b> If <span class="math-container">$W$</span> doesn't contain a pattern <span class="math-container">$312$</span> in which <span class="math-container">$3$</span> corresponds to <span class="math-container">$W(1)$</span> and <span class="math-container">$1$</span> corresponds to the minimum of <span class="math-container">$W$</span> then after running one round of the algorithm, <span class="math-container">$S(1)$</span> contains the index of the minimal element, and <span class="math-container">$W \circ S = N(W)$</span>.</p> <p><b>Proof.</b> Follows directly from the proof of Lemma 2.</p> <p>Thus we should expect trouble if there are <span class="math-container">$i&lt;j$</span> such that <span class="math-container">$W(1) &gt; W(j) &gt; W(i)$</span>. However, if <span class="math-container">$W(i)$</span> is not the minimal element, the trouble won't be immediate.</p> <p>List the elements which are smaller than <span class="math-container">$W(1)$</span> as <span class="math-container">$W(t_1),\ldots,W(t_k)$</span>, and suppose that <span class="math-container">$W(t_r) &lt; W(t_{r+1}) &gt; \cdots &gt; W(t_k)$</span>. One round of the algorithm puts <span class="math-container">$t_r$</span> at the place of <span class="math-container">$t_{r+1}$</span>. The following rounds maintain the relative order of the elements in positions <span class="math-container">$t_{r+1},\ldots,t_k$</span>, and so in the final result, the position which should have contained <span class="math-container">$t_{r+1}$</span> will contain <span class="math-container">$t_r$</span>.</p> <p>Example: <span class="math-container">$W = 632541$</span>. The final result is <span class="math-container">$S = 652134$</span>, which corresponds to the permutation <span class="math-container">$143625$</span>. We can see that <span class="math-container">$S(1)$</span> is correct since <span class="math-container">$W$</span> satisfies the conditions of Lemma 4. We have <span class="math-container">$t_r = 3$</span> and <span class="math-container">$W(t_r) = 2, W(t_{r+1}) = 5$</span>. We see that indeed <span class="math-container">$W(S(5)) = 2$</span> instead of <span class="math-container">$5$</span>.</p> <p><b>Theorem 2.</b> If <span class="math-container">$W$</span> contains <span class="math-container">$312$</span> then <span class="math-container">$W$</span> is unlucky.</p> <p><b>Proof.</b> Along the lines of the discussion above.</p>
<p>I think that your program is doing something very similar to a simple stack sort. I found this paper online <a href="http://www.combinatorics.org/Volume_9/PDF/v9i2a1.pdf" rel="nofollow">http://www.combinatorics.org/Volume_9/PDF/v9i2a1.pdf</a> which explains both the basic stack sort and some variations. In the case of the basic stack sort, Donald Knuth has proved that the number of sortable permutations of length n is $C_n$ (this is proposition 1.3 in the linked paper).</p> <p>Your method does not replicate stack sort exactly, but I think it will output a cyclically shifted version of what the stack sort algorithm will produce. I'll edit my answer if I figure out some more details.</p>
linear-algebra
<p>What is an intuitive proof of the multivariable changing of variables formula (Jacobian) without using mapping and/or measure theory?</p> <p>I think that textbooks overcomplicate the proof.</p> <p>If possible, use linear algebra and calculus to solve it, since that would be the simplest for me to understand.</p>
<p>To do it for a particular number of variables is very easy to follow. Consider what you do when you integrate a function of x and y over some region. Basically, you chop up the region into boxes of area ${\rm d}x{~\rm d} y$, evaluate the function at a point in each box, multiply it by the area of the box. This can be notated a bit sloppily as:</p> <p>$$\sum_{b \in \text{Boxes}} f(x,y) \cdot \text{Area}(b)$$</p> <p>What you do when changing variables is to chop the region into boxes that are not rectangular, but instead chop it along lines that are defined by some function, call it $u(x,y)$, being constant. So say $u=x+y^2$, this would be all the parabolas $x+y^2=c$. You then do the same thing for another function, $v$, say $v=y+3$. Now in order to evaluate the expression above, you need to find "area of box" for the new boxes - it's not ${\rm d}x~{\rm d}y$ anymore.</p> <p>As the boxes are infinitesimal, the edges cannot be curved, so they must be parallelograms (adjacent lines of constant $u$ or constant $v$ are parallel.) The parallelograms are defined by two vectors - the vector resulting from a small change in $u$, and the one resulting from a small change in $v$. In component form, these vectors are ${\rm d}u\left\langle\frac{\partial x}{\partial u}, ~\frac{\partial y}{\partial u}\right\rangle $ and ${\rm d}v\left\langle\frac{\partial x}{\partial v}, ~\frac{\partial y}{\partial v}\right\rangle $. To see this, imagine moving a small distance ${\rm d}u$ along a line of constant $v$. What's the change in $x$ when you change $u$ but hold $v$ constant? The partial of $x$ with respect to $u$, times ${\rm d}u$. Same with the change in $y$. (Notice that this involves writing $x$ and $y$ as functions of $u$, $v$, rather than the other way round. The main condition of a change in variables is that both ways round are possible.)</p> <p>The area of a paralellogram bounded by $\langle x_0,~ y_0\rangle $ and $\langle x_1,~ y_1\rangle $ is $\vert y_0x_1-y_1x_0 \vert$, (or the abs value of the determinant of a 2 by 2 matrix formed by writing the two column vectors next to each other.)* So the area of each box is </p> <p>$$\left\vert\frac{\partial x}{\partial u}{\rm d}u\frac{\partial y}{\partial v}{\rm d}v - \frac{\partial y}{\partial u}{\rm d}u\frac{\partial x}{\partial v}dv\right\vert$$</p> <p>or</p> <p>$$\left\vert \frac{\partial x}{\partial u}\frac{\partial y}{\partial v} - \frac{\partial y}{\partial u}\frac{\partial x}{\partial v}\right\vert~{\rm d}u~{\rm d}v$$</p> <p>which you will recognise as being $\mathbf J~{\rm d}u~{\rm d}v$, where $\mathbf J$ is the Jacobian.</p> <p>So, to go back to our original expression</p> <p>$$\sum_{b \in \text{Boxes}} f(x,y) \cdot \text{Area}(b)$$</p> <p>becomes</p> <p>$$\sum_{b \in \text{Boxes}} f(u, v) \cdot \mathbf J \cdot {\rm d}u{\rm d}v$$</p> <p>where $f(u, v)$ is exactly equivalent to $f(x, y)$ because $u$ and $v$ can be written in terms of $x$ and $y$, and vice versa. As the number of boxes goes to infinity, this becomes an integral in the $uv$ plane.</p> <p>To generalize to $n$ variables, all you need is that the area/volume/equivalent of the $n$ dimensional box that you integrate over equals the absolute value of the determinant of an n by n matrix of partial derivatives. This is hard to prove, but easy to intuit.</p> <hr> <p>*to prove this, take two vectors of magnitudes $A$ and $B$, with angle $\theta$ between them. Then write them in a basis such that one of them points along a specific direction, e.g.:</p> <p>$$A\left\langle \frac{1}{\sqrt 2}, \frac{1}{\sqrt 2}\right\rangle \text{ and } B\left\langle \frac{1}{\sqrt 2}(\cos(\theta)+\sin(\theta)),~ \frac{1}{\sqrt 2} (\cos(\theta)-\sin(\theta))\right\rangle $$</p> <p>Now perform the operation described above and you get $$\begin{align} &amp; AB\cdot \frac12 \cdot (\cos(\theta) - \sin(\theta)) - AB \cdot 0 \cdot (\cos(\theta) + \sin(\theta)) \\ = &amp; \frac 12 AB(\cos(\theta)-\sin(\theta)-\cos(\theta)-\sin(\theta)) \\ = &amp; -AB\sin(\theta) \end{align}$$</p> <p>The absolute value of this, $AB\sin(\theta)$, is how you find the area of a parallelogram - the products of the lengths of the sides times the sine of the angle between them.</p>
<p>The multivariable change of variables formula is nicely intuitive, and it's not too hard to imagine how somebody might have derived the formula from scratch. However, it seems that proving the theorem rigorously is not as easy as one might hope.</p> <p>Here's my attempt at explaining the intuition -- how you would derive or discover the formula.</p> <p>The first thing to understand is that if <span class="math-container">$A$</span> is an <span class="math-container">$N \times N$</span> matrix with real entries and <span class="math-container">$S \subset \mathbb R^N$</span>, then <span class="math-container">$$ \tag{1} m(AS) = |\det A| \, m(S). $$</span> Here <span class="math-container">$m(S)$</span> is the area of <span class="math-container">$S$</span> (if <span class="math-container">$N=2$</span>) or the volume of <span class="math-container">$S$</span> (if <span class="math-container">$N=3$</span>) or more generally the Lebesgue measure of <span class="math-container">$S$</span>. Technically I should assume that <span class="math-container">$S$</span> is measurable. The above equation (1) is intuitively clear from the SVD of <span class="math-container">$A$</span>: <span class="math-container">\begin{equation} A = U \Sigma V^T \end{equation}</span> where <span class="math-container">$U$</span> and <span class="math-container">$V$</span> are orthogonal and <span class="math-container">$\Sigma$</span> is diagonal with nonnegative diagonal entries. Multiplying by <span class="math-container">$V^T$</span> doesn't change the measure of <span class="math-container">$S$</span>. Multiplying by <span class="math-container">$\Sigma$</span> scales along each axis, so the measure gets multiplied by <span class="math-container">$\det \Sigma = | \det A|$</span>. Multiplying by <span class="math-container">$U$</span> doesn't change the measure.</p> <p>Next suppose <span class="math-container">$\Omega$</span> and <span class="math-container">$\Theta$</span> are open subsets of <span class="math-container">$\mathbb R^N$</span> and suppose <span class="math-container">$g:\Omega \to \Theta$</span> is <span class="math-container">$1-1$</span> and onto. We should probably assume <span class="math-container">$g$</span> and <span class="math-container">$g^{-1}$</span> are <span class="math-container">$C^1$</span> just to be safe. (Since we're just seeking an intuitive derivation of the change of variables formula, we aren't obligated to worry too much about what assumptions we make on <span class="math-container">$g$</span>.) Suppose also that <span class="math-container">$f:\Theta \to \mathbb R$</span> is, say, continuous (or whatever conditions we need for the theorem to actually be true).</p> <p>Partition <span class="math-container">$\Theta$</span> into tiny subsets <span class="math-container">$\Theta_i$</span>. For each <span class="math-container">$i$</span>, let <span class="math-container">$u_i$</span> be a point in <span class="math-container">$\Theta_i$</span>. Then <span class="math-container">\begin{equation} \int_{\Theta} f(u) \, du \approx \sum_i f(u_i) m(\Theta_i). \end{equation}</span></p> <p>Now let <span class="math-container">$\Omega_i = g^{-1}(\Theta_i)$</span> and <span class="math-container">$x_i = g^{-1}(u_i)$</span> for each <span class="math-container">$i$</span>. The sets <span class="math-container">$\Omega_i$</span> are tiny and they partition <span class="math-container">$\Omega$</span>. Then <span class="math-container">\begin{align} \sum_i f(u_i) m(\Theta_i) &amp;= \sum_i f(g(x_i)) m(g(\Omega_i)) \\ &amp;\approx \sum_i f(g(x_i)) m(g(x_i) + Jg(x_i) (\Omega_i - x_i)) \\ &amp;= \sum_i f(g(x_i)) m(Jg(x_i) \Omega_i) \\ &amp;\approx \sum_i f(g(x_i)) |\det Jg(x_i)| m(\Omega_i) \\ &amp;\approx \int_{\Omega} f(g(x)) |\det Jg(x)| \, dx. \end{align}</span></p> <p>We have discovered that <span class="math-container">\begin{equation} \int_{g(\Omega)} f(u) \, du \approx \int_{\Omega} f(g(x)) |\det Jg(x)| \, dx. \end{equation}</span> By using even tinier subsets <span class="math-container">$\Theta_i$</span>, the approximation would be even better -- so we see by a limiting argument that we actually have equality.</p> <p>At a key step in the above argument, we used the approximation <span class="math-container">\begin{equation} g(x) \approx g(x_i) + Jg(x_i)(x - x_i) \end{equation}</span> which is a good approximation when <span class="math-container">$x$</span> is close to <span class="math-container">$x_i$</span></p>
logic
<p>Is there a proper and precise definition that goes something like this?</p> <p><strong>Definition.</strong> <em>A statement $S$ is a</em> vacuous truth <em>if ... ...</em></p>
<p>No. The phrase "vacuously true" is used informally for statements of the form $\forall a \in X: P(a)$ that happen to be true because $X$ is empty, or even for statements of the form $\forall a \in X: Q(a) \to P(a)$ that happen to be true because no $a \in X$ satisfies $Q(a)$. In both cases, it is irrelevant what statement $P(a)$ is.</p> <p>I guess you could turn this into a formal definition of a property of statement, but that's not standard.</p>
<p>We say that an implication $p\to q$ holds vacuously if $p$ is always false. That is to say, it is impossible to have $p$ true and $q$ false. So the implication is a tautology. </p> <p>Of course tautologies exist in propositional calculus, and not quite in predicate logic (and thus not in first-order logic), but the concept caries over. </p> <p>So when we say that the empty set is a subset of $A$ is vacuously true, we say that there is just no counterexample to the contrary. Why is that true? Because the set is empty. </p>
geometry
<p>I was writing some exercises about the AM-GM inequality and I got carried away by the following (pretty nontrivial, I believe) question:</p> <blockquote> <p><strong>Q:</strong> By properly folding a common <span class="math-container">$210mm\times 297mm$</span> sheet of paper, what is the maximum amount of water such a sheet is able to contain?</p> </blockquote> <p><a href="https://i.sstatic.net/2QDXM.jpg" rel="noreferrer"><img src="https://i.sstatic.net/2QDXM.jpg" alt="enter image description here"></a></p> <p>The volume of the optimal <em>box</em> (on the right) is about <span class="math-container">$1.128l$</span>. But the volume of the <em>butterfly</em> (in my left hand) seems to be much bigger and I am not sure at all about the shape of the optimal folded sheet. Is is something <a href="https://ibb.co/jd5SUJ" rel="noreferrer">boat-like</a>?</p> <p>Clarifications: we may assume to have a magical glue to prevent water from leaking through the cracks, or for glueing together points of the surface. Solutions where parts of the sheet are cut out, <em>then</em> glued back together deserve to be considered as separate cases. On the other hand these cases are trivial, as pointed by joriki in the comments below. The isoperimetric inequality gives that the maximum volume is <span class="math-container">$&lt;2.072l$</span>.</p> <p>As pointed out by Rahul, here it is a way for realizing the optimal configuration: the maximum capacity of the following A4+A4 bag exceeds <span class="math-container">$2.8l$</span>.</p> <p><a href="https://i.sstatic.net/Fy4nf.jpg" rel="noreferrer"><img src="https://i.sstatic.net/Fy4nf.jpg" alt="enter image description here"></a></p>
<p>This problem reminds me of tension field theory and related problems in studying the shape of inflated inextensible membranes (like helium balloons). What follows is far from a solution, but some initial thoughts about the problem. </p> <p>First, since you're allowing creasing and folding, by Nash-Kuiper it's enough to consider short immersions $$\phi:P\subset\mathbb{R}^2\to\mathbb{R}^3,\qquad \|d\phi^Td\phi\|_2 \leq 1$$ of the piece of paper $P$ into $\mathbb{R}^3$, the intuition being that you can always "hide" area by adding wrinkling/corrugation, but cannot "create" area. It follows that we can assume, without loss of generality, that $\phi$ sends the paper boundary $\partial P$ to a curve $\gamma$ in the plane.</p> <p>We can thus partition your problem into two pieces: (I) given a fixed curve $\gamma$, what is the volume of the volume-maximizing surface $M_{\gamma}$ with $\phi(\partial P) = \gamma$? (II) Can we characterize $\gamma$ for which $M_{\gamma}$ has maximum volume?</p> <hr> <p>Let's consider the case where $\gamma$ is given. We can partition $M_{\gamma}$ into</p> <p>1) regions of pure tension, where $d\phi^Td\phi = I$; in these regions $M_{\gamma}$ is, by definition, developable;</p> <p>2) regions where one direction is in tension and one in compression, $\|d\phi^Td\phi\|_2 = 1$ but $\det d\phi^Td\phi &lt; 1$.</p> <p>We need not consider $\|d\phi^Td\phi\|_2 &lt; 1$ as in such regions of pure compression, one could increase the volume while keeping $\phi$ a short map.</p> <p>Let us look at the regions of type (2). We can trace on these regions a family of curves $\tau$ along which $\phi$ is an isometry. Since $M_{\gamma}$ maximizes volume, we can imagine the situation physically as follows: pressure inside $M_{\gamma}$ pushes against the surface, and is exactly balanced by stress along inextensible fibers $\tau$. In other words, for some stress $\sigma$ constant along each $\tau$, at all points $\tau(s)$ along $\tau$ we have $$\hat{n} = \sigma \tau''(s)$$ where $\hat{n}$ the surface normal; it follows that (1) the $\tau$ follow geodesics on $M_{\gamma}$, (2) each $\tau$ has constant curvature.</p> <hr> <p>The only thing I can say about problem (II) is that for the optimal $\gamma$, the surface $M_\gamma$ must meet the plane at a right angle. But there are many locally-optimal solutions that are not globally optimal (for example, consider a half-cylinder (type 1 region) with two quarter-spherical caps (type 2 region); it has volume $\approx 1.236$ liters, less than Joriki's solution).</p> <hr> <p>I got curious so I implemented a quick-and-dirty tension field simulation that optimizes for $\gamma$ and $M_{\gamma}$. Source code is here (needs the header-only Eigen and Libigl libraries): <a href="https://github.com/evouga/DaurizioPaper" rel="noreferrer">https://github.com/evouga/DaurizioPaper</a></p> <p>Here is a rendering of the numerical solution, from above and below (the volume is roughly 1.56 liters).</p> <p><a href="https://i.sstatic.net/pzYjK.png" rel="noreferrer"><img src="https://i.sstatic.net/pzYjK.png" alt="enter image description here"></a></p> <hr> <p>EDIT 2: A sketch of the orientation of $\tau$ on the surface:</p> <p><a href="https://i.sstatic.net/canc5.jpg" rel="noreferrer"><img src="https://i.sstatic.net/canc5.jpg" alt="enter image description here"></a></p>
<p>This is equivalent to the <a href="https://en.wikipedia.org/wiki/Paper_bag_problem" rel="noreferrer">paper bag problem</a>, which asks for the maximum possible volume attainable by inflating an initially flat rectangular pillow made of inextensible material. Separate the two sides of the pillow while keeping their shape, and you obtain (two copies of) your optimal sheet.</p>
logic
<p>I've heard of some other paradoxes involving sets (i.e., &quot;the set of all sets that do not contain themselves&quot;) and I understand how paradoxes arise from them. But this one I do not understand.</p> <p>Why is &quot;the set of all sets&quot; a paradox? It seems like it would be fine, to me. There is nothing paradoxical about a set containing itself.</p> <p>Is it something that arises from the &quot;rules of sets&quot; that are involved in more rigorous set theory?</p>
<p>Let <span class="math-container">$|S|$</span> be the cardinality of <span class="math-container">$S$</span>. We know that <span class="math-container">$|S| &lt; |2^S|$</span>, which can be proven with <a href="https://en.wikipedia.org/wiki/Cantor%27s_diagonal_argument#General_sets" rel="noreferrer">generalized Cantor's diagonal argument</a>.</p> <hr /> <p><strong>Theorem</strong></p> <blockquote> <p>The set of all sets does not exist.</p> </blockquote> <p><strong>Proof</strong></p> <blockquote> <p>Let <span class="math-container">$S$</span> be the set of all sets, then <span class="math-container">$|S| &lt; |2^S|$</span>. But <span class="math-container">$2^S$</span> is a subset of <span class="math-container">$S$</span>. Therefore <span class="math-container">$|2^S| \leq |S|$</span>. A contradiction. Therefore the set of all sets does <strong>not</strong> exist.</p> </blockquote>
<p>Just by itself the notion of a universal set is not paradoxical.</p> <p>It becomes paradoxical when you add the assumption that whenever $\varphi(x)$ is a formula, and $A$ is a preexisting set, then $\{x\in A\mid \varphi(x)\}$ is a set as well.</p> <p>This is known as bounded comprehension, or separation. The full notion of comprehension was shown to be inconsistent by Russell's paradox. But this version is not so strikingly paradoxical. It is part of many of the modern axiomatizations of set theory, which have yet to be shown inconsistent.</p> <p>We can show that assuming separation holds, the proof of the Russell paradox really translates to the following thing: If $A$ is a set, then there is a subset of $A$ which is not an element of $A$.</p> <p>In the presence of a universal set this leads to an outright contradiction, because this subset should be an element of the set of all sets, but it cannot be.</p> <p>But we may choose to restrict the formulas which can be used in this schema of axioms. Namely, we can say "not every formula should define a subset!", and that's okay. Quine defined a set theory called New Foundations, in which we limit these formulas in a way which allows a universal set to exist. Making it consistent to have the set of all sets, if we agree to restrict other parts of our set theory.</p> <p>The problem is that the restrictions given by Quine are much harder to work with naively and intuitively. So we prefer to keep the full bounded comprehension schema, in which case the set of all set cannot exist for the reasons above.</p> <p>While we are at it, perhaps it should be mentioned that the Cantor paradox, the fact that the power set of a universal set must be strictly larger, also fails in Quine's New Foundation for the same reasons. The proof of Cantor's theorem that the power set is strictly larger simply does not go through without using "forbidden" formulas in the process.</p> <p>Not to mention that the Cantor paradox fails if we do not assume the power set axiom, namely it might be that not all sets have a power set. So if the universal set does not have a power set, there is no problem in terms of cardinality.</p> <p>But again, we are taught from the start that these properties should hold for sets, and therefore they seem very natural to us. So the notion of a universal set is paradoxical for us, for that very reason. We are educated with a bias against universal sets. If you were taught that not all sets should have a power set, or that not all sub-collections of a set which are defined by a formula are sets themselves, then neither solution would be problematic. And maybe even you'd find it strange to think of a set theory without a universal set!</p>
probability
<p>In an exam with <span class="math-container">$12$</span> yes/no questions with <span class="math-container">$8$</span> correct needed to pass, is it better to answer randomly or answer exactly <span class="math-container">$6$</span> times yes and 6 times no, given that the answer 'yes' is correct for exactly <span class="math-container">$6$</span> questions?</p> <p>I have calculated the probability of passing by guessing randomly and it is</p> <p><span class="math-container">$$\sum_{k=8}^{12} {{12}\choose{k}}0.5^k0.5^{n-k}=0.194$$</span></p> <p>Now given that the answer 'yes' is right exactly <span class="math-container">$6$</span> times, is it better to guess 'yes' and 'no' <span class="math-container">$6$</span> times each? </p> <p>My idea is that it can be modelled by drawing balls without replacement. The balls we draw are the correct answers to the questions.</p> <p>Looking at the first question, we still know that there are <span class="math-container">$6$</span> yes and no's that are correct. The chance that a yes is right is <span class="math-container">$\frac{6}{12}$</span> and the chance that a no is right is also <span class="math-container">$\frac{6}{12}$</span>. </p> <p>Of course the probability in the next question depends on what the first right answer was. If yes was right, yes will be right with a probability of <span class="math-container">$5/11$</span> and a no is right with the chance <span class="math-container">$6/11$</span>. If no was right, the probabilities would change places.</p> <p>Now that we have to make the choice <span class="math-container">$12$</span> times and make the distinction which one was right, we get <span class="math-container">$2^{12}$</span> paths total. We cannot know what the correct answers to the previous questions were. So we are drawing <span class="math-container">$12$</span> balls at once, but from what urn? It cannot contain <span class="math-container">$24$</span> balls with <span class="math-container">$12$</span> yes and <span class="math-container">$12$</span> no's. Is this model even correct?</p> <p>Is there a more elegant way to approach that?</p> <p>I am asking for hints, not solutions, as I'm feeling stuck. Thank you.</p> <hr> <p><strong>Edit</strong>: After giving @David K's answer more thought, I noticed that the question can be described by the <a href="https://en.wikipedia.org/wiki/Hypergeometric_distribution" rel="noreferrer">hypergeometric distribution</a>, which yields the desired result.</p>
<p>We are given the fact that there are $12$ questions, that $6$ have the correct answer "yes" and $6$ have the correct answer "no."</p> <p>There are $\binom{12}{6} = 924$ different sequences of $6$ "yes" answers and $6$ "no" answers. If we know nothing that will give us a better chance of answering any question correctly than sheer luck, the most reasonable assumption is that every possible sequence of answers is equally likely, that is, each one has $\frac{1}{924}$ chance to occur.</p> <p>So guess "yes" $6$ times and "no" $6$ times. I do not care how you do that: you may guess "yes" for the first $6$, or flip a coin and answer "yes" for heads and "no" for tails until you have used up either the $6$ "yeses" or the $6$ "noes" and the rest of your answers are forced, or you can put $6$ balls labeled "yes" and $6$ labeled "no" in an urn, draw them one at a time, and answer the questions in that sequence.</p> <p>No matter <em>what</em> you do, you end up with some sequence of "yes" $6$ times and "no" $6$ times. You get $12$ correct if and only if the sequence of correct answers is exactly the same as your sequence. That probability is $\frac{1}{924}.$</p> <p>There is no way for you to get $11$ correct. You get $10$ correct if and only if the correct answers are "yes" on $5$ of your "yes" answers and "no" on your other "yes" answers. The number of ways this can happen is the number of ways to choose $5$ correct answers from your $6$ "yes" answers, times the number of ways to choose $5$ correct answers from your $6$ "no" answers: $\binom 65 \times \binom 65 = 36.$</p> <p>There is no way for you to get $9$ correct. You get $8$ correct if and only if the correct answers are "yes" on $4$ of your "yes" answers and "no" on your other "yes" answers. The number of ways this can happen is the number of ways to choose $4$ correct answers from your $6$ "yes" answers, times the number of ways to choose $4$ correct answers from your $6$ "no" answers: $\binom 64 \times \binom 64 = 225.$</p> <p>In any other case you fail. So the chance to pass is $$ \frac{1 + 36 + 225}{924} = \frac{131}{462} \approx 0.283550, $$ which is much better than the chance of passing if you simply toss a coin for each individual question but not nearly as good as getting $4$ or more heads in $6$ coin tosses.</p> <hr> <p>Just to check, we can compute the chance of failing in the same way: $6$ answers correct ($3$ "yes" and $3$ "no"), $4$ answers correct, $2$ correct, $0$ correct. This probability comes to $$ \frac{\binom 63^2 + \binom 62^2 + \binom 61^2 + 1}{924} = \frac{400 + 225 + 36 + 1}{924} = \frac{331}{462} \approx 0.716450, $$ which is the value needed to confirm the answer above.</p>
<p>In terms of balls and urns: Maybe it helps to think about it as follows:</p> <p>You have a red urn and a blue urn, and you have $6$ red balls and $6$ blue balls. You randomly put $6$ of the twelve balls in the red urn, and the other $6$ in the blue urn. Now: what it the chance that at least $8$ balls are in the 'right' (i.e. same colored) urn? </p> <p>Well, to get $8$ correct, you either need to get all $6$ red balls in the red urn ($1$ possibility), or $5$ red ones and $1$ blue in the red urn (${6 \choose 5} \cdot {6 \choose 1} = 6 \cdot 6 = 36$ possibilities), or $4$ red ones and $2$ blue ones (${6 \choose 4} \cdot {6 \choose 2} = 15 \cdot 15 = 225$ possibilities). This is out of a total of ${12 \choose 6} = 924$ possibilities, and so the probability is $\frac{1+36+225}{924}$</p> <p>NOTE: Thanks to @DavidK for pointing out my initial answer was wrong! Everyone please upvote his answer!</p>
matrices
<p>Given a matrix, is the Frobenius norm of that matrix always equal to the 2-norm of it, or are there certain matrices where these two norm methods would produce different results?</p> <p>If they are identical, then I suppose the only difference between them is the method of calculation, eh?</p>
<p>There are three important types of matrix norms. For some matrix $A$</p> <ul> <li><p>Induced norm, which measures what is the maximum of $\frac{\|Ax\|}{\|x\|}$ for any $x \neq 0$ (or, equivalently, the maximum of $\|Ax\|$ for $\|x\|=1$).</p></li> <li><p>Element-wise norm, which is like unwrapping $A$ into a long vector, then calculating its vector norm.</p></li> <li><p>Schatten norm, which measures the vector norm of the singular values of $A$.</p></li> </ul> <p>So, to answer your question:</p> <ul> <li><p>Frobenius norm = Element-wise 2-norm = Schatten 2-norm</p></li> <li><p>Induced 2-norm = Schatten $\infty$-norm. This is also called Spectral norm.</p></li> </ul> <p>So if by "2-norm" you mean element-wise or Schatten norm, then they are identical to Frobenius norm. If you mean induced 2-norm, you get spectral 2-norm, which is $\le$ Frobenius norm. (It should be less than or equal to)</p> <p>As far as I can tell, if you don't clarify which type you're talking about, induced norm is usually implied. For example, in matlab, norm(A,2) gives you induced 2-norm, which they simply call the 2-norm. So in that sense, the answer to your question is that the (induced) matrix 2-norm is $\le$ than Frobenius norm, and the two are only equal when all of the matrix's eigenvalues have equal magnitude.</p>
<p>The 2-norm (spectral norm) of a matrix is the greatest distortion of the unit circle/sphere/hyper-sphere. It corresponds to the largest singular value (or |eigenvalue| if the matrix is symmetric/hermitian). </p> <p>The Forbenius norm is the "diagonal" between all the singular values.</p> <p>i.e. <span class="math-container">$$||A||_2 = s_1 \;\;,\;\;||A||_F = \sqrt{s_1^2 +s_2^2 + ... + s_r^2}$$</span> </p> <p>(r being the rank of A). </p> <p>Here's a 2D version of it: <span class="math-container">$x$</span> is any vector on the unit circle. <span class="math-container">$Ax$</span> is the deformation of all those vectors. The length of the red line is the 2-norm (biggest singular value). And the length of the green line is the Forbenius norm (diagonal). <a href="https://i.sstatic.net/voFvR.png" rel="noreferrer"><img src="https://i.sstatic.net/voFvR.png" alt="enter image description here"></a></p>
geometry
<p>Is there a geometric intuition for integration by parts?</p> <p><span class="math-container">$$\int f(x)g'(x)\,dx = f(x)g(x) - \int g(x)f'(x)\,dx$$</span></p> <p>This can, of course, be shown algebraically by product rule, but still where is geometric intuition? I have seen geometry of IBP using parametric equations but I don't get it.</p> <p>Newest edit: few similar questions has been asked before, but they use parametric equations to show geometry behind IBP. I am interested if there is geometric intuition which uses functions in Cartesian plane or some other, maybe more natural, explanation.</p>
<p><em>Note.</em> Edited because Adayah pointed out (correctly, and to my chagrin) that this answer was totally sloppy—sloppier even than I intended it to be. Let's hope it's better now.</p> <hr /> <p>When we use integration by parts on an integral</p> <p><span class="math-container">$$ \int u(x) \, \mathrm{d}v(x) = \int u(x) v'(x) \, \mathrm{d}x $$</span></p> <p>we implicitly treat <span class="math-container">$u$</span> and <span class="math-container">$v$</span> as parametric functions of <span class="math-container">$x$</span>. If we plot these functions against each other on the <span class="math-container">$u$</span>-<span class="math-container">$v$</span> plane, we might obtain something like the below:</p> <p><a href="https://i.sstatic.net/PKZz2.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/PKZz2.png" alt="enter image description here" /></a></p> <p>(Note that <span class="math-container">$v$</span> is on the horizontal axis, and <span class="math-container">$u$</span> on the vertical.) In this diagram, the purple region below the curve represents the definite integral</p> <p><span class="math-container">$$ \int_{v(x)=2}^3 u(x) \, \mathrm{d}v(x) = \int_{x=v^{-1}(2)}^{v^{-1}(3)} u(x) v'(x) \, \mathrm{d}x $$</span></p> <p>Similarly, the blue region to the left of the curve represents the definite integral</p> <p><span class="math-container">$$ \int_{u(x)=1}^2 v(x) \, \mathrm{d}u(x) = \int_{x=u^{-1}(1)}^{u^{-1}(2)} v(x) u'(x) \, \mathrm{d}x $$</span></p> <p>Note that we can set</p> <ul> <li><span class="math-container">$x_1$</span> such that <span class="math-container">$u(x_1) = 1$</span> and <span class="math-container">$v(x_1) = 2$</span></li> <li><span class="math-container">$x_2$</span> such that <span class="math-container">$u(x_2) = 2$</span> and <span class="math-container">$v(x_2) = 3$</span></li> </ul> <p>and so we can relate those two integrals by</p> <p><span class="math-container">$$ \int_{x=x_1}^{x_2} u(x) v'(x) \, \mathrm{d}x = \left. u(x) v(x) \phantom\int\!\!\!\!\! \right]_{x=x_1}^{x_2} - \int_{x=x_1}^{x^2} v(x) u'(x) \, \mathrm{d}x $$</span></p> <hr /> <p>Obviously this simple visualization of integration by parts relies (at least to some degree) on <span class="math-container">$u(x)$</span> and <span class="math-container">$v(x)$</span> being one-to-one; otherwise, we have to use signed areas. However, the necessary rigor can be added. I'm making the assumption that rigor was not what was needed here. (ETA: Though more than I provided at first!)</p>
<p>In light of @Adayah's observations, I'll offer a different geometric intuition for <span class="math-container">$fdg=d(fg)-gdf$</span>, which integrates to the desired result. Consider the special case <span class="math-container">$f,\,g,\,df,\,dg&gt;0$</span>, so we can draw an <span class="math-container">$f\times g$</span> rectangle inside an <span class="math-container">$(f+df)\times (g+dg)$</span> rectangle. Apart from a negligible <span class="math-container">$df\times dg$</span> corner piece, the trimming <span class="math-container">$d(fg)$</span> outside the slightly smaller rectangle is two rectangles of areas <span class="math-container">$fdg,\,gdf$</span>.</p>
linear-algebra
<p>As it is mentioned in the answer by <em>Sheldon Axler</em> in <a href="https://math.stackexchange.com/questions/1877766/what-is-the-definition-of-linear-algebra/1878206#1878206">this post</a>, we usually restrict linear algebra to finite dimensional linear spaces and study the infinite dimensional ones in functional analysis. </p> <p>I am wondering that what are those parts of the theory in linear algebra that restrict it to finite dimensions. To clarify myself, here is the main question</p> <blockquote> <p><strong>Question</strong>.<br> What are the <strong>main</strong> theorems in linear algebra that are just valid for finite dimensional linear spaces and are propagated in the sequel of theory, used to prove the following theorems?</p> </blockquote> <p>Please note that I want to know the <strong>main</strong> theorems that are just valid for finite dimensions not <strong>all</strong> of them. By <strong>main</strong>, I mean the minimum number of theorems of this kind such that all other such theorems can be concluded from these.</p>
<p>In finite-dimensional spaces, the main theorem is the one that leads to the definition of dimension itself: that any two bases have the same number of vectors. All the others (e.g., reducing a quadratic form to a sum of squares) rest on this one.</p> <p>In infinite-dimensional spaces, (1) the linearity of an operator generally does not imply continuity (boundedness), and, for normed spaces, (2) "closed and bounded" does not imply "compact" and (3) a vector space need not be isomorphic to its dual space via canonical isomorphism. </p> <p>Furthermore, in infinite-dimensional vector spaces there is no natural definition of a volume form.</p> <p>That's why Halmos's <em>Finite-Dimensional Vector Spaces</em> is probably the best book on the subject: he was a functional analyst and taught finite-dimensional while thinking infinite-dimensional.</p>
<p>To add to avs's answer, in finite dimensions you have the result that a linear operator $V\to V$ is injective iff surjective. This fails in infinite dimensions.</p>
probability
<p>In an exam with <span class="math-container">$12$</span> yes/no questions with <span class="math-container">$8$</span> correct needed to pass, is it better to answer randomly or answer exactly <span class="math-container">$6$</span> times yes and 6 times no, given that the answer 'yes' is correct for exactly <span class="math-container">$6$</span> questions?</p> <p>I have calculated the probability of passing by guessing randomly and it is</p> <p><span class="math-container">$$\sum_{k=8}^{12} {{12}\choose{k}}0.5^k0.5^{n-k}=0.194$$</span></p> <p>Now given that the answer 'yes' is right exactly <span class="math-container">$6$</span> times, is it better to guess 'yes' and 'no' <span class="math-container">$6$</span> times each? </p> <p>My idea is that it can be modelled by drawing balls without replacement. The balls we draw are the correct answers to the questions.</p> <p>Looking at the first question, we still know that there are <span class="math-container">$6$</span> yes and no's that are correct. The chance that a yes is right is <span class="math-container">$\frac{6}{12}$</span> and the chance that a no is right is also <span class="math-container">$\frac{6}{12}$</span>. </p> <p>Of course the probability in the next question depends on what the first right answer was. If yes was right, yes will be right with a probability of <span class="math-container">$5/11$</span> and a no is right with the chance <span class="math-container">$6/11$</span>. If no was right, the probabilities would change places.</p> <p>Now that we have to make the choice <span class="math-container">$12$</span> times and make the distinction which one was right, we get <span class="math-container">$2^{12}$</span> paths total. We cannot know what the correct answers to the previous questions were. So we are drawing <span class="math-container">$12$</span> balls at once, but from what urn? It cannot contain <span class="math-container">$24$</span> balls with <span class="math-container">$12$</span> yes and <span class="math-container">$12$</span> no's. Is this model even correct?</p> <p>Is there a more elegant way to approach that?</p> <p>I am asking for hints, not solutions, as I'm feeling stuck. Thank you.</p> <hr> <p><strong>Edit</strong>: After giving @David K's answer more thought, I noticed that the question can be described by the <a href="https://en.wikipedia.org/wiki/Hypergeometric_distribution" rel="noreferrer">hypergeometric distribution</a>, which yields the desired result.</p>
<p>We are given the fact that there are $12$ questions, that $6$ have the correct answer "yes" and $6$ have the correct answer "no."</p> <p>There are $\binom{12}{6} = 924$ different sequences of $6$ "yes" answers and $6$ "no" answers. If we know nothing that will give us a better chance of answering any question correctly than sheer luck, the most reasonable assumption is that every possible sequence of answers is equally likely, that is, each one has $\frac{1}{924}$ chance to occur.</p> <p>So guess "yes" $6$ times and "no" $6$ times. I do not care how you do that: you may guess "yes" for the first $6$, or flip a coin and answer "yes" for heads and "no" for tails until you have used up either the $6$ "yeses" or the $6$ "noes" and the rest of your answers are forced, or you can put $6$ balls labeled "yes" and $6$ labeled "no" in an urn, draw them one at a time, and answer the questions in that sequence.</p> <p>No matter <em>what</em> you do, you end up with some sequence of "yes" $6$ times and "no" $6$ times. You get $12$ correct if and only if the sequence of correct answers is exactly the same as your sequence. That probability is $\frac{1}{924}.$</p> <p>There is no way for you to get $11$ correct. You get $10$ correct if and only if the correct answers are "yes" on $5$ of your "yes" answers and "no" on your other "yes" answers. The number of ways this can happen is the number of ways to choose $5$ correct answers from your $6$ "yes" answers, times the number of ways to choose $5$ correct answers from your $6$ "no" answers: $\binom 65 \times \binom 65 = 36.$</p> <p>There is no way for you to get $9$ correct. You get $8$ correct if and only if the correct answers are "yes" on $4$ of your "yes" answers and "no" on your other "yes" answers. The number of ways this can happen is the number of ways to choose $4$ correct answers from your $6$ "yes" answers, times the number of ways to choose $4$ correct answers from your $6$ "no" answers: $\binom 64 \times \binom 64 = 225.$</p> <p>In any other case you fail. So the chance to pass is $$ \frac{1 + 36 + 225}{924} = \frac{131}{462} \approx 0.283550, $$ which is much better than the chance of passing if you simply toss a coin for each individual question but not nearly as good as getting $4$ or more heads in $6$ coin tosses.</p> <hr> <p>Just to check, we can compute the chance of failing in the same way: $6$ answers correct ($3$ "yes" and $3$ "no"), $4$ answers correct, $2$ correct, $0$ correct. This probability comes to $$ \frac{\binom 63^2 + \binom 62^2 + \binom 61^2 + 1}{924} = \frac{400 + 225 + 36 + 1}{924} = \frac{331}{462} \approx 0.716450, $$ which is the value needed to confirm the answer above.</p>
<p>In terms of balls and urns: Maybe it helps to think about it as follows:</p> <p>You have a red urn and a blue urn, and you have $6$ red balls and $6$ blue balls. You randomly put $6$ of the twelve balls in the red urn, and the other $6$ in the blue urn. Now: what it the chance that at least $8$ balls are in the 'right' (i.e. same colored) urn? </p> <p>Well, to get $8$ correct, you either need to get all $6$ red balls in the red urn ($1$ possibility), or $5$ red ones and $1$ blue in the red urn (${6 \choose 5} \cdot {6 \choose 1} = 6 \cdot 6 = 36$ possibilities), or $4$ red ones and $2$ blue ones (${6 \choose 4} \cdot {6 \choose 2} = 15 \cdot 15 = 225$ possibilities). This is out of a total of ${12 \choose 6} = 924$ possibilities, and so the probability is $\frac{1+36+225}{924}$</p> <p>NOTE: Thanks to @DavidK for pointing out my initial answer was wrong! Everyone please upvote his answer!</p>
number-theory
<p>The number $128$ can be written as $2^n$ with integer $n$, and so can its every individual digit. Is this the only number with this property, apart from the one-digit numbers $1$, $2$, $4$ and $8$? </p> <p>I have checked a lot, but I don't know how to prove or disprove it. </p>
<p>This seems to be an open question. See <a href="http://oeis.org/A130693">OEIS sequence A130693</a> and references there.</p>
<p>Here's some empirical evidence (not a proof!).</p> <p>Here are the first powers which increase the length of 1-2-4-8 runs in the least significant digits (last digits):</p> <pre> Power 0: 1 digits. ...0:1 Power 7: 3 digits. ...0:128 Power 18: 4 digits. ...6:2144 Power 19: 5 digits. ...5:24288 Power 90: 6 digits. ...9:124224 Power 91: 7 digits. ...9:8248448 Power 271: 8 digits. ...0:41422848 Power 1751: 9 digits. ...3:242421248 Power 18807: 10 digits. ...9:8228144128 Power 56589: 14 digits. ...3:21142244442112 Power 899791: 16 digits. ...9:8112118821224448 Power 2814790: 17 digits. ...6:42441488812212224 Power 7635171: 19 digits. ...5:2288212218148814848 Power 39727671: 20 digits. ...6:48844421142411214848 Power 99530619: 21 digits. ...6:142118882828812812288 Power 233093807: 25 digits: ...0:2821144412811214484144128 Power 22587288091 : 26 digits: ...9:81282288882824141181288448 </pre> <p>Easy to see, this run length grows veeeery slow: $25$ digits of $233093807*log_{10}2 \approx 70168227$ decimal digits are powers of 2. Hardly 25 can reach 70168227.</p> <p>Let's look at it deeper. Consider $2^k$ having $n$ decimal digits (obviously $n \le k$). Let's say $2^k \mod 5^n = a$. Then by CRT we can recover $2^k \mod 10^n$ (note that $2^k \equiv 0 \pmod {2^n}$):</p> <p>$$f(a) \equiv 2^k \equiv a \cdot 2^n \cdot (2^{-n})_{\mod 5^n} \pmod{10^n}$$</p> <p>Now <strong>let's assume</strong> that $2^k$ randomly goes over $\mod 5^n$. How many there are elements $x \in (0,\dots,5^n-1)$ such that $f(x) \mod 10^n$ consists from digits 1-2-4-8? There are at most $4^n$ such values (all possible combinations of 1-2-4-8 $n$ times), from $5^n$ (remark - we should consider only coprime with 5 numbers, there are $5^{n-1}*4$ such). So if $2^k$ <em>acts randomly</em>, then the probability of getting 1-2-4-8 value is limited by $(4/5)^{n-1}$, which decreases exponentially with $n$ (and $k$).</p> <p>Now how much powers of 2 do we have for each $n$? Constant amount, 3 or 4! So, if for some small $n$ there are no such values, then very probably for all numbers it's also true.</p> <p>Remark: this may look mouthful, nearly same explanation could be given modulo $10^n$. But in my opinion it's easier to believe that $2^k$ randomly goes over $\mod 5^n$ than $\mod 10^n$. <strong>EDIT</strong>: Also, $2$ is a primitive root modulo $5^n$ for any $n$, so it indeed goes over all $5^{n-1}*4$ accounted values.</p> <p>Remark 2: the exact amount of $x$, such that $f(x) \mod 10^n$ consist from digits 1-2-4-8, from experiments:</p> <pre> ... n=15: 54411 / 30517578125 ~= 2^-19.0973107004 n=16: 108655 / 152587890625 ~= 2^-20.4214544789 n=17: 216803 / 762939453125 ~= 2^-21.7467524186 n=18: 433285 / 3814697265625 ~= 2^-23.0697489411 n=19: 866677 / 19073486328125 ~= 2^-24.3914989097 n=20: 1731421 / 95367431640625 ~= 2^-25.7150367656 ... </pre> <p><strong>UPD:</strong></p> <p>The fact that $2$ is a primitive root modulo $5^n$ is quite important.</p> <ol> <li><p>We can use it to optimize search for first powers of 2 which increase the 1-2-4-8 run length (first data in this post). For example, for $n=3$ only $13$ of $5^2*4=100$ values correspond to 1-2-4-8 3-digit endings. For $\mod 1000$, period for powers of 2 is equal to order of the group, namely $100$. It means we need to check only 13 of each 100 values. I managed to build the table for $n=20$ which speeds up the computation roughly by $2^{25}$. Sadly each next $n$ for the table is much harder to compute, so this approach does not scale efficiently.</p></li> <li><p>For arbitrary $n$ we can quite efficiently find some $k$ such that $2^k$ has last $n$ digits-powers-of-two.<br> Let's assume that for some $n$ we know such $k_0$. Consider $a = 2^{k_0} \mod 10^n$. We want to construct $k'$ for $n+1$. Let's look at $a \mod 2^{n+1}$. It's either $0$ or $2^{n}$. If it's $0$, we can set $(n+1)$'s digit to any from $0,2,4,6,8$, in particular $2,4,8$ will fit our goal. If it's $2^{n}$ then we need to set $(n+1)$'s digit to any from $1,3,5,7,9$, in particular $1$ will be fine for us.<br> After setting the new digit we have some value $a' &lt; 10^{n+1}$. We now find $k'$ by calculating discrete logarithm of $a'$ base $2$ in the group $(\mathbb{Z}/5^{n+1}\mathbb{Z})^*$. It must exist, because $2$ is primitive root modulo $5^{n+1}$ and $a'$ is not divisible by five (meaning that it falls into the multiplicative group).</p></li> </ol> <p>Summing up, it's possible to extend any existing 1-2-4-8 tail either with $1$, or with any of $2,4,8$. For example, tail of length 1000, consisting only of 1 and 2:</p> <pre><code>sage: k 615518781133550927510466866560333743905276469414384071264775976996005261582333424319169262744569107203933909361398767112744041716987032548389396865721149211989700277761744700088281526981978660685104481509534097152083798849174934153949598921020219299137483196605381824600377210207048355959118105502326334547495384673753323864726827644650703466356156319492521379682428275201262134907960967634887658195264018797348236155773958687977059474419550906257366056229915615067527218040720408353328787880060032847746927391316869927283585312014157952623949696812057481086276896651244409107902992111507870787820359137244857060839675634572294938878098506151681269336043213294287160464665102314138635395739226878089 sage: print pow(2, k, 10**1000) 1112221212111222212111211212211112121221111221112211221212222212222111211212111122221111222222211112222211112122111222122222212222111221111112211122121122221212111122212112211122121121212211211221122111111111111121211111211212222212112121222221221122111222221222222122212221212111121111112111211222111111211222222222112222212112211212121122212122222211111121112122122112112122222212121121222221112121221222221121122221121222121112111121221221212211121221122121122122122112112112111222212111111221121211211122222122211122211211222122122211112121121111211222211211212211112111212121212111222221212221211212222121122221211112222211221121221211211221222211112121221222122112122221221221221221222211122222222222222222222111121122221121121212111222211112122112112222112221212111112121221221121211221111121212111111121212222212211222122122212112211221221112222121221212121121112111222221122221221121111212121211211211221121211211121122122211212221112122111122212112212121112121121122111112111211111212122112 </code></pre>
game-theory
<p>Just learning about Nash Equilibria. The pure strategy one is explained as an outcome where both/all players feel like they couldn't have done better given what the others were doing. Mixed strategy is one where even after announcing your strategy openly, your opponents can make any choice without affecting their expected gains. Is there a relationship between the two ? Is the pure strategy one some sort of special case for the mixed strategy one ? (I doubt it, since there can be multiple pure ones, while the linear equations of the mixed one can only give one or infinite number of results). I'd like to intuitively understand the relationship. Thanks !</p>
<p>If you like, you can think of a pure strategy as a mixed strategy in which a player has a 100% chance of picking a certain strategy.</p> <p>The equilibrium definition is the same for both pure and mixed strategy equilibria ("even after announcing your strategy openly, your opponents can make any choice without affecting their expected gains"). The difference is that in a mixed equilibrium, you are announcing your <em>probability distribution</em>, not the strategy that it randomly produces.</p> <p>Example: Rock-Paper-Scissors. There are no pure strategy equilibria: If I announce "I'm going to play definitely Rock!" then clearly my opponent will choose Paper; if I know they're going to play paper then I don't want to play Rock anymore, so this is not stable. However, if I announce "I'm going to secretly roll a die, play Rock if it shows 1-2, Scissors for 3-4, and Paper for 5-6!" then my opponent is equally happy with any choice he makes. If he therefore chooses the same strategy as me, then <em>I</em> am equally happy with any choice I make, so this is a mixed equilibrium.</p> <p>Also, your statement "the linear equations of the mixed one can only give one or infinite number of results" isn't true - there are many games with an in-between number of equilibria (<a href="http://en.wikipedia.org/wiki/Chicken_%28game%29">Chicken</a>, for example, has 3 in a two-player version of the game). As an aside, a randomly-generated game will have a finite, odd number of equilibria with probability 1, but that's about all you can say about the number of equilibria.</p>
<p>As far as I know, a mixed strategy vector is a randomized vector where each player can play some action with some probability. i.e., if you play action $a$ with probability $p_a$, I can play (for example) an action $b$ with probability $p_b$. So the set of actions is randomized. There is a random play! That's why it is called $\mathbf{mixed}$.</p> <p>In pure strategy, if you play $a$ (with probability $1$), I can play for example the same action $a$ but with probability $1$. There is no random play! That's why it is called $\mathbf{pure}$.</p> <p>In fact, mixed strategy is used to guarantee that every game has at least one Nash equilibrium. Randomize the set of strategy to make them convex sets and apply <a href="http://en.wikipedia.org/wiki/Brouwer_fixed-point_theorem" rel="nofollow">Brouwer fixed point Theorem</a> to prove this result. A well known theorem due to <a href="http://en.wikipedia.org/wiki/Nash_equilibrium" rel="nofollow">Nash</a>.</p>
game-theory
<p>Everyone knows rock, paper, scissors. Now a long time ago, when I was a child, someone claimed to me that there was not only those three, but also as fourth option the well. The well wins against rock and scissors (because both fall into it) but loses against paper (because the paper covers it).</p> <p>Now I wonder: What would be the ideal playing strategy for rock, paper, scissors, well?</p> <p>It's obvious that now the different options are no longer on equal footing. The well wins against two of the three other options, and also the paper now wins over two options, namely rock and well. On the other hand, rock and scissors only win on one of their three possible opponents.</p> <p>Moreover, the scissors seem to have an advantage to the rock, as it wins against a "strong" symbol, namely paper, while the rock only wins against the "weak" symbol scissors.</p> <p>Only playing "strong" symbols is obviously not a good idea because of those two, the paper always wins, so if both players only played strong symbols, the clear winning strategy would be to play paper each time; however if you play paper each time, you're predictable, and your opponent can beat you by selecting scissors.</p> <p>So what if you play only well, paper and scissors, but all with the same probability? If your opponent knows or guesses it, it's obviously undesirable to choose rock, because in two of three cases he'd lose, while with any other symbol, he'd lose only in one of three cases. But if nobody plays rock, we are effectively at the original three-symbol game, except that the rock is now replaced by the well.</p> <p>Therefore my hypothesis is: The ideal strategy for this game is to never play rock, and play each other symbol with equal probability.</p> <p>Is my hypothesis right? If not, what is the ideal strategy?</p>
<p>You are quite right. Rock is dominated by Well: no matter what the opponent plays, you do at least as well playing Well as you would playing Rock, and against Rock or Well you do better. Good players will never play Rock, so the game reduces to Well, Paper, Scissors, which is isomorphic to Rock, Paper, Scissors.</p>
<p>Mixing evenly between paper, scissors, and well is indeed an equilibrium. </p> <p>Starting with Vadim's condition:</p> <p>$$ p-s+(1-r-p-s)=\\-r+s-(1-r-p-s)=\\r-p+(1-r-p-s)=\\-r+p-s$$</p> <p>If Rock receives no weight, we have:</p> <p>$$s-(1-p-s)=\\-p+(1-p-s)=\\p-s$$</p> <p>Which gives $p=s=(1-p-s)=\frac{1}{3}$</p> <p>Further, Rock is dominated by any combination of the other three strategies against this mixture. Thus, any mixture of the three is indeed a best response to an equal mixture and so the equal mixture is a Nash equilibrium. </p> <p>To see there is no other equilibrium, we can use the fact that in a symmetric non-zero sum game, any strategy optimal for one player is optimal for another. Note that when rock receives weight in opponent's strategy, rock is strictly dominated by well. Thus, rock cannot be part of an equilibrium since it would imply that rock is part of an optimal strategy against a strategy that includes positive weight on rock. </p>
combinatorics
<p>It seems easy to grasp that number of ways of choosing <span class="math-container">$n$</span> items from <span class="math-container">$n$</span> items is 1. But I am unable to understand why is it 1 for choosing 0 items.</p>
<p>When you phrase it in plain English, the answer isn't necessarily totally clear. It might seem reasonable to argue that there are <span class="math-container">$0$</span> ways of choosing <span class="math-container">$0$</span> things from <span class="math-container">$n$</span>, since choosing <span class="math-container">$0$</span> things isn't really a choice. However, when mathematicians talk about "the number of ways to choose <span class="math-container">$0$</span> from <span class="math-container">$n$</span>," we mean something a bit more specific. </p> <p>A few ways of describing what we mean:</p> <ol> <li>The number of subsets of an <span class="math-container">$n$</span>-element set with <span class="math-container">$0$</span> elements (and we always assume the empty set counts)</li> <li>The number of functions from a <span class="math-container">$0$</span>-element set to an <span class="math-container">$n$</span>-element set, up to permutations of the domain (there's exactly one function from the empty set to any set).</li> <li>The coefficient of <span class="math-container">$x^0y^n$</span> in the expansion of the binomial <span class="math-container">$(x+y)^n$</span>. </li> </ol> <p>All of these agree that there is <em>one</em> way to choose <span class="math-container">$0$</span> out of <span class="math-container">$n$</span> things, and all of these perspectives are mathematically very useful. Thus the perspective that there is a way to choose <span class="math-container">$0$</span> out of <span class="math-container">$n$</span> things is universal in mathematics. </p> <p>This wasn't always so obvious to everyone: for instance, I have heard of an early 20th century mathematician who insisted in his books that all intersections be nonempty to be defined. It seems to me that this would be consistent with refusing to accept the empty set as a subset, and with saying there are <span class="math-container">$0$</span> ways to choose <span class="math-container">$0$</span> things from <span class="math-container">$n$</span>. But this would make for lots of inconvenient circumlocutions, so we've settled pretty firmly on the other solution.</p>
<p>Perhaps a little duality argument can help to provide some intuition.</p> <p>Given a bag of <span class="math-container">$n$</span> balls, consider these two tasks:</p> <ol> <li>choose <span class="math-container">$k$</span> balls inside the bag, and remove <em>them</em> from the bag</li> <li>choose <span class="math-container">$n-k$</span> balls inside the bag, and remove <em>all the others</em> from the bag</li> </ol> <p>Intuition suggests that these tasks are essentially the same: choosing which <span class="math-container">$k$</span> balls we remove corresponds to choosing which <span class="math-container">$n-k$</span> balls we keep in the bag.</p> <p>Indeed, there are as many ways to choose <span class="math-container">$k$</span> balls (to remove) as there are to choose <span class="math-container">$n-k$</span> balls (to keep).</p> <p>In particular, to determine how many ways we have to choose (and remove) <span class="math-container">$0$</span> balls, we can equivalently count how many ways we have to choose (and keep) <span class="math-container">$n-0=n$</span> balls. In your own question, you agree on there being only one way to choose <span class="math-container">$n$</span> balls out of <span class="math-container">$n$</span>. Hence, "one way to choose what to keep" can be restated as "one way to choose what to remove". </p>
logic
<p>Let a statement P is "X is true if and only if Y is true". What is the negation of P? I am little confused. It seems that digital equivalent of this statement is P = X and Y. Hence negation of P is (not X) or (not Y) i.e. Either X or Y is false. Am I right guys? </p>
<p>$X\leftrightarrow Y$ is the conjunction of $X\leftarrow Y$ and $X\rightarrow Y$. The negation of a conjunction is the disjunction of the negations; the negation of $P\rightarrow Q$ is $P\wedge \neg Q$. So we have: \begin{align*} \neg(X\leftrightarrow Y) &amp;\Longleftrightarrow \neg\Bigl( (X\rightarrow Y)\wedge (Y\rightarrow X)\Bigr)\\ &amp;\Longleftrightarrow \neg(X\rightarrow Y)\vee \neg(Y\rightarrow X)\\ &amp;\Longleftrightarrow (X\wedge \neg Y) \vee (Y\wedge \neg X). \end{align*} So the negation of "$X$ is true if and only if $Y$ is true" is "Either $X$ is true and $Y$ is false, or $X$ is false and $Y$ is true." <em>Added</em>: as it happens, as noted by Rahul Narain in his comment, this is in turn equivalent to "$X$ is true if and only if $Y$ is false" (just compare the cases when they are each true). So you also get that $$\neg(X\leftrightarrow Y) \Longleftrightarrow X\leftrightarrow \neg Y \Longleftrightarrow \neg X\leftrightarrow Y.$$</p>
<p>The digital equivalent is P = X XNOR Y, and thus the negation is (not P) = X XOR Y. In other words, P is false when X is true but Y is false, or when X is false but Y is true.</p>
logic
<p>All the definitions I came across so far stated, that if a statement is true, then also its dual statement is true and this dual statement is obtained by changing <code>+</code> for <code>.</code>, <code>0</code> for <code>1</code> and vice versa.</p> <p>However when I say <code>1+1</code>, whose dual statement according to the above is <code>0.0</code>, I get opposite results, that is:</p> <pre><code>1 + 1 = 1 0 . 0 = 0 </code></pre> <p>How should I understand this duality principle ?</p>
<p>"$1 + 1 = 1$" is a <em>statement</em> (a boolean statement, in fact), and indeed, $1 + 1 = 1$ happens to be a true statement.</p> <p>Likewise, the entire statement "$0 \cdot 0 = 0$" is a <em>true statement</em>, since $0 \cdot 0$ <em>correctly</em> evaluates to false: and this is exactly what "$0 \cdot 0 = 0$" asserts, so it is a correct (true) statement about the falsity of $0 \cdot 0$. </p> <p>The duality principle ensures that "if we exchange <strong>every</strong> symbol by its dual in a formula, we get the <strong>dual</strong> result".</p> <ul> <li>Everywhere we see 1, change to 0. </li> <li>Everywhere we see 0, change to 1. </li> <li>Similarly, + to $\cdot$, and $\cdot$ to +.</li> </ul> <hr> <p>More examples:</p> <p>(a) <code>0 . 1 = 0</code>: is a true statement asserting that "false and true evaluates to false"</p> <p>(b) <code>1 + 0 = 1</code>: is the dual of (a): it is a true statement asserting that "true or false evaluates true."</p> <hr> <p>(c) <code>1 . 1 = 1</code>: it is a true statement asserting that "true and true evaluates to true".</p> <p>(d) <code>0 + 0 = 0</code>: (d) is the dual of (c): it is a true statement asserting, correctly, that "false or false evaluates to false".</p>
<p>The statement is the full equation, including the = sign. <code>1+1</code> is neither true nor false: it takes the value <code>1</code>, but it is not actually saying anything. Analogously, the expression "Tom has a cat" is neither true nor false (without specifying who Tom is) - it is an expression which could be true or false, depending on who we mean when we say "Tom".</p> <p>On the other hand, the statement <code>1+1=0</code> is a false. Analogously, the statement "If Tom has a cat then Tom has no cats" is false, no matter who we mean when we say "Tom".</p> <p>In this case, <code>1+1=1</code> is the true statement. Its dual is <code>0.0=0</code>, which is also a true statement.</p>
logic
<p>I don't know if that is something obvious or if it is a dumb question. But it seems to be true.</p> <p>Consider the non-theorem $\forall x. x &lt; 1$. Its negation is $\exists x. x \geq 1$ and is a theorem. Is this always true?</p> <p>I couldn't find a counterexample.</p> <p>If this is true I would like to know a good explanation why.</p>
<p>It's neither obvious nor a dumb question. But it is, perhaps surprisingly, sensitive to what theory, or at least what language, you're proving things in. I assume you intend the example you gave, $(\exists x)\,x\ge1$, as a sentence about the real numbers. The reals are a <a href="https://en.wikipedia.org/wiki/Real_closed_field" rel="nofollow">real closed field</a>, and the theory of real closed fields is complete: every sentence or its negation is a theorem. So this really is a special case: as fate would have it, for this theory, the negation of every non-theorem actually is a theorem, so you'll search in vain for a counterexample.</p> <p>However, the same cannot be said for arithmetic, as formalized by Peano arithmetic (PA): there are sentences $S$ in the language of arithmetic such that neither $S$ nor $\neg S$ is a theorem of PA (assuming, of course, that PA is consistent). Examples include Gödel sentences (true sentences asserting their own unprovability within the system), as well as more natural sentences: <a href="http://www.wikipedia.or.ke/index.php?title=Goodstein%27s_theorem" rel="nofollow">Goodstein's theorem</a>, which Kirby and Paris showed is unprovable in PA, and a true sentence about finite Ramsey theory which <a href="https://en.wikipedia.org/wiki/Paris%E2%80%93Harrington_theorem" rel="nofollow">Paris and Harrington</a> showed is independent of PA. </p> <p>Set theory offers further examples. For our purposes, it's safe to say that ZFC is the system in which contemporary mathematical practice takes place. ZFC has its own Gödel sentences (assuming it's consistent), but it turns out that many natural mathematical questions — sentences $S$ — are simply independent of the ZFC axioms: ZFC proves neither $S$ nor $\neg S$. One famous example is the Continuum Hypothesis, but the list of <a href="https://en.wikipedia.org/wiki/List_of_statements_undecidable_in_ZFC" rel="nofollow">interesting statements independent of ZFC</a> is substantial. </p> <p>The Axiom of Choice, AC, provides the "C" in ZFC. AC says: for every set $X$ of nonempty sets, there is a function $f$ with domain $X$ such that $f(x)\in x$ for all $x\in X$ ($f$ is a <em>choice function</em> for $X$). ZFC without AC is the system known as ZF. It turns out AC is not provable in ZF, and the negation of AC is not provable in ZF. In some models of ZF, every set has a choice function (these models are, of course, models of ZFC); in other models, many infinite sets lack choice functions.</p> <p>Finally, note that, assuming it's consistent, ZFC cannot prove its own consistency. Via Gödel numbering and arithmetization of syntax, a sentence meaning "ZFC is consistent" can be formulated within ZFC. This sentence is just a statement about the integers, which isn't provable even in ZFC. However, if we add a large cardinal axiom, even a "small large cardinal" axiom such as "There exists an inaccessible cardinal", then the resulting stronger theory <em>can</em> prove that ZFC is consistent, and in particular new statements <em>of arithmetic</em> become provable.</p>
<p>Suppose we are talking about the theory of groups. The statement $$ \forall x \forall y \big(xy=yx\big) $$ is not a theorem (it is false for some groups). It negation $$ \exists x \exists y \big(xy \ne yx\big) $$ is also not a theorem (it, too, is false for some groups).</p>
game-theory
<p>I am taking a course in game theory. For proving the Nash equilibrium we require Brouwer's fixed point theorem. But I have not taken a topology course so I am finding the proof difficult to understand. You may explain the same Brouwer's in little easy way.</p>
<p>Of course "easy" has a large degree of subjectivity to it. But there is a famous proof due to Emanuel Sperner that was (and still is) striking for minimizing the amount of topology needed. </p> <p><a href="http://math.mit.edu/~fox/MAT307-lecture03.pdf" rel="noreferrer">These</a> course notes of Jacob Fox give an exposition using Sperner's Lemma. The document starts from scratch and proves Brouwer's Theorem (for all $n$) in just under 2.5 pages. </p>
<p>I think so. Hirsch's proof, which is in Guillemin and Pollack. </p> <p>It goes (something like) this:</p> <p>Suppose $p:D^2\to D^2$ doesn't have a fixed point. Define $r:D^2\to S^1$ by $r(x)$ is the point on the segment from $x$ to $p(x)$ on $S^1$. $r$ would be a retraction of the disk onto the circle. This is impossible.</p>
geometry
<p>I recently learnt a Japanese geometry temple problem. </p> <p>The problem is the following:</p> <p><strong>Five squares are arranged as the image shows. Prove that the area of triangle <em>T</em> and the area of square <em>S</em> are equal.</strong></p> <p><a href="https://i.sstatic.net/FMQoB.png" rel="noreferrer"><img src="https://i.sstatic.net/FMQoB.png" alt=""></a></p> <p>This is problem 6 in this <a href="https://sms.math.nus.edu.sg/smsmedley/Vol-24-2/Traditional%20Japanese%20Geometry%20(John%20F%20Rigby).pdf" rel="noreferrer">article.</a> I am thinking about law of cosines, but I have not been able to prove the theorem. Any hints would be appreciated. </p>
<p>We will, first of all, prove a very interesting property</p> <blockquote> <p><span class="math-container">$\mathbf{Lemma\;1}$</span></p> <p>Given two squares PQRS and PTUV (as shown on the picture), the triangles <span class="math-container">$\Delta STP$</span> and <span class="math-container">$\Delta PVQ$</span> have equal area.</p> </blockquote> <p><span class="math-container">$\mathbf {Proof}$</span></p> <p><a href="https://i.sstatic.net/IkV5Z.png" rel="noreferrer"><img src="https://i.sstatic.net/IkV5Z.png" alt="enter image description here" /></a></p> <p>Denote by <span class="math-container">$\alpha$</span> the angle SPT and by <span class="math-container">$[...]$</span> the area of the polygon &quot;...&quot;. Hence <span class="math-container">$$[\Delta STP]=\frac{\overline {PS}\cdot\overline {PT}\cdot \sin(\alpha)}{2}$$</span> <span class="math-container">$$[\Delta PVQ]=\frac{\overline {QP}*\overline {PV}\cdot\sin\Bigl(360°-(90°+90+\alpha)\Bigr)}{2}=\frac{\overline {QP}\cdot\overline {PV}\cdot\sin\Bigl(180°-\alpha\Bigr)}{2}=\frac{\overline {QP}\cdot\overline {PV}\cdot\sin(\alpha)}{2}$$</span></p> <p>Since <span class="math-container">$\overline {PS}=\overline {PQ}$</span> and <span class="math-container">$\overline {PT}=\overline {PV}$</span> <span class="math-container">$$[\Delta STP]=[\Delta PVQ]$$</span></p> <p>Now, back to the problem</p> <p><a href="https://i.sstatic.net/a48CQ.png" rel="noreferrer"><img src="https://i.sstatic.net/a48CQ.png" alt="enter image description here" /></a> Let <span class="math-container">$\overline {AB}=a$</span> and <span class="math-container">$\overline {IJ}=b$</span>. Note first of all that <span class="math-container">$$\Delta BEC \cong \Delta EIF$$</span> See why? <span class="math-container">$\mathbf {Hint:}$</span></p> <blockquote> <p>It is obvious that <span class="math-container">$\overline {CE}=\overline {EF}$</span>. Use the properties of right triangles in order to show that all angles are equal.</p> </blockquote> <p>Thus <span class="math-container">$${(\overline{CE})^2}={a^2}+{b^2}=S$$</span></p> <p>Note furthermore that <span class="math-container">$$[\Delta BEC]=[\Delta EIF]=\frac{ab}{2}$$</span> By Lemma 1: <span class="math-container">$$[\Delta DCG]=[\Delta BEC]=\frac{ab}{2}=[\Delta EIF]=[\Delta GFK]$$</span> The area of the polygon AJKGD is thus <span class="math-container">$$[AJKGD]=[ABCD]+[CEFG]+[FIJK]+4[\Delta DCG]=2\Bigl({a^2}+{b^2}\Bigr)+2ab$$</span></p> <p>The area of the trapezoid AJKD is moreover <span class="math-container">$$[AJKD]=\frac{(a+b)(2a+2b)}{2}={a^2}+2ab+{b^2}$$</span></p> <p>Finally <span class="math-container">$$T=[\Delta DKG]=[AJKGD]-[AJKD]={a^2}+{b^2}=S \Rightarrow S=T$$</span></p>
<p><a href="https://i.sstatic.net/qFFWD.png" rel="noreferrer"><img src="https://i.sstatic.net/qFFWD.png" alt="enter image description here"></a></p> <p><span class="math-container">$$|\square P_1 P_2 P_3 P_4| = (a+b)^2 = \frac12(a+b)(2a+2b) = |\square Q_1 Q_2 Q_3 Q_4|\quad=:R$$</span></p> <blockquote> <p><span class="math-container">$$S \;=\; R - 4\cdot\frac12ab \;=\; T$$</span></p> </blockquote> <p>(This space intentionally left blank.)</p>
linear-algebra
<blockquote> <p>Let <span class="math-container">$\,A,B,C\in M_{n}(\mathbb C)\,$</span> be Hermitian and positive definite matrices such that <span class="math-container">$A+B+C=I_{n}$</span>, where <span class="math-container">$I_{n}$</span> is the identity matrix. Show that <span class="math-container">$$\det\left(6(A^3+B^3+C^3)+I_{n}\right)\ge 5^n \det \left(A^2+B^2+C^2\right)$$</span></p> </blockquote> <p>This problem is a test question from China (xixi). It is said one can use the equation</p> <p><span class="math-container">$$a^3+b^3+c^3-3abc=(a+b+c)(a^2+b^2+c^2-ab-bc-ac)$$</span></p> <p>but I can't use this to prove it. Can you help me?</p>
<p>Here is a partial and positive result, valid around the &quot;triple point&quot; <span class="math-container">$A=B=C= \frac13\mathbb 1$</span>.</p> <p>Let <span class="math-container">$A,B,C\in M_n(\mathbb C)$</span> be Hermitian satisfying <span class="math-container">$A+B+C=\mathbb 1$</span>, and additionally assume that <span class="math-container">$$\|A-\tfrac13\mathbb 1\|\,,\,\|B-\tfrac13\mathbb 1\|\,,\, \|C-\tfrac13\mathbb 1\|\:\leqslant\:\tfrac16\tag{1}$$</span> in the spectral or operator norm. (In particular, <span class="math-container">$A,B,C$</span> are positive-definite.)<br /> Then we have <span class="math-container">$$6\left(A^3+B^3+C^3\right)+\mathbb 1\:\geqslant\: 5\left(A^2+B^2+C^2\right)\,.\tag{2}$$</span></p> <p><strong>Proof:</strong> Let <span class="math-container">$A_0=A-\frac13\mathbb 1$</span> a.s.o., then <span class="math-container">$A_0+B_0+C_0=0$</span>, or <span class="math-container">$\,\sum_\text{cyc}A_0 =0\,$</span> in notational short form. Consider the</p> <ul> <li>Sum of squares <span class="math-container">$$\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^2 \:=\: \sum_\text{cyc}\big(A_0^2 + \tfrac23 A_0+ \tfrac19\mathbb 1\big) \:=\: \sum_\text{cyc}A_0^2 \:+\: \tfrac13\mathbb 1$$</span></li> <li>Sum of cubes <span class="math-container">$$\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^3 \:=\: \sum_\text{cyc}\big(A_0^3 + 3A_0^2\cdot\tfrac13 + 3A_0\cdot\tfrac1{3^2} + \tfrac1{3^3}\mathbb 1\big) \\ \;=\: \sum_\text{cyc}A_0^3 \:+\: \sum_\text{cyc}A_0^2 \:+\: \tfrac19\mathbb 1$$</span> to obtain <span class="math-container">$$6\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^3+\mathbb 1 \;-\; 5\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^2 \:=\: \sum_\text{cyc}A_0^2\,(\mathbb 1 + 6A_0) \:\geqslant\: 0$$</span> where positivity is due to each summand being a product of commuting positive-semidefinite matrices. <span class="math-container">$\quad\blacktriangle$</span></li> </ul> <p><em><strong>Two years later observation:</strong></em><br /> In order to conclude <span class="math-container">$(2)$</span> the additional assumptions <span class="math-container">$(1)$</span> may be weakened a fair way off to <span class="math-container">$$\tfrac16\mathbb 1\:\leqslant\: A,B,C\tag{3}$$</span> or equivalently, assuming the smallest eigenvalue of each matrix <span class="math-container">$A,B,C\,$</span> to be at least <span class="math-container">$\tfrac16$</span>.</p> <p><strong>Proof:</strong> Consider the very last summand in the preceding proof. Revert notation from <span class="math-container">$A_0$</span> to <span class="math-container">$A$</span> and use the same argument, this time based on <span class="math-container">$(3)$</span>, to obtain <span class="math-container">$$\sum_\text{cyc}\big(A-\tfrac13\mathbb 1\big)^2\,(6A -\mathbb 1)\:\geqslant\: 0\,.\qquad\qquad\blacktriangle$$</span></p>
<p><strong>Not a full proof</strong>, but a number of thoughts too long for a comment. This post aims at finding alternative (yet harder) criteria for proving the conjecture. Please discuss.</p> <p>As in previous comments, let's denote $ X=6(A^3+B^3+C^3)+I $ and $ Y=5(A^2+B^2+C^2) $ and $D = X-Y$.</p> <p>The question is to show $\det(X) \ge \det(Y)$ or $1 \ge \det(X^{-1}Y)$. Write $Q = X^{-1}Y$, then $Q$ is positive definite, since $X$ and $Y$ are positive definite. Now it is known for a positive definite matrix $Q$ (see e.g. <a href="https://math.stackexchange.com/questions/202248/">here</a>) that the <em>trace bound</em> is given by $$ \bigg(\frac{\text{Tr}(Q)}{n}\bigg)^n \geq \det(Q) $$ </p> <p>So a second (harder) criterion for the conjecture is $n \ge \text{Tr}(X^{-1}Y)$ or $ \text{Tr}(X^{-1}D) \geq 0$. I wouldn't see how I can compute this trace or find bounds, can someone?</p> <p>Let's call $d_i$ the eigenvalues of $D$, likewise for $X$ and $Y$. While $x_i &gt; 0$, this doesn't necessarily hold for $d_i$ since we know from comments that $D$ is not necessarily positive definite. So (if $X$ and $D$ could be simultaneously diagonalized) $ \text{Tr}(X^{-1}D) = \sum_i \frac{d_i}{x_i} = r \sum_i {d_i}$ where there exists an $r$ by the mean value theorem. Where $r$ is not guaranteed to be positive, it is likely that $r$ <em>will</em> be positive, since $r$ will only become negative if there are (many, very) negative $d_i$ with small associated $x_i$. Can positivity of $r$ be shown? If we can establish that a positive $r$ can be found, a third criterion is $ \text{Tr}(D) \geq 0$.</p> <p>Now with this third criterion, we can use that the trace is additive and that the trace of commutors vanishes, i.e. $\text{Tr} (AB -BA) = 0$. Using this argument, it becomes unharmful when matrices do not commute, since under the trace their order can be changed. This restores previous solutions where the conjecture was reduced to the valid Schur's inequality (as noted by a previous commenter), which proves the conjecture.</p> <hr> <p>A word on how hard the criteria are, indicatively in terms of eigenvalues:</p> <p>(hardest) positive definiteness: $d_i &gt;0$ $\forall i$ or equivalently, $\frac{y_i}{x_i} &lt;1$ $\forall i$ </p> <p>(second- relies on positive $r$) $ \text{Tr}(D) \geq 0$: $\sum_i d_i \geq 0$</p> <p>(third) $n \ge \text{Tr}(X^{-1}Y)$: $\sum_i \frac{y_i}{x_i} \leq n$</p> <p>(fourth - least hard) $\det(X) \ge \det(Y)$: $\prod_i \frac{y_i}{x_i} \leq 1$</p> <p>Solutions may also be found by using criteria which interlace between those four. </p> <hr> <p>A word on simulations and non-positive-definiteness:</p> <p>I checked the above criteria for the non-positive definite example given by @user1551 in the comments above, and the second, third and fourth criteria hold. </p> <p>Note that equality $\det(X) = \det(Y)$ occurs for (a) symmetry point: $A=B=C=\frac13 I$ and for (b) border point: $A=B=\frac12 I$ and $C=0$ (and permutations). I checked the "vicinity" of these equality points by computer simulations for real matrices with $n=2$ where I extensively added small matrices with any parameter choices to $A$ and $B$ (and let $C = I - A-B$), making sure that $A,B$ and $C$ are positive definite. It shows that for the vicinity of the symmetry point, the second, third and fourth criteria above hold, while there occur frequent non-positive-definite examples. For the vicinity of the border point all four criteria hold.</p>
combinatorics
<p>What is the shortest string <span class="math-container">$S$</span> over an alphabet of size <span class="math-container">$n$</span>, such that every permutation of the alphabet is a substring of <span class="math-container">$S$</span>?</p> <p><strong>Edit 2019-10-17:</strong> This is called a superpermutation, and there is a <a href="https://en.wikipedia.org/wiki/Superpermutation" rel="noreferrer">wikipedia page</a> that keeps track of the best results. Turns out the problem is still open.</p>
<p>Here are some thoughts: given a permutation $abcde$, you can generate all its cyclic rotations with no additional cost: $abcdeabcd$. Then you'd want to capitalize of the largest number symbols, so we repeat the deepest symbol, in this case $a$, complete the permutation with $e$, and generate all cyclic rotations: $abcdeabcdaebcda$. So far we've generated all cyclic rotations of $abcde$ and $bcdae$. Notice that the first $n-1$ characters are rotated. We continue to generate all cyclic rotations of $cdabe,dabce$, and then we have to bring back one symbol shallower: $\ldots dabcedabcadebcad$. So we moved from $dabce$ to $bcade$. This corresponds to rotation of the middle $n-2$ characters, followed by the usual rotation of $n-1$ characters. Now we get back to the earlier operation (rotation of $n-1$), applying occasionally the new rotation, until we get stuck; we would then need to do a rotation of the middle $n-3$ characters, and so on.</p> <p>I would conjecture that the preceding scheme is optimal; the diligent reader can recursively calculate its length.</p>
<p>I researched this question 20 years ago and found that the length of the shortest string containing all the permutations of n objects to be as stated in <a href="http://www.notatt.com/permutations.pdf">http://www.notatt.com/permutations.pdf</a>. We created a computer algorithm to generate all possible strings containing all permutations of n objects and proved this minimal length through brute force for alphabets up to 11 objects. We never could find a proof that our algorithm generated the shortest strings for any n and I would love for someone to pick this subject up. I've found that most mathematicians disregard this topic as already done when in fact, upon close examination, it has not been proven. If anyone knows of such a proof, please pass it along. You can find our paper at Minimal Superpermutations, Ashlock D., and J. Tillotson, Congressus Numerantium 93(1993), 91-98.</p>
linear-algebra
<blockquote> <p>Let <span class="math-container">$ \sigma(A)$</span> be the set of all eigenvalues of <span class="math-container">$A$</span>. Show that <span class="math-container">$ \sigma(A) = \sigma\left(A^T\right)$</span> where <span class="math-container">$A^T$</span> is the transpose matrix of <span class="math-container">$A$</span>.</p> </blockquote>
<p>The matrix <span class="math-container">$(A - \lambda I)^{T}$</span> is the same as the matrix <span class="math-container">$\left(A^{T} - \lambda I\right)$</span>, since the identity matrix is symmetric.</p> <p>Thus:</p> <p><span class="math-container">$$\det\left(A^{T} - \lambda I\right) = \det\left((A - \lambda I)^{T}\right) = \det (A - \lambda I)$$</span></p> <p>From this it is obvious that the eigenvalues are the same for both <span class="math-container">$A$</span> and <span class="math-container">$A^{T}$</span>.</p>
<p>I'm going to work a little bit more generally.</p> <p>Let $V$ be a finite dimensional vector space over some field $K$, and let $\langle\cdot,\cdot\rangle$ be a <em>nondegenerate</em> bilinear form on $V$.</p> <p>We then have for every linear endomorphism $A$ of $V$, that there is a unique endomorphism $A^*$ of $V$ such that $$\langle Ax,y\rangle=\langle x,A^*y\rangle$$ for all $x$ and $y\in V$.</p> <p>The existence and uniqueness of such an $A^*$ requires some explanation, but I will take it for granted.</p> <blockquote> <p><strong>Proposition:</strong> Given an endomorphism $A$ of a finite dimensional vector space $V$ equipped with a nondegenerate bilinear form $\langle\cdot,\cdot\rangle$, the endomorphisms $A$ and $A^*$ have the same set of eigenvalues.</p> </blockquote> <p><em>Proof:</em> Let $\lambda$ be an eigenvalue of $A$. And let $v$ be an eigenvector of $A$ corresponding to $\lambda$ (in particular, $v$ is nonzero). Let $w$ be another arbitrary vector. We then have that: $$\langle v,\lambda w\rangle=\langle\lambda v,w\rangle=\langle Av,w\rangle=\langle v,A^*w\rangle$$ This implies that $\langle v,\lambda w-A^*w\rangle =0$ for all $w\in V$. Now either $\lambda$ is an eigenvalue of $A^*$ or not. If it isn't, the operator $\lambda I -A^*$ is an automorphism of $V$ since $\lambda I-A^*$ being singular is equivalent to $\lambda$ being an eigenvalue of $A^*$. In particular, this means that $\langle v, z\rangle = 0$ for all $z\in V$. But since $\langle\cdot,\cdot\rangle$ is nondegenerate, this implies that $v=0$. A contradiction. $\lambda$ must have been an eigenvalue of $A^*$ to begin with. Thus every eigenvalue of $A$ is an eigenvalue of $A^*$. The other inclusion can be derived similarly.</p> <p>How can we use this in your case? I believe you're working over a real vector space and considering the dot product as your bilinear form. Now consider an endomorphism $T$ of $\Bbb R^n$ which is given by $T(x)=Ax$ for some $n\times n$ matrix $A$. It just so happens that for all $y\in\Bbb R^n$ we have $T^*(y)=A^t y$. Since $T$ and $T^*$ have the same eigenvalues, so do $A$ and $A^t$.</p>
logic
<p>I'm reading Manfredo Do Carmo's differential geometry book. In section 1-7, he discusses the "Isoperimetric Inequality" which is related to the question of what 2-dimensional shape maximizes the enclosed area for a closed curve of constant length. He mentions that </p> <blockquote> <p>A satisfactory proof of the fact that the circle is a solution to the isoperimetric problem took, however, a long time to appear. The main reason seems to be that the earliest proofs assumed that a solution should exist. It was only in 1870 that K. Weierstrass pointed out that many similar questions did not have solutions.</p> </blockquote> <p>This line of reasoning would suggest that assuming the existence of a solution might lead to a contradiction (such as an apparent solution that is not in fact valid). Is this actually a problem?</p> <p><strong>Are there any problems that produce invalid solutions under the (flawed) assumption that a solution exists at all? If so, what is an example and how does it differ from the statement of the isoperimetric problem?</strong></p>
<p>Just the first thing that came to my mind... assume $A=\sum_{n=0}^{\infty}2^n $ exists, it is very easy to <em>find</em> $A $: note $A=1+2\sum_{n=0}^{\infty}2^n =1+2A $, so $A=-1$.</p> <p>Of course, this is all wrong precisely because $A $ does not exist.</p>
<p>Here is a "joke" due to Perron showing that assuming the existence of a solution is not always a very good idea: </p> <p><strong>Theorem.</strong> $1$ is the largest positive integer.</p> <p><em>Proof.</em> For any integer that is not $1$, there is a method to obtain a larger number (namely, taking the square). Therefore $1$ is the largest integer. $\square$</p> <p>A good source is V. Blåsjö, The isoperimetric problem, Amer. Math. Monthly 112 (2005), 526-566.</p>
logic
<p>I am very interested in learning the incompleteness theorem and its proof. But first I must know what things I need to learn first.<br> My current knowledge consists of basic high school education and the foundations of linear algebra and calculus which probably wont help but I figured it's worth mentioning.<br> I prefer that you recommend books as well as abstract subjects that I should learn. Also, a place where I can find the proof would be nice to have.</p> <p>Thanks in advance!</p>
<p>Gödel's first incompleteness theorem tell us about the limitations of effectively axiomatized formal theories strong enough to do a modicum of arithmetic. So you need at least to have a notion of what an effectively axiomatized formal theory is, if you are to grasp what is going on. To understand the "formal theory" bit, it will help to have encountered a bit of formal logic; but a good intro to Gödel should explain the extra "effectively axiomatized" bit. After that, the basic argumentative moves in proving the first incompleteness theorem are surprisingly straightforward (and it was philosophically important to Gödel that this is so) -- though filling in some of the details can get fiddly: so you don't need to bring much background maths to the table in order to get to understand the proof.</p> <p>My own book <em>An Introduction to Gödel's Theorems</em> was written for people who don't have much maths background but have done an intro logic course, and lots of people seem to find it pretty clear (I assume no more than some familiarity with elementary logic). There is also a freely available abbreviated version of some of my book in the form of lecture notes at <a href="http://www.logicmatters.net/resources/pdfs/gwt/GWT.pdf">http://www.logicmatters.net/resources/pdfs/gwt/GWT.pdf</a> There are suggestions for other reading in the relevant sections of the study guide at <a href="http://www.logicmatters.net/tyl">http://www.logicmatters.net/tyl</a></p> <p>You might however find it very helpful to look at Torkel Franzen's admirable little book <em>Gödel's Theorem: An Incomplete Guide to its Use and Abuse</em> which gives an informal presentation and will give you some understanding of what's going on, before deciding whether to tackle a book like mine which goes into the mathematical details. </p>
<p>For the proof you may want to actually take a look at Gödel's 1931 paper <a href="http://www.research.ibm.com/people/h/hirzel/papers/canon00-goedel.pdf">here</a>. As for gentle introduction, along Douglas Hofstadter's <a href="http://rads.stackoverflow.com/amzn/click/0465026567"><em>Gödel,Escher, Bach</em></a> I highly recommend <a href="http://books.google.com/books?id=G29G3W_hNQkC&amp;printsec=frontcover#v=onepage&amp;q&amp;f=false">Gödel's Proof by Ernest Nagel and James Newman</a>. A preview can be found in Google books, but the actual book is really lucid and short and starts off with Problem with Inconsistency. </p>
combinatorics
<p>Given an infinite (in all directions), $n$-dimensional chess board $\mathbb Z^n$, and a black king. What is the minimum number of white rooks necessary that can guarantee a checkmate in a finite number of moves?</p> <p>To avoid trivial exceptions, assume the king starts a very large distance away from the nearest rook.</p> <p>Rooks can change one coordinate to anything. King can change any set of coordinates by one.</p> <p>And same problem with i) Bishops and ii) Queens, in place of rooks.</p>
<p>In 3-dimensional chess, it is possible to force checkmate starting with a finite number of rooks. As this fact still appears to be open, I'll post a method of forcing checkmate with 96 rooks, even though it should be clear that this is not optimal. You can remove some of the rooks from the method I'll give below, but I am aiming for a simple explanation of the method rather than the fewest possible number of rooks.</p> <p>First, we move all of the rooks far away in the <span class="math-container">$z$</span> direction, so that they cannot be threatened by the king. We also move each of the rooks so that they all have distinct <span class="math-container">$z$</span> coordinates. That way, they are free to move any number of steps in the <span class="math-container">$x$</span> and <span class="math-container">$y$</span> directions without blocking each other. The king will be in check whenever it has the same <span class="math-container">$(x,y)$</span>-coordinate as one of the rooks. We can project onto the <span class="math-container">$(x,y)$</span>-plane to reduce it to a 2-dimensional board. Looked at this way, each rook can move any number of places in the <span class="math-container">$x$</span> or <span class="math-container">$y$</span> direction (and can pass through each other, can pass through the king, and you can multiple rooks in the same <span class="math-container">$(x,y)$</span>-square). The king is in check if it is on the same square as a rook.</p> <p>First, I'll describing the following "blocking move" to stop the king passing a given horizontal (or vertical) line.</p> <p><a href="https://i.sstatic.net/ZMZyA.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/ZMZyA.png" alt="blocking move"></a> </p> <p>In the position above, the right-most 3 rooks are stopping the king moving past the red line on the next move. Then, once the king moves, do the following. (i) If the king's <span class="math-container">$x$</span>-coordinate does not change, do nothing. (ii) If the king's <span class="math-container">$x$</span>-coordinate increases by one, move the left-most rook so that it is to the right of the other three. Then you are back in the same position, just moved along by one step. (iii) If the king's <span class="math-container">$x$</span>-coordinate decreases by one step, do nothing. We are back in the same situation, except reflected (so, keep performing the same steps, but reflected in the <span class="math-container">$x$</span>-direction on subsequent moves).</p> <p>This way, we chase the king along the red line, but he can never cross it. Furthermore, if the king changes from going right to going left, we have a free move to do something elsewhere on the board. Actually, for this to work, if the king is in column <span class="math-container">$i$</span>, we just need three rooks at positions <span class="math-container">$i-1,i,i+1$</span> on the row above the red line, and one more at any other position on the row. Next, if we have 4 rooks stationed somewhere on the given horizontal row, how many moves does it take to move them into the blocking position? The answer is 6. You first move one rook to have the same <span class="math-container">$x$</span>-coordinate as the king (say, <span class="math-container">$x=i$</span>). After the king moves, by reflection we can assume he keeps the same <span class="math-container">$x$</span>-coordinate or moves one to the right. Then, move the next rook to position <span class="math-container">$i+2$</span>. Then, after the next move, move a rook to position <span class="math-container">$i-2$</span> or <span class="math-container">$i+4$</span> in such a way that we have three rooks on the row, with one space between each of them, and the kings is in one of the 3 middle columns. Say, the rooks are at positions <span class="math-container">$j-2,j,j+2$</span> and the king is in column <span class="math-container">$j-1,j$</span> or <span class="math-container">$j+1$</span>. If the king moves to column <span class="math-container">$j-1$</span> or <span class="math-container">$j+1$</span> we just move the 4th rook to this position and we have attained the blocking position. If the king moves to column <span class="math-container">$j$</span>, we move the rook in position <span class="math-container">$j-2$</span> to position <span class="math-container">$j-1$</span> and, on the next move, we can move the 4th rook in to attain the blocking position. If the king moves to column <span class="math-container">$j+2$</span>, we move the rook in column <span class="math-container">$j-2$</span> to <span class="math-container">$j+4$</span>, then we are in the position above where there are rooks at positions <span class="math-container">$k-2,k,k+2$</span> and the king in position <span class="math-container">$k$</span>, so it takes 2 more moves to attain the blocking position.</p> <p>So, we just need to keep 4 rooks stationed along the row which we wish to block the king from crossing. Whenever he moves within 6 steps from this row, start moving the rooks into the blocking position, and he can never step into the given row.</p> <p>Now, choose a large rectangle surrounding the king, and position 15 rooks in each corner as below.</p> <p><a href="https://i.sstatic.net/GIe2C.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/GIe2C.png" alt="rectangle"></a> </p> <p>Also, position 4 rooks in arbitrary positions along each edge of the rectangle. So, that's <span class="math-container">$4\times15+4\times4=76$</span> rooks used so far. I puposefully left some of the board blank in the diagram above. The point is to not specify exactly how big the rectangle is. It doesn't matter, just so long as it is large enough to be able to move the 76 rooks into position before the black king can get within 6 steps of any of the edges of the rectangle.</p> <p>Now, once we are in this position, then whenever the black king moves within one of the red rectangles, use the 4 rooks positioned along the adjacent edge to perform the blocking move as described above to stop the king crossing that edge. We can keep doing this, and imprison the black king within the big rectangle. Furthermore, we keep getting free moves to do something else whenever the king moves out of the red rectangles, or whenever he changes direction within a red rectangle. Also, if the king is in one of the inside corners of a red rectangle, there is already a rook in the corresponding position at the adjacent edge of the big rectangle, giving us a free move.</p> <p>Now, suppose that we have an extra 20 rooks. During the free moves we get while chasing the king around the edge of the big square, we can move these to any position we like. With 20 rooks, we can position 16 of to the left of each of the 16 rooks near the right-hand corners of the big rectangle which have an empty square to their left. Also, position 4 rooks along the column one step to the left of the right-hand edge of the big rectangle. This way, we create a new rectangle one square smaller in the <span class="math-container">$x$</span>-direction. If the king ever enters the right-hand red rectangle or one step to the left of this, we use the new 4 blocking rooks to stop him from reaching the right-hand edge of the new big rectangle. If he is already within the red rectangle, and stays there then, when we get a free move, we can move one of the new blocking rooks to the position one above or below the row in which the king is. Then we can bring the other 3 rooks in, blocking him out of this column. In this way, we create a new big rectangle one step smaller in the <span class="math-container">$x$</span>-direction and with the king still trapped inside. Similarly, we can reduce the height of the big rectangle by 1. Repeat this, enclosing the king in ever smaller rectangles until, eventually, he gets trapped in the single square within a 3x3 rectangle surrounded by 8 rooks. Then bring one of the other rooks in to cover this square, which is checkmate.</p>
<p>As the beginnings of an impossibility proof, let's consider the possibility of blocking off one direction of motion to the king in three dimensions. Consider the following game:</p> <pre><code>............. ........... ......... ....... ..... ... K </code></pre> <p>Each turn, you get to place one # on the top row, and then the king gets to move his K one space forward, either straight or diagonally, but cannot pass through a #. If the K reaches the back row, you lose. This game is actually winnable with this size grid or larger, but not with a smaller grid.</p> <p>How does this compare to the chess game? Well, if we just consider one direction of motion, we can project from 3 dimensions down to two. If the king is not in the same plane as any of your rooks, then each of your rooks can block off a single square in the projected game.</p> <p>Unfortunately, you can't really guarantee being able to place one rook per turn in the correct position (and don't forget in the real game, we are trying to block 3 directions of motion at once!) So now consider the same game, but the king gets to make <em>two</em> moves for every move you make.</p> <p>I don't think you can win this version of the game.</p> <p>Now, a better version of the game would be to let you place one # per turn anywhere, and the king gets two moves (or less, if he wants) per turn in any direction. I don't know if this game might be winnable; it's not quite the Conway Angel problem that was mentioned (jumping isn't allowed).</p> <p>But again, you're trying to bound the king in three directions at once. So you're playing three games at once, and on your turn you get to place one piece on any of the three boards, but your opponent gets two moves (or less if he likes) on all boards at once. It seems... unlikely that this game is winnable.</p> <p>So, in order to actually force a checkmate, you're going to have to do one of:</p> <ul> <li>Take some advantage of the initial arrangement of your rooks</li> <li>Find some way to make useful moves on two or three of the projected boards at once</li> <li>Get your rooks in the same plane as the king frequently enough to be meaningful</li> </ul> <p>It's not clear that this can be done.</p> <hr> <p>Update: you don't need to win in 3 directions at once, just two. More precisely, consider a game on an infinite two-dimensional grid where you have pieces # and your opponent has a piece K. You and your opponent alternate turns, and the rules are:</p> <ul> <li>You can move a # horizontally or vertically any distance.</li> <li>You are allowed to move a # onto the K.</li> <li>Your opponent can move one space in any of the 8 directions or remain still.</li> <li>Your opponent is not allowed to end his turn on a #.</li> </ul> <p>You win if your opponent has no legal moves. If you can win this game in N moves with M #'s, then you can force a checkmate as follows:</p> <ul> <li>Imagine the above two-dimensional grid as a projection of the three-dimensional chessboard.</li> <li>Move your rooks vertically 2M + N + lots more spaces away from the king, all with different vertical coordinates.</li> <li>Play the above game, where the #'s are rooks and the K is the king.</li> </ul> <p>If you can build walls quickly enough in just two dimensions, of course, that would give a winning strategy for the above game (given enough #'s): wall in the K, then move #'s to fill all of the interior squares.</p>
geometry
<p>My knowledge of geometry is just a little bit above high school level and I know absolutely nothing about topology. So, what is the point of this meme?</p> <p><a href="https://i.sstatic.net/UmUkL.jpg" rel="noreferrer"><img src="https://i.sstatic.net/UmUkL.jpg" alt="meme about birds &quot;talking&quot;"></a></p> <p>(Original unedited webcomic: <a href="http://falseknees.com/158.html" rel="noreferrer">“Juncrow” by False Knees</a>)</p>
<p>The topologist bird is stating some nice simple topological concepts. The geometer bird comes along and interrupts the topologist bird, squawking loudly over the top with something much longer, more complex-looking and uglier, involving iterated partial derivatives, multiple nested subscripts and superscripts, and so on. The topologist bird looks pissed off.</p> <p>The meme was probably made by a topologist, in a frustrated attempt to convey "why do geometers always overcomplicate things?" or "why is geometry so ugly?" or "why do geometers always talk over topologists?" or something along those lines. (As in most memes, this probably isn't an entirely fair reflection of reality.)</p> <p>I imagine a geometer could make a meme in reverse that implied "why do topologists always take nice things like doughnuts and turn them into coffee cups and start calculating their cohomology?".</p> <p>I don't think there's anything deep going on here. The contents of the speech bubbles don't actually mean much as sentences. They're just some common expressions that you find in topology and geometry respectively, thrown together.</p>
<p>I rebut your meme with a meme of my own</p> <p><a href="https://i.sstatic.net/lSmbF.jpg" rel="noreferrer"><img src="https://i.sstatic.net/lSmbF.jpg" alt="enter image description here"></a></p>
logic
<p>Ever since day one of of my Mathematical Logic course, this fact has really bothered me. I cannot wrap my head around how an empty set is a subset of every possible set. Could someone kindly explain how this is true? Any help is appreciated! </p>
<p>If you're comfortable with proof by contrapositive, then you may prefer to prove that for any set $A,$ if $x\notin A,$ then $x\notin\emptyset$. But of course, $x\notin\emptyset$ is trivial since $\emptyset$ has no elements at all. Hence, $x\notin A\implies x\notin\emptyset,$ so by contrapositive, $x\in\emptyset\implies x\in A,$ meaning $\emptyset\subseteq A$.</p>
<p>By definition, $A$ is a subset of $B$ if every element of $A$ is in $B$.</p> <p>If we set $A=\emptyset$, then the above statement is vacuously true. Every element of $A$ is in fact an element of $B$ since the former has no elements.</p>
matrices
<p>This question aims to create an &quot;<a href="http://meta.math.stackexchange.com/q/1756/18880">abstract duplicate</a>&quot; of numerous questions that ask about determinants of specific matrices (I may have missed a few):</p> <ul> <li><a href="https://math.stackexchange.com/q/153457/18880">Characteristic polynomial of a matrix of $1$&#39;s</a></li> <li><a href="https://math.stackexchange.com/q/55165/18880">Eigenvalues of the rank one matrix $uv^T$</a></li> <li><a href="https://math.stackexchange.com/q/577937/18880">Calculating $\det(A+I)$ for matrix $A$ defined by products</a></li> <li><a href="https://math.stackexchange.com/q/84206/18880">How to calculate the determinant of all-ones matrix minus the identity?</a></li> <li><a href="https://math.stackexchange.com/q/86644/18880">Determinant of a specially structured matrix ($a$&#39;s on the diagonal, all other entries equal to $b$)</a></li> <li><a href="https://math.stackexchange.com/q/629892/18880">Determinant of a special $n\times n$ matrix</a></li> <li><a href="https://math.stackexchange.com/q/689111/18880">Find the eigenvalues of a matrix with ones in the diagonal, and all the other elements equal</a></li> <li><a href="https://math.stackexchange.com/q/897469/18880">Determinant of a matrix with $t$ in all off-diagonal entries.</a></li> <li><a href="https://math.stackexchange.com/q/227096/18880">Characteristic polynomial - using rank?</a></li> <li><a href="https://math.stackexchange.com/q/3955338/18880">Caclulate $X_A(x) $ and $m_A(x) $ of a matrix $A\in \mathbb{C}^{n\times n}:a_{ij}=i\cdot j$</a></li> <li><a href="https://math.stackexchange.com/q/219731/18880">Determinant of rank-one perturbations of (invertible) matrices</a></li> </ul> <p>The general question of this type is</p> <blockquote> <p>Let <span class="math-container">$A$</span> be a square matrix of rank<span class="math-container">$~1$</span>, let <span class="math-container">$I$</span> the identity matrix of the same size, and <span class="math-container">$\lambda$</span> a scalar. What is the determinant of <span class="math-container">$A+\lambda I$</span>?</p> </blockquote> <p>A clearly very closely related question is</p> <blockquote> <p>What is the characteristic polynomial of a matrix <span class="math-container">$A$</span> of rank<span class="math-container">$~1$</span>?</p> </blockquote>
<p>The formulation in terms of the characteristic polynomial leads immediately to an easy answer. For once one uses knowledge about the eigenvalues to find the characteristic polynomial instead of the other way around. Since $A$ has rank$~1$, the kernel of the associated linear operator has dimension $n-1$ (where $n$ is the size of the matrix), so there is (unless $n=1$) an eigenvalue$~0$ with geometric multiplicity$~n-1$. The algebraic multiplicity of $0$ as eigenvalue is then at least $n-1$, so $X^{n-1}$ divides the characteristic polynomial$~\chi_A$, and $\chi_A=X^n-cX^{n-1}$ for some constant$~c$. In fact $c$ is the trace $\def\tr{\operatorname{tr}}\tr(A)$ of$~A$, since this holds for the coefficient of $X^{n-1}$ of <em>any</em> square matrix of size$~n$. So the answer to the second question is</p> <blockquote> <p>The characteristic polynomial of an $n\times n$ matrix $A$ of rank$~1$ is $X^n-cX^{n-1}=X^{n-1}(X-c)$, where $c=\tr(A)$.</p> </blockquote> <p>The nonzero vectors in the $1$-dimensional image of$~A$ are eigenvectors for the eigenvalue$~c$, in other words $A-cI$ is zero on the image of$~A$, which implies that $X(X-c)$ is an annihilating polynomial for$~A$. Therefore</p> <blockquote> <p>The minimal polynomial of an $n\times n$ matrix $A$ of rank$~1$ with $n&gt;1$ is $X(X-c)$, where $c=\tr(A)$. In particular a rank$~1$ square matrix $A$ of size $n&gt;1$ is diagonalisable if and only if $\tr(A)\neq0$.</p> </blockquote> <p>See also <a href="https://math.stackexchange.com/q/52395/18880">this question</a>.</p> <p>For the first question we get from this (replacing $A$ by $-A$, which is also of rank$~1$)</p> <blockquote> <p>For a matrix $A$ of rank$~1$ one has $\det(A+\lambda I)=\lambda^{n-1}(\lambda+c)$, where $c=\tr(A)$.</p> </blockquote> <p>In particular, for an $n\times n$ matrix with diagonal entries all equal to$~a$ and off-diagonal entries all equal to$~b$ (which is the most popular special case of a linear combination of a scalar and a rank-one matrix) one finds (using for $A$ the all-$b$ matrix, and $\lambda=a-b$) as determinant $(a-b)^{n-1}(a+(n-1)b)$.</p>
<p>Here’s an answer without using eigenvalues: the rank of <span class="math-container">$A$</span> is <span class="math-container">$1$</span> so its image is spanned by some nonzero vector <span class="math-container">$v$</span>. Let <span class="math-container">$\mu$</span> be such that <span class="math-container">$$Av=\mu v.$$</span></p> <p>We can extend this vector <span class="math-container">$v$</span> to a basis of <span class="math-container">$\mathbb{C}^n$</span>. With respect to this basis now, we have that the matrix of <span class="math-container">$A$</span> has all rows except the first one equal to <span class="math-container">$0$</span>. Since determinant and trace are basis-independent it follows by expanding the first column of <span class="math-container">$A$</span> wrt to this basis that <span class="math-container">$$\det(A-\lambda I)= (-1)^n(\lambda -\mu)\lambda^{n-1}.$$</span> Using this same basis as above we also see that <span class="math-container">$\text{Tr}(A) =\mu$</span>, so the characteristic polynomial of <span class="math-container">$A$</span> turns out to be</p> <p><span class="math-container">$$(-1)^n(\lambda -\text{Tr}(A))\lambda^{n-1}.$$</span></p>
geometry
<p>Let's say you have two points, $(x_0, y_0)$ and $(x_1, y_1)$.</p> <p>The gradient of the line between them is:</p> <p>$$m = (y_1 - y_0)/(x_1 - x_0)$$</p> <p>And therefore the equation of the line between them is:</p> <p>$$y = m (x - x_0) + y_0$$</p> <p>Now, since I want another point along this line, but a distance $d$ away from $(x_0, y_0)$, I will get an equation of a circle with radius $d$ with a center $(x_0, y_0)$ then find the point of intersection between the circle equation and the line equation.</p> <p>Circle Equation w/ radius $d$:</p> <p>$$(x - x_0)^2 + (y - y_0)^2 = d^2$$</p> <p>Now, if I replace $y$ in the circle equation with $m(x - x_0) + y_0$ I get:</p> <p>$$(x - x_0)^2 + m^2(x - x_0)^2 = d^2$$</p> <p>I factor is out and simplify it and I get:</p> <p>$$x = x_0 \pm d/ \sqrt{1 + m^2}$$</p> <p>However, upon testing this equation out it seems that it does not work! Is there an obvious error that I have made in my theoretical side or have I just been fluffing up my calculations?</p>
<p>Let me explain the answer in a simple way.</p> <p>Start point - $(x_0, y_0)$</p> <p>End point - $(x_1, y_1)$</p> <p>We need to find a point $(x_t, y_t)$ at a distance $d_t$ from start point towards end point.</p> <p><a href="https://i.sstatic.net/3yDtI.png" rel="noreferrer"><img src="https://i.sstatic.net/3yDtI.png" alt="Point on a line at a distance"></a></p> <p>The distance between Start and End point is given by $d = \sqrt{(x_1-x_0)^2+(y_1-y_0)^2}$</p> <p>Let the ratio of distances, $t=d_t/d$</p> <p>Then the point $(x_t, y_t) =(((1-t)x_0+tx_1), ((1-t)y_0+ty_1))$</p> <p>When $0&lt;t&lt;1$, the point is on the line.</p> <p>When $t&lt;0$, the point is outside the line near to $(x_0,y_0)$.</p> <p>When $t&gt;1$, the point is outside the line near to $(x_1,y_1)$.</p>
<p>Another way, using vectors:</p> <p>Let $\mathbf v = (x_1,y_1)-(x_0,y_0)$. Normalize this to $\mathbf u = \frac{\mathbf v}{||\mathbf v||}$.</p> <p>The point along your line at a distance $d$ from $(x_0,y_0)$ is then $(x_0,y_0)+d\mathbf u$, if you want it in the direction of $(x_1,y_1)$, or $(x_0,y_0)-d\mathbf u$, if you want it in the opposite direction. One advantage of doing the calculation this way is that you won't run into a problem with division by zero in the case that $x_0 = x_1$.</p>
geometry
<p>I have a sphere of radius $R_{s}$, and I would like to pick random points in its volume with uniform probability. How can I do so while preventing any sort of clustering around poles or the center of the sphere?</p> <hr> <p>Since I'm unable to answer my own question, here's another solution:</p> <p>Using the strategy suggested by <a href="http://mathworld.wolfram.com/SpherePointPicking.html">Wolfram MathWorld</a> for picking points on the surface of a sphere: Let $\theta$ be randomly distributed real numbers over the interval $[0,2\pi]$, let $\phi=\arccos(2v−1)$ where $v$ is a random real number over the interval $[0,1]$, and let $r=R_s (\mathrm{rand}(0,1))^\frac13$. Converting from spherical coordinates, a random point in $(x,y,z)$ inside the sphere would therefore be: $((r\cos(\theta)\sin(\phi)),(r\sin(\theta)\sin(\phi)),(r\cos(\phi)))$.</p> <p>A quick test with a few thousand points in the unit sphere appears to show no clustering. However, I'd appreciate any feedback if someone sees a problem with this approach.</p>
<p>Let's say your sphere is centered at the origin $(0,0,0)$.</p> <p>For the distance $D$ from the origin of your random pointpoint, note that you want $P(D \le r) = \left(\frac{r}{R_s}\right)^3$. Thus if $U$ is uniformly distributed between 0 and 1, taking $D = R_s U^{1/3}$ will do the trick.</p> <p>For the direction, a useful fact is that if $X_1, X_2, X_3$ are independent normal random variables with mean 0 and variance 1, then $$\frac{1}{\sqrt{X_1^2 + X_2^2 + X_3^2}} (X_1, X_2, X_3)$$ is uniformly distributed on (the surface of) the unit sphere. You can generate normal random variables from uniform ones in various ways; the <a href="http://en.wikipedia.org/wiki/Box%E2%80%93Muller_transform">Box-Muller algorithm</a> is a nice simple approach.</p> <p>So if you choose $U$ uniformly distributed between 0 and 1, and $X_1, X_2, X_3$ iid standard normal and independent of $U$, then $$\frac{R_s U^{1/3}}{\sqrt{X_1^2 + X_2^2 + X_3^2}} (X_1, X_2, X_3)$$ would produce a uniformly distributed point inside the ball of radius $R_s$.</p>
<p>An alternative method in $3$ dimensions: </p> <p>Step 1: Take $x, y, $ and $z$ each uniform on $[-r_s, r_s]$. </p> <p>Step 2: If $x^2+y^2+z^2\leq r_s^2$, stop. If not, throw them away and return to step $1$. </p> <p>Your success probability each time is given by the volume of the sphere over the volume of the cube, which is about $0.52$. So you'll require slightly more than $2$ samples on average. </p> <p>If you're in higher dimensions, this is not a very efficient process at all, because in a large number of dimensions a random point from the cube is probably not in the sphere (so you'll have to take many points before you get a success). In that case a modified version of Nate's algorithm would be the way to go. </p>
logic
<p>If <span class="math-container">$P$</span> and <span class="math-container">$Q$</span> are statements,</p> <blockquote> <p><span class="math-container">$P \iff Q$</span></p> </blockquote> <p>and</p> <blockquote> <p>The following are equivalent:</p> <p><span class="math-container">$(\text{i}) \ P$</span></p> <p><span class="math-container">$(\text{ii}) \ Q$</span></p> </blockquote> <p>Is there a difference between the two? I ask because formulations of certain theorems (such as Heine-Borel) use the latter, while others use the former. Is it simply out of convention or &quot;etiquette&quot; that one formulation is preferred? Or is there something deeper? Thanks!</p>
<p>As Brian M. Scott explains, they are logically equivalent.</p> <p>However, <em>in principle</em>, the expression $$(*) \qquad A \Leftrightarrow B \Leftrightarrow C$$ is ambiguous. It could mean either of the following.</p> <ol> <li><p>$(A \Leftrightarrow B) \wedge (B \Leftrightarrow C)$</p></li> <li><p>$(A \Leftrightarrow B) \Leftrightarrow C$</p></li> </ol> <p>These are not equivalent; in particular, (1) means that each of $A,B$ and $C$ have the same truthvalue, whereas (2) means that either precisely $1$ of them is true, or else all $3$ of them are true. Also, you can check for yourself that, perhaps surprisingly, the $\Leftrightarrow$ operation actually <em>associative</em>! That is, the following are equivalent:</p> <ul> <li>$(A \Leftrightarrow B) \Leftrightarrow C$</li> <li>$A \Leftrightarrow (B \Leftrightarrow C)$.</li> </ul> <p>In <em>practice</em>, however, (1) is almost always the intended meaning.</p>
<p>They are exactly equivalent. There may be a pragmatic difference in their use: when $P$ and $Q$ are relatively long or complex statements, the second formulation is probably easier to read.</p>
matrices
<p>How do we prove that</p> <p><span class="math-container">$\operatorname{rank}(A) = \operatorname{rank}(AA^T) = \operatorname{rank}(A^TA)$</span> ?</p> <p>Is it always true?</p>
<p>This is only true for real matrices. For instance $\begin{bmatrix} 1 &amp; i \\ 0 &amp;0 \end{bmatrix}\begin{bmatrix} 1 &amp; 0 \\ i &amp;0 \end{bmatrix}$ has rank zero. For complex matrices, you'll need to take the conjugate transpose.</p>
<p>Here is a common proof.</p> <p>All matrices in this note are real. Think of a vector <span class="math-container">$X$</span> as an <span class="math-container">$m\!\times\!1$</span> matrix. Let <span class="math-container">$A$</span> be an <span class="math-container">$m\!\times\!n$</span> matrix.</p> <p>We will prove that <span class="math-container">$A A^T X = 0$</span> if and only if <span class="math-container">$A^T X = 0$</span>.</p> <p>It is clear that <span class="math-container">$A^T X = 0$</span> implies <span class="math-container">$AA^T X = 0$</span>.</p> <p>Assume that <span class="math-container">$AA^T X = 0$</span> and set <span class="math-container">$Y = A^T\!X$</span>. Then <span class="math-container">$X^T\!A\, Y = 0$</span>, and thus <span class="math-container">$(A^T\!X)^T Y = 0$</span>. That is <span class="math-container">$Y^T Y = 0$</span>. Setting <span class="math-container">$Y = [y_1 \cdots y_n]^\top$</span> we obtain <span class="math-container">$0 = Y^T Y = y_1^2 + \cdots + y_n^2$</span>. Since the entries of <span class="math-container">$Y$</span> are real, for all <span class="math-container">$k \in \{1,\ldots,n\}$</span> we have <span class="math-container">$y_k^2 \geq 0$</span>. Therefore, <span class="math-container">$Y^T Y = 0$</span> yields <span class="math-container">$y_k = 0$</span> for all <span class="math-container">$k \in \{1,\ldots,n\}$</span>. Thus <span class="math-container">$Y = A^T X = 0$</span>.</p> <p>We just proved that the <span class="math-container">$m\!\times\!m$</span> matrix <span class="math-container">$AA^T$</span> and the <span class="math-container">$n\!\times\!m$</span> matrix <span class="math-container">$A^T$</span> have the same null space. Consequently, they have the same nullity. The nullity-rank theorem states that <span class="math-container">$$ \operatorname{Nul} AA^T + \operatorname{Rank} AA^T = m = \operatorname{Nul} A^T + \operatorname{Rank} A^T. $$</span></p> <p>Hence <span class="math-container">$\operatorname{Rank} AA^T = \operatorname{Rank} A^T$</span>.</p>
probability
<p>Suppose you flip a fair coin repeatedly until you see a Heads followed by a Tails. What is the expected number of coin flips you have to flip?</p> <p>By manipulating an equation based on the result of the first flip, shown at this link:</p> <p><a href="http://www.codechef.com/wiki/tutorial-expectation">http://www.codechef.com/wiki/tutorial-expectation</a></p> <p>the answer is 6. This also makes sense intuitively since the expected value of the number flips until HH or TT is 3. But is there a way to tackle this problem by summing a series of probabilities multiplied by the values?</p> <p>Thank you!</p>
<p>Let <code>X</code> be the random variable which counts the number of flips till we get a <code>T</code> (tails). Then: $$E[X] = \frac{1}{2}\cdot1 + \frac{1}{2}(1+E[X])$$ $$\implies E[X] = 2$$ The first term on LHS is if we get a <code>T</code> on a our first flip (with probability $\frac{1}{2}$). The second term is if we get a <code>H</code> (heads) on our first flip (with probability $\frac{1}{2}$), which means that we are effectively starting over with <code>1</code> extra flip. </p> <p>Now let <code>Y</code> be the random variable which counts the number of flips till we get a <code>HT</code> sequence. Then: $$E[Y] = \frac{1}{2}(1+E[Y])+\frac{1}{2}(1+E[X])$$ $$\implies E[Y] = 4$$ The first term on LHS is if we get a <code>T</code> on our first flip (with probability $\frac{1}{2}$), which means we are effectively starting over with <code>1</code> extra flip. The second term if we get a <code>H</code> on our first flip (with probability $\frac{1}{2}$), then all we want is a <code>T</code>, which means we want to count 1 + expected number of flips to get a <code>T</code>.</p>
<p>Another way to solve this is to use Markov chains. Let state <code>0</code> be the start state. Then with probability 0.5 you will get heads and move to state <code>1</code>; with probability 0.5 you will get tails and stay in state <code>0</code>. Once in state <code>1</code>, you will either get heads (probability 0.5) and remain in state <code>1</code> or you will get tails (probability 0.5) and move to state <code>2</code> which is the accepting state.</p> <p>As a transition matrix then, we have:</p> <p>$$ \begin{array}{c|ccc} &amp; 0 &amp; 1 &amp; 2 \\ \hline 0 &amp; 0.5 &amp; 0.5 &amp; 0 \\ 1 &amp; 0 &amp; 0.5 &amp; 0.5 \\ 2 &amp; 0 &amp; 0 &amp; 1 \\ \end{array} $$</p> <p>If we let $\phi(i)$ be the expected number of flips to go from state $i$ to state <code>2</code>, then from this transition matrix we must have:</p> <p>$\phi(0) = 0.5*(1 + \phi(0)) + 0.5*(1+\phi(1)) + 0*(1+\phi(2))$ $\phi(1) = 0*(1 + \phi(0)) + 0.5*(1+\phi(1)) + 0.5*(1+\phi(2))$ $\phi(2) = 0*(1 + \phi(0)) + 0*(1+\phi(1)) + 1*\phi(2)$</p> <p>So, obviously, $\phi(2)=0$ and plugging this into the first two equations gives the same system to solve as in the other answers. </p> <p>Solving for $\phi(0)$ gives $\phi(0) = 4$.</p> <p>"Why" does this only require 4 flips in expectation making it different than the 6 flips needed in expectation to see HH or TT? If the coin is fair, then out of a two flip sequence, HH, HT, TH, and TT are all equally likely, so shouldn't it take the same amount of "time" before you expect to see any given one of those two-flip patterns?</p> <p>No. Firstly because we just calculated it and the expectations are different. Unless our model of the situation is wrong, then 4 is simply the answer, even if it doesn't "feel" right. Secondly, though, there is an important asymmetry in the two problems.</p> <p>When looking for HH, we would have a transition matrix like this:</p> <p>$$ \begin{array}{c|ccc} &amp; 0 &amp; 1 &amp; 2 \\ \hline 0 &amp; 0.5 &amp; 0.5 &amp; 0 \\ 1 &amp; 0.5 &amp; 0 &amp; 0.5 \\ 2 &amp; 0 &amp; 0 &amp; 1 \\ \end{array} $$</p> <p>The difference is the second row. Instead of being able to stick around indefinitely in state <code>1</code>, we are immediately faced with either succeeding (getting that second H) or failing and being forced to start over. </p> <p>This means, on average, it should take longer in the HH case to reach the success state <code>2</code> from the middle state <code>1</code> than in our original problem. But the probability of going from the start state <code>0</code> to the middle state <code>1</code> remains identical between the two problems. </p> <p>So we should expect that it takes longer on average to see the first HH than to see the first HT.</p> <p>An interesting exercise would be to ask: is there a biased coin of some kind for which the expected number of flips to see HH is the same as the expected number of flips to see HT?</p> <p>I decided to go ahead and work this one out assuming that $p$ represents the probability of the coin landing on Heads on a certain flip. You can modify the above two transition matrices to use $p$ and $1-p$ in the appropriate places, get the system of equations in each case (the HH case or the HT case) and then solve.</p> <p>When I solve this, I get that in general, for a coin with bias $p$ for Heads, it will take on average $1/p + 1/(1-p)$ flips to see HT (this agrees with the answer in the 0.5 case) and it will take $(1+p)/p^2$ flips in the HH case, again agreeing with previous calculations for the 0.5 case.</p> <p>This leads to an equation for $p$:</p> <p>$\frac{1}{p} + \frac{1}{1-p} = \frac{1+p}{p^2}$</p> <p>and after rearranging and simplifying, it is a polynomial equation:</p> <p>$0 = 1 - p - p^2$</p> <p>which has roots: 0.61803399, -1.618003399, the first of which can serve as a valid bias parameter for a coin.</p> <p>Thus, if you ever encounter a coin with a probability of Heads of 0.61803399, then in that case it will be true that, on average, it takes as many flips to see the first occurrence of HH as it does to the first occurrence of HT. </p>
logic
<p><a href="http://mathworld.wolfram.com/Axiom.html">One usually describes an axiom to be a proposition regarded as self-evidently true without proof.</a></p> <p>Thus, axioms are propositions we assume to be true and we use them in an axiomatic theory as premises to infer conclusions, which are called "theorems" of this theory.</p> <p>For example, we can use the <a href="http://mathworld.wolfram.com/PeanosAxioms.html">Peano axioms</a> to prove theorems of arithmetic.</p> <p>This is one meaning of the word "axiom". But I recognized that the word "axiom" is also used in quite different contexts.</p> <p>For example, a group is defined to be an algebraic structure consisting of a set $G$, an operation $G\times G\to G: (a, b)\mapsto ab$, an element $1\in G$ and a mapping $G\to G: a\mapsto a^{-1}$ such that the following conditions, the so-called group <i>axioms</i>, are satisfied:</p> <ol> <li><p>$\forall a, b, c\in G.\ (ab)c=a(bc)$,</p></li> <li><p>$\forall a\in G.\ 1a=a=a1$ and</p></li> <li>$\forall a\in G.\ aa^{-1}=1=a^{-1}a$.</li> </ol> <blockquote> <p>Why are these conditions (that an algebraic structure has to satisfy to be called a group) called <i>axioms</i>? What have these conditions to do with the word "axiom" in the sense specified above? I am really asking about this modern use of the word "axiom" in mathematical jargon. It would be very interesting to see how the modern use of the word "axiom" historically developed from the original meaning.</p> </blockquote> <p>Now, let me give more details why it appears to me that the word is being used in two different meanings:</p> <p>As peter.petrov did, one can argue that group theory is about the conclusions one can draw from the group axioms just as arithmetic is about the conclusions one can draw from the Peano axioms. But in my opinion there is a big difference: while arithmetic is really about natural numbers, the successor operation, addition, multiplication and the "less than" relation, group theory is not just about group elements, the group operation, the identity element and the inverse function. Group theory is rather about <i>models</i> of the group axioms. Thus: <i>The axioms of group theory are not the group axioms, the axioms of group theory are the axioms of set theory.</i></p> <p>Theorems of arithmetic can be formalized as sentences over the signature (a. k. a. language) $\{0, s, +, \cdot\}$, while theorems of group theory cannot always be formalized as sentences over the signature $\{\cdot, 1, ^{-1}\}$. Let me give an example: A typical theorem of arithmetic is the case $n=4$ of Fermat's last theorem. It can be formalized as follows over the signature $\{0, s, +, \cdot\}$: $$\neg\exists x\exists y\exists z(x\not = 0\land y\not = 0\land z\not = 0\quad\land\quad x\cdot x\cdot x\cdot x + y\cdot y\cdot y\cdot y = z\cdot z\cdot z\cdot z).$$ A typical theorem of group theory is <a href="https://en.wikipedia.org/wiki/Lagrange%27s_theorem_(group_theory)">Lagrange's theorem</a> which states that for any finite group G, the order of every subgroup H of G divides the order of G. I think that one cannot formalize this theorem as a sentence over the "group theoretic" signature $\{\cdot, 1, ^{-1}\}$; or can one?</p>
<h2>Axioms</h2> <p>Originally, &quot;axioms&quot; meant &quot;self-evident truths&quot;, or at least what seemed self-evident. But the more important question is what axioms are <strong>used</strong> for. From the beginning, <strong>logic</strong> in some form has been an essential part of <strong>reasoning</strong>, and we reason about things all the time. Then whenever we want to <strong>convey</strong> our reasoning to other people, and want them to <strong>accept</strong> our viewpoint, we need to present a valid <strong>argument</strong>. What is a valid argument? It is a series of inferences or <strong>deductions</strong>, each one following from the previous ones logically. But no argument can get started without first making at least one <strong>assumption</strong>. If the other person accepts all our assumptions as well as all the deductive steps we take, they would also have to accept the conclusion of our argument.</p> <p>The goal in convincing another person, therefore, is to make as few and as weak assumptions as we can in our argument. Sometimes, there are assumptions that the vast majority of people accept, in which case we could call them <strong>self-evident truths</strong>. This is a common source of the assumptions that we freely use in everyday argumentation.</p> <p>But sometimes we do not want to bother ourselves with small details of the real world that might have to be catered to in self-evident truths. In this case, we often come up with <strong>idealized</strong> forms, that we still call <strong>axioms</strong>. The axioms that Euclid came up with to describe geometrical objects are of this kind. Although there are no physical manifestations of ideal lines (with zero thickness) and ideal points (with zero diameter) and ideal circles, what we can derive about ideal lines and points and circles is so general that the slight deviation of physical entities from these ideal objects does not affect the vast <strong>utility</strong> of the mathematical theorems about the ideal geometrical world. All we need to remember is that the ideal world is merely an approximation of the real world, and we can effectively apply the theorems (such as Pythagoras' theorem) to reality by taking those deviations into account.</p> <p>Approximation is but the first step in from the real to the abstract. The objective of <strong>abstraction</strong> is to attempt to isolate the crucial <strong>structures</strong> from the not so important details or specific <strong>data</strong>. The next step is to consider worlds governed by different axioms (assumptions). A well-known historical example was the exploration of geometrical worlds that satisfy Euclid's axioms minus the parallel postulate. In that case, there are ways to interpret some of these worlds in a Euclidean world. But the point of laying down a collection of axioms describing a world is so that we can thereafter argue completely based on deductive reasoning without any appeal whatsoever to the intuitive nature of the axioms (whether or not they are)! This is the <strong>modern</strong> meaning of &quot;axiom&quot; in mathematics, more or less.</p> <h2>Algebraic structures</h2> <p>Now about your questions regarding the axiomatization of groups, first let us see what it really is about. The axioms for a group govern a <strong>single</strong> group, a world in which there is only one binary operation and it satisfies those properties as specified by the axioms. <strong>Inside</strong> any such world, you cannot tell whether it is finite or not, for example, not to say know the size of the world. <strong>Outside</strong> the world, however, you can, as long as your outside world is strong enough to talk about <strong>worlds</strong> that satisfy the group axioms!</p> <p>In logic, a world satisfying a collection of axioms is called a <strong>model</strong>. Commonly, we work in a higher world that satisfies the axioms of ZFC, in which we can talk about sets of axioms and sets that are models for some set of axioms. That is precisely why we are able to prove Lagrange's theorem; we <strong>cannot</strong> express it as a statement over the language of group theory, as you noted, which intuitively you can understand to mean that if you are 'inside' any group you do not even have the ability to express the theorem, not to say prove it.</p> <p>There are indeed many more theorems you can prove in ZFC about groups than you can simply by deduction using only the group axioms. This is a very common phenomenon in mathematics, where you need to work from 'outside' all algebraic structures of a certain family (such as fields) to do anything much. The reason is that the axioms governing the algebraic structure hold for <strong>every</strong> member of the family that satisfy those axioms, so naturally you are very limited in what you can prove using them.</p>
<p>As you remark, doing formal proofs from the group axioms is not very interesting -- that won't let us prove (or even formulate) most of the theorems of what we know as group theory.</p> <p>So what does the group axioms have to do with axioms for general mathematical reasoning, such as the axioms of Peano Arithmetic or set theory? I would like to propose that the missing link is that <strong>model theory</strong> has interesting things to say about both kinds of axioms.</p> <p>Model theory is mostly about relation between <em>different models</em> for the same set of axioms. In that it looks more like abstract algebra than <em>proof theory</em> does; doing model theory with the group axioms actually connects to what we view as group theory.</p> <p>At the same time, useful results can come from applying model theory to the axioms of a proposed foundation for mathematics, such as ZFC. Model-theoretic results such as the Löwenheim-Skolem theorems are relevant all the time when we investigate the limits of what one can prove from those axioms.</p> <p>In order to formulate model theory such that it applies to both of these situations, we need a word for "the conditions that define what is or isn't a model". The word "axiom" has been picked for that because in the case of a foundational theory those conditions are indeed supposed to be (at least somewhat close to) axioms in the traditional sense.</p> <p>We then choose to use the <em>same word</em> for the conditions-for-being-a-model when we're talking about something less foundational such as groups. That's the beauty and curse of abstraction: It's often most powerful if we accept calling some thing by a name that originally only belonged to another thing else that it is merely formally analogous to.</p> <p>In this way, what should perhaps by itself have been called the "group conditions" naturally become "group <em>axioms</em>" when we're using model-theoretic methods to study groups. And once that happens, it makes sense to reduce confusion by <em>still</em> calling them "axioms" when we're doing group theory with methods that are specific to groups.</p> <p>(Repeat the above for all other kinds of algebraic structure, of course).</p>
differentiation
<p>The symmetric derivative is always equal to the regular derivative when it exists, and still isn't defined for jump discontinuities. From what I can tell the only differences are that a symmetric derivative will give the 'expected slope' for removable discontinuities, and the average slope at cusps. These seem like extremely reasonable quantities to work with (especially the former), so I'm wondering why the 'typical' derivative isn't taken to be this one. What advantage is there to taking $\lim\limits_{h\to0}\frac{f(x+h)-f(x)} h$ as the main quantity of interest instead? Why would we want to use the one that's defined less often?</p>
<p>The symmetric derivative being defined at more places isn't a good thing. </p> <p>In my mind, the main point of differentiation is to locally approximate a function by a linear function. That is, the heart of saying that the derivative $f'(a)$ exists at a point $a$ is the statement that</p> <p>$$f(x) = f(a) + f'(a) (x - a) + o(|x - a|)$$</p> <p>as $x \to a$, and if I were the King of Calculus this is how the derivative would actually be defined. (Among other things, this definition generalizes smoothly to higher dimensions.) Removable discontinuities are a non-issue as they should just be removed, but at a cusp we <em>do not have this property for any possible value of $f'(a)$</em>, so we shouldn't be talking about derivatives at such points at all. (We can talk about left or right derivatives, but this is something different.) </p> <p>The symmetric derivative at $a$ is not a natural definition. It has the utterly strange property that any weirdness in a neighborhood of $a$ is ignored if it happens to be canceled by equivalent weirdness after reflecting around $a$. Let me give an example. Consider the function $f(x) = 1_{\mathbb{Q}}(x)$ which is equal to $1$ if $x$ is rational and $0$ otherwise. The symmetric derivative of $f$ at any rational point exists and is equal to $0$! Is there any reasonable sense in which $f$ is differentiable at a rational point? </p> <p>The ordinary derivative, on the other hand, is sensitive to weirdness around $a$ because it compares all of that weirdness to $f(a)$. </p>
<p>Following my comment on the Mean Value Theorem. Since MVT fails, anything we prove from MVT is likely to fail as well. For example:</p> <p><strong>Find the minimum of the (symetrically) differentiable function $f(x) = x+2|x|$ on the interval $[-1,1]$</strong>.<br> Usual solution: find where the derivative is zero. Answer: nowhere! Since $f'(x) = -1$ on $[-1,0)$, $f'(0)=1$, and $f'(x)=3$ on $(0,1]$.</p>
linear-algebra
<p>I have an n-dimensional hyperplane: $w'x + b = 0$ and a point $x_0$. The shortest distance from this point to a hyperplane is $d = \frac{|w \cdot x_0+ b|}{||w||}$. I have no problem to prove this for 2 and 3 dimension space using algebraic manipulations, but fail to do this for an n-dimensional space. Can someone show a nice explanation for it?</p>
<p>There are many ways to solve this problem. In principal one can use Lagrange multipliers and solve a large system of equations, but my attempt to do so met with a road block. However, since you are working in $\mathbb{R}^n$ we have the privilege of orthogonal projection via the dot product. To this end we need to construct a vector from the plane to $x_0$ to project onto a vector perpendicular to the plane. Then we compute the <em>length of the projection</em> to determine the distance from the plane to the point.</p> <p>First, you have an affine hyperplane defined by $w \cdot x + b=0$ and a point $x_0$. Suppose that $X \in \mathbb{R}^n$ is a point satisfying $w \cdot X+b=0$, i.e. it is a point on the plane. You should construct the vector $x_0 - X$ which points from $X$ to $x_0$ so that you can project it onto the unique vector <em>perpendicular</em> to the plane. Some quick reasoning should tell you that this vector is, in fact, $w$. So we want to compute $\| \text{proj}_{w} (x_0-X)\|$. Some handy formulas give us $$ d=\| \text{proj}_{w} (x_0-X)\| = \left\| \frac{(x_0-X)\cdot w}{w \cdot w} w \right\| = |x_0 \cdot w - X \cdot w|\frac{\|w\|}{\|w\|^2} = \frac{|x_0 \cdot w - X \cdot w|}{\|w\|}$$ We chose $X$ such that $w\cdot X=-b$ so we get $$ d=\| \text{proj}_{w} (x_0-X)\| = \frac{|x_0 \cdot w +b|}{\|w\|} $$ as desired.</p> <p>This almost seems like cheating and purely heuristic based on Euclidean geometry. Indeed, I would be more satisfied with a solution via Lagrange multipliers since it would not have required the fact that $\mathbb{R}^n$ has an inner product and just needed the topology of $\mathbb{R}^n$ instead. But we have the inner product, so maybe geometry will suffice for us this time.</p> <p>To make this argument more concrete you should do each step in $\mathbb{R}^2$ for a line $y=mx+b$ and a point $(x_0,y_0)$.</p>
<p>Here is a Lagrange multiplier based solution.</p> <p>The goal is to minimize <span class="math-container">$ (x_0 - x)'(x_0 - x) $</span> subject to <span class="math-container">$ w'x + b = 0 $</span></p> <p>The Lagrangian is <span class="math-container">$ (x_0 - x)'(x_0 - x) - L(w'x + b) $</span></p> <p>The derivative of the Lagrangian is <span class="math-container">$ -2(x_0 - x) - Lw = 0 $</span></p> <p>Dot with <span class="math-container">$ w $</span>, we get <span class="math-container">$ -2w'(x_0 - x) - Lw'w = 0 \implies L = -\frac{2w'(x_0 - x)}{w'w} $</span></p> <p>Dot with <span class="math-container">$ (x_0 - x) $</span>, we get <span class="math-container">\begin{alignat*}{1} &amp; -2(x_0 - x)'(x_0 - x) - L(x_0 - x)'w = 0 \\ &amp; \implies -2(x_0 - x)'(x_0 - x) = -\frac{2w'(x_0 - x)}{w'w} (x_0 - x)'w \\ &amp; \implies (x_0 - x)'(x_0 - x) = \frac{\left(w'(x_0 - x)\right)^2}{w'w} \\&amp; \implies (x_0 - x)'(x_0 - x) = \frac{\left(w'x_0 + b\right)^2}{w'w} \end{alignat*}</span></p> <p>Taking square root gives the answer we wanted.</p>
combinatorics
<p>Let <span class="math-container">$\mathbb{N}=\{0,1,2,\ldots\}$</span>. Does there exist a bijection <span class="math-container">$f\colon\mathbb{N}\to\mathbb{N}$</span> such that <span class="math-container">$f(0)=0$</span> and <span class="math-container">$|f(n)-f(n-1)|=n$</span> for all <span class="math-container">$n\geq1$</span>?</p> <p>The values <span class="math-container">$f(1)=1$</span>, <span class="math-container">$f(2)=3$</span>, and <span class="math-container">$f(3)=6$</span> are forced. After that, you might choose to continue with</p> <p><span class="math-container">$$\begin{array}{c|c}n&amp;f(n)\\\hline0&amp;0\\1&amp;1\\2&amp;3\\3&amp;6\\4&amp;2\end{array}\qquad\begin{array}{c|c}n&amp;f(n)\\\hline5&amp;7\\6&amp;13\\7&amp;20\\8&amp;28\\9&amp;37\end{array}\qquad\begin{array}{c|c}n&amp;f(n)\\\hline10&amp;27\\11&amp;16\\12&amp;4\\13&amp;17\\14&amp;31\end{array}$$</span></p> <p>Here, after deceasing to <span class="math-container">$f(4)=2$</span>, the next smallest remaining value was 4. I chose to continue to increase until there was a clear way down to 4 and back up. </p> <p>As mentioned in the comments, the greedy algorithm where you decrease whenever you can is given by sequence <a href="https://oeis.org/A005132" rel="noreferrer">A005132</a> in the OEIS. However, this sequence gets stuck at <span class="math-container">$f(20)=42$</span>, <span class="math-container">$f(21)=63$</span>, <span class="math-container">$f(22)=41$</span>, <span class="math-container">$f(23)=18$</span> as there is no possible value for <span class="math-container">$f(24)$</span>. Also, this greedy approach would take longer to get to the value <span class="math-container">$4$</span>.</p> <p>In general, if <span class="math-container">$k$</span> is the smallest number that you haven't hit yet then the strategy of increasing until there is a clear way down to <span class="math-container">$k$</span> and a clear way back up seems to be a reasonable strategy. This is the strategy employed by the table above. Unfortunately, Symlic's answer shows that this strategy doesn't work (in fact, it will never hit the value 5). Therefore, a more sophisticated strategy is required.</p> <p>If you instead consider <span class="math-container">$f\colon\mathbb{N}\to\mathbb{Z}$</span> then alternating between increasing and decreasing is a valid bijection. However, employing this technique in original situation will often lead to you getting stuck in coming back up.</p>
<p>The good news is that your function will never get stuck. The bad news is that the reason quite easy: your function will never have value 5. Let see how to get it.</p> <p>Suppose there are $k$ and $\ell$ such that $f(\ell) = 5$, and $f(n) = f(n - 1) + n$ for all $13 \le n \le k$, and $f(n) = f(n - 1) - n$ for all $k &lt; n \le l$. Then $$f(k) = 4 + \sum_{n = 13}^k n = 4 + \frac{k(k + 1)}2 - 78 = \frac{k(k + 1)}2 - 74$$ and $$5 = f(\ell) = f(k) - \sum_{n = k + 1}^{\ell} n = \frac{k(k + 1)}2 - 74 - \frac{\ell(\ell + 1)}2 + \frac{k(k + 1)}2,$$ i. e., $$k(k + 1) = 79 + \frac{\ell(\ell + 1)}2.$$ It is easy to see that $\frac{\ell(\ell + 1)}2 \bmod 9 \in \{\,0, 1, 3, 6\,\}$ and $k(k + 1) \bmod 9 \in \{\,0, 2, 3, 6\,\}$. Since $79 \bmod 9 = 7$ we get a contradiction, which means that there are no such $k$ and $\ell$.</p>
<p><strong>Such a bijection exists</strong>.</p> <p>It is convenient to assume that we are looking for an infinite jump sequence on $\mathbb N$ starting from $0$, never returning to a previous position and ultimately filling all $\mathbb N$. The distance of the $n$th jump is restricted to be $n$, we can choose only its direction. So our task is to find the appropriate sequence $\mathcal D$ of jump directions like $\mathcal D=(+\!+\!+\!-\!+\dots)$, where $+$ means jumping $n$ positions forward and $-$ means jumping $n$ positions backward, $n$ is the number of the sign in the sequence. The term <em>state</em> below stands for a pair $(n, m)$, where $n \in \mathbb N$ is <em>time</em> and $m \in \mathbb N$ is <em>position</em> (it results from adding $\pm n$ to a previous position when $n&gt;0$ and corresponds to $f(n)$ in the original statement). A state $(n, m)$ is called <em>safe</em> if $m$ is the largest position up to the time $n$ (i.e. $f(t)&lt;f(n)$ for all $t&lt;n$).</p> <p>The solution relies on two jump patterns. Lower index $k \in \mathbb N$ after some subpattern $\mathcal P$ (which may be a single sign or a bracketed group) below means that $\mathcal P$ must be repeated $k$ times.</p> <h2>Saturator</h2> <p>Pattern: $\mathcal S_k = +_2(-+)_k$</p> <p>Prerequisite: safe state $(n, m)$.</p> <p>Parameter: $k, \; 0 \le k \le n$.</p> <p>Result: safe state $(n+2k+2, m+2n+k+3)$.</p> <p>Comment: the table below summarizes state change during the pattern realization. Position never goes into the "unsafe" area below $m$.</p> <p>$$\begin{array}{|c|ccc|} \hline \text{Time (from ... to)} &amp;&amp; \;\text{Position}\\ n+\bullet &amp; m+\bullet &amp; m+n+\bullet &amp; m+2n+\bullet\\ \hline 0 \,\dots\, 2 &amp; \color{lime}{0} &amp; 1 &amp; 3\\ 2i+3 \,\dots\, 2i+4 &amp;&amp; -i &amp; i+4\\ \hline \text{min pos} &amp; 0 &amp; -k+1 &amp;3\\ \text{max pos} &amp; 0 &amp; 1 &amp; \color{lime}{k+3}\\ \hline \end{array}$$</p> <p>Positions are grouped in columns according to $n$-driven <em>bands</em>. For brevity, common summands like $n + \bullet$ are put into header, they must be added to what's written beneath. The line containing $i$, where $0 \le i &lt; k$, describes a cycle repeated $k$ times. As $k \le n$, the bands never intersect. This is also reflected in the last two rows. For example, the minimal position in the second band is $m+n-k+1$, which is greater than the sole position $m$ in the first band.</p> <p>Particular case: $k=n$. This Saturator, called <em>the complete Saturator</em> and denoted simply by $\mathcal S$, will be used most often. It transforms the safe state $(n, m)$ to the safe state $(3n+2, m+3n+3)$. Looking at the ratio $t = \frac m {n+1}$ for each state, it transforms $t$ to $\frac {m+3n+3} {3n+3}=1 + \frac t 3$. The map $t \to 1 + \frac t 3$ has one fixed point: $t_0 = \frac 3 2$, so starting from any safe state and using $\mathcal S$ an appropriate number of times it is possible to get $t$ as close as needed to $\frac 3 2$.</p> <h2>Fencer</h2> <p>Pattern: $\mathcal F_k = +(+_3\!-_3)_k\!+_5\!-\!+\!-_6+_6$</p> <p>Prerequisites: safe state $(n, m)$ and previously unattended position $a = m - (15k+47)$.</p> <p>Parameter: $k$ (fixed, determined by $a$), $0 \le k &lt; \frac {n-33} 9$.</p> <p>Result: new safe state, $a$ is attended.</p> <p>Comment: the table below summarizes state change during the pattern realization. The only position inside "unsafe" area is $a$, which is indicated by the red color.</p> <p>$$\begin{array}{|c|ccccccc|} \hline \text{Time (from ... to)} &amp;&amp;&amp;&amp; \;\text{Position}\\ n+\bullet &amp; m\!+\!\bullet &amp; m\!+\!n\!+\!\bullet &amp; m\!+\!2n\!+\!\bullet &amp; m\!+\!3n\!+\!\bullet &amp; m\!+\!4n\!+\!\bullet &amp; m\!+\!5n\!+\!\bullet &amp; m\!+\!6n\!+\!\bullet\\ \hline 0 \,\dots\, 1 &amp; \color{lime}{0} &amp; 1\\ 6i+2 \,\dots\, 6i+4 &amp;&amp;&amp; -3i+3 &amp; 3i+6 &amp; 9i+10\\ 6i+5 \,\dots\, 6i+7 &amp;&amp; -9i-8 &amp; -3i-1 &amp; 3i+5\\ 6k+2 \,\dots\, 6k+6 &amp;&amp;&amp; -3k+3 &amp; 3k+6 &amp; 9k+10 &amp; 15k+15 &amp; 21k+21\\ 6k+7 \,\dots\, 6k+8 &amp;&amp;&amp;&amp;&amp;&amp; 15k+14 &amp;21k+22\\ 6k+9 \,\dots\, 6k+14 &amp; \color{red}{-15k-47} &amp; -9k-33 &amp; -3k-20 &amp; 3k-8 &amp; 9k+3 &amp; 15k+13\\ 6k+15 \,\dots\, 6k+20 &amp;&amp; -9k-32 &amp; -3k-16 &amp; 3k+1 &amp; 9k+19 &amp; 15k+38 &amp; \color{lime}{21k+58}\\ \hline \text{min pos} &amp; -15k-47 &amp; -9k-33 &amp; -3k-20 &amp; \min(5, 3k\!-\!8) &amp; \min (10, 9k\!+\!3) &amp; 15k+13 &amp; 21k+21\\ \text{max pos} &amp; 0 &amp; 1 &amp; 3 &amp; 3k+6 &amp; 9k+19 &amp; 15k+38 &amp; 21k+58\\ \hline \end{array}$$</p> <p>Two lines containing $i$, where $0 \le i &lt; k$, describe a cycle repeated $k$ times. As $9k+33 &lt; n$, two first bands don't intersect. The same is true for other band pairs. For example, $3k+21&lt;9k+33&lt;n$, thus the second and the third bands don't intersect.</p> <h2>Sequence construction</h2> <p>We are starting from the safe state $(0, 0)$ and empty $\mathcal D$. The latter will be composed of $\mathcal S_k$ and $\mathcal F_k$ only. The strategy is to use the Fencer pattern repeatedly making "lunges" at the lowest unattended positions. The main purpose of the Saturator pattern is to provide prerequisites for the Fencer. If there is no unattended position below the current one (as it is at the beginning), $\mathcal S$ simply executes until it arrives. Then, after fixing minimal unattended position $a$, the Saturator must increase $m$ such that $m \equiv a+2 \pmod {15}$ and $0 \le \frac {m-a-47} {15} &lt; \frac {n-33} 9 \iff a+47 \le m &lt; \frac 5 3 n + a - 8$. The inequality $a+47 \le m$ can be easily achieved since the Saturator always increases $m$. After that apply the complete Saturator one or more times until the ratio $t=\frac {m'}{n'+1}$ for the next expected pair $(n',m')=(3n_{i-1}\!+\!2, m\!+\!3n_{i-1}\!+\!3)$ becomes lower than $\frac {5 / 3 \, (n'-28) + a - 8} {n'+1}$. This will happen some time because, as noted above, $t_i \to \frac 3 2$, $n_i \to +\infty$ and $\frac 3 2 &lt; \frac 5 3$. To make the Fencer available, apply "almost complete" Saturator $\mathcal S_k$ with $k=n_{i-1}-d$ instead of $k=n_{i-1}$, where $d$ is chosen between $0$ and $14$ such that $m'-d \equiv a+2 \pmod {15}$. Then $n_i=n'-2d \ge n'-28$, $m_i=m'-d$, thus $m_i \le m'&lt;\frac {5 / 3 \, (n'-28) + a - 8} {n'+1} (n'+1) \le \frac 5 3 n_i + a - 8$ and all prerequisites for the Fencer are fulfilled. As the lowest unattended position is greater than $n$ after the $n$th application of the Fencer, any position ultimately will be attended.</p>
differentiation
<blockquote> <p>If $f(x)=\frac{1}{x^2+x+1}$, find $f^{(36)} (0)$. </p> </blockquote> <p>So far I have tried letting $a=x^2+x+1$ and then finding the first several derivatives to see if some terms would disappear because the third derivative of $a$ is $0$, but the derivatives keep getting longer and longer. Am I on the right track? Thanks!</p>
<p>We can write:</p> <p>$$1+ x + x^2 = \frac{1-x^3}{1-x}$$</p> <p>Therefore:</p> <p>$$f(x) = \frac{1-x}{1-x^3} $$</p> <p>We can then expand this in powers of $x$:</p> <p>$$f(x) = (1-x)\sum_{k=0}^{\infty}x^{3 k}$$</p> <p>which is valid for $\left|x\right|&lt;1$. The coefficient of $x^{36}$ is thus equal to $1$, so the 36th derivative at $x = 0$ is $36!$ .</p>
<p>Let $\omega$ be a complex cube root of $1$. Then Partial Fraction representation of $f(x)$ is given by</p> <p>$f(x) = \dfrac{1}{x^2+x+1} = \dfrac{1}{(x-\omega)(x-\omega^2)} = \dfrac{1}{\omega - \omega^2}\Big(\dfrac{1}{x-\omega} - \dfrac{1}{x - \omega^2}\Big)$.</p> <p>Find successive derivatives to show that</p> <p>$f^{(36)}(x) = \dfrac{1}{\omega - \omega^2}(36! (x-\omega)^{-37} - 36! (x - \omega^2)^{-37})$.</p> <p>Let $x = 0$ and use $\omega^3 = 1$.</p>
matrices
<p>I have two square matrices: <span class="math-container">$A$</span> and <span class="math-container">$B$</span>. <span class="math-container">$A^{-1}$</span> is known and I want to calculate <span class="math-container">$(A+B)^{-1}$</span>. Are there theorems that help with calculating the inverse of the sum of matrices? In general case <span class="math-container">$B^{-1}$</span> is not known, but if it is necessary then it can be assumed that <span class="math-container">$B^{-1}$</span> is also known.</p>
<p>In general, <span class="math-container">$A+B$</span> need not be invertible, even when <span class="math-container">$A$</span> and <span class="math-container">$B$</span> are. But one might ask whether you can have a formula under the additional assumption that <span class="math-container">$A+B$</span> <em>is</em> invertible.</p> <p>As noted by Adrián Barquero, there is <a href="http://www.jstor.org/stable/2690437" rel="noreferrer">a paper by Ken Miller</a> published in the <em>Mathematics Magazine</em> in 1981 that addresses this.</p> <p>He proves the following:</p> <p><strong>Lemma.</strong> If <span class="math-container">$A$</span> and <span class="math-container">$A+B$</span> are invertible, and <span class="math-container">$B$</span> has rank <span class="math-container">$1$</span>, then let <span class="math-container">$g=\operatorname{trace}(BA^{-1})$</span>. Then <span class="math-container">$g\neq -1$</span> and <span class="math-container">$$(A+B)^{-1} = A^{-1} - \frac{1}{1+g}A^{-1}BA^{-1}.$$</span></p> <p>From this lemma, we can take a general <span class="math-container">$A+B$</span> that is invertible and write it as <span class="math-container">$A+B = A + B_1+B_2+\cdots+B_r$</span>, where <span class="math-container">$B_i$</span> each have rank <span class="math-container">$1$</span> and such that each <span class="math-container">$A+B_1+\cdots+B_k$</span> is invertible (such a decomposition always exists if <span class="math-container">$A+B$</span> is invertible and <span class="math-container">$\mathrm{rank}(B)=r$</span>). Then you get:</p> <p><strong>Theorem.</strong> Let <span class="math-container">$A$</span> and <span class="math-container">$A+B$</span> be nonsingular matrices, and let <span class="math-container">$B$</span> have rank <span class="math-container">$r\gt 0$</span>. Let <span class="math-container">$B=B_1+\cdots+B_r$</span>, where each <span class="math-container">$B_i$</span> has rank <span class="math-container">$1$</span>, and each <span class="math-container">$C_{k+1} = A+B_1+\cdots+B_k$</span> is nonsingular. Setting <span class="math-container">$C_1 = A$</span>, then <span class="math-container">$$C_{k+1}^{-1} = C_{k}^{-1} - g_kC_k^{-1}B_kC_k^{-1}$$</span> where <span class="math-container">$g_k = \frac{1}{1 + \operatorname{trace}(C_k^{-1}B_k)}$</span>. In particular, <span class="math-container">$$(A+B)^{-1} = C_r^{-1} - g_rC_r^{-1}B_rC_r^{-1}.$$</span></p> <p>(If the rank of <span class="math-container">$B$</span> is <span class="math-container">$0$</span>, then <span class="math-container">$B=0$</span>, so <span class="math-container">$(A+B)^{-1}=A^{-1}$</span>).</p>
<p>It is shown in <a href="http://dspace.library.cornell.edu/bitstream/1813/32750/1/BU-647-M.version2.pdf" rel="noreferrer">On Deriving the Inverse of a Sum of Matrices</a> that </p> <p><span class="math-container">$(A+B)^{-1}=A^{-1}-A^{-1}B(A+B)^{-1}$</span>.</p> <p>This equation cannot be used to calculate <span class="math-container">$(A+B)^{-1}$</span>, but it is useful for perturbation analysis where <span class="math-container">$B$</span> is a perturbation of <span class="math-container">$A$</span>. There are several other variations of the above form (see equations (22)-(26) in this paper). </p> <p>This result is good because it only requires <span class="math-container">$A$</span> and <span class="math-container">$A+B$</span> to be nonsingular. As a comparison, the SMW identity or Ken Miller's paper (as mentioned in the other answers) requires some nonsingualrity or rank conditions of <span class="math-container">$B$</span>.</p>
game-theory
<p>Is there any computer software available for solving for mixed strategy Nash equilibria for two players given each player's payoff matrix?</p>
<p>Yes. Here are two that I have co-authored:</p> <p><a href="http://banach.lse.ac.uk/">http://banach.lse.ac.uk/</a></p> <p><a href="http://gametheoryexplorer.org/">http://gametheoryexplorer.org/</a></p> <p>The first one is succeeded by the second, which also solves two-player extensive-form games and offers more algorithms.</p> <p>Both allow enumeration of all equilibria (including all equilibrium components for degenerate games) of bimatrix games, and only require one matrix to be input for zero-sum and symmetric games.</p> <p>We welcome feedback on these, as they, in particular the second one, are in ongoing development.</p> <p>For offline use, you should also check out the nash binary from the lrs program (which the web software above use as one of their algorithms):</p> <p><a href="http://cgm.cs.mcgill.ca/~avis/C/lrslib/USERGUIDE.html#nash">http://cgm.cs.mcgill.ca/~avis/C/lrslib/USERGUIDE.html#nash</a></p> <p>For the underlying theory see e.g.:</p> <p>D. Avis, G. Rosenberg, R. Savani , and B. von Stengel (2010). Enumeration of Nash Equilibria for Two-Player Games. <em>Economic Theory</em> 42, 9-37.</p> <p>You should also be aware of the Gambit software package:</p> <p><a href="http://gambit.sourceforge.net/">http://gambit.sourceforge.net/</a></p> <p>The web solvers above are distinct from but affiliated with the main Gambit software.</p>
<p>If you have <em>Mathematica</em>, there is a <a href="http://www.mathematica-journal.com/2014/03/using-reduce-to-compute-nash-equilibria/" rel="nofollow">brute-force algorithm I authored</a>. It is not efficient as the ones listed by Rahul Savani and it works well only for small games (say 4x4 or smaller). The only advantage is that if you are familiar with Mathematica you do not have to incur the cost of learning something new or install a system like Gambit.</p>
geometry
<p>How did mathematicians prior to the coming of calculus derive the area of the circle from scratch, without the use of calculus?</p> <p>The area, $A$, of a circle is $\pi r^2$. Given radius $r$, diameter $d$ and circumference $c$, by definition, $\pi := \frac cd$.</p>
<p>There's an interesting method using which you can approximately find the area. Split up the circle into many small sectors, and arrange them as a parallelogram as shown in the image (from wikipedia)</p> <p><a href="https://i.sstatic.net/ZhIBJ.png" rel="noreferrer"><img src="https://i.sstatic.net/ZhIBJ.png" alt="enter image description here" /></a></p> <p>The higher the number of sectors you take, the more it tends to a parallelogram, with one of it’s height the radius <span class="math-container">$r$</span>, and the other side half the circumference <span class="math-container">$\pi r$</span>. Thus, its area tends to <span class="math-container">$\pi r \cdot r = \pi r^2$</span></p>
<p>Calculus depends on the concept of a limit, and does apply that to the problem of determining the area of a curved object. But the concept of a limit and the ability to reason about the area of a curved object using that concept existed before Calculus. </p> <p>As far as recorded history is concerned, Archimedes was the first to derive $A = \pi r^2$. Though he didn't call it $\pi$, I think we can still say this is the answer to your question. His proof depends on the concept of a limit. He showed that, given a circle, with radius $r$ and circumference $c$, the area of that circle can't be more than that of a triangle with height $r$ and base $c$, and that it can't be less than the area of that triangle either. He did this by examining the area of polygons with an increasing number of sides, both inside the circle and outside the circle. This involved the concept of a limit and calculating area, which FEELS like calculus, but isn't.</p> <p>Polygons with increasing number of sides inside: <a href="https://i.sstatic.net/6bAUA.png" rel="noreferrer"><img src="https://i.sstatic.net/6bAUA.png" alt="enter image description here"></a> Polygons with increasing number of sides outside: <a href="https://i.sstatic.net/FdBzT.png" rel="noreferrer"><img src="https://i.sstatic.net/FdBzT.png" alt="enter image description here"></a></p>
game-theory
<p>What are some examples of mathematical games that can take an unbounded amount of time (a.k.a. there are starting positions such that for any number $n$, there is a line of play taking $&gt;n$ times) but is finite (every line of play eventually ends.) Also, it would be nice if it were recreational in nature (by this I mean I basically mean its nontrivial, I could conceivably be enjoyed by humans theortically.) One answer per game please, but edit variants into the same answer.</p> <p>This is a big-list question, so many answers would be appreciated.</p>
<p>One example is <a href="http://en.wikipedia.org/wiki/Sylver_coinage">Sylver's Coinage</a> played like so:</p> <p>Player's alternate selecting positive integers ($1, 2, 3, 4\dots$). The rule is that no number is allowed to be expressed as sum (with possible duplicates) of the previous. For example, say $\{4, 8, 5, 7\}$ ($8$ would have had to been said before $4$) was previously said. Then $6$ could be said, but $14$ could not, for it is equal to $5+5+4$ (or $7+7$.) The player who says $1$ loses! (If you prefer normal play convention, outlaw the number $1$ and then the last player who can move wins!)</p> <p>This game is unbounded ($\{n, n-1, n-2, \dots n/2\}$), but, according to a theorem of arithmetic, finite (if you have trouble even seeing how this game could end, note that when $2$ and $3$ are said, all even numbers, and all odd number more that $3$ are illegal.</p> <p>Does anyone know any variants (say based on different mathematical structures than positive integers? Ordinals maybe?)</p>
<p>One example is the ring game, which is defined <a href="https://mathoverflow.net/questions/93276/a-game-on-noetherian-rings">here</a> - in essence, the game (or a slight variant thereon) can be described as:</p> <blockquote> <p>Start with a Noetherian ring $R$. At each turn, replace $R$ with a quotient thereof. If a player can make no legal moves (i.e. $R$ is a field, thus has no proper quotients).</p> </blockquote> <p>One can notice that if we play this on $\mathbb Z$, then this is equivalent to the game $*\omega$, since the first move takes it to $\mathbb Z/n\mathbb Z$ which is clearly equivalent to $*k$ where $k$ is the number of (not necessarily distinct) prime factors of $n$. However, as evidenced by <a href="https://math.stackexchange.com/questions/158924/the-ring-game-on-kx-y-z">certain unanswered questions</a>, the structure of the game can get fairly complicated when we consider more complicated rings. One could generalize to replace "ring" with any algebraic structure they desire - like one could play on groups with no infinite ascending chains of normal subgroups.</p>
geometry
<p>For example, the square can be described with the equation $|x| + |y| = 1$. So is there a general equation that can describe a regular polygon (in the 2D Cartesian plane?), given the number of sides required?</p> <p>Using the Wolfram Alpha site, this input gave an almost-square: <code>PolarPlot(0.75 + ArcSin(Sin(2x+Pi/2))/(Sin(2x+Pi/2)*(Pi/4))) (x from 0 to 2Pi)</code></p> <p>This input gave an almost-octagon: <code>PolarPlot(0.75 + ArcSin(Sin(4x+Pi/2))/(Sin(4x+Pi/2)*Pi^2)) (x from 0 to 2Pi)</code></p> <p>The idea is that as the number of sides in a regular polygon goes to infinity, the regular polygon approaches a circle. Since a circle can be described by an equation, can a regular polygon be described by one too? For our purposes, this is a regular convex polygon (triangle, square, pentagon, hexagon and so on).</p> <p>It can be assumed that the centre of the regular polygon is at the origin $(0,0)$, and the radius is $1$ unit.</p> <p>If there's no such equation, can the non-existence be proven? If there <em>are</em> equations, but only for certain polygons (for example, only for $n &lt; 7$ or something), can those equations be provided?</p>
<p>Any polygon (regular or not) can be described by an equation involving only absolute values and polynomials. Here is a small explanation of how to do that.</p> <p>Let's say that a curve $C$ is given by the equation $f$ if we have $C = \{(x,y) \in \mathbb{R}^2, \, f(x,y) = 0\}$.</p> <ul> <li><p>If $C_1$ and $C_2$ are given by $f_1$ and $f_2$ respectively, then $C_1 \cup C_2$ is given by $f_1 . f_2$ and $C_1 \cap C_2$ is given by $f_1^2 + f_2^2$ (or $|f_1| + |f_2|$). So if $C_1$ and $C_2$ can be described by an equation involving absolute values and polynomials, then so do $C_1 \cup C_2$ and $C_1 \cap C_2$.</p></li> <li><p>If $C = \{(x,y) \in \mathbb{R}^2, \, f(x,y) \ge 0\}$, then $C$ is given by the equation $|f|-f$.</p></li> </ul> <p>Now, any segment $S$ can be described as $S = \{(x,y) \in \mathbb{R}^2, \, a x + b y = c, \, x_0 \le x \le x_1, \, y_0 \le y \le y_1\}$, which is given by a single equation by the above principles. And since union of segments also are given by an equation, you get the result.</p> <p>EDIT : For the specific case of the octagon of radius $r$, if you denote $s = \sin(\pi/8)$, $c = \cos(\pi/8)$, then one segment is given by $|y| \le rs$ and $x = rc$, for which an equation is</p> <p>$$f(x, y) = \left||rs - |y|| - (rs - |y|)\right| + |x-rc| = 0$$</p> <p>So I think the octagon is given by</p> <p>$$f(|x|,|y|) \ f(|y|,|x|) \ f\left(\frac{|x|+|y|}{\sqrt{2}}, \frac{|x|-|y|}{\sqrt{2}}\right) = 0$$ </p> <p>To get a general formula for a regular polygon of radius $r$ with $n$ sides, denote $c_n = \cos(\pi/n)$, $s_n = \sin(\pi/n)$ and</p> <p>$$f_n(x+iy) = \left||rs_n - |y|| - (rs_n - |y|)\right| + |x-rc_n|$$</p> <p>then your polygon is given by</p> <p>$$\prod_{k = 0}^{n-1} f_n\left(e^{-\frac{2 i k \pi}{n}} (x+iy)\right) = 0$$</p> <p>Depending on $n$, you can use symmetries to lower the degree a bit (as was done with $n = 8$).</p>
<p>Here's a parametric equation I have made for a regular <span class="math-container">$n$</span>-gon, coded in R:</p> <pre><code>n=5; theta=(0:999)/1000; r=cos(pi/n)/cos(2*pi*(n*theta)%%1/n-pi/n); plot(r*cos(2*pi*theta),r*sin(2*pi*theta),asp=1,xlab=&quot;X&quot;,ylab=&quot;Y&quot;, main=paste(&quot;Regular &quot;,n,&quot;-gon&quot;,sep=&quot;&quot;)); </code></pre> <p>And picture:</p> <p><img src="https://i.sstatic.net/bUhKk.png" alt="5-gon" /></p> <p>The formula I used is</p> <p><span class="math-container">$$\displaystyle r=\frac{\cos\left(\frac{\pi}{n}\right)}{\cos\left(\left(\theta \mod \frac{2\pi}{n}\right) -\frac{\pi}{n}\right)} \; .$$</span></p> <p>This equation is actually just the polar equation for the line through the point <span class="math-container">$(1,0)$</span> and <span class="math-container">$(\cos(2\pi/n),\sin(2\pi/n))$</span> which contains one of the edges. By restricting the range of the variable <span class="math-container">$\theta$</span> to the interval <span class="math-container">$[0,2\pi/n[$</span>, you will in fact just get that edge. Now, we want to replicate that edge by rotating it repeatedly through an angle <span class="math-container">$2\pi/n$</span> to get the full polygon. But this can also be achieved by using the modulus function and reducing all angles to the interval <span class="math-container">$[0,2\pi/n[$</span>. This way, you get the polar equation I propose.</p> <p>So, using polar plots and the modulo function, it's pretty easy to make regular <span class="math-container">$n$</span>-gons.</p>
logic
<p>I am having trouble seeing the difference between weak and strong induction.</p> <hr /> <p>There are a few examples in which we can see the difference, such as reaching the <span class="math-container">$k^{th}$</span> rung of a ladder and proving every integer <span class="math-container">$&gt;1$</span> can be written as a product of primes:</p> <blockquote> <p>To show every <span class="math-container">$n\ge2$</span> can be written as a product of primes, first we note that <span class="math-container">$2$</span> is prime. Now we assume true for all integers <span class="math-container">$2 \le m&lt;n$</span>. If <span class="math-container">$n$</span> is prime, we're done. If <span class="math-container">$n$</span> is not prime, then it is composite and so <span class="math-container">$n=ab$</span>, where <span class="math-container">$a$</span> and <span class="math-container">$b$</span> are less than <span class="math-container">$n$</span>. Since <span class="math-container">$a$</span> and <span class="math-container">$b$</span> are less than <span class="math-container">$n$</span>, <span class="math-container">$ab$</span> can be written as a product of primes and hence <span class="math-container">$n$</span> can be written as a product of primes. QED</p> </blockquote> <hr /> <p>However, it seems sort of like weak induction, only a bit dubious. In weak induction, we show a base case is true, then we assume true for all integers <span class="math-container">$k-1$</span>, (or <span class="math-container">$k$</span>), then we attempt to show it is true for <span class="math-container">$k$</span>, (or <span class="math-container">$k+1$</span>), which implies true <span class="math-container">$\forall n \in \mathbb N$</span>.</p> <p><strong>When we assume true for all integers <span class="math-container">$k$</span>, isn't that the same as a strong induction hypothesis? That is, we're assuming true for all integers up to some specific one.</strong></p> <hr /> <p>As a simple demonstrative example, how would we show <span class="math-container">$1+2+\cdots+n= {n(n+1) \over 2}$</span> using strong induction?</p> <p>(Learned from Discrete Mathematics by Kenneth Rosen)</p>
<p><strong>Initial remarks:</strong> Good question. I think it deserves a full response (warning: this is going to be a long, but hopefully very clear, answer). First, most students do not really understand <a href="https://math.stackexchange.com/questions/1139579/why-is-mathematical-induction-a-valid-proof-technique/1139606#1139606">why mathematical induction is a valid proof technique</a>. That's part of the problem. Second, weak induction and strong induction are actually logically equivalent; thus, differentiating between these forms of induction may seem a little bit difficult at first. The important thing to do is to understand how weak and strong induction are stated and to clearly understand the differences therein (I disagree with the previous answer that it is "just a matter of semantics"; it's not, and I will explain why). Much of what I will have to say is adapted from David Gunderson's wonderful book <em>Handbook of Mathematical Induction</em>, but I have expanded and tweaked a few things where I saw fit. That being said, hopefully you will find the rest of this answer to be informative.</p> <hr> <p><strong>Gunderson remark about strong induction:</strong> While attempting an inductive proof, in the inductive step one often needs only the truth of $S(n)$ to prove $S(n+1)$; sometimes a little more "power" is needed (such as in the proof that any positive integer $n\geq 2$ is a product of primes--we'll explore why more power is needed in a moment), and often this is made possible by strengthening the inductive hypothesis. </p> <hr> <p><strong>Kenneth Rosen remark in <em>Discrete Mathematics and Its Applications Study Guide</em>:</strong> Understanding and constructing proofs by mathematical induction are extremely difficult tasks for most students. Do not be discouraged, and do not give up, because, without doubt, this proof technique is the most important one there is in mathematics and computer science. Pay careful attention to the conventions to be observed in writing down a proof by induction. As with all proofs, remember that a proof by mathematical induction is like an essay--it must have a beginning, a middle, and an end; it must consist of complete sentences, logically and aesthetically arranged; and it must convince the reader. Be sure that your basis step (also called the "base case") is correct (that you have verified the proposition in question for the smallest value or values of $n$), and be sure that your inductive step is correct and complete (that you have derived the proposition for $k+1$, assuming the inductive hypothesis that proposition is true for $k$--or the slightly strong hypothesis that it is true for all values less than or equal to $k$, when using strong induction. </p> <hr> <p><strong>Statement of weak induction:</strong> Let $S(n)$ denote a statement regarding an integer $n$, and let $k\in\mathbb{Z}$ be fixed. If</p> <ul> <li>(i) $S(k)$ holds, and</li> <li>(ii) for every $m\geq k, S(m)\to S(m+1)$,</li> </ul> <p>then for every $n\geq k$, the statement $S(n)$ holds.</p> <hr> <p><strong>Statement of strong induction:</strong> Let $S(n)$ denote a statement regarding an integer $n$. If </p> <ul> <li>(i) $S(k)$ is true and</li> <li>(ii) for every $m\geq k, [S(k)\land S(k+1)\land\cdots\land S(m)]\to S(m+1)$,</li> </ul> <p>then for every $n\geq k$, the statement $S(n)$ is true. </p> <hr> <p><strong>Proof of strong induction from weak:</strong> Assume that for some $k$, the statement $S(k)$ is true and for every $m\geq k, [S(k)\land S(k+1)\land\cdot\land S(m)]\to S(m+1)$. Let $B$ be the set of all $n&gt;m$ for which $S(n)$ is false. If $B\neq\varnothing, B\subset\mathbb{N}$ and so by well-ordering, $B$ has a least element, say $\ell$. By the definition of $B$, for every $k\leq t&lt;\ell, S(t)$ is true. The premise of the inductive hypothesis is true, and so $S(\ell)$ is true, contradicting that $\ell\in B$. Hence $B=\varnothing$. $\blacksquare$</p> <hr> <p><strong>Proof of weak induction from strong:</strong> Assume that strong induction holds (in particular, for $k=1$). That is, assume that if $S(1)$ is true and for every $m\geq 1, [S(1)\land S(2)\land\cdots\land S(m)]\to S(m+1)$, then for every $n\geq 1, S(n)$ is true. </p> <p>Observe (by truth tables, if desired), that for $m+1$ statements $p_i$, $$ [p_1\to p_2]\land[p_2\to p_3]\land\cdots\land[p_m\to p_{m+1}]\Rightarrow[(p_1\land p_2\land\cdots\land p_m)\to p_{m+1}],\tag{$\dagger$} $$ itself a result provable by induction (see end of answer for such a proof). </p> <p>Assume that the hypotheses of weak induction are true, that is, that $S(1)$ is true, and that for arbitrary $t, S(t)\to S(t+1)$. By repeated application of these recent assumptions, $S(1)\to S(2), S(2)\to S(3),\ldots, S(m)\to S(m+1)$ each hold. By the above observation, then $$ [S(1)\land S(2)\land\cdots\land S(m)]\to S(m+1). $$ Thus the hypotheses of strong induction are complete, and so one concludes that for every $n\geq 1$, the statement $S(n)$ is true, the consequence desired to complete the proof of weak induction. $\blacksquare$</p> <hr> <p><strong>Proving any positive integer $n\geq 2$ is a product of primes using strong induction:</strong> Let $S(n)$ be the statement "$n$ is a product of primes."</p> <p><strong>Base step ($n=2$):</strong> Since $n=2$ is trivially a product of primes (actually one prime, really), $S(2)$ is true. </p> <p><strong>Inductive step:</strong> Fix some $m\geq 2$, and assume that for every $t$ satisfying $2\leq t\leq m$, the statement $S(t)$ is true. To be shown is that $$ S(m+1) : m+1 \text{ is a product of primes}, $$ is true. If $m+1$ is a prime, then $S(m+1)$ is true. If $m+1$ is not prime, then there exist $r$ and $s$ with $2\leq r\leq m$ and $2\leq s\leq m$ so that $m+1=rs$. Since $S(r)$ is assumed to be true, $r$ is a product of primes [<strong>note:</strong> <em>This</em> is where it is imperative that we use strong induction; using weak induction, we cannot assume $S(r)$ is true]; similarly, by $S(s), s$ is a product of primes. Hence $m+1=rs$ is a product of primes, and so $S(m+1)$ holds. Thus, in either case, $S(m+1)$ holds, completing the inductive step.</p> <p>By mathematical induction, for all $n\geq 2$, the statement $S(n)$ is true. $\blacksquare$</p> <hr> <p><strong>Proof of $1+2+3+\cdots+n = \frac{n(n+1)}{2}$ by strong induction:</strong> Using strong induction here is completely unnecessary, for you do not need it at all, and it is only likely to confuse people as to why you are using it. It will proceed just like a proof by weak induction, but the assumption at the outset will look different; nonetheless, just to show what I am talking about, I will prove it using strong induction.</p> <p>Let $S(n)$ denote the proposition $$ S(n) : 1+2+3+\cdots+n = \frac{n(n+1)}{2}. $$</p> <p><strong>Base step ($n=1$):</strong> $S(1)$ is true because $1=\frac{1(1+1)}{2}$. </p> <p><strong>Inductive step:</strong> Fix some $k\geq 1$, and assume that for every $t$ satisfying $1\leq t\leq k$, the statement $S(t)$ is true. To be shown is that $$ S(k+1) : 1+2+3+\cdots+k+(k+1)=\frac{(k+1)(k+2)}{2} $$ follows. Beginning with the left-hand side of $S(k+1)$, \begin{align} \text{LHS} &amp;= 1+2+3+\cdots+k+(k+1)\tag{by definition}\\[1em] &amp;= (1+2+3+\cdots+k)+(k+1)\tag{group terms}\\[1em] &amp;= \frac{k(k+1)}{2}+(k+1)\tag{by $S(k)$}\\[1em] &amp;= (k+1)\left(\frac{k}{2}+1\right)\tag{factor out $k+1$}\\[1em] &amp;= (k+1)\left(\frac{k+2}{2}\right)\tag{common denominator}\\[1em] &amp;= \frac{(k+1)(k+2)}{2}\tag{desired expression}\\[1em] &amp;= \text{RHS}, \end{align} we obtain the right-hand side of $S(k+1)$. </p> <p>By mathematical induction, for all $n\geq 1$, the statement $S(n)$ is true. $\blacksquare$</p> <p>$\color{red}{\text{Comment:}}$ See how this was really no different than how a proof by weak induction would work? The only thing different is really an unnecessary assumption made at the beginning of the proof. However, in your prime number proof, strong induction is essential; otherwise, we cannot assume $S(r)$ or $S(s)$ to be true. Here, any assumption regarding $t$ where $1\leq t\leq k$ is really useless because we don't actually use it anywhere in the proof, whereas we did use the assumptions $S(r)$ and $S(s)$ in the prime number proof, where $1\leq t\leq m$, because $r,s &lt; m$. Does it now make sense why it was necessary to use strong induction in the prime number proof? </p> <hr> <p><strong>Proof of $(\dagger)$ by induction:</strong> For statements $p_1,\ldots,p_{m+1}$, we have that $$ [p_1\to p_2]\land[p_2\to p_3]\land\cdots\land[p_m\to p_{m+1}]\Rightarrow[(p_1\land p_2\land\cdots\land p_m)\to p_{m+1}]. $$ </p> <p><em>Proof.</em> For each $m\in\mathbb{Z^+}$, let $S(m)$ be the statement that for $m+1$ statements $p_i$, $$ S(m) : [p_1\to p_2]\land[p_2\to p_3]\land\cdots\land[p_m\to p_{m+1}]\Rightarrow[(p_1\land p_2\land\cdots\land p_m)\to p_{m+1}]. $$ <strong>Base step:</strong> The statement $S(1)$ says $$ [p_1\to p_2]\Rightarrow [(p_1\land p_2)\to p_2], $$ which is true (since the right side is a tautology). </p> <p><strong>Inductive step:</strong> Fix $k\geq 1$, and assume that for any statements $q_1,\ldots,q_{k+1}$, both $$ S(1) : [q_1\to q_2]\Rightarrow [(q_1\land q_2)\to q_2] $$ and $$ S(k) : [q_1\to q_2]\land[q_2\to q_3]\land\cdots\land[q_k\to q_{k+1}]\Rightarrow[(q_1\land q_2\land\cdots\land q_k)\to q_{k+1}]. $$ hold. It remains to show that for any statements $p_1,p_2,\ldots,p_k,p_{k+1},p_{k+2}$ that $$ S(k+1) : [p_1\to p_2]\land[p_2\to p_3]\land\cdots\land[p_{k+1}\to p_{k+2}]\Rightarrow[(p_1\land p_2\land\cdots\land p_{k+1})\to p_{k+2}] $$ follows. Beginning with the left-hand side of $S(k+1)$, \begin{align} \text{LHS} &amp;\equiv [p_1\to p_2]\land\cdots\land[p_{k+1}\to p_{k+2}]\land[p_{k+1}\to p_{k+2}]\\[0.5em] &amp;\Downarrow\qquad \text{(definition of conjunction)}\\[0.5em] &amp;[[p_1\to p_2]\land[p_2\to p_3]\land\cdots\land[p_{k+1}\to p_{k+2}]]\land[p_{k+1}\to p_{k+2}]\\[0.5em] &amp;\Downarrow\qquad \text{(by $S(k)$ with each $q_i = p_i$)}\\[0.5em] &amp;[(p_1\land p_2\land\cdots\land p_k)\to p_{k+1}]\land[p_{k+1}\to p_{k+2}]\\[0.5em] &amp;\Downarrow\qquad \text{(by $S(1)$ with $q_1=p_1\land\cdots\land p_k)$ and $q_2=p_{k+1}$)}\\[0.5em] &amp;[[(p_1\land p_2\land\cdots\land p_k)\land p_{k+1}]\to p_{k+1}]\land [p_{k+1}\to p_{k+2}]\\[0.5em] &amp;\Downarrow\qquad \text{(by definition of conjunction)}\\[0.5em] &amp;[(p_1\land p_2\land\cdots\land p_k\land p_{k+1}]\to p_{k+1}]\land [p_{k+1}\to p_{k+2}]\\[0.5em] &amp;\Downarrow\qquad \text{(since $a\land b\to b$ with $b=[p_{k+1}\to p_{k+2}]$)}\\[0.5em] &amp;[(p_1\land p_2\land\cdots\land p_k\land p_{k+1})\to p_{k+2}]\land[p_{k+1}\to p_{k+2}]\\[0.5em] &amp;\Downarrow\qquad \text{(since $a\land b\to a$)}\\[0.5em] &amp;(p_1\land p_2\land\cdots\land p_k\land p_{k+1})\to p_{k+2}\\[0.5em] &amp;\equiv \text{RHS}, \end{align} we obtain the right-hand side of $S(k+1)$, which completes the inductive step.</p> <p>By mathematical induction, for each $n\geq 1, S(n)$ holds. $\blacksquare$</p>
<p>Usually, there is no need to distinguish between weak and strong induction. As you point out, the difference is minor. In both weak and strong induction, you must prove the base case (usually very easy if not trivial). Then, weak induction assumes that the statement is true for size $n-1$ and you must prove that the statement is true for $n$. Using strong induction, you assume that the statement is true for all $m&lt;n$ (at least your base case) and prove the statement for $n$.</p> <p>In practice, one may just always use strong induction (even if you only need to know that the statement is true for $n-1$). In the example that you give, you only need to assume that the formula holds for the previous case (weak) induction. You could assume it holds for every case, but only use the previous case. As far as I can tell, it is really just a matter of semantics. There are times when strong induction really is more useful, the case when you break up the problem into two problem of size $n/2$ for example. This happens frequently when making proofs about graphs where you decompose the graph on $n$ vertices into two subgraphs (smaller, but you have little or no control over the exact size).</p>
game-theory
<p>So there are $n$ people, each choosing some non-zero counting number. You don't know what any of them choose. To win, you must choose the smallest number; but if you choose the same number as somebody else, you are disqualified. How would you decide what number $k$ is best to choose? I feel like $k\le n$, but apart from that I have no idea where to start. Any ideas?</p> <p><strong>EDIT</strong>: So to avoid a trivial paradox and to somewhat model real human behavior, we want the $n$ people to choose numbers reasonably but not necessarily perfectly. For instance, nobody else is gonna choose $k &gt; n$, as that would be silly. Since choosing 1 being unreasonable would lead to paradox, we'll also say 1 could be chosen, but won't necessarily be picked.</p>
<p>Contrary to intuition, the Nash equilibrium for this game (assuming $n\geq 2$) must have positive probability of choosing any positive integer. Assume not, so there is some integer $m$ such that the Nash equilibrium picks $m$ with probability $p_m&gt;0$ but never picks $m+1$. Suppose everyone else is playing that strategy, and consider what happens if you play the modified strategy which instead picks $m+1$ with probability $p_m$ and never picks $m$. This performs exactly the same if you pick some number other than $m+1$. If you pick $m+1$ and would have won had you picked $m$ then you will still win, since no-one else has picked $m+1$ (because they can't) or $m$ (by assumption that you would have won by picking $m$). You also win in the event that you pick $m+1$ and everyone else picks $m$, which has positive probability. So the original strategy wasn't a Nash equilibrium, because this one beats it.</p>
<p>Given that there are $n$ players, let's assume that each player must choose a number $k \in \{z \in \mathbb{Z} | 1 \le z \le n\}$. Note that the order of players picking a number does not affect the outcome.</p> <p>Some thoughts:</p> <p>When $\textbf{n = 2}$ equilibrium is achieved when both players choose the smallest number i.e. $1$.</p> <p>For case $\textbf{n = 3}$, let two numbers from $\{1,2,3\}$ be already choose, then</p> <p>it is impossible to win whenever $\{1, 2\}$, $\{1, 3\}$ are chosen by others.</p> <p>it is possible to win when $\{2, 3\}$, $\{1, 1\}$, $\{2, 2\}$ or $\{3, 3\}$ by others.</p> <p>Let's consider what happens if we choose</p> <p>$\rightarrow$ winning number</p> <p>$1$</p> <p>$\{1, 2\} \rightarrow 2$</p> <p>$\{1, 3\} \rightarrow 3$</p> <p>$\{2, 3\} \rightarrow 1$ <strong>We win!</strong></p> <p>$\{1, 1\}$ <em>No winner.</em></p> <p>$\{2, 2\} \rightarrow 1$ <strong>We win!</strong></p> <p>$\{3, 3\} \rightarrow 1$ <strong>We win!</strong></p> <p>$2$</p> <p>$\{1, 2\} \rightarrow 1$</p> <p>$\{1, 3\} \rightarrow 1$</p> <p>$\{2, 3\} \rightarrow 3$</p> <p>$\{1, 1\} \rightarrow 2$ <strong>We win!</strong></p> <p>$\{2, 2\}$ <em>No winner.</em></p> <p>$\{3, 3\} \rightarrow 2$ <strong>We win!</strong></p> <p>$3$</p> <p>$\{1, 2\} \rightarrow 1$</p> <p>$\{1, 3\} \rightarrow 1$</p> <p>$\{2, 3\} \rightarrow 2$</p> <p>$\{1, 1\} \rightarrow 3$ <strong>We win!</strong></p> <p>$\{2, 2\} \rightarrow 3$ <strong>We win!</strong></p> <p>$\{3, 3\}$ <em>No winner.</em></p> <p>Therefore it has been shown that choosing $1$ when $n = 3$ gives us best chance of winning. Hence, $k = 1$ is the equilibrium.</p> <p>This approach can be generalised for more players.</p>
probability
<p>Consider the triangle formed by randomly distributing three points on a circle. What is the probability of the center of the circle be contained within the triangle?</p>
<p>The probability is, in fact, $\large\frac14$.</p> <p>Wherever the first point is chosen, the diameter on which it lies (the diameter being determined by the circle center and the first chosen point) divides the circle into two symmetric semi-circles, so the second and third points (assuming they are distinct) must necessarily be place on opposite halves of the circle. </p> <p>The line connecting the second and third points must then also lie above the center (with respect to the first point - or below the center, if the first point was on "top"); so if the second point is at a distance $x$ from the first point along the perimeter of the circle (in units of the length of the perimeter), there's a range within length $\frac12-x$ in which to place the third point. Thus, computing the probability gives:</p> <p>$$2\int_0^{\large\frac12}\left(\frac12-x\right)\,dx\;=\;2\int_0^{\large\frac12}x\,dx\;=\;\frac14$$</p> <p>where we multiply the integral by $2$ to cover the fact that we can interchange the second and third point.</p>
<p>The probability is $\frac14$. The argument given in <a href="https://math.stackexchange.com/a/172368/12042">this answer</a> to the corresponding question for $n$-gons applies equally well to circles. <a href="https://math.stackexchange.com/a/1407/12042">This answer</a> to the generalization of this question to arbitrary dimensions may also be of interest: the probability that the convex hull of $n+2$ points in $S^n$ (the unit sphere in $\Bbb R^{n+1}$) contains the origin is $2^{−n−1}$.</p>
logic
<p>There are five boxes in a row. There is robot in any one of these five boxes. Every morning I can open and check a box (one only). In the night, the robot moves to an adjacent box. It is compulsory that he moves. I need a method to ensure that I can catch the robot within ten days. How to do so?</p>
<p>I think 6 tries are enough.</p> <p>For example: 2,3,4,4,3,2</p> <p>The diagram (time goes down) shows, in blue, the posible displacements of the robot, the yellow dots are the (failed) tries, the red lines the impossible displacements, the red dot the impossible positions.</p> <p><img src="https://i.sstatic.net/Ik8fK.png" alt="enter image description here"></p> <p>Another possible try (perhaps more elegant): 2 3 4 2 3 4</p> <p>In general: if we have N boxes (N odd) we make a first sweep 2, 3 ... N-1. If we didn't find it, the it's moving with opposite parity. We try again the same sweep (or the mirrored) and we find it in $2 \times (N-2)$ tries (worst case).</p> <p>Added: The two strategies [2 3 4 2 3 4] and [2 3 4 4 3 2] are equivalent for odd N. But the later works also for even N.</p>
<p>Here's a possible solution. The best way to solve these things is just trying, i think.</p> <p>Check the boxes in this order: 1,2,3,4,5. If you haven't met the robot yet, the robot must have started in box 2 or 4.</p> <p>Proof: Suppose he started in box one, then you would have found him the first day.</p> <p>Suppose it started in box 3, then it moved to 4, then to 5, then to 4, where you find it the forth day.</p> <p>Suppose it started in box 5. It moves to 4, to 5, to 4, and you find it.</p> <p>After these 5 days (nights), the robot has again moved to an odd box: 1, 3 or 5. So, check boxes 1,2,3,4,5 again. you will meet the robot, because of the same reason as you didn't met it during the first five days.</p>
combinatorics
<p>5 mathematicians, 5 biologists, 5 chemists, 5 physicists, and 5 economists sit around a large round table.</p> <p>Prove that the 25 people can be seated such that, if A and B are two different people with the same specialty (for example, two mathematicians), then the people sitting to the immediate left of A and to the immediate left of B are of different specialties (for example, a biologist and a chemist).</p> <p>I thought to use induction, since $n=1$ and $n=2$ are easy to do. However, I don't know how to continue.</p>
<p>We prove this generalization: If there are $n$ people each of $n$ different specialties, then the $n^2$ people can be seated around a round table such that, if $A$ and $B$ are two different people with the same specialty, then the people sitting to the immediate left of A and to the immediate left of $B$ are of different specialties. (Our problem is the case $n=5$.) </p> <p>If $n=1$, then there is only one person, so the statement we're trying to prove is trivial. If $n=2$, then there are two people in each of two specialties. They can be seated so that both pairs of people of the same specialty are next to each other; this seating satisfies the requirements of the problem. We now continue by induction. </p> <p>Suppose that we can seat $n$ people in each of $n$ specialties according to the conditions of the problem. Now consider the problem with $n+1$ people in each of $n+1$ specialties. To our existing $n$-specialty seating, we need to add $1$ additional person from each of the original $n$ specialties, plus $n+1$ people from the new specialty, which we'll call $Z$. </p> <p>Let $S$ be one of the original $n$ specialties, and consider the left neighbors of the original $n$ people from $S$. Those neighbors must all have different specialties (among the original $n$ specialties), so among them there must be exactly one from each original specialty, including S itself. Thus there must be a pair of specialists in $S$ in adjacent seats. We seat the $(n+1)^{\text{th}}$ person from $S$ and one person from $Z$ (in either order) between the adjacent pair of people from $S$. We have thereby put a specialty-$Z$ person to the left of a specialty-$S$ person, and a specialty-$S$ person to the left of a specialty-$Z$ person; this is all we've done. So, it's still the case that no two people from the same specialty have people from the same specialty as their neighbors to the left. We repeat this operation for all $n$ choices of specialty $S$. </p> <p>Finally, we need to add the $(n+1)^{\text{th}}$ specialty-$Z$ person. We can simply seat her next to any other specialty-$Z$ person. By construction, all the specialty-$Z$ people will have left neighbors of different specialties. </p> <p>As an example, in our problem, we have $5$ people each of specialties M,B,C,P, and E. We can iterate the above process as follows, where the lists below are thought of as starting at some point on the table and going clockwise:</p> <p>$\begin{align} M \\MMBB \\ MMCCMBBCB\\ MMPPMCCPCMBBPBCB\\MMEEMPPEPMCCECPCMBBEBPBCB \end{align}$</p> <p>Note that in each list, no letter pair appears twice in the sequence.</p>
<p>It's a graph theory problem. What you're looking for is an <a href="https://en.wikipedia.org/wiki/Eulerian_path" rel="nofollow noreferrer">Eulerian circuit</a> in a complete directed graph of order $5$, consisting of five vertices $M,B,C,P,E$ and $25$ directed edges, one going from every vertex to every other vertex and also one looping from each vertex to itself. The existence of an Eulerian circuit (i.e. traversing each edge exactly once) in your graph is easily shown; see the answer to <a href="https://math.stackexchange.com/questions/81554/necessary-and-sufficient-condition-for-a-directed-graph-be-eulerian-circuit-and">this question</a>.</p> <p>For generalizations look up <a href="https://en.wikipedia.org/wiki/De_Bruijn_sequence" rel="nofollow noreferrer">De Bruijn sequence</a>.</p>
number-theory
<p>In <a href="https://math.stackexchange.com/questions/13050/eee79-and-ultrafinitism/">this question</a>, I needed to assume in my answer that $e^{e^{e^{79}}}$ is not an integer. Is there some standard result in number theory that applies to situations like this? </p> <p>After several years, it appears this is an open problem. As a non-number theorist, I had assumed there would be known results that would answer the question. I was aware of the difficulty in proving various constants to be transcendental -- such as $e + \pi$, which is not known to be transcendental at present. </p> <p>However, I was looking at a question that seems simpler, naively: whether a number is an integer, rather than whether it is transcendental. It seems that what appeared to be possibly simpler is actually not, with current techniques. </p> <p>The main motivation for asking about this particular number is that it is very large. It is certainly possible to find a pair of very large numbers, at least one of which is transcendental. But the current lack of knowledge about this particular number is even an integer shows just how much progress remains to be made, in my opinion. Any answers that describe techniques that would suffice to solve the problem (perhaps with other, unproven assumptions) would be very welcome. </p>
<p>The paper Chuangxun Cheng, Brian Dietel, Mathilde Herblot, Jingjing Huang, Holly Krieger, Diego Marques, Jonathan Mason, Martin Mereb, and S. Robert Wilson, Some consequences of Schanuel’s conjecture, Journal of Number Theory 129 (2009) 1464–1467, shows that <span class="math-container">$e,e^e,e^{e^e},\dots$</span> is an algebraically independent set, on the assumption of Schanuel's Conjecture. Maybe a close reading of that paper will suggest a way of applying the result to the <span class="math-container">$79-$</span>question.</p>
<p>if $e^{e^{e^{79}}}$ is an integer then $e^{e^{e^{e^{79}}}}$ is not an integer (otherwise $e$ would be algebraic). Perhaps your arguments make sense with this number too.</p>
probability
<p>My understanding right now is that an example of conditional independence would be:</p> <p>If two people live in the same city, the probability that person <strong>A</strong> gets home in time for dinner, and the probability that person <strong>B</strong> gets home in time for dinner are independent; that is, we wouldn't expect one to have an effect on the other. But if a snow storm hits the city and introduces a probability <strong>C</strong> that traffic will be at a stand still, you would expect that the probability of both <strong>A</strong> getting home in time for dinner and <strong>B</strong> getting home in time for dinner, would change.</p> <p>If this is a correct understanding, I guess I still don't understand what exactly conditional independence <em>is</em>, or what it does for us (why does it have a separate name, as opposed to just compounded probabilities), and if this isn't a correct understanding, could someone please provide an example with an explanation?</p>
<p>The scenario you describe provides a good example for conditional independence, though you haven't quite described it as such. As <a href="http://en.wikipedia.org/wiki/Conditional_independence" rel="noreferrer">the Wikipedia article</a> puts it, </p> <blockquote> <p>$R$ and $B$ are conditionally independent [given $Y$] if and only if, given knowledge of whether $Y$ occurs, knowledge of whether $R$ occurs provides no information on the likelihood of $B$ occurring, and knowledge of whether $B$ occurs provides no information on the likelihood of $R$ occurring.</p> </blockquote> <p>In this case, $R$ and $B$ are the events of persons <strong>A</strong> and <strong>B</strong> getting home in time for dinner, and $Y$ is the event of a snow storm hitting the city. Certainly the probabilities of $R$ and $B$ will depend on whether $Y$ occurs. However, just as it's plausible to assume that if these two people have nothing to do with each other their probabilities of getting home in time are independent, it's also plausible to assume that, while they will both have a lower probability of getting home in time if a snow storm hits, these lower probabilities will nevertheless still be independent of each other. That is, if you already know that a snow storm is raging and I tell you that person <strong>A</strong> is getting home late, that gives you no new information about whether person <strong>B</strong> is getting home late. You're getting information on that from the fact that there's a snow storm, but given that fact, the fact that <strong>A</strong> is getting home late doesn't make it more or less likely that <strong>B</strong> is getting home late, too. So conditional independence is the same as normal independence, but restricted to the case where you know that a certain condition is or isn't fulfilled. Not only can you not find out about <strong>A</strong> by finding out about <strong>B</strong> in general (normal independence), but you also can't do so under the condition that there's a snow storm (conditional independence).</p> <p>An example of events that are independent but not conditionally independent would be: You randomly sample two people <strong>A</strong> and <strong>B</strong> from a large population and consider the probabilities that they will get home in time. Without any further knowledge, you might plausibly assume that these probabilities are independent. Now you introduce event $Y$, which occurs if the two people live in the same neighbourhood (however that might be defined). If you know that $Y$ occurred and I tell you that <strong>A</strong> is getting home late, then that would tend to increase the probability that <strong>B</strong> is also getting home late, since they live in the same neighbourhood and any traffic-related causes of <strong>A</strong> getting home late might also delay <strong>B</strong>. So in this case the probabilities of <strong>A</strong> and <strong>B</strong> getting home in time are not conditionally independent given $Y$, since once you know that $Y$ occurred, you are able to gain information about the probability of <strong>B</strong> getting home in time by finding out whether <strong>A</strong> is getting home in time.</p> <p>Strictly speaking, this scenario only works if there's always the same amount of traffic delay in the city overall and it just moves to different neighbourhoods. If that's not the case, then it wouldn't be correct to assume independence between the two probabilities, since the fact that one of the two is getting home late would already make it somewhat likelier that there's heavy traffic in the city in general, even without knowing that they live in the same neighbourhood.</p> <p>To give a precise example: Say you roll a blue die and a red die. The two results are independent of each other. Now you tell me that the blue result isn't a $6$ and the red result isn't a $1$. You've given me new information, but that hasn't affected the independence of the results. By taking a look at the blue die, I can't gain any knowledge about the red die; after I look at the blue die I will still have a probability of $1/5$ for each number on the red die except $1$. So the probabilities for the results are conditionally independent given the information you've given me. But if instead you tell me that the sum of the two results is even, this allows me to learn a lot about the red die by looking at the blue die. For instance, if I see a $3$ on the blue die, the red die can only be $1$, $3$ or $5$. So in this case the probabilities for the results are not conditionally independent given this other information that you've given me. This also underscores that conditional independence is always relative to the given condition -- in this case, the results of the dice rolls are conditionally independent with respect to the event "the blue result is not $6$ and the red result is not $1$", but they're not conditionally independent with respect to the event "the sum of the results is even".</p>
<p>The example you've given (the snowstorm) is usually given as a case where you might <em>think</em> two events might be truly independent (since they take totally different routes home), i.e.</p> <p>$p(A|B)=p(A)$.</p> <p>However in this case they are not truly independent, they are "only" conditionally independent given the snowstorm i.e.</p> <p>$p(A|B,Z) = p(A|Z)$.</p> <p>A clearer example paraphrased from <a href="https://www.eecs.qmul.ac.uk/~norman/BBNs/Independence_and_conditional_independence.htm" rel="noreferrer">Norman Fenton's website</a>: if Alice (A) and Bob (B) both flip the same coin, but that coin might be biased, <em>we cannot say</em></p> <p>$p(A=H|B=H) = p(A=H)$</p> <p>(i.e. that they are independent) because if we see Bob flips heads, it is more likely to be biased towards heads, and hence the left probability should be higher. However if we denote Z as the event "the coin is biased towards heads", then</p> <p>$p(A=H|B=H,Z)=p(A=H|Z)$</p> <p>we can remove Bob from the equation because we know the coin is biased. Given the fact that the coin is biased, the two flips are conditionally independent.</p> <p>This is the common form of conditional independence, you have events that are not statistically independent, but they are conditionally independent.</p> <p>It is possible for something to be statistically independent and not conditionally independent. To borrow from <a href="https://en.wikipedia.org/wiki/Conditional_independence" rel="noreferrer">Wikipedia</a>: if $A$ and $B$ both take the value $0$ or $1$ with $0.5$ probability, and $C$ denotes the product of the values of $A$ and $B$ ($C=A\times B$), then $A$ and $B$ are independent:</p> <p>$p(A=0|B=0) = p(A=0) = 0.5$</p> <p>but they are not conditionally independent given $C$:</p> <p>$p(A=0|B=0,C=0) = 0.5 \neq \frac{2}{3} = p(A=0|C=0)$</p>
logic
<p><a href="http://en.wikipedia.org/wiki/Second-order_logic" rel="noreferrer">Wikipedia</a> describes the first-order vs. second-order logic as follows:</p> <blockquote> <p>First-order logic uses only variables that range over <strong>individuals</strong> (elements of the domain of discourse); second-order logic has these variables as well as additional variables that range over <strong>sets of individuals</strong>.</p> </blockquote> <p>It gives $\forall P\,\forall x (x \in P \lor x \notin P)$ as an SO-logic formula, which makes perfect sense to me.</p> <p>However, in a <a href="https://cstheory.stackexchange.com/q/5117/873">post at CSTheory</a>, the poster claimed that $\forall x\forall y(x=y\leftrightarrow\forall z(z\in x\leftrightarrow z\in y))$ is an FO formula. I think this must not be the case, since in the above formula, $x$ and $y$ are <strong>sets of individuals</strong>, while $z$ is an <strong>individual</strong> (and therefore this must be an SO formula).</p> <p>I mentioned this as a comment, but two users commented that ZF can be entirely described by FO logic, and therefore $\forall x\forall y(x=y\leftrightarrow\forall z(z\in x\leftrightarrow z\in y))$ is an FO formula.</p> <p>I'm confused. Could someone explain this please?</p>
<p>It seems to me that you're confusing the first order formulas with their intended interpretations.</p> <p>The language of set theory consists of just a single 2 place predicate symbol, usually denoted $\in$. The statement you quote is a first order statement - it means just what is says: "for all $x$ and for all $y$, ($x = y$ iff for all $z$, ($z \in x$ iff $z \in y$))", but it does <em>not</em> tell you what $x$ is. When you say "but $x$ is a set and $z$ is an individual, so this statement looks second order!", you're adding an interpretation to the picture which is not specified by the first order formula alone - namely that "for all x" means "for all sets x" and "$\in$" means "the usual $\in$ in set theory".</p> <p>In first order logic, this "adding of interpretation" is usually called "exhibiting a model".</p> <p>Here's another way of looking at this same first order statement. Suppose I reinterpret things - I say "for all $x$" means "for all real numbers $x$" and $\in$ means $&lt;$. Then, $\forall x \forall y$ ($x=y$ iff $\forall z$, ($z \in x$ iff $z \in y$)) is a true statement: it says two real numbers are equal iff they have the same collection of smaller things. Notice that in this model, nothing looks second order.</p> <p>By contrast, in second order logic, you are directly referring to subsets, so that in any model (that is, interpretation), $\forall S$ means "for all subsets of whatever set the variable $x$ ranges over".</p>
<p>The statement is indeed a first order statement in standard Set Theory. But it is no wonder you are a bit confused.</p> <p>Most people think of sets and elements as different things. However, in standard set theory this is not the case. </p> <p>In standard set theory, <em>everything</em> is a set (there are no "ur-elements", elements that are not sets). The <em>objects</em> of set theory are sets themselves. The primitive relation $\in$ is a relation between <em>sets</em>, not between ur-elements and sets. So, for example, the Axiom of the Power Set in ZFC states that $$\forall x\exists y(\forall z(z\in y \leftrightarrow z\subseteq x))$$ which is a first order statement, because all the things being quantified over are objects in the theory (namely, "sets").</p> <p>So you need to forget the notion that "elements" are things <em>in</em> sets and sets are things that contain elements. In ZF, <em>everything</em> is a set.</p> <p>It's a little hard to see the distinction between first and second order statements in ZF precisely because "sets" are the objects, and moreover, given any set, there is a <em>set</em> that contains all the subsets (the power set). In a way, the Axioms are set up precisely to allow you to talk about collections of sets without having to go to second order logic. </p> <p>In ZF, to get to second order you need to start talking about "proper classes" or "properties". For instance, that's why Comprehension is not a single axiom, but an entire infinite family of axioms. Comprehension essentially says that for <em>every</em> property $P$ and every object $x$ of the theory (i.e., every set $x$), $\{y\mid y\in x\wedge P(y)\}$ is a set. But trying to quantify over <em>all propositions</em> would be a second order statement. Instead, you have an "Axiom Schema" which says that for each property $P$, you have an axiom that says $$\forall x\exists y\Bigl(z\in y\leftrightarrow\bigl(z\in x\wedge P(z)\bigr)\Bigr).$$ If you try quantifying over "all $P$", <strong>then</strong> you get a second order statement in ZF. </p>
geometry
<p>We define an <strong>integer</strong> polynomial as polynomial that has only integer coefficients. Here I am only interested in polynomials in two variables.</p> <p>Example:</p> <ul> <li>$P = 5x^4 + 7 x^3y^4 + 4y$</li> </ul> <p>Note that each polynomial P defines a curve by considering the set of points where it evaluates to zero. We will speak about this curve.</p> <p>Example: </p> <p>The circle can be described by</p> <ul> <li>$x^2 + y^2 -1 = 0$</li> </ul> <p>We say two polynomials $P,Q$ are <strong>touching</strong> in point $(a,b)$ if $P(a,b) = Q(a,b) = 0$ and the tangent at $(a,b)$ is the same. Or more geometrically, the curves of $P$ and $Q$ are not crossing.</p> <p><a href="https://i.sstatic.net/emOI2.png" rel="noreferrer"><img src="https://i.sstatic.net/emOI2.png" alt="enter image description here"></a></p> <p>(The Figure was created with IPE - drawing editor.)</p> <p>We also need a further technical condition. For this let $D$ be a ''small enough'' disk around $(a,b)$. Then $Q$ and $P$ define two regions indicated green and yellow. Those regions must be interior disjoint. Without this condition for $P = y-x^3$ and $Q=y$ the point $(0,0)$ would be a touching point as well. See also the right side of the figure. (I know that I am not totally precise here, but I don't want to be too formal, so that I can reach a wide audience.) (Thanks for the comment from Jeppe Stig Nielsen.)</p> <p>Example:</p> <ul> <li>$P = y - x^2$ (Parabola)</li> <li>$Q = y$ ($x$-axis)</li> </ul> <p>They touch at the origin $(0,0)$.</p> <p>My question: </p> <p>Does there exist two <em>integer</em> polynomials $P,Q$ that <em>touch</em> in an <em>irrational</em> point $(a,b)$? (It would be fine for me if either $a$ or $b$ is irrational)</p> <p>Many thanks for answers and comments. Till</p>
<p>What about $(x^2-2)^2$ and $0$?</p> <p><a href="https://www.wolframalpha.com/input/?i=plot+%7B(x%5E2-2)%5E2,+0%7D+for+x+from+-2+to+2" rel="noreferrer"><img src="https://i.sstatic.net/mgjRD.gif" alt="quad and 0"></a></p> <p>If you want both coordinates to be irrational, you can add something like $x^3$ to both.</p> <p><a href="https://www.wolframalpha.com/input/?i=plot+%7B(x%5E2-2)%5E2%2Bx%5E3,+0%2Bx%5E3%7D+for+x+from+-2+to+2" rel="noreferrer"><img src="https://i.sstatic.net/0EUqw.gif" alt="quad and cubic"></a></p> <p>I hope this helps $\ddot\smile$</p> <hr> <p><sup>Images courtesy of <a href="https://www.wolframalpha.com/" rel="noreferrer">WolframAlpha</a>.</sup></p>
<p>If you have an irrational tangent point between your curves, it must have at least another conjugate, and since tangent points are double points, by Bézout's theorem, the product of the degrees of the curves must be at least $4$.</p> <p>Since dtldarek gave an example of a degree $4$ curve and a degree $1$ curve, let me give an example between two degree $2$ curves :</p> <p>The circle $x^2+y^2= 1$ and the ellipse $17x² + 8y² + 12x = 4$ are tangent at $(-2/3, \pm \sqrt {5}/3)$</p> <p><a href="https://i.sstatic.net/lNiDf.png"><img src="https://i.sstatic.net/lNiDf.png" alt="enter image description here"></a></p>
linear-algebra
<p>We are allowed to use a calculator in our linear algebra exam. Luckily, my calculator can also do matrix calculations.</p> <p>Let's say there is a task like this:</p> <blockquote> <p>Calculate the rank of this matrix:</p> <p>$$M =\begin{pmatrix} 5 &amp; 6 &amp; 7\\ 12 &amp;4 &amp;9 \\ 1 &amp; 7 &amp; 4 \end{pmatrix}$$</p> </blockquote> <p>The problem with this matrix is we cannot use the trick with multiples, we cannot see multiples on first glance and thus cannot say whether the vectors rows / columns are linearly in/dependent. Using Gauss is also very time consuming (especially in case we don't get a zero line and keep trying harder).</p> <p>Enough said, I took my calculator because we are allowed to use it and it gives me following results:</p> <p>$$M =\begin{pmatrix} 1 &amp; 0{,}3333 &amp; 0{,}75\\ 0 &amp;1 &amp;0{,}75 \\ 0 &amp; 0 &amp; 1 \end{pmatrix}$$</p> <p>I quickly see that $\text{rank(M)} = 3$ since there is no row full of zeroes.</p> <p>Now my question is, how can I convince the teacher that I calculated it? If the task says "calculate" and I just write down the result, I don't think I will get all the points. What would you do?</p> <p>And please give me some advice, this is really time consuming in an exam.</p>
<p>There is a very nice trick for showing that such matrix has full rank, it can be performed in a few seconds without any calculator or worrying "moral bending". The entries of $M$ are integers, so the determinant of $M$ is an integer, and $\det M\mod{2} = \det(M\mod{2})$. Since $M\pmod{2}$ has the following structure $$ \begin{pmatrix} 1 &amp; 0 &amp; 1 \\ 0 &amp; 0 &amp; 1 \\ 1 &amp; 1 &amp; 0\end{pmatrix} $$ it is trivial that $\det M$ is an odd integer. In particular, $\det M\neq 0$ and $\text{rank}(M)=3$.</p>
<p>You're allowed to use your calculator. So, if it were me on the test, I'd write something like this:</p> <blockquote> <p>$$ \pmatrix{5&amp;6&amp;7\\12&amp;4&amp;9\\1&amp;7&amp;4} \overset{REF}{\to} \pmatrix{ 1 &amp; 0,3333 &amp; 0,75\\ 0 &amp;1 &amp;0,75 \\ 0 &amp; 0 &amp; 1 } $$ because the reduced form of $M$ has no zero rows, $M$ has rank $3$.</p> </blockquote> <p>REF here stands for row-echelon form.</p> <hr> <p><strong>Note:</strong> You should check with your professor whether or not this constitutes a sufficient answer. It may be the case that your professor wants any <em>matrix-calculations</em> to be done by hand. See Robert Israel's comment.</p> <p>If that's the case, then you should do row-reduction by hand. It only takes 3 row operations, though.</p>
logic
<p>In <a href="https://www.youtube.com/watch?v=O4ndIDcDSGc" rel="noreferrer">the most recent numberphile video</a>, Marcus du Sautoy claims that a proof for the Riemann hypothesis must exist (starts at the 12 minute mark). His reasoning goes as follows:</p> <ul> <li><p>If the hypothesis is undecidable, there is no proof it is false.</p></li> <li><p>If we find a non-trivial zero, that is a proof that it is false.</p></li> <li><p>Thus if it is undecidable there are no non-trivial zeros.</p></li> <li><p>This constitutes a proof the hypothesis is true, thus it is decidable.</p></li> </ul> <p>This makes perfect sense, however only seconds earlier he states that the Goldbach conjecture <em>might</em> be undecidable. It seems to me that the exact same reasoning we applied to the Riemann hypothesis could be applied to the Goldbach conjecture. Just switch out the words "non-trivial zero" for "even number that cannot be represented by the sum of two primes" and to me this reasoning looks fine.</p> <p>In fact as far as I can tell <em>any</em> statement that can be verified or falsified by example can be plugged into this to generate a proof it is decidable.</p> <p>Since Marcus du Sautoy is considerably more qualified than I to speak about this I trust that there is something more complex going on behind the scenes here. Does this apply to the Goldbach conjecture? If not why not? What am I not understanding here?</p>
<p>The issue here is how complicated is each statement, when formulated as a claim about the natural numbers (the Riemann hypothesis can be made into such statement).</p> <hr> <p>For the purpose of this discussion we work in the natural numbers, with $+,\cdot$ and the successor function, and Peano Axioms will be our base theory; so by "true" and "false" we mean in the natural numbers and "provable" means from Peano Arithmetic. </p> <p>We will say that a statement is "simple" if in order to verify it, you absolutely know that you do not have to check <em>all</em> the natural numbers. (The technical term here is "bounded" or "$\Delta_0$".)</p> <p>For example, "There is a prime number small than $x$" is a simple statement, since verifying whether or not some $n$ is prime requires only checking its divisibility by numbers less than $n$. So we only need to check numbers below $x$ in order to verify this.</p> <p>On the other hand, "There is a Fermat prime larger than $x$" is not a simple statement, since possibly this is false but only checking <em>all</em> the numbers above $x$ will tell us the truth of this statement.</p> <p>The trick is that a simple statement is true if and only if it is provable. This requires some work, but it is not incredibly difficult to show. Alas, most interesting questions cannot be formulated as simple statements. Luckily for us, this "provable if and only if true" can be pushed a bit more. </p> <p>We say that a statement is "relatively simple" if it has the form "There exists some value for $x$ such that plugging it in will turn the statement simple". (The technical term is $\Sigma_1$ statement.)</p> <p>Looking back, the statement about the existence of a Fermat prime above $x$ is such statement. Because if $n&gt;x$ is a Fermat prime, then the statement "$n$ is larger than $x$ and a Fermat prime" is now simple. </p> <p>Using a neat little trick we can show that a relatively simple statement is also true if and only if it is provable. </p> <p>And now comes the nice part. The Riemann hypothesis can be formulated as the negation of a relatively simple statement. So if the Riemann hypothesis was false, its negation was provable, so Riemann hypothesis would be refutable. This means that if you cannot disprove the Riemann hypothesis, it has to be true. The same can also be said on the Goldbach conjecture.</p> <p>So both of these might turn to be independent, in the sense that they cannot be proved from Peano Arithmetic, but if you show that they are at least consistent, then you immediately obtain that they are true. And this would give us a proof of these statements from a stronger theory (e.g. set theory).</p> <p>You could also ask the same about the twin prime conjecture. But this conjecture is no longer a relatively simple statement nor the negation of one. So the above does not hold for, and it is feasible that the conjecture is consistent, but false in the natural numbers.</p>
<p>The last bullet point, saying that this constitutes a proof it is decidable, does not follow.</p> <p>$X$ is decidable means either $X$ is provable or $\neg X$ is provable. It's possible that both are provable, in which case the theory is inconsistent and every statement and its negation are provable and every statement is decidable.</p> <p>The situation generalizes to any statement on the same level of the <a href="https://en.wikipedia.org/wiki/Arithmetical_hierarchy" rel="noreferrer">arithmetical hierarchy</a> as the Riemann hypothesis or the Goldbach conjecture, including the Gödel sentence. All assert the existence or non-existence of a natural number satisfying a computable predicate. If the existential form is unprovable then the universal form is true. And the contrapositive is: if the universal form is false, then the existential form is provable (implying both forms are decidable). So if RH is false then RH is decidable, and if GC is false then GC is decidable, and if arithmetic is inconsistent then the consistency of arithmetic is decidable. That may be what was intended by the final point.</p> <p>An example of a <a href="https://rjlipton.wordpress.com/2009/05/27/arithmetic-hierarchy-and-pnp/" rel="noreferrer">problem with a different situation</a> is $\text{P=NP}$.</p>
logic
<p>I am familiar with the mechanism of proof by contradiction: we want to prove $P$, so we assume $¬P$ and prove that this is false; hence $P$ must be true.</p> <p>I have the following devil's advocate question, which might seem to be more philosophy than mathematics, but I would prefer answers from a mathematician's point of view:</p> <p>When we prove that $¬P$ is "false", what we are really showing is that it is inconsistent with our underlying set of axioms. Could there ever be a case were, for some $P$ and some set of axioms, $P$ and $¬P$ are <em>both</em> inconsistent with those axioms (or both consistent, for that matter)?</p>
<p>The situation you ask about, where $P$ is inconsistent with our axioms and $\neg P$ is also inconsistent with our axioms, would mean that the axioms themselves are inconsistent. Specifically, the inconsistency of $P$ with the axioms would mean that $\neg P$ is provable from those axioms. If, in addition, $\neg P$ is inconsistent with the axioms, then the axioms themselves are inconsistent --- they imply $\neg P$ and then they contradict that. (I have phrased this answer so that it remains correct even if the underlying logic of the axiom system is intuitionistic rather than classical.)</p>
<p>It is possible for both $P$ and $ \neg P $ to be consistent with a set of axioms. If this is the case, then $P$ is called <em>independent</em>. There are a few things known to be independent, such as the Continuum Hypothesis being independent of ZFC.</p> <p>It is also possible for both $P$ and $ \neg P $ to be inconsistent with a set of axioms. In this case the axioms are considered inconsistent. Inconsistent axioms result in systems which don't work in a way that is useful for engaging in mathematics.</p> <p>Proof by contradiction depends on the law of the excluded middle. Constructivist mathematics, which uses intuitionistic logic, rejects the use of the law of the excluded middle, and this results in a different type of mathematics. However, this doesn't protect them from the problems resulting from inconsistent axioms.</p> <p>There are logical systems called <em>paraconsistent logic</em> which can withstand inconsistent axioms. However, they are more difficult to work with than standard logic and are not as widely studied.</p>
geometry
<p>Back in grade school, I had a solution involving "folding the triangle" into a rectangle half the area, and seeing that all the angles met at a point:</p> <p><a href="https://i.sstatic.net/8UuqW.png" rel="noreferrer"><img src="https://i.sstatic.net/8UuqW.png" alt="triangle proof"></a></p> <p>However, now that I'm in university, I'm not convinced that this proof is the best one (although it's still my favourite non-rigorous demonstration). Is there a proof in, say, linear algebra, that the sum of the angles of a triangle is 180 degrees? Or any other Euclidean proofs that I'm not aware of?</p>
<p>Here's a decent Euclidean proof:</p> <p>Let $x$ be the line parallel to side $AB$ of $\triangle ABC$ that goes through point $C$ (the line is unique because of the fifth postulate). $AC$ cuts $x$ and $AB$ at the same angle, $\angle BAC$ (corollary of the fifth postulate). $BC$ cuts $x$ and $AB$ at the same angle, $\angle ABC$. These two angles and the final angle $\angle ACB$ form a straight angle on $x$, which is always $180^\circ$ (corollary of the third postulate).</p> <p><img src="https://i.sstatic.net/N9fP4.gif" alt="enter image description here"></p>
<p>According to the <a href="http://en.wikipedia.org/wiki/Gauss%E2%80%93Bonnet_theorem">Gauss-Bonnet theorem</a>, if $T$ is your triangle, $\gamma_i$ its sides and $v_i$ its vertices, $$\int_T K+\sum_i\int_{\gamma_i}\kappa + \sum_i\alpha_i=2\pi\chi(T)$$ with $K$ the Gaussian curvature, $\kappa$ the geodesic curvature along the sides, $\alpha_i$ the external angle at the vertex $v_i$ (measured in radians), and $\chi(T)$ the Euler characteristic of $T$. Since the plane is flat, $K\equiv 0$; since the sides of the triangle are geodesics, $\kappa\equiv0$; and since $T$ is contractible, $\chi(T)=1$. Therefore the above formula tells us that $$\sum_i\alpha_i=2\pi.$$ Since the internal angle at the $i$th vertex is $\pi-\alpha_i$, this tells us that the sum of the internal angles is $\pi$, which is what we wanted</p>
matrices
<p>This question aims to create an &quot;<a href="http://meta.math.stackexchange.com/q/1756/18880">abstract duplicate</a>&quot; of numerous questions that ask about determinants of specific matrices (I may have missed a few):</p> <ul> <li><a href="https://math.stackexchange.com/q/153457/18880">Characteristic polynomial of a matrix of $1$&#39;s</a></li> <li><a href="https://math.stackexchange.com/q/55165/18880">Eigenvalues of the rank one matrix $uv^T$</a></li> <li><a href="https://math.stackexchange.com/q/577937/18880">Calculating $\det(A+I)$ for matrix $A$ defined by products</a></li> <li><a href="https://math.stackexchange.com/q/84206/18880">How to calculate the determinant of all-ones matrix minus the identity?</a></li> <li><a href="https://math.stackexchange.com/q/86644/18880">Determinant of a specially structured matrix ($a$&#39;s on the diagonal, all other entries equal to $b$)</a></li> <li><a href="https://math.stackexchange.com/q/629892/18880">Determinant of a special $n\times n$ matrix</a></li> <li><a href="https://math.stackexchange.com/q/689111/18880">Find the eigenvalues of a matrix with ones in the diagonal, and all the other elements equal</a></li> <li><a href="https://math.stackexchange.com/q/897469/18880">Determinant of a matrix with $t$ in all off-diagonal entries.</a></li> <li><a href="https://math.stackexchange.com/q/227096/18880">Characteristic polynomial - using rank?</a></li> <li><a href="https://math.stackexchange.com/q/3955338/18880">Caclulate $X_A(x) $ and $m_A(x) $ of a matrix $A\in \mathbb{C}^{n\times n}:a_{ij}=i\cdot j$</a></li> <li><a href="https://math.stackexchange.com/q/219731/18880">Determinant of rank-one perturbations of (invertible) matrices</a></li> </ul> <p>The general question of this type is</p> <blockquote> <p>Let <span class="math-container">$A$</span> be a square matrix of rank<span class="math-container">$~1$</span>, let <span class="math-container">$I$</span> the identity matrix of the same size, and <span class="math-container">$\lambda$</span> a scalar. What is the determinant of <span class="math-container">$A+\lambda I$</span>?</p> </blockquote> <p>A clearly very closely related question is</p> <blockquote> <p>What is the characteristic polynomial of a matrix <span class="math-container">$A$</span> of rank<span class="math-container">$~1$</span>?</p> </blockquote>
<p>The formulation in terms of the characteristic polynomial leads immediately to an easy answer. For once one uses knowledge about the eigenvalues to find the characteristic polynomial instead of the other way around. Since $A$ has rank$~1$, the kernel of the associated linear operator has dimension $n-1$ (where $n$ is the size of the matrix), so there is (unless $n=1$) an eigenvalue$~0$ with geometric multiplicity$~n-1$. The algebraic multiplicity of $0$ as eigenvalue is then at least $n-1$, so $X^{n-1}$ divides the characteristic polynomial$~\chi_A$, and $\chi_A=X^n-cX^{n-1}$ for some constant$~c$. In fact $c$ is the trace $\def\tr{\operatorname{tr}}\tr(A)$ of$~A$, since this holds for the coefficient of $X^{n-1}$ of <em>any</em> square matrix of size$~n$. So the answer to the second question is</p> <blockquote> <p>The characteristic polynomial of an $n\times n$ matrix $A$ of rank$~1$ is $X^n-cX^{n-1}=X^{n-1}(X-c)$, where $c=\tr(A)$.</p> </blockquote> <p>The nonzero vectors in the $1$-dimensional image of$~A$ are eigenvectors for the eigenvalue$~c$, in other words $A-cI$ is zero on the image of$~A$, which implies that $X(X-c)$ is an annihilating polynomial for$~A$. Therefore</p> <blockquote> <p>The minimal polynomial of an $n\times n$ matrix $A$ of rank$~1$ with $n&gt;1$ is $X(X-c)$, where $c=\tr(A)$. In particular a rank$~1$ square matrix $A$ of size $n&gt;1$ is diagonalisable if and only if $\tr(A)\neq0$.</p> </blockquote> <p>See also <a href="https://math.stackexchange.com/q/52395/18880">this question</a>.</p> <p>For the first question we get from this (replacing $A$ by $-A$, which is also of rank$~1$)</p> <blockquote> <p>For a matrix $A$ of rank$~1$ one has $\det(A+\lambda I)=\lambda^{n-1}(\lambda+c)$, where $c=\tr(A)$.</p> </blockquote> <p>In particular, for an $n\times n$ matrix with diagonal entries all equal to$~a$ and off-diagonal entries all equal to$~b$ (which is the most popular special case of a linear combination of a scalar and a rank-one matrix) one finds (using for $A$ the all-$b$ matrix, and $\lambda=a-b$) as determinant $(a-b)^{n-1}(a+(n-1)b)$.</p>
<p>Here’s an answer without using eigenvalues: the rank of <span class="math-container">$A$</span> is <span class="math-container">$1$</span> so its image is spanned by some nonzero vector <span class="math-container">$v$</span>. Let <span class="math-container">$\mu$</span> be such that <span class="math-container">$$Av=\mu v.$$</span></p> <p>We can extend this vector <span class="math-container">$v$</span> to a basis of <span class="math-container">$\mathbb{C}^n$</span>. With respect to this basis now, we have that the matrix of <span class="math-container">$A$</span> has all rows except the first one equal to <span class="math-container">$0$</span>. Since determinant and trace are basis-independent it follows by expanding the first column of <span class="math-container">$A$</span> wrt to this basis that <span class="math-container">$$\det(A-\lambda I)= (-1)^n(\lambda -\mu)\lambda^{n-1}.$$</span> Using this same basis as above we also see that <span class="math-container">$\text{Tr}(A) =\mu$</span>, so the characteristic polynomial of <span class="math-container">$A$</span> turns out to be</p> <p><span class="math-container">$$(-1)^n(\lambda -\text{Tr}(A))\lambda^{n-1}.$$</span></p>
probability
<p>Suppose the winning combination consists of $7$ digits, each digit randomly ranging from $0$ to $9$. So the probability of $1111111$, $3141592$ and $8174249$ are the same. But $1111111$ seems (to me) far less likely to be the lucky number than $8174249$. Is my intuition simply wrong or is it correct in some sense?</p>
<p>You should never bet on that kind of sequence. Now, every poster will agree that the odds of any sequence from 000000000 through 999999999 has an equal probability. And if the prize is the same for all winners, it's fine. But, for <em>shared prizes</em>, you will find that you just beat 10 million to 1 odds only to split the pot with dozens of people. To be clear, the odds are the same, no argument. But people's bets will not be 100% random. They will bet your number as well as a pattern of 2's or other single digits. They will bet 1234567. I can't comment whether pi's digits are a common pattern, but the bottom line is to avoid obvious patterns for shared prizes.</p> <p>When numbers run 1-50 or so, the chance of shared prizes increases when all numbers are below 31, as many people bet dates and stick to 1-31. Not every bettor does this of course, but enough so shared prizes show a skew due to this effect. </p> <p>Again - odds are the same, but human nature skews the chance of split payout. I hope this answer is clear. </p>
<p>Your intuition is wrong. Compare the two statements</p> <p>A. The event "the lucky number has all its digits repeated" is much less probable than the event "the lucky number has a few repeated digits"</p> <p>B. The number 1111111 (which has all its repeated digits) is much less probable than the number 8174249 (which has a few repeated digits).</p> <p>A is true, B is false.</p> <p>BTW, this can be related to the "<a href="https://physics.stackexchange.com/questions/66651/clear-up-confusion-about-the-meaning-of-entropy">entropy</a>" concept, and the distinction of microstates-vs-macrostates.</p>
linear-algebra
<p>Wikipedia introduces the vector product for two vectors $\vec a$ and $\vec b$ as $$ \vec a \times\vec b=(\| \vec a\| \|\vec b\|\sin\Theta)\vec n $$ It then mentions that $\vec n$ is the vector normal to the plane made by $\vec a$ and $\vec b$, implying that $\vec a$ and $\vec b$ are 3D vectors. Wikipedia mentions something about a 7D cross product, but I'm not going to pretend I understand that.</p> <p>My idea, which remains unconfirmed with any source, is that a cross product can be thought of a vector which is orthogonal to all vectors which you are crossing. If, and that's a big IF, this is right over all dimensions, we know that for a set of $n-1$ $n$-dimensional vectors, there exists a vector which is orthogonal to all of them. The magnitude would have something to do with the area/volume/hypervolume/etc. made by the vectors we are crossing.</p> <p>Am I right to guess that this multidimensional aspect of cross vectors exists or is that last part utter rubbish?</p>
<p>Yes, you are correct. You can generalize the cross product to $n$ dimensions by saying it is an operation which takes in $n-1$ vectors and produces a vector that is perpendicular to each one. This can be easily defined using the exterior algebra and Hodge star operator <a href="http://en.wikipedia.org/wiki/Hodge_dual">http://en.wikipedia.org/wiki/Hodge_dual</a>: the cross product of $v_1,\ldots,v_{n-1}$ is then just $*(v_1 \wedge v_2 \cdots \wedge v_{n-1}$).</p> <p>Then the magnitude of the cross product of n-1 vectors is the volume of the higher-dimensional parallelogram that they determine. Specifying the magnitude and being orthogonal to each of the vectors narrows the possiblity to two choices-- an orientation picks out one of these.</p>
<p>The answer to this problem is sadly not very well-known, since it depends on what you really want as "cross product".</p> <p>1st solution. r-ary operation in any dimension with certain axiomns. Suppose an r-ary operation on certain d-dimensional space V. Then, a r-fold d-dimensional "cross product" multilinear operation exists: </p> <p><span class="math-container">$$ (C_1\times C_2\times \ldots\times C_r): V^{dr}=\underbrace{V^d\times \cdots \times V^d}_{r}\longrightarrow V^d$$</span></p> <p>such as <span class="math-container">$$\forall i=1,2,...,r$$</span> we have that</p> <p><span class="math-container">$$ (C_1\times C_2\times \ldots\times C_r)\cdot C_i=0$$</span></p> <p><span class="math-container">$$ (C_1\times C_2\times \ldots\times C_r)\cdot (C_1\times C_2\times \ldots\times C_r)=\det (C_i\cdot C_j)$$</span></p> <p>Eckmann (1943) and Whitehead (1963) solved this problem in the continuous case over real euclidean spaces, while Brown and Gray (1967) solved the multilinear case. Moreover, the solution that I am going to provide is valid in any field with characteristic different of 2 and with <span class="math-container">$1\leq r\leq d$</span>. The theorem (due to Eckmann, Whitehead, and Brown-Gray) says that the "generalized cross product" (including the 3d case) exists when:</p> <p>A) <span class="math-container">$d$</span> is even, <span class="math-container">$r = 1$</span>. A cross product exists in every even dimension with one single factor. This can be thought some kind of "Wick rotation" if you are aware of this concept in every even dimensions! This cross product with a single factor is a bit non-trivial but easy to understand. </p> <p>B) <span class="math-container">$d$</span> is arbitrary, <span class="math-container">$r = d − 1$</span>. A cross product exists in arbitrary dimension d and (d-1) factors. It is also said that an arbitrary (d-1)-fold cross product exists in any dimension. Just take the determinant of those (d-1) vectors with the versors <span class="math-container">$(e_1,...,e_r)$</span>!</p> <p>C) <span class="math-container">$d = 3, 7, r = 2$</span>. A 2-fold cross vector exists in dimension 3 and 7. Therefore, the "bilinear" cross product can only exists with two factors in 3D and 7D. The 3D cross product is well known, the 7D cross product can be found (both in coordinate and free coordinate versions) in wikipedia. </p> <p>D) <span class="math-container">$d = 8, r = 3$</span>. A 3-fold cross product exists in eight dimensions. There, there is a non-trivial 3-fold cross in 8D, i.e., you can build a non-trivial cross product with 3 vectors in 8 dimensions. I haven't seen a coordinate expression for this but I believe someone did it (I could write a post about it, though, in my blog, in the near future).</p> <p>This happens in euclidean signature, I suppose there are some variants in pseudo-euclidean metrics (and perhaps some non-trivial subcases; I have heard about a non-trivial 3-fold cross product in 4D but I can not find a reference). Moreover, you can find a similar conclusion in the book Clifford algebras and Spinors by P. Lounesto. Geometric algebra is very useful when handling with this vector stuff since vectors are just a particular grade of a polyvector/cliffor/blade... </p> <p>2nd solution. Cross product can be seen as the dual of the exterior product via <span class="math-container">$ia\times b=a\wedge b$</span> or <span class="math-container">$\star (a\wedge b)=a\times b$</span>. Therefore, the wedge product (exterior product, a bivector) is much more fundamental since it can be defined in ANY spacetime dimension. You can of course identify bivectors with antisymmetric matrices too, but that is only a realization of the bivector. Indeed, bivector defines rotations in a give plane and this is much more useful than thinking in terms of a vector. Bivectors are the generators of rotations in N-dimensional spaces (even if you consider multivectors or polyvectors fields). Thus, the second solution is to consider the exterior product as the true generalization (with two factors!) of the cross product in any spacetime dimension. </p> <p>3rd solution. Use k-forms (k-vectors) and give up the 2-ary condition., assuming a metric can be defined. If you keep wanting a VECTOR, or 1-blade, then using the Hodge star operator: <span class="math-container">$$V=\star(V_1\wedge\cdots \wedge V_{N-1})$$</span> This produces a 1-form (1-vector) from an N-1-form, N-1-vector. Indeed, if you have a non-factorizable nonsimple k-vector on N-dimensional space, the star operator, with a single term!, produces a (N-k)-form or (N-k)-vector in general, as said in the references of other users.</p>
linear-algebra
<p>First of all, I am very comfortable with the tensor product of vector spaces. I am also very familiar with the well-known generalizations, in particular the theory of monoidal categories. I have gained quite some intuition for tensor products and can work with them. Therefore, my question is not about the definition of tensor products, nor is it about its properties. It is rather about the mental images. My intuition for tensor products was never really <strong>geometric</strong>. Well, except for the tensor product of commutative algebras, which corresponds to the fiber product of the corresponding affine schemes. But let's just stick to real vector spaces here, for which I have some geometric intuition, for example from classical analytic geometry. </p> <p>The direct product of two (or more) vector spaces is quite easy to imagine: There are two (or more) "directions" or "dimensions" in which we "insert" the vectors of the individual vector spaces. For example, the direct product of a line with a plane is a three-dimensional space.</p> <p>The exterior algebra of a vector space consists of "blades", as is nicely explained in the <a href="http://en.wikipedia.org/wiki/Exterior_algebra" rel="noreferrer">Wikipedia article</a>.</p> <p>Now what about the tensor product of two finite-dimensional real vector spaces $V,W$? Of course $V \otimes W$ is a direct product of $\dim(V)$ copies of $W$, but this description is not intrinsic, and also it doesn't really incorporate the symmetry $V \otimes W \cong W \otimes V$. How can we describe $V \otimes W$ geometrically in terms of $V$ and $W$? This description should be intrinsic and symmetric.</p> <p>Note that <a href="https://math.stackexchange.com/questions/115630">SE/115630</a> basically asked the same, but received no actual answer. The answer given at <a href="https://math.stackexchange.com/questions/309838">SE/309838</a> discusses where tensor products are used in differential geometry for more abstract notions such as tensor fields and tensor bundles, but this doesn't answer the question either. (Even if my question gets closed as a duplicate, then I hope that the other questions receive more attention and answers.)</p> <p>More generally, I would like to ask for a geometric picture of the tensor product of two vector bundles on nice topological spaces. For example, tensoring with a line bundle is some kind of twisting. But this is still some kind of vague. For example, consider the Möbius strip on the circle $S^1$, and pull it back to the torus $S^1 \times S^1$ along the first projection. Do the same with the second projection, and then tensor both. We get a line bundle on the torus, okay, but how does it look like geometrically?</p> <p>Perhaps the following related question is easier to answer: Assume we have a geometric understanding of two linear maps $f : \mathbb{R}^n \to \mathbb{R}^m$, $g : \mathbb{R}^{n'} \to \mathbb{R}^{m'}$. Then, how can we imagine their tensor product $f \otimes g : \mathbb{R}^n \otimes \mathbb{R}^{n'} \to \mathbb{R}^m \otimes \mathbb{R}^{m'}$ or the corresponding linear map $\mathbb{R}^{n n'} \to \mathbb{R}^{m m'}$ geometrically? This is connected to the question about vector bundles via their cocycle description.</p>
<p>Well, this may not qualify as "geometric intuition for the tensor product", but I can offer some insight into the tensor product of line bundles.</p> <p>A line bundle is a very simple thing -- all that you can "do" with a line is flip it over, which means that in some basic sense, the Möbius strip is the only really nontrivial line bundle. If you want to understand a line bundle, all you need to understand is where the Möbius strips are.</p> <p>More precisely, if $X$ is a line bundle over a base space $B$, and $C$ is a closed curve in $B$, then the preimage of $C$ in $X$ is a line bundle over a circle, and is therefore either a cylinder or a Möbius strip. Thus, a line bundle defines a function $$ \varphi\colon \;\pi_1(B)\; \to \;\{-1,+1\} $$ where $\varphi$ maps a loop to $-1$ if its preimage is a Möbius strip, and maps a loop to $+1$ if its preimage is a cylinder.</p> <p>It's not too hard to see that $\varphi$ is actually a homomorphism, where $\{-1,+1\}$ forms a group under multiplication. This homomorphism completely determines the line bundle, and there are no restrictions on the function $\varphi$ beyond the fact that it must be a homomorphism. This makes it easy to classify line bundles on a given space.</p> <p>Now, if $\varphi$ and $\psi$ are the homomorphisms corresponding to two line bundles, then the tensor product of the bundles corresponds to the <em>algebraic product of $\varphi$ and $\psi$</em>, i.e. the homomorphism $\varphi\psi$ defined by $$ (\varphi\psi)(\alpha) \;=\; \varphi(\alpha)\,\psi(\alpha). $$ Thus, the tensor product of two bundles only "flips" the line along the curve $C$ if exactly one of $\varphi$ and $\psi$ flip the line (since $-1\times+1 = -1$).</p> <p>In the example you give involving the torus, one of the pullbacks flips the line as you go around in the longitudinal direction, and the other flips the line as you around in the meridional direction:</p> <p><img src="https://i.sstatic.net/iEOgb.png" alt="enter image description here"> <img src="https://i.sstatic.net/SKGy1.png" alt="enter image description here"></p> <p>Therefore, the tensor product will flip the line when you go around in <em>either</em> direction:</p> <p><img src="https://i.sstatic.net/tmKVQ.png" alt="enter image description here"></p> <p>So this gives a geometric picture of the tensor product in this case.</p> <p>Incidentally, it turns out that the following things are all really the same:</p> <ol> <li><p>Line bundles over a space $B$</p></li> <li><p>Homomorphisms from $\pi_1(X)$ to $\mathbb{Z}/2$.</p></li> <li><p>Elements of $H^1(B,\mathbb{Z}/2)$.</p></li> </ol> <p>In particular, every line bundle corresponds to an element of $H^1(B,\mathbb{Z}/2)$. This is called the <a href="https://en.wikipedia.org/wiki/Stiefel%E2%80%93Whitney_class" rel="noreferrer">Stiefel-Whitney class</a> for the line bundle, and is a simple example of a <a href="https://en.wikipedia.org/wiki/Characteristic_class" rel="noreferrer">characteristic class</a>.</p> <p><strong>Edit:</strong> As Martin Brandenburg points out, the above classification of line bundles does not work for arbitrary spaces $B$, but does work in the case where $B$ is a CW complex.</p>
<p>Good question. My personal feeling is that we gain true geometric intuition of vector spaces only once norms/inner products/metrics are introduced. Thus, it probably makes sense to consider tensor products in the category of, say, Hilbert spaces (maybe finite-dimensional ones at first). My geometric intuition is still mute at this point, but I know that (for completed tensor products) we have an isometric isomorphism $$ L^2(Z_1) \otimes L^2(Z_2) \cong L^2(Z_1 \times Z_2) $$<br> where $Z_i$'s are measure spaces. In the finite-dimensional setting one, of course, just uses counting measures on finite sets. From this point, one can at least rely upon analytic intuition for the tensor product (Fubini theorem and computation of double integrals as iterated integrals, etc.).</p>
differentiation
<p>My topology book says that "A function $f:U \to \mathbb{R}^m$ from an open set $U$ in $\mathbb{R}^n$ into $\mathbb{R}^m$ is smooth provided that $f$ has continuous partial derivatives of all orders. A function $f:A \to \mathbb{R}^m$ from an arbitrary subset $A$ of $\mathbb{R}^n$ to $\mathbb{R}^m$ is smooth provided that for each $x$ in $A$ there is an open set $U$ containing $x$ and a smooth function $F:U \to \mathbb{R}^m$ such that $F$ agrees with $f$ on $U \cap A$."</p> <p>It really just leaves things at that, assuming knowledge of calculus including partial derivatives (which I do have). What I'm curious about is...</p> <blockquote> <p>Is there a topological notion of the derivative? If there is not, is there a generalization of the derivative designed to allow the notion to make sense in a purely topological context?</p> </blockquote> <p>I have never seen any references to such an idea. There is a topological notion of limit (see <a href="http://en.wikipedia.org/wiki/Limit_of_a_function#Functions_on_topological_spaces">here</a>), but can this be used to define a topological definition of the derivative?</p>
<p>There can be no purely topological definition of deriviative, because neither is the notion of differentiability preserved under homeomorphisms, nor (in cases where it happens to be preserved) does the derivative transform well under homeomorphisms (for instance the derivative could be nonzero before, and zero after application of a homeomorphism). General topology simply does not deal with notions of differentiation; you need a different category than topological spaces for that (for instance that of differentiable manifolds).</p>
<p>I am not sure if you count this as topological $X$ and I must admit that this might be unnecessarily "high-brow" but if your topological space is a locally ringed space (it's not that bad - just think of attaching a ring to every open set in some coherent way and when you "zoom" into a point $x$ you get a local ring $O_{X,x}$ - a ring with only one maximal ideal. Think manifolds or Euclidean space with rings of continuous $\mathbb{R}$-valued functions at each point), then one may define the (co)tangent space at $x$ as the vector space $m_x/m_x^2$ over the base field $O_{X,x}/m_x$ where $m_x$ is the unique maximal ideal of $O_{X,x}$.</p> <p>The motivation of (the purely algebraic process of) quotienting out by the 2nd power of the ideal is exactly capturing the intuition of a derivative - you want to linearize everything in sight. This is what's done in algebraic geometry where the intuitive notion of smoothness is trickier and sometimes absent, but you still want to somehow have them anyway. </p> <p>Hope that was at least fun!</p>
differentiation
<p>I've got a function <span class="math-container">$$g(x,y) = \| f(x,y) \|_2$$</span> and I want to calculate its derivatives with respect to <span class="math-container">$x$</span> and <span class="math-container">$y$</span>.</p> <p>Using Mathematica, differentiating w.r.t. <span class="math-container">$x$</span> gives me <span class="math-container">$ f'_x(x,y) \text{Norm}'( f(x,y))$</span>, where Norm is <span class="math-container">$\| \cdot \|$</span>.</p> <p>I read <a href="http://www.cs.berkeley.edu/%7Ewkahan/MathH110/NORMlite.pdf" rel="noreferrer">here</a> that</p> <p><span class="math-container">$$d\|{\bf x}\| = \frac{ {\bf x}^Td{\bf x}}{\|{\bf x}\|}$$</span></p> <p>at least for the <span class="math-container">$2$</span>-norm. Point is, as inside the norm I have a multivariate function, I'm still confused on how to calculate <span class="math-container">$ f'_x(x,y) \text{Norm}'( f(x,y))$</span></p> <p>I think it should be <span class="math-container">$f'_x(x,y) \frac{f(x,y)}{||f(x,y)||}$</span>, but some verification would be great :)</p>
<p>Suppose $f:\mathbb R^m \to \mathbb R^n$. Decompose into $f = (f_1, \ldots, f_n)$. Each $f_i$ is a real-valued function, <em>i.e.</em>, $f_i: \mathbb R^m \to \mathbb R$. Then $$ g(X) = \|f(X)\|_2 = \sqrt{\sum_{i=1}^n f_i(X)^2}. $$ Therefore, $$\nabla g(X) = \frac 12\left(\sum_{i=1}^n f_i(X)^2\right)^{-\frac 12}\left(\sum_{i=1}^n 2f_i(X)\nabla f_i(X)\right) = \frac{\sum_{i=1}^n f_i(X)\nabla f_i(X)}{\|f(X)\|_2}. $$ This matches your answer.</p> <p>If you want to write in terms of the Jacobian matrix of $f$ instead of components $f_i$, you can: $$ \nabla g(X) = \frac{J_f(X)^T f(X)}{\|f(X)\|_2}. $$</p>
<p>To calculate the derivative of the function <span class="math-container">$ g(x, y) = \|f(x, y)\|^2 $</span> with respect to <span class="math-container">$x$</span>, you can use the chain rule and the derivative of the Euclidean norm <span class="math-container">$\|x\|$</span> as you mentioned. Here's the correct calculation:</p> <p>Given <span class="math-container">$$g(x, y) = \|f(x, y)\|^2,$$</span> let's find <span class="math-container">$\dfrac{{\partial g}}{{\partial x}}$</span>. We have</p> <p><span class="math-container">$$ \begin{align*} g(x, y) &amp;= \|f(x, y)\|^2 \\ &amp;= [f(x, y) \cdot f(x, y)] \\ &amp;= [f(x, y)]^T \cdot f(x, y) \quad \text{ (assuming \(f\) is a column vector)} \\ \end{align*} $$</span> Now, we can differentiate both sides with respect to <span class="math-container">$x$</span>: <span class="math-container">$$ \begin{align*} \frac{{\partial g}}{{\partial x}} &amp;= \frac{{\partial}}{{\partial x}} \left([f(x, y)]^T \cdot f(x, y)\right) \\ &amp;= \left(\frac{{\partial}}{{\partial x}}[f(x, y)]^T\right) \cdot f(x, y) + [f(x, y)]^T \cdot \left(\frac{{\partial}}{{\partial x}} f(x, y)\right) \\ \end{align*} $$</span></p> <p>Now, the first term is the derivative of the transpose of <span class="math-container">$f$</span> which is simply the transpose of the derivative of <span class="math-container">$f$</span> with respect to <span class="math-container">$x$</span>. So, it becomes <span class="math-container">$f_x^\prime(x, y)^T$</span>.</p> <p>The second term <span class="math-container">$$\frac{{\partial}}{{\partial x}} f(x, y)$$</span> is the derivative of <span class="math-container">$f$</span> with respect to <span class="math-container">$x$</span>, therefore the final result for <span class="math-container">$\dfrac{{\partial g}}{{\partial x}}$</span> is:</p> <p><span class="math-container">$$\frac{{\partial g}}{{\partial x}} = f_x'(x, y)^T \cdot f(x, y) + [f(x, y)]^T \cdot f_x(x, y)$$</span></p> <p>This expression accounts for the derivative of the norm as well as the derivative of the function <span class="math-container">$f(x, y)$</span> with respect to <span class="math-container">$x$</span>.</p> <p>The approach to calculate <span class="math-container">$\dfrac{{\partial g}}{{\partial y}}$</span> is similar.</p>
logic
<p>I'm not quite sure that I really understand WHY I need to use <strong>implication</strong> for <strong>universal quantification</strong>, and <strong>conjunction</strong> for <strong>existential quantification</strong>.</p> <p>Let $F$ be the domain of fruits and</p> <p>$$A(x) : \text{is an apple}$$</p> <p>$$D(x) : \text{is delicious}$$</p> <p>Let's say: $$\forall{x} \in F, A(x) \implies D(x)$$ Is <strong>correct</strong> and means <em>all apples are delicous</em>. </p> <p>Whereas, $$\forall{x} \in F, A(x) \land D(x)$$ is <strong>incorrect</strong> because this would be saying that <em>all fruits are apples and delicious</em> which is wrong.</p> <p>But when it comes to the <strong>existential quantifier</strong>: $$\exists{x} \in F, A(x) \land D(x)$$ Is <strong>correct</strong> and means <em>there is some apple that is delicious</em>.</p> <p>Also, $$\exists{x} \in F, A(x) \implies D(x)$$ Is <strong>incorrect</strong>, but I cannot tell why. To me it says <em>there is some fruit that if it is an apple, it is delicious</em>.</p> <p>I cannot tell the difference in this case, and why the second case is incorrect?</p>
<blockquote> <p>To me it says <em>there is some fruit that if it is an apple, it is delicious</em>.</p> </blockquote> <p>This is absolutely correct. There exists a fruit such that <em>if</em> it is an apple, then it is delicious. Let $x$ be such a fruit. We have two cases for what $x$ may be here:</p> <ul> <li>$x$ is an apple. Then $x$ is delicious. This is the $x$ you are searching for.</li> <li>$x$ is not an apple. Now the statement "if $x$ is an apple, then $x$ is delicious" automatically holds true. Since $x$ is not an apple, the conclusion doesn't matter. The statement is vacuously true.</li> </ul> <p>So the statement $\exists{x} \in F, A(x) \implies D(x)$ fails to capture precisely your desired values of $x$, i.e., apples which are delicious, because it also includes other fruits.</p>
<blockquote> <p>I'm not quite sure that I really understand WHY I need to use implication for universal quantification, and conjunction for existential quantification.</p> </blockquote> <p>Modifying your analysis a bit, let $A$ be the set of apples, and $D$ the set of delicious things.</p> <p>$\forall x: [x\in A \implies x\in D]$ means all apples are delicious. Often written $\forall x\in A :x\in D$</p> <p>$\forall x: [x\in A \land x\in D]$ means everything is a delicious apple.</p> <p>$\exists x:[x\in A \land x\in D]$ means there exists at least one delicious apple. Often written $\exists x\in A:x\in D$, or equivalently $\exists x\in D: x\in A$</p> <p>What does $\exists x:[x\in A \implies x\in D]$ mean? It is equivalent to $\exists x:[x\notin A \lor x\in D]$.</p> <p>For a given $x$ then, either of the following possibilities that will satisfy this condition:</p> <ol> <li><p>$x\in A \land x\in D$, i.e. there exists at least one delicious apple (as above) </p></li> <li><p>$x\notin A\land x\in D$, i.e. there exists at least one non-apple that is delicious</p></li> <li><p>$x\notin A\land x\notin D$, i.e. there exists at least one non-apple that is not delicious</p></li> </ol> <p>So, the implication allows for more possibilities than the conjunction. In particular, the implication allows for the possibility that there are no apples. The conjunction does not.</p> <p>Furthermore, $\exists x: [x\in A \implies x\in D]$ is a set theoretic variation of the so-called Drinker's Paradox. Here's where it gets crazy! For <em>any</em> set $A$ and <em>any</em> proposition $P$, we can prove using ordinary set theory that $$\exists x: [x\in A \implies P]$$</p> <p>You could even prove, for example, that $$\exists x: [x\in A \implies x\notin A]$$ So, to avoid confusion, you would probably want to avoid such constructs in mathematics. For a formal development, see <a href="https://dcproof.wordpress.com/" rel="noreferrer">The Drinker's Paradox: A Tale of Three Paradoxes</a> at my blog.</p>
probability
<p>How should I understand the difference or relationship between binomial and Bernoulli distribution?</p>
<p>A Bernoulli random variable has two possible outcomes: $0$ or $1$. A binomial distribution is the sum of <strong>independent</strong> and <strong>identically</strong> distributed Bernoulli random variables.</p> <p>So, for example, say I have a coin, and, when tossed, the probability it lands heads is $p$. So the probability that it lands tails is $1-p$ (there are no other possible outcomes for the coin toss). If the coin lands heads, you win one dollar. If the coin lands tails, you win nothing.</p> <p>For a <em>single</em> coin toss, the probability you win one dollar is $p$. The random variable that represents your winnings after one coin toss is a Bernoulli random variable.</p> <p>Now, if you toss the coin $5$ times, your winnings could be any whole number of dollars from zero dollars to five dollars, inclusive. The probability that you win five dollars is $p^5$, because each coin toss is independent of the others, and for each coin toss the probability of heads is $p$.</p> <p>What is the probability that you win <em>exactly</em> three dollars in five tosses? That would require you to toss the coin five times, getting exactly three heads and two tails. This can be achieved with probability $\binom{5}{3} p^3 (1-p)^2$. And, in general, if there are $n$ Bernoulli trials, then the sum of those trials is binomially distributed with parameters $n$ and $p$.</p> <p>Note that a binomial random variable with parameter $n = 1$ is equivalent to a Bernoulli random variable, i.e. there is only one trial.</p>
<p>All Bernoulli distributions are binomial distributions, but most binomial distributions are not Bernoulli distributions.</p> <p>If $$ X=\begin{cases} 1 &amp; \text{with probability }p, \\ 0 &amp; \text{with probability }1-p, \end{cases} $$ then the probability distribution of the random variable $X$ is a Bernoulli distribution.</p> <p>If $X=X_1+\cdots+X_n$ and each of $X_1,\ldots,X_n$ has a Bernoulli distribution with the same value of $p$ and they are independent, then $X$ has a binomial distribution, and the possible values of $X$ are $\{0,1,2,3,\ldots,n\}$. If $n=1$ then that binomial distribution is a Bernoulli distribution.</p>
logic
<p>In plain language, what's the difference between two things that are 'equivalent', 'equal', 'identical', and isomorphic?</p> <p>If the answer depends on the area of mathematics, then please take the question in the context of logical systems and statements.</p>
<p>Convention may vary, but the following is, I guess, how most mathematicians would use these notions. Identical and equal are very often used synonymously. However, sometimes identical is meant to say that the two things are not just equal, but actually are syntactically equal. For instance, take $x=2$. The claim that $x^2=4$ is saying that $x^2$ and $4$ are equal. The claim that $x^2=x^2$ is saying that $x^2$ is equal to $x^2$, but we also say that the left hand side and the right hand side are identical. </p> <p>Equivalence is a strictly weaker notion than equality. It can be formalized in many different ways. For instance, as an equivalence relation. The identity relation is always an equivalence relation, but not the other way around. A typical way to obtain an equivalence is to suppress some properties of the objects you study, and only look at particular aspects of them. A classical example is modular arithmetic. We say that $10$ and $20$ are equivalent modulo $5$, basically saying that while $10$ and $20$ are not equal, if the only thing we care about is their divisibility by $5$, then they are the same. </p> <p>Isomorphism is a specific term from category theory. Two objects are isomorphic if there exists an invertible morphism between them. Informally, two isomorphic objects are identical for the purposes of answering any question about them in their category. </p>
<p>They have different <a href="http://qchu.wordpress.com/2013/05/28/the-type-system-of-mathematics/">types</a>.</p> <p>"Equal" and "identical" take as input two elements of a <em>set</em> and return a truth value. They both mean the same thing, which is what you think they'd mean. For example, we can consider the set $\{ 1, 2, 3, \dots \}$ of natural numbers, and then $1 = 1$ is true, $1 = 2$ is false, and so forth.</p> <p>"Equivalent" takes as input two elements of a <em>set together with an <a href="http://en.wikipedia.org/wiki/Equivalence_relation">equivalence relation</a></em> and returns a truth value corresponding to the equivalence relation. For example, we can consider the set $\{ 1, 2, 3, \dots \}$ of natural numbers together with the equivalence relation "has the same remainder upon division by $2$," and then $1 \equiv 3$ is true, $1 \equiv 4$ is false, and so forth. The crucial point here is that an equivalence relation is extra structure on a set. It doesn't make sense to ask whether $1$ is equivalent to $3$ without specifying what equivalence relation you're talking about. </p> <p>"Isomorphic" takes as input two objects in a <em><a href="http://en.wikipedia.org/wiki/Category_%28mathematics%29">category</a></em> and returns a truth value corresponding to whether an <a href="http://en.wikipedia.org/wiki/Isomorphism">isomorphism</a> between the two objects exists. For example, we can consider the category of sets and functions, and then the set $\{ 1, 2 \}$ and the set $\{ 3, 4 \}$ are isomorphic because the map $1 \to 3, 2 \to 4$ is an isomorphism between them. The crucial point here is, again, a category structure is extra structure on a set (of objects). It doesn't make sense to ask whether two objects are isomorphic without specifying what category structure you're talking about.</p> <p>Here is a terrible place where this distinction matters. In <a href="http://en.wikipedia.org/wiki/Zermelo%E2%80%93Fraenkel_set_theory">ZF set theory</a>, in addition to being able to ask whether two sets are isomorphic (which means that they are in bijection with each other), it is also a meaningful question to ask whether two sets are <em>equal</em>. The former involves the structure of the category of sets while the latter involves the "set" of sets (not really a set, but that isn't the problem here). For example, $\{ 1, 2 \}$ and $\{ 3, 4 \}$ are particular sets in ZFC which are not the same set (because they don't contain the same elements; that's what it means for two sets in ZFC to be <em>equal</em>) even though they are in bijection with each other. This distinction can trip up the unwary if they aren't careful.</p> <p>(My personal conviction is that you should never be allowed to ask the question of whether two bare sets are equal in the first place. It is basically never the question you actually want to ask.) </p>
linear-algebra
<p>I understand that a vector space is a collection of vectors that can be added and scalar multiplied and satisfies the 8 axioms, however, I do not know what a vector is. </p> <p>I know in physics a vector is a geometric object that has a magnitude and a direction and it computer science a vector is a container that holds elements, expand, or shrink, but in linear algebra the definition of a vector isn't too clear. </p> <p>As a result, what is a vector in Linear Algebra?</p>
<p>In modern mathematics, there's a tendency to define things in terms of <em>what they do</em> rather than in terms of <em>what they are</em>.</p> <p>As an example, suppose that I claim that there are objects called "pizkwats" that obey the following laws:</p> <ul> <li><span class="math-container">$\forall x. \forall y. \exists z. x + y = z$</span></li> <li><span class="math-container">$\exists x. x = 0$</span></li> <li><span class="math-container">$\forall x. x + 0 = 0 + x = x$</span></li> <li><span class="math-container">$\forall x. \forall y. \forall z. (x + y) + z = x + (y + z)$</span></li> <li><span class="math-container">$\forall x. x + x = 0$</span></li> </ul> <p>These rules specify what pizkwats <em>do</em> by saying what rules they obey, but they don't say anything about what pizkwats <em>are</em>. We can find all sorts of things that we could call pizkwats. For example, we could imagine that pizkwats are the numbers 0 and 1, with addition being done modulo 2. They could also be bitstrings of length 137, with "addition" meaning "bitwise XOR." Or they could be sets, with “addition” meaning “symmetric difference.” Each of these groups of objects obey the rules for what pizkwats do, but neither of them "are" pizkwats.</p> <p>The advantage of this approach is that we can prove results about pizkwats knowing purely how they behave rather than what they fundamentally are. For example, as a fun exercise, see if you can use the above rules to prove that</p> <blockquote> <p><span class="math-container">$\forall x. \forall y. x + y = y + x$</span>.</p> </blockquote> <p>This means that anything that "acts like a pizkwat" must support a commutative addition operator. Similarly, we could prove that</p> <blockquote> <p><span class="math-container">$\forall x. \forall y. (x + y = 0 \rightarrow x = y)$</span>.</p> </blockquote> <p>The advantage of setting things up this way is that any time we find something that "looks like a pizkwat" in the sense that it obeys the rules given above, we're guaranteed that it must have some other properties, namely, that it's commutative and that every element has its own and unique inverse. We could develop a whole elaborate theory about how pizkwats behave and what pizkwats do purely based on the rules of how they work, and since we specifically <em>never actually said what a pizkwat is</em>, anything that we find that looks like a pizkwat instantly falls into our theory.</p> <p>In your case, you're asking about what a vector is. In a sense, there is no single thing called "a vector," because a vector is just something that obeys a bunch of rules. But any time you find something that looks like a vector, you immediately get a bunch of interesting facts about it - you can ask questions about spans, about changing basis, etc. - regardless of whether that thing you're looking at is a vector in the classical sense (a list of numbers, or an arrow pointing somewhere) or a vector in a more abstract sense (say, a function acting as a vector in a "vector space" made of functions.)</p> <p>As a concluding remark, Grant Sanderson of 3blue1brown has <a href="https://youtu.be/TgKwz5Ikpc8" rel="noreferrer">an excellent video talking about what vectors are</a> that explores this in more depth.</p>
<p>When I was 14, I was introduced to vectors in a freshman physics course (algebra based). We were told that it was a quantity with magnitude and direction. This is stuff like force, momentum, and electric field.</p> <p>Three years later in precalculus we thought of them as "points," but with arrows emanating from the origin to that point. Just another thing. This was the concept that stuck until I took linear algebra two more years later.</p> <p>But now in the abstract sense, vectors don't have to be these "arrows." They can be anything we want: functions, numbers, matrices, operators, whatever. When we build vector spaces (linear spaces in other texts), we just call the objects vectors - who cares what they look like? It's a name to an abstract object.</p> <p>For example, in $\mathbb{R}^n$ our vectors are ordered n-tuples. In $\mathcal{C}[a,b]$ our vectors are now functions - continuous functions on $[a, b]$ at that. In $L^2(\mathbb{R}$) our vectors are those functions for which</p> <p>$$ \int_{\mathbb{R}} | f |^2 &lt; \infty $$</p> <p>where the integral is taken in the Lebesgue sense.</p> <p>Vectors are whatever we take them to be in the appropriate context.</p>
differentiation
<p>The nuclear norm is defined in the following way</p> <p>$$\|X\|_*=\mathrm{tr} \left(\sqrt{X^T X} \right)$$</p> <p>I'm trying to take the derivative of the nuclear norm with respect to its argument</p> <p>$$\frac{\partial \|X\|_*}{\partial X}$$</p> <p>Note that $\|X\|_*$ is a norm and is convex. I'm using this for some coordinate descent optimization algorithm. Thank you for your help.</p>
<p>As I said in my comment, in a convex optimization setting, one would normally <em>not</em> use the derivative/subgradient of the nuclear norm function. It is, after all, nondifferentiable, and as such cannot be used in standard descent approaches (though I suspect some people have probably applied semismooth methods to it). </p> <p>Here are two alternate approaches for "handling" the nuclear norm.</p> <p><em>Semidefinite programming</em>. We can use the following identity: the nuclear norm inequality $\|X\|_*\leq y$ is satisfied if and only if there exist symmetric matrices $W_1$, $W_2$ satisfying $$\begin{bmatrix} W_1 &amp; X \\ X^T &amp; W_2 \end{bmatrix} \succeq 0, ~ \mathop{\textrm{Tr}}W_1 + \mathop{\textrm{Tr}}W_2 \leq 2 y$$ Here, $\succeq 0$ should be interpreted to mean that the $2\times 2$ block matrix is positive semidefinite. Because of this transformation, you can handle nuclear norm minimization or upper bounds on the nuclear norm in any semidefinite programming setting. For instance, given some equality constraints $\mathcal{A}(X)=b$ where $\mathcal{A}$ is a linear operator, you could do this: $$\begin{array}{ll} \text{minimize} &amp; \|X\|_* \\ \text{subject to} &amp; \mathcal{A}(X)=b \end{array} \quad\Longleftrightarrow\quad \begin{array}{ll} \text{minimize} &amp; \tfrac{1}{2}\left( \mathop{\textrm{Tr}}W_1 + \mathop{\textrm{Tr}}W_2 \right) \\ \text{subject to} &amp; \begin{bmatrix} W_1 &amp; X \\ X^T &amp; W_2 \end{bmatrix} \succeq 0 \\ &amp; \mathcal{A}(X)=b \end{array} $$ My software <a href="http://cvxr.com/cvx">CVX</a> uses this transformation to implement the function <code>norm_nuc</code>, but any semidefinite programming software can handle this. One downside to this method is that semidefinite programming can be expensive; and if $m\ll n$ or $n\ll m$, that expense is exacerbated, since size of the linear matrix inequality is $(m+n)\times (m+n)$.</p> <p><em>Projected/proximal gradients</em>. Consider the following related problems: $$\begin{array}{ll} \text{minimize} &amp; \|\mathcal{A}(X)-b\|_2^2 \\ \text{subject to} &amp; \|X\|_*\leq \delta \end{array} \quad $$ $$\text{minimize} ~~ \|\mathcal{A}(X)-b\|_2^2+\lambda\|X\|_*$$ Both of these problems trace out <em>tradeoff curves</em>: as $\delta$ or $\lambda$ is varied, you generate a tradeoff between $\|\mathcal{A}(X)-b\|$ and $\|X\|_*$. In a very real sense, these problems are <em>equivalent</em>: for a fixed value of $\delta$, there is going to be a corresponding value of $\lambda$ that yields the <em>exact</em> same value of $X$ (at least on the interior of the tradeoff curve). So it is worth considering these problems together.</p> <p>The first of these problems can be solved using a <em>projected gradient</em> approach. This approach alternates between gradient steps on the smooth objective and <em>projections</em> back onto the feasible set $\|X\|_*\leq \delta$. The projection step requires being able to compute $$\mathop{\textrm{Proj}}(Y) = \mathop{\textrm{arg min}}_{\{X\,|\,\|X\|_*\leq\delta\}} \| X - Y \|$$ which can be done at about the cost of a single SVD plus some $O(n)$ operations.</p> <p>The second model can be solved using a <em>proximal gradient</em> approach, which is very closely related to projected gradients. In this case, you alternate between taking gradient steps on the smooth portion, followed by an evaluation of the <em>proximal function</em> $$\mathop{\textrm{Prox}}(Y) = \mathop{\textrm{arg min}}_X \|X\|_* + \tfrac{1}{2}t^{-1}\|X-Y\|^2$$ where $t$ is a step size. This function can also be computed with a single SVD and some thresholding. It's actually easier to implement than the projection. For that reason, the proximal model is preferable to the projection model. When you have the choice, solve the easier model!</p> <p>I would encourage you to do a literature search on proximal gradient methods, and nuclear norm problems in particular. There is actually quite a bit of work out there on this. For example, <a href="http://www.eecs.berkeley.edu/~elghaoui/Teaching/EE227A/lecture18.pdf">these lecture notes</a> by Laurent El Ghaoui at Berkeley talk about the proximal gradient method and introduce the prox function for nuclear norms. My software <a href="http://cvxr.com/tfocs/">TFOCS</a> includes both the nuclear norm projection and the prox function. You do not have to use this software, but you could look at the implementations of <code>prox_nuclear</code> and <code>proj_nuclear</code> for some hints.</p>
<p>Start with the SVD decomposition of <span class="math-container">$x$</span>:</p> <p><span class="math-container">$$x=U\Sigma V^T$$</span></p> <p>Then <span class="math-container">$$\|x\|_*=tr(\sqrt{x^Tx})=tr(\sqrt{(U\Sigma V^T)^T(U\Sigma V^T)})$$</span></p> <p><span class="math-container">$$\Rightarrow \|x\|_*=tr(\sqrt{V\Sigma U^T U\Sigma V^T})=tr(\sqrt{V\Sigma^2V^T})$$</span></p> <p>By circularity of trace:</p> <p><span class="math-container">$$\Rightarrow \|x\|_*=tr(\sqrt{V^TV\Sigma^2})=tr(\sqrt{V^TV\Sigma^2})=tr(\sqrt{\Sigma^2})=tr(\Sigma)$$</span></p> <p>Since the elements of <span class="math-container">$\Sigma$</span> are non-negative.</p> <p>Therefore nuclear norm can be also defined as the sum of the absolute values of the singular value decomposition of the input matrix.</p> <p>Now, note that the absolute value function is not differentiable on every point in its domain, but you can find a subgradient.</p> <p><span class="math-container">$$\frac{\partial \|x\|_*}{\partial x}=\frac{\partial tr(\Sigma)}{\partial x}=\frac{ tr(\partial\Sigma)}{\partial x}$$</span></p> <p>You should find <span class="math-container">$\partial\Sigma$</span>. Since <span class="math-container">$\Sigma$</span> is diagonal, the subdifferential set of <span class="math-container">$\Sigma$</span> is: <span class="math-container">$\partial\Sigma=\Sigma\Sigma^{-1}\partial\Sigma$</span>, now we have:</p> <p><span class="math-container">$$\frac{\partial \|x\|_*}{\partial x}=\frac{ tr(\Sigma\Sigma^{-1}\partial\Sigma)}{\partial x}$$</span> (I)</p> <p>So we should find <span class="math-container">$\partial\Sigma$</span>.</p> <p><span class="math-container">$x=U\Sigma V^T$</span>, therefore: <span class="math-container">$$\partial x=\partial U\Sigma V^T+U\partial\Sigma V^T+U\Sigma\partial V^T$$</span></p> <p>Therefore: </p> <p><span class="math-container">$$U\partial\Sigma V^T=\partial x-\partial U\Sigma V^T-U\Sigma\partial V^T$$</span></p> <p><span class="math-container">$$\Rightarrow U^TU\partial\Sigma V^TV=U^T\partial xV-U^T\partial U\Sigma V^TV-U^TU\Sigma\partial V^TV$$</span></p> <p><span class="math-container">$$\Rightarrow \partial\Sigma =U^T\partial xV-U^T\partial U\Sigma - \Sigma\partial V^TV$$</span></p> <p><span class="math-container">\begin{align} \Rightarrow\\ tr(\partial\Sigma) &amp;=&amp; tr(U^T\partial xV-U^T\partial U\Sigma - \Sigma\partial V^TV)\\ &amp;=&amp; tr(U^T\partial xV)+tr(-U^T\partial U\Sigma - \Sigma\partial V^TV) \end{align}</span></p> <p>You can show that <span class="math-container">$tr(-U^T\partial U\Sigma - \Sigma\partial V^TV)=0$</span> (Hint: diagonal and antisymmetric matrices, proof in the comments.), therefore:</p> <p><span class="math-container">$$tr(\partial\Sigma) = tr(U^T\partial xV)$$</span></p> <p>By substitution into (I):</p> <p><span class="math-container">$$\frac{\partial \|x\|_*}{\partial x}= \frac{ tr(\partial\Sigma)}{\partial x} =\frac{ tr(U^T\partial xV)}{\partial x}=\frac{ tr(VU^T\partial x)}{\partial x}=(VU^T)^T$$</span></p> <p>Therefore you can use <span class="math-container">$U V^T$</span> as the subgradient.</p>
combinatorics
<p><a href="http://en.wikipedia.org/wiki/Tetration">Tetration</a> is a generalization of exponentiation in arithmetic and a part of a series of other generalized notions, <em><a href="http://en.wikipedia.org/wiki/Hyperoperation">Hyperoperators</a></em>. Consider $m\uparrow n$ denotes the tetration of $m$ and $n$. i.e. $$\underbrace{m^{m^{m^{.^{.^{.^{m}}}}}}}_{n-times}$$</p> <p>Note that one can find a combinatorial description of each one of operators <em>sum</em>, <em>multiplication</em> and <em>exponentiation</em> as follows:</p> <ul> <li><p>$m+n$ is the size of <em>disjoint union of two sets with $m$ and $n$ elements</em>. </p></li> <li><p>$m.n$ is the size of <em>Cartesian product of two sets with $m$ and $n$ elements</em>.</p></li> <li><p>$m^n$ is the size of <em>set of all functions from a set with $n$ elements to a set with $m$ elements.</em></p></li> <li><p>$m\uparrow n$ is the size of ... (?)</p></li> </ul> <blockquote> <p><strong>Question:</strong> Is it possible to introduce a combinatorial set (defined by $m$, $n$) which its size is $m\uparrow n$ as well as the case of $m+n$, $m.n$, $m^n$? What about other Hyperoperators like pentation and hexation? The simple and most natural expressions are more interesting.</p> </blockquote>
<p>This is probably not what you want. but we can create the notion of the $n$'th dual of a set (I'm borrowing this notation from linear algebra).</p> <p>Given sets $X$ and $Y$ consider the dual of $X$ with respect to $Y$ to be the the functions from $X$ to $Y$. </p> <p>Define recursively the $n$'th dual of a set $X$ to be the dual of $X$ with respect to $X$ for $n=1$ and the dual of the $n-1$'th dual of $X$ with respect to $X$ for $n&gt;1$. Then $m\uparrow n$ is the order of the $n$'th dual of a set of $m$ elements.</p>
<p><span class="math-container">$2 \uparrow \uparrow (n-1)$</span> is the number of sets of <a href="https://en.wikipedia.org/wiki/Von_Neumann_universe" rel="noreferrer">rank</a> <span class="math-container">$n$</span>. Intuitively, the rank of a set is the depth of the nesting braces needed to write it. Recursively, the rank of the empty set is zero, and the rank of a nonempty set is the one plus the maximum rank of its elements. It is also the depth of the stack needed by a pushdown automaton to recognize the braces are balanced. In short, <span class="math-container">$2 \uparrow \uparrow (n-1) = |V_n|$</span> where</p> <p><span class="math-container">$$V_\alpha = \bigcup_{\beta &lt; \alpha} \mathcal{P}(V_\beta)$$</span></p>
combinatorics
<p>The question is how many triangles are there in the following picture?</p> <p><img src="https://i.sstatic.net/pv66U.jpg" alt="How many triangles?"></p> <p>I have thought to solve it by creating a formula based on the angles of the lines starting from the bottom of each side. I don't get it right though. Any clues/ideas would be appreciated.</p>
<p><strong>@Sp3000</strong> is right, this is actually <a href="http://projecteuler.net/problem=163">$PE-163$</a>, and your particular case is given in the problem statement $ T(2) = 104.$</p> <p>But if you are looking for a general formula to count the number of triangles in higher order then <a href="http://www.mathematik.uni-bielefeld.de/~sillke/SEQUENCES/grid-triangles">check here</a>, (spoiler for the original PE problem).</p>
<p>You can model this using the graph theory. Then make an algorithm that will solve the problem.</p> <p>Every line that ends connecting more than one line is a node. Find all nodes. Then start from one and look for graphs that contain 3 elements.</p>
logic
<p>I am struggling to understand this. According to truth tables, if $P$ is false, it doesn't matter whether $Q$ is true or not: Either way, $P \implies Q$ is true.</p> <p>Usually when I see examples of this people make up some crazy premise for $P$ as a way of showing that $Q$ can be true or false when $P$ is something outrageous and obviously untrue, such as "If the moon is made of bacon-wrapped apple-monkey carburetors, then I am a better wakeborder than Gauss."</p> <p>$P$ is clearly false, but $P \implies Q$ is true no matter what the state of $Q$ is, and I don't understand why.</p> <p>Are we saying "If $P$ is false, then all bets are off and $Q$ can be anything, either true or false, and not contradict our earlier claim, and if it isn't false, it must be true"?</p> <p>Otherwise why can't we say that if $P$ is false, then we can't make any claims one way or the other on whether or not it implies anything at all? </p>
<p>Consider the statement:</p> <blockquote> <p>All multiples of 4 are even.</p> </blockquote> <p>You would say that statement is true, right?</p> <p>So let's formulate that in formal logic language:</p> <blockquote> <p>$\forall x: 4|x \implies 2|x$</p> </blockquote> <p>(Here "$a|b$" means "$a$ divides $b$", that is, $b$ is a multiple of $a$.)</p> <p>Now a $\forall$ statement is true if it is true whatever you insert for the quantified variable (after all,that's "for all" means). So let's try to insert $3$:</p> <blockquote> <p>$4|3 \implies 2|3$</p> </blockquote> <p>But wait, $4|3$ is false! Moreover, $2|3$ is also false. So the only way for the original statement to be true is that the implication $\text{false}\implies\text{false}$ gives true.</p> <p>A similar argument can be done for $\text{false}\implies\text{true}$.</p>
<p>This is done so that classical propositional calculus follows some natural rules. Let's try to motivate this, without getting into technical details:</p> <p>The expression "$P\Rightarrow Q$" should be read "$P$ implies $Q$", or "whenever $P$ is true, $Q$ is also true".</p> <p>The negation of such an expression would be a counter-example, i.e., "there is some case in which $P$ is true but $Q$ is not".</p> <p>So assume $P$ is not true. The negation "$\lnot(P\Rightarrow Q)$" is not true in this case, by our interpretation above, so "$P\Rightarrow Q$" must be true.</p> <p>We are basically using the rules that either an expression or its negation should be true, and that the negation of the negation of an statement is the statement itself. These are basic rules which are natural and useful, even though as a consequence we have that "$P\Rightarrow Q$" is true whenever $P$ is false.</p>
number-theory
<p>I have heard <a href="https://en.wikipedia.org/wiki/Golden_ratio" rel="noreferrer">$\varphi$</a> called the most irrational number. Numbers are either irrational or not though, one cannot be more "irrational" in the sense of a number that can not be represented as a ratio of integers. What is meant by most irrational? Define what we mean by saying one number is more irrational than another, and then prove that there is no $x$ such that $x$ is more irrational than $\varphi$.</p> <p>Note: I have heard about defining irrationality by how well the number can be approximated by rational ones, but that would need to formalized.</p>
<p>How well can a number <span class="math-container">$\alpha$</span> be approximated by rationals? Trivially, we can find infinitely many <span class="math-container">$\frac pq$</span> with <span class="math-container">$|\alpha -\frac pq|&lt;\frac 1q$</span>, so something better is needed to talk about a good approximation. For example, if <span class="math-container">$d&gt;1$</span>, <span class="math-container">$c&gt;0$</span> and there are infinitely many <span class="math-container">$\frac pq$</span> with <span class="math-container">$|\alpha-\frac pq|&lt;\frac c{q^d}$</span>, then we can say that <span class="math-container">$\alpha$</span> can be approximated better than another number if it allows a higher <span class="math-container">$d$</span> than that other number. Or for equal values of <span class="math-container">$d$</span>, if it allows a smaller <span class="math-container">$c$</span>.</p> <p>Intriguingly, numbers that can be approximated exceptionally <em>well</em> by rationals are transcendental (and at the other end of the spectrum, rationals can be approximated exceptionally <em>poorly</em> - if one ignores the exact approximation by the number itself). On the other hand, for every irrational <span class="math-container">$\alpha$</span>, there exists <span class="math-container">$c&gt;0$</span> so that for infinitely many rationals <span class="math-container">$\frac pq$</span> we have <span class="math-container">$|\alpha-\frac pq|&lt;\frac c{q^2}$</span>. The infimum of allowed <span class="math-container">$c$</span> may differ among irrationals and it turns out that it depends on the continued fraction expansion of <span class="math-container">$\alpha$</span>. Especially, terms <span class="math-container">$\ge 2$</span> in the continued fraction correspond to better approximations than those for terms <span class="math-container">$=1$</span>. Therefore, any number with infinitely many terms <span class="math-container">$\ge 2$</span> allows a smaller <span class="math-container">$c$</span> than a number with only finitely many terms <span class="math-container">$\ge2$</span> in the continued fraction. But if all but finitely many of the terms are <span class="math-container">$1$</span>, then <span class="math-container">$\alpha$</span> is simply a rational transform of <span class="math-container">$\phi$</span>, i.e. <span class="math-container">$\alpha=a+b\phi$</span> with <span class="math-container">$a\in\mathbb Q, b\in\mathbb Q^\times$</span>.</p>
<p>The measure is indeed what you think. The simple continued fraction has "digits" which are all 1's. See, for example, Khinchin's little book on continued fractions.</p> <p>Simple version, the convergent just before a large "digit" is a very good approximation, the relevant error being less than $$ \frac{1}{q_n q_{n+1}} $$ where the $q$'s are the denominators. So, with a big digit, $q_n$ is of modest size but $q_{n+1}$ is quite large, so the error with denominator $q_n$ is small compared with $1/q_n^2.$ </p>
differentiation
<p>I think $\frac{d}{dx} \int f(x) dx = f(x)$ right? So $\frac{d}{dx} \int^b_a f(x) dx = [f(x)]^b_a = f(a)-f(b)$? But why when: </p> <p>$$f(x) = \int^{x^3}_{x^2} \sqrt{7+2e^{3t-3}}$$</p> <p>then </p> <p>$$f'(x) = \color{red}{(x^3)'}\sqrt{7+2e^{3x-3}} - \color{red}{(x^2)'}\sqrt{7+2e^{3x-3}}$$</p> <p>Where did the $(x^3)'$ and $(x^2)'$ come from? </p>
<p>$\int_a^bf(x)\,dx$ is a number, so ${d\over dx}\int_a^bf(x)\,dx=0$. </p> <p>Now suppose $\int g(x)\,dx=F(x)$. Then $\int_{x^2}^{x^3}g(t)\,dt=F(x^3)-F(x^2)$, so ${d\over dx}\int_{x^2}^{x^3}g(t)\,dt=(x^3)'F'(x^3)-(x^2)'F'(x^2)=3x^2g(x^3)-2xg(x^2)$.</p>
<p>For a definite integral with a variable upper limit of integration $\int_a^xf(t)\,dt$, you have ${d\over dx} \int_a^xf(t)\,dt=f(x)$.</p> <p>For an integral of the form $$\tag{1}\int_a^{g(x)} f(t)\,dt,$$ you would find the derivative using the chain rule. </p> <p>As stated above, the basic differentiation rule for integrals is: </p> <p>$\ \ \ \ \ \ $for $F(x)=\int_a^x f (t)\,dt$, we have $F'(x)=f(x)$. </p> <p>The chain rule tells us how to differentiate $(1)$. Here if we set $F(x)=\int_a^x f(t)\,dt$, then the derivative sought is $${d\over dx} \int_a^{g(x)} f(t)\,dt =[F(g(x))]' =F' (g(x)) g'(x) =f(g(x))\cdot g'(x).$$</p> <p>So for example, given $$ {d\over dx} \int_0^{x^3} \sqrt{7+2e^{3t-3}}\, dt, $$ we have $F(x)=\int_0^x \sqrt {7+2e^{3t-3}}\,dt$, and we want to find the derivative of $F(x^3)$. Using the chain rule $$ {d\over dx} \int_0^{x^3}\underbrace{ \sqrt{7+2e^{3t-3}}}_{f(t)}\, dt = [F(x^3)]'=f(x^3)\cdot(x^3)'=\sqrt{7+3{e^{3x^3-3} }}\cdot 3x^2. $$ Note you have a mistake in the exponents in your solution.</p> <p>If both the upper and lower limits of integration are variables, you'd do as you suggest. For example, you'd write $$\eqalign{ \int_{x^2}^{x^3}f(t)\,dt&amp;= \int_{x^2}^0f(t)\,dt+ \int_0^{x^3}f(t)\,dt\cr &amp;= -\int_{0}^{x^2}f(t)\,dt+ \int_0^{x^3}f(t)\,dt} $$ The derivative will then be, applying the chain rule to both integrals above $-f(x^2)\cdot2x+f(x^3)\cdot (3x^2)$.</p>
combinatorics
<p>What are the number of onto functions from a set <span class="math-container">$\Bbb A $</span> containing <code>m</code> elements to a set <span class="math-container">$\Bbb B$</span> containing <code>n</code> elements.</p> <p>I found that if <span class="math-container">$m = 4$</span> and <span class="math-container">$n = 2$</span> the number of onto functions is <span class="math-container">$14$</span>.</p> <p>But is there a way to generalise this using a formula? If yes, what is this formula and how is it derived?</p> <p><strong>reference</strong></p> <p>I referred to this question but my doubt was not cleared: <a href="https://math.stackexchange.com/questions/333497/how-many-one-to-one-and-onto-function">How many one to one and onto functions are there between two finite sets?</a></p> <p>If not, Then what is the standard way of doing it?</p> <p>If you explain this to me with an example please explain with the example of <span class="math-container">$m = 5$</span> and <span class="math-container">$n = 3$</span>.</p>
<p>Obviously if $m&lt;n$, there are no function from $\Bbb A$ onto $\Bbb B$, so assume that $m\ge n$. We’ll use an <a href="http://en.wikipedia.org/wiki/Inclusion%E2%80%93exclusion_principle" rel="noreferrer">inclusion-exclusion</a> argument. There are $n^m$ functions of all kinds from $\Bbb A$ to $\Bbb B$. If $b\in\Bbb B$, there are $(n-1)^m$ functions from $\Bbb A$ to $\Bbb B\setminus\{b\}$, i.e., functions whose ranges do not include $b$. We need to subtract these from the original $n^m$, and we need to do it for each of the $n$ members of $\Bbb B$, so a better approximation is $n^m-n(n-1)^m$.</p> <p>Unfortunately, a function whose range misses <strong>two</strong> members of $\Bbb B$ gets subtracted twice in that computation, and it should be subtracted only once. Thus, we have to add back in the functions whose ranges miss at least two points of $\Bbb B$. If $b_0,b_1\in\Bbb B$, there are $(n-2)^m$ functions from $\Bbb A$ to $\Bbb B\setminus\{b_0,b_1\}$, and there are $\binom{n}{2}$ pairs of points of $\Bbb B$, so we have to add back in $\binom{n}2(n-2)^m$ to get</p> <p>$$n^m-n(n-1)^m+\binom{n}2(n-2)^m\;,$$</p> <p>which can be expressed more systematically as</p> <p>$$\binom{n}0n^m-\binom{n}1(n-1)^m+\binom{n}2(n-2)^m\;.$$</p> <p>Unfortunately, this over-corrects in the other direction, by adding back in too much. The final result, when the entire inclusion-exclusion computation is made, is</p> <p>$$\sum_{k=0}^n(-1)^k\binom{n}k(n-k)^m\;,$$</p> <p>which can also be written $$n!{m\brace n}\;,$$ where ${m\brace n}$ is a <a href="http://en.wikipedia.org/wiki/Stirling_numbers_of_the_second_kind" rel="noreferrer">Stirling number of the second kind</a>. The Stirling number gives the number of ways of dividing up $\Bbb A$ into $n$ non-empty pieces, and the $n!$ then gives the number of ways of assigning those pieces to the $n$ elements of $\Bbb B$.</p>
<p>The answer is a little complicated. It is $n!S(m,n)$, where $S(m,n)$ is the appropriate <a href="http://en.wikipedia.org/wiki/Stirling_number_of_the_second_kind" rel="noreferrer">Stirling Number of the second kind.</a></p> <p>There are nice recursions for the $S(m,n)$, but no simple closed-form formula. </p>
matrices
<p>Can <span class="math-container">$\det(A + B)$</span> expressed in terms of <span class="math-container">$\det(A), \det(B), n$</span> where <span class="math-container">$A,B$</span> are <span class="math-container">$n\times n$</span> matrices?</p> <h3></h3> <p>I made the edit to allow <span class="math-container">$n$</span> to be factored in.</p>
<p>When <span class="math-container">$n=2$</span>, and suppose <span class="math-container">$A$</span> has inverse, you can easily show that</p> <p><span class="math-container">$\det(A+B)=\det A+\det B+\det A\,\cdot \mathrm{Tr}(A^{-1}B)$</span>.</p> <hr /> <p>Let me give a general method to find the determinant of the sum of two matrices <span class="math-container">$A,B$</span> with <span class="math-container">$A$</span> invertible and symmetric (The following result might also apply to the non-symmetric case. I might verify that later...). I am a physicist, so I will use the index notation, <span class="math-container">$A_{ij}$</span> and <span class="math-container">$B_{ij}$</span>, with <span class="math-container">$i,j=1,2,\cdots,n$</span>. Let <span class="math-container">$A^{ij}$</span> donate the inverse of <span class="math-container">$A_{ij}$</span> such that <span class="math-container">$A^{il}A_{lj}=\delta^i_j=A_{jl}A^{li}$</span>. We can use <span class="math-container">$A_{ij}$</span> to lower the indices, and its inverse to raise. For example <span class="math-container">$A^{il}B_{lj}=B^i{}_j$</span>. Here and in the following, the Einstein summation rule is assumed.</p> <p>Let <span class="math-container">$\epsilon^{i_1\cdots i_n}$</span> be the totally antisymmetric tensor, with <span class="math-container">$\epsilon^{1\cdots n}=1$</span>. Define a new tensor <span class="math-container">$\tilde\epsilon^{i_1\cdots i_n}=\epsilon^{i_1\cdots i_n}/\sqrt{|\det A|}$</span>. We can use <span class="math-container">$A_{ij}$</span> to lower the indices of <span class="math-container">$\tilde\epsilon^{i_1\cdots i_n}$</span>, and define <span class="math-container">$\tilde\epsilon_{i_1\cdots i_n}=A_{i_1j_1}\cdots A_{i_nj_n}\tilde\epsilon^{j_1\cdots j_n}$</span>. Then there is a useful property: <span class="math-container">$$ \tilde\epsilon_{i_1\cdots i_kl_{k+1}\cdots l_n}\tilde\epsilon^{j_1\cdots j_kl_{k+1}\cdots l_n}=(-1)^sl!(n-l)!\delta^{[j_1}_{i_1}\cdots\delta^{j_k]}_{i_k}, $$</span> where the square brackets <span class="math-container">$[]$</span> imply the antisymmetrization of the indices enclosed by them. <span class="math-container">$s$</span> is the number of negative elements of <span class="math-container">$A_{ij}$</span> after it has been diagonalized.</p> <p>So now the determinant of <span class="math-container">$A+B$</span> can be obtained in the following way <span class="math-container">$$ \det(A+B)=\frac{1}{n!}\epsilon^{i_1\cdots i_n}\epsilon^{j_1\cdots j_n}(A+B)_{i_1j_1}\cdots(A+B)_{i_nj_n} $$</span> <span class="math-container">$$ =\frac{(-1)^s\det A}{n!}\tilde\epsilon^{i_1\cdots i_n}\tilde\epsilon^{j_1\cdots j_n}\sum_{k=0}^n C_n^kA_{i_1j_1}\cdots A_{i_kj_k}B_{i_{k+1}j_{k+1}}\cdots B_{i_nj_n} $$</span> <span class="math-container">$$ =\frac{(-1)^s\det A}{n!}\sum_{k=0}^nC_n^k\tilde\epsilon^{i_1\cdots i_ki_{k+1}\cdots i_n}\tilde\epsilon^{j_1\cdots j_k}{}_{i_{k+1}\cdots i_n}B_{i_{k+1}j_{k+1}}\cdots B_{i_nj_n} $$</span> <span class="math-container">$$ =\frac{(-1)^s\det A}{n!}\sum_{k=0}^nC_n^k\tilde\epsilon^{i_1\cdots i_ki_{k+1}\cdots i_n}\tilde\epsilon_{j_1\cdots j_ki_{k+1}\cdots i_n}B_{i_{k+1}}{}^{j_{k+1}}\cdots B_{i_n}{}^{j_n} $$</span> <span class="math-container">$$ =\frac{\det A}{n!}\sum_{k=0}^nC_n^kk!(n-k)!B_{i_{k+1}}{}^{[i_{k+1}}\cdots B_{i_n}{}^{i_n]} $$</span> <span class="math-container">$$ =\det A\sum_{k=0}^nB_{i_{k+1}}{}^{[i_{k+1}}\cdots B_{i_n}{}^{i_n]} $$</span> <span class="math-container">$$ =\det A+\det A\sum_{k=1}^{n-1}B_{i_{k+1}}{}^{[i_{k+1}}\cdots B_{i_n}{}^{i_n]}+\det B. $$</span></p> <p>This reproduces the result for <span class="math-container">$n=2$</span>. An interesting result for physicists is when <span class="math-container">$n=4$</span>,</p> <p><span class="math-container">\begin{split} \det(A+B)=&amp;\det A+\det A\cdot\text{Tr}(A^{-1}B)+\frac{\det A}{2}\{[\text{Tr}(A^{-1}B)]^2-\text{Tr}(BA^{-1}BA^{-1})\}\\ &amp;+\frac{\det A}{6}\{[\text{Tr}(BA^{-1})]^3-3\text{Tr}(BA^{-1})\text{Tr}(BA^{-1}BA^{-1})+2\text{Tr}(BA^{-1}BA^{-1}BA^{-1})\}\\ &amp;+\det B. \end{split}</span></p>
<p>When $n\ge2$, the answer is no. To illustrate, consider $$ A=I_n,\quad B_1=\pmatrix{1&amp;1\\ 0&amp;0}\oplus0,\quad B_2=\pmatrix{1&amp;1\\ 1&amp;1}\oplus0. $$ If $\det(A+B)=f\left(\det(A),\det(B),n\right)$ for some function $f$, you should get $\det(A+B_1)=f(1,0,n)=\det(A+B_2)$. But in fact, $\det(A+B_1)=2\ne3=\det(A+B_2)$ over any field.</p>
linear-algebra
<p>The following is a well-known result in functional analysis:</p> <blockquote> <p>If the vector space $X$ is finite dimensional, all norms are equivalent. </p> </blockquote> <p>Here is the standard proof in one textbook. First, pick a norm for $X$, say $$\|x\|_1=\sum_{i=1}^n|\alpha_i|$$ where $x=\sum_{i=1}^n\alpha_ix_i$, and $(x_i)_{i=1}^n$ is a basis for $X$. Then show that every norm for $X$ is equivalent to $\|\cdot\|_1$, i.e., $$c\|x\|\leq\|x\|_1\leq C\|x\|.$$ For the first inequality, one can easily get $c$ by triangle inequality for the norm. For the second inequality, instead of constructing $C$, the <a href="http://en.wikipedia.org/wiki/Bolzano%E2%80%93Weierstrass_theorem" rel="noreferrer">Bolzano-Weierstrass theorem</a> is applied to construct a contradiction. </p> <p>The strategies for proving these two inequalities are so different. Here is my <strong>question</strong>, </p> <blockquote> <p>Can one prove this theorem without Bolzano-Weierstrass theorem?</p> </blockquote> <p><strong>UPDATE:</strong></p> <blockquote> <p>Is the converse of the theorem true? In other words, if all norms for a vector space $X$ are equivalent, then can one conclude that $X$ is of finite dimension?</p> </blockquote>
<p>To answer the question in the update:</p> <p>If $(X,\|\cdot\|)$ is a normed space of infinite dimension, we can produce a non-continuous linear functional: Choose an algebraic basis $\{e_{i}\}_{i \in I}$ which we may assume to be normalized, i.e., $\|e_{i}\| = 1$ for all $i$. Every vector $x \in X$ has a unique representation $x = \sum_{i \in I} x_i \, e_i$ with only finitely many nonzero entries (by definition of a basis).</p> <p>Now choose a countable subset $i_1,i_2, \ldots$ of $I$. Then $\phi(x) = \sum_{k=1}^{\infty} k \cdot x_{i_k}$ defines a linear functional on $x$. Note that $\phi$ is not continuous, as $\frac{1}{\sqrt{k}} e_{i_k} \to 0$ while $\phi(\frac{1}{\sqrt{k}}e_{i_k}) = \sqrt{k} \to \infty$.</p> <p>There can't be a $C \gt 0$ such that the norm $\|x\|_{\phi} = \|x\| + |\phi(x)|$ satisfies $\|x\|_\phi \leq C \|x\|$ since otherwise $\|\frac{1}{\sqrt{k}}e_k\| \to 0$ would imply $|\phi(\frac{1}{\sqrt{k}}e_k)| \to 0$ contrary to the previous paragraph.</p> <p>This shows that on an infinite-dimensional normed space there are always inequivalent norms. In other words, the converse you ask about is true.</p>
<p>You are going to need something of this nature. A Banach Space is a complete normed linear space (over $\mathbb{R}$ or $\mathbb{C}$). The equivalence of norms on a finite dimensional space eventually comes down to the facts that the unit ball of a Banach Space is compact if the space is finite-dimensional, and that continuous real-valued functions on compact sets achieve their sup and inf. It is the Bolzano Weirstrass theorem that gives the first property.</p> <p>In fact, a Banach Space is finite dimensional if and only if its unit ball is compact. Things like this do go wrong for infinite-dimensional spaces. For example, let $\ell_1$ be the space of real sequences such that $\sum_{n=0}^{\infty} |a_n| &lt; \infty $. Then $\ell_1$ is an infinite dimensional Banach Space with norm $\|(a_n) \| = \sum_{n=0}^{\infty} |a_n|.$ It also admits another norm $\|(a_n)\|' = \sqrt{ \sum_{n=0}^{\infty} |a_{n}|^2}$ , and this norm is not equivalent to the first one.</p>
logic
<p>Let's say that I prove statement $A$ by showing that the negation of $A$ leads to a contradiction. </p> <p>My question is this: How does one go from "so there's a contradiction if we don't have $A$" to concluding that "we have $A$"?</p> <p>That, to me, seems the exact opposite of logical. It sounds like we say "so, I'll have a really big problem if this thing isn't true, so out of convenience, I am just going to act like it's true". </p>
<p>Proof by contradiction, as you stated, is the rule$\def\imp{\Rightarrow}$ "$\neg A \imp \bot \vdash A$" for any statement $A$, which in English is "If you can derive the statement that $\neg A$ implies a contradiction, then you can derive $A$". As pointed out by others, this is not a valid rule in intuitionistic logic. But I shall now show you why you probably have no choice but to agree with the rule (under certain mild conditions).</p> <p>You see, given any statement $A$, the law of excluded middle says that "$A \lor \neg A$" is true, which in English is "Either $A$ or $\neg A$". Now is there any reason for this law to hold? If you desire that everything you can derive comes with direct evidence of some sort (such as various constructive logics), then it might not hold, because sometimes we have neither evidence for nor against a statement. However, if you believe that the statements you can make have meaning in the real world, then the law obviously holds because the real world either satisfies a statement or its negation, regardless of whether you can figure out which one.</p> <p>The same reasoning also shows that a contradiction can never be true, because the real world never satisfies both a statement and its negation at the same time, simply by the meaning of negation. This gives the principle of explosion, which I will come to later.</p> <p>Now given the law of excluded middle consider the following reasoning. If from $\neg A$ I can derive a contradiction, then $\neg A$ must be impossible, since my other rules are truth-preserving (starting from true statements they derive only true statements). Here we have used the property that a contradiction can never be true. Since $\neg A$ is impossible, and by law of excluded middle we know that either $A$ or $\neg A$ must be true, we have no other choice but to conclude that $A$ must be true.</p> <p>This explains why proof by contradiction is valid, as long as you accept that for every statement $A$, exactly one of "$A$" and "$\neg A$" is true. The fact that we use logic to reason about the world we live in is precisely why almost all logicians accept classical logic. This is why I said "mild conditions" in my first paragraph.</p> <p>Back to the principle of explosion, which is the rule "$\bot \vdash A$" for any statement $A$. At first glance, this may seem even more unintuitive than the proof by contradiction rule. But on the contrary, people use it without even realizing. For example, if you do not believe that I can levitate, you might say "If you can levitate, I will eat my hat!" Why? Because you know that if the condition is false, then whether the conclusion is true or false is completely irrelevant. They are implicitly assuming the rule that "$\bot \imp A$" is always true, which is equivalent to the principle of explosion.</p> <p>We can hence show by a formal deduction that the law of excluded middle and the principle of explosion together give the ability to do proofs by contradiction:</p> <p>[Suppose from "$\neg A$" you can derive "Contradiction".]</p> <p>&emsp; $A \lor \neg A$. [law of excluded middle]</p> <p>&emsp; If $A$:</p> <p>&emsp; &emsp; $A$.</p> <p>&emsp; If $\neg A$:</p> <p>&emsp; &emsp; Contradiction.</p> <p>&emsp; &emsp; Thus $A$. [principle of explosion]</p> <p>&emsp; Therefore $A$. [disjunction elimination]</p> <p>Another possible way to obtain the proof by contradiction rule is if you accept double negation elimination, that is "$\neg \neg A \vdash A$" for any statement $A$. This can be justified by exactly the same reasoning as before, because if "$A$" is true then "$\neg A$" is false and hence "$\neg \neg A$" is true, and similarly if "$A$" is false so is "$\neg \neg A$". Below is a formal deduction showing that contradiction elimination and double negation elimination together give the ability to do proofs by contradiction:</p> <p>[Suppose from "$\neg A$" you can derive "Contradiction".]</p> <p>&emsp; If $\neg A$:</p> <p>&emsp; &emsp; Contradiction.</p> <p>&emsp; Therefore $\neg \neg A$. [contradiction elimination / negation introduction]</p> <p>&emsp; Thus $A$. [double negation elimination]</p>
<p>A contradiction isn't a “problem”. A contradiction is an impossibility. This isn't a matter of saying “Gee, if I have fewer than 20 dollars in the back I won't be able to go out to dinner and I want to so badly, I'll just assume I have more than 20 dollars.” This is a matter of walking into the bank and saying "I'd like to withdraw 20 dollars" and having a trapdoor under you collapse and a 300 lb security guard jumping on your spleen shouting in you ear “You don't <em>have</em> it!!! You don't have it!!” </p> <p>You can't just say “Oh, I got a contradiction when I assumed I had 20 dollars... But that doesn't mean I don't have 20 dollars.”</p> <p>It means <em>precisely</em> that. It is <em>impossible</em> for you to have 20. So you must conclude you <em>don't</em> have 20 dollars.</p> <p>If you get a contradiction, it just isn't possible for A to be false. </p> <p>A contradiction, by its definition is an impossibility. So if you assume A isn't true and you get a contradiction. You have <em>proven</em> that it is <em>impossible</em> for A not to be true. If it is <em>impossible</em> for something not to be true what other options are there? </p>
probability
<p>I just came back from a class on Probability in Game Theory, and was musing over something in my head.</p> <p>Assuming, for the sake of the question:</p> <ul> <li>Playing cards in their current state have been around for approximately eight centuries</li> <li>A deck of playing cards is shuffled to a random configuration one billion times per day</li> <li>Every shuffle ever is completely (theoretically) random and unaffected by biases caused by human shuffling and the games the cards are used for</li> <li>By "deck of cards", I refer to a stack of unordered $52$ unique cards, with a composition that is identical from deck to deck.</li> </ul> <p>This would, approximately, be on the order of $3 \cdot 10^{14}$ random shuffles in the history of playing cards.</p> <p>If I were to shuffle a new deck today, completely randomly, what are the probabilistic odds (out of $1$) that you create a new unique permutation of the playing cards that has never before been achieved in the history of $3 \cdot 10^{14}$ similarly random shuffles?</p> <p>My first thought was to think that it was a simple matter of $\frac{1}{52!} \cdot 3 \cdot 10^{14}$, but then I ran into things like <a href="http://en.wikipedia.org/wiki/Birthday_Paradox">Birthday Paradox</a>. While it is not analogous (I would have to be asking about the odds that any two shuffled decks in the history of shuffled decks ever matched), it has caused me to question my intuitive notions of Probability.</p> <p>What is wrong in my initial approach, if it is wrong?</p> <p>What is the true probability?</p> <p>And, if the probability is less than $0.5$, if we how many more years (centuries?) must we wait, assuming the current rate of one billion shuffles per day, until we reach a state where the probability is $0.5$+? $0.9$+?</p> <p>(Out of curiosity, it would be neat to know the analogous birthday paradox answer, as well)</p>
<p>Your original answer of $\dfrac{3 \times 10^{14}}{52!}$ is not far from being right. That is in fact the expected number of times any ordering of the cards has occurred.</p> <p>The probability that any particular ordering of the cards has not occurred, given your initial assumptions, is $\left(1-\frac1{52!}\right)^{(3\times10^{14})}$, and the probability that it has occurred is 1 minus this value. But for small values of $n\epsilon$, $(1+\epsilon)^n$ is nearly $1+n\epsilon$. In particular, since $52!\approx 8\times 10^{67}$ and so $\dfrac{3\times10^{14}}{52!}\approx 3.75\times 10^{-54}$ is microscopically small, $1-\left(1-\frac1{52!}\right)^{(3\times10^{14})}$ is very nearly $\frac1{52!}\times (3\times10^{14})$. </p>
<p>There are $52!$ possible orders for a deck of $52$ cards. If a unique order of a deck of $52$ unique cards had been created every second since the big bang, the chances that any two of them were repeated is approximated by $$1-(1-1/52!)^{(10^{17})} = 1.2397999\times10^{-51}\ .$$ To show the size of this number, assume that the same shuffling has taken place every second on one planet orbiting every one of the estimated $10^{24}$ stars in the known universe since the beginning of time. The chances that all of those orders has been unique is still $$99.999999999999999999999999876\%\ .$$ Go shuffle a deck of cards six times and create something truly unique!</p>
differentiation
<p><strong>Does anyone know anything about the following &quot;super-derivative&quot; operation?</strong> I just made this up so I don't know where to look, but it appears to have very meaningful properties. An answer to this question could be a reference and explanation, or known similar idea/name, or just any interesting properties or corollaries you can see from the definition here? Is there perhaps a better definition than the one I am using? What is your intuition for what the operator is doing (i.e. is it still in any sense a gradient)? Is there a way to separate the log part out, or remove it? Or is that an essential feature?</p> <p><strong>Definition:</strong> I'm using the word &quot;super-derivative&quot; but that is a made-up name. Define the &quot;super-derivative&quot;, operator <span class="math-container">$S_x^{\alpha}$</span>, about <span class="math-container">$\alpha$</span>, using the derivative type limit equation on the fractional derivative operator <span class="math-container">$D_x^\alpha$</span> <span class="math-container">$$ S_x^{\alpha} = \lim_{h \to 0} \frac{D^{\alpha+h}_x-D^{\alpha}_x}{h} $$</span> then for a function <span class="math-container">$$ S_x^{\alpha} f(x) = \lim_{h \to 0} \frac{D^{\alpha+h}_xf(x)-D^{\alpha}_x f(x)}{h} $$</span> for example, the [Riemann-Liouville, see appendix] fractional derivative of a power function is <span class="math-container">$$ D_x^\alpha x^k = \frac{\Gamma(k+1)}{\Gamma(k-\alpha+1)}x^{k-\alpha} $$</span> and apparently <span class="math-container">$$ S_x^{\alpha} x^k = \frac{\Gamma (k+1) x^{k-\alpha} (\psi ^{(0)}(-\alpha+k+1) - \log (x))}{\Gamma (-\alpha+k+1)} = (\psi ^{(0)}(-\alpha+k+1) - \log (x)) D_x^\alpha x^k $$</span> a nice example of this, the super-derivative of <span class="math-container">$x$</span> at <span class="math-container">$\alpha=1$</span> is <span class="math-container">$-\gamma - \log(x)$</span>, which turns up commonly. I'm wondering if this could be used to describe the series expansions of certain functions that have log or <span class="math-container">$\gamma$</span> terms, e.g. BesselK functions, or the Gamma function.</p> <p><strong>Potential relation to Bessel functions</strong>: For example, a fundamental function with this kind of series, (the inverse Mellin transform of <span class="math-container">$\Gamma(s)^2$</span>), is <span class="math-container">$2 K_0(2 \sqrt{x})$</span> with <span class="math-container">$$ 2 K_0(2 \sqrt{x}) = (-\log (x)-2 \gamma )+x (-\log (x)-2 \gamma +2)+\frac{1}{4} x^2 (-\log (x)-2 \gamma +3)+\\ +\frac{1}{108} x^3 (-3 \log (x)-6 \gamma +11)+\frac{x^4 (-6 \log (x)-12 \gamma +25)}{3456}+O\left(x^5\right) $$</span> in the end, taking the super-derivative of polynomials and matching coefficients we find <span class="math-container">$$ S_x^1[2 \sqrt{x}I_1(2\sqrt{x})] + I_0(2 \sqrt{x})\log(x) = 2K_0(2 \sqrt{x}) $$</span> which can also potentially be written in terms of linear operators as <span class="math-container">$$ [2 S_x x D_x + \log(x)]I_0(2 \sqrt{x}) = 2K_0(2 \sqrt{x}) $$</span> likewise <span class="math-container">$$ [2 S_x x D_x - \log(x)]J_0(2 \sqrt{x}) = \pi Y_0(2 \sqrt{x}) $$</span> I like this because it's similar to an eigensystem, but the eigenfunctions swap over.</p> <p><strong>Gamma Function:</strong> We can potentially define higher-order derivatives, for example <span class="math-container">$$ (S_x^{\alpha})^2 = \lim_{h \to 0} \frac{D^{\alpha+h}_x-2 D^{\alpha}_x + D^{\alpha-h}_x}{h^2} $$</span> and <span class="math-container">$$ (S_x^{\alpha})^3 = \lim_{h \to 0} \frac{D^{\alpha+3h}_x-3 D^{\alpha+2h}_x + 3 D^{\alpha+h}_x - D^{\alpha}_x}{h^3} $$</span></p> <p>this would be needed if there was any hope of explaining the series <span class="math-container">$$ \Gamma(x) = \frac{1}{x}-\gamma +\frac{1}{12} \left(6 \gamma ^2+\pi ^2\right) x+\frac{1}{6} x^2 \left(-\gamma ^3-\frac{\gamma \pi ^2}{2}+\psi ^{(2)}(1)\right)+ \\+\frac{1}{24} x^3 \left(\gamma ^4+\gamma ^2 \pi ^2+\frac{3 \pi ^4}{20}-4 \gamma \psi ^{(2)}(1)\right)+O\left(x^4\right) $$</span> using the 'super-derivative'. This appears to be <span class="math-container">$$ \Gamma(x) = [(S^1_x)^0 x]_{x=1} x^{-1} + [(S^1_x)^1 x]_{x=1} x + \frac{1}{2}[(S^1_x)^2 x]_{x=1} x^2 + \frac{1}{6} [(S^1_x)^3 x]_{x=1} x^3 + \cdots $$</span> so one could postulate <span class="math-container">$$ \Gamma(x) = \frac{1}{x}\sum_{k=0}^\infty \frac{1}{k!}[(S^1_x)^k x]_{x=1} x^{k} $$</span> which I think is quite beautiful.</p> <p><strong>Appendix:</strong> I used the following definition for the fractional derivative: <span class="math-container">$$ D_x^\alpha f(x) = \frac{1}{\Gamma(-\alpha)}\int_0^x (x-t)^{-\alpha-1} f(t) \; dt $$</span> implemented for example by the Wolfram Mathematica code found <a href="https://community.wolfram.com/groups/-/m/t/1313893" rel="noreferrer">here</a></p> <pre><code>FractionalD[\[Alpha]_, f_, x_, opts___] := Integrate[(x - t)^(-\[Alpha] - 1) (f /. x -&gt; t), {t, 0, x}, opts, GenerateConditions -&gt; False]/Gamma[-\[Alpha]] FractionalD[\[Alpha]_?Positive, f_, x_, opts___] := Module[ {m = Ceiling[\[Alpha]]}, If[\[Alpha] \[Element] Integers, D[f, {x, \[Alpha]}], D[FractionalD[-(m - \[Alpha]), f, x, opts], {x, m}] ] ] </code></pre> <p>I'm happy to hear more about other definitions for the fractional operators, and whether they are more suitable.</p>
<p>I've thought about this for a few days now, I didn't originally intend to answer my own question but it seems best to write this as an answer rather than add to the question. I think there is nice interpretation in the following: <span class="math-container">$$ f(x) = \lim_{h \to 0} \frac{e^{h f(x)}-1}{h} $$</span> also consider the Abel shift operator <span class="math-container">$$ e^{h D_x}f(x) = f(x+h) $$</span> from the limit form of the derivative we have (in the sense of an operator) <span class="math-container">$$ D_x = \lim_{h \to 0} \frac{e^{h D_x}-e^{0 D_x}}{h} = \lim_{h \to 0} \frac{e^{h D_x}-1}{h} $$</span> now we can also manipulate the first equation to get <span class="math-container">$$ \log f(x) = \lim_{h \to 0} \frac{f^h(x)-1}{h} $$</span> so by (a very fuzzy) extrapolation, we might have <span class="math-container">$$ \log(D_x) = \lim_{h \to 0} \frac{D_x^h-1}{h} $$</span> and applying that to a <em>function</em> we now get <span class="math-container">$$ \log(D_x) f(x) = \lim_{h \to 0} \frac{D_x^h f(x)-f(x)}{h} $$</span> which is the <span class="math-container">$\alpha = 0$</span> case of the 'super-derivative'. So <strong>one interpretation</strong> of this case is the logarithm of the derivative? If we apply the log-derivative to a fractional derivative then we have <span class="math-container">$$ \log(D_x) D^\alpha_x f(x) = \lim_{h \to 0} \frac{D_x^h D^\alpha_x f(x)-D^\alpha_x f(x)}{h} $$</span> there might be a question of the validity of <span class="math-container">$D_x^h D^\alpha_x = D_x^{\alpha+h}$</span> which I believe isn't always true for fractional derivatives.</p> <p>This interpretation would explain the <span class="math-container">$\log(x)$</span> type terms arising in the series above. I'd be interested to see if anyone has any comments on this? I'd love to see other similar interpretations or developments on this. What are the eigenfunctions for the <span class="math-container">$\log D_x$</span> operator for example? Can we form meaningful differential equations?</p> <p><strong>Edit:</strong> For some functions I have tried we do have the expected property <span class="math-container">$$ n \log(D_x) f(x) = \log(D_x^n) f(x) $$</span> with <span class="math-container">$$ \log(D_x^n) f(x) = \lim_{h \to 0} \frac{D_x^{n h} f(x)-f(x)}{h} $$</span></p>
<p>Seems like you have happened upon some relations similar to ones I've written about over several years. Try for starters the <a href="https://math.stackexchange.com/questions/125343/lie-group-heuristics-for-a-raising-operator-for-1n-fracdnd-betan-fra">MSE-Q&amp;A</a> &quot;Lie group heuristics for a raising operator for <span class="math-container">$(-1)^n \frac{d^n}{d\beta^n}\frac{x^\beta}{\beta!}|_{\beta=0}$</span>.&quot; There are several posts on my blog (see my user page) on this topic, logarithm of the derivative operator (see also <a href="https://oeis.org/A238363" rel="nofollow noreferrer">A238363</a> and links therein, a new one will be added soon, my latest blog post), and fractional differ-integral calculus.</p>
matrices
<p>I have looked extensively for a proof on the internet but all of them were too obscure. I would appreciate if someone could lay out a simple proof for this important result. Thank you.</p>
<p>These answers require way too much machinery. By definition, the characteristic polynomial of an $n\times n$ matrix $A$ is given by $$p(t) = \det(A-tI) = (-1)^n \big(t^n - (\text{tr} A) \,t^{n-1} + \dots + (-1)^n \det A\big)\,.$$ On the other hand, $p(t) = (-1)^n(t-\lambda_1)\dots (t-\lambda_n)$, where the $\lambda_j$ are the eigenvalues of $A$. So, comparing coefficients, we have $\text{tr}A = \lambda_1 + \dots + \lambda_n$.</p>
<p>Let $A$ be a matrix. It has a <a href="http://en.wikipedia.org/wiki/Jordan_normal_form">Jordan Canonical Form</a>, i.e. there is matrix $P$ such that $PAP^{-1}$ is in Jordan form. Among other things, Jordan form is upper triangular, hence it has its eigenvalues on its diagonal. It is therefore clear for a matrix in Jordan form that its trace equals the sum of its eigenvalues. All that remains is to prove that if $B,C$ are <a href="http://en.wikipedia.org/wiki/Similar_%28linear_algebra%29">similar</a> then they have the same eigenvalues.</p>
linear-algebra
<blockquote> <p>Let <span class="math-container">$\,A,B,C\in M_{n}(\mathbb C)\,$</span> be Hermitian and positive definite matrices such that <span class="math-container">$A+B+C=I_{n}$</span>, where <span class="math-container">$I_{n}$</span> is the identity matrix. Show that <span class="math-container">$$\det\left(6(A^3+B^3+C^3)+I_{n}\right)\ge 5^n \det \left(A^2+B^2+C^2\right)$$</span></p> </blockquote> <p>This problem is a test question from China (xixi). It is said one can use the equation</p> <p><span class="math-container">$$a^3+b^3+c^3-3abc=(a+b+c)(a^2+b^2+c^2-ab-bc-ac)$$</span></p> <p>but I can't use this to prove it. Can you help me?</p>
<p>Here is a partial and positive result, valid around the &quot;triple point&quot; <span class="math-container">$A=B=C= \frac13\mathbb 1$</span>.</p> <p>Let <span class="math-container">$A,B,C\in M_n(\mathbb C)$</span> be Hermitian satisfying <span class="math-container">$A+B+C=\mathbb 1$</span>, and additionally assume that <span class="math-container">$$\|A-\tfrac13\mathbb 1\|\,,\,\|B-\tfrac13\mathbb 1\|\,,\, \|C-\tfrac13\mathbb 1\|\:\leqslant\:\tfrac16\tag{1}$$</span> in the spectral or operator norm. (In particular, <span class="math-container">$A,B,C$</span> are positive-definite.)<br /> Then we have <span class="math-container">$$6\left(A^3+B^3+C^3\right)+\mathbb 1\:\geqslant\: 5\left(A^2+B^2+C^2\right)\,.\tag{2}$$</span></p> <p><strong>Proof:</strong> Let <span class="math-container">$A_0=A-\frac13\mathbb 1$</span> a.s.o., then <span class="math-container">$A_0+B_0+C_0=0$</span>, or <span class="math-container">$\,\sum_\text{cyc}A_0 =0\,$</span> in notational short form. Consider the</p> <ul> <li>Sum of squares <span class="math-container">$$\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^2 \:=\: \sum_\text{cyc}\big(A_0^2 + \tfrac23 A_0+ \tfrac19\mathbb 1\big) \:=\: \sum_\text{cyc}A_0^2 \:+\: \tfrac13\mathbb 1$$</span></li> <li>Sum of cubes <span class="math-container">$$\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^3 \:=\: \sum_\text{cyc}\big(A_0^3 + 3A_0^2\cdot\tfrac13 + 3A_0\cdot\tfrac1{3^2} + \tfrac1{3^3}\mathbb 1\big) \\ \;=\: \sum_\text{cyc}A_0^3 \:+\: \sum_\text{cyc}A_0^2 \:+\: \tfrac19\mathbb 1$$</span> to obtain <span class="math-container">$$6\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^3+\mathbb 1 \;-\; 5\sum_\text{cyc}\big(A_0 + \tfrac13\mathbb 1\big)^2 \:=\: \sum_\text{cyc}A_0^2\,(\mathbb 1 + 6A_0) \:\geqslant\: 0$$</span> where positivity is due to each summand being a product of commuting positive-semidefinite matrices. <span class="math-container">$\quad\blacktriangle$</span></li> </ul> <p><em><strong>Two years later observation:</strong></em><br /> In order to conclude <span class="math-container">$(2)$</span> the additional assumptions <span class="math-container">$(1)$</span> may be weakened a fair way off to <span class="math-container">$$\tfrac16\mathbb 1\:\leqslant\: A,B,C\tag{3}$$</span> or equivalently, assuming the smallest eigenvalue of each matrix <span class="math-container">$A,B,C\,$</span> to be at least <span class="math-container">$\tfrac16$</span>.</p> <p><strong>Proof:</strong> Consider the very last summand in the preceding proof. Revert notation from <span class="math-container">$A_0$</span> to <span class="math-container">$A$</span> and use the same argument, this time based on <span class="math-container">$(3)$</span>, to obtain <span class="math-container">$$\sum_\text{cyc}\big(A-\tfrac13\mathbb 1\big)^2\,(6A -\mathbb 1)\:\geqslant\: 0\,.\qquad\qquad\blacktriangle$$</span></p>
<p><strong>Not a full proof</strong>, but a number of thoughts too long for a comment. This post aims at finding alternative (yet harder) criteria for proving the conjecture. Please discuss.</p> <p>As in previous comments, let's denote $ X=6(A^3+B^3+C^3)+I $ and $ Y=5(A^2+B^2+C^2) $ and $D = X-Y$.</p> <p>The question is to show $\det(X) \ge \det(Y)$ or $1 \ge \det(X^{-1}Y)$. Write $Q = X^{-1}Y$, then $Q$ is positive definite, since $X$ and $Y$ are positive definite. Now it is known for a positive definite matrix $Q$ (see e.g. <a href="https://math.stackexchange.com/questions/202248/">here</a>) that the <em>trace bound</em> is given by $$ \bigg(\frac{\text{Tr}(Q)}{n}\bigg)^n \geq \det(Q) $$ </p> <p>So a second (harder) criterion for the conjecture is $n \ge \text{Tr}(X^{-1}Y)$ or $ \text{Tr}(X^{-1}D) \geq 0$. I wouldn't see how I can compute this trace or find bounds, can someone?</p> <p>Let's call $d_i$ the eigenvalues of $D$, likewise for $X$ and $Y$. While $x_i &gt; 0$, this doesn't necessarily hold for $d_i$ since we know from comments that $D$ is not necessarily positive definite. So (if $X$ and $D$ could be simultaneously diagonalized) $ \text{Tr}(X^{-1}D) = \sum_i \frac{d_i}{x_i} = r \sum_i {d_i}$ where there exists an $r$ by the mean value theorem. Where $r$ is not guaranteed to be positive, it is likely that $r$ <em>will</em> be positive, since $r$ will only become negative if there are (many, very) negative $d_i$ with small associated $x_i$. Can positivity of $r$ be shown? If we can establish that a positive $r$ can be found, a third criterion is $ \text{Tr}(D) \geq 0$.</p> <p>Now with this third criterion, we can use that the trace is additive and that the trace of commutors vanishes, i.e. $\text{Tr} (AB -BA) = 0$. Using this argument, it becomes unharmful when matrices do not commute, since under the trace their order can be changed. This restores previous solutions where the conjecture was reduced to the valid Schur's inequality (as noted by a previous commenter), which proves the conjecture.</p> <hr> <p>A word on how hard the criteria are, indicatively in terms of eigenvalues:</p> <p>(hardest) positive definiteness: $d_i &gt;0$ $\forall i$ or equivalently, $\frac{y_i}{x_i} &lt;1$ $\forall i$ </p> <p>(second- relies on positive $r$) $ \text{Tr}(D) \geq 0$: $\sum_i d_i \geq 0$</p> <p>(third) $n \ge \text{Tr}(X^{-1}Y)$: $\sum_i \frac{y_i}{x_i} \leq n$</p> <p>(fourth - least hard) $\det(X) \ge \det(Y)$: $\prod_i \frac{y_i}{x_i} \leq 1$</p> <p>Solutions may also be found by using criteria which interlace between those four. </p> <hr> <p>A word on simulations and non-positive-definiteness:</p> <p>I checked the above criteria for the non-positive definite example given by @user1551 in the comments above, and the second, third and fourth criteria hold. </p> <p>Note that equality $\det(X) = \det(Y)$ occurs for (a) symmetry point: $A=B=C=\frac13 I$ and for (b) border point: $A=B=\frac12 I$ and $C=0$ (and permutations). I checked the "vicinity" of these equality points by computer simulations for real matrices with $n=2$ where I extensively added small matrices with any parameter choices to $A$ and $B$ (and let $C = I - A-B$), making sure that $A,B$ and $C$ are positive definite. It shows that for the vicinity of the symmetry point, the second, third and fourth criteria above hold, while there occur frequent non-positive-definite examples. For the vicinity of the border point all four criteria hold.</p>
combinatorics
<blockquote> <p>Can <span class="math-container">$18$</span> consecutive positive integers be separated into two groups such that their product is equal? We cannot leave out any number and neither we can take any number more than once.</p> </blockquote> <p>My work:<br /> When the smallest number is not <span class="math-container">$17$</span> or its multiple, there cannot exist any such arrangement as <span class="math-container">$17$</span> is a prime.</p> <p>When the smallest number is a multiple of <span class="math-container">$17$</span> but not of <span class="math-container">$13$</span> or <span class="math-container">$11$</span>, then no such arrangement exists.</p> <p>But what happens, when the smallest number is a multiple of <span class="math-container">$ 17 $</span> and <span class="math-container">$13$</span> or <span class="math-container">$11$</span> or both?<br /> Please help!</p>
<p>This is impossible. </p> <p>At most one of the integers can be divisible by $19$. If there is such an integer, then one group will contain it and the other one will not. The first product is then divisible by $19$ whereas the second is not (since $19$ is prime) --- a contradiction.</p> <p>So if this possible, the remainders of the numbers after division by $19$ must be precisely $1,2,3,\cdots,18$. </p> <p>Now let $x$ be the product of the numbers in one of the groups. Then </p> <p>$x^2 \equiv 18! \equiv -1 \pmod{19}$ </p> <p>by <a href="http://en.wikipedia.org/wiki/Wilson%27s_theorem">Wilson's Theorem</a>. However $-1$ is not a quadratic residue mod $19$, because the only possible squares mod $19$ are $1,4,9,16,6,17,11,7,5$.</p>
<p>If $18$ consecutive positive integers could be separated into two groups with equal products, then the product of all $18$ integers would be a perfect square. However, the product of two or more consecutive positive integers can never be a perfect square, according to a famous theorem of P. Erdős, <a href="http://www.renyi.hu/~p_erdos/1939-03.pdf">Note on products of consecutive integers</a>, J. London Math. Soc. 14 (1939), 194-198.</p>
number-theory
<p>Consider the following decision problem: given two lists of positive integers $a_1, a_2, \dots, a_n$ and $b_1, b_2, \dots, b_m$ the task is to decide if $a_1^{a_2^{\cdot^{\cdot^{\cdot^{a_n}}}}} &lt; b_1^{b_2^{\cdot^{\cdot^{\cdot^{b_m}}}}}$.</p> <ul> <li>Is this problem in the <a href="http://en.wikipedia.org/wiki/P_%28complexity%29">class $P$</a>?</li> <li>If yes, then what is the algorithm solving it in polynomial time?</li> <li>Otherwise, what is the fastest algorithm that can solve it?</li> </ul> <p><em>Update:</em> </p> <ul> <li>I mean polynomial type with respect to the size of the input, i.e. total number of digits in all $a_i, b_i$.</li> <li>$p^{q^{r^s}}=p^{(q^{(r^s)})}$, <strong>not</strong> $((p^q)^r)^s$.</li> </ul>
<p>Recently I asked a <a href="https://mathematica.stackexchange.com/questions/24815/how-to-compare-power-towers-in-mathematica">very similar question</a> at Mathematica.SE. I assume you know it, because you participated in the discussion.</p> <p><a href="https://mathematica.stackexchange.com/users/81/leonid-shifrin">Leonid Shifrin</a> suggested an <a href="https://mathematica.stackexchange.com/a/24864/7309">algorithm that solves this problem</a> for the majority of cases, although there were cases when it gave an incorrect answer. But his approach seems correct and it looks like it is possible to fix those defects. Although it was not rigorously proved, his algorithm seems to work in polynomial time. It looks like it would be fair if he got the bounty for this question, but for some reason he didn't want to.</p> <p>So, this question is not yet settled completely and I am going to look for the complete and correct solution, and will start a new bounty for this question once the current one expires. I do not expect to get a bounty for this answer, but should you choose to award it, I will add it up to the amount of the new bounty so that it passes to whomever eventually solves this question.</p>
<p>For readability I'll write $[a_1,a_2,\ldots,a_n]$ for the tower $a_1^{a_2^{a_3^\cdots}}$.</p> <p>Let all of the $a_i,b_i$ be in the interval $[2,N]$ where $N=2^K$ (if any $a_i$ or $b_i$ is 1 we can truncate the tower at the previous level, and the inputs must be bounded to talk about complexity).</p> <p>Then consider two towers of the same height $$ T=[N,N,\ldots,N,x] \quad \mathrm{and} \quad S=[2,2,\dots,2,y] $$ i.e. T is the largest tower in our input range with $x$ at the top, and S is the smallest with $y$ at the top.</p> <p>With $N, x\ge 2$ and $y&gt;2Kx$ then $$ \begin{aligned} 2^y &amp; &gt; 2^{2Kx} \\ &amp; = N^{2x} \\ &amp; &gt; 2log(N)N^x &amp;\text{ as $x \gt 1 \ge \frac{1+log(log(N))}{log(N)}$} \\ &amp; = 2KN^x \end{aligned} $$ Now write $x'=N^x$ and $y'=2^y&gt;2Kx'$ then $$ [N,N,x]=[N,x']&lt;[2,y']=[2,2,y] $$ Hence by induction $T&lt;S$ when $y&gt;2Kx$.</p> <p>So we only need to calculate the exponents down from the top until one exceeds the other by a factor of $2K$, then that tower is greater no matter what values fill in the lower ranks.</p> <p>If the towers have different heights, wlog assume $n&gt;m$, then first we reduce $$ [a_1,a_2,\ldots,a_n] = [a_1,a_2,\ldots,a_{m-1},A] $$ where $A=[a_m,a_{m+1},\ldots,a_n]$. If we can determine that $A&gt;2Kb_m$ then the $a$ tower is larger.</p> <p>If the towers match on several of the highest exponents, then we can reduce the need for large computations with a shortcut. Assume $n=m$, that $a_j&gt; b_j$ for some $j&lt;m$ and $a_i=b_i$ for $j&lt;i\le m$. Then $$ [a_1,a_2,\ldots,a_m] = [a_1,a_2,\ldots,a_j,X] \\ [b_1,b_2,\ldots,b_m] = [b_1,b_2,\ldots,b_j,X] $$ and the $a$ tower is larger if $(a_j/b_j)^X&gt;2K$. So we don't need to compute $X$ fully if we can determine that it exceeds $\log(2K)/\log(a_j/b_j)$.</p> <p>These checks need to be combined with a numeric method like the one @ThomasAhle gave. They can solve the problem that method has with deep trees that match at the top, but can't handle $[4,35,15],[20,57,13]$ which are too big to compute but don't allow for one of these shortcuts. </p>
matrices
<p>I am trying to understand how - exactly - I go about projecting a vector onto a subspace.</p> <p>Now, I know enough about linear algebra to know about projections, dot products, spans, etc etc, so I am not sure if I am reading too much into this, or if this is something that I have missed.</p> <p>For a class I am taking, the proff is saying that we take a vector, and 'simply project it onto a subspace', (where that subspace is formed from a set of orthogonal basis vectors).</p> <p>Now, I know that a subspace is really, at the end of the day, just a set of vectors. (That satisfy properties <a href="http://en.wikipedia.org/wiki/Projection_%28linear_algebra%29">here</a>). I get that part - that its this set of vectors. So, how do I "project a vector on this subspace"?</p> <p>Am I projecting my one vector, (lets call it a[n]) onto ALL the vectors in this subspace? (What if there is an infinite number of them?)</p> <p>For further context, the proff was saying that lets say we found a set of basis vectors for a signal, (lets call them b[n] and c[n]) then we would project a[n] onto its <a href="http://en.wikipedia.org/wiki/Signal_subspace">signal subspace</a>. We project a[n] onto the signal-subspace formed by b[n] and c[n]. Well, how is this done exactly?..</p> <p>Thanks in advance, let me know if I can clarify anything!</p> <p>P.S. I appreciate your help, and I would really like for the clarification to this problem to be somewhat 'concrete' - for example, something that I can show for myself over MATLAB. Analogues using 2-D or 3-D space so that I can visualize what is going on would be very much appreciated as well. </p> <p>Thanks again.</p>
<p>I will talk about orthogonal projection here.</p> <p>When one projects a vector, say $v$, onto a subspace, you find the vector in the subspace which is "closest" to $v$. The simplest case is of course if $v$ is already in the subspace, then the projection of $v$ onto the subspace is $v$ itself.</p> <p>Now, the simplest kind of subspace is a one dimensional subspace, say the subspace is $U = \operatorname{span}(u)$. Given an arbitrary vector $v$ not in $U$, we can project it onto $U$ by $$v_{\| U} = \frac{\langle v , u \rangle}{\langle u , u \rangle} u$$ which will be a vector in $U$. There will be more vectors than $v$ that have the same projection onto $U$.</p> <p>Now, let's assume $U = \operatorname{span}(u_1, u_2, \dots, u_k)$ and, since you said so in your question, assume that the $u_i$ are orthogonal. For a vector $v$, you can project $v$ onto $U$ by $$v_{\| U} = \sum_{i =1}^k \frac{\langle v, u_i\rangle}{\langle u_i, u_i \rangle} u_i = \frac{\langle v , u_1 \rangle}{\langle u_1 , u_1 \rangle} u_1 + \dots + \frac{\langle v , u_k \rangle}{\langle u_k , u_k \rangle} u_k.$$</p>
<p>Take a basis $\{v_1, \dots, v_n\}$ for the "signal subspace" $V$. Let's assume $V$ is finite dimensional for simplicity and practical purposes, but you can generalize to infinite dimensions. Let's also assume the basis is orthonormal.</p> <p>The projection of your signal $f$ onto the subspace $V$ is just</p> <p>$$\mathrm{proj}_V(f) = \sum_{i=1}^n \langle f, v_i \rangle v_i$$</p> <p>and $f = \mathrm{proj}_V(f) + R(f)$, where $R(f)$ is the remainder, or orthogonal complement, which will be 0 if $f$ lies in the subspace $V$. </p> <p>The $i$-th term of the sum, $\langle f, v_i\rangle$, is the projection of $f$ onto the subspace spanned by the $i$-th basis vector. (Note, if the $v_i$ are orthogonal, but not necessarily orthonormal, you must divide the $i$-th term by $\|v_i\|^2$.)</p>
probability
<p>A disc contains <span class="math-container">$n$</span> independent uniformly random points. Each point is connected by a line segment to its nearest neighbor, forming clusters of connected points.</p> <p>For example, here are <span class="math-container">$20$</span> random points and <span class="math-container">$7$</span> clusters, with an average cluster size of <span class="math-container">$\frac{20}{7}$</span>.</p> <p><a href="https://i.sstatic.net/PXovh.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/PXovh.png" alt="enter image description here" /></a></p> <blockquote> <p>What does the average cluster size approach as <span class="math-container">$n\to\infty$</span> ?</p> </blockquote> <p><strong>My attempt:</strong></p> <p>I made a <a href="https://www.desmos.com/calculator/v4ziiyaonx?lang=zh-CN" rel="nofollow noreferrer">random point generator</a> that generates <span class="math-container">$20$</span> random points. The average cluster size is usually approximately <span class="math-container">$3$</span>.</p> <p>I considered what happens when we add a new random point to a large set of random points. Adding the point either causes no change in the number of clusters, or it causes the number of clusters to increase by <span class="math-container">$1$</span> (<strong>Edit:</strong> this is not true, as noted by @TonyK in the comments). The probability that adding a new point increases the number of clusters by <span class="math-container">$1$</span>, is the reciprocal of the answer to my question. (Analogy: Imagine guests arriving to a party; if 25% of guests bring a bottle of wine, then the expectation of the average number of guests per bottle of wine is <span class="math-container">$4$</span>.) But I haven't worked out this probability.</p> <p><strong>Context:</strong></p> <p>This question was inspired by the question <a href="https://math.stackexchange.com/questions/271497/stars-in-the-universe-probability-of-mutual-nearest-neighbors">Stars in the universe - probability of mutual nearest neighbors</a>.</p> <p><strong>Edit:</strong> Postd on <a href="https://mathoverflow.net/q/462252/494920">MO</a>.</p>
<p>This is <a href="https://math.stackexchange.com/questions/271497/">Stars in the universe - probability of mutual nearest neighbors</a> in disguise. If there are <span class="math-container">$k$</span> pairs of mutual nearest neighbours, then there are <span class="math-container">$n-k$</span> edges (since <span class="math-container">$n$</span> edges are drawn and <span class="math-container">$k$</span> of them occur twice). There can’t be any cycles (unless it’s an Escher disk) because the distances would have to decrease all along the cycle. So the graph is a forest of <span class="math-container">$n-(n-k)=k$</span> trees. For <span class="math-container">$n\to\infty$</span>, the fraction of points that are their nearest neighbour’s nearest neighbour goes to the probability for that to happen; <span class="math-container">$\frac kn$</span> is half that fraction, and the expected average cluster size is the reciprocal of that. In two dimensions, that yields</p> <p><span class="math-container">$$ 2\left(\frac43+\frac{\sqrt3}{2\pi}\right)\approx3.218\;. $$</span></p>
<p>Your question is scratching the surface of the area in probability called <em>percolation theory</em>.</p> <p>Indeed, noting that the connectivity of a random graph in OP's model is independent of the scale, we may consider <span class="math-container">$n$</span> independent points sampled uniformly at random from a disk of radius <span class="math-container">$\sqrt{n}$</span>. Then, as <span class="math-container">$n \to \infty$</span>, the thermodynamic limit of this model converges to what is termed as the <em>nearest-neighbor continuum percolation</em> model [1], which can be described as follows:</p> <blockquote> <p><strong>Limit Model.</strong> Let <span class="math-container">$X$</span> be a Poisson point process on <span class="math-container">$\mathbb{R}^2$</span> with constant intensity. For any two distinct points <span class="math-container">$x$</span> and <span class="math-container">$y$</span> in <span class="math-container">$X$</span>, connect <span class="math-container">$x$</span> and <span class="math-container">$y$</span> if <span class="math-container">$y$</span> is a nearest neighbor of <span class="math-container">$x$</span>.</p> <p><strong>Q.</strong> Can we say anything about the cluster-size distribution in this model?</p> </blockquote> <p>To my knowledge, it seems that most of the questions regarding this distribution, including OP's one, has never been explored in the literature, and I have a hunch that it is almost impossible to answer this exactly. At least, it is known that all the clusters are finite with probability one, as proved in [1].</p> <hr /> <p><strong>Edit.</strong> <a href="https://math.stackexchange.com/a/4845566/9340"><strong>@joriki</strong> demonstrated that</a> OP's question can be answered without explicitly knowing the size distribution of the connected clusters, via associating each cluster to the unique &quot;mutual nearest-neighbor pair&quot; contained in it.</p> <hr /> <p><strong>[1]</strong> Häggström, O. and Meester, R. (1996), <em>Nearest neighbor and hard sphere models in continuum percolation</em>. Random Struct. Alg., 9: 295-315. <a href="https://doi.org/10.1002/(SICI)1098-2418(199610)9:3%3C295::AID-RSA3%3E3.0.CO;2-S" rel="nofollow noreferrer">https://doi.org/10.1002/(SICI)1098-2418(199610)9:3&lt;295::AID-RSA3&gt;3.0.CO;2-S</a></p>
combinatorics
<p>Can rotations and translations of this shape</p> <p><a href="https://i.sstatic.net/uZWU5.png" rel="noreferrer"><img src="https://i.sstatic.net/uZWU5.png" alt="enter image description here"></a></p> <p>perfectly tile some equilateral triangle?</p> <hr> <p>I've now also asked this question on <a href="https://mathoverflow.net/questions/267095/can-a-row-of-five-equilateral-triangles-tile-a-big-equilateral-triangle">mathoverflow</a>.</p> <hr> <p>Notes:</p> <ul> <li>Obviously I'm ignoring the triangle of side <span class="math-container">$0$</span>.</li> <li>Because the area of the triangle has to be a multiple of the area of the tile, the triangle must have side length divisible by <span class="math-container">$5$</span> (where <span class="math-container">$1$</span> is the length of the short edges of the tile).</li> <li>The analogous tile made of <em>three</em> equilateral triangles <em>can</em> tile any equilateral triangle with side length divisible by three.</li> <li>There is a computer program, <a href="http://burrtools.sourceforge.net/" rel="noreferrer">Burr Tools</a>, which was designed to solve this kind of problem. <a href="https://math.stackexchange.com/users/4308/josh-b">Josh B.</a> has used it to prove by exhaustive search that there is no solution when the side length of the triangle is <span class="math-container">$5$</span>, <span class="math-container">$10$</span>, <span class="math-container">$15$</span>, <span class="math-container">$20$</span> or <span class="math-container">$25$</span>. Lengths of <span class="math-container">$30$</span> or more will take a very long time to check.</li> <li>This kind of problem can often be solved be a <a href="http://yufeizhao.com/olympiad/tiling.pdf" rel="noreferrer">colouring argument</a> but I've failed to find a suitable colouring. (See below.)</li> <li><a href="https://math.stackexchange.com/users/26501/lee-mosher">Lee Mosher</a> pointed me in the direction of Conway's theory of <a href="http://www.cimat.mx/ciencia_para_jovenes/pensamiento_matematico/thurston.pdf" rel="noreferrer">tiling groups</a>. This theory can be used to show that if the tile can cover an equilateral triangle of side length <span class="math-container">$n$</span> then <span class="math-container">$a^nb^nc^n=e$</span> in the group <span class="math-container">$\left&lt;a,b,c\;\middle|\;a^3ba^{-2}c=a^{-3}b^{-1}a^2c^{-1}=b^3cb^{-2}a=b^{-3}c^{-1}b^2a^{-1}=c^3ac^{-2}b=c^{-3}a^{-1}c^2b^{-1}=e\right&gt;$</span>. But sadly it turns out that we <em>do</em> have that <span class="math-container">$a^nb^nc^n=e$</span> in this group whenever <span class="math-container">$n$</span> divides by <span class="math-container">$5$</span>.</li> <li>In fact one can use the methods in <a href="http://www.cflmath.com/Research/Tilehomotopy/tilehomotopy.pdf" rel="noreferrer">this paper</a> of Michael Reid to prove that this tile's homotopy group is the cyclic group with <span class="math-container">$5$</span> elements. I think this means that the <em>only</em> thing these group theoretic methods can tell us is a fact we already knew: that the side length must be divisible by <span class="math-container">$5$</span>.</li> <li>These group theoretic methods are also supposed to subsume all possible colouring arguments, which means that any proof based purely on colouring is probably futile.</li> <li>The smallest area that can be left uncovered when trying to cover a triangle of side length <span class="math-container">$(1,\dots,20)$</span> is <span class="math-container">$($</span><a href="https://i.sstatic.net/9iIJT.png" rel="noreferrer"><span class="math-container">$1$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/RjPaa.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/lC3fl.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/kR3Gz.png" rel="noreferrer"><span class="math-container">$1$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/5FlgV.png" rel="noreferrer"><span class="math-container">$5$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/euPiN.png" rel="noreferrer"><span class="math-container">$6$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/ZGWPR.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/CDHCC.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/zv5AL.png" rel="noreferrer"><span class="math-container">$6$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/71Y9n.png" rel="noreferrer"><span class="math-container">$5$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/K9Jc1.png" rel="noreferrer"><span class="math-container">$6$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/2UeYX.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/78ujz.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/aFLjk.png" rel="noreferrer"><span class="math-container">$6$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/ycu54.png" rel="noreferrer"><span class="math-container">$5$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/Wzrak.png" rel="noreferrer"><span class="math-container">$6$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/DXbsB.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/VGBjo.png" rel="noreferrer"><span class="math-container">$4$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/NT0mE.png" rel="noreferrer"><span class="math-container">$6$</span></a><span class="math-container">$,\,$</span><a href="https://i.sstatic.net/m1N3D.png" rel="noreferrer"><span class="math-container">$5$</span></a><span class="math-container">$)$</span> small triangles. In particular it's surprising that when the area is <span class="math-container">$1\;\mathrm{mod}\;5$</span> one must sometimes leave six triangles uncovered rather than just one.</li> <li>We can look for "near misses" in which all but <span class="math-container">$5$</span> of the small triangles are covered and in which <span class="math-container">$4$</span> of the missing small triangles could be covered by the same tile. There's essentially only <a href="https://i.sstatic.net/fKa4U.png" rel="noreferrer">one</a> near miss for the triangle of side <span class="math-container">$5$</span>, none for the triangle of side <span class="math-container">$10$</span> and six (<a href="https://i.sstatic.net/sqVLe.png" rel="noreferrer">1</a>,<a href="https://i.sstatic.net/wvC9j.png" rel="noreferrer">2</a>,<a href="https://i.sstatic.net/BWPxQ.png" rel="noreferrer">3</a>,<a href="https://i.sstatic.net/d7TD3.png" rel="noreferrer">4</a>,<a href="https://i.sstatic.net/cbu6T.png" rel="noreferrer">5</a>,<a href="https://i.sstatic.net/O0nZN.png" rel="noreferrer">6</a>) for the triangle of side <span class="math-container">$15$</span>. (All other near misses can be generated from these by rotation, reflection, and by reorienting the three tiles that go around the lonesome missing triangle.) This set of six near misses are very interesting since the positions of the single triangle and the place where it "should" go are very constrained.</li> </ul>
<p>I suppose I should post: I solved this <a href="https://mathoverflow.net/questions/267095/can-a-row-of-five-equilateral-triangles-tile-a-big-equilateral-triangle/267401#267401">on MathOverflow</a>. The answer is YES: a size-45 triangle can be tiled.</p> <p>I thank two insights from Josh B here: first that a rhombus with side length 15 can be tiled, and second the strategy to "select a different shape which does tile a triangle, then tile that shape with our $5$ triangle trapezoid."</p> <p>This $15-15-15-30$ trapezoid can be tiled, and three such trapezoids can tile a triangle with side length $45$.</p> <p><a href="https://i.sstatic.net/vAh1v.png" rel="noreferrer"><img src="https://i.sstatic.net/vAh1v.png" alt="enter image description here"></a></p>
<p>Here's the minimal solution, a side-30 triangle. Also posted to MathOverflow here <a href="https://mathoverflow.net/questions/267095/can-a-row-of-five-equilateral-triangles-tile-a-big-equilateral-triangle">https://mathoverflow.net/questions/267095/can-a-row-of-five-equilateral-triangles-tile-a-big-equilateral-triangle</a>.<a href="https://i.sstatic.net/deciC.png" rel="noreferrer"><img src="https://i.sstatic.net/deciC.png" alt="enter image description here"></a></p>
logic
<p>I received this question from my mathematics professor as a leisure-time logic quiz, and although I thought I answered it right, he denied. Can someone explain the reasoning behind the correct solution?</p> <blockquote> <p>Which answer in this list is the correct answer to <em>this</em> question?</p> <ol> <li>All of the below.</li> <li>None of the below.</li> <li>All of the above.</li> <li>One of the above.</li> <li>None of the above.</li> <li>None of the above.</li> </ol> </blockquote> <p>I thought:</p> <ul> <li><span class="math-container">$2$</span> and <span class="math-container">$3$</span> contradict so <span class="math-container">$1$</span> cannot be true.</li> <li><span class="math-container">$2$</span> denies <span class="math-container">$3$</span> but <span class="math-container">$3$</span> affirms <span class="math-container">$2,$</span> so <span class="math-container">$3$</span> cannot be true</li> <li><span class="math-container">$2$</span> denies <span class="math-container">$4,$</span> but as <span class="math-container">$1$</span> and <span class="math-container">$3$</span> are proven to be false, <span class="math-container">$4$</span> cannot be true.</li> <li><span class="math-container">$6$</span> denies <span class="math-container">$5$</span> but not vice versa, so <span class="math-container">$5$</span> cannot be true.</li> </ul> <p>at this point only <span class="math-container">$2$</span> and <span class="math-container">$6$</span> are left to be considered. I thought choosing <span class="math-container">$2$</span> would not deny <span class="math-container">$1$</span> (and it can't be <em>all of the below</em> and <em>none of the below</em>) hence I thought the answer is <span class="math-container">$6.$</span></p> <p>I don't know the correct answer to the question. Thanks!</p>
<pre><code>// gcc ImpredictivePropositionalLogic1.c -o ImpredictivePropositionalLogic1.exe -std=c99 -Wall -O3 /* Which answer in this list is the correct answer to this question? (a) All of the below. (b) None of the below. (c) All of the above. (d) One of the above. (e) None of the above. (f) None of the above. */ #include &lt;stdio.h&gt; #define iff(x, y) ((x)==(y)) int main() { printf("a b c d e f\n"); for (int a = 0; a &lt;= 1; a++) for (int b = 0; b &lt;= 1; b++) for (int c = 0; c &lt;= 1; c++) for (int d = 0; d &lt;= 1; d++) for (int e = 0; e &lt;= 1; e++) for (int f = 0; f &lt;= 1; f++) { int Ra = iff(a, b &amp;&amp; c &amp;&amp; d &amp;&amp; e &amp;&amp; f); int Rb = iff(b, !c &amp;&amp; !d &amp;&amp; !e &amp;&amp; !f); int Rc = iff(c, a &amp;&amp; b); int Rd = iff(d, (a &amp;&amp; !b &amp;&amp; !c) || (!a &amp;&amp; b &amp;&amp; !c) || (!a &amp;&amp; !b &amp;&amp; c)); int Re = iff(e, !a &amp;&amp; !b &amp;&amp; !c &amp;&amp; !d); int Rf = iff(f, !a &amp;&amp; !b &amp;&amp; !c &amp;&amp; !d &amp;&amp; !e); int R = Ra &amp;&amp; Rb &amp;&amp; Rc &amp;&amp; Rd &amp;&amp; Re &amp;&amp; Rf; if (R) printf("%d %d %d %d %d %d\n", a, b, c, d, e, f); } return 0; } </code></pre> <p>This outputs:</p> <pre><code>a b c d e f 0 0 0 0 1 0 </code></pre> <p>The main point I'd like to get across is that you <em>cannot</em> assume at the outset that there is only 1 satisfying assignment. For example consider the question:</p> <pre><code>Which of the following is true? (a) both of these (b) both of these </code></pre> <p>You might be tempted to say that both (a) and (b) are true. But it is also consistent that both (a) and (b) are false. The tendency to assume singularity from definitions isn't correct when the definitions are impredictive.</p>
<p>"6 denies 5 but not vice versa, so 5 cannot be true." This is the incorrect statement. You are right that 5 does not deny 6, but neither does it affirm 6, so this does not rule out 5. Rather, if 6 holds, then 5 holds a fortiori, but this is a contradiction since 6 denies 5. So 6 is ruled out, and 5 is the only possible answer.</p> <p>Edit: Note that this approach does not assume that only one answer is correct! I argue above that 6 cannot be true. The OP argues quite clearly that 1, 3, and 4 cannot be true. I might revise the OP's discussion of 2 as follows: if 2 holds, then 4 is false. If we take 4 to mean "at least one of the above," this is already a contradiction. If we take 4 to mean "exactly one of the above," then since 3 is false (by 2), 1 must be true, also a contradiction. So we have shown separately that 1, 2, 3, 4, and 6 produce contradictions. Thus, a posteriori there is at most one correct answer, although this was never assumed. In fact, there is exactly one, since if 5 were false, at least one of the contradictory statements above it would hold.</p>
differentiation
<p>This question has been bothering me for quite a while and I still haven't found a satisfying answer anywhere on the internet or in any of my books (which may not be <em>that</em> advanced, mind you...). Since I couldn't find a similar question here on MSE, it probably is rather obvious if you have a sufficiently advanced level, which I do not (I'm still undergraduate and my knowledge of tensors is really small!). Out of simplicity, I'll take a specific example for my question. Here it is:</p> <p>Let $f : \mathbb{R}^2 \rightarrow \mathbb{R}$ ; $(x,y) \rightarrow f(x,y)$ be a continous function with two variables $x$ and $y$.</p> <p>The "equivalent" of the first derivative known from single-variable functions would be the gradient:</p> <p>$\nabla f = \left(\begin{array}{cccc} f_x \\ f_y \end{array}\right)$</p> <p>The second derivative is the Hessian-Matrix: $H_f(x,y) = \left(\begin{array}{cccc} f_{xx} &amp; f_{xy} \\ f_{yx} &amp; f_{yy} \end{array}\right)$</p> <p>So what does the third-order derivative of this function (or in general...) look like? I've been able to work out that it is a tensor with order $3$. How does one notate such a geometric object? </p> <p>Concerning the properties: the gradient is a vector field depicting the "slope" of the function in any point using a vector (i.e.: an orientation and a magnitude). The Hessian-Matrix shows us the rate of change of the gradient (correct use of words?). So by this analogy, the third derivative measures the rate of change of the second derivative. But how?</p> <p>Feel free to change the tags and edit my answer, if you think it necessary. I'm looking forward to any answers!</p> <p>Thanks in advance, SDV</p>
<p>I have written a somewhat eccentric course on this, which can be found here:</p> <p><a href="http://ximera.osu.edu/course/kisonecat/m2o2c2/course/activity/week1/" rel="noreferrer">http://ximera.osu.edu/course/kisonecat/m2o2c2/course/activity/week1/</a></p> <p>A short answer to your question, though, is that if $f:\mathbb{R}^n \to \mathbb{R}$, then $D^{k+1} f$ is a locally a $(k+1)$-linear function with the property that</p> <p>$$ D^{k}f\big|_{p+v_{k+1}}(v_1,v_2,...,v_k) \approx D^{k}f\big|_{p}(v_1,v_2,...,v_k) +D^{k+1}\big|_{p}(v_1,v_2,...,v_k,v_{k+1}) $$ </p> <p>In other words, the $(k+1)$ derivative measures changes in the $k$ derivative.</p> <p>To write things out in a basis, in Einstein notation, we have</p> <p>$$D^k f = f_{i_1i_2...i_k} dx^{i_1} \otimes dx^{i_2} \otimes ... \otimes dx^{i_k}$$</p> <p>where $f_{i_1i_2...i_k}$ is the higher partial derivative of $f$ with respect to $x_{i_1}$ then $x_{i_2}$, etc.</p> <p>I should note that the multivariable Taylor's theorem becomes especially easy to write down using this formalism:</p> <p>$$ f(x+h) = f(x)+Df\big|_x (h)+\frac{1}{2!} D^2 f\big|_x (h,h)+\frac{1}{3!} D^3 f\big|_x (h,h,h)+... $$</p> <p>This may also illuminate the presence of $\frac{1}{k!}$ in Taylor's theorem: it arises from the $k!$ permutations of the arguments.</p>
<p>The gradient is not the real equivalent, even though many texts treat it as if it is.</p> <p>The <em>derivative</em> of a function $f:\mathbb{R}^n\to\mathbb{R}$ at a point $p\in\mathbb{R}^n$ is a $1$-tensor, which means that it eats a vector and spits out a number. More specifically, the thing is obtaining a function $I\to\mathbb{R}$, where $I$ is an open segment in $\mathbb{R}$, and then differentiate it. So given a point $p\in\mathbb{R}^n$ and a "direction" $v\in\mathbb{R}^n$ we define $g_{p,v}:(-\epsilon,\epsilon)\to\mathbb{R}$ by $t\mapsto f(p+tv)$, and then: $$df_p(v)=g_{p,v}'(0).$$ So as claimed above, the $1$-tensor $df_p$ eats a vector ($v$, the direction), and returns a number (the corresponding directional derivative). Since $df_p$ is a linear transfomation $\mathbb{R}^n\to\mathbb{R}$, the appropriate matrix to represent it is a row vector (rather than a column vector).</p> <p>The <em>second derivative</em> is a $2$-tensor, i.e. it eats two vectors. The procedure is as follows: given a point $p\in\mathbb{R}^n$ and two directions $u,v\in\mathbb{R}^n$ we first define $h_{p,u,v}:(-\epsilon,\epsilon)\to\mathbb{R}$ by $t\mapsto df_{p+tu}(v)$, and then (using $d^2f_p$ for the second derivative tensor) $$d^2f_p(u,v)=h_{p,u,v}'(0).$$ Since $d^2f_p$ is nothing but a <em>bilinear form</em>, it can be represented by a $n\times n$ matrix.</p> <p>The higher derivatives are defined analogously, and yes, the $m$th derivative is a $m$-tensor, which means one gives it $m$ directions and it returns a number. It can be represented (if we insist) by an $m$ dimensional matrix $n\times n\times\ldots\times n$.</p>
linear-algebra
<p>Consider the class of rational functions that are the result of dividing one linear function by another:</p> <p>$$\frac{a + bx}{c + dx}$$</p> <p>One can easily compute that, for $\displaystyle x \neq \frac cd$ $$\frac{\mathrm d}{\mathrm dx}\left(\frac{a + bx}{c + dx}\right) = \frac{bc - ad}{(c+dx)^2} \lessgtr 0 \text{ as } ad - bc \gtrless 0$$ Thus, we can easily check whether such a rational function is increasing or decreasing (on any connected interval in its domain) by checking the determinant of a corresponding matrix</p> <p>\begin{pmatrix}a &amp; b \\ c &amp; d\end{pmatrix}</p> <p>This made me wonder whether there is some known deeper principle that is behind this connection between linear algebra and rational functions (seemingly distant topics), or is this probably just a coincidence?</p>
<p>I'll put it more simply. If the determinant is zero, then the linear functions $ax+b$ and $cx+d$ are rendered linearly dependent. For a pair of monovariant functions this forces the ratio between them to be a constant. The zero determinant condition is thereby a natural boundary between increasing and decreasing functions.</p>
<p>What you are looking at is a <a href="https://en.wikipedia.org/wiki/M%C3%B6bius_transformation" rel="noreferrer">Möbius transformation</a>. The relationship between matrices and these functions are given in some detail in the Wikipedia article. Most of this is not anything that I know much about, perhaps another responder will give better details.</p> <p>What you can find is that the composition of two of these functions corresponds to matrix multiplication with the matrix defined as you have inferred from the determinant issue. </p> <p>These are also related to continued fraction arithmetic since a continued fraction just is a composition of these functions. A simple continued fraction is a number $a_0+\frac{1}{a_1 + \frac{1}{a_2 + \cdots}}$ and you can see almost directly that each level of the continued fraction is something like $t+\frac{1}{x} = \frac{tx+1}{x}$ where "x" is "the rest of the continued fraction." Each time we expand a bit more of the continued fraction, we engage in just this composition of functions as above. So Gosper used this relationship to perform term-at-a-time arithmetic of continued fractions. In practice this means representing a continued fraction as a matrix product. </p> <p>For instance, $1+\sqrt{2} = 2 + \frac{1}{2+\frac{1}{2 + \cdots}}$ so you could represent it as $$\prod^{\infty} \pmatrix{2 &amp; 1 \\ 1 &amp; 0}$$ And to find out what $\frac{3}{5}(1+\sqrt{2})$ is you could then calculate, to arbitrary precision, $$\pmatrix{3 &amp; 0 \\ 0 &amp; 5}\times \prod^{\infty} \pmatrix{2 &amp; 1 \\ 1 &amp; 0}$$</p>
geometry
<p>When you draw a circle in a plane you can perfectly surround it with 6 other circles of the same radius. This works for any radius. What's the significance of 6? Why not some other numbers?</p> <p>I'm looking for an answer deeper than "there are $6\times60^\circ=360^\circ$ in a circle, so you can picture it".</p>
<p>The short answer is "because they don't work," but that's kind of a copout. This is actually quite a deep question. What you're referring to is <a href="https://en.wikipedia.org/wiki/Sphere_packing" rel="noreferrer">sphere packing</a> in two dimensions, specifically the <a href="https://en.wikipedia.org/wiki/Kissing_number" rel="noreferrer">kissing number</a>, and sphere packing is actually quite a sophisticated and active field of mathematical research (in arbitrary dimensions). </p> <p>Here's one answer, which isn't complete but which tells you why <span class="math-container">$6$</span> is a meaningful number in two dimensions. The packing you refer to is a special type of packing called a <em>lattice</em> packing, which means it comes from an arrangement of regularly spaced points; in this case, the <a href="https://en.wikipedia.org/wiki/Hexagonal_lattice" rel="noreferrer">hexagonal lattice</a>. The number <span class="math-container">$6$</span> appears here because the hexagonal lattice has <span class="math-container">$6$</span>-fold symmetry. So a natural question might be whether one can find lattices in two dimensions with, say <span class="math-container">$7$</span>-fold or <span class="math-container">$8$</span>-fold symmetry, since these might correspond to circle packings with more circles around a given circle. (Intuitively, we expect more symmetric lattices to give rise to denser packings and to packings where each circle has more neighbors.)</p> <p>The answer is no: <span class="math-container">$6$</span>-fold symmetry is the best you can do! This is a consequence of the <a href="https://en.wikipedia.org/wiki/Crystallographic_restriction_theorem" rel="noreferrer">crystallographic restriction theorem</a>. The generalization of the theorem to <span class="math-container">$n$</span> dimensions says this: it is possible for a lattice to have <span class="math-container">$d$</span>-fold symmetry only if <span class="math-container">$\phi(d) \le n$</span>, where <span class="math-container">$\phi$</span> is <a href="https://en.wikipedia.org/wiki/Euler&#39;s_totient_function" rel="noreferrer">Euler's totient function</a>.</p> <p>The generalization implies that you still cannot do better than <span class="math-container">$6$</span>-fold symmetry in <span class="math-container">$3$</span> dimensions. There are two natural lattice packings in <span class="math-container">$3$</span> dimensions, which <a href="https://en.wikipedia.org/wiki/Hexagonal_close_packing#Fcc_and_hcp_lattices" rel="noreferrer">both occur</a> in molecules and crystals in nature and which both have <span class="math-container">$6$</span>-fold symmetry, and <a href="https://en.wikipedia.org/wiki/Kepler_conjecture" rel="noreferrer">it turns out</a> that these are the densest sphere packings in <span class="math-container">$3$</span> dimensions. It also turns out that they give the correct kissing number in <span class="math-container">$3$</span> dimensions, which is <span class="math-container">$12$</span> (see the wiki article).</p> <p>In <span class="math-container">$4$</span> dimensions, the kissing number is <span class="math-container">$24$</span>, and I believe the corresponding packing is a lattice packing coming from a lattice with <span class="math-container">$8$</span>-fold symmetry, which is possible in <span class="math-container">$4$</span> dimensions. In higher dimensions, only two other kissing numbers are known: <span class="math-container">$8$</span> dimensions, where the <a href="https://en.wikipedia.org/wiki/E8_lattice" rel="noreferrer"><span class="math-container">$E_8$</span> lattice</a> gives kissing number <span class="math-container">$240$</span>, and <span class="math-container">$24$</span> dimensions, where the <a href="https://en.wikipedia.org/wiki/Leech_lattice" rel="noreferrer">Leech lattice</a> gives kissing number <span class="math-container">$196560$</span>! These lattices are really mysterious objects and are related to a host of other mysterious objects in mathematics.</p> <p>A great reference for this stuff, although it is a little dense, is Conway and Sloane's <a href="http://neilsloane.com/doc/splag.html" rel="noreferrer">Sphere Packing, Lattices, and Groups</a> (<a href="http://web.archive.org/web/20190620051530/http://neilsloane.com/doc/splag.html" rel="noreferrer">Wayback Machine</a>). <strong>Edit:</strong> And for a very accessible and engaging introduction to symmetry in the plane and in general, I highly recommend Conway, Burgiel, and Goodman-Strauss's <a href="https://rads.stackoverflow.com/amzn/click/com/1568812205" rel="noreferrer" rel="nofollow noreferrer">The Symmetries of Things</a>.</p>
<p>The question is equivalent to asking why 6 equilateral triangles fit together exactly around a point, with no additional room left over. The answer is "because the Euclidean plane is flat", a condition equivalent to triangles having angle sum of 180 degrees (half the angle around a point), so that each vertex of a symmetrical triangle has 1/3 of half of a full rotation = 1/6. That the six-circle arrangement exists for any radius is also a special feature of Euclidean geometry: scale invariance. </p> <p>For flat surfaces such as a cylinder (rolled up plane) or flat torus (as in the Asteroids video game) the perfect 6-circle configurations exist only for small enough radius of the circles. These geometries are, in small regions, the same as the Euclidean plane but differ "globally", e.g. there is a maximum distance between points of the torus. So the magic number of 6 is really about local flatness (absence of curvature) and having this configuration for circles of all size is a global question about the space in which the circles live. </p> <p>In hyperbolic geometry there are tesselations of the plane by equilateral triangles with angle $180/n$ at each vertex, for any $n \geq 7$. In the picture of the $n=7$ triangular tesselation at <a href="http://www.plunk.org/~hatch/HyperbolicTesselations/3_7_trunc0_512x512.gif">http://www.plunk.org/~hatch/HyperbolicTesselations/3_7_trunc0_512x512.gif</a> (triangles in white with the dual tesselation by heptagons shown in blue) if at each triangle vertex you draw a circle inscribed in its heptagon, there will be 7 circles exactly surrounding each circle, with all circles of the same radius. The same type of configuration exists for any $n$ and suitable radius of the circles. So the flatness condition is necessary; the theorem is false in negatively curved two-dimensional geometry. Six is also not the correct number for spherical geomety, and both spherical and hyperbolic geometry lack a radius-independent "number of circles that fit around one circle".</p> <p>In the geometry of surfaces, having 5-or-fewer as the local number of circles that can be fit around a single circle characterizes positive curvature, as in spherical geometry. Having more-than-6 fit, or extra room when surrounding one circle by six, is a characterization of negative curvature, as in hyperbolic geometry. This is a statement about the local geometry of general 2-dimensional surfaces, and does not assume the surface has the same amount of curvature at all points, as would be the case for the spherical and hyperbolic analogues of Euclidean plane geometry, where there is a homogeneity assumption that "geometry is the same at all points". Having exactly 6 circles fit perfectly is a characterization of locally Euclidean (that is, zero curvature) geometry. If you don't know what curvature is in a technical sense, for purposes of this discussion it is (for surfaces) a number that can be associated to any point on the surface, and curvature being zero in a region of surface is equivalent to the ability to make a distance-preserving planar map of that region. Impossibility of doing this for surfaces of nonzero curvature, such as the sphere which is positively curved, was Gauss' <em>Theorema Egregium</em> which ruled out perfect flat cartography of the Earth.</p> <p>Flatness plays the same role in the higher dimensional, sphere-packing interpretation of the question that Qiaochu suggested. The necessary packings exist only in a limited set of dimensions. The reason is that exactly surrounding a sphere of radius $r$ by $k$ spheres of that radius means more than a kissing number of $k$, the optimal kissing configuration should also be <em>rigid</em> (tight enough that the spheres cannot be moved). Rigidity is false in three dimensions and is believed to be false in most other dimensions but in those cases where it is known or suspected to be true (i.e., dimensions $d = 2, 8, 24$ and possibly a few others) the existence of a configuration with the same set of equalities between various interpoint distances as in the optimal kissing arrangement (in flat Euclidean space $\mathbb{R}^d$)should force a homogeneous $d$-dimensional geometry to be flat. This is because deforming the curvature of the space in the positive direction would reduce, and negative curvature would increase, the freedom to position such spheres around a central sphere.</p>
differentiation
<p><strong>Is a Lipschitz function differentiable?</strong></p> <p>I have been wondering whether or not this property applies to all functions. </p> <blockquote> <p>I do not need a formal proof, just the concept behind it. <br> Let $f: [a,b] \to [c,d]$ be a continuous function (What is more - it is uniformly continuous!) And let's assusme that it's also Lipschitz continuous on this interval. <br></p> </blockquote> <p>Does this set of assumptions imply that $f$ is differentiable on $(a,b)$?</p>
<p>It is not always true indeed, good counterexample could be $x\mapsto |x-a|$. But rather, we have </p> <blockquote> <p><strong>Theorem:</strong> <a href="https://en.wikipedia.org/wiki/Rademacher%27s_theorem" rel="noreferrer">Radamacher theorem</a> says every Lipschitz function is almost everywhere differentiable</p> </blockquote> <p>Fine a nice proof of this theorem here: <a href="https://www.google.de/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=4&amp;ved=0ahUKEwiJ8pu3zuHYAhWNKlAKHRcLDskQFghAMAM&amp;url=https%3A%2F%2Fwww.intfxdx.com%2Fdownloads%2Frademacher-thm-2015.pdf&amp;usg=AOvVaw1KhvqywM_tHERNbdYZVvyC" rel="noreferrer">An Elementary Proof of Rademacher's Theorem - James Murphy</a> or <a href="https://www.google.de/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=7&amp;ved=0ahUKEwiJ8pu3zuHYAhWNKlAKHRcLDskQFghcMAY&amp;url=http%3A%2F%2Fmath.arizona.edu%2F~friedlan%2Fteach%2F553%2Fradem.pdf&amp;usg=AOvVaw0Y60ixNID0CPKXftvfivUA" rel="noreferrer">Here using distribution theory</a>
<p>The function $$x \mapsto \left|x\right|$$ is Lipschitz-continuous (with $k=1$) but not differentiable at $0$.</p>
linear-algebra
<p>If $A,B$ are $2 \times 2$ matrices of real or complex numbers, then</p> <p>$$AB = \left[ \begin{array}{cc} a_{11} &amp; a_{12} \\ a_{21} &amp; a_{22} \end{array} \right]\cdot \left[ \begin{array}{cc} b_{11} &amp; b_{12} \\ b_{21} &amp; b_{22} \end{array} \right] = \left[ \begin{array}{cc} a_{11}b_{11}+a_{12}b_{21} &amp; a_{11}b_{12}+a_{12}b_{22} \\ a_{21}b_{11}+a_{22}b_{21} &amp; a_{22}b_{12}+a_{22}b_{22} \end{array} \right] $$</p> <p>What if the entries $a_{ij}, b_{ij}$ are themselves $2 \times 2$ matrices? Does matrix multiplication hold in some sort of "block" form ?</p> <p>$$AB = \left[ \begin{array}{c|c} A_{11} &amp; A_{12} \\\hline A_{21} &amp; A_{22} \end{array} \right]\cdot \left[ \begin{array}{c|c} B_{11} &amp; B_{12} \\\hline B_{21} &amp; B_{22} \end{array} \right] = \left[ \begin{array}{c|c} A_{11}B_{11}+A_{12}B_{21} &amp; A_{11}B_{12}+A_{12}B_{22} \\\hline A_{21}B_{11}+A_{22}B_{21} &amp; A_{22}B_{12}+A_{22}B_{22} \end{array} \right] $$ This identity would be very useful in my research.</p>
<p>It depends on how you partition it, not all partitions work. For example, if you partition these two matrices </p> <p>$$\begin{bmatrix} a &amp; b &amp; c \\ d &amp; e &amp; f \\ g &amp; h &amp; i \end{bmatrix}, \begin{bmatrix} a' &amp; b' &amp; c' \\ d' &amp; e' &amp; f' \\ g' &amp; h' &amp; i' \end{bmatrix} $$ </p> <p>in this way </p> <p>$$ \left[\begin{array}{c|cc}a&amp;b&amp;c\\ d&amp;e&amp;f\\ \hline g&amp;h&amp;i \end{array}\right], \left[\begin{array}{c|cc}a'&amp;b'&amp;c'\\ d'&amp;e'&amp;f'\\ \hline g'&amp;h'&amp;i' \end{array}\right] $$</p> <p>and then multiply them, it won't work. But this would</p> <p>$$\left[\begin{array}{c|cc}a&amp;b&amp;c\\ \hline d&amp;e&amp;f\\ g&amp;h&amp;i \end{array}\right] ,\left[\begin{array}{c|cc}a'&amp;b'&amp;c'\\ \hline d'&amp;e'&amp;f'\\ g'&amp;h'&amp;i' \end{array}\right] $$</p> <p>What's the difference? Well, in the first case, all submatrix products are not defined, like $\begin{bmatrix} a \\ d \\ \end{bmatrix}$ cannot be multiplied with $\begin{bmatrix} a' \\ d' \\ \end{bmatrix}$</p> <p>So, what is the general rule? (Taken entirely from the Wiki page on <a href="https://en.wikipedia.org/wiki/Block_matrix" rel="noreferrer">Block matrix</a>)</p> <p>Given, an $(m \times p)$ matrix $\mathbf{A}$ with $q$ row partitions and $s$ column partitions $$\begin{bmatrix} \mathbf{A}_{11} &amp; \mathbf{A}_{12} &amp; \cdots &amp;\mathbf{A}_{1s}\\ \mathbf{A}_{21} &amp; \mathbf{A}_{22} &amp; \cdots &amp;\mathbf{A}_{2s}\\ \vdots &amp; \vdots &amp; \ddots &amp;\vdots \\ \mathbf{A}_{q1} &amp; \mathbf{A}_{q2} &amp; \cdots &amp;\mathbf{A}_{qs}\end{bmatrix}$$</p> <p>and a $(p \times n)$ matrix $\mathbf{B}$ with $s$ row partitions and $r$ column parttions</p> <p>$$\begin{bmatrix} \mathbf{B}_{11} &amp; \mathbf{B}_{12} &amp; \cdots &amp;\mathbf{B}_{1r}\\ \mathbf{B}_{21} &amp; \mathbf{B}_{22} &amp; \cdots &amp;\mathbf{B}_{2r}\\ \vdots &amp; \vdots &amp; \ddots &amp;\vdots \\ \mathbf{B}_{s1} &amp; \mathbf{B}_{s2} &amp; \cdots &amp;\mathbf{B}_{sr}\end{bmatrix}$$</p> <p>that are compatible with the partitions of $\mathbf{A}$, the matrix product</p> <p>$ \mathbf{C}=\mathbf{A}\mathbf{B} $</p> <p>can be formed blockwise, yielding $\mathbf{C}$ as an $(m\times n)$ matrix with $q$ row partitions and $r$ column partitions.</p>
<p>It is always suspect with a very late answer to a popular question, but I came here looking for what a compatible block partitioning is and did not find it:</p> <p>For <span class="math-container">$\mathbf{AB}$</span> to work by blocks the important part is that the partition along the columns of <span class="math-container">$\mathbf A$</span> must match the partition along the rows of <span class="math-container">$\mathbf{B}$</span>. This is analogous to how, when doing <span class="math-container">$\mathbf{AB}$</span> without blocks—which is of course just a partitioning into <span class="math-container">$1\times 1$</span> blocks—the number of columns in <span class="math-container">$\mathbf A$</span> must match the number of rows in <span class="math-container">$\mathbf B$</span>.</p> <p>Example: Let <span class="math-container">$\mathbf{M}_{mn}$</span> denote any matrix of <span class="math-container">$m$</span> rows and <span class="math-container">$n$</span> columns irrespective of contents. We know that <span class="math-container">$\mathbf{M}_{mn}\mathbf{M}_{nq}$</span> works and yields a matrix <span class="math-container">$\mathbf{M}_{mq}$</span>. Split <span class="math-container">$\mathbf A$</span> by columns into a block of size <span class="math-container">$a$</span> and a block of size <span class="math-container">$b$</span>, and do the same with <span class="math-container">$\mathbf B$</span> by rows. Then split <span class="math-container">$\mathbf A$</span> however you wish along its rows, same for <span class="math-container">$\mathbf B$</span> along its columns. Now we have <span class="math-container">$$ A = \begin{bmatrix} \mathbf{M}_{ra} &amp; \mathbf{M}_{rb} \\ \mathbf{M}_{sa} &amp; \mathbf{M}_{sb} \end{bmatrix}, B = \begin{bmatrix} \mathbf{M}_{at} &amp; \mathbf{M}_{au} \\ \mathbf{M}_{bt} &amp; \mathbf{M}_{bu} \end{bmatrix}, $$</span></p> <p>and <span class="math-container">$$ AB = \begin{bmatrix} \mathbf{M}_{ra}\mathbf{M}_{at} + \mathbf{M}_{rb}\mathbf{M}_{bt} &amp; \mathbf{M}_{ra}\mathbf{M}_{au} + \mathbf{M}_{rb}\mathbf{M}_{bu} \\ \mathbf{M}_{sa}\mathbf{M}_{at} + \mathbf{M}_{sb}\mathbf{M}_{bt} &amp; \mathbf{M}_{sa}\mathbf{M}_{au} + \mathbf{M}_{sb}\mathbf{M}_{bu} \end{bmatrix} = \begin{bmatrix} \mathbf{M}_{rt} &amp; \mathbf{M}_{ru} \\ \mathbf{M}_{st} &amp; \mathbf{M}_{su} \end{bmatrix}. $$</span></p> <p>All multiplications conform, all sums work out, and the resulting matrix is the size you'd expect. There is nothing special about splitting in two so long as you match any column split of <span class="math-container">$\mathbf A$</span> with a row split in <span class="math-container">$\mathbf B$</span> (try removing a block row from <span class="math-container">$\mathbf A$</span> or further splitting a block column of <span class="math-container">$\mathbf B$</span>).</p> <p>The nonworking example from the accepted answer is nonworking because the columns of <span class="math-container">$\mathbf A$</span> are split into <span class="math-container">$(1, 2)$</span> while the rows of <span class="math-container">$\mathbf B$</span> are split into <span class="math-container">$(2, 1)$</span>.</p>
linear-algebra
<p>I'm getting started learning engineering math. I'm really interested in physics especially quantum mechanics, and I'm coming from a strong CS background.</p> <p>One question is haunting me. </p> <p>Why do I need to learn to do complex math operations on paper when most can be done automatically in software like Maple. For instance, as long as I learn the concept and application for how aspects of linear algebra and differential equations work, won't I be able to enter the appropriate info into such a software program and not have to manually do the calculations?</p> <p>Is the point of math and math classes to learn the big-picture concepts of how to apply mathematical tools or is the point to learn the details to the ground level?</p> <p>Just to clarify, I'm not trying to offend any mathematicians or to belittle the importance of math. From CS I recognize that knowing the deep details of an algorithm can be useful, but that is equally important to be able to work abstractly. Just trying to get some perspective on how to approach the next few years of study.</p>
<blockquote> <p>Is the point of math and math classes to learn the big-picture concepts of how to apply mathematical tools or is the point to learn the details to the ground level?</p> </blockquote> <p>Both. One is difficult without the other. How are you going to solve equations that Maple can't solve? How are you going to solve it, exactly or numerically? What's the best way to solve something numerically? How can you simplify the problem to get an approximate answer? How are you going to interpret Maple's output, and any issues you have with its solution? How can you simplify the answer it gives you? What if you are only interested in the problem for a particular set of values/parameters/in a particular range? What happens if a parameter is small? How many solutions are there? Does a solution even exist? </p> <p>Using a CAS without knowing the background maths behind the problems you're trying to solve is like punching the buttons on a calculator without knowing what numbers are, what the operations mean or what the order of operations might be. </p>
<blockquote> <p>Is the point of math and math classes to learn the big-picture concepts of how to apply mathematical tools or is the point to learn the details to the ground level?</p> </blockquote> <p>I will second Bennett, the point is both. Consider the analogy that learning mathematics and physics is much like constructing maps. First, you will see maps others have created, how details are crafted, norms, what are usual rules, what are the great maps for certain regions. This is the highview.</p> <p>However, you must be sure these maps are correct. Therefore, you'll go to the places they give you directions to and check if it matches. This is the ground level. You have to make sure you are following instructions correctly, arriving at the same results, be able to walk yourself through the path.</p> <p>It's the only way you have a firm, solid, sharp knowledge of anything you study. Learning how to switch between the bird's-eye view and sniffing the ground is part of the apprenticeship of anyone in science.</p> <p>I will end this answer with a quote from <a href="http://en.wikipedia.org/wiki/Richard_Hamming">Richard Hamming</a>:</p> <blockquote> <p><em>The purpose of computing is insight, not numbers.</em></p> </blockquote>
linear-algebra
<p>Suppose I have a $n\times n$ matrix $A$. Can I, by using only pre- and post-multiplication by permutation matrices, permute all the elements of $A$? That is, there should be no binding conditions, like $a_{11}$ will always be to the left of $a_{n1}$, etc.</p> <p>This seems to be intuitively obvious. What I think is that I can write the matrix as an $n^2$-dimensional vector, then I can permute all entries by multiplying by a suitable permutation matrix, and then re-form a matrix with the permuted vector.</p>
<p>It is not generally possible to do so.</p> <p>For a concrete example, we know that there can exist no permutation matrices <span class="math-container">$P,Q$</span> such that <span class="math-container">$$ P\pmatrix{1&amp;2\\2&amp;1}Q = \pmatrix{2&amp;1\\2&amp;1} $$</span> If such a <span class="math-container">$P$</span> and <span class="math-container">$Q$</span> existed, then both matrices would necessarily have the same rank.</p>
<p>Let me add one more argument:</p> <p>For <span class="math-container">$n \ge 2$</span>:</p> <p>Suppose the entries in the <span class="math-container">$n \times n$</span> matrix <span class="math-container">$A$</span> are all distinct. Then there are <span class="math-container">$(n^2)!$</span> distinct permutations of <span class="math-container">$A$</span>.</p> <p>There are <span class="math-container">$n!$</span> row-permutations of <span class="math-container">$A$</span> (generated by premultiplication by various permutation matrices), and <span class="math-container">$n!$</span> col-permutations of <span class="math-container">$A$</span> (generated by post-multiplication by permutation matrices). If we consider <em>all</em> expressions of the form <span class="math-container">$$ RAC $$</span> where <span class="math-container">$R$</span> and <span class="math-container">$C$</span> each range independently over all <span class="math-container">$n!$</span> permutation matrices, we get at most <span class="math-container">$(n!)^2$</span> possible results. But for <span class="math-container">$n &gt; 1$</span>, we have <span class="math-container">\begin{align} (n!)^2 &amp;= [ n \cdot (n-1) \cdots 2 \cdot 1 ] [ n \cdot (n-1) \cdots 2 \cdot 1 ] \\ &amp;&lt; [ 2n \cdot (2n-1) \cdots (n+2) \cdot (n+1) ] [ n \cdot (n-1) \cdots 2 \cdot 1 ] \\ &amp;= (2n)! \\ &amp;\le (n^2)! \end{align}</span> because <span class="math-container">$2n \le n^2$</span> for <span class="math-container">$n \ge 2$</span>, and factorial is an increasing function on the positive integers. So the number of possible results of applying row- and col-permutations to <span class="math-container">$A$</span> is smaller than the number of possible permutations of the elements of <span class="math-container">$A$</span>. Hence there's some permutation of <span class="math-container">$A$</span> that does not appear in our list of all <span class="math-container">$RAC$</span> matrices.</p> <p>BTW, just to close this out: for <span class="math-container">$1 \times 1$</span> matrices, the answer is &quot;yes, all permutations can in fact be realized by row and column permutations.&quot; I suspect you knew that. :)</p> <p>PS: Following the comment by @Jack M, I want to make clear why it's OK to consider only things of the form <span class="math-container">$RAC$</span>. Why do we do the column permutations first, and then the rows? (Or vice-versa, if you read things the other way). What if interleaving row and column permutations does something funky? The answer is that if you do a bunch of row ops interleaved with a bunch of column ops, you get the same thing as if you do all the row-ops first, and then all the column ops afterwards (although the row ops have to come in the same order in this rearrangement, and similarly for the column ops). That requires a little proof, but nothing hairy.</p> <p>What if we do more than one row-permutation, say, two of them? Don't we have to look at <span class="math-container">$R_1 R_2 A C$</span> instead? Answer: <span class="math-container">$R_1 R_2$</span> will again be a permutation matrix, so we can really consider this as being <span class="math-container">$(R_1 R_2) A C$</span>, i.e. the matrix I've called <span class="math-container">$R$</span> is the product of any number of permutation matrices. And it will always be a matrix with one <span class="math-container">$1$</span> in each row and each column. So my counting of possible row-permutations is still valid.</p>