When I dip a paper towel in a cup of water the water gets drawn up due to . How is this reconciled with conservation of energy, as it would seem on the surface that the potential energy of the system has gone up with no work being done?

Take a glass of water and piece of toilet paper. If you keep the paper vertical, and touch the surface of the water with the tip of the paper, you can see the water being absorbed and climbing up the paper. This climbing up is intriguing me. Where is the energy coming from?  Supposedly, a lot of water molecules are moving up and gaining potential energy. This has to be balanced by something. I can think of a few possibilities, but I can't tell which one it is.   When the water molecules dilute into the paper, they are at a state of lower potential binding energy. Some molecular interaction (van der Waals?) is at lower energy when you have a water+paper solution, compared to a water-only solution. This compensates the gain in gravitational energy. The surface between the paper and the water is at lower pressure than the atmosphere. This causes the water to be pushed into the paper by the atmospheric pressure, up until the point that the column of water above the surface is heavy enough to counterbalance. The potential energy would be a result of work done by the atmosphere. Some water molecules climb up randomly and loose kinetic energy going up, and somehow get "stuck" up there. Something else?


I recently applied for a tourist/visit visa to UAE. The passport I applied with, whose number is on the e-visa I received, is damaged so I couldn't even fly there.  If I get a new passport, is that going to be a problem with Immigration?  Will they allow entry, since I now have a new passport with a number different from that on the visa?

I got my US B1 visa last month on my Indian passport. Someone in my family wrote a phone number on one of the blank page of my passport. As my passport is damaged now, can I travel with my current passport to US or I should apply for new passport? Also, will B1 visa be valid on old damaged passport if I get new passport?


Changing the display mode (resolution and/or refresh rate) causes the screen to flicker or go dark for a few seconds before the image stabilizes. At least this happens on all laptops and desktops I've used. Why ?  As , when using a complex operating system, part of the delay is due to the display software. However I'm not interested in the "software" delay due to heavy user-interfaces and window management, but only in the "hardware" delay which causes flickering, backlight blinks, etc.  This flickering and delay happens between the firmware greet (bios/efi) and the first installed software (OS splash or bootloader), and the same happens when changing resolution from within all the windows and linux versions I've tried, so it obviously has nothing to do with higher level software such as graphical shells or windows managers.  I see multiple (hypothetical!) causes:   Physical delay ?, like for old CRT display there was a low noise probably indicating the power electronics driving the electron beam was reset. Maybe on LCD the backlight power is reset, which causes flickering and delay, but why does it have to be reset? Very slow protocol ? Brian suggested that the resolution change protocol between the GPU and the display panel is slow. Experience shows that the flickering is not as long on newer laptop, which points in this direction. What I don't get is this : listing available resolutions and sending the desired one should take a few (kilo) bytes and video signals transit @Gbps speeds and a few ms latencies, so how come it takes around a second to negotiate a resolution change ? Display embedded electronics reconfiguration : kreemoweet states on  question that there is no protocol involved but each frame caries its resolution. When a frame has a different resolution than the last, the on-board electronics driving the display needs to be reconfigured: registers and buffers are reallocated, etc. The details are blurry but the electronics can efficiently process the video frames once configured, but takes a (relatively) long time to get configured. Maybe some other reason ?

Why does it take so long for a computer monitor to change resolution? Why does it take 2-3 seconds rather than, say, 50 ms?  E.g. my current Windows 7 with strong GPU and 24 inch monitor takes 2-3 seconds. Why so long? I know some might say "it's JUST 2 seconds", but come on... Games produce hundreds of FPS, and monitors work at 60 Hz, so what is it that takes so much time?  I remember this was the same in just about any machine I ever worked with.


My marriage visitor visa was refused on the basis of a document which was tagged non genuine (offer letter from a registered company)   We are considering filing a pre action protocol explaining our situation and proving that the document is true and genuine and get a response from Home office.   Any advice on filing pre action protocol? We didn't find any good lawyers yet, still searching as most of them we spoke to don't seem professional. We are also considering getting married in another country and applying for EEA family permit, will previous U.K. Visa refusal affect my application for EEA, even when we're husband an wife?   Thanks for any advice!

I applied for a marriage visitor visa, to get married to my boyfriend of 2 years.   We met while we were students in the UK and have had vacations together in the two years but not in the U.K.   With the application I had attached an offer letter from a company stating that I have a job offer open starting 3 months later.   This however has been tagged as non genuine, although the company is registered and is run by someone I know.  How can I appeal to this?


From which expansion is this magic the gathering card?

I have a few Magic: The Gathering cards whose editions I'm having trouble identifying. They are obviously from either Alpha or Beta, since they have black borders and the same design as the Unlimited edition, but how can I distinguish between both editions?


Some friends and I were swapping hypothetical scenarios regarding the Potter universe. Polyjuice potion, of course, brought up a number of interesting questions, but perhaps the most unsettling was what the effect might be if, say, a 9-months-pregnant witch consumed Polyjuice Potion made with the hair of an adult male. What would happen - would she successfully transform, with the infant being absorbed into her body and incorporated as part of the transformation? Or would the child remain unchanged within the new male body, as it is a separate entity? Or - the most horrifying possibility - would the infant ALSO transform into a second copy of the adult male, as it is directly connected to the mother's bloodstream, thereby certainly killing its own mother and likely itself in the process?  Cheers.

Polyjuice potions are used a lot through the Harry Potter story, and it's an established fact that it accounts for both age and gender. The only known limitation is that it is only intended for taking on the forms of other humans.  Would a man changing form into a woman (or vice-versa) have functional parts of the opposite sex? It seems to me that all of the appropriate organs would be there, as the potion is all about changing form, but it is not so clear that they would work, as this would imply all sorts of strange effects.  Is there anything canonical which addresses this?


Let $f(x)=0$ if x is irrational and $f(\frac{p}{q})=\frac{1}{q}$ if $p$ and $q$ are positive integers with no common factors. Show that f is discontinuous at every rational and continuous at every irrational on $(0, \infty)$   If $x$ is irrational, then $f(x^-)=f(x^+)=f(x)=0$. It follows the function is continuous $\forall x \in \mathbb{Q}'$     An addition I did here as the statement right above was not sufficient. Any feedback on that part is much appreciated.      let $x$ be irrational and $a,b \in \mathbb{Z}$ such that $$a+ \frac{1}{b} < x$$   By using the density theorem on the real number there exists an infinite number of rational numbers in between such as:    $$a+ \frac{1}{b}< a+ \sum_{1}^{n} \frac{1}{nb}< x$$   As the rational number approaches the irrational number $x$ from the left,   $$\lim\limits_{n \rightarrow \infty} f(a+ \sum_{1}^{n} \frac{1}{nb})=\lim\limits_{n \rightarrow \infty} \frac{1}{nb}=0=f(x)$$   We can proceed similarly to the right of $x$ with $x<a-\frac{1}{b}$      As we approach from the left or right of an irrational number, the function $f$ approaches $0$.       Therefore $f$ is continuous at every irrational number.   If $x \in \mathbb{Q}$, we have $x_n= \frac{p}{q}+ \frac{1}{n}$  approaching from the right $x$ such that  $$\lim\limits_{n \rightarrow \infty} x_n =x $$ It follows that: $$ \lim\limits_{n \rightarrow \infty} f(x_n) = \lim\limits_{n \rightarrow \infty} \frac{pn+q}{qn}=\frac{p}{q} \neq f(x)=\frac{1}{q} $$ It shows that $f$ is not continuous from the right at any rational point of the domain.  Similarly, given $x$ is rational, and $x_m = x - \frac{1}{n}$ approaching $x$ from the left such that : $$\lim\limits_{n \rightarrow \infty} x_m =x $$  $$\lim\limits_{m \rightarrow \infty} f(x_m) = \lim\limits_{m \rightarrow \infty} \frac{pm-q}{qm}=\frac{p}{q} \neq f(x)=\frac{1}{q} $$  It shows that $f$ is not continuous from the left at any rational point of the domain.  any input is much appreciated.

Consider the function:  $f(x)= \begin{cases}  1/n \quad &\text{if $x= m/n$ in simplest form} \\ 0 \quad &\text{if $x \in \mathbb{R}\setminus\mathbb{Q}$}  \end{cases} $  Prove that the function is continuous at every irrational point and also that the function is not continuous at every rational point.  Also, we can say that the function is continuous at some point $k$ if $\displaystyle\lim_{x \to k} f(x)=f(k)$.  I was thinking of doing an epsilon delta proof backwards using the fact that $\mathbb{Q}$ is dense in $\mathbb{R}$ for rational points and irrational points.  Any ways on how to expand on this are welcome.


I'm currently designing a logo in CYMK (in Illustrator CS6). The logo will be used in digital printing, web and for business cards. Is it correct to use CYMK or would it better to use colors from Pantone/HKS?  If CMYK is the correct choice, is it good to export the logo from Illustrator for web publishing? Is there something that I need to ensure that the colors remain the same as in CYMK?

Let's say I'm designing a logo or some other artwork that it's both for printing and screen. How should I set my ai file? CMYK or RGB? Align to grid or not? For instance, when I "save for the web" and my artwork is not align to grid and CMKY, will that affect the result? Do you create separate files for print and screen? Thanks in advance


It's awkward, but to be completely honest: I never understood what eigenvectors are all about. The only reasons I can think of why they could be interesting are:   They are calculated to diagonalize a matrix (which is useful, because one can calculate faster with diagonal matrices?). If one has a linear transformation that represents a rotation, an eigenvector would be the rotation axis. Everybody says that they are used "everywhere".   But I find all of these reasons unsatisfying. The concept of an eigenvector just seems unnatural to me. I associate this concept with a lot of unmotivated calculations. I would love to hear an honest, down-to-earth explanation of why eigenvectors are interesting.  Note: I am not asking what eigenvectors are, my question is purely about why a pure mathematician (not interested in numerical calculations) should care.

What is the importance of eigenvalues/eigenvectors?


I am learning about PCA, regarding PCA I need to know that given a dataset is it always necessary to use centering? what if I don't center the variables used in PCA?

What is the motivation for demeaning the data when doing PCA. I've been told to do it, but I've never heard a good and/or intuitive reason for it. Is this a case where doing it just makes the math easier, or is it more like: if you don't do it, you'll get the wrong answer.  This is something I've been wondering about for a while.  One other question: when you demean the data, do you also need to normalize it (i.e., divide by standard deviation)?


I'm trying to choose a desktop environment for my future laptop, and have this thing with Unity: I generally don't like it so much (lacking configurability, high resources, etc.), but while I was using Ubuntu I found the HUD brilliant.  Is there    Any way to get that HUD in other DEs / with other WMs, or Anything like the HUD in Unity, to search application menus with a keybinding?

