Set of commuting Matrices $\Rightarrow $ Common Eigenvector
How do I prove that in every commuting family there is a common eigenvector?
Fastest way to clamp a real (fixed/floating point) value? Is there a more efficient way to clamp real numbers than using if statements or ternary operators? I want to do this both for doubles and for a 32-bit fixpoint implementation (16.16). I'm not asking for code that can handle both cases; they will be handled in separate functions.  Obviously, I can do something like:  double clampedA; double a = calculate(); clampedA = a &gt; MY_MAX ? MY_MAX : a; clampedA = a &lt; MY_MIN ? MY_MIN : a;   or  double a = calculate(); double clampedA = a; if(clampedA &gt; MY_MAX)     clampedA = MY_MAX; else if(clampedA &lt; MY_MIN)     clampedA = MY_MIN;   The fixpoint version would use functions/macros for comparisons.  This is done in a performance-critical part of the code, so I'm looking for an as efficient way to do it as possible (which I suspect would involve bit-manipulation)   EDIT: It has to be standard/portable C, platform-specific functionality is not of any interest here. Also, MY_MIN and MY_MAX are the same type as the value I want clamped (doubles in the examples above). Converting from 7-speed to 10-speed rear wheel My Bridgestone MB-5 currently has a 7-speed rear wheel. I'd like to convert it to a 10-speed. Is this possible? Is it practical? Should an off-topic question always be downvoted? The upvote tooltip says:      This question shows research effort; it is useful and clear.   The downvote tooltip says:      This question does not show any research effort; it is unclear or not useful.   Sometimes, a question can show research effort, be useful, be clear, but just not in the good place. Voting to close the question and downvoting seems like a double penalty.  Should an off-topic question always be downvoted ? Let $V$ be an n-dimensional vector space over $\mathbb{R}$ and $T:V \rightarrow V$ be linear. Call a vector $v \in V$ cyclic if $V$ is spanned by $\{v, \ Tv, \ T^2v,..\}$.  Question:  Show that $v$ is cyclic for $T$ then there is some $k \geq 1$ such that   $$B=\{v, \ Tv,..T^{k-1}v \}$$ is linearly independent in $V$ and that $T^kv$ lies in  the span of $B$.  Thoughts:  If we suppose that no such $k$ exists, then every subset of the form $\{v, \ Tv,..T^{l-1}v \}$ is linearly dependent, or it is linearly dependent with $T^lv$ not lying in it span.  There are in effect then two cases to consider.  Suppose every subset of the form $\{v, \ Tv,..T^{l-1}v \}$ is linearly dependent. Then $T^{l-1}$ can be expressed as a linear combination of $v,...,T^{l-2}v$. Now, $\{v, \ Tv,..T^{l-2}v \}$ is also linearly dependent by assumption and so we can express $T^{l-2}$ as a linear combination of  $v,...,T^{l-3}v$ etc... Continuing in this way, we show that $T^{l-1}v= \lambda v$ for some $\lambda \in \mathbb{R}$. Thus $$B=\{ \mu v \ | \ \mu \ \text{is an eigenvalue of} \ T^mv \ \text{for some} \ m \}$$ This is 'at best' countably infinite, and therefore could not span $V$ even if it were 1-dimensional, wince our base field is $\mathbb{R}$, which is uncountable.  Suppose then that $B$ is linearly independent for some $k$ but that $T^kv$ does not lie in its span. I can't see how to progress this argument.  Note: This question is for second year Undergraduates, and I think there must be some more simple approach; even the first part surprises me if we need to argue using the uncountability of $\mathbb{R}$, so any alternative approaches are also appreciated. Points at integer distance How many points can one can place in $\mathbb{R}^n$, with the requirement that no $n+1$ points lie in the same $\mathbb{R}^{n-1}$-plane, and the euclidean distance between every two points is an integer? How to flatten a non-planar face to a targeted plane? Let's take a non-planar quad here for a simple example, how to only move one vertex on it, to finally make it planar while keeping the other three vertices still? Let $x,y,z&gt;0$: Prove that:   $\frac{1}{(x+2y)^2}+\frac{1}{(y+2z)^2}+\frac{1}{(z+2x)^2} \geq\frac{1}{xy+yz+zx}$  I tried to apply Cauchy - Schwarz's inequality but I couldn't prove this inequality! Why is the following C# code not allowed:  public abstract class BaseClass {     public abstract int Bar { get;} }  public class ConcreteClass : BaseClass {     public override int Bar     {         get { return 0; }         set {}     } }      CS0546 'ConcreteClass.Bar.set': cannot override because 'BaseClass.Bar' does not have an overridable set accessor lists Ubuntu 4.10 (Warty Warthog) as the first Ubuntu released by Canonical Ltd.  But I wanted to know whether there ever was an Ubuntu 1.x, as in Windows or Mac OS. If yes, is it available somewhere? Central limit theorem and the law of large numbers I have a very beginner's question regarding the Central Limit Theorem (CLT):  I am aware that the CLT states that a mean of i.i.d. random variables is approximately normal distributed (for $n \to \infty$, where $n$ is the index of the summands) or the standardized random variable would have a standard normal distribution.  Now the Law of Large Number states roughly speaking that the mean of i.i.d random variables converges (in probability or almost surely) to their expected value.  What I don't understand is: If, as the CLT states, the mean is approximately normally distributed, how then can it also converge to the expected value at the same time?   Convergence would imply for me that with time the probability that the mean takes a value which is not the expected value is almost zero, hence the distribution would not really be a normal but almost zero everywhere except at the expected value.  Any explanation is welcome. According to my text book:  The Lorentz Force F on a charged particle moving in an electromagnetic field is given by:  $$F= qE + q(v\times B)$$  then it states that "it is to be pointed out that only the electric force does work, while the no work is done by the magnetic force which is simply a deflecting force."  How can this by true won't the the magnetic force have a considerable magnitude, will it now impart kinetic energy to the charge? Any explanations will help a lot. Please keep the terminology simple, thanks. Which word to use when we ask for help?  Some conditions:     We know that the person asked is able to do it. We don't know if the person asked is able to do it. Last minute flight bookings - better to book online or at the airport? We had , which covered ground on what happens to flight prices over the period.  What I'm interested to know is if I had to fly out at short notice, say within 1-2 days, then am I better off booking within that 1-2 day gap online, or am I better off trying my luck directly at the airport (as long as I'm willing to wait at the airport) for a cheaper price? Is there any truth to rumours that airlines sell tickets at cheaper prices at the airport right before flights to fill empty seats or is that a myth? Introductory Calculus textbook for physics? How to make a cyclorama I can create a collection of pictures giving a 360-degree view from a certain spot, just taking a bunch of photographs from the same spot but in a different direction.  However, what software could I use (on Windows) to stitch these images together to get one big image?  I prefer something that would stitch them together without showing any seams. Python provides the "*" operator for unpacking a list of tuples and giving them to a function as arguments, like so:  args = [3, 6] range(*args)            # call with arguments unpacked from a list   This is equivalent to:  range(3, 6)   Does anyone know if there is a way to achieve this in PHP? Some googling for variations of "PHP Unpack" hasn't immediately turned up anything.. perhaps it's called something different in PHP? Sorry to start a subjective question, but want to understand "own.sty" file.  Other than all \usepackage{} what sort of other commands can be added to the makeyourown.sty file.  Can you include \let command, and \newcommands in it.   What sort of precaution / structure newbies should follow. I'm having trouble with the exercise in the title, even with part (a), which asks to prove that if $X$ is a closed subset of $\mathbb{P}^n_k$ of dimension at least 1 and $H$ is a non-empty hypersurface, then $X$ and $H$ meet.   Following the hint, I've done the following: By assumption, $X$ is given by $V(I)$ for some homogenous prime ideal $I\subset k[x_0,\dots x_n]=:A$ and $H$ by $V(f)$ for some homogenous polynomial $f\in A$. We wish to prove that there is a homogenous prime ideal $\mathfrak{p}$ (that's not the irrelevant one) containing both $I$ and $f$.  Consider the affine cone $\mathrm{Spec}\ A/I$ of $X$ in $\mathrm{Spec}\ A$. Being homogenous, both $I$ and $f$ are contained in the ideal $(x_0,\dots x_n)$. By Krull's principal ideal theorem, every minimal prime ideal containing $f\mod I$ has codimension one. $X$ having dimension at least one implies that there are homogenous prime prime ideals $\mathfrak{q}\supsetneq \mathfrak{r}\supset I$. This implies that $(x_o,\dots x_n)$ has codimension at least two. Thus there are prime ideals containing $f\mod I$ that are contained in $(x_o,\dots x_n)$. However, I'd need to show that there are homogenous such prime ideals, right? I'd rather get hints than full solutions. What is the difference between confidence intervals and hypothesis testing? I have read about   with some commentators suggesting that hypothesis testing should not be used. Some commentators suggest that confidence intervals should be used instead.    What is the difference between confidence intervals and hypothesis testing? Explanation with reference and examples would be appreciated. How to find out the terminal command of an application? I want to use some applications shown on the Unity Launcher in a terminal, but I need to know the appropriate command to run them. How can I achieve that?