Android Studio - Java - Error while evaluating a String

this is my code:  public String TakeText; ...   TakeText = startBox.getText().toString(); if (marker == null && TakeText == Text1)  {...}   Android Studio debug tool shows me that TakeText="WoW" and Text1="WoW" and at the same time that TakeText == Text1 is false.  Why?


I'm using Ubuntu 14.04.  I've downloaded wine and wine Q4 and I've made sure that i have all the components for wine. I'm trying to play battlefront 2 (it's an exe file which I downloaded online). I have the original cd but I can't play in on my laptop as my disk drive is broken.   When I try to open the file with wine it acts as if it's about to open but then closes down and changes my screen resolution. I know the file works because I've used it before on windows 7.  The file also has .dll and .bink.32 which I think it needs to run.  How can I get it working?


I have the following issue.  With a Monte Carlo simulation I have generated a data set, x values and their frequencies. When I plot the histogram I noticed that the shape of the distribution is skewed. The distribution of ln(x) is almost a perfect Gaussian distribution. As far as I have understood this right a quantity is ln-normal distributed when ln(x) is normal distributed. So what then I calculated $\mu$ and $\sigma$ of the distribution of ln(x). As I mentioned I assumed that ln(x) is normal distributed so that its PDF is $y=A\times e^{-0.5\times(ln(x)-\mu)^2/\sigma^2}$.   Now, how do I get the standard deviation of x (being ln-normal distributed) and its expected value?


Bug with notifications: I'm getting notified of two items every day

I'm always getting these two notifications every single day:


Contact limit reached - trying to figure out how

Basically we are over limit and I did some investigating but I am still baffled as to how.  I checked contact builder - email and mobile and we have a total of 1.7 million contacts.  Our limit is 1.5 million, but apparently we are over by 400,000 (1.54M)?  MC counts Contact Keys as individual records and they are unique, so by that logic there should be no duplicates correct?   My question is, is there a way for me to figure out if there are any duplicates and to gain a much more specific answer as to how our total is calculated.  I see 1.7 contacts total in Contact Builder - All contacts, but apparently we are at 1.54m total contacts.  If someone uploads a list of contacts as a DATA EXTENSION using say an email, would that be counted towards our limit?


I was debugging a bug when I came across a piece of code which can be simplified as below  $value = '9611080820001471'; $value = sprintf('%.0f', (float)$value); echo $value . "\n";  This produces following Output:  9611080820001472  Can somebody explains why/how the $value got incremented


Winter Bash 2014 closing remarks - ideas for next year

we had a question like this, and  SE  members have supported one this year, and nobody seems to have made one yet.  Hence:  What does everybody want for next year's Winter Bash? It's okay to repost old ideas that have already come up if you feel they haven't had enough attention (but please don't go just copy/pasting every  !).  A few ideas I can think of off the top of my head:   Moar hats! There's been plenty of time to get all the hats this year; it would be great if next year there'd be more to do. Keep secret hats secret-er. This could be pretty hard to do, but possibly by deleting/locking "how do I get secret hats" posts?   One idea per answer, please!


Calculate $\lim\limits_{ x\to \infty} \frac{\ln(x)}{x^a}$ where $ a > 0 $

I want to calculate $$\lim\limits_{  x\to \infty} \frac{\ln(x)}{x^a}$$ where $ a > 0 $  It looks simple because if $a>0$ then $ x^a $ it grows asymptotically faster than $ \ln(x) $ so $$\lim\limits_{  x\to  \infty} \frac{\ln(x)}{x^a} = 0$$ But I don't know how to formally justify that. I am thinking about something what I was doing in case of sequences:  $$\frac{\ln(x+1)}{(x+1)^a} \cdot \frac{x^a}{\ln(x)} $$ But it have no sense because sequences was being considered in $\mathbb N$ but functions like that are considered in $\mathbb R$ I can't use there hospital's rule


Can I use a power supply that supply slightly higher current than the rated current from my dc motor?

I have a 12v, 0.9A dc motor. Currently I have two 12v dc supplies which I borrowed from my friend. The current of the 2 dc supplies is 1.0A and 0.5A respectively. Is it safe for me to use the higher current  supply from 12v dc supply (1A) or a 0.5A 12 dc supply to my dc motor?


Problem: Show for two positive definite matrices $A$ and $B$, if $A \succeq B$ then $B^{-1} \succeq A^{-1}$ Definition: $A \succeq B$ if $A-B$ is positive semidefinite. I've been trying to use the adjunct matrices since $A^{-1}=\frac{1}{det(A)}adj(A)$ so from the $\frac{1}{det(A)}$ it seems sort of obvious that if $A \succeq B$ then $B^{-1} \succeq A^{-1}$. However, I have no idea beyond this how to use the positive definite nature of $A$ and $B$ or definition of $A \succeq B$ to prove the statement. All I know is that if a matrix $A$ is positive definite then so is $A^{-1}$. Any help would be appreciated!


Getting Sha256 values in any arbitrary range with almost equal probability

I went through this post , this post,  and I felt like the exact way mentioned in the first one is really helpful. I am looking for help to generalize the way for any arbitrary integer, in other words, if we want the output values in range of 0 to n where any output may get any value in the range with equal probability, how would I apply the exact way mentioned in the first post? Or is there any other way which helps?


I have following expression to reduce: $(λmnfx.mf(nfx) λfx.fx λzy.zzy)$ After some substitutions i get the result: $(λfx. f(f(f x)))$ Is it correct answer? If not, please tell me what is correct one so i could try to get into it. Thanks in advance.


How to install an app outside Google Play?

How can I install an apk app outside of Google Play. Like if I downloaded it from another site and I try to open it, it says unable to install and I read that you have to do something to get it to work. What do you have to do?


How do wizards/witches in the Harry Potter universe learn non-magic subjects?

In the Harry Potter series, there is a lot of talk about the curriculum at Hogwarts but they never talk about learning math, Muggle history, advanced reading/writing, etc.   Are we to believe they are learning these as well, but they are just less interesting as topics for a book/movie? Or do magical people have no use for learning those past the age of 10?


I signed up for a new site and it got added under "Your Communities"

I just signed up for an account on Ask Different. After some time, I noticed that Ask Different got automatically added to my personalized list of Communities in the site switcher.  As I had personalized the list, there shouldn't be any automated changes taking place.    This is getting very annoying. I have been looking at some sites which I reached via the Hot Network Questions. Some of the content is interesting/good and I want to vote/comment. To do that I need to create an account (which happens fairly frequently). As soon as I do that, the site gets added to my manually created list.


How to evaluate $\int_0^{2\pi} \frac{d\theta}{A+B\cos\theta}$?

I'm having a trouble with this integral expression:  $$\int_0^{2\pi} \frac{d\theta}{A+B \cos\theta}$$  I've done this substitution: $t= \tan(\theta/2)$  and get: $\displaystyle \cos\theta= \frac{1-t^2}{1+t^2}$ and $\displaystyle d\theta=\frac{2}{1+t^2}dt$ where $\displaystyle \cos^2\theta/2=\frac{1}{1+t^2}$  then the integral becomes:  $$\int\frac{2 \, dt}{(A-B)t^2+(A+B)}= \sqrt\frac{A+B}{A-B} \arctan \left(\left(\sqrt\frac{A+B}{A-B} \right) t\right)$$   However, I'm not sure about the new limits since $\tan$ has period $\pi$ so what I have to do at this point to decide the new limits? And of course if you find some mistake in what I've done before, please let me know!


Why is the $S_{z} =0$ state forbidden for photons?

If photons are spin-1 bosons, then doesn't quantum mechanics imply that the allowed values for the z-component of spin (in units of $\hbar$) are -1, 0, and 1?  Why then in practice do we only use the $\pm 1$ states?  I have been told that this is directly related to the two polarizations of the photon.  This seems to be more of a classical argument however, arising from the fact that Maxwell's equations do not permit longitudinal EM waves in a vacuum.  I have also heard that it is related to the fact that photons have no rest mass, although I understand far less of this reasoning.  What I'm looking for are elaborations on these two arguments (if I have them correct), and perhaps an argument as to how these two are equivalent (if one exists).


JavaScript stopwatch SetInterval ignoring ClearInterval

I am making a stop watch and the setInterval seems to be restarting on it's own after I tell it to stop or it doesn't stop at all.  What I want is that when I press Stop the setInterval stops cycling but keeping the number it's at unless the reset button is clicked.    const sw = {     time: 0,     reset: ()=>{         clearInterval(sw.stopWatch)         sw.time = 0     },     stop: ()=>{         clearInterval(sw.stopWatch)         console.log("stop")     },     stopWatch: ()=>{         setInterval(function(){             sw.time ++             document.getElementById("time").innerHTML = sw.time         }, 1000)     } } <!DOCTYPE html>       <meta charset="UTF-8">     <meta name="viewport" content="width=device-width, initial-scale=1.0">     <meta http-equiv="X-UA-Compatible" content="ie=edge">     <title>Document</title>
0
     <button onclick="sw.stopWatch()">Start</button>     <button onclick="sw.stop()">Stop</button>     <button onclick="sw.reset()">Reset</button>


How to set up a wi-fi hotspot with an Ubuntu laptop (access point mode)?

I've read , and carefully followed the instructions provided. I am sure the wireless card in my laptop supports going into wireless access point mode. But unfortunately, when I use the following command to start hostapd service it throws an error:   $ sudo service hostapd stop  Starting advanced IEEE 802.11 management hostapd                      [fail]    The instructions mentioned above said this could possibly be because my wireless card does not support the g mode, and provided the wiki of hostapd. But what is g mode? I tried to switch to a, or b mode, but it just didn't work.  Can anyone help with this or recommend a tool like connectify in windows ?  ps. I am using Ubuntu 12.04, 32 bit. I have an ADSL wired network, and I want to share it by setting my laptop into a WiFi hotspot with  my windows phone.


I want all bookmarks after "Anhang" (appendix) to be a level deeper, but I need them to be \chapter{} for the right numbering.  I write a scrbook document and that's what I got:    Is it possible to change the depth of the chapter to act like a section in the bookmarks?  UPDATE  MWE:  \documentclass[12pt,a4paper,oneside]{scrbook}  \usepackage[ngerman]{babel}     % deutsche Worttrennung \usepackage[T1]{fontenc}        % Ausgabe von Sonderzeichen und Akzenten in PDF verbessert \usepackage[utf8]{inputenc}         % Eingabe von Sonderzeichen möglich \usepackage{lipsum}  \setcounter{secnumdepth}{3}     % subsubsections nummerieren \setcounter{tocdepth}{3}        % subsubsections in TOC  \usepackage[ %     pdfproducer={Texmaker},     %      pdfcreator={pdfLaTeX},      %      hidelinks,          % versteckt die Boxen um die Links in der PDF     bookmarksnumbered,      % nummereiert Lesezeichen     ]{hyperref}         % PDF Metainformationen hinzufügen   \begin{document}  \appendix \pagenumbering{alph}  \thispagestyle{empty}  \vspace*{3em} \begin{center} \begin{Huge} \textbf{\textsf{Anhang}} \pdfbookmark{Anhang}{Anhang} \end{Huge} \end{center}  \chapter{Appendix 1}  \chapter{Appendix 2}  \section{Appendix 2.1}  \section{Appendix 2.2}  \chapter{Appendix 3}  \end{document}