The Ubuntu Heads-Up Display (HUD) - you love it or you hate it. Personally I rather like a classic desktop, so I use  or GNOME-fork , and I'd like to keep those menu's where they are.  But the HUD is pretty awesome when your menus are complex and you forgot where an option sits. This makes that search trick very interesting.  I know the HUD is Unity specific. I am looking for a HUD-like tool to complement the menu in shells other than Unity.  There is  for KDE that does this. There is also  for KDE.  Problem with the above is that it uses KDE libs, and it only works for KDE apps.  This is Linux, there aught to be something like this for GNOME/GTK apps, right?  Looking for any tool that can search the menus. I already use(d) ,  and , but those are simply app-launchers (with some tricks). Something like that would suffice if only they included searching the menus for the currently focused application.  The HUD allows users to activate menu items by typing part of the name. It uses a fuzzy search algorithm that will highlight partial matches. It can match menu items that are multiple layers deep in an application's menu hierarchy. The feature, which replaces traditional menu accelerators, is activated by pressing the alt key.  Similar questions:      - AskUbuntu


I need to setup a static IP for eth0, my server has multiple network interfaces and I don't want to bring any of them, except for eth0 down.  I found lot of guides like  but all of them ends with "now restart networking" or "now reboot"  I can't reboot this server, nor I can bring down eth1 even if it was for a microsecond. How would I change eth0 config without touching other interfaces?

How can I restart a network interface? I have a vm that doesn't update its IP address correctly when switching between home and work. The vm runs Ubuntu server and uses a bridged network adapter.


I am wondering this because I love electronics, but I go to a college which is mostly for vocational training. Often times I feel like our courses are 40% waste of time (usually too much industry software and/or uninterested lecturers giving compulsory classes).  So I had this idea of taking a year off to focus on my own projects as I did over last summer.  Since I am not sure a masters degree will teach me anything that a book can not, I was wondering whether I could do applied research at home permanently and potentially make money off of it? Right now I earn some money at home online via a site I own. Not much, but enough to get me by. I know how to read and I spend 10 hours in the library with ease (as I have been told this is how grad students work their way through projects). I mostly work on small-scale electronics, like currently an abbreviated type of joystick for paraplegics (that a paraplegic friend suggested). I work alone, at least at the moment.  Could I work on projects on my own and make a life out of this or should I try to join a good university for my masters? How are people without degrees regarded?

Are there any books on how to be an independent/freelance researcher?


I'm trying to replace all instances of $timestamp = mysqli_real_escape_string($db_conx, $_POST['Timestamp']); with $timestamp = date("Y-m-d H:i:s"); in all files under /home/user/public_html/  I have tried many variations of the below command but can't seem to get the escaping right!  find /home/user/public_html/ -type f -print0 | xargs -0 sed -i 's/\$timestamp = mysqli_real_escape_string(\$db_conx, \$_POST['\''Timestamp'\'']);/\$timestamp = date(\"Y-m-d H:i:s\");/g'

Take the following script:  #!/bin/sh sed 's/(127\.0\.1\.1)\s/\1/' [some file]   If I try to run this in sh (dash here), it'll fail because of the parentheses, which need to be escaped. But I don't need to escape the backslashes themselves (between the octets, or in the \s or \1). What's the rule here? What about when I need to use {...} or [...]? Is there a list of what I do and don't need to escape?


Can somebody help me to evaluate $$\lim_{(x,y,z) \rightarrow (0,0,0)} \frac{xy+4yz^2+5xz^2}{x^2+y^2+z^4}?$$ The first thing I tried to do was set $x=y=0$ and evaluate the limit, and I got that the limit of the function was $0$. I did the same thing for $x=z=0$ and $y=z=0$. So, I was pretty confident the limit was $0$. My online homework said that was incorrect. I think set $x=y$, set $z=0$ and took the limit, which was $\frac{1}{2}$. So basically, I found a direction in which to take the limit that didn't agree with the other directions. Can somebody tell me more about how I should think about this? How would I know to set $x=y$ in the future? I felt like it was a lucky guess. Thanks!

Study the following limit: $$ \lim\limits_{ (x,y,z) \to (0,0,0) } \frac{xy-z^2}{x^2+y^2+z^2} $$   I'm not sure if this way of proving that the limit does not exist is correct so I'm this is basically for a proof verification.  Approaching $(0,0,0)$ through the plane $z=0$, then the limit becomes  $$ \lim\limits_{ (x,y) \to (0,0) } \frac{xy}{x^2+y^2} $$  Now this limit does not exist, because approaching $(0,0)$ through the line $y=0$, the limit becomes  $$ \lim\limits_{ x \to 0 } \frac{0}{x^2} =0$$  But if we approach $(0,0)$ through the line $y=x$ we have that  $$ \lim\limits_{ (x,x) \to (0,0) } \frac{x^2}{2x^2}=\lim\limits_{ (x,x) \to (0,0) } \frac{1}{2} =\frac{1}{2}$$  So the limit $ \lim\limits_{ (x,y) \to (0,0) } \frac{xy}{x^2+y^2} $ doesn't exist. This means that the limit we began with doesn't exist, correct?


The  shows an effect previously seen in movies like “The Matrix”.                                  What is it is called and how is it made?

I am always amazed by 3D still shots in which the action freezes and a character is able to walk around and the people are frozen like statues. How do they do that?  Some of the famous movies featuring 3D still shots:   The Matrix (1999) Clockstoppers (2002) circus scene in Big Fish (2003) Cashback (2006) The bar scene in The Other Guys (2010) Quicksilver scene in X-Men Apocalypse (2016)   The movie "Clockstoppers" completely revolved around this time stop effect.


[man] makes himself the instrument of somebody or something outside of   himself; he need not solve the problem of living by productive   activity.   Bold part means “a man doesn't need to solve any problems”, not “a man have no problems to solve”? Is it common phrase?

The header of  states:     High-level languages need not be slower than low-level ones.     Why use need not instead of do not need? What does it mean? Also, why no to before be?


I checked by ls -al in my home directory but I don't see .bashrc file in my home directory. Ubuntu 18.04 release notes does not mention anything about this. I installed it without formatting previous /home partition after deleting files like .bash_, .local, .gnome, etc. I am able to use the pc like normal but where is the bashrc file now? Isn't it supposed to be recreated automatically?

For instance, if I were to run the command adduser test, is the .bashrc created automatically upon creation of the home directory for the user test? If it's not created upon user creation, under what conditions is it created?  Also, if I add a .bashrc file to the home directory of a user, will it be overwritten by the OS?  Thanks in advance.


I have a tiny hard drive - 128 GB. I am not that technical. I see that other files under storage is taking up say 40 GB of space. My boyfriend got me a WD NAS hard drive and I was able to move my photos from iPhoto, and iTunes, there to free up some space. I accidentally deleted iPhoto so in order to install it. My boyfriend showed me a script that showed the size of some big directories.  .3G   /Applications/iMovie 9.0.9/iMovie 9.0.9.app/Contents/Resources 1.3G  /Applications/iMovie 9.0.9/iMovie 9.0.9.app/Contents 1.3G  /Applications/iMovie 9.0.9/iMovie 9.0.9.app 1.3G  /Applications/iMovie 9.0.9 2.0G  /Applications/iMovie.app/Contents 2.0G  /Applications/iMovie.app 5.3G  /Applications/Install OS X Yosemite.app/Contents/SharedSupport 5.3G  /Applications/Install OS X Yosemite.app/Contents 5.3G  /Applications/Install OS X Yosemite.app 1.1G  /Applications/iPhoto.app/Contents/Resources 1.3G  /Applications/iPhoto.app/Contents 1.3G  /Applications/iPhoto.app 1.0G  /Applications/Microsoft Office 2011/Office 1.2G  /Applications/Microsoft Office 2011  Can i delete the iMovie directory and maybe download it at a later time? Is there a better way to figure out where all the space is being taken up? Like lets say I had an 18 GB zip file saved on my desktop. Theoretically that would be under the other space category but OS X isn't helping make me aware of that file. How do I find big files like that? Mind you i don't have a 18 GB zip file sitting around but I am trying to find if I have any big files sitting around to delete.

Every few days I get notices on my MacBook that it's running or run out of hard drive space. Curiously, restarting the computer will enable me to recover gigabytes of space (this past time, it was able to recover about 2.2GB). However, I can't identify anything in my personal activity that consumed that space.  It's possible that it's a rogue iTunes podcast or a huge software update that my Mac is automatically downloading - would either of these reclaim the space upon a restart?  One possibility that I can think of is that FileVault has some sort of disk leak, allocating but not freeing files. Does this make sense? Is there a tool that I can run to determine where this space is going? Assuming it is FileVault, should I try to disable it? What's the best way to turn of FileVault on a nearly full computer?


I need to start unit testing for my angularjs app, I am a bit confused with, which is best framework out of Protractor or Jasmine.  Majorly I need to test controller functions, services, dependency injection, state data.  Please suggest which one to go for.  You can suggest any other better framework also apart from these two.

I've looked into and considered many JavaScript unit tests and testing tools, but have been unable to find a suitable option to remain fully TDD compliant. So, is there a JavaScript unit test tool that is fully TDD compliant?


I'm writing a report right now (in an article class, I know.. But I didn't want to have a Chapter as my top level of organization), and the report guidelines specify a memorandum/letter of submittal after the title page.   I was wondering if it's possible to have an "environment" of a memo (TexMemo is one I saw a lot while googling this question) inside my article class.     Thank you!

Let's say I have a document that has many pages and some pages have different formats. For example, most of the pages are fine with \documentclass{article} but there may be pages in the middle that I want to be \documentclass{letter}. I want my letter pages to be numbered inline with the other pages and have them show up in the Table of Contents.   Is it possible to change the class used for an individual or range of pages while still keeping things like page numbering consistent across them?   EDIT I'm trying to create a "welcome to the company" sort of document that has a cover page, table of contents, welcome letter, then various sections of information. I've never tried this in anything other than a word processor where it's easy to set "master pages" or "template pages" for individual pages in the document. So I could use a letterhead template page for the welcome letter part and a standard article-type template for the rest and still have the letter numbered/referenced in the ToC.   So the idea was to take advantage of the classes written, if possible, rather than have to format a single page by hand differently from the rest.


I know how to make proofs by induction, but I don't understand why it prove that the propriety is true. It's in fact logical, but how to prove that proof by induction really prove the assertion.

I just realized something interesting. At schools and universities you get taught mathematical induction. Usually you jump right into using it to prove something like   $$1+2+3+\cdots+n = \frac{n(n+1)}{2}$$  However.  I just realized that at no point is mathematical induction proved itself? What's the mathematical induction's proof? Is mathematical induction proved using mathematical induction itself? (That would be mind blowing.)


I am trying to edit a list of lists by   s[0][0]=1   but instead of just the first number in the first row changing to 1, the first number in all the rows are changing to 1.  I was first taught python using 2.7, but the class I'm taking now requires 3.4. Was there a change in syntax between the two versions? Otherwise, what am I doing incorrectly?   Thanks in advance

I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


