Why does my procedure run slowly until I update statistics?
Why does my procedure run slowly until I update statistics?
Redirect everything from old domain to new domain I need to (permanent) redirect all of the following:   www.example.com www.example.com/folder sub.example.com sub.example.com/folder   Basically, all URLs that are reachable without being intended to: www.new-example.com, I want to do this within Apache and using the mod_rewrite module via the .htaccess file. We all know that the amount of current flowing b/w the plates is independent of the frequency. If I were to ask why doesn't it depend then you'd probably say that it depends on the number of electrons rather than the frequency or you might show me a current vs frequency graph.  But here is my theoretical argument. Electric current is defined as the amount of charge flowing through a point/space/wire per unit time. Let I be current due to photo electrons ejected by photons of some frequency. Now if I would increase the frequency, the kinetic energy of the ejected electron would increases, therefore it will move faster and therefore contribute more current (charge will through the same point many times per unit time) . Thereby, giving a net current greater than I.  What is wrong with my argument?  After thinking a lot, I came up with a possible reason. However fast the electrons may move, but when they hit the metal plate, they would lose their velocity and start moving in drift velocity. Now there is a problem with this argument. If this were to be true then I should expect to see a big chunk of extra electrons getting stuck at the anode.  If my reasoning was correct, then why can't I see a big charge buildup at the anode. File changed listener in Java I'd like to be notified when a file has been changed in the file system. I have found nothing but a thread that polls the lastModified File property and clearly this solution is not optimal. Given function $g$ continuous in line $[0,\infty)$, positive and strongly increasing that upholds $\lim_{t\to\infty}  g(t) = L$. Calculate the limit:  $$ \lim_{n\to\infty} \int\limits_1^2 g(nx) \, dx. $$  At the moment what I think that I should do is swap the $g(nx)$ with $L$ as it approaches infinity but from there on I am just not sure whats my next step is. Have you ever had a case where you felt compelled to include strange things like a double that in a sentence? If so, then what did you do to resolve this?  For me, I never knew whether it was acceptable grammar. However, what I did learn was that it was a logic distractor, could lead to confusion, and therefore should be reworded to avoid this. If it was possible to dig a hole that went from one side of the Earth to the other... ...And you jumped in.  What would happen when you got to the middle of the Earth? Would you gradually slow down, until you got to the middle and once you were in middle would every direction feel like it was up? Problem working fontspec, babel and datetime with cyrillic I have discovered that fontspec with russian babel settings doesn't work with datetime package. I tried to compile such code:  \documentclass[a4paper,11pt]{article} \usepackage[T2A]{fontenc} \usepackage[utf8]{inputenc} \usepackage[main=russian,english]{babel} \usepackage{datetime} \usepackage[cm-default]{fontspec}  \begin{document} \today \end{document}   with a xelatex and got an error: Command \cyri unavailable in encoding EU1.  Is there any way to handle it?  UPDATE: I really bungle with charset in XeLateX. Thanks to egreg. I have removed fontenc and inputenc and used some cyrillic font, so my MWE now looks this way:  \documentclass[a4paper,11pt]{article} \usepackage[main=russian,english]{babel} \usepackage{fontspec} \setromanfont{PT Sans} \usepackage{datetime}  \begin{document} \today \end{document}   and I've got another error, if I used russian as a main language in babel: Undefined control sequence. \\monthnamerussian ...cyrm \cyra \cyrya \or \cyri  \cyryu \cyrn \cyrya \or \c...  Is it still because of XeLaTeX? Show that $G$ is cyclic Here is a problem from Herstein.     Let G be a finite abelian group so that the equation $x^n=e$ has at most $n$ solutions in $G$ for every positive integer $n$. Show that $G$ is cyclic.   I will have to basically show that there exists an element $g$ in $G$ having order $o(G)$.   I showed that such an element exists if $o(G)=p_1p_2...p_k$ where $p_i$ are primes. But I could not proceed if $o(G)=p_1^{a_1}p_2^{a_2}$. I feel that if I can prove this I will be able to extend. What techniques are available for collapsing (or pooling) many categories to a few, for the purpose of using them as an input (predictor) in a statistical model?    Consider a variable like  (discipline chosen by an undergraduate student). It is unordered and categorical, but it can potentially have dozens of distinct levels. Let's say I want to use major as a predictor in a regression model.  Using these levels as-is for modeling leads to all sorts of issues because there are just so many. A lot of statistical precision would be thrown away to use them, and the results are hard to interpret. We're rarely interested in specific majors -- we're much more likely to be interested in broad categories (subgroups) of majors. But it isn't always clear how to divide up the levels into such higher-level categories, or even how many higher-level categories to use.  For typical data I would be happy to use factor analysis, matrix factorization, or a discrete latent modeling technique. But majors are mutually exclusive categories, so I'm hesitant to exploit their covariance for anything.  Furthermore I don't care about the major categories on their own. I care about producing higher-level categories that are coherent with respect to my regression outcome. In the binary outcome case, that suggests to me something like linear discriminant analysis (LDA) to generate higher-level categories that maximize discriminative performance. But LDA is a limited technique and that feels like dirty data dredging to me. Moreover any continuous solution will be hard to interpret.  Meanwhile something based on covariances, like multiple correspondence analysis (MCA), seems suspect to me in this case because of the inherent dependence among mutually exclusive dummy variables -- they're better suited for studying multiple categorical variables, rather than multiple categories of the same variable.  edit: to be clear, this is about collapsing categories (not selecting them), and the categories are predictors or independent variables. In hindsight, this problem seems like an appropriate time to "regularize 'em all and let God sort 'em out". Glad to see this question is interesting to so many people! I would like to evaluate the sum  $$\sum_{n=0}^\infty \frac{1}{an^2+bn+c}$$  Here is my attempt:    Letting    $$f(z)=\frac{1}{az^2+bz+c}$$  The poles of $f(z)$ are located at   $$z_0 = \frac{-b+\sqrt{b^2-4ac}}{2a}$$  and  $$z_1 = \frac{-b-\sqrt{b^2-4ac}}{2a}$$  Then  $$ b_0=\operatorname*{Res}_{z=z_0}\,\pi \cot (\pi z)f(z)= \lim_{z \to z_0} \frac{(z-z_0)\pi\cot (\pi z)}{az^2+bz+c}= \lim_{z \to z_0} \frac{\pi\cot (\pi z)+(z_0-z)\pi^2\csc^2 (\pi z)}{2az+b} $$  Using L'Hopital's rule. Continuing, we have the limit is  $$ \lim_{z \to z_0} \frac{\pi\cot (\pi z)+(z_0-z)\pi^2\csc^2 (\pi z)}{2az+b}= \frac{\pi\cot (\pi z_0)}{2az_0+b} $$  For $z_0 \ne 0$  Similarly, we find  $$b_1=\operatorname*{Res}_{z=z_1}\,\pi \cot (\pi z)f(z)=\frac{\pi\cot (\pi z_1)}{2az_1+b}$$  Then   $$\sum_{n=-\infty}^\infty \frac{1}{an^2+bn+c} = -(b_0+b_1)=\\ -\pi\left( \frac{\cot (\pi z_0)}{2az_0+b} + \frac{\cot (\pi z_1)}{2az_1+b}\right)=  -\pi\left( \frac{\cot (\pi z_0)}{\sqrt{b^2-4ac}} + \frac{\cot (\pi z_1)}{-\sqrt{b^2-4ac}}\right)= \frac{-\pi(\cot (\pi z_0)-\cot (\pi z_1))}{\sqrt{b^2-4ac}}= \frac{\pi(\cot (\pi z_1)-\cot (\pi z_0))}{\sqrt{b^2-4ac}} $$  Then we have  $$\sum_{n=0}^\infty \frac{1}{an^2+bn+c} = \frac{\pi(\cot (\pi z_1)-\cot (\pi z_0))}{2\sqrt{b^2-4ac}}$$    Is this correct?  I feel like I made a mistake somewhere.  Could someone correct me?  Is there an easier way to evaluate this sum? Why doesn't the Moon fall onto the Earth? For that matter, why doesn't anything rotating a larger body ever fall onto the larger body? How to compute $\lim\limits_{n\rightarrow \infty} \{(2+\sqrt{3})^{n}\}$, where $\{x\}$ is the fractional part of $x$? I've stumbled upon the following problem:  $$\lim_{n\rightarrow \infty} \{(2+\sqrt{3})^{n}\}$$  where "{}" notates the fractional part.  I've never studied this kind of problem, there exists any reference that I could read about this type of problem? Where did the brush size lock go for sculpt mode in 2.8??? What is difference between the different 'flavours' of neutrinos? SQL Server FOR XML Enclosing Element? Adding CSS Reference on Site Page So I have created a Site Page that has the "New Experience" look and I would like to change its style a little. Nothing major, just the height, width, color, etc. However, I can not seem to figure it out.   For example, I tried to change the height of the .pageHeader to a smaller value.   .pageHeader{ height: 150px !important } //for example of CSS in file   Here is a reference image of the page i'm trying to change    I tried adding   &lt;link href="../SiteAssets/file.css" rel="stylesheet" type="text/css"&gt;   to the .aspx page using SharePoint Designer and it didn't work.    I also tried adding   &lt;SharePoint:CssRegistration ID="CssRegistration" Name="SiteAssets/file.css" runat="server" /&gt;   to the .aspx page and it didn't work    I tried to use the "Embed" feature to add the CSS; however, it complains and says,     This embed code doesn't seem to work. We only support iframe based embeds.   Question:   How can I add custom CSS to this type page?  I can't seem to figure it out and I'm not sure exactly why the page will not load the file.  Is this even possible? Where do the X-Men get all their money/funding? Charles Xavier's father was a "wealthy nuclear scientist". In the beginning, Charles personally bankrolled the Xavier Institute/X-Men using his family's money.   This included, but was not limited to things like upgrading the mansion to house the training levels, providing a helicopter (the predecessor to the Blackbird jet), providing and replacing uniforms, providing health care for injured students, and rebuilding/repairing the mansion and parts of the Danger Room  repeatedly.  These have all been recurring costs. The mansion has been damaged or outright destroyed a ridiculous number of times. X-Men can't get into a fight without someone's uniform getting damaged.   In one of the more recent stories (I believe it was an early issue of Wolverine &amp; The X-Men), a comment is made about how the X-Men are pretty much bankrupt.  Where has all this money come from over all these years?   Xavier may have had a large war chest to start with, but no other income has ever been mentioned to my knowledge. Student's tuition could account for some of it, but there's no way that's going to fund everything. How many squares actually ARE in this picture? Is this a trick question with no right answer? This is one of those popular pictures on sites like Facebook. I always see a huge variation of answers such as $8, 9, 16, 17, 24, 28, 30, 40, 41, 52,$ etc., yet I've never seen a definitive answer on any website.    I counted $16$ whole squares ($4$ going down on left side, $4$ going down on right side, $8$ small squares in the centre). With this method the answer could also be $17$ if you want to count the entire shape as one big square.  I can also see the answer being $24$ if you count the smaller squares separately, as if they were floating above the main grid instead of intersecting with it.  Is there a right answer, or is it possible that there is no 'right' answer and it just depends on your counting method? Should your PhD students call you by your first name? GTA V for PC exited unexpectedly I recently ordered the GTA V PC from Steam and when I finished installing and launch the game. It gave me "Grand Theft Auto V has exited unexpectedly". I tried "safe mod" and every option available, but none of them work. I checked some forums and found a lot of people having the same problems. What could be the possible cause? I'm using a laptop with these specs:  CPU: i7 4700m GPU: AMD HD8970M RAM: 8GB  I'm pretty sure my laptop is way beyond the minimum specs. Does someone know how can I enter the game?