Get the identifier
Set String via String.prototype function without return
Detecting Color of iPhone/iPad/iPod touch? How exactly was the finalist chosen in the NIST AES competition? Calculate $\int_{0}^{1} (x-f(x))^{2016} dx$, given $f(f(x))=x$. How to install MATLAB on Ubuntu 14.04? A question about E12 series resistors I'm trying to calculate E12 resistor series myself.  Above is an illustration of the idea where such equation can be written:  x = r3 + r3 * %tol = r4 - r4 * %tol  form that we can derive:  r4 = r3* [(1 + %tol)/(1 - %tol)]  hence in generalized form we can write (%tol = 0.1 for E12 series);   r(i+1) = ri* [(1 + %tol)/(1 - %tol)]  But when I iterate the above formula in a for loop I obtain the following results for the first resistor values:  1.0000    1.2222    1.4938    1.8258    2.2315    2.7274    3.3335    4.0743    4.9797    6.0863    7.4388  Then I take [(1 + %tol)/(1 - %tol)] = 1.2 rounded value instead of 1.222222 and write the formula as:  r(i+1) = r(i)*1.2  But again when I iterate the above formula in a for loop I obtain the following results for the first resistor values:  1.0000    1.2000    1.4400    1.7280    2.0736    2.4883    2.9860    3.5832    4.2998    5.1598    6.1917  But the real values for E12 should be as:  1.0, 1.2, 1.5, 1.8, 2.2, 2.7, 3.3, 3.9, 4.7, 5.6, 6.8  What am I doing wrong here? How often do you have to roll a 6-sided die to obtain every number at least once? I've just played a game with my kids that basically boils down to: whoever rolls every number at least once on a 6-sided die wins.  I won, eventually, and the others finished 1-2 turns later. Now I'm wondering: what is the expectation of the length of the game?  I know that the expectation of the number of rolls till you hit a specific number is  $\sum_{n=1}^\infty n\frac{1}{6}(\frac{5}{6})^{n-1}=6$.  However, I have two questions:   How many times to you have to roll a six-sided die until you get every number at least once?  Among four independent trials (i.e. with four players), what is the expectation of the maximum number of rolls needed? [note: it's maximum, not minimum, because at their age, it's more about finishing than about getting there first for my kids]   I can simulate the result, but I wonder how I would go about calculating it analytically.    Here's a Monte Carlo simulation in Matlab  mx=zeros(1000000,1); for i=1:1000000,    %# assume it's never going to take us &gt;100 rolls    r=randi(6,100,1);    %# since R2013a, unique returns the first occurrence    %# for earlier versions, take the minimum of x    %# and subtract it from the total array length    [~,x]=unique(r);     mx(i,1)=max(x); end  %# make sure we haven't violated an assumption assert(numel(x)==6)  %# find the expected value for the coupon collector problem expectationForOneRun = mean(mx)  %# find the expected number of rolls as a maximum of four independent players maxExpectationForFourRuns = mean( max( reshape( mx, 4, []), [], 1) )  expectationForOneRun =    14.7014 (SEM 0.006)  maxExpectationForFourRuns =    21.4815 (SEM 0.01) Does Facebook allow a user to give my app access to their friends email addresses? The intuition I have for why quantum computing can perform better than classical computing is that the wavelike nature of wavefunctions allow you to interfere multiple states of information with a single operation, which theoretically could allow for exponential speedup.   But if it really is just constructive interference of complicated states, why not just perform this interference with classical waves?  And on that matter, if the figure-of-merit is simply how few steps something can be calculated in, why not start with a complicated dynamical system that has the desired computation embedded in it. (ie, why not just create "analog simulators" for specific problems?) When should \cdot be used to indicate multiplication? Is this purely personal style, or are the generally accepted guidelines? Clearly, when dealing with numbers either $2 \cdot 2$ or $2 \times 2$ is needed, but within formulae where an absence of an operator implies multiplication, when should a \cdot be used? I tend to use it only sparingly if it aids in grouping. (Of course, barring the cases where it's required, e.g. a dot product.) Dragging layer into new file changes its size Let's say I have a file that's 4'x12' and represents a space on an actual wall. I want to open certain files (of different sizes) and drag each file into the large file in order to arrange the images correctly on the computer before physically hanging the framed finals.  When I drag a new image into the larger file, the new image's size and the size of its copy don't match. That is, Say I drag an 8x10 into the large file, well on the large file (trying to control size with guides and rulers) the new image is some other size, but not the right one.   What am I doing wrong? How do I make sure that when I click and drag the new image that it will be properly represented? Let $H$, $K$ be subgroups of $G$. Prove that $o(HK) = \frac{o(H)o(K)}{o(H \cap K)}$.  I need this theorem to prove something. May $y=e^x$ be satisfied with both $x$ and $y$ be positive integers?  I think it is not possible as $e$ ,a transcendental number, when multiplied by itself would never result in rational number.  Am I right? I'm trying to prove that the converse of Lagrange's theorem is true for finite abelian groups (i.e. "given an abelian group $G$ of order $m$, for all positive divisors $n$ of $m$, $G$ has a subgroup of order $n$"). This is an exercise from a book, and it is in the section on finite abelian groups, so I know I have to use the fundamental theorem of finite abelian groups. I have come up with a proof, but it seems a bit messy, and I'm not entirely sure if it's correct. It is given below.     Let the order of $G$ be $m$ = $p_1^{\alpha_1} \ldots p_k^{\alpha_k}$. It is known that $G$ is a direct product of $p$-groups, say:      $$G = G_1 \times \ldots \times G_k$$      where each $G_i$ is a $p_i$-group. By the fundamental theorem of finite abelian groups, each $G_i$ is isomorphic to a direct product of cyclic groups of the form      $$\mathbb{Z}_{{p_i}^{\beta_1}} \times \ldots \times \mathbb{Z}_{{p_i}^{\beta_l}},$$      where $\beta_1, \ldots, \beta_l$ are positive integers such that $\sum_{j=1}^l \beta_j = \alpha_i$. Now if $n$ divides $m$, then we must have      $$n = p_1^{\gamma_1} \ldots p_k^{\gamma_k}$$      for some $\gamma_1, \ldots, \gamma_k$ with $0 \leq \gamma_i \leq \alpha_i$.      Claim: Each $G_i$ has a subgroup of order $p_i^{\gamma_i}$      Proof: As above, we have that       $$ G_i \cong \mathbb{Z}_{{p_i}^{\beta_1}} \times \ldots \times \mathbb{Z}_{{p_i}^{\beta_l}} $$      where $\beta_1, \ldots, \beta_l$ are positive integers such that $\sum_{j=1}^l \beta_j = \alpha_i$.      Now since $0 \leq \gamma_i \leq \alpha_i$, we can find   $l$ numbers $\delta_1, \ldots , \delta_l$ such that $\gamma_i = \sum_{j=1}^l \delta_j$, and $0 \leq \delta_j \leq \beta_j$. (This choice of numbers is not necessarily unique).      Then $p_i^{\delta_j} | p_i^{\beta_j}$ for each $j = 1, \ldots , l$. Hence, for each factor $\mathbb{Z}_{{p_i}^{\beta_j}}$, there exists a subgroup of order $p_i^{\delta_j}$, namely $\mathbb{Z}_{{p_i}^{\delta_j}}$ (using the fact that the converse of Lagrange's theorem is true for finite cyclic groups). Taking the direct product of each of these subgroups, we get a new subgroup $G_i'$ of $G_i$:      $$G_i' \cong \mathbb{Z}_{{p_i}^{\delta_1}} \times \ldots \times \mathbb{Z}_{{p_i}^{\delta_l}}$$      The order of this subgroup is $p_i^{\delta_1} \times \ldots \times p_i^{\delta_l} = p_i^{\delta_1 + \ldots + \delta_l} = p_i^{\gamma_i} $. So we have found a subgroup of $G_i$ of order $p_i^{\gamma_i}$, as required.      So each factor $G_i$ in the product $G = G_1 \times \ldots \times G_k$ has a subgroup $G_i'$ of order $p_i^{\gamma_i}$.       Therefore, $G$ has a subgroup   $$G_1' \times G_2' \times \ldots \times G_k'$$       of order $p_1^{\gamma_i}...p_k^{\gamma_k} = n$, which completes the proof.   I have two questions about this: firstly, does this proof seem to work? Secondly, is there a way to make the proof more concise (e.g. a way to prove the statement without using all these indices)? What can you use Python generator functions for? I'm starting to learn Python and I've come across generator functions, those that have a yield statement in them.  I want to know what types of problems that these functions are really good at solving. Why there is much interest in the study of $\operatorname{Gal}\left(\overline{\mathbb Q}/\mathbb Q\right)$? Java: how to parse double from regex Install software from packages, or build it from source? This is a  about when to use packaged software and when to build and install it yourself.   When should I install software from packages provided by my OS distribution, instead of building and installing it myself from source?  When is it better to build from source? I live in Ethiopia and the government blocks all urls with the word "proxy" in them. I couldn't use that word in the title above because that would make the url contain the word proxy.   When I apt-get upgrade I get errors because some packages like libproxy1, libproxy1-plugin-gsettings, libproxy1-plugin-networkmanager, python-libproxy all contain the p word.  Therefore, it is all blocked. I tried putting the urls into proxy sites, but they all just returned to their home page.   Are there any other solutions? I need to calculate the Cramer Rao lower bound of variance for the parameter $\theta$ of the distribution $$f(x)=\frac{1}{\pi(1+(x-\theta)^2)}$$   How do I proceed I have calculated $$4 E\frac{(X-\theta)^2}{1+X^2+\theta^2-2X\theta}$$  Can somebody help I'm having exactly the same issue as , also using Biber 2.14, albeit I didn't upgrade, downgrade, change TexLive version, change encoding or (seemingly) do anything. It's like Biber suddenly quit parsing dates on me.  Whether the bibfile is encoded in ASCII or UTF-8 makes no difference. Whether the date is a short format or the full YYYY-MM-DD makes no difference. I'm not sure what else to test.  Here's a MWE and the associated .blg file:  \begin{filecontents}{mwe.bib}     @Article{JD2020,         author       = {John Doe},         title        = {A Title},         date         = {2020-01-01},         %date       = {2020}         journaltitle = {Journal},     } \end{filecontents}  \documentclass{article} \usepackage{biblatex} \addbibresource{mwe.bib}  \begin{document}     test\autocite{JD2020}     \printbibliography \end{document}   [1] Config.pm:304&gt; INFO - This is Biber 2.14 [1] Config.pm:307&gt; INFO - Logfile is 'mwe.blg' [154] biber-darwin:322&gt; INFO - === Thu Apr 30, 2020, 11:04:33 [185] Biber.pm:415&gt; INFO - Reading 'mwe.bcf' [354] Biber.pm:943&gt; INFO - Found 1 citekeys in bib section 0 [384] Biber.pm:4256&gt; INFO - Processing section 0 [385] Utils.pm:75&gt; INFO - Globbing data source 'mwe.bib' [385] Utils.pm:91&gt; INFO - Globbed data source 'mwe.bib' to mwe.bib [401] Biber.pm:4455&gt; INFO - Looking for bibtex format file 'mwe.bib' for section 0 [402] bibtex.pm:1653&gt; INFO - LaTeX decoding ... [406] bibtex.pm:1471&gt; INFO - Found BibTeX data source 'mwe.bib' [437] Utils.pm:304&gt; WARN - Entry 'JD2020' (mwe.bib): Invalid format '2020-01-01' of date field 'date' - ignoring [457] UCollate.pm:68&gt; INFO - Overriding locale 'en-US' defaults 'normalization = NFD' with 'normalization = prenormalized' [457] UCollate.pm:68&gt; INFO - Overriding locale 'en-US' defaults 'variable = shifted' with 'variable = non-ignorable' [457] Biber.pm:4084&gt; INFO - Sorting list 'nty/global//global/global' of type 'entry' with template 'nty' and locale 'en-US' [457] Biber.pm:4090&gt; INFO - No sort tailoring available for locale 'en-US' [461] bbl.pm:652&gt; INFO - Writing 'mwe.bbl' with encoding 'UTF-8' [463] bbl.pm:755&gt; INFO - Output to mwe.bbl [463] Biber.pm:128&gt; INFO - WARNINGS: 1   The \printbibliography output actually looks like this: [1] John Doe. “A Title”. In: Journal ().  In my actual thesis, all the dates are gone from the pdf output.