I'm really interested on how to simulate physical systems that I'm currently studying as a first year student at University. For example, how to replicate a Pendulum using different algorithms (Euler's formula, RK4, ...), how to draw a vectorial field, how to recreate the N-Body problem and what are the bests current technics, ... The problem is that I didn't find a lot of books on that particular subject, but only "random" articles on them. Does anybody knows good books about this subject?

Can anyone recommend some good textbooks for undergraduate level computational physics course? I am using numerical recipe but find it not a very good textbook.


I found this phrase in the Clean Code book:     Pragmatic Dave Thomas and Andy Hunt said this a different way.   Is this phrase correct? From what I know, one should write:     Pragmatic Dave Thomas and Andy Hunt said this in a different way.

I have asked the same question in ELL stackexchange, but unfortunately haven't received enough answer/comment. The one answer I got is not satisfactory. So that's the reason I am asking it here again. .  I have seen in some cases prepositions are omitted before some noun phrases. And it's explained that those phrases are actually an adverb phrases. But I know a simple thing. If the head of the phrase is a noun, it's a noun phrase. If the head of the phrase is an adverb it is an adverb phrase. For example -   Look both ways before crossing the road. [both ways is a noun phrase, where the head is ways, but still there is no preposition.]  He approached me in a friendly way. [a friendly way is a noun phrase, where the head is way, but as expected unlike sentence #1 it's preceded by the preposition in. And I have never seen this phrase is used without a preposition. I believe dropping the preposition is wrong, according to the grammar.]  She made a pickle a different way from her mother. [a different way is a noun phrase, where the head is way, but strangely there is no preposition before it. But I have seen examples of a different way used both with prepositions and without prepositions. I think the preposition here is optional.]    Now from these example sentences I have tried to demonstrate my problem/confusing area. My question is - 1. When a noun phrase is used as an adverb phrase? 2. When before a noun phrase the placement of preposition is obligatory (like sentence #2)? And where it's optional (like sentence #3)? And where placing the preposition is wrong (like sentence #1)?


I'm always missing appointments because the event notifications in Calendar app are so pathetic.  I when its time to leave for an appointment, I want my phone to ring as loud as possible as if I'm getting a phone call, and to continue ringing until I turn it off.  Is there any app/SaaS for this?

I miss many calendar reminders because they're just too subtle. I might put my phone down and walk out of the room for 5 minutes, missing the reminder, then come back and not touch my phone again for an hour; completely missing an important appointment.  If reminders worked like alarms, they would make their notification sound continuously (up to a point, like alarms: ~10 minutes), and take over the whole screen, until silenced. That would be preferable to me. Is there an app that can do this?


Suppose that the vector [1, 1] is an eigenvector of a matrix A corresponding to the eigenvalue 3 and that [2, 1] is an eigenvector of A corresponding to the eigenvalue -2. Compute $A^2$ [4, 3].   Can someone please guide me on where to start?  Thank you

Question:     Let $A$ be a $3 \times 3$ Matrix such that $[-3,4,1]$   is the eigenvector corresponding to eigenvalue $3$, and $[6,-3,2]$ is an eigenvector corresponding to the eigenvalue $2$. If $v$ = $[0,5,4]$, compute $A^{2}v$.      Hint: $[6,-3,2]+2[-3,4,1]$ = $v$   Where I'm stuck:  I know that we can  solve A with the equation:   A = $P^{-1}DP$, where $P$ is the matrix consisting of the eigenvectors and $D$ is the matrix consisting of the eigenvalues.  However, since $A$ is a $3$ x $3$, we should have a $3 \times 3$ matrix $D$ and $ 3 \times 3 $ matrix $P$ as well, consisting of the eigenvalues and eigenvectors respectively - and in this case, we only have two eigenvalues and two eigenvectors. Where can I obtain the other one of each?  Any help will be very appreciated.  Thank you.


I have a problem that I am sure the solution is so easy but I am not able to find it. I have an ArrayList of smaller ArrayLists. Those lists contain elements of type String. I want to merge the smaller lists to one and then remove the duplicates. Let me be clear.  I have this:   [[USA, Maine], [USA, Maine, Kennebunk], [USA, Maine, North Berwick],  [USA, New Hampshire], [USA, Keene, New Hampshire], [USA, Keene, New  Hampshire, Main Street], [USA, New Hampshire, Swanzey]].   This is my main list that has smaller lists inside. I want to have a final ArrayList which is the merge of the smaller ones and get the duplicates deleted.   What I want is:  [USA, Maine, Kennebunk, North Berwick, New Hampshire , Keene, Main Street, Swanzey]   Any help is appreciated. Thank you

I have an ArrayList<String>, and I want to remove repeated strings from it. How can I do this?


I am trying to concatenate two fields into one label, where the second field sometimes has a NULL value.  The first field is a numerical street address (ADR_NO) the second field is a text string (ADR_NO_SFX).  I want to combine them like this:  13, 13A, 14, 15, 15A, etc  I tried the solution here  but the expression dialogue throws an error.  I also tried this, but I get empty labels whenever "ADR_NO_SFX" is NULL.   CASE WHEN  "ADR_NO_SFX" = NULL   THEN "ADR_NO"   ELSE "ADR_NO" || '-' || "ADR_NO_SFX" END

I am having some issues trying to show multiple fields for a single label in QGIS. In QGIS2.6, attempting to display labels for a feature consisting of multiple fields results in an empty label if one of the fields is null. So for example, in the label expression dialog:  concat("Temp Site",'\n',"Notes",'\n',"Function")   will function normally unless one of the fields is null, then it results in no label being shown. Using the '||' operator instead in the expression dialog also results in the same behaviour:  "Temp Site" || '\n'  ||  "Notes" || '\n'  ||  "Function"   Is there a way to display the labels even if one of the fields is null?


How do I create a new tag in the mobile iOS/ Android app? This operation is currently not supported.  When I tap the tags section, a search window opens; when I type something not existing and press Done, the tag section remains blank.  Please add such option to the apps. It is specially important in case of newly launched sites.

When I was using the mobile version of an SE site I got prompted with the error:     new tags cannot be created from the mobile site. The tag 'sometag' is new.   Why is this so?


here I want to ask, I am familiar with ubuntu, with unity, shortcuts, etc.  I have learned about Kali linux, I have installed Kali linux in my PC but I am not familiar with the environment,  I've had Kali linux Iso,  My Laptops is installed Ubuntu LTS 12.04,  Can I install a Kali Linux Package from iso into my ubuntu,

I want to know if there is any way to install Kali tools like sqlmap, nikto, john, aircrack-ng, ... on Ubuntu 12.04?  If yes, then how should I proceed?


I am trying to scrape a web page containing the names of companies. The names are between  tags. The format is:  <option value="15589" id="optExhibitor15589" title="N571  Company One, Inc">N571 Company One, Inc</option> <option value="16441" id="optExhibitor16441" title="N873  Company Two">Company Two</option> <option value="14863" id="optExhibitor14863" title="N219  Company Three">N219 Company Three</option>   I've tried breaking the file into a list of lines using .readline() but I cannot figure out how to extract the text between thetitle= and ">.  I have hundreds of these names I want to extract and I want to produce a list of the company names.

I'd like to extract the text from an HTML file using Python.  I want essentially the same output I would get if I copied the text from a browser and pasted it into notepad.    I'd like something more robust than using regular expressions that may fail on poorly formed HTML.  I've seen many people recommend Beautiful Soup, but I've had a few problems using it.  For one, it picked up unwanted text, such as JavaScript source.  Also, it did not interpret HTML entities.  For example, I would expect &#39; in HTML source to be converted to an apostrophe in text, just as if I'd pasted the browser content into notepad.  Update html2text looks promising. It handles HTML entities correctly and ignores JavaScript.  However, it does not exactly produce plain text; it produces markdown that would then have to be turned into plain text. It comes with no examples or documentation, but the code looks clean.    Related questions:


I see this a lot on Facebook. Two people doing a thing, and the picture captioned with: "John and I waiting on the bus" "Mary and I at the Beyonce show" "Sally and I with our awesome guide Sven"  I think it should be "Joe and me" but I'm not sure why. Is there an implied "this is" at the beginning of each sentence, making Joe and me the object rather than the subject?

From some comments in the answers for  (now deleted, 10k only), there's confusion around the usage of I vs. me:  While the sentence, "the other attendees are myself and Steve," is agreed to be incorrect, there's confusion about whether the correct form is "the other attendees are me and Steve" or "the other attendees are Steve and I."  (I've always used the heuristic of removing the other people from the sentence, so I always thought "the other attendee is me" would be correct, instead of "the other attendee is I." Is this true, or am I using a flawed heuristic?)


Another question....  I am looking for an Excel formula that will calculate the following...Based of a cells date, I want a cell to return the date of the prior Friday unless the initial cell's date is Saturday then I want the cell to return the date of 2 Friday's prior.   Example...if cell A1 has a date of 10/17/17, then cell A2 will return the date of the prior Friday of 10/13/17. If the date in cell A1 is a Saturday (like 10/21/17) then cell A2 would return the date of the previous Friday (10/13/17 NOT 10/20/17).   This question deals specifically with Friday. My previous post/question was different days. I am not familiar with this complex of a formula. I tried to edit the formula I have for my previous question (=IF(WEEKDAY(A1-2)=1,A1-4,IF(WEEKDAY(A1-2)=7,A1-3,A1-2)), but I am not knowledgeable of this complex of equation.

I want a formula that will return a date that depends on the date in another cell, but modified by the day of the week of the date in that cell.   If cell A1 has a date value that is a Sunday, Monday, or Tuesday, I want cell A2 to return the date of the Friday before (e.g. if A1 is Monday 16 Oct 2017, A2 would return Friday 13 Oct 2017). If the date in cell A1 is Wednesday through Saturday then the date in cell A2 would be two days prior to the day (e.g. If A1 is Thursday 19 Oct 2017 then cell A2 would return a date of Tuesday 17 Oct 2017).   I want the formula to do all of the above calculations in one formula.


I have this NSString:  <title>My Friends Website</title>   How do I pull out My Friends Website into it's own NSString on iOS with Objective-C?

There are a couple of different ways to remove HTML tags from an NSString in Cocoa.   is to render the string into an NSAttributedString and then grab the rendered text.   is to use NSXMLDocument's -objectByApplyingXSLTString method to apply an XSLT transform that does it.  Unfortunately, the iPhone doesn't support NSAttributedString or NSXMLDocument. There are too many edge cases and malformed HTML documents for me to feel comfortable using regex or NSScanner. Does anyone have a solution to this?  One suggestion has been to simply look for opening and closing tag characters, this method won't work except for very trivial cases.   For example these cases (from the Perl Cookbook chapter on the same subject) would break this method:  <IMG SRC = "foo.gif" ALT = "A > B">  <!-- <A comment> -->  <script>if (a<b && a>c)</script>  <![INCLUDE CDATA [ >>>>>>>>>>>> ]]>


When I was first learning Linux I recall reading that because it is so widely used, "nobody" is (jokingly?) known as the "second most privileged user, after root" on Unix machines.  A quick google search seems to corroborate that it is a common saying, not just a quirk of the author I was reading.  Why is this a common saying?  Is it really true?

On my server (Synology DS212) some files and folders have nobody nobody users and groups. What are the characteristics of this user and group? Who can write of read this file?    How can I change it ? For which user and group?


I'd like to obtain the size of a file, but pesky leading indentation gets brought along. Consider the following two scenarios: ❯❯❯ printf "Size: %s\n" $(wc -c < <(echo test)) Size: 5  Here wc is being provided with an file descriptor being sent "test\n" so it produces an output of 5 bytes. This is as expected. ❯❯❯ SIZEVAR=$(wc -c < <(echo test)); echo $SIZEVAR | xxd 00000000: 2020 2020 2020 2035 0a                          5. ❯❯❯ printf "Size: %s\n" $SIZEVAR Size:        5  Here we see things start to fall apart when using a straightforward variable assignment to cache the output of wc. I've lost the "whitespace trimming operation"! I have double-quoted neither the shell interpolation upon variable assignment nor the variable upon use. How can I force the variable assignment to trim? Perhaps with a printf? Is there a less ugly or at least more concise way to achieve it?  Originally I thought this was bash behavior but it turns out this behavior is due to zsh. bash behaves as expected. Leaving question open because I'm still very curious why zsh behavior diverges here and I'd love to know the root cause.

I know that Bash has word splitting but zsh doesn't, and I'm not familiar with others(csh, tcsh, ksh, etc), but I was wondering if it is a part of any standard.  In other words, does sh have word splitting, or is it a Bash-only feature? If I wanted to write a portable shell script, would I have to account for word splitting, or is it something nonstandard that is added by other shells?


The plane that passes through the point $(−1,1,2)$ and contains the line of intersection of the planes $x+y−z=5$ and $2x−y+3z=1$.

Find equation of a plane that passes through point P $(-1,4,2)$ that contains the intersection line of the planes  $$\begin{align*} 4x-y+z-2&=0\\ 2x+y-2z-3&=0 \end{align*}$$  Attempt: I found the the direction vector of the intersection line by taking the cross product of vectors normal to the known planes. I got $\langle 1,10,6\rangle$. Now, I need to find a vector normal to the plane I am looking for. To do that I need one more point on that plane. So how do I proceed?


I have a large house model that is composed of other models. Some of the models in the house for example doors are joined together.    How can I select entire model and separate into loose parts?

I've just made a set of armor by using a male body mesh model I downloaded and selecting certain faces from the model and duplicating them to create viable armor pieces.   Since the pieces are just duplicated from the same mesh male model, then it's still part of the same object.   How do I separate the armor piece from the model to make the pieces separate?


Now and then, I'll unlock my computer and see this:    You can see in the bottom-right corner that when I open the calendar, nothing is shown. This is true for most applications.  Now look at the bottom-left:    The fonts used in the MATE toolbar are, unlike most applications, just mostly invisible! They have changed color from white to a dark, translucent color that blends in with the rest of the panel.  What could possibly be causing this? A reboot fixes it, but I'd like to ensure that it doesn't happen again.  I am running Ubuntu 16.04 64-bit. I have upgraded from Ubuntu 14.04 64-bit. Before  you ask, I do not have a graphics card. I have integrated graphics:  $ lspci | grep VGA 00:02.0 VGA compatible controller: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics Controller (rev 06)

I find that often after awakening from suspend on Ubuntu GNOME 16.04 with GNOME 3.20 (I have only found this issue on the latest version, though I have not tried with GNOME 3.18 on 16.04) that I get this strange font issue which can't be fixed by restarting gnome-shell and seemingly only by restarting my entire machine:            I do not believe that this is a theme issue as I have tried all the built-in themes (including the dark and light versions) and it is the same for them all. Though it does not seem to affect gnome-shell areas, that is the top-bar, the Activities Overview, etc, are not affected for some reason. So what could this issue be caused by and how can I fix or workaround it?  Information Update:  I have had a look at  but the only options in the gnome-tweak-tool for Antialiasing are Rgba, None, and Grayscale, but none of them seem to have any affect on the issue. Is there something I'm missing?


I am not sure how it happened but all my faces are now semi-transparent in Edit Mode.    I have tried multiple settings to get solid faces back. I am not in wire frame mode and I made sure that "Limit selection to visible" is disabled as see in the picture. I have no idea why I can't get my solid faces back.   Any help is greatly appreciated,  BloodHound27

I changed my Blender Units to Metric System, but when I'm building things, my meshes are transparent, i.e. I can see through faces like in wireframe even though my wireframe is turned off. All faces have a light white in non-wireframe mode, but I can still see through them.   How do I reverse this?  Another issue I get is this    Looks like clipping is not working properly.


I'm facing float point precision problem in my C++ code  given double d = 32.4;  d / 0.01 == 3240.0;   gives true, while   d / 0.1 == 324.0   gives false.  But if I multiple by 10 and 100 then the result are both true.  Since 32.4, 324 and 3240 can all be represented by 64bit double without any precision loss, so this result is quite confusing to me. (I'm not very familiar with multiplier and divident operation in float point)  In my use case, I will do some conversion among different scale, by simpliy multiplying or dividing something like 0.1, 0.01, 0.05. I mean, I don't require very high precision, my operands are usually less than 6 decimals, which can be represent in 64bit double without precision loss, so I want to get consistent result. I have a guess: should I always use multiplying instead of dividing in my use case?

Consider the following code:   0.1 + 0.2 == 0.3  ->  false   0.1 + 0.2         ->  0.30000000000000004   Why do these inaccuracies happen?


Is there a good summary of theorems to apply when deciding if a polynomial in $\mathbb{Q}[X]$ is irreducible, specifically one with positive integer coefficients?

Given a polynomial over a field, what are the methods to see it is irreducible? Only two comes to my mind now. First is Eisenstein criterion. Another is that if a polynomial is irreducible mod p then it is irreducible. Are there any others?


I have edited some question post on stack overflow, then after some other user also made edit on that post. My question is in this case my edited will be count towards edited post by me or not. It will be counted towards to get badges related to edit post.?

I have been editing few questions on Stack Overflow for formatting and spelling mistakes. But I have noticed, that after my edits, some other user also edits the same question and his name shows up as the last edited person on the question.   Since I had already edited that same question, does my edit count be +1 for such edits too and count towards my total no. of edits? Similarly for cases where my edits have been rolled back by the OP, even in that case does my edit count increase by 1?  Additionally, if I edit same question again twice, does my edit count be increased by 2?


Let G1 and G2 be two regions.  Suppose that G1 ∩ G2 ≠ 0.  Show that G1 U G2 is connected.  I know I have to first show that G1 U G2 is open and then show it is connected but I have no idea where to start or how to even prove this.

Let $\mathscr{F}$ be a collection of connected subsets of a metric space $M$ such that $\bigcap\mathscr{F}\ne\emptyset$. Prove that $\bigcup\mathscr{F}$ is connected.   If $\bigcup\mathscr{F}$ is not connected, then it can be partitioned into two disjoint, non-empty subsets $A,B$. Let $x$ be a point in $\bigcap\mathscr{F}$. Then either $x\in A$ or $x\in B$. I don't know where to go from here.


I try resize my devtmpfs size, by add a row to /etc/fstab.  This is my fstab file :  # <file system> <mount point>   <type>  <options>       <dump>  <pass> # / was on /dev/mmcblk0p2 during installation UUID=6e7b65b0-f9ce-4a0d-97fd-73374d0a8492 /               ext4    errors=remount-ro 0       1 # /boot was on /dev/mmcblk0p1 during installation UUID=26c4e594-31fe-49ab-844a-a2e7e195ea36 /boot           ext2    defaults        0       2 0       0 # Define devtmpfs size udev /dev   devtmpfs  rw,relatime,size=102400k,nr_inodes=217992,mode=755  1  0   But during reboot machine I get these rows :  EXT4-fs (mmcblk0p1): mounting ext2 file system using the ext4 subsystem EXT4-fs (mmcblk0p1): mounted filesystem without journal. Opts: (null) [....] Mounting local filesystems...mount: udev is already mounted or /dev busy failed.   What I make wrong ?

My new kernel has CONFIG_DEVTMPFS enabled, and thus my /dev is mounted as devtmpfs. My old kernel was not using CONFIG_DEVTMPFS, and /dev used to be mounted as plain tmpfs.  Now I have noticed, the size of /dev/ is ridiculously large: 8GB, which is half of my RAM:  df | grep devtmpfs devtmpfs         devtmpfs  7.8G     0  7.8G   0% /dev   In the past, when my /dev was mounted as tmpfs, the size used to be 10MB  df | grep tmpfs tmpfs                 tmpfs        10M     0   10M   0% /dev   Seems to me, 10MB is more than enough for /dev. Why does /dev/ allocate 50% of my RAM by default? Where can I change this ?


Harry is a half-blood and Ginny is a pure-blood, so what does that make his children? I've been told it means they are pure-bloods but I can't be sure. What do you think?

I was checking on something in the Harry Potter wiki and saw Harry listed as "Half-Blood."  Both his parents were magical, but, as we know, his grandparents on his Mother's side were muggles.  This reminds me of the racially loaded terms like octoroon.  (In the south, you still hear those terms every once in a while.)  When there was still segregation, having only 1 great-grandparent of an ethnic group was enough to classify a person of that group.  So how far down the line did it go in the Harry Potter universe?  Just how many generations removed from a muggle-born would a person have to be before they're no longer classified as half-blood or something similar?


Apparently GNOME has been "improved" so .desktop files can't be executed. Previously I could add a bash script to favorites by creating a .desktop file for it. I can't find an alternative.  I'm envisioning some generic helper I can execute and pass my script name to.  I want to put this script in my favorites so it can be executed by mouse-click by someone not very computer savvy.  I've done this before.  Once the .desktop file has been created, there used to be a "make executable" option in its context menu (not the "Allow executing file as a program" in Properties - Permissions).  That's not there now.  So I can get the script to open in my editor of choice by double-clicking on its icon on the desktop but not to run.  Does anyone have a solution?

I have made .desktop files for Ubuntu 16.04 to access my Google Chrome profiles, but once I upgraded to Ubuntu 17.10 (it worked up to Ubuntu 17.04) they got removed from the dock and I can't pin them back. Sample File: #!/usr/bin/env xdg-open  [Desktop Entry] Version=1.0 Type=Application Terminal=false Icon[en_US]=google-chrome Name[en_US]=Google Chrome Exec=google-chrome --profile-directory=Default Comment[en_US]=Chrome Name=Google Chrome Comment=Chrome Browser Icon=google-chrome Categories=Browser;Internet;


Life for me ain’t been no crystal stair   (", by Langston Hughes)  As per my knowledge we can't use Two Negative words in a clause or a sentence .I did research But could find anything . Could anyone tell me how the author has used two negative. IF THERE IS ANY RULE PLEASE ELABORATE .AND ONE REQUEST PLEASE EXPLAIN ME THE MEANING IF THE SENTENCE

In contemporary American English usage, I come across sentences like:   I ain’t got no money.  Ain’t no man like him.    Saying ain’t no sounds incorrect to me because it is a double negative.  What is the origin of this particular construction? I wasn’t able to find anything online related to the origins of this incorrect usage.


I am using a double sided document for my report, which always have new chapters starting on a page to the right, which sometimes means leaving a page blank. However, for my appendix I would like to not leave any pages blank. Is it possible to force the 'openany' command after the conclusion? Or in some other way remove the blank pages?  I could perhaps also separate my appendix using a different command than \chapter, but I like the table of contents as shown below:

I am writing my thesis using   \documentclass[12pt,a4paper,twoside]{book}   At the end of chapters, I get a blank page. This is because chapters start from right side (Odd page number, [RO] and that at the end of each chapter book.cls has a \clearpage by default. I do not want Openany as a solution.  How do I adjust my TeX document then to remove these blank pages?  thanks


three men drop their hats off at the cloakroom when entering a restaurant and choose at random when taking out 1 of the 3 hats.  Calculating the probability that none of the 3 men take their own hats.   The total outcomes are 3! = 6  There are favorable outcomes: those that have neither 1 in the first position, nor 2 in second, nor 3 in third.  With manual counting, there are then 2 favorable outcomes.  The probability is, therefore 2/6  All is good, but how can I find the number of favorable outcomes when 50 drop their hats off at the cloakroom?     Edit:   After research, the precise answer is the nearest integer to n!/e, 50!/e in my case.

I understand the whole concept of Rencontres numbers but I can't understand how to prove this equation  $$D_{n,0}=\left[\frac{n!}{e}\right]$$  where $[\cdot]$ denotes the rounding function (i.e., $[x]$ is the integer nearest to $x$). This equation that I wrote comes from solving the following recursion, but I don't understand how exactly the author calculated this recursion.  $$\begin {align*}  D_{n+2,0} & =(n+1)(D_{n+1,0}+D_{n,0}) \\ D_{0,0} & = 1 \\ D_{1,0} & = 0  \end {align*} $$


Here my code:  As you can see on the image, the first space is squeezed; I don't understand why.  \documentclass{article}  \usepackage{datatool} \usepackage{colortbl}  \begin{filecontents*}{bogus_first_char.csv} nom, prenom A la la, toto B lala, titi C yoyo, tutu \end{filecontents*}  \begin{document}  \DTLloaddb{dat}{bogus_first_char.csv} \begin{tabular}{ll}   nom & prenom \\   \DTLforeach{dat}{\nom=nom, \prenom=prenom}{   \\ \nom & \ prenom} \end{tabular}  \end{document}

I've come across a strange problem with datatool. If the first character of the first column of a row is immediately followed by a space, that space gets gobbled somehow.  Am I doing something wrong or is this a bug?  \begin{filecontents}{\jobname.csv} Sentence1,Sentence2,Sentence3 The child played a new game.,He played it three times with his friends.,He loved the game. I visited my childhood home last week.,It's just as I remembered it.,My house has always been white. It's just as I remembered it.,I visited my childhood home last week.,My house has always been white. \end{filecontents} \documentclass{article} \usepackage{datatool} \DTLloaddb{sentences}{\jobname.csv} \begin{document} \DTLforeach{sentences}{% \sOne=Sentence1,\sTwo=Sentence2,\sThree=Sentence3} {% \sOne\par \sTwo\par \sThree\par } \end{document}   Here's the output.  Notice that the  sentence in column 1 of the CSV file (marked with the red arrow) has the gobbled space, but the exact same sentence in column 2 (marked with the blue arrow) doesn't have the space gobbled.


Where can we go?   Where could we go?              Can you pass me the salt?   Could you pass me the salt?      Which sentence is more appropriate and why? What are the differences?

I'm a native English speaker and I've been doing some research into English grammar for a programme I'm working on. However, on looking into modal verbs, I've only just come to appreciate how subtle and complicated they are.  What is the difference between these sentences? What possible different response might one have to each?        I can go to the cinema tonight.   I could go to the cinema tonight.   I may go to the cinema tonight.   I might go to the cinema tonight.      Granted, the first of these looks more like a statement of ability or possibility than the three that follow. But in what ways does it differ from the others, since all suggest ability and possibility? And crucially, what distinguishes the other three.  Perhaps it's a matter of tone, of context, of the speaker... The question may appear quite simple but I haven't found a satisfactory answer elsewhere.    looked quite useful in that it covered levels of confidence and certainty but it was talking about the potential state of something rather than the possibility for the person who is speaking. Are there any differences in that sense?   looked at these verbs used in question form (e.g., differences between 'Can I...?' and 'May I...?') but I'm not so interested in that for now.  Any thoughts appreciated.


Is there any way I can make apt-get wait for the other apt-get (or another package manager) process to finish?  I know that, generally, apt-get can only run one instance at a time and if we try to run another apt-get instance at the same time, then we get a message saying that some other process is using it.  My question is: how can I make apt-get wait for the other processes to finish and then run?  An advantage is that there is no need to type the command apt-get again, it will be automated after the 1st apt-get finishes.

I have seen many softwares such as Update Manager and Synaptic Package Manager, they wait if some other program is using the /var/lib/dpkg/lock and is locked. How can we do this through the Terminal? I saw apt-get's manual but didn't find anything useful.


I use Ubuntu 20.04. Budgie desktop + Plasma + Pantheon. I am stuck in login loop. Have dual -boot. Windows and Ubuntu. Recently, suddenly i got login loop. Tried everything on internet, nothing worked. Actually i tried installing Xubuntu it worked. But no background in Xubuntu. All apps DID NOT WORK. Problem with graphics maybe. And budgie, plasma and pantheon still not working. Now Xubuntu also not working......Still in login loop..... PLEASE HELP! I tried reinstalling. That also did not help. I tried playing with .Xauthority and .ICEauthority and everything else.I mean chowning and trying removing them. Didn't help. I remember it happened after a windows update.(A small one). Sometimes i try to use startx. But it sometimes says [xinit:connection to x server lost]. This is new issue than others. SO i need help.

My Ubuntu is stuck in a login loop when trying to enter my desktop. When I login, the screen gets black and soon after that the login screen comes back.   I've read that the problem might be caused by an error depending on the graphics, here's my graphics card: ATI Radeon 7670M


In the concrete case that $\mathcal{O}_K = \mathbb{Z}[i]$, and $\mathfrak{p} = (1+i)$, how to make sense of $\mathfrak{p}\cap \mathbb{Z}$?  I want to know if (1+i) lies above/over 2.

Let $R \subset S$ be an integral extension of commutative rings.  Then if $P \subset R$ is prime, there exists a prime ideal $Q \subset S$ such that $Q \cap R = P$.     My D&F book says look at Corollary 50, but I cannot find it in the book!  Is the proof easy or does it require much build-up lemmas?    Hints, or location of Corollary 50, please.


When I am logged in to any Stack Exchange site, many (all?) of the JavaScript features do not work. I am unable to view my inbox or view more comments, autosuggestions for tags do not work, and I am unable to view my question as it will finally appear while typing it. I am getting the error  Expected ')' full.js Line: 166 Char: 336   This error started today and does not occur on other Stack Exchange sites. I am using Internet Explorer 8 (I know, I know... I can't change it for now).  Why could this be?  For some reason, this applies on every Stack Exchange site except Meta Stack Overflow. Other Stack Exchange meta sites do not work.

I am unable to post questions on Stack Overflow. I am using IE8. Is that a supported browser? As far as I can remember I was able to post questions earlier. Here's the JavaScript error:     "JSON is unidentified"   full.js Line 108   Code:0 Char 405   URI:


I am in the process of creating a forum where user will be creating tags similar to the way Stack Overflow does.   To allow users to discover more and more questions, I liked the related tags in the right which comes when we visit a page of some particular tag.   So, I wanna know how two tags are considered related ? How can I calculate the distance between tags !  I just need the views or algorithm that can be used to calculate the distance.  Thanks !!

On the right, there is a widget that lists "Related Tags" (left − SO April 2013, right − MSE May 2014):         What are they related to? There isn't even a question selected. Are they related to the whole displayed list?  This can be seen on every SE site.


What happens when two people are arm-wrestling and one is winning? How is the torque that they apply on each other's arms different? And how do they follow Newton's third law of rotational motion? For example - Let's say you have arm A on the left and arm B on the right (representing the arms). arm A exerts 50 N towards the right. arm B exerts 40 N to the left. I.e. Force𝐴𝑜𝑛𝐵=50𝑁 and Force𝐵𝑜𝑛𝐴=40𝑁. Applying Newton's third law now, Force𝐵𝑜𝑛𝐴=50𝑁 and Force𝐴𝑜𝑛𝐵=40𝑁. Thus there is a net force of 90N in each direction. How can one person be winning in this scenario?

Given Newton's third law, why is there motion at all? Should not all forces even themselves out, so nothing moves at all? When I push a table using my finger, the table applies the same force onto my finger like my finger does on the table just with an opposing direction, nothing happens except that I feel the opposing force. But why can I push a box on a table by applying force ($F=ma$) on one side, obviously outbalancing the force the box has on my finger and at the same time outbalancing the friction the box has on the table? I obviously have the greater mass and acceleration as for example the matchbox on the table and thusly I can move it, but shouldn't the third law prevent that from even happening? Shouldn't the matchbox just accommodate to said force and applying the same force to me in opposing direction?


I want to reset all system file permissions. Because I used sudo chmod 777 -R / command. But I don't know how.

I was trying to run chmod -R 777 ./ but ended up typing chmod -R 777 / and set 777 on my entire machine. What can go wrong? How can I fix it?


I'm trying to create a sequence in the following way:  create sequence some_seq start with (select max(id) + 1 from some_table);   But I'm getting the following error:  ERROR: syntax error at or near "("   I've also tried this approach:  DO $$ DECLARE     min_seq_value int8 := (select max(id) + 1 from some_table); BEGIN     create sequence some_seq start with min_seq_value; END; $$;   But it gives me:  ERROR: syntax error at or near "min_seq_value"   It seems to be pretty basic but I can't get it working. Any ideas?  Thank you!

I've been playing with Postgres for a week or so and I'm seeing if it's possible to set the min/max values for a sequence using an expression. The specific goal is to automate create-scripts for disjoint ranges between servers to avoid key-conflicts in a multi-master setup.  For example, using psql:  CREATE SEQUENCE key_seq MINVALUE (:servernum * :stride)                         MAXVALUE ((:servernum + 1) * :stride - 1);   This gives me a syntax error. Variables are interpolated verbatim, no calculations happen.  An alternative would be to set a variable based on the output of an expression:  \set minvalue (:servernum * :stride)   But the \set statement doesn't evaluate expressions.


I have a spreadsheet monitoring my Stocks and cryptos etc on Google Sheets. I have a formula which 50% works and auto updates and 50% doesnt work and comes up with 'N/A : Could not fetch URL'...when multiple others are working and that one also sometimes works. The formula is; =SUBSTITUTE(IMPORTXML("https://coinmarketcap.com/currencies/"&A4,"//div[@class='priceValue___11gHJ']"), "$", )*GOOGLEFINANCE("CURRENCY:USDGBP") A4 is the title box next to it so its pulling into the box in this case 'Dogecoin'. Can someone guide me with this error please?


I want to disable Hyper-V, but when I go to Windows Features, untick Hyper-V and click OK. It asks me to Restart my computer, and I let it do a restart.  During the restart, it says it failed to apply the changes, and it says undoing changes. When I'm logged back into the computer, I can see that the Hyper-V is still ticked in Windows Features.  My Hyper-V manager looks like this:    I've read others threads, and they say there might be network stuff still hanging about, but I can't see anything Hyper-V related in Network and Sharing Center that is enabled.    As you can see, anything hyper-v is disabled, yet I still cannot disable hyper-v.

Hi I installed Docker for Windows which enabled Hyper-V on my windows 10 machine. Unfortunately this caused Virtual Box to not work anymore, therefore I removed Docker again, but Hyper-V is still activated.  If I try to disable Hyper-V with any of those ways:  on the reboot it will first try to apply the changes and than say that the changes couldn't be applied and reverts, so Hyper-V is activated again.  Has anybody an idea what could be the issue here?


I have been asked to prove that $(a+b+c)\big|(a^n + b^n + c^n)$ for infinitely many $n$ given that $(a+b+c)\big| (a^2+b^2+c^2)$. Here | denotes divides (divisibility).   I have tried with the strong form of induction and tried to use the fact that $a+b+c$ also divides $2( ab+bc+ca)$, but could not prove it.

Let $ a,b,c$ positive integer such that $ a + b + c \mid a^2 + b^2 + c^2$.   Show that $ a + b + c \mid a^n + b^n + c^n$ for infinitely many positive integer $ n$.   (problem composed by Laurentiu Panaitopol)  So far no idea.


I'm trying to get the length of seznam2 by using int postle in Stanovanje. However, the variable getPostle() does not pass and I  get Exception in thread "main" java.lang.NullPointerException error for this line:      private String[] seznam2 = new String[getStanovanje().getPostle()].    I would also like to know when to use:  Stanovanje stanovanje = new Stanovanje();    or  private Stanovanje stanovanje1;    Here is my code:  Potovanje.java  public class Potovanje {      Stanovanje stanovanje = new Stanovanje();     private Stanovanje stanovanje1;      private String datumOdhoda;     private int trajanje;      private Popotnik[] popotnik;     private ArrayList<Popotnik> seznam = new ArrayList<>();     private String[] seznam2 = new String[getStanovanje().getPostle()];       public Potovanje(String datumOdhoda, int trajanje){         this.datumOdhoda = datumOdhoda;         this.trajanje = trajanje;     }      public void setStanovanje(Stanovanje stanovanje1){         this.stanovanje1 = stanovanje1;     }      public Stanovanje getStanovanje(){         return stanovanje1;     }      public void setPopotnik(Popotnik[] popotnik){         this.popotnik = popotnik;     }      public Popotnik[] getPopotnik(){         return popotnik;     }      public ArrayList<Popotnik> getSeznam(){         return seznam;     }      public void setSeznam2(String[] seznam2){         this.seznam2 = seznam2;     }      public String[] getSeznam2(){         return seznam2;     }       public void dodajPotnika(Popotnik[] popotnik){         //System.out.println("postle: " + stanovanje.getPostle());         for(int i=0; i<getSeznam2().length; i++){             //System.out.println("wadap");             setPopotnik(popotnik);             seznam.add(getPopotnik()[i]);         }      }      public String toString(){         return "datumOdhoda: " + datumOdhoda + "\n" + "trajanje: " + trajanje + "\n" + "popotnik: " + getPopotnik();     } }   Stanovanje.java  public class Stanovanje {      private int postle;      public Stanovanje(){      }      public Stanovanje(int postle){         this.postle = postle;     }      public void setPostle(int postle){         this.postle = postle;     }      public int getPostle(){         return postle;     }      public String toString(){         return "postle: " + postle;     } }

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


Similar question to this one, but it's 8 years old so seeing if theres any solutions since:  I have a custom ArcGIS Toolbox, with a script tool. After I click "Ok" when running my tool, I want a pop-up window to appear, something along the lines of "Are you sure you want to execute this tool" -> Yes will run it normally, no will exit/return to the inputs of the script tool. Is this even possible? I am on ArcGIS Desktop 10.6.

I want to add a box message to pop up before execution of a button tool. When I click a button which will do geoprocessing, I want a box to appear on view before processing with message that I am about to do xxx processing. How do I do it?


Let $R$ be a commutative ring with $1_{R}$ and $R'$ be a commutative ring but do not assume that $R'$ has a multiplicative identity. Let f be a map mapping R to $R'$ be a nonzero map that satisfies $f(xy)=f(x)f(y)$ for all $x, y$ in $R$. Assume that $R'$ has no zero divisors. How to show that f($1_{R}$) is the multiplicative identity in $R'$?  I know how to prove it if we assume $R'$ to have a multiplicative identity, but now I don't know how to do this...  Thank you very much for your help!

Let $R$ and $S$ be rings with unity $1_R$ and $1_S$ respectively. Let $\phi\colon R\to S$ be a ring homomorphism. Give an example of a non-zero $\phi$ such that $\phi(1_R)\neq 1_S$  In trying to find a non-zero $\phi$ I've done the following observation: Since for $\forall r\in R$ $\phi(r) = \phi(r\times1_R) = \phi(r)\times\phi(1_R)$ we must have that $\phi(1_R)$ is an identity of $\phi(R)$ but not an identity of $S$. We must therefor construct a $\phi$ that is not onto and which have this property. I can't come up with any explicit example though, please help me.


I have initialized an array of size 10 but on printing the sizof array shows  40 . The code is as follows  ,   #include <iostream>  using namespace std;  int main() {     int  arr[10] =  {2,4,5,6,7,8,9,6,90};          printf("%d \n" , sizeof(arr));  }   Output :  /Users/venkat/Library/Caches/CLion2016.1/cmake/generated/InsertionSort-e101b03d/e101b03d/Debug/InsertionSort 40   Process finished with exit code 0   What does C prints 40 here ?

How do I determine the size of my array in C?   That is, the number of elements the array can hold?


So I got a request converting xls to xlsx. After a few hours of researching all sites and solutions I managed to adapt some code i found on various site... Now I am stuck with a java.lang.NoClassDefFoundError: org/apache/log4j/Logger  here is a list all my libs i am using to get this working so far, I had to add a few libs just to get this far and now i am stuck.  dropbox-core-sdk-1.7.7, itextpdf-5.3.0, jackson-core-2.2.4, PDFBox-0.7.3, poi-3.10-FINAL-20140208, poi-ooxml-3.5-beta5, poi-ooxml-schemas-3.10-beta1, rs2xml, slf4j-api-1.7.5, sqlite, sqlite-jdbc-3.8.7, xmlbeans   Below is my code where i call he class  private void exportRepBtnActionPerformed(java.awt.event.ActionEvent evt) {                                                  connect();            exportRepairReport();     // This is where I am trying to convert the xls file     convertExcelFiles.convertWorkbookHSSFToXSSF(workbook);     //     int selectedOption = JOptionPane.showConfirmDialog(null,             "Generate Comprehensive Report?",             "OPTIONAL",             JOptionPane.YES_NO_OPTION);      if (selectedOption == JOptionPane.YES_OPTION) {         exportRawRepairs();     }  }    Hers is the class where things go south.  public static XSSFWorkbook convertWorkbookHSSFToXSSF(HSSFWorkbook source)  {     XSSFWorkbook retVal = new XSSFWorkbook();         for (int i = 0; i < source.getNumberOfSheets(); i++)          {             XSSFSheet xssfSheet = retVal.createSheet();             HSSFSheet hssfsheet = source.getSheetAt(i);             copySheets(hssfsheet, xssfSheet);         }     return retVal; }   Any help will be appreciated, let me know if you need more info.  Thanks in advance.

I am getting a NoClassDefFoundError when I run my Java application.  What is typically the cause of this?


I'm new to bash and I have been having hard time to understand and implement this flock logic in python. (  flock -e 200   echo "locked"   sleep 5  ) 200>/tmp/blah.lockfile  echo "lock released"  I have a python script in which I would like to incorporate something like above that acquires a lock on volume. I understand that 200 is used a file descriptor but is that needed in python? Is the .lockfile something that will be created or is it a existing file?

I need to lock a file for writing in Python. It will be accessed from multiple Python processes at once. I have found some solutions online, but most fail for my purposes as they are often only Unix based or Windows based.


I have a Schengen visa valid from 15 August 2017 to 9 September 2017, but my duration of stay is only 10 days.    I'm travelling to Europe from the 15th to 24th of August. I'm getting a ticket for a flight that leaves on the 25th August, for very low price since it departs must after midnight at 00:35 hours.I have to check in airport on the 24th Aug by 10 pm.  With this itinerary, am I going to have any issues at the Consulate?

I have short term german visa for three days.  I don't have a flight in my budget on the 3rd day night so I want to know if I can finish my immigration on the 3rd day night and take up the flight next day morning.   Do the airline companies and immigration allow such things.


Why is the American flag featured upside down and mirrored with no stars on the logo for the Netflix series House of Cards?

The logo for Netflix's  shows an upside-down & mirrored American Flag with 0 stars on it.  What does this logo represent in terms of the show?  Is it meant to be symbolism with the themes of the show, or just simple dramatic flair?


How do I completely delete all the files for pre-installed applications (e.g. CandyCrush) in Windows 10?   e.g. I want to remove the directory for CandyCrush C:\Program Files\WindowsApps\king.com.CandyCrushSaga_1.1380.6.0_x86__kgqvnymyfvs32 but Windows won't let me.   It says SYSTEM isn't giving me permission.  I have tried running a Windows PowerShell as Administrator and I tried running the command:  Remove-AppxPackage king.com.CandyCrushSaga_1.540.1.0_x86__khqwnzmzfus32   But I get "Deployment failed"  Background: I want to get rid of all the stupid .JPG files associated with CandytCrush. I deeply resent the high-handed approach of Microsoft giving us all this bloatware that none of us asked for and also making it so hard to get rid of. It is wasting the space on my hard disk. And I don't want to see those .JPGs cluttering up my search results when I use Everything Search.   EDIT01: CandyCrush does not appear to be installed. But I want to delete the installation files(!)

Fresh Windows 10 install. Somehow the MSN Weather app became corrupted. (Unable to launch) I removed the app with the following Powershell command:     Remove-AppxPackage -Package Microsoft.BingWeather_4.7.118.0_x86__8wekyb3d8bbwe   However, when running     Get-Appxpackage –Allusers   the package is still present. When I attempt to reinstall the app via the Windows Store, the download is skipped and the same corrupted package is installed.  I've tried restarting (many times) and using WSReset to no avail.  What can I do? Thank you!


I'm sure this has been asked numerous times, but I'm brand new to all of this and I can barely make sense of it. Say I want to create a longsword that catches fire when used. From what I've looked through, that's the flaming enchantment. According to the cost under the flaming enchantment, I need Craft Magic Arms and Armor, either Fireball, Flame Strike, or Flame Blade, and I need to factor in the cost of a +1 enhancement. According to the magic item creation guide, I would need to factor in the spell level, times the caster level, times 2000 since it's a continuous/on use effect, and since it's a spell effect I need to factor in spell level time 1000. Assuming I use Flame Blade as the spell material, I would need to spend ~46,000 on the effect alone, since the caster level of Flaming is 10 (I think). Is this anywhere near accurate?

For my new adventure I want to buy an Inspired Rapier and just do not get how to calculate it. I actually thought I calculate the costs of the weapon (20gp) plus the +1 enchantment (2000gp) and pay the Inspired with the +1 so instead of a +1 Rapier I have an Inspired Rapier.   Is that correct and if not, could anyone explain to me how to calculate this?


Is there a command for this symbol in Latex? |=. If I use | and = in the source code, then in the pdf there is a big gap between them.  The symbol is from math (from logical clauses). I'm not exactly sure how to translate it in english, it kinda means "resolves" and it used like this c |= C.

I know what my symbol or character looks like, but I don't know what the command is or which math alphabet it came from. How do I go about finding this out?


When I use variable within glob expression like gunzip *_{${X}}.gz it does not work. Here is an example: [nir@etl-dev test]$ ll total 96 -rw-rw-r-- 1 nir nir 22431 May  6 10:35 a20210427_AA.gz -rw-rw-r-- 1 nir nir 22431 May  6 10:36 a20210427_BB.gz -rw-rw-r-- 1 nir nir 22259 May  6 10:35 a20210427_LR.gz -rw-rw-r-- 1 nir nir 22431 May  6 10:41 u20210427_BB.gz [nir@etl-dev test]$ X=AA,BB [nir@etl-dev test]$ echo $X AA,BB [nir@etl-dev test]$ gunzip *_{${X}}.gz gzip: *_{AA,BB}.gz: No such file or directory [nir@etl-dev test]$ gunzip *_{AA,BB}.gz [nir@etl-dev test]$ ll total 756 -rw-rw-r-- 1 nir nir 249448 May  6 10:35 a20210427_AA -rw-rw-r-- 1 nir nir 249448 May  6 10:36 a20210427_BB -rw-rw-r-- 1 nir nir  22259 May  6 10:35 a20210427_LR.gz -rw-rw-r-- 1 nir nir 249448 May  6 10:41 u20210427_BB  Ideas?

I want to use $var in a shell brace expansion with a range, in bash. Simply putting {$var1..$var2} doesn't work, so I went "lateral"...   The following works, but it's a bit kludgey.    # remove the split files echo rm foo.{$ext0..$extN} rm-segments > rm-segments source rm-segments   Is there a more "normal" way?


How do I take backup of all installed apks from my sgs2 to PC using android sdk/ 3rd party tool etc? My phone is not rooted. I can install/uninstall apks using adb, but is there any similar command line tool to take backup of the same?

I was pulling the .apk files from the device using the following command:  ./adb pull /data/app/com.example.tracker-1.apk   When I tried using the same command for the encrypted app as below:  ./adb pull /mnt/asec/net.stfj.spelltower-1/pkg.apk    I get the following message  failed to copy '/mnt/asec/net.stfj.spelltower-1/pkg.apk' to './pkg.apk': Permission denied   The device is not rooted and the app is a paid app. The intention of pulling is not piracy but to understand the library and architecture of a set of apps. Is there a way I can retrieve that .apk file?


I read that big bang caused all the matter to spread in the universe and it happened by a gigantic bang from a tiny ball of matter. But where was matter before it? From where did all the stuff came and contracted into a ball?

Did spacetime start with the Big Bang?  I mean, was there any presence of this spacetime we are experiencing now before big bang? And could there be a presence/existence of any other space-time before the big bang?


In Order of the Phoenix, Lucius Malfoy “falls from grace” and ends up on Voldemort's bad side.  What exactly did he do to anger Voldemort?

In Harry Potter and the Deathly Hallows, chapter one The Dark Lord Ascending, Voldemort believes he must use a wand other than his own in order to kill Harry, when Harry is moved from Privet Drive. He demands Lucius Malfoy's wand, and gets it.   My question is, why did Voldemort take the wand of one of his most loyal servants, rendering Lucius Malfoy useless if a battle was to occur?  If I remember correctly, he had Ollivander at his disposal, and he was the one who told him to use another wand in first place. Why not ask Ollivander to create another wand, or just use ones that he had ready to sell in his shop at Diagon Alley? He could even have taken Ollivander's own wand. If my memories are correct, a wand's importance was compared to that of a limb.


How do I start proving this? I don't really know where to start.

Let $A$ and $B$ be two matrices which can be multiplied. Then $$\operatorname{rank}(AB) \leq \operatorname{min}(\operatorname{rank}(A), \operatorname{rank}(B)).$$   I proved $\operatorname{rank}(AB) \leq \operatorname{rank}(B)$ by interpreting $AB$ as a composition of linear maps, observing that $\operatorname{ker}(B) \subseteq \operatorname{ker}(AB)$ and using the kernel-image dimension formula. This also provides, in my opinion, a nice interpretation: if non-stable, under subsequent compositions the kernel can only get bigger, and the image can only get smaller, in a sort of loss of information.  How do you manage $\operatorname{rank}(AB) \leq \operatorname{rank}(A)$? Is there a nice interpretation like the previous one?


I'd like to perform an ANOVA with a normally distributed response variables and several explanatory variables. Some of the explanatory variables are continuous and some are categorical (factor(..)).  aov(a~numeric(b) + factor(c ) + numeric(d) + factor(e))   The residuals of this model are perfectly normally distributed but the assumption of homoscedasticity is not respected. What can I do?   Welch correction?   Does it work for multiple way ANOVA? How can we perform such a thing with R?  ordered logic model?   I tried the function polr (in R) but I get an error message saying that the response should be a factor  Friedman test?   I tried but I got an error message saying that the formula is incorrect (although it is exactly the same as for aov(..))  Kruskal.wallis?   It works only for one-way Anova I think.      Update  m = aov(myFormula, myData) plot(y=residuals(m), x=m$fit) abline(lm(residuals(m)~m$fit))

This isn't a strictly stats question--I can read all the textbooks about ANOVA assumptions--I'm trying to figure out how actual working analysts handle data that doesn't quite meet the assumptions. I've gone through a lot of questions on this site looking for answers and I keep finding posts about when not to use ANOVA (in an abstract, idealized mathematical context) or how to do some of the things I describe below in R. I'm really trying to figure out what decisions people actually make and why.   I'm running analysis on grouped data from trees (actual trees, not statistical trees) in four groups. I've got data for about 35 attributes for each tree and I'm going through each attribute to determine if the groups differ significantly on that attribute. However, in a couple of cases, the ANOVA assumptions are slightly violated because the variances aren't equal (according to a Levene's test, using alpha=.05).   As I see it, my options are to: 1. Power transform the data and see if it changes the Levene p-val. 2. Use a non-parametric test like a Wilcoxon (if so, which one?). 3. Do some kind of correction to the ANOVA result, like a Bonferroni (I'm not actually sure if something like this exists?). I've tried the first two options and gotten slightly different results--in some cases one approach is significant and the other is not. I'm afraid of falling into the p-value fishing trap, and I'm looking for advice that will help me justify which approach to use.  I've also read some things that suggest that heteroscedasticity isn't really that big of a problem for ANOVA unless the means and variances are correlated (i.e. they both increase together), so perhaps I can just ignore the Levene's result unless I see a pattern like that? If so, is there a test for this?  Finally, I should add that I'm doing this analysis for publication in a peer-reviewed journal, so whatever approach I settle on has to pass muster with reviewers. So, if anyone can provide links to similar, published examples that would be fantastic.


I’m currently working on modelling a piece of terrain for a set of visuals for an infrastructure project. I’ve been given a .DXF file with the design layout and the terrain/height data included as a series of points marked by a number that gives an approximate indication of the height of that terrain at that specific point. There are a few hundred of these in the drawing, and rather than taking single vertices and placing them individually at the marked height and joining them all up later, I was curious if anyone knew of a way to potentially automate/script the process so that a vertex can be generated at each of the different points at the height specified? I realise this question may be better suited elsewhere, but any help would be appreciated!

I have a series of point clouds I want to convert to mesh (there are points inside the object, uniformly distributed, not only on the surface).  I want to generate a model of the surface of the point cloud.   When the model is convex (like a cube or a sphere) applying a convex hull around the object is good enough but when the model has holes (like a torus (a.k.a. doughnut)) or cavities (like the area around the eyes in a head model or the area around the steam in a glass of wine) those concave features are lost.  Is there a way to wrap a mesh around a point cloud in a "convex hull style" without loosing the cavities?  It doesn't need to be perfect, a reasonable approximation of the geometry of the object would be good enough.


I am currently Playing a Monk 8/ Rogue 4 The Rogue is an Assassin. pg97 of the PHB says that for assassinate the move      In addition, any hit you score against a creature that is surprised is a critical hit   I attacked a surprise creature with my flurry of blows from the Monk giving me 4 hits. Since the passage on Surprise in chapter 9 doesnt specify how many attacks count for "surprised" my DM ruled that only the first hit was a critical. My argument was that Assassinate uses the word "all" for the hits.  So who is correct via RAW?

I am trying to figure out if the surprised state ends on a creature after the first attack of a surprise round, or if the surprised state (which I would then see almost as an unofficial condition) ends only after the first round of combat.  In the second case, I would believe that a character (having the rogue's Assassinate ability) attacking a surprised creature AND having multiple attacks would score a critical hit on all hits.  Example: Does a Monk 5/Rogue 3 surprising a creature get automatic critical hits on all hits if he does 2 attacks (with extra attack) and additional unarmed strike(s)?  Or does the critical hit only affect the first hit? However, that would surprise me as the rules mention any hit is a critical hit.


I am currently using Microsoft Visual Studio 2019 to compile these code below  #include<iostream> using namespace std;  double hamTinhTienDien(int kWH) {     if (kWH >= 0 && kWH <= 100) return kWH * 1242;     else if (kWH >= 101 && kWH <= 150) return 100 * 1242 + (kWH - 100) * 1304;     else if (kWH >= 151 && kWH <= 200) return 100 * 1242 + 50 * 1304 + (kWH - 150) * 1651;     else if (kWH >= 201 && kWH <= 300) return 100 * 1242 + 50 * 1304 + 50 * 1651 + (kWH - 200) * 1788;     else if (kWH >= 301 && kWH <= 400) return 100 * 1242 + 50 * 1304 + 50 * 1651 + 100 * 1788 + (kWH - 300) * 1912;     else if (kWH >= 401) return 100 * 1242 + 50 * 1304 + 50 * 1651 + 100 * 1788 + 100 * 1912 + (kWH - 400) * 1962; }  int main() {     int kWH;     cout << "Nhap so dien tieu thu: ";     cin >> kWH;     cout << "So tien phai tra la: " << hamTinhTienDien(kWH)*1.1 << endl; }   When i put 251 as the input, the output is 399452 but it is supposed to be 399451.8 I dont understand why . Please help!!!

In my  I was printing a double using cout that got rounded when I wasn't expecting it.  How can I make cout print a double using full precision?


I know this question has been posted ad-nauseam; however, I still cannot manage to get a working solution.  OS being used is Debian 7 Wheezy.  vHosts file (/etc/apache2/sites-available/default):  <VirtualHost *:80>   ServerName www.example.com   ServerAlias *.example.com   RedirectPermanent / https://www.example.com/ </VirtualHost>  <VirtualHost *:443>         ServerAdmin domains@example.com         SSLEngine on         ServerName www.example.com         SSLCertificateFile /etc/apache2/ssl/ev-cert.crt         SSLCertificateKeyFile /etc/apache2/ssl/private.key         SSLCertificateChainFile /etc/apache2/ssl/intermediate.crt         SSLProtocol all         SSLCipherSuite HIGH:MEDIUM         DocumentRoot /var/www      <Directory /var/www/>             Options -Indexes FollowSymLinks MultiViews             AllowOverride All             Order allow,deny             allow from all     </Directory>          ErrorLog /var/log/apache2/error.log         LogLevel info         CustomLog /var/log/apache2/access.log combined </VirtualHost>   EDIT (Added description of the problem):  Upon restarting apache2, I get no errors; however, when I visit  it goes no where and get a server connection error (cannot connect to server), though when I visit  I get through just fine.  There are no logs in apache to indicate a failure.

This is a  about Connection Refused    We see a lot of questions to the effect      When I try to connect to a system I get a message      Connection refused      Why is this ?


I have a list  a = ['a', 'b', 'c']   How I can get all combinations with repeat and without them from this list. Final output will be:  [('a', 'b', 'c'),  ('a', 'c', 'b'),  ('b', 'a', 'c'),  ('b', 'c', 'a'),  ('c', 'a', 'b'),  ('c', 'b', 'a')]

How do you generate all the permutations of a list in Python, independently of the type of elements in that list?  For example:  permutations([]) []  permutations([1]) [1]  permutations([1, 2]) [1, 2] [2, 1]  permutations([1, 2, 3]) [1, 2, 3] [1, 3, 2] [2, 1, 3] [2, 3, 1] [3, 1, 2] [3, 2, 1]


I want to do an INSERT into a MySQL database using:  $sql = "INSERT INTO table (title1) VALUES ('$myVar')";   but the problem is $myVar can contain the single quotes (' symbols, e.g. in "idiot's"). Can somebody tell me how to handle any single quotes in the variable as a letter and not as a piece of code?  (I know there are posts about this in the forum already, but I do not really understand their solutions, so sorry for double posting)

If user input is inserted without modification into an SQL query, then the application becomes vulnerable to , like in the following example:  $unsafe_variable = $_POST['user_input'];   mysql_query("INSERT INTO `table` (`column`) VALUES ('$unsafe_variable')");   That's because the user can input something like value'); DROP TABLE table;--, and the query becomes:  INSERT INTO `table` (`column`) VALUES('value'); DROP TABLE table;--')   What can be done to prevent this from happening?


To reset footnote numbering on each page I use   \usepackage[perpage]{footmisc}   But if a paragraph including a footnote spread in two pages, the numbering is not reset on the next page  -----footnote{A}---- -------------------- ------ -------------------- --------------------  <- End of a page 1 1. A  -------------------- <- the rest of previous paragraph --------- footnote{B} ------- -------------footnote{C} ------------------------ 2. B 1. C   I use xepersion and xelatex compiler for a document in Persian. Is this problem exist for English too or its a bug in my settings?  You can see this behavior in the following code  \documentclass[a4paper,11pt]{book} \usepackage{blindtext}  \usepackage{subfig} \usepackage{graphicx, wrapfig} \usepackage{float} \usepackage{setspace} \usepackage{geometry} \geometry{top=5.1cm, bottom=4.6cm, left=3.8cm, right=3.8cm} %\geometry{top=5.1cm, bottom=4.6cm, left=5.8cm, right=5.8cm} \usepackage[perpage]{footmisc}   \usepackage{xepersian}  \setstretch{1.54} %\linespread{1.8}  \begin{document} \blindtext\LTRfootnote{paragraph}  \blindtext[2]\LTRfootnote{paragraph}  \blindtext\LTRfootnote{paragraph}       \end{document}

I'm using xepersian package for my Persian job, and I would like the footnote counter to automatically restart from '1' for each page of my document when I using \LTRfootnote command, but footmisc package not work with this command.


Should I use npm package like crypto-js ? String hash = "Something" ; hash = (new sun.misc.BASE64Encoder()).encode(sha.digest(hash.getBytes()));  Edit: Suggestions led to different results. I have found the solution as below on server side with nodejs: const crypto = require('crypto'); const hashStr = "Something different"; let sha = crypto.createHash('sha1'); sha.update(hashStr); let shaBase64 = sha.digest('base64');  console.log(shaBase64);

I have a PHP script that can encode a PNG image to a Base64 string.  I'd like to do the same thing using JavaScript. I know how to open files, but I'm not sure how to do the encoding. I'm not used to working with binary data.


It's way too complex for me. I need to use Localhost (PHP + MySQL)

I set up a new VPS instance of Ubuntu and am wondering what the easiest way is to get up and running with a basic LAMP stack (i.e. which packages are required, which configuration options need to be tweaked, if any, etc.).


I've heard it said that the vacuum permittivity is the lowest possible permittivity for any substance, that no substance can have $ε_r<1$. Is this true? If so, why is this different from permeability, where common materials like copper and graphite have $μ_r<1$? Is there some connection to the nonexistence of magnetic monopoles, which is the only other asymmetry I'm aware of between electrical and magnetic phenomena?  Edit: So it seems it is possible to have $ε_r<1$ for sufficiently high frequencies. I'm not considering high-frequency effects here; I'm asking specifically and only about electric permittivity at DC.  I would be interested to know what causes it to be frequency-dependent, but that's for another question.

Relative permittivity shows that force of interaction in some media is 3 times less than in vacuum ($\varepsilon = 3$) for example. When looking tables of permittivity I never saw a value less than 1.  Russian wikipedia says that $\varepsilon > 1$ is typical for low frequency. So I guess that under some conditions it is possible that $\varepsilon < 1$.   For a static (electrostatic) electrical field is it ever possible (and for what material) that $\varepsilon < 1$? For the electric component of EMF field - when is it possible that $\varepsilon < 1$?


Let $f \in \mathbb{H}(\mathbb{D})$(I mean$f$ is holomorphic on $\mathbb{D})$ be such that $\forall z \in \mathbb{D},  Re f(z) > 0$ and $f(0) = a > 0$. Prove that: $|f'(0)| \leq 2a$.   I tried to solve it with Cauchy integral formula but I can't. Is there a solution with this method?  It's the problem 1.14 in "A Course in Complex Analysis and Riemann Surfaces(Wilhelm Schlag)".

Suppose $f(z)$ is holomorphic in $|z|< 1$ and $\operatorname{Re}f(z) > 0$ in this region. Furthermore, suppose $f(0) = a > 0$. Then why does $|f'(0)| \leq 2a$?  The hint I have is to consider $g(z) = \frac{f(z) - a}{f(z) + a}$ and then show $|g'(0)| \leq 1$. If I do have $|g'(0)| \leq 1$, then the result follows as $|f'(0)| = 2a|g'(0)| \leq 2a$, but I have no idea on how to show $|g'(0)| \leq 1$.


I am running an Ubuntu 16.04 VM in VirtualBox 5.0.18 and I need to switch to TTY1, how can this be achieved? Is there a keyboard shortcut to achieve this in the guest session because doing the normal one just switches to TTY1 in the host?

I want to access virtual consoles in my Ubuntu guests running VirtualBox with Ubuntu guest. However, even if the focus is within the guest window, if I press Ctrl+F1 thru F6 I move in a virtual terminal of the host, not the guest.  How do I switch to a virtual terminal in the guest OS?


There is a badge named Electorate which is going to be awarded on "Voted on 600 questions and 25% or more of total votes are on questions". Can somebody explain this to me?  Voted on 600 Question and 25% are on Question? is this  means   Voted on 600 Posts and 25% are on Question  Can't SO place some easy text or Definitions for average users?

I just got the  badge on StackOverflow, which is nice, but I noticed a number of top users aren't yet listed (inluding Jon Skeet and Marc Gravell, who would certainly qualify).  This made me wonder how the badges are retrospectively applied. Is it just that the display is heavily cached and the badge is awarded when the user logs in again or something?


I saw in a episode of The Clone Wars, Yoda teaching younglings to build their lightsabers purely on force instinct.  Does this explain how Luke was able to construct his own lightsaber?

It's true that Lightsaber construction is a mandatory skill for a trained Force user, but I am not sure about it in reverse.  @DVK has commented on  that:     Grievous wasn't a Jedi (or a Force Sensitive) at all. He couldn't construct one.   I always thought that a Lightsaber was a normal piece of technology which even non-Force users could construct, and you only need Force sensitivity to master  Lightsaber skills. But, I could be wrong.  Does construction of a Lightsaber require use of the Force? If yes, what role does the Force play in the construction of a Lightsaber?


I will be flying Virgin Atlantic from Boston and then connecting with British Airways to Barcelona.  I don't know if I'll be able to bypass customs and rechecking my bag? I have given myself enough time just in case.  Any help will be great.

I will be travelling from IAD (Washington DC) to VIE (Vienna) on two separate tickets, first one being on Virgin Atlantic (redeeming miles from IAD to LHR) and second one being on British Airways from LHR to VIE. I am planning to have a layover of about 5 hrs 20 min between both the flights (both arriving and departing from terminal 3 at LHR)  I have an Indian passport with a valid US visa. I have following questions:   Is there even a slight chance that my luggage will be checked through? Does anyone have any experience here? This will help me avoid the UK border and immigration check. I checked with Virgin Atlantic and they said baggage cannot be tagged through to VIE since I have separate tickets. Still I was hoping that things may change at the gate while boarding at IAD. On checking  I see that I will not need a visa for passing UK Border and Immigration. However, the results on this website say "You might be eligible for ‘transit without visa’" if you are arriving from USA and have an onward flight leaving on same or next day. The words 'might be eligible' concern me. Again anyone with experience here? There's an earlier BA flight available (leaving me with a layover of 2 hours between arriving and departing flights from the same terminal 3). Will this be sufficient? Or should I stick to the later flight giving me 5 hrs and 20 min in transit?   Many thanks for your replies.


Some yesterday I accidentally clicked/used a keyboard shortut that screwed up my item movement. Previously, when I used the arrows to move an object, the object would follow along in real time, now, the object seems to move on a tiled grid. It jumps around following my cursor instead of moving fluently.   I'm relatively new to blender, and I can't find an answer to my question anywhere :)  Thanks!

My cursor is moving by every selection by large increments!  Normally when I use Blender, I am able to select and move objects to any coordinate. Now, all of the sudden, when I select an object or mesh the selection moves by an inch or so in each direction.  How do I reset it to normal?