This is my opening a new question after having one of my questions marked as a duplicate (). If you came from my previous question, after reading everything at this link:  :my question is still unanswered. I don't need a command line script, I think. The chosen answer at that link isn't suited for my problem, nor did I find anything pertaining to my problem in the other answers. The other answers contained information I would find useful if I were trying to enable unicode characters on the command line on my own computer.  I am trying to learn as much about coding as I possibly can. So I wrote a few small programs, and wanted to allow my mother to use them on her computer, which does not have Python, of course. So in order to do that, I have been using the cx_Freeze module to make it to where these little programs of mine will work on her computer, with her having nothing to do but extract a .rar and move the shortcut to her desktop.  This is what the programs look like when the .exe's are run.    This is the loop I am using containing the instructions for what to do if help is asked for.  valid_help_string_list = ['\'help\'',                           '\'HELP\'',                             'help',                             'HELP',                            '"help"',                            '"HELP"'] while True:     weight_entry = input('Please enter your weight or type \'help\' for the pictogram legend.\nPlease round decimal numbers to the nearest tenth: ')     if weight_entry in valid_help_string_list:         print('\nLegend:\n□ = 10 lbs\n▪ =  5 lbs\n▫ =  1 lb\n∙ = .1 lbs\n')     else:         weight_entry = validate_entry(weight_entry)         if weight_entry:             break   This is what it should look like when anything in the help list is input.    This is what I am getting. Whenever anything in valid_help_string_list is typed, the program crashes because of the unicode characters.    Is there any actual Python code that can handle something like this? I want to be able to make this happen on other people's computers locally during runtime (the change to the encoding of the command line, if that's what needs to happen).


Two layers with same SRs and same coordinates don't overlap

i'm trying to do some analysis on road accidents.   I have :   a .csv with lat,long data of road accidents  a .shp with the road network   When I create a new layer from .csv, it is automatically assigned to WGS 84 epsg 4326.  The road networks instead is  WGS 84 32N epsg 32632  The layers overlap when using the different SRs. The problem is when I change them to a uniform SR (that is, when creating a new shp of road accidents with epsg 32632), they don't overlap anymore and can only be visualized one at time.  Any ideas?   I'm using Qgis 2.18 (but the same with Qgis 3.0)


Program not stopping when I press "Stop"

I have a very strange problem. When I press stop, the code does not stop. see: import tkinter as tk x=tk.Tk() stops=False def stop():     stops=True     print("STOPPED") tk.Button(x,command=stop,text="Stop").pack() while not stops:     print(stops)     x.update()     x.update_idletasks()  If I press stop, why does still it keep on printing? the stops variable is not edited in the while loop, so why doesn't it stop? I have also tried adding this to the end of the while loop: if stops:     break  But it still does not stop. Why?


erase ubuntu and reinstall will it affect windows and other windows partitions

I am trying to install a fresh version of Ubuntu in my computer without touching the windows 10 dual boot! In the Installation Type, the first option seems exactly what i wanted to do.  My question is, is this feature is safe to use? because i don't want to lose any windows files and other NTFS partitions on the hard-disk. Please eliminate my confusion. Note as that i dont need any files or media which are in the ubuntu partition, Thanks.


How to change certain word in certain line in a file

i have a file in which i have to change a word and then save it by same name.  for ex-  for file "name"-  my name is joe (original data) my name is roy (changed data)   how to do it in best possible way?


Figure and table side by side with different captions

I am trying to get a figure and a table next to eachother but they aren't staying together. In my document the figure ends up somewehere else but the table stays where I want it to be, as if the h in the \begin{figure}[h] isnt working.  The caption for the table has to be above the table and the caption for the figure has to be under the figure.  My code as of now:  \begin{figure}[h]  \parbox{7cm}{  \centering   \includegraphics[height=3.5cm, width=6.5cm{Kapitler/Metode/Linersammenhang.png}  \caption{Lineærsammenhæng mellem erstatningsgrad og cementindhold}  \label{fig:linersammenhang}  }  \begin{table}[h]  \parbox{7cm}{  \centering  \caption{Tabel over cementindhold for hver erstatningsgrad udregnet vha. den lineærsammenhæng}  \label{tab:cementindhold}  \begin{tabular}{cc}  \hline  \begin{tabular}[c]{@{}c@{}}Erstatningsgrad\\ {[}\%{]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}Cementindhold\\ $[\frac{kg}{m^3}]$\end{tabular} \\  \hline  0 (REF)                                                            & 222,4                                                                      \\ 10                                                                 & 227,8                                                                      \\ 30                                                                 & 238,8                                                                      \\ 100                                                                & 277,0                                                                      \\ \hline  \end{tabular}  }  \end{table}  \end{figure}   Hope someone is able to find a solution :)


How to derive the equation in my question?


Reading and displaying correct utf-8 on windows-python

I have a subtitle file consisting of utf-8 with Chinese characters. In fact, it's tiny so  is the file.  So far I've managed to read the file using   with open(path) as f:     text = f.read().decode('utf-8-sig').encode('utf-8')     print text[:100]   All I get is the usual mis-encoding mess:  1 00:00:20,160 --> 00:00:22,660 æ´¾æ‹‰è’™ç”µå½±å…¬å¸  2 00:00:32,160 --> 00:00:36,660 åŽçº³å…„å¼Ÿç   I've set chcp 65001 in cmd.exe and then ran the py script. What am I doing wrong?


