Weight distributions If a man is standing on two weighing machines (scales), with one foot on each, Will both machines show equal weight or his weight will be distributed in two machines?
Place each foot on a scale: can you add the two to find your weight? I frequent a blog from a British psychologist, and every Friday he likes to pose an interesting puzzle or riddle. The Monday after that he posts the answer. They're good fun, and IANAP but  made my it-might-not-be-quite-as-simple-as-that detector go off.  My question boils down to this: let's say I have two identical scales, and I stand on the scales with one foot on each scale. The scales read W1 and W2. Does my weight equal W1 + W2?
Here's the question: Prove that $\lim_{n \to \infty} (\sqrt{n^2+n}-n) = \frac{1}{2}.$  Here's my attempt at a solution, but for some reason, the $N$ that I arrive at is incorrect (I ran a computer program to test my solution against some test cases, and it spits out an error). Can anyone spot the error for me?  $\left|\sqrt{n^2+n}-n-\frac{1}{2}\right| &lt; \epsilon$  $\Rightarrow \left|\frac{n}{\sqrt{n^2+n}+n} - \frac{1}{2}\right| &lt; \epsilon$  $\Rightarrow \frac{1}{2}-\frac{1}{\sqrt{1+\frac{1}{n}}+1} &lt; \epsilon$  $\Rightarrow \frac{1}{\sqrt{1+\frac{1}{n}}+1} &gt; \frac{1}{2} - \epsilon = \frac{1-2 \epsilon}{2}$  $\Rightarrow \frac{1}{\sqrt{1+\frac{1}{n}}} &gt; \frac{1-2 \epsilon}{2}$  $\Rightarrow \frac{1}{\sqrt{\frac{1}{n}}} &gt; \frac{1-2 \epsilon}{2}$  $\Rightarrow \sqrt{n} &gt; \frac{1-2 \epsilon}{2}$  $\Rightarrow n &gt; \frac{4 {\epsilon}^2-4 \epsilon +1}{4}$ PHP: Replace umlauts with closest 7-bit ASCII equivalent in an UTF-8 string What I want to do is to remove all accents and umlauts from a string, turning "lärm" into "larm" or "andré" into "andre". What I tried to do was to utf8_decode the string and then use strtr on it, but since my source file is saved as UTF-8 file, I can't enter the ISO-8859-15 characters for all umlauts - the editor inserts the UTF-8 characters.  Obviously a solution for this would be to have an include that's an ISO-8859-15 file, but there must be a better way than to have another required include?  echo strtr(utf8_decode($input),             'ŠŒŽšœžŸ¥µÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýÿ',            'SOZsozYYuAAAAAAACEEEEIIIIDNOOOOOOUUUUYsaaaaaaaceeeeiiiionoooooouuuuyy');   UPDATE: Maybe I was a bit inaccurate with what I try to do: I do not actually want to remove the umlauts, but to replace them with their closest "one character ASCII" equivalent. More options when flagging for migration I think there should be more Stack Exchange networks available when flagging a question to be migrated. For example I'd think that the following question:    ...would be a better fit on unix.stackexchange.com instead of Stack Overflow. But without the option to mark it so, I feel hesitant to mark it. Include the option to flag posts as spam in the Low Quality queue I guess this is an additional to previous requests like  and .  But I just came across  review item, and was unable to flag it as spam.  edit: Since I posted this, the item has been removed (deleted) here is a screenshot: I may be visiting the US soon for both work (conference) and leisure (sight-seeing) but was wondering whether it is possible to pay a visit to Cuba, as I see that direct commercial flights have been restarted. From what I can tell, it is still not permitted for US citizens to travel to Cuba as tourists (from the ).  What is the legal status of European citizens - would it be permitted for me to travel as a tourist from, say, Florida to Cuba on a commercial flight? Would this cause problems for me on my return to the US?  I understand that the question has been asked before () but the situation has changed and I believe it warrants asking again. I have dual boot configured with Windows 7 (32bit) and Ubuntu 12.04(64bit). I installed Ubuntu after windows, now my windows is corrupt due to some virus and I need to reinstall it. Currently when I start my PC, grub loader comes up and I need to select Ubuntu or Windows.   I was wondering how can I install windows again and still have my Ubuntu install? Is there a way to do this?  I do not want to install Ubuntu again and lose my settings and data there.   Thanks, Ketan The question  got me curious and thinking about the following:   For which $n$ and $k$ are there nontrivial homomorphisms from the symmetric group $S_n$ to the cyclic group $\mathbb{Z}/k\mathbb{Z}$ of order $k$? I'm thinking it might be an open problem. Is this a problem with a known solution? If so, how can we prove it?   Thanks! I have an Asus UL30JT. It has Nvidia Optimus technology which I am not really interested in. I currently rarely use this laptop with it being connected to power. And I want to be able to play video at high res, play games and do some OpenCL coding.  In the BIOS I switched it to NVIDIA only (non windows 7). Previously, this worked just fine, using the nvidia driver.  After upgrading everything was broken. I have added nomodeset and blacklist.nouveau=1 as kernel options. The nvidia drivers install without error. However they are not found/used.  jockey-text -l kmod:nvidia_310_updates - nvidia_310_updates (Proprietary, Enabled, Not in use) kmod:nvidia_304_updates - NVIDIA binary Xorg driver, kernel module and VDPAU library (Proprietary, Disabled, Not in use) kmod:nvidia_313_updates - NVIDIA binary Xorg driver, kernel module and VDPAU library (Proprietary, Disabled, Not in use) kmod:nvidia_310 - NVIDIA binary Xorg driver, kernel module and VDPAU library (Proprietary, Disabled, Not in use) kmod:nvidia_304 - NVIDIA binary Xorg driver, kernel module and VDPAU library (Proprietary, Disabled, Not in use)   Trying to load the module manually fails as well.  sudo modprobe nvidia FATAL: Module nvidia not found.   Xorg.0.log show the following:  [    12.028] Loading extension GLX [    12.028] (II) LoadModule: "nvidia" [    12.037] (WW) Warning, couldn't open module nvidia [    12.037] (II) UnloadModule: "nvidia" [    12.037] (II) Unloading nvidia [    12.037] (EE) Failed to load module "nvidia" (module does not exist, 0) [    12.037] (==) Matched nvidia as autoconfigured driver 0 [    12.037] (==) Matched nouveau as autoconfigured driver 1 [    12.037] (==) Matched vesa as autoconfigured driver 2 [    12.037] (==) Matched modesetting as autoconfigured driver 3 [    12.038] (==) Matched fbdev as autoconfigured driver 4 [    12.038] (==) Assigned the driver to the xf86ConfigLayout [    12.038] (II) LoadModule: "nvidia" [    12.038] (WW) Warning, couldn't open module nvidia [    12.038] (II) UnloadModule: "nvidia" [    12.038] (II) Unloading nvidia [    12.038] (EE) Failed to load module "nvidia" (module does not exist, 0) [    12.038] (II) LoadModule: "nouveau" [    12.039] (WW) Warning, couldn't open module nouveau   I have installed the kernel headers, of the correct kernel. I verified that the kernel options are in the grub configuration. I have purged all nvidia packages and tried to reinstall (multiple times...)  Currently I am at a loss. I have checked the following question:  But nothing there worked for me. Both the Romulans and the Federation have regularly violated the Treaty when it suits them. Starfleet has obviously developed and manufactured cloaking/stealth technology and the Romulans make regular excursions across the Neutral Zone. They obviously aren't declaring all-out war, so what penalties or sanctions have been imposed for violations?  -edit added for clarity-  Has either side ever 'punished' their own people for any violations of the Treaty? How to print the full NumPy array, without truncation? Hide a Field From ONE User Scenario: If I had a Custom Profile / Standard Profile, say Sales,and I have 50 Users assigned to the same Profile and had same Permission / Access on a particular object (Could be Standard or Custom Object), if I were to Hide a Field ONLY TO ONE USER, which would be  a better Solution to achieve this WITHOUT EDITING OR TOUCHING THE PROFILE??  Option 1: Create a Custom Profile for this particular User and give CRED access (I know this one isn't a good solution as I got a Thumbs-down from a Technical Architect)  Option 2: Create a Permission Set - Go to the particular Object,say, Accounts, Object Permission Enabled -->Field Permissions-->Remove READ Access - This would make this particular field hidden from the Object to the Profile. Then Assign this Permission to particular User whom I don't want to see this field.  I would go with the 2nd option but I still hear a groan. Where am I going wrong? How would you hide a particular field from ONE User out of 10 Profiles who have the same Access Rights?  What's the best possible solution to hide a Filed from only one User out of 10 Users who have the same Profile. Example of vector space such that $cv = 0$ where $c \ne 0$ and $v \ne \vec{0}$ Is there an example of a vector space $V/F$ such that $0 \ne c \in F$, $\vec{0} \ne v \in V$, but $c \cdot v = 0 $?  I couldn't think of an example. Setting the correct encoding when piping stdout in Python Continuity of Integration for a measurable function I am having difficulties with this problem:  Let $f$ be a measurable function on $R$. Show that $\lim\limits_{n \to \infty} \int\limits_{-n}^{n} | f | = \int\limits_{R} | f | $  My idea is to use Continuity of integration: We need an ascending collection of measurable sets. These are $E_n = R \cap [-n, n]$ $R = \bigcup E_n$ Now if we apply Continuity of Integration we have:  $\lim_{R} |f| = \lim\limits_{n \to \infty} \int_{E_n} =\lim\limits \int_{-n}^{n} |f |$. My problem is Continuity requires f to be intergrable and all i know is that f is measurable.  Another way i was thinking to use monotone convergence theorem, but i am not sure how to create the sequences.  Any Ideas? thanks Inversion in "only [adverb] have they" I am interested in displaying some things (e.g.: title page) in full color on screen, while having the same object/page display in a black and white friendly form when printed.  According to , there is built-in functionality in the PDF specification for Screen-Only objects and Screen-And-Print objects.  There may also be a way to add a layer on top of the B&amp;W page that only displays the full color page on screen via the PDF 1.5 Optional Content Groups feature.  Similarly,  demonstrates the selective printing of text via ocg-p.  But it is not clear how I can use this package in the way that I need to.  My scenario is compounded by the fact that my color page text is white on a dark background.  MWE:  This code presents the way I am currently switching back and forth between color and b&amp;w.  I change the printincolor bool variable to make the change.  \documentclass[11pt]{article}  \usepackage[demo]{graphicx} \usepackage{etoolbox}  \providebool{printincolor} % Will set color title page and section headings \setbool{printincolor}{false}  % Setup color if needed \ifbool{printincolor}{% \usepackage[pagecolor=none]{pagecolor}% \definecolor{MyBlue}{HTML}{1b3667}% \usepackage{afterpage}}{}  \begin{document}  % Begin Title Page {  \thispagestyle{empty}   \ifbool{printincolor}{%   \pagecolor{MyBlue}%   \afterpage{\nopagecolor}}{}   \begin{center}   {\ifbool{printincolor}{\color{white}\sffamily}{\sffamily}%  Set text color white or leave [default] black   \ifbool{printincolor}{\includegraphics[width=1.5in]{logo-gold}}{\includegraphics{logo-blue}}% put logo gold or blue   \\ \vskip 1in   \begin{huge}         \textbf{Title}         \vskip 0.1ex\rule{0.5\textwidth}{0.8pt}\vskip 1ex         Subtitle         \\         \end{huge}   \vfill\vfill   \begin{large}    Authors:\\   John Doe and Jane Doe\\   \end{large}   }   \end{center} }  \end{document}   How can I layer (or otherwise display) two versions of the title page in a way that color displays on screen, but black and white is printed? I want to install selenium webdriver in my Ubuntu 16.04 system for python CSS3 selector to find the 2nd div of the same class I need a CSS selector that can find the 2nd div of 2 that has the same class. I've looked at nth-child() but it's not what I want since I can't see a way to further clarify what class I want. These 2 divs will be siblings in the document if that helps.  My HTML looks something like this:  &lt;div class="foo"&gt;...&lt;/div&gt; &lt;div class="bar"&gt;...&lt;/div&gt; &lt;div class="baz"&gt;...&lt;/div&gt; &lt;div class="bar"&gt;...&lt;/div&gt;   And I want the 2nd div.bar (or the last div.bar would work too). Easy way to write contents of a Java InputStream to an OutputStream I was surprised to find today that I couldn't track down any simple way to write the contents of an InputStream to an OutputStream in Java. Obviously, the byte buffer code isn't difficult to write, but I suspect I'm just missing something which would make my life easier (and the code clearer).  So, given an InputStream in and an OutputStream out, is there a simpler way to write the following?  byte[] buffer = new byte[1024]; int len = in.read(buffer); while (len != -1) {     out.write(buffer, 0, len);     len = in.read(buffer); } Find the product $\prod_{n=1}^{\infty} (1+x^{2n-1}) $