Imagine that I've got a big $N \times N$ boolean matrix (all entries are $0$ or $1$). At the beginning, the matrix is full of zeros.  Then, I execute the following algorithm  Matrix M empty of type N x N while (there is a 0 in M) {     Position pos;     do {         pos = random position in M     } while (pos is 1);     // Here pos is 0     mark pos as 1; }   I want the cost of the previous algorithm (suppose that "there is a $0$ in $M$" has no cost, and that "random position in M" has constant, i.e. $\Theta(1)$, cost).   My intuition says that it is $\Theta(\cdot)$ of $$ 1 + \textrm{Geom}\left(\frac{N^2 -1}{N^2}\right) + \textrm{Geom}\left(\frac{N^2 -2}{N^2}\right) + \cdots + \textrm{Geom}\left(\frac{1}{N^2}\right) $$
What is the average number of times it would it take to roll a fair 6-sided die and get all numbers on the die?  The order in which the numbers appear does not matter.  I had this questions explained to me by a professor (not math professor), but it was not clear in the explanation.  We were given the answer $(1-(\frac56)^n)^6 = .5$ or $n = 12.152$  Can someone please explain this to me, possibly with a link to a general topic?
Is it acceptable to write a thank you in a comment? There have been a number of cases where I would like to thank someone for providing me with a thorough response and give them feedback beyond the vote up. Often I wish people would tell me why they voted me up. Not that the thank you part is necessary but it sets it apart from the other comments related to answering the question itself.  In this type of situation is a "Thank you" acceptable in a comment?     For more information, see  in the . Word for one who likes to share knowledge when asked The "Info" bar on top disappeared and the mouse pointer is misaligned I have a problem with Blenders UI. The "Info" bar on top disappeared and the mouse pointer is misaligned. I reinstalled Blender 2 times, deleted every leftover files  but it still does the same thing. This is in v2.78c. The weird thing is that on the bottom everything works fine. Here are some images: How can I monitor the memory usage? I have used top to see the memory usage at the moment. But I would like to monitor the memory usage over a period of time. E.g start monitoring and then execute a few commands, and final stop the monitoring and see how much memory that have been used during the period.  How can I do this on Ubuntu Server?  I guess I could start a cronjob every 5th second or so, and invoke a command that log the current memory usage in a textfile. But what command should I use to get the current memory usage in a format that is easy to log to a text file? How to remove URI encoding from file names? I realise this might be quite a simple question, but I'm still quite new to the command line and only have a grasp of basic commands.  I've downloaded some lecture presentations (~25 or so) from my University however on doing so they've been named things like...  L2%20Development%20of%20immune%20system.pptx L4%20Molecular%20Recognition.pdf   As you can see they've downloaded with the URL encoding %20 instead of a space.  My question is how to batch rename all of these files so that the %20 is removed and replaced with a space instead? Ubuntu system is broken after accidentally uninstalling many packages How to make a logo where a letter is made of particles of varying sizes? How can I make a logo in Adobe Illustrator like the AntiParticle logo below, from ?   It is a large number circles of different, varying sizes, which form the shape of a text character. Do I need swap space if I have more than enough amount of RAM? From what I understand, the purpose of a swap partition in Linux is to free up some "not as frequently accessed" information from RAM and move it to a specific partition on your harddrive (at the cost of making it slower to read from or write to), essentially allowing active applications more of the "high speed memory".  This is great for when you are on a machine with a small amount of RAM and don't want to run into problems if you run out. However, if your system has 16 GB or 32 GB of RAM, and assuming you aren't running a MySQL database for StackExchange or editing a 1080p full length movie in Linux, should a swap partition be used? Probability of a player winning before another Given a 7 sided dice, 2 players roll it independantly simultaneously and when a player rolls a '6' he gets a prize.  What is the probability of the first player getting a prize before the second?  So my solution is to sum over all the turns j in which player 1 could win, and make the second player lose all these turns:  $$P(A) = \sum_{i=1}^{\infty}(6/7)^{j-1}*(1/7)*(6/7)^j = 0.461$$ My question is if my solution is correct, and if so, why is the probability so low? It seems to me that either player 1 wins before the 2nd or the other way around, and the probability of them playing forever is 0, so it should be 0.5? Why is it dangerous to eat meat which has been left out and then cooked? What does the size of the standard deviation mean? According to  (my emphasis),     In statistics, the standard deviation ... is a measure that is used to quantify the amount of variation or dispersion of a set of data values. A standard deviation close to 0 indicates that the data points tend to be very close to the mean (also called the expected value) of the set, while a high standard deviation indicates that the data points are spread out over a wider range of values.   The purpose of the standard deviation (SD), then, is to tell us how varied or uniform (SD → 0) the data is.  So, given a certain SD, how varied is the data? What does the size of the standard deviation mean?  Please explain the meaning of the SD by interpreting an SD = 1 (M = 0).  If you cannot interpret the size (quantity) of this SD, what other information would you need to be able to interpret it, and how would you interpret it, given that information? Please provide an example.  If, on the other hand, the quantity of the SD cannot be qualified in this manner, my argument is that it is essentially meaningless. If you disagree, please explain the meaning of the SD.  &nbsp;    The following are earlier versions to give context to the answers. Unfortunately these didn't really convey what I wanted, and my attempt to ask it elsewhere was closed. (I don't need these versions answered now):  First revision:  What does the size of the standard deviation mean?  For example, if I want to study human body size and I find that adult human body size has a standard deviation of 2 cm, I would probably infer that adult human body size is very uniform, while a 2 cm standard deviation in the size of mice would mean that mice differ surprisingly much in body size.  Obviously the meaning of the standard deviation is its relation to the mean, and a standard deviation around a tenth of the mean is unremarkable (e.g. for IQ: SD = 0.15 * M).  But what is considered "small" and what is "large", when it comes to the relation between standard deviation and mean? Are there guidelines similar to the ones that Cohen gives for correlations (a correlation of 0.5 is large, 0.3 is moderate, and 0.1 is small)?    Original question:  We always calculate and report means and standard deviations. But what does the size of the variance actually mean?  For example, assume we are observing which seat people take in an empty room. If we observe that the majority of people sit close to the window with little variance, we can assume this to mean that people generally prefer siting near the window and getting a view or enough light is the main motivating factor in choosing a seat. If on the other hand we observe that while the largest proportion sit close to the window there is a large variance with other seats taken often also (e.g. many sit close to the door, others sit close to the water dispenser or the newspapers), we might assume that while many people prefer to sit close to the window, there seem to be more factors than light or view that influence choice of seating and differing preferences in different people.  At what values can we say that the behavior we have observed is very varied (different people like to sit in different places)? And when can we infer that behavior is mostly uniform (everyone likes to sit at the window) and the little variation our data shows is mostly a result of random effects or confounding variables (dirt on one chair, the sun having moved and more shade in the back, etc.)?  Are there guidelines for assessing the magnitude of variance in data, similar to Cohen's guidelines for interpreting effect size (a correlation of 0.5 is large, 0.3 is moderate, and 0.1 is small)?  For example, if 90% (or only 30%) of observations fall within one standard deviation from the mean, is that uncommon or completely unremarkable? We've had a number of instances over on Stack Overflow involving users who get to the reputation level where they can comment, then spam comments across the site. Due to the lack of community review around comments, these spammed comments can remain on the site for months before someone notices and flags one. Moderators then have to go and manually remove each of these comments. In the last few months, I've personally had to deal with two users who spammed their website across 200+ questions each.  This isn't just limited to people spamming comments with a URL in them. We've had a number of users spray the same nonsense comment or insult across tons of posts and have no one seem to notice for months.  What I'd like is some kind of system-generated notification when a user has posted a barrage of copied-and-pasted comments. This could possibly be triggered when a user has posted a set number of identical comments in a row (4 of them, maybe) or maybe even if they've posted the same comment multiple times. We receive similar system-generated flags when users post duplicate answers, edit many of their posts in a row, or delete many of their own posts at a time.  This system-generated flag should ignore comments generated by review (which have the same text in them). I'm thinking that it shouldn't ignore comments generated by custom off-topic reasons, because someone using the exact same close reason over and over again might be something we want to look into.  The flag itself won't do anything to a user, and would only appear to moderators. I imagine there will be a number of false positives, but it should be easy for us to check these and identify the well-intentioned stock comments from the problematic ones.   We currently have no means of detecting comment spam, so even if this didn't have a great hit rate it would still be beneficial on the balance. Running sample queries for this seems to indicate that it wouldn't have that much noise.  This would allow us to catch comment spam early, and prevent it from living on the site or developing into a more serious problem. Non-Metrizable Topological Spaces Is there a word that describes a person who dies on his/her birthdate? I was looking for alternate proofs of the theorem that "a vector space $V$ of dimension greater than $1$ over an infinite field $\mathbf{F}$ is not a union of fewer than $|\mathbf{F}|$ proper subspaces" and possible generalizations.  A simple measure-theoretic proof over $\mathbb{R}$ is as follows: By countable additivity the sum of the measures of any collection of subspaces is zero since the measure of each subspace is zero, which is a contradiction.  I would like to look at proofs over arbitrary infinite fields and would like to know if similar statements hold for say modules (finitely generated or otherwise) over infinite rings. "Everything is a file" in the UNIX World.  Above sentence is famous. When I run echo "hello programmer" &gt;&gt; /dev/tty1 , I can watch the given string on TeleType 1  , ....  What and where is file per each socket? Suppose my friend connects to my PC, and its IP is h.h.h.h , how can I access the respective file? Is it possible? Listing layers from .mxd file using ArcPy for ArcGIS Pro? Keras - no prediction probability for multiple output models? $\sqrt{1-x^2}$ is not a rational function If $k$ is a field in which $1 + 1 \neq 0$, prove that $\sqrt{1-x^2}$ is not a rational function. Hint. Mimic the classical proof that $\sqrt{2}$ is irrational   It seems rather odd to discuss the square root function in the context of an arbitrary field, but here goes nothing!  Proof:   Suppose that $\sqrt{1-x^2}$ is a rational function in $k(x)$. Then there exist polynomials $p(x)$ and $q(x) \neq 0$ that are relatively prime with $\sqrt{1-x^2} = \frac{p(x)}{q(x)}$; clearly we may take $p(x) \neq 0$. Then $1-x^2 = \frac{p(x)^2}{q(x)^2}$ or $q(x)^2(1-x^2) = p(x)^2$, which says $q^2 | p^2$, and since $q | q^2$, we can infer $q | p^2$. Moreover, since $p|p^2$ and $(p,q)=1$, then $pq|p^2$ or $q|p$, which contradicts the fact that the polynomials are relatively prime. Hence $\sqrt{1-x^2}$ cannot be a rational function.    How does this sound? Aside from the problem of discussing $\sqrt{~~}$ in the context of an arbitrary field, I am worried about not using the fact that $1+1 \neq 0$, at least not explicitly. Where exactly is this assumed used, if at all?  EDIT:  Suppose that $q(x) =1$, and let $f(x) = a_n x^n + ... a_1 x + a_0$. Then $1-x^2 = f(x)^2$. If $x=0$, $1 = a^2_0$ and therefore $a_0$ must be a unit. Letting $x=1$ we get $0 = (a_n + ... + a_1 + a_0)^2$; and letting $x=-1$ we get $0 = (-a_n - ... - a_1  + a_0)^2$. Since we are working in a field, there can be no nonzero nilpotent which means that $a_n + ... + a_1 + a_0$ and $-a_n - ... - a_1  + a_0$ are both zero. Adding the two equations together yields $2a_0 = 0$, and since $1+1 \neq 0$, $a_0 = 0$ which contradicts the fact that $a_0$ is a unit.   How does this sound?  Another attemtpt:  If $f(x)^2 = 1-x^2$, then $2 = \deg(f^2) = 2 \deg (f)$ implies $\deg(f) = 1$. Yet if $x=-1$, we get $f(-1)^2 = 1 - 1 = 0$ and therefore $f(-1)=0$ since there are no nonzero nilpotent elements in a field; similarly, $f(1)=0$. Since $1+1 \neq 0$, $f$ has two distinct roots in $k$ yet is only a $1$-st degree polynomial, a contradiction. Irfanview nearest equivalent for linux