Jquery delegate() deprecated , then how to listen dynamic create object event  FOR Example     $(document).ready(function() {   $(document).find("p").on("click", function(event) {     $("#contain").append("
Click this paragraph
" + event.timeStamp);   }); });
Click this paragraph.

     Here contain>p click event not happened with on event delegate is working is there any idea for this instead of delegate() or live() ?


Proving a basis for inner product space V when $||e_j-v_j||< \frac{1}{\sqrt{n}}$.

Suppose $(e_1,e_2,...,e_n)$ is an orthonormal basis of the inner product space $V$ and $v_1,v_2,...,v_n$ are vectors of $V$ such that $$||e_j-v_j||< \frac{1}{\sqrt{n}}$$ for each $j \in \left\{1,2,...,n \right \}$. Prove that $(v_1,v_2,...,v_n)$ is a basis of $V$.  I am completely lost and just starting to learn about inner product spaces. Could someone provide a proof with the explanation of how you got there?


Universal property of universal bundles.

A classifying space for a group $G$ is a topological space $BG$ with a principle $G$-bundle $p : EG \to BG$ where $EG$ is contractile, so that $BG = EG/G$. A classifying space is universal in the sense that if $q : E \to B$ is a principle $G$-bundle, then there is a continuous map $B \rightarrow BG$, unique up to homotopy, such that $E$ is the fiber product $f^*EG$. Why this definition implies tha there is a one-to-one corrispondence between the isomorphism classes of $G$-bundle on a space $X$ (that I denote with $\mathcal{P}_G(X)$) and the homotopy classes of maps $X \to BG$ ([X,BG])? In practice, how can I show that $$ [\mathcal{P}_G(X)] \simeq [X,BG] $$


How to determine max supportable display resolution?

I'm trying to determine what is the highest monitor resolution that will be supported by a computer.  System   Win XP-era Compaq Presario SR1750NX that contains  Radeon Xpress 200 integrated graphics on an AMD Athlon 64 based motherboard.    The Radeon Xpress 200 uses shared video memory (UMA).  The computer has 3 GB RAM.  (I'm not familiar with how UMA works and whether the video can access as much memory as it needs, or how much that would be.)  It is currently running Linux Mint 17.0.  I understand that AMD has a Linux version of Catalyst.  However, the Xpress 200 probably pre-dates ATI's acquisition by AMD, and the appearance of the UI looks generic, so the driver is probably FOSS, and possibly required some reverse-engineering. The only built-in video connector is VGA.  A VGA connector has no limit on resolution, but I understand the output quality at higher resolutions depends on the DAC and other factors.     Xpress 200 Info  The only thing I've seen that deals with maximum supported VGA resolution of the video chipset, itself, is the link posted by Daniel B in a comment, below.  The "for Intel architecture" version of the Xpress 200 is spec'ed to support up to 2048x1536 (apparently a common spec based on a 400MHz DAC).  Assuming the specs are the same in the "for AMD architecture" version, that would appear to be an upper limit.  It isn't clear whether other factors would limit it below that (e.g., maximum memory it can use).   Usage  I don't think this affects anything, but just in case, the intended use is a lot of screen real estate for static content (large spreadsheets, lots of browser tabs, and the like), I'm not trying to view hi-res video or do 3D rendering.    Info From The System  Some years ago, I upgraded the monitor to 1600x900, just guessing that it would be supported.  The available resolution settings under monitor preferences lists 1400x1050 as the only higher resolution, which is virtually the same total pixel count as the current monitor.  However, I don't know if this reflects system assumptions based on the current monitor or the actual system limitation (or perhaps the limit of the Linux driver).  The Linux driver does not have an explicit "list all" option.  Update   I checked with AMD and HP to see if they had any useful specs.  Answer: No. I used the xrandr command to see what it might show, which produced this (followed by available settings for the current monitor):  Screen 0: minimum 320 x 200, current 1600 x 900, maximum 4096 x 4096 VGA-0 connected 1600x900+0+0 (yada yada...)  The 4096 x 4096 maximum refers to the virtual screen size (maximum framebuffer), rather than a (useful) resolution possible from the VGA port.  Would that imply at least that the chipset limit is not further limited by memory (one variable eliminated)?   What I'm Looking For In An Answer  I'd like to get a higher resolution monitor, but don't know how to determine what the limit supported by the system would be, or what factor is the limitation.     An answer for this particular computer would be great.  If that can't be answered without available specs, somebody actually using a higher resolution monitor on a similar system would be good evidence. In a more general sense, how do I go about determining the limit for a given system?  Is it just the chipset limit (in which case, I probably have an answer, already), or can that be further limited by other factors (memory, drivers, etc.)?  If there can be further limits, can those be determined in a practical way, or does it basically come down to just locating specs?


Move Queues between instances with Force.com Migration Tool (Ant)?

I know I can move Queues from instance to instance using Change Sets, but is there any way to do it with the Force.com Migration Tool (Ant)?


One exercise from a list. I have no idea how to finish it.  Let $I=[c,d]\subset \mathbb{R}$. Let $f:I\to \mathbb{R}$ be continuous at $a\in (c,d)$. Suppose that there exists $L\in \mathbb{R}$ such that $$\lim \frac{f(y_n)-f(x_n)}{y_n-x_n}=L$$ for every pair of sequences $(x_n),(y_n)$ in $I$, with $x_n<a<y_n$ and $\lim x_n=\lim y_n=a$. Prove that $f'(a)$ exists and it is equal to $L$.  Any help? Thanks in advance.


I have been stuck on this problem for almost an hour and couldn't find a solution or a work around.  Here is my problem:  I have a subprocess that starts a subscriber S  that listens to some real time data publisher P. P randomly publish data at a random time, and I want to get all the data within a timespan (say 30 seconds).    subscriber = subprocess.Popen('/start/process', stdout = PIPE, stderr = PIPE)  max_time = 30  inital_time = time.time()  while time.time()-initial_time < max_time:      try:          print(subscriber.stdout.readline())      except:          pass   After compiling, I find the while loop blocked by the readline() when P doesn't publish data. The loop stops at the print until P publish some data, and then the loop prints the data and go to the condition check. So if P never publish data, the program never ends.  I'm assuming that this is because readline require some sort of input in order for it to return, so my questions is how to I work around this? I have read  and I don't see anything related.


A really cool combinatorics problem / puzzle

Problem statement  6 scientists are working on a secret project. They wish to lock up the documents in a cabinet so that cabinet can be opened when and only when 3 or more scientists are present. What is smallest number of locks needed? What is smallest number of keys each scientist must carry??  Let $n$ be the number of locks. Let us name each scientist as $1,2,3,4,5,6$.Let $S_i$ be the set of keys that scientist $i$ is carrying and each scientist carries $k$ number of keys.we would get following results  $|S_i|=k$ $|S_p \cup S_q \cup S_r|=n$ $n=3k-(|S_p \cap S_q|+|S_p \cap S_r|+|S_r \cap S_q|)+|S_p \cap S_q \cap S_r|$  I tried manipulating the above results in hope of finding solutions but failed.Is there anything I am missing or is this approach entirely wrong?


I try to adjust the right margin of a cventry for the ModernCV template to match with the overall right margin but it is always broader (see screenshot). I tried geometry package and minipage but both have not solved the problem. Here is example code: \documentclass[11pt,a4paper,sans]{moderncv}  \moderncvstyle{banking}  \moderncvcolor{black}  \usepackage[utf8]{inputenc}  \usepackage{enumitem}  \usepackage[official]{eurosym}   \name{David}{Doe} \usepackage[scale=0.9]{geometry} \begin{document} \section{Employment} \begin{itemize} \item{ \cventry{11/2019 - current}{Hello}{Hello}{Hello}{}{\vspace{0pt} \begin{itemize}[label=$\bullet$]  \item{XXX} \end{itemize}} }  \end{itemize}  \end{document}


HP Pavillion ay012nx Wi-Fi not working properly on Ubuntu 18.04

I purchased a HP laptop with model number hp 15-ay012nx. The Wi-Fi works perfectly in Windows but is really very weak in Ubuntu that I can use Wi-Fi in laptop only when I place laptop very near to my modem. I tried to solve the issue with some related  results but, I think its not specific to my model. The network details are as follows.    03:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. RTL8723BE PCIe Wireless Network Adapter [10ec:b723] Subsystem: Hewlett-Packard Company RTL8723BE PCIe Wireless Network Adapter [103c:81c1] Kernel driver in use: rtl8723be Kernel modules: rtl8723be   I'm running Ubuntu 18.04 with Linux kernel 4.15.0-36-generic.


Synaptic touchpad, Ubuntu 15.10, multiple devices.... pain

I've installed Ubuntu 15.10 on a new Dell Precision 5510 from a Live USB stick. I used the "Try without install" mode, and from there installed Ubuntu to the hard drive. During the install, the touchpad worked. However, in the newly installed system, the Synaptic touchpad isn't registering anything.   I've done a bit of digging, and I can confirm the following:   The kernel sees the touchpad. xinput list lists the touchpad. evtest does see any events from the touch pad.   When I run xinput list, I get the following:  Virtual core pointer                        id=2    [master pointer  (3)] ⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)] ⎜   ↳ A4Tech USB Mouse                          id=11   [slave  pointer  (2)] ⎜   ↳ ELAN Touchscreen                          id=13   [slave  pointer  (2)] ⎜   ↳ SynPS/2 Synaptics TouchPad                id=15   [slave  pointer  (2)] ⎜   ↳ DLL06E5:01 06CB:7A13 UNKNOWN              id=17   [slave  pointer  (2)]   Now doing further digging, I've established that id=15 and id=17 are both trying to hog the touchpad, and as such, it's not working.  I can see that the touchpad is recognised in Settings > Mouse and Touchpad, and that options like disabling the touchpad, etc. are also present, and the touchpad is "enabled".  Is there any way to solve this? Can I just disable the UNKNOWN touchpad? I'm not a linux expert, so might need pointers on basics. Any help is appreciated.


Algorithms - Solving the recurrence $T(n) = \sqrt{n} T \left(\sqrt n \right) + n$

I have been trying to solve the recurrence   $T(n) = \sqrt{n} T \left(\sqrt n \right) + n$  for some time now. I only know substitution, recursion trees, and the master method (though it doesn't apply here, so i'd prefer help in those forms. I also attempted to change variables but got nowhere.  My plan was to use a recursion tree, but I seem to be stuck, as this recurrence isn't in the usual form $T(n)= aT(n/b)+f(n)$. However, I do know that the first level of the tree has the cost of $cn$, and that the next level down has $\sqrt n$ nodes. My main concern is how I can express the next level's recurrence, which I got to be $T(\sqrt n)=\sqrt nT(\sqrt(\sqrt n))+\sqrt n$, though I feel like that is wrong.


What's the difference between these varieties of octocoupler?

It looks like ON Semi makes a bunch of different kinds of optocouplers for various applications. The array of choices is kind of bewildering. What, exactly, is the difference between an optocoupler made specifically to drive triacs (e.g. the MOC3023M) and a standard logic gate optocoupler (e.g. the H11L1M)? What about AC line monitor optos (e.g. the MID400 - which, strangely, is much more expensive than the others despite a lower isolation rating and lower tolerance for high frequencies)?


I'm trying to find all duplicate files (based on MD5 hash) and ordered by file size. So far I have this:  find . -type f -print0 | xargs -0 -I "{}" sh -c 'md5sum "{}" |  cut -f1 -d " " | tr "\n" " "; du -h "{}"' | sort -h -k2 -r | uniq -w32 --all-repeated=separate   The output of this is:  1832348bb0c3b0b8a637a3eaf13d9f22 4.0K   ./picture.sh 1832348bb0c3b0b8a637a3eaf13d9f22 4.0K   ./picture2.sh 1832348bb0c3b0b8a637a3eaf13d9f22 4.0K   ./picture2.s  d41d8cd98f00b204e9800998ecf8427e 0      ./test(1).log   Is this the most efficient way?


I installed Linux on a partition and now I don't know how to boot it

Today I installed Ubuntu on to a pre-existing partition (I also made a swap partition during the installation) and when my machine went to restart, my screen went dark and did nothing, I did wait. There was power going to the machine.  I did a forced restart but now I have no clue how to boot to the partition that I have Ubuntu on. I have Windows 7, by the way. I have poked around my BIOS settings and I didn't see anything in the boot tab about choosing a partition to boot off of.


Can a power failure or forceful shutdown damage hardware?

Can computer hardware suffer damage from forceful shutdowns (holding the power button for five (5) seconds) or power failures?   I believe that normal PC hardware does not suffer from this - after all, it's not much different than what they experience under a standard shutdown. But elsewhere I've read tht another person thought that it could do physical harm to the hard drive and possibly other components as well. He also said that the journaling features of filesystems are useless in face of power failures and were intended to help mitigate damage from system crashes.  I think this is nonsense, but then again I lack the experience and knowledge to say it with certainty.


I am an Indian (Indian Passport) presently in Kano, Nigeria on a business visa. I am going back to Mumbai on 22 Sept by Turkish Airlines with a 12 hour layover time in Istanbul.  We plan to see the city during this time.  Can I get a visa on arrival?


I had 3 Partition(C(150gb),D(350gb),E(400gb)) and Windows 8.1 installed on C drive. I replaced Windows 8 with Ubuntu 13.04.  Now I have only one file system(900gb).  Is there any way to access data of D and E partition from Ubuntu? Is it possible to get back D,E partition if i replace Ubuntu with windows? Has Ubuntu formatted my entire hard disk?  $df -h /dev/sda2       909G  2.7G  861G   1% / none            4.0K     0  4.0K   0% /sys/fs/cgroup udev            3.9G  4.0K  3.9G   1% /dev tmpfs           788M  860K  787M   1% /run none            5.0M     0  5.0M   0% /run/lock none            3.9G  156K  3.9G   1% /run/shm none            100M   44K  100M   1% /run/user /dev/sda1        93M  121K   93M   1% /boot/efi


Accuracy of "on-the-fly" CRS transformation in QGIS

How accurate are the OTF transformations in QGIS (2.18)?   I created a 100m by 100m square polygon in a shapefile layer using a CRS of WGS84/UTM zone 14N (EPSG:32614). The project also uses the same CRS. With OTF transformation turned off, when I measure the area and the side of the square using the measurement tool, I get 10,000 sq m for the area and 100m on each side, as expected.   If I turn on OTF transformation and use the measurement tool, I get 10066.2065 sq m for the area and 99.9941 m for each side. Not only is the area incorrect, but multiplying the lengths of the measured sides (99.9941 x 99.9941) does not equal 10066.2065.  Is there a bug or am I just not understanding what OTF does?  Currently, most of my projects use OTF because I receive shapefiles with varying CRS's. It sounds like I need to have each layer reprojected to the same CRS as the project and turn off OTF if I want to get accurate areas and distances. Is this correct and is reprojecting a layer more accurate than OTF?


Curl a string with whitespaces and characters in it?

I'm trying to create a "simple" script that I'm going to use to create some documentation for Unix/Mac machines.  I've successfully received the information I need, but it seems like I can't send it over to a webserver I've created with CURL because it gives some whitespaces and characters in the information output. I've tried with very many methods but nothing seems to work correctly..   This is the URL output that the script will send over to curl:   "ip.ip.ip.ip/documentation/index.php?avdelning=XX&user=XXX&hostname=XXX&model=ModelName:MacminiModelIdentifier:Macmini4,1&RAM=Memory:8GB&CPU=ProcessorName:IntelCore2DuoProcessorSpeed:2.4GHzNumberofProcessors:1&CPUCORES=TotalNumberofCores:2&MACADDRESS=etherxx:xx:xx:xx:xx:xx&SERIALNUMBER=SerialNumber(system):XXXXXXXX&LASTLOGGEDIN=XXXXX   Using only the following string will work if I do it directly with CURL and will not give me any errors and I receive the information on the webserver.   But when I use the script it does not work. The script:   #!/bin/bash  STR_RAM=$(/usr/sbin/system_profiler SPHardwareDataType | grep Memory: | sed 's/ //g'); STR_MODEL=$(/usr/sbin/system_profiler SPHardwareDataType | grep Model | sed 's/ //g'); STR_CPUNAME=$(/usr/sbin/system_profiler SPHardwareDataType | grep Processor | sed 's/ //g'); STR_CPUCORES=$(/usr/sbin/system_profiler SPHardwareDataType | grep Cores: | sed 's/ //g'); STR_SERIAL=$(/usr/sbin/system_profiler SPHardwareDataType | grep Serial | sed 's/ //g'); STR_MACADDR=$(ifconfig | grep en0 -A3 | grep ether | sed 's/ //g'); STR_LOGGEDIN=$(finger | tail -1 | sed 's/ //g'); STR_HOSTNAME=$(hostname | sed 's/ //g');  STR_URL=ip.ip.ip.ip/documentation/index.php?avdelning=$1\&user=$2\&hostname=$STR_HOSTNAME\&model=$STR_MODEL\&RAM=$STR_RAM\&CPU=$STR_CPUNAME\&CPUCORES=$STR_CPUCORES\&MACADDRESS=$STR_MACADDR\&SERIALNUMBER=$STR_SERIAL\&LASTLOGGEDIN=$STR_LOGGEDIN;   STR_URL2=$(echo $STR_URL | sed 's/ //g' | awk '{printf("\"%s\"\n", $0);}'); curl $STR_URL2;   As you can see I've added a bunch of probably unnecessary editing with sed and awk but nothing seems to work.   I get these error messages:  After I added the awk to add double quotes before and after the URL string I get:  Could not resolve "ip.ip.ip.ip   Which is very strange since I can run the curl command directly in terminal without that error. And If I do not remove the spaces etc I receive multiple lines that the URL can not be resolved. I've tried with urlencoding in perl and bash but that does not seem to fix the problem either.  I'm running this on a Mac now. Usage: sudo sh script.sh randomstring randomstring  EDIT: Output of new script   sudo sh script2.sh IT Denniz curl: (3) Illegal characters found in URL xx.xx.xx.xx/documentation/index.php?avdelning=XX&user=Denniz&hostname=admins-Mac-mini-2.local&model=ModelName:Macmini ModelIdentifier:Macmini4,1&RAM=Memory:8GB&CPU=ProcessorName:IntelCore2Duo ProcessorSpeed:2.4GHz NumberofProcessors:1&CPUCORES=TotalNumberofCores:2&MACADDRESS=  etherXX:XX:XX:XX:XX&SERIALNUMBER=SerialNumber(system):XXXXXXXXXXX&LASTLOGGEDIN=adminadmins008Jun10:21


Can hypercomputation compute the impossible?

There are things which are illogical/logically impossible (like saying that 2+2=4 and 2+2=5. Without changing anything in the axioms of mathematics or logic, this would be a contradiction and would be inconsistent and illogical/logically impossible.   There are other types of logic systems apart from classical logic, like paraconsistent logics or even trivialism, that allow these contradictions to occur, prove them as right and work with them.   We can make a paraconsistent or trivialist system and work with it. For example, with trivialism, in theory, we would be able to derive and state everything we would want (since literally everything, even including illogical/logically impossible inconsistencies and contradictions), but we as humans (or as brains), are limited and can't conceive everything we want (at least to what I know). Therefore, no matter how many trivialist models we create and how much time we would work with them, we would never find or conceive many illogical/logically things because they are just that: impossible. There are impossible things to describe and conceive. For example, Russel's set is the set of all sets that do not contain themselves. If Russel's set contains itself, then it cannot contain itself, since it only contains sets that don't contain themselves. But if Russel's set does not contain itself, then it must contain itself, since it contains all sets that don't contain themselves.  There are quite a few logic bombs like this. You cannot ever compute the contents of Russel's set, and there are more formal, mathematical ways to present it. All of them have in common that you can't actually compute what the set is, whether you do it by hand, in your head, or on a computer. It's just a statement that cannot be fully logically processed.  If you take every possible state the human brain can be in, none of them include the computation of Russel's Set's contents. That is, not only can the contents not be computed, they cannot even be represented. No stimulus can cause us to comprehend Russel's Set, since such comprehension is not possible to begin with. It does not have a solution. Even if we try to solve it using trivialism, we would just be able to write a solution that does not make sense and prove it has sense and it is the real solution, but we could not be able to have a solution that would make sense "outside" the realm of trivialism (for example in classical logic), even though, using trivialism, we could prove that such solution would have sense in whatever context and logic system.   But what about hypercomputational machines (for example oracle-like machines)? I've read about some models of hypercomputation which are compatible with paraconsistent or trivialism logics. I've also read there are some models of hypercomputation (particularly those oracle-like models which use a black box) where, essentially, the hypercomputer is an algorithm that cannot exist. It might be because such an algorithm is fundamentally forbidden by logic itself (which is hided in a black box). Would any of these be capable of computing/"conceiving" these impossible things I wrote before? Do you know of anything that would help?


I'm talking about the movie  Spoilers ahead.  Walter (Daniel Radcliffe) gave the task or blackmailed the Four Horsemen to steal a chip from a lab which can access any digital device. So they did steal the chip. And when they rescue Dylan Rhodes (Mark Ruffalo) from drowning in the water, Jack Wilder said that the chip is fake.     Jack: Wait something is not right.      Atlas: What's wrong?      Jack: It's fake.   Then they assumed that Walter did not know that the chip is fake. So they came with a plan to bluff. They pretended that they had the real chip. After they got caught by Walter, they gave the fake chip to Walter. Walter checked the chip and declared it as real. The Four Horsemen were surprised.     Walter: I'm sorry to interrupt. But I have to say congratulations and   thank you. It's real.      Lula: What? It's real!!!!!      Atlas: What? Is it real?      Jake: What is he talking about?   What happened? I didn't get it. What did I miss? Was the chip real? Was Walter pretending it to be real? If so, then why? If not, who switched the real chip with the fake one? Who had the real chip before?


Text alphanumerical characters changes to characters in Illustrator

I am working with Adobe 2020 while transferring the chart from Excel to Illustrator, text change to weird nonnumerical characters. I have tried these before transferring the chart change the font to Arial, Times New Roman, Myriad and then paste change it to PDF, or picture or TIFF or PNG image and then paste to Illustrator Nothing worked... Any help would be highly appreciated Thanks


Anyone recognize this lyric about "story of my life"?

I've been trying to find the title of these lyrics; it's rather jazzy from 90ish, female singer    "it's the story of my life if you want to know. a play where everything is meant to be. You're the story of my life and I can't let you go"


Error when I run 'sudo apt update' after installing python3.6: 'sh: 1: /usr/lib/cnf-update-db: not found'

I am a new Ubuntu 18.04 user. I installed python in terminal and closed the terminal (sudo apt-get install python3.6). After that, terminal can't open from favorites, although it opens with right-click from desktop.  When I run sudo apt update I get output like:  sh: 1: /usr/lib/cnf-update-db: not found            Reading package lists... Done E: Problem executing scripts APT::Update::Post-Invoke-Success 'if /usr/bin/test -w /var/lib/command-not-found/ -a -e /usr/lib/cnf-update-db; then /usr/lib/cnf-update-db > /dev/null; fi' E: Sub-process returned an error code


want to do sql pagination for gridview in vb.net

Hi Actually I want to do sql pagination in sql server 2008 for a single table gridview which has nearly 50 rows, please help me to create sp for that pagination


FF000000=4278190080<2^(8*4)-1 (4 bytes)   but when I type in "System.out.println(0xff000000);"  it shows "-16777216". Why does it become negative in java?


Why do I need to replace "quiet splash" with "nomodeset"?

I have recently installed Ubuntu but could not load it. By searching on Interned I found a solution which works for me but I do not understand it. The solution is taken from .  In more detail, while I load Ubuntu, I get into a menu which asks me what I want to do. At this point I press e. After that I get a screen with some text where I replace quiet splash by nomodeset and then I press F10. After that Ubuntu loads.  Now, my questions are:   What exactly am I doing? Why does it help? Can I do something to avoid doing these steps each time I when I wont to load Ubuntu?


How can I create a file with executable permission itself? I want to create a new file with a single command with executable permissions how can I do it?


When I look at the storage section of my phone, the various categories add up to about 2.5 GB of storage, but it says that 11.4 GB is being used. Is there any way to figure out what else is taking up space on my phone?


Discreteness of the general angular momentum in quantum mechanics

When studying the general angular momentum $\textbf{J}$, which is defined as a vector operator with its components being Hermitian operators satisfying the commutation relations \begin{align*} \textbf{J} \times \textbf{J} = i\hbar \textbf{J} , \end{align*} and the simultaneous eigenvectors of $\textbf{J}^2$ and an abitrary component $J_z$, my book stated that the eigenvalues $j$ and $m$ are either integer (including zero) or half-odd-integer values. They came to this conclusion by using the raising and lowering operators which are defined as \begin{align*} J_{\pm} = J_x \pm iJ_y. \end{align*} More specifically, because of the inequality \begin{align*} j(j+1) \geq m^2 \end{align*} there must be an upper and lower bound $m_T , m_B$ which differ from each other an integer amount $n$. However, what ensures that these eigenvalues are the only possible values? How can it not be that the spectrum of eigenvalues is continuous? Say for example we forget about the raising and lowering operators and just postulate that there exists a simultaneous eigenvector of both $\textbf{J}^2$ and $J_z$ with $j = 2.3$ and $m = 2.3$. Is there a way to contradict this assumption? I have already found an answer using the representation theory of Lie algebras, but since my mathematical background is limited, I would like to have a simpler explanation. If this is the only formal explanation, then I would like to know that and move on :). The book I use for studying QM is Bransden & Joachain (chapter 6.5).


Difference between medium and long sized hyphen?

Is there any difference between a 'long' and a 'medium' sized hyphen?  (I don't think so, but I am just checking to make sure)  We all know the very short line, namely, the 'dash': -  Then there is also the hyphen, which I just recently found two versions of:   A medium hyphen A long hyphen     For comparison, I added the the dash to the right.


Java JButton creating and calling in different classes

I was just trying to code stuff for fun, however I am stuck. I am trying to create 3 JButtons in one class A, and then call those buttons in another class B and then add ActionListeners in class B. So basically I only create the buttons in abstract class A and then call them in class B which extends class A and in class B I do stuff with those buttons. It sounds very simple, however I can't figure this out.   In class A:   public abstract class Activity implements ActionListener {          public static JFrame frame;`         public static JPanel panel;         public static JLabel label;         public JButton buttonleft;         public JButton buttonmid;         public JButton buttonright;      protected void makenButtons(String textlinks, String textmidden, String textrechts) {                 JButton buttonleft = new JButton(textlinks);                 JButton buttonmid = new JButton(textmidden);                 JButton buttonright = new JButton(textrechts);                 panel.add(buttonleft);                 panel.add(buttonmid);                 if (textrechts!=null) {                 panel.add(buttonright);             }   In class B:  package hi; import java.awt.event.ActionEvent; import java.awt.event.ActionListener;  import javax.swing.JButton; import javax.swing.JPanel;  public class MainActivity extends Activity{      public static void main(String[] args) {         Activity.makenFrame(380,120,"Choose mode");         Activity.makenLabel("Choose a work mode: ");         Activity.makenOpties("Run as server", "Run as client");         //Activity.makenButtons("Start","Exit",null);         MainActivity a = new MainActivity();         a.actiesButtons("Start","Exit");         Activity.toevoegenpanel();         }      public void actiesButtons(String textleft, String textright) {         JButton buttonleft  = super.buttonleft;         JButton buttonmid  = super.buttonmid;         buttonleft.setText(textleft);         buttonmid.setText(textright);         buttonleft.addActionListener(new ActionListener() {         public void actionPerformed(ActionEvent event) {             if (event.getSource() == buttonleft) {                 System.out.print("Hi");         }      }           });         buttonmid.addActionListener(new ActionListener() {         public void actionPerformed(ActionEvent event) {             if (event.getSource() == buttonright) {                 System.exit(0);             }         }                });     }      @Override     public void actionPerformed(ActionEvent e) {         // TODO Auto-generated method stub      } }  I deleted some not-important stuff. So basically I just like to know how to call the JButtons in class B. I tried:    JButton buttonleft  = super.buttonleft;         JButton buttonmid  = super.buttonmid;   However this gave me a nullpointerexception. Thanks in advance!  Edit: I know my problem is the exception, I just don't know how to fix it :( Could someone please write some quick pseudocode for me how to create a button in one class and call that button in another? :)


I followed the mainstream instructions for installing Ubuntu 16.10 alongside windows 10. After installing Ubuntu I restarted my computer to get the GRUB menu to choose which OS to boot. Everything is fine. Booted Ubuntu 16.10 and then I wanted to test Windows as well, so I shut the pc down and turned on again to find the same menu but this time I chose Windows. When I turned it on again, it just ignored grub and went straight to booting Windows.   EDIT: Windows 10 fast start and hibernation are disabled, Secure Boot is disabled; my notebook is a Sony Vaio SVE151J11X  EDIT2: through admin prompt on windows i just ran:  bcdedit /set {bootmgr} path \EFI\ubuntu\shimx64.efi   now everything is fine. Thanks


Alter "format as code" button ('Ctrl+K') to detect when your selection is in a list, and format appropriately

Normally when you want to enter code in an answer you can simply paste your code, highlight it and hit the "format as code" (curly braces icon) on the toolbar above your answer ('Ctrl+K' does the same thing). That indents by four spaces to produce something like this:  alert("hello");   Thats all fine and dandy but if you want to include code in a list, that is where the "format as code" button fails, because it always simply adds (or removes) 4 spaces before the highlighted block. I am proposing that the "format as code" function be modified to detect how deep you are in a list and format the code (add spaces) accordingly. For example:   This is my first list item  alert("Format as code should indent me by 8 spaces");  This is my second list item  alert("Format as code should indent me by 8 spaces");    This list item is indented by four spaces  alert("Format as code should indent me by 12 spaces");    This list item is indented by eight spaces  alert("Format as code should indent me by 16 spaces");


I've accidentally deleted the Pictures folder in /home/my_username. I've tried to re-create that folder but it seems that the system doesn't understand it. All the pictures I take from the screenshot program, shutter, save from the web... automatically go to /home/my_username, not /home/my_username/Pictures  How do I restore the default Pictures folder?


I found a  that I had previously edited (the user had written it both in English and Spanish and I removed the English part).  Today I found that the user added a comment with the code:     I decided to add that comment into the question itself, tapped on the edit link, and found that the text displayed in the box is not the current one, but the original text in English and Spanish:    After a quick check, it doesn’t happen on the mobile or desktop website. It seems it only affects the app. I am using an IPhone 6 with iOS 11.2.6.   I tried to replicate the issue in other questions, but I haven’t been able to do it. The issue only seems to happen on that one. I don’t remember trying to edit that question on mobile before, but maybe that could be the case (could it be caching a previous value?).


Cannot move sites by dragging the hamburger icon on Android app

I cannot move sites in the "Edit Your Sites" section, because the swipe-from-left-on-screen gesture blocks the hamburger (3-bar) icon.  I'm using Android 5.1 if it matters.


Is it professionally okay to use the term "caught flat-footed"?


For a Gaussian process, how does $\mathcal{N}(\mathbf{f}, {\sigma_n}^2\mathbf{I})$ relate to the Normal PDF?

I am told during the Gaussian Process class that the following notations are equivalent as convention: \begin{align*} \mathbf{y}|\mathbf{f} &\sim \mathcal{N}(\mathbf{f}, {\sigma_n}^2\mathbf{I}) \\  p(\mathbf{y}|\mathbf{f}) &= \mathcal{N}(\mathbf{f}, {\sigma_n}^2\mathbf{I}) \end{align*}  How does it relate to the typical definition of pdf of a Gaussian distribution:     Normal Probability Density Function   $$F(x) = \frac{1}{\sigma\sqrt{2\pi}}e^{-\frac{(x-\mu)^2}{2\sigma^2}}$$


Number of options to distribute $N$ different balls to $K$ numbered cells

There are $N$ different balls and $K$ numbered cells, $K<N$. I need to calculate the number of options to distribute the balls into exactly $L$ cells ($L<K$) so each cell will have at least 1 ball. I tried doing this: I assume all the balls are identical and arrange all the balls in a line, there are $\binom{N-1}{L-1}$ ways to distribute them to L cells so each cell has at least 1 ball, now because the balls are different I have $N!$ ways to arrange them in the line so in total I have $\binom{N-1}{L-1}\cdot N!$ ways to distribute the balls into cells. I have $\binom{K}{L}$ ways to choose the cells that have balls, so the total number of options is $$\binom{K}{L}\cdot \binom{N-1}{L-1}\cdot N!$$ but it is apparently wrong but I don't understand what did I do wrong here  EDIT: after the comment I tried doing this instead: I choose $\binom{K}{L}$ cells and put 1 ball in each cell, I choose the $L$ balls in $\binom{N}{L}$ ways and because the balls are different I have $L!$ ways to distribute them between the $L$ chosen cells, the remaining $N-L$ balls can be distributed in $L^{N-L}$ ways so in total $$\binom{K}{L}\cdot \binom{N}{L} \cdot L! \cdot L^{N-L}$$ but again I got the wrong answer, I assume because there are intersections I missed, at this point I'm not sure how I'm supposed to approach this


I already have the pink and red leather gloves, the armor, the crown, and the monkey's staff (and they're all enchanted). Regardless of how many health potions I use, I always die. Help!


How can I disable animation when switching desktops in Lion?

I would very much like to disable the sliding animation that occurs when switching desktops via ctrl+→/← or ctrl+[number] in Lion.   This was previously accomplished in previous versions with this command:  defaults write com.apple.dock workspaces-swoosh-animation-off -bool YES && killall Dock   This new animation is even more slow than in Snow Leopard - nearly 1 second to switch - a real productivity killer.  Any help greatly appreciated!


Using OpenLayers, I added a WFS layer (on GeoServer) with a filter that returns all features (black) that intersect my polygon (yellow) placed over some Latin American countries within certain dates.    However, the feature that crosses horizontally across the map does NOT actually intersect my polygon. This feature is somewhere in the pacific ocean between Hawaii and Fiji and NOT in Latin America. The problem is that instead of crossing the International Date Line it is being rendered on the map by wrapping around the whole world.  The problamatic feature is defined:     POLYGON((-179.700417   14.202717,-178.687422 13.992875,179.024138 8.24716,-179.98241 8.035567,-179.700417 14.202717))   I have many of problematic date line features like this but have narrowed it down to this one for this example. I can't just ignore it in my application because I have many of them.  I've tried using "wrapDateLine: true" in base layer and WFS layer with same results.  Not sure if this would be a GeoServer problem or an OpenLayers problem.  Does anyone know a solution to my international date line problem?


How can I control fan speed on Acer Nitro 5?

I have an Acer Nitro-AN515-53 running Ubuntu. Is there a way I can control fan speed? Is there any type of software for this?


Indian Passport back cover torn a bit. Can it get accepted?

I got some minor damage(torn marks) to back side cover due to accidental spilling of glue stick. The last cover page got stick to its previous page. When I try to separate them it got torn a bit. Is this acceptable for travel or can I better go for a re-issue of passport ? Except this there is no other visual or physical damage.


Example of incomplete, but decidable theory, and of complete and undecidable theory, question

On  it is written that     Decidability should not be confused with completeness. For example, the theory of algebraically closed fields is decidable but incomplete, whereas the set of all true first-order statements about nonnegative integers in the language with + and × is complete but undecidable.   A theory is called complete (see  if for every sentence either it or its negation is provable in the theory. But then, I guess completeness would yield decidability, as we can just enumerate all provable proposition (proofs are finite length derivations) and check whether the current one equals the sentence (or its negation) under question. By completeness this procedure will terminate.  So maybe completeness of the logical system is meant in that paragraph, i.e. a logical system is complete if the valid sentences coincide with the provable ones. By  first order logic is complete. As written  the theory of algebraically closed fields is axiomatizable in first order logic, so it could not be incomplete in this sense, but the cited paragraph claims exactly that.  So, for both interpretations of completeness, completeness of a theory, or of a logical system, the cited paragraph makes no sense to me. Could someone explain what I miss, or what is meant here?


I have a really big PNG image, it's ~11GB. Is there any way to open it? I would just like to view it without too many problems.  I tried Photoshop CS6 and it's too big even for this kind of modern software.  I am using Windows8 64.


Can we find the derivative of modulus function? if yes, then how?

I am confused with the derivatives of modulus function.


Poincaré maps and how they are used in dynamic systems

I am trying to find a solid definition for what a Poincaré map is and how they are used but the ones online are very complicated. Can someone explain with a simpler definition of what a Poincaré map is, and provide an example of a chaotic system in which a Poincaré map can be used?


The books have sold vs. The books have been sold

Do both "The books have sold" and "The books have been sold" natural and appropriate in English? "The books have sold" sounds as if the book can sell themselves. Can they?  List of best-selling books - Wikipediaen.wikipedia.org › wiki › List_of_best-selling_books The books have sold more than 150 million copies and have spawned two film adaptations, with a third one slated for release next year." (4 February 2018)


Is “This room was slept in by Milton” grammatical even though ‘sleep’ is an intransitive verb?

Milton slept in this room.    According to   , sleep is an intransitive verb (A1). So we shouldn't be able to rewrite the sentence in the English  passive voice.   But I want the most important part of the sentence to be the room and not Milton, so I wrote     This room was slept in by Milton.    First, is this grammatical?   Second, I thought the passive voice in English can only use transitive verbs??   I researched about the English Passive Voice on  and Purdue University's  .   This answer has been marked as a possible duplicate of . But the most upvoted answer there does not address the property of intransitive as assigned by the dictionary, which is an integral part of this question. In addition the same answer there is confusing  because it says both that transitivity is not a property of verbs and yet ends up talking about transitive verbs. In addition, the same answer does not explicitly deal with verbs other than "sense verbs". So I'm not sure if that answer applies to to sleep.


Schengen Visa via France, but visiting Amsterdam and Reykjavik (Iceland)

I am an Indian National and have a schengen visa via France embassy. I will be visiting Paris for a few days and then return to India. After a few days, I have to visit Amsterdam and Reykjavik (Iceland) from India. Would my schengen visa issues from France embassy be valid for the second travel, considering I am not going to France in my second visit. Please help, slightly urgent.


conflict using matlab-prettifier and LaTeX beamer

I was trying to use the  package with the LaTeX  package, and I noticed I was getting errors when trying to compile. Mainly I was getting an error when trying to use matlab-prettifier environment, within beamer's frame environment.  Here is a MWE:  \documentclass{beamer}  \usepackage{matlab-prettifier} \lstMakeShortInline[style=Matlab-editor]"  \begin{document}  \frame{     "break"  }  \end{document}   Trying to run this code sample gives me a "runaway argument error".   I should also say that the error is not limited to trying to insert the "double-quote" environment defined in the preamble, I've also tried using other matlab-prettifier environments, but haven't had any success...  Does anyone know of a workaround?


Higher lowercase - how to make it equal?

I have a textView in which I can search some words and the code for the search is this:  public void btn_search(View view) {     int total = 0;     String word_search = Etxt.getText().toString().trim();     String fullTxt = textView.getText().toString();     String[] array = fullTxt.split("\n");     String word;     StringBuilder st = new StringBuilder();     for (int i = 0; i < array.length; i++) {         word = array[i];         if (word.contains(word_search)) {             st.append("" + word.trim() + "");             total++;         } else {             st.append(word);         }         st.append("
");     }     textView.setText(Html.fromHtml("" + st));     text_total.setText("Ergebnisse: " + total); }   Now, the problem is that when I search something, I must pay attention to the higher lower case. And the question is: How can I make the higher lower case equal, so that I can search something without paying attention to this?  Thanks!


Can anyone tell me if my Canon EF lenses can be used on a Canon Rebel t5(1200D)


limit function to only work with argument from a specific instance

I have a function and I want the first positional argument   of that only give the instances of a specific class  ,  a code like this in other programming languages  from channels import Channel   def get_frame_link(Channel channel):     print(channel)    if coder use that function in this way the python most raise an error  get_frame_link(123) get_frame_link("hello")   the truth way most be only this  channel=Channel() get_frame_link(channel)   note: this is not duplicated question because  I don't asked for how to check a variable type


I want to see all everything in booting like what is being loaded and all instead of grub purple Interface.. So is there any way to enable text kind of mode and disable that purple screen ??


All he does is watching TV.   I said this sentence and my native friend corrected me and said 'you need to use bare infinitive here'      All he does is watch TV.   Why is this right while the other is false? If I change the placement of the complement and subject, I will have this sentence:     Watch TV is all he does.   Shouldn't it be 'watching TV (or to watch) is all he does'?  I searched for it online and I couldn't get anything. Is there a rule that I'm missing? When do they use bare infinitive after 'to be' verbs?  Thanks


Integrating $\int_{0}^{\infty} \frac{(\log x)^2}{x^2+x+1}$ using residue theorem

Just out of curiosity, how does one integrate something like this using residue theory?     $$\int_{0}^{\infty}\frac{(\log x)^2}{x^2+x+1} dx$$   According to Wolfram Alpha, the  is $\dfrac{16\pi^3}{81\sqrt{3}}$.  I have seen similar integrals before, like  and , and they all require seem some sort of ingenuity. I am sure  will come to rescue soon. :)


Is it possible for an end portal to not generate in the legacy console (xbox 360) edition of minecraft

I recently loaded up a new world in the xbox 360 edition of minecraft in survival, and then once again in creative to find the stronghold. I couldnt find the end portal in creative, but since that happens almost every time I go in creative and look for a portal, i thought, "ok, i'll just go to the stronghold in  my survival world", but i couldnt find the end portal either. I was hoping someone knows whats going on, whether it got overwritten, or if i just have bad luck with seeds. Here is the seed if that helps: -7368897920777790432. Oh, and here are the coords: X: 146, Y: 45, Z: 132.


Is it possible to give more weight to a keyword while doing a (Google) search?

Say I want to search for an error message like The given filter instance must implement one or more of the following filter interfaces but in the context of MiniProfiler. Is it possible to give more weight to the MiniProfiler part.  In example by enclosing it with asterisks: The given filter instance must implement one or more of the following filter interfaces *MiniProfiler*  Just a theoretical question that popped up in my mind. I think I can find the answer with the current search query too :)


I'm trying to determine where connectivity to an external host using a specific TCP port is being blocked. Traceroute for Windows only uses ICMP, and telnet will only tell me that the port is blocked and not where. Does anyone know of a Windows utility similar to traceroute that will achieve this?


Tag score calculation wrong in Android App

I checked yesterday and today the new homepage in the Android app. Very surprised I saw that I would almost reach a silver tag badge, that confused be because I always take a look on possible badges I can get. However I compared the score with the website and I got a total different results. See this two screenshots:


$insert_document_list_results   = "insert into social_compliance_document_list_results      (user_id, serial_number, status, date_of_renewal, date_of_expiry, evidence_1, remarks)       values($user_id, {$row['ID']}, $status_array[$index], $date_of_renewal_array[$index], $date_of_expiry_array[$index], $evidence, $remark_array[$index])";   This is a query that I have written in order to insert data into my MYSQL database. However, each time I execute it, I get this error message,   ERROR: Could not execute sql. You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'Handbook 2019.pdf, 'Remark')' at line 1


List-class variable slower than ArrayList-class variable

when I create List - program executed for 2.5 ms, if I changed List to ArrayList - program executed for 1.1ms.... who knows why?  class StockSpanner {      ArrayList<Integer> list; //1.1 ms     //List<Integer> list; 2.5 ms      public StockSpanner(){        list = new ArrayList<>();     }      public int next(int price) {         int less = 0;         int counter = 0;                  list.add(price);         counter = list.size() - 1;          while(counter >= 0){             if(list.get(counter) <= price) {                 less++;                 counter--;             } else {break;}         }         return less;     } }


What is the difference between a virtual machine on which you can run an virtualized OS on it and a virtual machine like Java VM?

It seems that they are quite different things but everybody uses the same term for them.


JQuery Treetable in Lightning is not working when navigating from standard pages to page where treetable is implemented

I have a requirement where I use  in Lightning and I have implemented the same as below code. I created a Lightning Tab from this component and used in Lightning Experience. Component: <aura:component implements="force:appHostable">     <ltng:require scripts="/resource/treeTable/treeTableJS.js" afterScriptsLoaded="{!c.loadScripts}"/>     <aura:attribute name="temp" type="String" default="none" />     <aura:attribute name="content" type="String[]" default="item1,item2,item3,item4" />

                 <ui:button label="Click" press="{!c.selectClick}" />	                 Content
             <aura:iteration items="{!v.content}" var="item" indexVar="index">
                     	                     {!item}
             </aura:iteration>

 </aura:component>  Controller: ({     loadScripts : function(component, event, helper) {         $("#table").treetable({                 expandable: true             }, {                 force: true             }, {                 initialState: "collapsed"             });     },      selectClick : function(component, event, helper) {         if(component.get("v.temp")==="none"){             component.set("v.temp","plus");             $("#table").treetable("expandNode", "parent");         } else{             component.set("v.temp","none");             $("#table").treetable("collapseNode", "parent");          }     }, })  Now about the issue, when I use this in Lightning tab first time it works (meaning straight forward scenario), but now from this page I navigate to any standard record page (be it Accounts record page) or even Home page and come back to this lightning tab, it does not work. We have to refresh the page to make it work again. Any resolve so that we don't need to refresh the page? Please help. Note: Lightning Locker service is disabled.


Does getElementByID() method work if ID contains spaces

Element i have has spaces within the id attribute which is causing the getElementByID() to not work and not be able to capture the element. If there any workaround i can do in this. Do i have to remove all white spaces in all element ID values i have. window.addEventListener('DOMContentLoaded', (event) => { var str=document.getElementById('Monica Finolta Sol ID treReport').id; alert(str); })


Since neutral is connected to ground how is current kept off of ground?

If neutral is connected to ground and current desires ground then I would think it would go to ground.  But my understanding is that it is kept off of ground until it's "upstream" of the breaker box, or unless a malfunctioning device shorts hot to ground.  So what "prevents" the electricity from going to the ground that the neutral is connected to?


I've been searching a lot but couldn't find a solution. How do you deal with a DateTime that should be able to contain an uninitialized value (equivalent to null)? I have a class which might have a DateTime property value set or not. I was thinking of initializing the property holder to DateTime.MinValue, which then could easily be checked. I guess this is a quite common question, how do you do that?


How can I get the creation date of an Excel File in a Python script?

I am currently creating a script to automate the treatment of some Excel files. I am working on Excel (.xlsx) files and modifying them with the library Pandas. I need to get the creation date of one of those files so I can insert it into another file and I don't have the slightest clue on how to proceed.   I am currently using Python 3.3.5, Pandas 0.15.2 and I can't use any library not currently in Spyder (I work in a big company where we aren't allowed to update versions or to install anything not approved first and approving something takes months)   Thanks,


Flag dialogue popup is stacked behind realtime-post-deleted-notification banners

There is a little bug that becomes visible when a page contains realtime-post-deleted-notification banners (that's the CSS classname of these red banners appearing on answers which just got deleted, see screenshot below) and you try to open the flag dialogue above them:    Obviously, the dialogue appears below the banners, which it clearly should not do. It also has no input focus, trying to interact with the dialogue fails and either closes it (clicking outside of the red banners) or reloads the page (clicking on the red banners).  The cause for this is simply the z-index ordering in the site's CSS. Relevant CSS snippets:  .realtime-post-deleted-notification {     position: absolute;     text-align: center;     z-index: 100; }  .popup {     display: none;     padding: 15px;     position: absolute;     z-index: 10; }   So the fix for this minor bug would probably be to raise the z-index of the popup class to something greater than 100.


Why did the gamma ray burst from GW170817 lag two seconds behind the gravitational wave?

, reporting on the announcement of gravitational wave GW170817, explained that for the first time we could identify the precise source of a gravitational wave because we also observed the event in the electromagnetic spectrum. It notes however that the gamma ray burst detected by the FERMI space telescope was observed nearly two seconds later than the gravitational wave.   Did the gamma ray burst actually arrive at Earth two seconds after the gravitational wave, or is this time delay just some kind of observational artefact? If the delay is real, what is its cause? Is the delay due to the gamma ray burst somehow being slowed, or was it 'emitted' at a different time in the merger event? What does a delay even mean when the gravitational wave was detected for over 100 seconds? Is it a delay from peak GW to peak gamma ray?


Do prepositions at the end of sentences, and split infinitives any longer matter?

In the 1950s we were strongly discouraged from placing prepositions at the end of sentences, and also from using split infinitives. Is this considered important now?


Features used in quantum mechanics but not used in classical mechanics

What are (and why?) all the variables (features) used in the models in quantum mechanics but not used in classical mechanics (e.g. spin, flavor)?


How can I recover my files and my system after running rm -r /home/username?

I am new to Linux & was running some random commands to experiment in terminal (Ubuntu-18.04 LTS) & by mistake I deleted my home directory.  The command I executed is shown in the screenshot of my history below. It was  rm -r /home/dawn   Now all my files are gone, as well as the default folders such as Pictures, Desktop, Screenshots, etc & my desktop screen has turned dark black.  When I tried to open the files icon, it's giving me an error.  Can anyone help me on this?


Why won't my controllers connect to my PS4? I want to use unplugging my PS4 as a last resort

I was playing on my PlayStation 4 when my fully charged controller suddenly turned off. I thought it just went dead and plugged it into my charger. I then tried to turn on my other controller but it wouldn't connect. I tried to rest the controller but that didn't work. Does anyone know how to fix this? I only want to use unplugging my Playstation as a last resort because I've put a lot of hours into what I was playing and was about to save when the controller turned off. Also, my controllers will connect to my mom's system but not mine.


Let $A,B \in \mathbb{M}_n (\mathbb{C})$. If $A^2B + BA^2 = 2ABA$ then exist $k \in \mathbb{N}$ where $(AB-BA)^k = 0$.  I tried solve with minimal polynomial, but I did not have much effect.


Imputation of missing values for doing PCA in R

I have a dataset with approximately 4000 rows and 150 columns. I want to predict the values of a single column (= target).  The data is on cities (demography, social, economic, ... indicators). A lot of these are highly correlated, so I want to do a PCA - Principal Component Analysis.   The problem is, that ~40% of the values are missing.  My current approach is: Remove target indicator and do PCA with mean/median imputation of missing values. Select x principal components (PC). Append target indicator to these PC. Use PC as predictors for the target variable and try common regression techniques, e.g. knn, linear regression, random forest etc.  With this approach, I'm getting quite good results. My metric is RMSE% - root mean squared relative prediction error. I tried this for all columns in the dataset, the RMSE% is between 0.5% and 8% (depending on the column). These errors are for values I actually know, NOT imputed values.  So, here's my problem: I'm not sure how much my data is distorted by replacing the missing values with the column mean/median. Is there any other way of imputing the missing values with minimal effect on the PCA results?


Verify that 4(29!)+5! is divisible by 31. How do I work this out? Step by step explanation please!


Why do objects follow geodesics in spacetime?

Trying to teach myself general relativity. I sort of understand the derivation of the geodesic equation $$\frac{d^{2}x^{\alpha}}{d\tau^{2}}+\Gamma_{\gamma\beta}^{\alpha}\frac{dx^{\beta}}{d\tau}\frac{dx^{\gamma}}{d\tau}=0.$$ which describes  "how" objects move through spacetime. But I've no idea "why" they move along geodesics.   Is this similar to asking why Newton's first law works? I seem to remember reading Richard Feynman saying no one knows why this is, so maybe that's the answer to my geodesic question?


I would like to know how to set the hostname of another mac remotely as done locally via sudo scutil --set HostName <new host name>.   I was in a cowork space in Medellin today and someone had changed my hostname to iphone-de-diana. I also would like to know how to prevent this.   PS. I have a 2017 Macbook Pro running Mojave


What is the difference between user and service account?

I would like to know difference between user and service account.  I know that e.g. Jenkins installed to ubuntu is not a user, .    What is use of service account? When we need them? How can I create service account?


document class: report  \[ f(x)= \begin{cases} 1 &\text{if } x\in U\\ F(x) &\text{if } x\notin U. \end{cases} \]  If $T$ is open in $[0,1]$ then   \[ f^{-1}[T]=\begin{cases} \big(F^{-1}[T]\cap X\big)\cup U &\text{if } 1\in T\\ F^{-1}[T]\cap V &\text{if } 1\notin T, \end{cases} \]     This produces    Does anyone else think the brackets look a little too big? How can I correct this?  EDIT: I believe the problem is that \doublespace is used throughout the document.  (I was able to replicate the image using that). \linespread{1} made the brackets smaller, but it only seems to work if it's outside of the proof environment (and then it shrinks everything!).


What is the function of the list of loop devices?

A lot of strange loop devices appear in my Kubuntu OS.      [translation:     Hard disk 107.4GB     Hard disk 487.0GB     Loop Device     Hard Disk 4.0GB     Loop Device     Loop Device     Loop Device     Loop Device     Victor Disk]   Can anybody tell me what it is? .


why javascript map parsint of ['10','10','10'] gives nonsense?

xs = ['10','10','10']   [ '10', '10', '10' ]      xs.map(parseInt)   [ 10, NaN, 2 ]   xs.map(parseFloat)   [ 10, 10, 10 ]   why is the result 10,nan,2 for first one? why the second one is right?


How can I write an uppercase script L? (ℒ)

This is the symbol...    It's like a uppercase and cursive l.


Dropbox gives an error message when starting up but then it disappears

Something like "cannot monitor file system , run sudo tee 1000 |"..., but then it disappears before I can read the full message. Dropbox seems to work ok so not sure what this is about?


Why is a set of orthonormal vectors linearly independent?

A set of orthonormal vectors  is linearly independent.   Since I wouldn't memorize any such facts that is mentioned in my course book, what is the reason behind it and why are they linearly independent?


Compare two List objects for equality, ignoring order

Yet another list-comparing question.  List<MyType> list1; List<MyType> list2;   I need to check that they both have the same elements, regardless of their position within the list. Each MyType object may appear multiple times on a list. Is there a built-in function that checks this? What if I guarantee that each element appears only once in a list?  EDIT: Guys thanks for the answers but I forgot to add something, the number of occurrences of each element should be the same on both lists.


Trek 26" mtb disc, how to change up crank set /gear size?

What should I consider with regard to the front gear (derailleur) selector unit when changing up from a 42 to a 48 tooth crankset? I have changed a few similar cranksets but not done a gear ratio lift. A previous attempt (grip shifts) resulted in only one of the 3 crankwheels usable. Thanks.


Can we get notification in the tab (change of title)?

I'm usually running many different StackExchange sites in Firefox using tabs (using ReloadEvery to update every 5 minutes).  Right now to check for activity, I have to manually click on the tab to see if the envelope is lighted.  How about making the icon on the tab i.e. the title text change in some way, denoting that you have activity on the page?  We already add a message count for the chat tabs, so this shouldn't be very complicated.  Possible Example:


Infinitely many prime divisors of $f(a)$

Let $f(x)\in \mathbb{Z}[x]$ be a non constant polynomial with integer coefficients. Show that as $a$ varies over the integers, the set of divisors of $f(a)$ includes infinitely many primes...  To be frank, I have no idea where to start...   Trivial case is when constant term of $f(x)$ is zero.  In case of $f(x)=x(a_nx^n+\cdots+a_1)$  we have $p$ divides $f(p)$ for all primes $p$...  Other than this i have no idea...  Please give only hints..


Did all Headmasters get a portrait in Hogwarts?

Throughout the Harry Potter series, we see that deceased Headmasters of the school get a semi-sentient portrait of themselves in the Headmaster's Office, at the service of the current Headmaster. Do all Headmasters get a portrait? What are the conditions of getting one? For instance, there are a couple of times when Dumbledore is temporarily deposed as Headmaster: Dolores Umbridge takes over the job in Order of the Phoenix, and Minerva McGonagall takes the job in Chamber of Secrets and Half Blood Prince. Will Umbridge and McGonagall have portraits in the Headmaster's Office when they expire?


Find a tangent to two quadratic bezier curves

I have two quadratic bezier curves and I want to find whether they have a common tangent, and if so where it is.  If the first bezier is defined by points $(x_1, y_1)$, $(x_2, y_2)$, $(x_3, y_3)$, then the points on the curve have coordinates:  $x = (x_1 - 2x_2 + x_3)t^2 + (2x_2 - 2x_1)t + x_1 \\ y = (y_1 - 2y_2 + y_3)t^2 + (2y_2 - 2y_1)t + y_1$  Or to simplify things:  $x = A_xt^2 + B_xt + C_x \\ y = A_yt^2 + B_yt + C_y$  Likewise, I can get an equation for the second bezier:  $x = D_xs^2 + E_xs + F_x \\ y = D_ys^2 + E_ys + F_y$  The gradient of the tangent, $m$, to the first curve at $t$ is $\dfrac{2A_yt + B_y}{2A_xt + B_x}$,  which must be equal to the tangent to the second curve at $s$, $\dfrac{2D_ys + E_y}{2D_xs + E_x}$.  So $m = \dfrac{2A_yt + B_y}{2A_xt + B_x} = \dfrac{2D_ys + E_y}{2D_xs + E_x}$  Which I rearranged to get:  $t = \dfrac{2(B_yD_x - D_yB_x)s + B_yE_x - B_xE_y}{4(A_xD_y - A_yD_x)s + 2(A_xE_y - A_yE_x)}$  The gradient of the tangent is also equal to the difference in the y-coordinates over the difference in x-coordinates:  $m = \dfrac{D_ys^2 + E_ys + F_y - (A_yt^2 + B_yt + C_y)}{D_xs^2 + E_xs + F_x - (A_xt^2 + B_xt + C_x)}$  But that's as far as I got. The algebra looks too messy from here. Can anyone solve this, or is there a better approach?


I would like to replace "fWord" in the string "Input" as case insensitive.  while (FilteredWords.Any(Input.Contains)) {     foreach (string fWord in FilteredWords)     {         Input = Input.Replace(fWord, "****");     } }   (FilteredWords is a list of strings and Input is the string to "clean") It works, however is case sensitive. How do I make fWord case insensitive at replacing?


How to download a 32-bit version of Ubuntu 18.04

How do you download a 32-bit version of Ubuntu?


How can i get back dodge maximized windows function for Launcher in 13.10?

I still can't understand why the developers completely removed the function to let the Launcher dodge only maximized windows but is there a way to get this function back by tweaking dconf or so? this question is explicit to 13.10 where none of the patches or hacks work!


Do neutrinos not couple to the Higgs field?

I was reading the CernCourier, my favorite source of message on Higgs and friends. I was rather shocked, when I saw this:     "The mechanism by which neutrino mass is generated is not known."   What? Not known?  says: In Higgs-based theories, the property of 'mass' is a manifestation of potential energy transferred to particles when they interact ("couple") with the Higgs field, which had contained that mass in the form of energy.  Does this mean that neutrinos don't couple to the Higgs field?


Passing an object (message and image) using AJAX

I have the a function that POST a text message alright, but I'm trying to include an image file/attachment with it but no luck:  // this function sends over the message  createMessage ( messageToSend, callback ) {   return utils.ajax( {     url: '/messages',     type: 'POST',     data: messageToSend   }, callback ); }   I include what I need to send like this  const messageToSend = {      text: this.message,      attachments: this.attachments };         return api.createMessage( messageToSend, ( message ) => {        // some code } );   When passing the object, the text is included but the image file /attachment was never included. What could I have missed?


How to connect 2 ISPs into a single LAN?

I have 2 ISPs in case one fails. Ideally I would also like to take advantage of balancing LOAD on each ISP to maximize speed. My Current Network:  LAN A + 6 Deco M4 Mesh Router Mode (4 connected to LAN): 40+ devices (USING ISP A - 300MB symmetric - fiber) LAN B 15+ devices cable modem w/router function (USING ISP B - 300MB asymmetric - coaxial)  Goal:  1 single LAN (no connectivity issues) with Deco M4 Mesh, with 2 ISPs balancing load and providing continuity in 1 ISP if the other is down  How can I do this? do I need a special device to manage traffic other than main the Deco M4? Can I do something plug and play or I need device programming? In that case, can I buy a device and get remote support to program this?


Remove slide from ToC and navigation in beamer

I would like to have a slide at the end of my presentation be not included in the ToC or the navigation bar at the top.  The solution used to be to put it in a \section*{}. But at some point in the last year or so, this stopped working! (I recompiled some slides I wrote a year ago, which originally worked as expected, but the result changed this time.) The ToC looks fine but the offending slide still appears in the navigation header.  MWE:  \documentclass{beamer} \usetheme{Frankfurt}  \begin{document}  \begin{frame} \tableofcontents \end{frame}  \section{Section 1}  \begin{frame} hi \end{frame}  \begin{frame} hi hi \end{frame}  \section*{}  \begin{frame} bye \end{frame}  \end{document}        (Note that on the 4th slide, the "Section 1" and the first two circles are grayed out.)  Edit: Creating an \appendix for the final slide has an effect, but not exactly the desired one. The circle for the final slide no longer appears as part of Section 1, but instead it appears by itself in the top right corner, only on the final slide.  Edit:  fixed the problem, though it's still not clear to me why the original method no longer works.


The padding in the chat top bar (seen in non-room views, e.g. ) is off under "My Communities" list, and achievements dialog:        and...        and...        Affected browsers/OS:   Chrome latest stable version (65.0.3325.181) under Windows 7 and 10 (Arch)Linux. Firefox   Do also note that the top bar itself is still following the old design.  Can this please be fixed?


Multivariate polynomials have infinitely many zeroes

Let $F \in K[x_1, \dotsc, x_n]$, $n\ge 2$, with $K$ an algebraically closed field and $\deg F \ge 1$. Prove that $F$ has infinitely many zeroes.   I would consider $F$ as a polynomial in the single variable $x_1$, so that from the algebraic closure of $K, \exists c \in K$ s.t. $F(c) = 0$ considered as a polynomial of the only variable $x_1$. But then I can vary the remaining variables as I like in $K$, thus obtaining infinite zeroes. However this argument doesn't convince me: can I vary the variables $x_2, \dotsc, x_n$ and keep fixed $x_1$ still obtaining a zero of $F$?


inverse image of fiber product of scheme

I asked this question and I couldn't understand the following result.  Let $X$ be a noetherian integral separated scheme which is regular in codimension one, $\pi$ is a projection $X \times_{\operatorname{Spec}\mathbb{Z}} \operatorname{Spec}\mathbb{Z}[t] \rightarrow X$,and $Y$ be a prime divisor of $X$. Then, according to the person who answered that question, $\pi^{-1}(Y)=Y\times_{\operatorname{Spec}\mathbb{Z}}\operatorname{Spec}\mathbb{Z}[t]$ . But I can't prove this and I also think this can be true in more general case, that is, $X$,$Y$ be schemes over scheme $S$, $\pi$:$X\times_{S} Y \rightarrow X$ be a projection, $Z\subset X$ be a closed subset. Then $\pi^{-1}(Z)=Z\times Y$. If this is true, I want to know how to prove it, and if this needs some modifications, I want to know it and its proof. This may be a elementary question, so only a good reference will be a great help.


SEO: Multilingual website with different subdirectories for each languages

I have a multilingual website with the following structure:  example.com       <--- Main english version example.com/fr    <--- The french version   Is it important for SEO reasons to put a trailing slash in example.com/fr and make it example.com/fr/ or is it not important?


I installed Ubuntu and it isn't working properly. I have tried everything to fix the issues such as not playing dvds or running windows software through Playonlinux. I tried to reinstall windows from a windows disk and it keeps giving me an error that I don't have enough space on my hard drive to install. I have tried booting from the disk as well with no success. I really just want to reinstall Windows so I can have piece of mind that my laptop will run properly. If anyone out there can help me it would be much appreciated.


Best way to encode text data for XML in Java?

Very similar to , except for Java.  What is the recommended way of encoding strings for an XML output in Java. The strings might contain characters like "&", "<", etc.


How to integrate $\frac{1}{\log(x)}$?  I have tried integration by parts, but it is a never ending series with no specific general term.  PS: It is indefinite integration.


Does anyone know where the third easter egg in Nintendo Nightmare is at?

I've been playing Nintendo Nightmare for a while and I am stuck in the post-ending stuff. I've found the first two easter eggs (the one when you kill the first supposedly 'unkillable' boss, and the one behind the entrance to the Eggman boss). Does anybody know where this might be at. I know this is a sort of niche question, but I figure somebody here might know.


Error while runing Virtualbox in Debian 8

In my attempt to run VirtualBox in Debian 8 I got:  alex@server-2:~$ virtualbox WARNING: The vboxdrv kernel module is not loaded. Either there is no module          available for the current kernel (2.6.32-042stab126.1) or it failed to          load. Please recompile the kernel module and install it by             sudo /sbin/vboxconfig           You will not be able to start VMs until this problem is fixed. Qt FATAL: QXcbConnection: Could not connect to display Aborted   In my attempt to follow this suggestion I got:  alex@server-2:~$ sudo /sbin/vboxconfig [sudo] password for alex: vboxdrv.sh: Stopping VirtualBox services. vboxdrv.sh: Building VirtualBox kernel modules. This system is currently not set up to build kernel modules. Please install the Linux kernel "header" files matching the current kernel for adding new hardware support to the system. This system is currently not set up to build kernel modules. Please install the Linux kernel "header" files matching the current kernel for adding new hardware support to the system.  There were problems setting up VirtualBox.  To re-start the set-up process, run   /sbin/vboxconfig as root.   My kernel version:  alex@server-2:~$ uname -r 2.6.32-042stab126.1   My linux-headers:  alex@server-2:~$ dpkg --get-selections | grep linux-headers linux-headers-3.16.0-4-amd64                    install linux-headers-3.16.0-4-common                   install linux-headers-amd64                             install   In my attempt to get right linux-header I got:  alex@server-2:~$ sudo apt-get install linux-headers-$(uname -r) Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package linux-headers-2.6.32-042stab126.1 E: Couldn't find any package by regex 'linux-headers-2.6.32-042stab126.1'   Then I tried to upgrade my linux kernel in order to be consistent with linux-headers  alex@server-2:~$ sudo apt-cache search linux-image linux-headers-3.16.0-4-amd64 - Header files for Linux 3.16.0-4-amd64 linux-image-3.16.0-4-amd64 - Linux 3.16 for 64-bit PCs linux-image-3.16.0-4-amd64-dbg - Debugging symbols for Linux 3.16.0-4-amd64 linux-image-amd64 - Linux for 64-bit PCs (meta-package) linux-image-amd64-dbg - Debugging symbols for Linux amd64 configuration (meta-package) nvidia-kernel-3.16.0-4-amd64 - NVIDIA binary kernel module for Linux 3.16.0-4-amd64  alex@server-2:~$ sudo apt-get install linux-image-3.16.0-4-amd64 Reading package lists... Done Building dependency tree Reading state information... Done linux-image-3.16.0-4-amd64 is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.   That seems that I have newest version. Now I have no clue what to do next in order to fix my problem with running VirtualBox. Do you have any suggestion?


The limit $\lim_{n\to \infty}\frac{T_n(n)}{e^n}$ where $T_n(x)$ is the Taylor polynomial of $e^x$

From working on a problem I was lead to consider the function $\frac{T_n(n)}{e^n}$ where $T_n(x)$ is the $n$'th order Taylor polynomial of $e^x$.  Numerical evidence suggest that  $$\lim_{n\to \infty} \frac{T_n(n)}{e^n} \equiv\lim_{n\to \infty} \frac{\sum_{k=0}^n\frac{n^k}{k!}}{\sum_{k=0}^\infty\frac{n^k}{k!}} = \frac{1}{2}$$  Is there a nice proof for this statement? More generally: is there a 'standard' approach for evaluating limits on the form $\lim_{n\to\infty}\frac{f_n(x_n)}{f(x_n)}$ where $f_n$ is a series converging (uniformly) to $f$ and where $x_n$ is an unbounded sequence? I would also apprechiate refs. to similar questions on this site or in the literature (I could only find ).


Does light color change when refracting?

When light refracts from a medium to a second one, its frequency stays the same, and its wavelength changes. If this is true, why we see the refracted light ray's colour is the same as the incident light ray in the second medium? The colors should not be the same. If the wavelength changes, colour should change too.


Deep Belief Network configuration for dice face recognition

I should develop a network that can read the result of throwing a dice. I have a dataset which consists on a synthetic collection of such images, together with the corresponding target values. Each image has size 32x32 and is represented as a vector of length 32x32=1024.  So far, I've created a training set by selecting at random 820 images with target 1, 820 with target 2, etc. (The whole data set contains 6x8200 images.)  Then I tried to follow this DBN implementation I found on the readme of  , as follows:  rand('state',0) %train dbn dbn.sizes = [1000 1000 1000]; opts.numepochs =   5; opts.batchsize = 120; opts.momentum  =   0; opts.alpha     =   1; dbn = dbnsetup(dbn, train_x, opts); dbn = dbntrain(dbn, train_x, opts);  %figure; visualize(dbn.rbm{1}.W');   %  Visualize the RBM weights  %unfold dbn to nn nn = dbnunfoldtonn(dbn, 6); nn.activation_function = 'sigm';  %train nn opts.numepochs =  5; opts.batchsize = 120;   [nn,L] = nntrain(nn, train_x, train_y, opts); %[er, bad] = nntest(nn, train_x, train_y);      nn.testing = 1;     nn = nnff(nn, test_x, zeros(size(test_x,1), nn.size(end)));     nn.testing = 0;     [dummy, i] = max(nn.a{end},[],2);     labels = i;      [dummy, expected] = max(test_y,[],2);     bad = find(labels ~= expected);         er = numel(bad) / size(test_x, 1);  net=nn.a{end}'; numRight = size(test_y, 1) - numel(bad');  fprintf('Accuracy: %.2f%%\n', numRight / size(test_y, 1) * 100);    The configuration was based on the one used in , even though it's using a different dataset.  I've used this implementation before on the dataset used in the thesis (the MNIST one) and I obtained good results, but for this problem I'm getting a strange result that the predicted results are almost always the same, so let's say it predicts all test elements as number 2, or all test elements as number 5, etc.  I believe it's because of my configuration, and not a problem with my implementation or anything code-wise (but maybe it is). Is there anything obviously wrong with these parameters values that I should change?


Why are these black dots / spots appearing in my pictures?

I took some shots recently and I noticed that I'm getting a lot of little black dots in my images.  I cleaned my lens thoroughly with the Nikon camelhair brush and retook the pictures but once again, the dots appear.  I'm shooting with a Nikon D7000 and using a starter lens. I've attached an example (notice the black spots on the chairs, on the ceiling, etc).