I am landing in Canada on my immigrant visa and I will stay here for a couple of days. Then I will board flight to India which has a stop in Rome, Italy. Do I need any kind of visa for the stop in Rome? My stop is at FCO airport for 3 hours. My airlines is AlItalia.


There is an Achievement for "Goliath, Meet David - Allowed a Goliath to level up four times before killing him" but I don't know how Goliaths work to figure out how to do this.   When I've come across them before, they seem to attack me until I behead them, then some weird shrunken head atop of stringy neck comes out and they start rushing towards their friends (my enemies) and attack them until there's none left.  So how and why does this happens, and what are the actual Goliath AI rules? How do they "level up"?


How to change the WMS Background Color in OpenLayers?

I am using geoserver to serve up an image pyramid basemap.  I want to have all areas outside of the data extent be black (instead of white).  I have the map displayed inside of a div tag and changing the css on that tag or the container (another div) it resides in has no effect.  I have checked both the geoserver and openlayers documentation, but have not seen any way to change the background color.  Any suggestions on where to continue searching?  Do I need to generate a black tiles and serve them?


I want to copy/modify/delete a Minecraft world. Where can I find my saves folder?


We know a vector  bundle as a manifold $E$ over a  manifold $M$ is defined using transition maps over a collection of open sets each giving  us a trivialization. Since $M$ is a manifold, it has an atlas. Can we intersect the two collections of open sets and obtain a chart for $E$ which also gives us the trivialization?


my character that i have models is one object, i want to subdivide the head and other body parts, however i dont know how to keep the one i want with sharp edges to stay  i want to keep the mouth the way it is, sharp, i dont know how to, can anyone help me


This is about files straight from the compiler, say g++, and the -o (outfile) flag.  If they are binary, shouldn't they just be a bunch of 0's and 1's?  When you cat them, you get unintelligible output but also intact words.  If you file them, you get the answer immediately - there seem to be no computation. Do the binary files in fact have headers with this kind of information?  I thought a binary executable was just the program just compiled, only in the form of machine instructions that your CPU can instantly and unambiguously understand. If so, isn't that instruction set just bit patterns? But then, what's all the other stuff in the binaries? How do you display the bits?  Also, if you somehow get hold of the manual of your processor, could you write a binary manually, one machine instruction at a time? That would be terribly ineffective, but very fascinating if you got it to work even for a "Hello World!" demo.


Could mods have some access to flags through the mobile web interface?

Background   I was recently away from home for about two weeks.  On some of the sites I moderate I wasn't the only one, so we were already down a little on moderator attention.  While I wasn't going to pay as much attention to SE as usual, I was hoping to help out some.  Unfortunately, using my phone I couldn't even see flags, let alone handle them.  Now some flags would be hard to handle on a phone anyway, but some are easy (yeah, delete that; no, decline that; etc).  And even seeing the rest would make discussions in the mod chat room easier.  Request  On the mobile interface we can see the diamond notification for new meta posts, mod messages, and SE announcements.  That's good.  Could we also have the flags notification, the one that leads to the flags page?  I don't think we want to try to jam the in-page flags overlay into the mobile interface; there just isn't room for that.  But for tempoary use on a phone, the following workflow seems quite acceptable to me: (1) Go to flags list. (2) Read a flag and then click through to read the post. Make a decision. (3) Use the "back" button to go back to the flags page and handle the flag.  I wouldn't want to do that all the time or when using a keyboard and mouse, but for a touch interface with limited real-estate this seems ok.  This also means that if I want to discuss the flag with other mods, I can copy the URL of the flagged post and head off to chat.  Note that I am asking for this in the mobile web interface, not the Android or iOS apps.  That would be ok too, but I've not had much luck navigating efficiently in the Android app so I don't use it for my regular browsing, just for notifications.  Note also that I am aware of the "use desktop site" option in mobile browsers, but that's quite unworkable for me at that screen size.  I tried that once or twice while I was away but quickly gave up.


After upgrading from Ubuntu 16.04 to 18.04, wine stopped working. After reinstalling it, I get dependency issues

I have upgraded my Ubuntu version from 16.04 to 18.04. After that wine programs stopped working. I have re-installed wine and now I'm getting the following error:  The following packages have unmet dependencies:  wine32:i386 : Depends: libwine:i386 (= 3.0-1ubuntu1) but it is not going to be installed  wine64 : Depends: libwine (= 3.0-1ubuntu1) but it is not going to be installed E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).   I can't even install FileZilla from software center.  How can I resolve this?


Belkin USB-C LAN not functioning on MacOS

I have a 2018 Macbook pro with MacOS 10.13.6.  To have a more stable connection (compared to WiFi) I got a "Belkin USB-C to Ethernet Adapter".  Initially, the adapter had a self-assigned IP which I fixed by changing how the IPv4 in Network settings is configured from DHCP to DHCP with manual address. Now the status is green and the device is assigned an IP address. However, there is still no connectivity through this device.  Any help is appreciated.


Is there a way to stop Mail from automatically selecting messages? For example when I delete a message, it will immediately select the next one and mark it read. Then if I don't want to read the message yet, I need to mark it as unread.


Let $A$ and $B$ be countable sets. Is there any function $f$ such that a certain condition holds for an uncountable number of functions $g$?

Let $A$ and $B$ be countable sets. Is there any function $f:A\to B$ such that there exists uncountably many functions $g:B\to A$ such that $g\circ f=\operatorname{id}$ but $f\circ g\neq\operatorname{id}$?


I want to take the XOR of all the elements of 1 list with another. How do I do it?

I have a bunch of lists in the form of say [0,0,1,0,1...], and I want to take the XOR of 2 lists and give the output as a list. Like: [ 0, 0, 1 ] XOR [ 0, 1, 0 ] -> [ 0, 1, 1 ]  res = [] tmp = []  for i in Employee_Specific_Vocabulary_Dict['Binary Vector']:     for j in Course_Specific_Vocabulary_Dict['Binary Vector']:          tmp = [i[index] ^ j[index] for index in range(len(i))]         res.append(temp)   The size of each of my lists / vectors is around 3500 elements, so I need something to save time, since this piece of code is taking more than 20 mins to run.  I have 3085 lists, each of which need an XOR operation with 4089 other lists.  How do I do this without iterating through each list explicitly?


In the movie production  and book Harry Potter and the Sorcerers Stone, we see ghosts floating through walls, without affecting them (i.e. smashing through them and leaving rubble behind).  In the movie production Harry Potter and the Chamber of Secrets, we see Moaning Myrtle surprise Ron Weasley as he asks why they're brewing Polyjuice Potion in the girls lavatory. After revealing herself, Myrtle does a demented loop-de-loop around the lavatory and then dive into the toilet.  Yet later, both in the book version and in the movie version of The Goblet of Fire, we see Myrtle soundlessly enter the prefects bathtub without displacing water.  Therefore, can ghosts (not poltegeists, who as we know can) interact with the physical world, and have an effect upon their surroundings?


Pyproj projection 0.5 meter differnce from official results (IGD05/12,IG05/12) Israel Grid


Unable to achieve long shadow effect in Illustrator

I have read several guides on how to achieve the Long Shadow effect using Illustrator, I tried both using the Transform Effect and Blend Modes, however I fail achieve it using both.  When I try using the Transform effect, I get all copies of the fill simply duplicated with no continuity, like so:    When I try using blend modes, here what I get:   An example of what I'm trying to achieve:


prove that $|\{0,1\}^{\mathbb{N}}|\leq |\mathbb{R}|$ Could you give me a suggestion to create a correspondence? Let $f:\{0,1\}^{\mathbb{N}}\rightarrow {\mathbb{R}}$ I must prove that f is injective but I don't know what correspondence I could use. Any suggestion?


We decided to travel to Croatia using ferry, train and coach from the UK. We had booked our train tickets through DB and actually had three trains on that ticket. We successfully caught our first train from Bruges to Brussels. We were then due to  catch a train to Frankfurt and then a further connection onwards to Munich. We then had an overnight train to Zagreb.  Our train from Brussels to Frankfurt was cancelled and the solution from Belgian Railways was to catch a train towards the Belgian/German border from where buses would take us to Aachen. This is because it was a German service. From there we had to catch a train to Cologne and then a train to Munich. Obviously we missed our connection from Frankfurt and then from Munich as we didn't arrive in Munich until 1.45am (we were due at 21.20). We had to pay for coach tickets from Munich to Zagreb so we didn't lose a day of our holiday.  Which parts of that should DB compensate us for?  EDIT:  Thought I should add a little more detail. Our train from Bruges-Brussels, Brussels-Frankfurt and then Frankfurt-Munich were booked through DB. Our train from Munich to Zagreb was booked through Austrian Railways.  On being told by Belgian Railways that the train was cancelled I told them that we had an onward connection from Munich that evening. The guy spoke to his supervisor and he said that we'd need to get into Germany and speak to someone. Once we reached Verviers there was a bus to Aachen station. From there we were on our own. There were 2 people trying to assist the hundreds who had arrived on buses. We sort of pushed in and tried to explain that we needed to get to Munich for our onward connection. We were given a printout of train times to Munich and that was it.   When we got to Cologne I went to the Travel Centre and explained the situation and the staff member stamped my ticket and gave me a complaints form. She then suggested a direct train to Munich which was due to arrive at about 1.30am. She said that when we arrived in Munich we should go to the Travel Centre and they would give us a hotel voucher.   En route we had to decide what our options were. If we arrived at 1.30am and then had to find a hotel it would mean that we'd probably be in the hotel for no more than 4 hours before we had to return to the station for the 8.20 train to Zagreb. On arrival in Zagreb we had a 7 hour coach journey to our destination. This would have meant that getting the train to Zagreb the following morning would mean we would arrive in Zagreb at 17.00 and even if we were able to get on a coach straight within the hour we wouldn't arrive at our destination until 3.00 or 4.00am the following morning and we had no idea if we'd be able to get into our accommodation at that time. So we looked at other options and found a coach that left at 3.15am from Munich arriving in Zagreb at 11am, only 2.5 hours after our original arrival time. We thought this was a better option. There was nobody on the train who we could clarify this with, the only staff onboard didn't even bother looking at our tickets. So we went ahead and booked the coach.  By the time we arrived in Munich it was 1.45 and the Travel Centre was just closing for the night. I went and explained our situation but there was no offer of a hotel or an offer to pay for a hotel, just another stamped form. So we continued with our coach booking just so we could keep on moving and get to our holiday quicker.   Hope this clarifies a few details!


Why don't the roots of an equation agree with the equation sometimes?

For example this equation (1): $$\sqrt{4x^2}-x+2=0$$ which then expanded to (2) $$3x^2+4x-4=0$$ and the roots via quadratic formula to (2) is $-2$ and $2/3$, but when put into (1), they don't agree with the first equation. What is the explanation behind this?


I have 4 files that I want to include them in a .zip file.  drwxr-xr-x  7 skemelio themelis 4,0K Οκτ  18 00:21 CSharp drwxr-xr-x 11 skemelio themelis 4,0K Οκτ  18 00:17 gnome-games drwxr-xr-x  8 skemelio themelis 4,0K Οκτ  18 00:17 gnome-music drwxr-xr-x  4 skemelio themelis 4,0K Οκτ  18 00:18 Test   As you can see in total their size is 16K.  After  I am creating the zip using the command bellow:  zip -r myfiles.zip *   The file was created successfully but now its size is 20M, as you can see bellow!   drwxr-xr-x  7 skemelio themelis 4,0K Οκτ  18 00:21 CSharp drwxr-xr-x 11 skemelio themelis 4,0K Οκτ  18 00:17 gnome-games drwxr-xr-x  8 skemelio themelis 4,0K Οκτ  18 00:17 gnome-music -rw-rw-r--  1 skemelio themelis  20M Απρ   4 02:00 myfiles.zip drwxr-xr-x  4 skemelio themelis 4,0K Οκτ  18 00:18 Test   What I've done wrong?  ps: Same thing (same size) happened when I try to create a .tar using tar cvf myfiles.tar *.


Glitch in render view after install newer GPU driver(RX 570)

(Sorry about poor english) It looks normal in solid view, but only mesh silhouette is visible in material preview or rendered view. I think it's a optional driver(20.12.1) problem, and I downgrade to the recommended version(20.11.2), but it's showing the same thing. The previous driver was 20.4.2, it works fine.


A question on pseudospectra of matrix polynomial

Suppose:    ${A_j} \in {\mathbb{C}^{n \times n}},0<{w_j}\in \mathbb{R} (j = 0,1,2....m)$ ${\rm{P(}}\lambda {\rm{) = }}{{\rm{A}}_m}{\lambda ^m} + .....{A_1}\lambda  + {A_0}$ is a matrix polynomial,  and $\lambda $ is a complex variable. ${\rm{q(}}\lambda {\rm{) = }}{{\rm{w}}_m}{\lambda ^m} + .....{w_1}\lambda  + {w_0}$ ${\sigma _{\varepsilon ,w}}(P) = \left\{ {\lambda  \in \mathbb{C}:\left\| {P{{(\lambda )}^{ - 1}}} \right\| \ge {{(\varepsilon q(\left| \lambda  \right|))}^{ - 1}}} \right\}$, where $\left\| . \right\|$ is any subordinate matrix norm.   Why does boundary of ${\sigma _{\varepsilon ,w}}(P)$ can be written in the form $S = \left\{ {\lambda  \in \mathbb{C}:\left\| {P{{(\lambda )}^{ - 1}}} \right\| = {{(\varepsilon q(\left| \lambda  \right|))}^{ - 1}}} \right\}$.


How to calculate areas for data that covers the whole of Australia

I have a polygon shapefile showing mining areas across all of Australia. I want to calculate the area for each of the polygons however they have been provided in a Geographic Coordinate System (GDA_94).  Can anyone tell me what projected coordinate system I could use that would enable me to calculate the areas of each polygon?   Will I need to transform the data and how might this affect the calculations given the size of Australia (i.e. it covers multiple GDA or UTM zones)?


Is this convexification of non-convex constraint correct?

Original problem setup   \begin{equation}\tag{1} \begin{array}{c} \min_{\mathbf{b}} \hspace{4mm}  \mathbf{b}^{T}_{}\mathbf{A}^{}_{}\mathbf{b}^{}_{} \\ s.t \hspace{5mm} \mathbf{b} \in \mathbb{R}^{4} \\ \hspace{9mm}b_0=1\\ \hspace{15mm}b_3=b_1b_2  \end{array} \end{equation}  where $\mathbf{A}$ is a $4\times 4$ positive semi-definite matrix.  I Reformulated this to  \begin{equation}\tag{2} \begin{array}{c} \min_{\mathbf{b}} \hspace{4mm}  \mathbf{b}^{T}_{}\mathbf{A}^{}_{}\mathbf{b}^{}_{} + \lambda(\mathbf{b}^{T}_{}\mathbf{Z}^{}_{}\mathbf{b}^{}_{}-1) \end{array} \end{equation}  where  \begin{equation} \mathbf{Z} = \begin{bmatrix}     1 & 0 & 0 & 0 \\     0 & 0 & -1 & 0 \\     0 & -1 & 0 & 0 \\     0 & 0 & 0 & 2 \\ \end{bmatrix} \end{equation}  My Question:   Are (1) and (2) exactly same? Does (2) result in convexification of non-convex constraint $b_3=b_1b_2$ If (2) is correct, then do we have a closed-form solution for $\mathbf{b}$   (Can someone please edit to place $\mathbf{b}$ exactly below min)


Java generics 2 set of  or  in method declaration

I have been seeing the following methods declaration but I do not understand how <K, V> and <T> are being used.  What does public <K, V> does in this method?  public <K, V> void add(K k, V v)   What does static <T> does in this method?  public static <T> int countGreaterThan(T[] anArray, T elem)


How to prove $V*V^T=I$ in SVD: $M=U*S*V^T$?  It's easy to understand $V^T*V=I$. It seems  $V*V^T=I$, but how to prove it?


Technically, what is a spacetime singularity?

In popular science books and articles, one often finds that the BigBang is a singularity of spacetime, and it is expected to be solved by a successful theory of Quantum gravity.  Technically what is a spacetime singularity? What diverges and why?   I don't have much familiarity with General Relativity except an elementary knowledge of the Einstein's field equations and Schwarzschild solution. It will be great if someone can explain what is a spacetime singularity all about.


How can I calculate $\lim_{x\to 0} \frac{\arctan(x)-\arcsin(x)}{x^3}$ without L'Hôpital?

$$\lim_{x\rightarrow 0} \frac{\arctan(x)-\arcsin(x)}{x^3}$$  I am new in area of limits could you help me about that


Error: SQLSTATE[42000] When I try to update a value in a table

Fatal error: Uncaught exception 'PDOException' with message   'SQLSTATE[42000]: Syntax error or access violation: 1064 You have an   error in your SQL syntax; check the manual that corresponds to your   MariaDB server version for the right syntax to use near ''1235'='1235'   WHERE username='wafflezzz'' at line 1' in   /home/wafflez3/public_html/Project SA Theme/ipn/set.php:14 Stack   trace: #0 /home/wafflez3/public_html/Project SA Theme/ipn/set.php(14):   PDOStatement->execute() #1 {main} thrown in   /home/wafflez3/public_html/Project SA Theme/ipn/set.php on line 14   I get that error when I use this code to change a null value to a value.      <?php session_start(); require "../pdo_connect.php"; $usrname = $_SESSION["username"]; ?> <title>Loading...</title> <?php $checker = $conn->prepare("SELECT * FROM transactions WHERE payer_user=:username AND success='1'"); $checker->bindParam(":username", $usrname); $checker->execute();  while ($row = $checker->fetch(PDO::FETCH_BOTH)) {     $paidscript = $row["item_name"];    $sql = $conn->prepare("UPDATE us SET :script=:script WHERE username=:userr");    $sql->bindParam(":userr", $usrname);    $sql->bindParam(":script", $paidscript);    $sql->execute();     echo "You can now view the script!";     }


How can we be sure that nature isn't "faking" quantum statistics?

In a recent publication,  (Gerhardt 2011) (), the statistics of quantum mechanics is faked using classical light sources.  But if it is possible for physicists to fake an experiment to imitate QM, how can we be sure that nature doesn't do the same trick on us? Can it be that QM is a fake, and in the end QM turns out to be an artifact of our imperfect measurement devices?


Liouville's theorem question - show f is constant

Assume that $f: \mathbb C \to \mathbb C$ is entire such that $\left|f\left(z_{0}\right)\right|\neq1$ for all $z\in\mathbb C$. Show that f is constant.  I know either $\left|f\left(z\right)\right|<1$ for all $z\in\mathbb C$ or $\left|f\left(z\right)\right|>1$ for all $z\in\mathbb C$ using Intermediate value theorem.  Afterwards,  I should be able to apply Liouville Thm. Hence, if $\left|f\left(z\right)\right|<1$ for all $z\in\mathbb C$ than f is constant (by Liouville Thm) but I don't know what to do with the other option.  Thanks!


In my user account page, I analyzed my reputation total, and it didn't add up:        I think they should match. What's wrong? What am I missing?     UPDATE: first time of downvote cast for me !!   After casting downvote , my reputation was descreased as my downvote casted. But there has nothing showing. I think that may differ reputation. Am I right ?


Why don't virtual particles violate conservation of mass/energy?

If virtual particles sometimes add more mass/energy to a system then was inputed or comes out in the output, how do they not violate conservation of mass/energy.


My mesh is partly hidden in the viewport

I was working on my mesh when all of a sudden, I realised it was partly hidden when I go to the Solid or Wireframe mode. I probably toggle something that only allows to show what's inside that dark grey area but I can't find what it is. Does any of you have an answer to that problem ? Cheers,


Show that the following group is identity:   $$G=\langle x,y,z  \mid xyx^{-1}=y^{2}\, , \, yzy^{-1}=z^{2}\, , \, zxz^{-1}=x^{2} \rangle.$$  This group is its own derived group. So all I get is group is perfect. Am I correct? What else I missed? Should I use tietze transformation, I am not getting anywhere with them.


What is the difference among these questions:  A . Have clothes dried?  B. Have clothes gotten dry ?  C . Have clothes gotten dried?


Capturing the result of a command for later use

I am running a batch script and outputting the info to a file in the temp folder, (just to learn from). I have an input for a user to select which mapped drive they want their data transferred out of. Here is what I have, it is super easy so I can learn then modify later. Cls @ECHO Off Net use > c:\Temp\Map.txt Net Use Pause :Start  ECHO Which Drive letter do you want to back up? ECHO ? - Enter Drive letter ECHO E - Exit SET /P M=Make Choice then press ENTER: IF %M%==E Exit Else goto :here If %M%==e Exit Else goto :here  :Here Echo %M% Findstr "OK           %M%:" c:\Temp\Map.txt pause  What I need is to extract the path name for the drive they select. Like if there are 5 drives, and they want drive S: backed up, output is: OK           S:        \\10.X.X.X\Deployment\David\Davids_Scripts\bats  I would need the \\10.52.8.1\Deployment\David\Davids_Scripts\bats saved so I can put it in a transfer script.


How to install OneDrive on ubuntu 13.10 x64

I have Ubuntu 13.10 and I don't know how to install OneDrive on ubuntu 13.10 x64.


How to prove this identity for functions which are analytic in the disk $|z|<R$

The following question was asked in a master's exam for which I am studying.  Suppose that $f(z)$ is analytic in the disk $|z|\leq R$ and let $$ A(r)= \max_{|z|=r} \text{Re}\,f(z). $$ Prove that, for $r<R$, $$\max_{|z|=r} \frac{ |f^{(n)} (z) | } { n!} \leq \frac{2^{n+2} R }{ (R-r)^{n+1} }\big\{A(r)+|f(0)|\big\}.$$  I am confused on which result I should use to prove this. $\max_{|z|=r} \frac{ |f^{(n)} z | } { n!} $ will have terms from both the real and imaginary parts of $f$. I thought of using Cauchy Integral formula but it will only esitmate value at $f(0)$. I need you to just outline the result that should be used. I will complete it myself.


I`m getting following error email when i trying to send emails from my web site.  This error coming when i trying to send sctivition email through my web site. But when i trying to send recover password mail it is sending successfully. There can`t be error in my code. So could any one help me out.   This message was created automatically by mail delivery software.  A message that you sent could not be delivered to one or more of its recipients. This is a permanent error. The following address(es) failed:      lmbkarunanayake93@gmail.com     host spam1.thewebhostserver.com [IP Address]     SMTP error from remote mail server after end of data:     550 High probability of spam


Finding the sum of the infinite series whose general term is not easy to visualize: $\frac16+\frac5{6\cdot12}+\frac{5\cdot8}{6\cdot12\cdot18}+\cdots$

I am to find out the sum of infinite series:- $$\frac{1}{6}+\frac{5}{6\cdot12}+\frac{5\cdot8}{6\cdot12\cdot18}+\frac{5\cdot8\cdot11}{6\cdot12\cdot18\cdot24}+...............$$ I can not figure out the general term of this series. It is looking like a power series as follows:- $$\frac{1}{6}+\frac{5}{6^2\cdot2!}+\frac{5\cdot8}{6^3\cdot3!}+\frac{5\cdot8\cdot11}{6^4\cdot4!}+.....$$ So how to solve it and is there any easy way to find out the general term of such type of series?


two converging sequences results in third

can anyone help me with this, I got stuck on it.  let $a_n$ and $b_n$ (for $n$ a non-negative integer) be two sequences of real numbers such that $\lim_{n\to \infty}a_n=a$ and $\lim_{n\to \infty}b_n=b$. prove that $\lim_{n\to \infty} \frac{a_0b_n+a_1b_{n-1}+....+a_nb_0}{n}=ab$.


Finding $z\in \mathbb C$ with $\sin z = 2$?

I'm trying to find all $z\in \mathbb C$ with $\sin z = 2$ but I'm stuck.  I tried writing $\sin z = {e^{iz} - e^{-iz}\over 2i} = 2$ and then writing $z = x + iy$ but the expression I got was $e^{ix}e^{-y} - e^{-ix}e^{y}=4i$ and I don't see how it's possible to solve this for $x$ and $y$.     Please could someone tell me how to calculate the inverse values of   the complex sine function?   I had also tried letting $w=e^{iz}$. Then I got the quadratic   $$ w^2 - 4i w + 1 = 0$$  and using the formula for quadratics I got  $$ w_{1,2} = {4i \pm i \sqrt{20}\over 2}$$  Taking the logarithm I got  $$ i z_{1,2} = \ln{{4i \pm i \sqrt{20}\over 2}}$$  whereas I should be getting   $$ z = ({\pi \over 2}  + 2\pi k ) - i \ln(2 \pm \sqrt{3})$$  for $k \in \mathbb Z$.


If I have the Armor of Shadows Eldritch Invocation, do I know the Mage Armor spell?

The warlock's  "Armor of Shadows" says:     You can cast mage armor on yourself at will, without expending a spell slot or material components.   Does this mean I know the spell? That is, can I cast it on someone else by expending a spell slot and material component as normal?


I research a lot in google for a script that tell me if apache2 is configurated well and it's capabilites/calibration are set correctly.  I use mpm_prefork_module and I would to know if params are set correctly for my machine.  This is my actual params:  <IfModule mpm_prefork_module>     StartServers          5     MinSpareServers       5     MaxSpareServers       25     MaxClients            50     MaxRequestsPerChild   500     ServerLimit           50 </IfModule>   The question is very simple, anyone know a script (bash prefered) that check apache2 calibration?


In Episodes VII and VIII we see BB-8, Poe Dameron's droid, be quite active, , ,  etc, but as far as I remember we never see it (?) actually recharge.   So my question is: What is BB-8's power source?


Is it possible for a swallowed caster to cast Fireball outside of a Giant Toad?

I had a situation last week where my DM and I completely disagreed how the following situation should have been ruled:  I'm a Circle of the Moon druid wild-shaped into a  and I had swallowed a mage. The Swallow attack description says     "(...) The swallowed target is blinded   and restrained, it has total cover against attacks and other effects   outside the toad, (...)" (Giant toad, MM.)   But on the mage's turn he was able to cast  at a point of his choice outside the Giant Toad, because Fireball's bright streak came from the Giant Toad's belly, exited the mouth, and struck a point outside the toad.   In broad terms, can a blinded caster choose a point outside of the Toad? And can a caster with total cover (in this case) target a point outside of the Giant Toad?   I've read the rules, especially regarding total cover and in fact it doesn't say anything about a person with total cover attacking someone who couldn't attack him because the cover. I would like to know if really it is possible for it to happen by RAW or RAI, because for me in this case total cover for those inside the Toad implies anyone outside it also has total cover, and vice versa.


Does the composition of adjoint functors again form an adjunction?  Say $\langle F_1,G^1\rangle$ is an adjunct pair between two categories A and B and $\langle F_2,G^2\rangle$ is also an adjoint pair between the categories B and C, then would $\langle F_2\circ F_1,G^1\circ G^2\rangle$ be an adjoint pair between the categories A and C?  If not is there some way of obtain an adjunction given the assumptions made on the 4 functors, or by adding extra properties to the categories?  Particularly, here I am assuming A is the category $_RMod$ for some (apriori) arbitrary ring.


copy files and folders from cluster to desktop using PuTTY

I would like to copy files and subfolders from a cluster that runs pacman to a Windows desktop computer using PuTTY.   First I would like to copy one specific file or subfolder as a test, for example my_test_file.r or my_test_folder, from the cluster to my desktop. Then I would like to copy every file or subfolder that contains a specific word, for example mykeyword, from the cluster to my desktop.  Note that mykeyword can appear anywhere in the name of the file or in the name of the subfolder, not just at the beginning of the name. Then I would like to copy every file containing mykeyword from my desktop to a specific folder on the cluster   I know this is a very basic question, but I cannot find the answer using Google.  Until now I have always used FileZilla to copy files and folders to and from the cluster.  Unfortunately after I installed the latest version of FileZilla I am having trouble connecting to the cluster with it.  I can still connect with PuTTY and want to copy files and folders that way if possible between the desktop and the cluster.  My question might be a duplicate of this question:    However, that question has no answer and I do not understand the comment.  Thank you for any assistance.


How to get exact time when converting date into string

i want get current time, when i convert new Date() into sting but when it converts reduces 5.30 hours based on my time zone.  How can i get same time which returns in new Date() method?


How to launch an application with a keyboard shortcut?

In Windows, certain keyboard shortcuts (usually involving the Windows key) are set to launch certain applications.  For example WK+R will launch Run, before Windows 8 WK+S would open the Send to OneNote screenshot maker, in some versions of MS Office WK+N would open Send to OneNote, etc.  (WK = Windows Key)  Is there any way I can set my own such keyboard shortcuts to launch certain programs?  (Exactly like  only for Windows 10.)


In the beginning of Order of Phoenix, Mrs Figg tells Harry not to put his wand away as "there might be more of them around".  I assumed she could see the Dementors. (They didn't attack her, so the only way she could have known they're around by seeing them. Maybe she felt them, but it's unlikely for a Squib who virtually never left her house to know that feeling too well; and jump to the conclusion that there are Dementors in Little Whinging.)  At the hearing, the Wizengamot aren't sure if Squibs can see Dementors. Harry suspects she has only seen a picture of a Dementor. But she does describe the feeling of having a Dementor around accurately.  So which one is it? Can she or can she not see Dementors?  EDIT: I disagree this is a duplicate of . That is a different question, as evident from the wording. The connection between squibs and dementors has been mentioned in passing and is not definitively answered there. Please read the answer here and my comment below it.


How would pretty be classified in this sentence

The sentence is "You look pretty tonight". I believe that pretty would be an adjective as it's referring to "You".   However in the sentence "You look pretty gorgeous tonight" I believe that pretty would be an adverb.  In the first sentence is pretty saying how "You" looks though, meaning it would be an adverb?


A path to truly understanding probability and statistics

I'm embarrassed to say that I have a PhD and hold an asst professorship, but get tripped up when reading statistics research. I am in a field of Business that is similar to IO Psychology or Social Psych. I spend too much time reading applied stats books, but I find even with all the reading I don't have a firm grasp of what I'm actually doing. Everything is very 'seat of the pants.' (As sad as it seems, I think this is not a unique situation among the faculty in the social sciences...) The biggest problem comes when I need to apply a rarely used stat technique. I can find an article from a mathematical stats journal with the equations that would solve my problem, but I don't have the math to convert those into code. I am forever relying on other prof's R packages, and crossing my fingers hoping it will work (I can't even check to verify if it did or not). It's been over 15 years since I took Calculus and Algebra in undergrad, and I think I want to start at the beginning and truly understand probability and statistics.   I am starting with  and  for a quick refresher of the basics -- I know it's hard to believe, but in an applied research field we rarely have use for sin or cos. I'm even trying to finally learn how to correctly do a proof, using the books from Velleman ("") and Houston ("") -- I'm serious about doing this right and understanding the subject. From there I want to move on to (correctly) learn the Calculus and Linear Algebra I need to tackle probability and statistics. I was thinking of using  and  books. But  comes highly recommended as well. After that I am completely at a loss. Further, I don't know how far to go into Calculus or Linear Algebra before I reach diminishing returns. (Apostle introduces Probability in the  -- is it vital that I work through everything preceding it before tackling Probability?)  So my question is: if you had to do it over again with the goal of truly, deeply understanding statistics, where would you start? What books are the modern path to deep understanding? I would like to follow a modern path so that I can understand current research in statistics, including Bayesian approaches. But not in a machine learning context (which seems to be the all the rage at the moment), rather a social science / design and analysis of experiments / multilevel modeling context. Perhaps my goal would be the work of Andrew Gelman;  showed me how I should be looking at modeling and statistics (simulation, uncertainty estimates everywhere, bayesian inference, and so on).  How should I go about relearning this material with that end goal in mind?    Update 1: Possible texts, starting from scratch with a focus on proofs and deep understanding. Not necessarily one after another.  Relearn the basics:    by Velleman  by Houston  and  by Gelfand (for understanding why and how instead of what)  by Simmons (for reference)  by Lockhart (for inspiration)   Calculus (which one(s), and how deep?):    by Strang  and  by Apostol   by Spivak ()   by Curant (and II/1 II/2?)   Linear Algebra (which one(s) and how deep?):    by Strang  by Searle  by Gentle   Probability (which one(s)?):    and  by Feller  (for intuitive understanding)  by Hoel, Port, Stone  by Resnick (for measure theoretic / modern approach?)  by Mosteller   Core Statistics (which one(s)?):    by DeGroot and Schervish  Casella and Berger   Other suggestions? Again with the goal of understanding and developing (or at least implementing) new methods in hierarchical modelling (generalized and linear).


Let $(X_n)$ be a sequence of independent RVs that converges in probability to some RV $X$. Show that $X$ is constant a.e.  My attempt  So from definition of convergence I have:  $$\forall\epsilon>0 \:\:\:\mathbb{P}(|X_n-X|>\epsilon)\longrightarrow0$$  I think that there is some useful theorem that I don't know. Can anyone help? I mean just give me some tip, not necessarily full answer.


java.lang.NoClassDefFoundError for external library

I have a simple program that parse csv file into json objects.  I added json.simple-1.1 into my maven. The content of my maven is like this:      <groupId>IoT</groupId>     <artifactId>ETL2</artifactId>     <version>1.0-SNAPSHOT</version>      <dependencies>     <dependency>         <groupId>com.googlecode.json-simple</groupId>         <artifactId>json-simple</artifactId>         <version>1.1</version>     </dependency>     </dependencies>        <build>         <plugins>             <plugin>                 <!-- Build an executable JAR -->                 <groupId>org.apache.maven.plugins</groupId>                 <artifactId>maven-jar-plugin</artifactId>                 <version>3.0.2</version>                 <configuration>                     <archive>                         <manifest>                             <addClasspath>true</addClasspath>                             <classpathPrefix>lib/</classpathPrefix>                             <mainClass>ETL2</mainClass>                         </manifest>                     </archive>                 </configuration>             </plugin>         </plugins>     </build>    I try to execute the jar artifact in the terminal.  I get these errors.      Error: A JNI error has occurred, please check your installation and   try again Exception in thread "main" java.lang.NoClassDefFoundError:   org/json/simple/parser/ParseException     at   java.lang.Class.getDeclaredMethods0(Native Method)    at   java.lang.Class.privateGetDeclaredMethods(Class.java:2701)    at   java.lang.Class.privateGetMethodRecursive(Class.java:3048)    at   java.lang.Class.getMethod0(Class.java:3018)   at   java.lang.Class.getMethod(Class.java:1784)    at   sun.launcher.LauncherHelper.validateMainClass(LauncherHelper.java:544)     at   sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:526)   > Caused by: java.lang.ClassNotFoundException:   org.json.simple.parser.ParseException     at   java.net.URLClassLoader.findClass(URLClassLoader.java:381)    at   java.lang.ClassLoader.loadClass(ClassLoader.java:424)     at   sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:335)     at   java.lang.ClassLoader.loadClass(ClassLoader.java:357)     ... 7 more   I read in here that      This is caused when there is a class file that your code depends on   and it is present at compile time but not found at runtime. Look for   differences in your build time and runtime classpaths.   That's why I suspect that my maven configuration might not be correct.


Where can I find an old version of dropbox app?

I'm using Android 2.3 and uninstalled dropbox. Then I wanted it back, but dropbox 3.01, the only official version available, is meant to work only from Android 4 on. Where can I find an old, trustable version of the dropbox 2.x that works for my phone?


How can I center the column when using X in tabularx environment like in this example?  \begin{tabularx}{\textwidth}{@{}lXXXXX@{}}  1 & 2 & 3 & 4 & 5 \\    \end{tabularx}


Suppose $G$ is a semigroup and it holds both left and right cancellation. Also for each $a,b\in G$, $xa=b$ has solution in $G$. Prove G is a group.   I know this question looks very "old" style. First I think it's easy for me too since I already practice probelems like "semigroup, $xa=b$ and $ax=b$ have solution , then group" Or "finite semigroup, both left and right cancellation hold, then group ". But I still get stuck... My try:  First of course, for $xa=a$ , there exists $e_a$ such that $e_aa=a$. Now we need to proof $e_a$ is left identity for all elements. Then left inverse exists hence $G$ is a group. But the key is to proof $e_ab=b$ for all $b\in G$.


Using keyboard alone, launch CMD with elevated privileges

Using the keyboard alone on Windows 7 or Windows 8, how can I open a privileged command prompt window with built-in tools?  I've unsucessfully tried Windows+R -> cmd -> runas /user:Administrator cmd but the resulting cmd doesn't run with administrator privileges (due to UAC )  I'm looking for a sudo equivalent essentially, without the mouse.  I've seen thus far. Is that the best way currently?


Obscured digits while chat in timeout for mobile client

As you can see, the top part of the countdown digits is obscured in mobile chat on Android Chrome.


How to exclude a specific warning while treating warnings as errors in Visual Studio

I have set VS 2010 to treat all warnings as errors in C# projects.    I want a specific warning to be excluded when compiler treats warnings as errors. Is there any way to do this?  With the options available it does not seem possible.


I can't seem to understand the following:  $$A^n-B^n=\left(A-B\right)\cdot \left(A^{n-1}+A^{n-2}\cdot B+\cdots+A\cdot B^{n-2}+B^{n-1}\right)$$  How can i derive this formula ? Also, when does the $A^\text{something}$ end and when does $B^\text{something}$ start.  Thank you.


I want to have global menu support for Java apps in Ubuntu 16.04. I think jayatana is installed by default in Ubuntu, but it isn't enabled by default. How can I enable it?


Running out of cards in Exploding Kittens

In the Exploding Kittens game, the rules say     You won't ever run out of cards in the Draw Pile, so there is never any need for a reshuffle.   In every game I've played all the cards end up on the discard pile fairly quickly and there is nothing left in the draw pile, so we have to reuse them.  Is this meant to happen? Are we doing something wrong?


What is the origin of the "-o-rama" suffix (such as in "app-o-rama"  by the Wall Street Journal), and how can this suffix be clearly defined?


Why wasn't Darth Maul able to react to Obi-Wans final attack?

I understand that Darth Maul was overconfident. I understand that Obi-Wans Force Jump and calling of Qui-Gons weapon was meant as a suprise to Darth Maul.  What I do not understand is, while in a fight the jedi and sith show us incredible fast Reflexes strikes and counterstrikes. Aided by the force (precognition and fast moving). If I remember the Scene correctly, Obi-Wan jumps out of the hole, jumps and saltoes over darth maul while grabbing and activating Qui-Gons weapon. But instead of an immediate fluid strike out of the same move, we see a stunned and disbelieving Darth Maul, and a still Standing  Obi-Wan who waits a full second before striking Darth Maul to peaces.  Why did Obi-Wan wait a full second? I think even out of universe it would have been as rule of cool if the strike was even while he was still saltoing over darth maul.  Darth Maul surely could be surprised a split second. But it seems highly unrealistic to me that he stood there frozen a full second, and no trained combat reflex kicked in, instinctivly blocking the strike. He was even able to turn around.  Edit:  I do not think its a duplicate. The "original" inspired me to ask this question. It states:     Even as he landed, he was drawing Qui-Gon Jinn’s fallen lightsaber to   his outstretched hand.   In the movie here is a full second nobody moves.     Darth Maul whirled to confront him, shock and rage twisting his red   and black face. But before he could act to save himself, Qui-Gon’s   lightsaber slashed through his chest, burning him with killing fire.   And I don't understand while the strike was "before he could act". Because in the movie he was able to turn around, Obi Wan waited a full second (why?) Darth Maul only looked surprised (a full second surprise? An experiences Fighter? So surprised that his trained reflexes don't let him block this simple strike that he had to wait for a full second?)


Join data using pivot table and alias columns

I have the following schema. CREATE TABLE `users`(                 id INT PRIMARY KEY AUTO_INCREMENT,                 steamid64 varchar(255) NOT NULL UNIQUE,                 steamid varchar(255) NOT NULL UNIQUE,                 name varchar(255),                 callsign varchar(255),                 qualifications LONGTEXT NULL,                 is_hidden BOOLEAN NOT NULL DEFAULT 0             );        CREATE TABLE `medals`(                 id INT PRIMARY KEY AUTO_INCREMENT,                 name varchar(255),                 description LONGTEXT,                 image TEXT,                 hierarchy INT UNIQUE NOT NULL             );          CREATE TABLE `has_medals`(                 id INT PRIMARY KEY AUTO_INCREMENT,                 medal_id INT,                 user_steamid64 varchar(255),                 issued_by_steamid64 varchar(255),                 FOREIGN KEY (user_steamid64) REFERENCES users(steamid64),                 FOREIGN KEY (medal_id) REFERENCES medals(id),                 FOREIGN KEY (issued_by_steamid64) REFERENCES users(steamid64)             );                          INSERT INTO users(id, steamid64, steamid, name, callsign)             VALUES (1, '76561198152109175', 'STEAM_0:1:95921723', 'vin', 'lorem ispum');                          INSERT INTO users(id, steamid64, steamid, name, callsign)             VALUES (2, '76561198163953541', 'STEAM_0:1:101843906', 'cleveland', 'lorem ispum');                          INSERT INTO medals(id, name, description, image, hierarchy)             VALUES (1, 'Test Medal', 'A Test Medal', 'http://google.com', 1);                          INSERT INTO has_medals(id, medal_id, user_steamid64, issued_by_steamid64)             VALUES (1, 1, '76561198152109175', '76561198163953541');  What I'm trying to do is get a result like this from a query based on a conditional select clause of finding all the medals a user has, the medals info, and all the user info from who gave them the medal.     id medal_id medal_name medal_description medal_image medal_hierarchy belongs_to_sid64 belongs_to_sid belongs_to_name belongs_to_callsign belongs_to_qualifications belongs_to_is_hidden issued_by_sid64 issued_by_sid issued_by_name issued_by_callsign issued_by_qualifications issued_by_is_hidden     I'm at a complete loss on how to do this. I tried messing around with some joins and stuff and couldn't get how I needed it. Can anyone help out? Here's an sql fiddle if anyone needs


Why did the Emperor want the Atreides wiped out?

In the film version of Dune, (and the novel, AFAIK) the Padisha Emperor conspired with the Harkkonens to eliminate House Atreides- but why did he choose to do so?


Finding out what OS is being run through a program

From a program created in Ruby is it possible to find out what OS the user is running from within the program?  For example could you check for a systems32 folder and from there decide that the user is running windows and use batch commands, or check for a root folder or something that all linux machines run and use bash commands instead?


Open document with default OS application in Python, both in Windows and Mac OS

I need to be able to open a document using its default application in Windows and Mac OS. Basically, I want to do the same thing that happens when you double-click on the document icon in Explorer or Finder. What is the best way to do this in Python?


Make WPF TextBlock text to be vertical within a expander

I have an WPF expander, and I have placed in its header a TextBlock. Now I am trying to put TextBlock text in vertical orientation. For example, if the text is "Settings" I want to put it in the following way:  S E T T I N G S   Expander xaml code:  <Expander Grid.Row="0"            Grid.RowSpan="2"           Grid.Column="1"            Width="25"           ExpandDirection="Left">     <Expander.Header>         <TextBlock Text="Settings">             <TextBlock.LayoutTransform>                 <RotateTransform Angle="-90"/>             </TextBlock.LayoutTransform>         </TextBlock>     </Expander.Header> </Expander>


How to use Uber my account with a different country sim but same email address

I have a different country sim to my country of origin account. When I put in the new number, I receive the OTP  so that works fine, but it will not let me get past the email address. It says it is already registered. The email address is the same as my country of origin account.  I want to book an Uber in NZ but can’t get beyond the prompt that says my email account is already registered.. please advise.


What is the difference between "as though" and "as if"?

I'm genuinely in confusion when it comes to using those two: can I draw a distintive line in using them?   Thank you.


Comparing strings from 2 objects returns false every time - javafx

I am trying to make Memory Puzzle game. So I have Card.java class:   import javafx.geometry.Pos; import javafx.scene.layout.StackPane; import javafx.scene.paint.Color; import javafx.scene.shape.Rectangle; import javafx.scene.text.Text;   public class Card extends StackPane {     private Text text = new Text ();     private String path;     public Card (String p){         this.path=p;         Rectangle rectangle = new Rectangle (80,80);         rectangle.setFill (null);         rectangle.setStroke (Color.BLACK);         text.setText (this.path);         setAlignment (Pos.CENTER);         getChildren ().addAll(rectangle, text);         hidden ();     }     public String getPath () {         return path;     }     public boolean isShown(){        return text.getOpacity () ==1;     }     public void shown(){         text.setOpacity (1);     }     public void hidden(){         text.setOpacity (0);     } }   Main.java:  [...] List<Card> cards = new ArrayList<> ();         for ( int i = 1; i <= numberOfPairs; i++ ) {             cards.add (new Card (String.valueOf (i)));             cards.add (new Card (String.valueOf (i)));         }         Collections.shuffle (cards);         int i = 0;         int j = 0;         for ( Card card : cards ) {             card.setOnMouseClicked (e -> cardClicked (card));             if (i == this.cardsInOneRow) {                 j++;                 i = 0;             }             gridpane.add (card, i, j);             i++;         } [...]     private Card selectedCard = null;     private int clickCounter = 0;     public void cardClicked (Card card) {         if (card.isShown () || clickCounter == 2) {             return;         }         clickCounter++;         if (selectedCard == null) {             selectedCard = card;             card.shown ();         } else {             card.shown ();                 if (card.getPath ()!=selectedCard.getPath ()) {                 selectedCard.hidden ();                 card.hidden ();                 }                 selectedCard=null;                 clickCounter=0;             }     }   In Main.java I'm creating couple pairs of cards, setting on mouse click function and placing them inside GridPane. Then I'm trying to compare String path from 2 cards and it results in false every time. I have no clue how to fix it.


Prob. 6 (d), Chap. 1, in Baby Rudin, 3rd ed: How to complete this proof?

Fix $b>1$.   Problem 6(a): Let $m$, $n$, $p$, $q$ be integers such that $n>0$, $q>0$, and $r = m/n = p/q$. Then I've managed to prove that $$b^{m/n} = b^{p/q}.$$ So we can reasonably define $b^r$ as $$b^r \colon = \sqrt[n]{b^m}.$$   From this definition, we can Problem 6(b) prove that $$ b^{r+s} = b^r \cdot b^s, $$ where $r$ and $s$ are any rational numbers.   Problem 6(c): Now for a rational number $r$, let the set $B(r)$ be defined as follows:  $$B(r) \colon= \{ \, b^t \colon \, t\in \mathbb{Q}, \, t \leq r \, \}. $$  Then it is clear that $$b^r = \sup B(r).$$ So for every real $x$, we can define $b^x$ as follows: $$b^x \colon= \sup B(x) = \sup \{ \, b^t \, \colon \, t \in \mathbb{Q}, \, t \leq x \, \}. $$   Problem 6(d): Using this definition, we are required to prove that, for every pair of real $x$ and $y$, the equation $$b^{x+y} = b^x \cdot b^y$$ holds.   My work:   If $r$, $s \in \mathbb{Q}$ such that $r \leq x$ and $s \leq y$, then $r+s \in \mathbb{Q}$ also and $r+s \leq x+y$ so that we can write  $$ B(x) \cdot B(y)  = \{ \, b^r \cdot b^s \, \colon \, r \in \mathbb{Q}, s\in \mathbb{Q}, \, r \leq x, s\leq y \, \} \subseteq \{ \, b^t \, \colon \, t \in \mathbb{Q}, \, t \leq x+y \, \} = B(x+y),$$ and hence  $$b^x \cdot b^y = \sup B(x) \cdot \sup B(y) = \sup \{ \, b^r \, \colon \, r \in \mathbb{Q}, \, r \leq x \, \} \cdot \sup \{ \, b^s \, \colon \, s \in \mathbb{Q}, \, s \leq y \, \} = sup \{ \, b^{r+s} \, \colon \, r \in \mathbb{Q}, \, s\in \mathbb{Q}, \,  r \leq x, \, s \leq y \, \} \leq \sup \{ \, b^t \, \colon \, t \in \mathbb{Q}, \, t \leq x+y \, \} = \sup B(x+y) = b^{x+y}.$$  Here we have used the following definition: Given two non-empty sets $U$ and $V$, say of real numbers, we define the set $U \cdot V$ as follows:  $$U \cdot V \colon= \{ \, u \cdot v \, \colon \, u \in U, \, v \in V \, \}.$$   And we have also used the fact that if $W$ and $Z$ are two non-empty bounded above subsets of the set of positive real numbers such that $W \subseteq Z$, then we must have  $$ \sup W \leq \sup Z.$$   So far, we have shown that $$b^x \cdot b^y \leq b^{x+y}.$$  Now how to prove the reverse inequality using the machinery developed above?  That is, how to prove that $$b^{x+y} \leq b^x \cdot b^y?$$


I have a class function int ComputerClass::getGuess() that every time it is called should produce a randomized number.  In my main function I created 2 functions of the class ComputerClass Computer1,Computer2 and called the class function, however it returns the same number for each call:  cout << Computer1.getGuess()<<endl; cout << Computer2.getGuess()<<endl;   Below is the class member function   int ComputerClass::getGuess() {     //Generate randomn number     srand(time(NULL));     generatednumber = rand() % 100 + 1;      //return computers randomly generated #     cout <<"--(Computer)Please enter a guess between 1-100: "<<      generatednumber<<endl;      return generatednumber; }   I'm assuming my issue is the seed value, however I don't know how to set it up so that makes the number random every time it is called.


I have an array of type double storing 3 values I want to increment the value by 3 cents but I get a bunch of decimal places I can't seem to figure out what the problem is   double [] cupsPrice = {0.93, 1.65, 2.77};     for(int i=0; i<7; i++){     for(int l=0; l<3; l++){         cupsPrice[l] += 0.03;     } }////expecting 0.96 in second run but is returning 0.0960000000000001


Proving $x^{1/x}$ approaches $1$ as $x$ approaches infinity

I was trying to solve a question that was uploaded here ():  $$\lim_{x \to \infty} \frac  {1 + 2^{1/2} + 3^{1/3} +...+ x^{1/x}}{x}$$  So i used the identity $$\lim_{x \to \infty} x^{1/x} = 1$$ and tried to prove it myself.  Since $$(\sqrt[x]{x})^x = x\implies f(x) = \sqrt[x]{x} =  \frac x{(\sqrt[x]{x})^{x-1}}$$  I tried to prove that there is a horizontal asymptote at $y=1$ when $\lim\limits_{x \to \infty} x$ using the latter function without using L'Hôpital's rule. I want to emphasize that I am not currently trying to solve the first limit, but trying to prove the asymptote of the function $f(x)$.  Any suggestions?


-y in Linux for example dnf -y install samba

what does the -y mean in linux. this symbol is always used after a command for example dnf -y install httpd.  Everywhere I have looked I cannot find a definite answer. Please help


NEC 2014: How many 12-2 Romex wires can I run through a hole in ceiling joist?

What does the 2014 code say about number of wires run through a bored hole? Can I run 2 Romex 12-2 cables through a 3/4in or 1in hole? I need to add outlets to my unfinished basement (probably 8 total) and I need to run a new circuit from panel. Can I save myself some time and hassle by running my new wire through a current hole w/1 existing wire?


Different counting problem by upper/lower case in list matching

Name Text 0   K    IeatApple 1   Y    bananaisdelicious 2   B    orangelikesomething  3   Q    blueBanana 4   C    appleislike  I want to match the 'text' column and list in the data frame. However, there is no distinction between lowercase and uppercase letters in the'text' column. So, to capture all of them, the list was changed to a regex as follows. mylist = [apple, banana] mylist = [f"(?i){re.escape(k)}" for k in mylist]  #contain matching list - column extracted = df['text'].str.findall(f'({"|".join(mylist)})').apply(set)  #Matched words are added to the data frame as column. df['matching'] = extracted.str.join(',')  #keyword counting s = pd.DataFrame(extracted.tolist()).stack().value_counts() print(s)  Apple 1 Banana 1 banana 1 apple 1  One problem with doing this is that it recognizes'apple' and 'Apple' differently. Is there a way to match both the upper and lower case letters and spell the same word?


Example where union of increasing sigma algebras is not a sigma algebra

If $\mathcal{F}_1 \subset \mathcal{F}_2 \subset \dotsb$ are sigma algebras, what is wrong with claiming that $\cup_i\mathcal{F}_i$ is a sigma algebra?  It seems closed under complement since for all $x$ in the union, $x$ has to belong to some $\mathcal{F}_i$, and so must its complement.  It seems closed under countable union, since for any countable unions of $x_i$ within it, each of the $x_i$ must be in some $\mathcal{F}_j$, and so we can stop the sequence at any point and take the highest $j$ and we know that all the $x_i$'s up to that point are in $\mathcal{F}_j$, and thus so must be their union. There must be some counterexample, but I don't see it.


error 4430: missing type specifier - int assumed. Note: C++ does not support default-int

fndef FIXED_LENGTH_STRING_H #define FIXED_LENGTH_STRING_H  #include <iostream>  using namespace std;  #include <string.h>  template <int Length> class FixedLengthString     {     public:         enum Exceptions {InvalidLength};                                         FixedLengthString       ();                                         FixedLengthString       (const FixedLengthString <Length> &);                                         FixedLengthString       (const char []);                                         ~FixedLengthString      ();                                         Copy                    (const FixedLengthString <Length> &);                                         Copy                    (const char []);         istream &                       Read                    ();         FixedLengthString <Length> &    operator =              (const FixedLengthString <Length> &);         FixedLengthString <Length> &    operator =              (const char []);         bool                            operator <              (const FixedLengthString <Length> &) const;         bool                            operator <              (const char []) const;                                             // also need the other comparison operators                                         operator const char *   () const;     private:         char    Data [Length + 1];     };  template <int Length> ostream & operator << (ostream & out, const FixedLengthString <Length> & Str)     {     // display the characters in the string     return out;     }  template <int Length> istream & operator >> (istream & in, FixedLengthString <Length> & Str)     {     Str.Read ();     return in;     }  template <int Length> FixedLengthString <Length>::FixedLengthString (const char S [])     {     if (Length != strlen (S))             throw InvalidLength;         else             strcpy (Data, S);     }  template <int Length> inline FixedLengthString <Length>::operator const char * () const     {     return Data;     }  #endif   The compiler is pointing at the two Copy constructors. I am creating a template with the number of characters as the template argument. From this I need a fixed length string  In my FixedLengthString.cpp file i have this  FixedLengthString<Length>::Copy(const FixedLengthString <Length> & M) { strcpy(Data, M.Data) }  template <int Length> FixedLengthString<Length>::Copy(const char M []) { strcpy(Data, M.Data) }


Things to do in 12 hour Night layover in Dubai?

I am looking for things to do in Dubai at night. I will be travelling in mid-June and will be arriving at 12.30 am. My connecting flight is at 1 pm next afternoon. I have glanced through the criteria for visa and I qualify to apply. I want to know what are the things that can be done in the time I have, provided I reach airport by 11 am for my connecting flight. I am more interested in sight seeing than sitting in pubs. Can anyone please guide me? Also what mode of transportation do you recommend considering a tight budget?


Why do we use wrapper class Integer in ArrayList a1 = new ArrayList()?

I have very basic doubt related to ArrayList Collection class.Consider the following declaration :   ArrayList<Integer> a1 = new ArrayList<Integer>();   Now, I want to know why are we using wrapper class 'Integer' here and why we can't use primitive type 'int'.I assume the answer would be so that we can perform different operations like toString etc. on the object created and to pass reference.Please correct me if I am wrong anywhere.  I executed following code to check how to pass reference but its not working.I mean method modify() should change value at index 0 if we are passing reference.....right? Please let me know what's wrong in below code:  import java.util.*; class ArrayvsLinkedList {  public static void main(String args[])  {   int n = 1000000;   ArrayList<Integer> a1= new ArrayList<Integer>();    for(int i=1;i<=n;i++)    a1.add(i);    System.out.println("Before method called"+a1.get(0));     new ArrayvsLinkedList().modify(a1.get(0));    System.out.println("After method called"+a1.get(0));  }  void modify(Integer x)  {   x=x*5;   System.out.println("Inside method "+x);  }  }


I am guessing differences in the following two codes. The first one is in python and works just fine.Here it is:  >>> def foo():         if 1:             print "this is working"             n=6          print "the value of n is {0}".format(n)   >>> foo() this is working the value of n is 6   The second one is in c, i guess the way i want to implement both programs is same.Here it is:  void main(){     if(1){         printf("this is working");         int n=9;     }     printf("the value of n is %d",n); }   n goes undeclared in the c code while it works good in python. I know that in the c code n has scope within the if block.But why there is no as such scope issue in python. Do the variables inside a block { } are stored in different memory stacks in c while in python they are stored in function's memory stack ?.Correct me if i am wrong somewhere. Regards.


I wonder whether there are rules or guidelines regarding plural nouns in nominal compounds. For example a compound university students list. If there are many lists and many universities is it grammatically correct to say universities students lists? Must all elements be in the plural form or can some be left in singular, even though the meaning is plural? I've seen an expression universities student lists; is it correct?


How come in English we don't put symbols above our letters to change how they are pronounced?

How come in English we don't put symbols (things) above our letters to change how they are pronounced?  In French for example they have an acute accent ( ´ ) and grave ( ` ) and the cedilla that goes under the "c" and in Spanish they sometimes put ~ over the "n".  Many languages do this so why not English?


Kids' fantasy movie from the 80s or 90s?

I have memories of a fantasy movie that I watched as kid, yet I can't remember the title or a single character's name! The protagonist was a boy. I know that it took place in a fantasy realm, possibly starting on Earth and then traveling to that fantasy realm. There was definitely an older mentor in the film, who is murdered by the main villain in combat. The villain was very pale and I remember a shot of the dying mentor with a diagonal slash across his face from the villain's blade. It was definitely live-action, in color, I remember watching it on VHS in English, probably got it from Blockbuster in the US, pretty sure the world had some form of magic in it, at least some of the fighting was martial-arts-esque, pretty sure (but not positive) there were sentient non-humans (maybe like Ewoks but wiser/less ridiculous). I believe the swords were metal, not laser swords or anything, and at least the villain used a large curved sword/scimitar


ostringstream s;      s << "123";     cout << s.str().c_str() << endl;      // how to clear ostringstream here?     s << "456";     cout << s.str().c_str() << endl;   Output is:   123 123456   I need:   123 456   How can I reset ostringstream to get desired output?


how to get the member detail from the array

I add a member detail from add() method , after that i go modify() to edit member detail by searching memberID, compare the stored memberID with the user entered memberID , if match then display the member detail else display invalid, so what should i create to do so?    public static void Modify(Registration [] reg){      Scanner scan = new Scanner(System.in);      System.out.print("Enter member id to search : ");      String search = scan.nextLine();      for(int i=0;i<reg.length;i++){     /*if(search == member[i].getMemberID()){     System.out.println(reg[i].toString());      }      else      System.out.println("Invalid.");*/      }}}


In the first comment in the above image, Chris's username is highlighted, because he is the original question asker. Sam's comment however, looks like anyone else's, despite being the answerer. While in the case of this particular comment chain, it doesn't really matter who is replying to Chris, in others, especially longish chains, it can get confusing who is the asker, answerer, and chimer-inners. Perhaps something minor, such as underlining it?


How to evaluate the integral $\int e^{x^3}dx $

How to evaluate the integral $$\int e^{x^3}dx \quad ?$$  I've tried to set $t=x^3$, but it seems to be a blind alley; I don't know what to do with $\int\frac{e^t}{3\sqrt[3]{t^2}}dt$.


I am trying to run sudo apt dist-upgrade and I am am getting an connection error. It is trying to update the package fwupdate.  Is this because the server is just down, or is there another problem with my system that could be causing this?  Err:1 ftp://ftp.cs.mun.ca/pub/mirror/ubuntu xenial-updates/main amd64 fwupdate amd64 0.5-2ubuntu7   Could not connect to ftp.cs.mun.ca:21 (134.153.48.2), connection timed out Err:2 ftp://ftp.cs.mun.ca/pub/mirror/ubuntu xenial-updates/main amd64 libfwup0 amd64 0.5-2ubuntu7   Unable to connect to ftp.cs.mun.ca:ftp: E: Failed to fetch ftp://ftp.cs.mun.ca/pub/mirror/ubuntu/pool/main/f/fwupdate/fwupdate_0.5-2ubuntu7_amd64.deb Could not connect to ftp.cs.mun.ca:21 (134.153.48.2), connection timed out  E: Failed to fetch ftp://ftp.cs.mun.ca/pub/mirror/ubuntu/pool/main/f/fwupdate/libfwup0_0.5-2ubuntu7_amd64.deb Unable to connect to ftp.cs.mun.ca:ftp:  E: Unable to fetch some archives, try running apt-get update or apt-get --fix-missing   .


Let $n = pq$ where $p$ and $q$ are distinct, odd primes. Show that there exists $\alpha,\beta\in\mathbb{Z}^*_{n}$ such that $\alpha$ and $\beta$ are not elements in $(\mathbb{Z}^*_{n})^2$, and $\alpha\beta$ is not an element in $(\mathbb{Z}^*_{n})^2$.   Any help would be appreciated.


Is it possible to add a colour code on a print statement so that I can output coloured text? Is there anything in the standard Python libraries that lets me do something like:  print "Hello, world!", #f3f3f3


So while installing Ubuntu MATE 17.04 Grub failed to install and I need to choose where to install the boot loader. The way I see it I have 3 places where I can place it: sda (my supposed ssd but where grub couldn't install) sdb which is where ubuntu is located but not where windows is installed, or sdb1 which is labeled windows 10.  Basically W10 is installed on my ssd while Ubuntu is on my regular hard drive and I am unsure of where to install the bootloader


Sampling from matrix-variate normal distribution with singular covariances?

The matrix-variate normal distribution can be . However, if one or both of the covariance matrices are positive semi-definite and not positive definite (for example a block structure due to several pairs of perfectly correlated features and samples) the Cholesky decomposition fails, e.g.   $\Sigma_{A} =  \begin{bmatrix}  1 & 1 & 0 & 0\\ 1 & 1 & 0 & 0\\ 0 & 0 & 1 & 1\\ 0 & 0 & 1 & 1 \end{bmatrix}  \quad $or another example:$ \quad \Sigma_{B} =  \begin{bmatrix}  4 & 14 & 0 & 0\\ 14 & 49 & 0 & 0\\ 0 & 0 & 25 & 20\\ 0 & 0 & 20 & 16 \end{bmatrix}$  Where $\Sigma_{B}$ is generated from $R$ (correlation matrix this time) = $\Sigma_{A} $   and $D$ (standard deviations) = $\begin{bmatrix}  2 & 0 & 0 & 0\\ 0 & 7 & 0 & 0\\ 0 & 0 & 5 & 0\\ 0 & 0 & 0 & 4 \end{bmatrix}$ via $RDR$.  Is it possible to adapt the  that overcomes this difficulty to the matrix-variate case?     This question is different from this  in that it is not clear if the lower diagonal produced by the SVD based sampling technique will suffice, since it is  that might be performed in this case by . Also, the mentioned  is not concerned with positive semi-definite matrices.


Are there strange attractors whose coordinates are "almost integers"?

I'll summarize first and then add details.  Please forgive me as I'm delving into the field of chaos without much knowledge of it, seeking an expert to help point me in the right direction.  Are there dynamic maps with strange attractors whose coordinates (or defining functions) are almost integers, in the sense that they could be described in the decimal system with very few digits to the right of the decimal point?  To make this idea of "almost integers" more precise, I'm looking for systems that essentially require coordinates with $n$ digits to the right of the decimal point, and $\exp(n)$ digits to the left of the decimal point.  For example, in the Mathematica 9 documentation of "RecurrenceTable", they delve into a system of the form:  $$ \begin{align} x_{n+1} &= \alpha x_n + y_n \\ y_{n+1} &= \beta + \left(x_n\right)^2 \\ y_0     &= \delta \\ x_0     &= \gamma \end{align} $$  I'm looking to find dynamic maps like this example that possess at least one strange attractor.  The important part is that this strange attractor can be described by large real or complex numbers that are "almost integers".


I want to use JDOM to read in an XML file, then use XPath to extract data from the JDOM Document.  It creates the Document object fine, but when I use XPath to query the Document for a List of elements, I get nothing.  My XML document has a default namespace defined in the root element.  The funny thing is, when I remove the default namespace, it successfully runs the XPath query and returns the elements I want.  What else must I do to get my XPath query to return results?  XML:  <?xml version="1.0" encoding="UTF-8"?> <collection xmlns="http://www.foo.com"> <dvd id="A">   <title>Lord of the Rings: The Fellowship of the Ring</title>   <length>178</length>   <actor>Ian Holm</actor>   <actor>Elijah Wood</actor>   <actor>Ian McKellen</actor> </dvd> <dvd id="B">   <title>The Matrix</title>   <length>136</length>   <actor>Keanu Reeves</actor>   <actor>Laurence Fishburne</actor> </dvd> </collection>   Java:  public static void main(String args[]) throws Exception {     SAXBuilder builder = new SAXBuilder();     Document d = builder.build("xpath.xml");     XPath xpath = XPath.newInstance("collection/dvd");     xpath.addNamespace(d.getRootElement().getNamespace());     System.out.println(xpath.selectNodes(d)); }


Need help with the integral $\int_{0}^\infty e^{-x^{2}}x^{2n+1}dx $

Problem: Prove that $$I = \int_{0}^\infty  e^{-x^{2}}x^{2n+1}dx = \frac{n!}{2}     $$  Source: A problem I found on an integral test. The problem bugged me for long and I did end up leaving it on the exam. Back home I decided to tackle it again. Here's my go on it.  My try: I have never encountered such a problem before, not even in my assignments and workbooks. Here's how I tried it  We can first take an indefinite integral and then we can work up towards a reduction formula.We can plug in the limits later. I don't know if it's any good but I did write this up on the exam: $$I_{2n+1} = \int{e^{x^{-2}}}{x^{2n+1}}dx$$  On applying Integration by parts:  $$I_{2n+1} = e^{-x^{2}}\frac{x^{2n+2}}{2n+2} +\frac{2}{2n+2} \int{e^{-x^{2}}}{x^{2n+3}}dx$$  or $$I_{2n+1} = e^{-x^{2}}\frac{x^{2n+2}}{2n+2} +\frac{I_{2n+3}}{n+1} $$ or  $$I_{2n+1} = {e^{-x^{2}}\over 2}\Bigl(\frac{x^{2n+2}}{n+1}\Bigl) +\frac{I_{2n+3}}{n+1} $$  What can I do next? Am I doing it incorrectly? Is this the wrong way? Please help me as I can't stop thinking about this problem! Thanks!  Edit 1: As suggested (already tried by me) lets put $u = -x^2$ $$ du = -2xdx$$ plug the above expression in the problem  $$I_{n} = -{1 \over 2}\int{e^{u}}{u^{n}}du$$  $$I_{n} = -{1 \over 2}e^{-u}\frac{u^{n+1}}{n+1} + \frac{I_(n+1)}{n+1}$$  Certainly helps. Now what?  Edit 2: Use the  to get the result. Now unfortunately I didn't read it for the test that's why I didn't get it. Thank you all for pointing out the right direction!


Is there a way to get Magic Lantern on my newer model Canon?

I recently bought a Canon Rebel T6i (750D) and have a short film project coming up soon. I want Magic Lantern on my camera (SD Card) for its fantastic enhanced features, but I am unable to find it from the Magic Lantern website or any other sources.  It would be a great help if someone could post a source where I can download this.


Java: final string comparison does not work

I have created final strings for certain commands but when I try to check if the command given by the user matches, it does not work.  These are examples of my final strings:  public static final String END = "quit"; public static final String SHOW = "print";   But if I were to use it e.g. like this:  String command = scanner.nextLine(); if (command == SHOW) {    System.out.println("Print this line."); }    It sees that they do not match even if they do. I tried printing the finalized variables:   System.out.println(END);   and it prints its value, but for some reason when I compare them to identical strings provided by the user, it does not recognize them.  I have tried to search similar examples and read about finalizing variables, but I think I am missing something important. I know that the problem is with the final variables and not elsewhere, because the program works if I compare these same strings with equal. E.g:  String command = scanner.nextLine(); if (command.equals("print") {    System.out.println("Print this line."); }   I am assuming that there is something very simple that I am doing wrong, but I could not find any answer anywhere that I would understand. I am still a beginner and all the other examples regarding similar questions include some features that I don't understand, so they don't help me to see what I am doing wrong.


I'm looking to prove that any $d$-regular bipartite graph satisfies the HALL condition and contains a perfect matching.  I'm having trouble seeing why, if $G=(V,W,E)$, for any $H \subseteq V$, $|H|\leqslant |N(H)|$.  Would appreciate an answer!   Edit: For degree $\geqslant 1$ obviously.


How to set default parameters for an application?

Is it possible to set default parameters for an application in Windows XP? (without using a shortcut) For example, I want Firefox to run with the parameters "-p username" when I run "firefox.exe".


how to install google chrome from terminal

I tried to do this in the terminal sudo apt-get install google chrome  but the package does not exist please help


Does Stokes theorem depend on the definition of a closed curve?

The two-dimensional Stokes theorem, written in vector notation, reads $$\oint_\mathcal{C} \vec{F} \cdot d \vec{r} = \int_\mathcal{S} (\vec{\nabla} \times\vec{F})\cdot d \vec{S},$$ where the closed curve $\mathcal{C}$ is the boundary of the surface $\mathcal{S}$, $\mathcal{C} = \partial \mathcal{S}$.  Now, the usual definition of a closed plane curve $\gamma$ is $$\gamma:[a,b] \to \mathbb{R}^2,$$ with $\gamma(a) = \gamma(b)$. However, wouldn't it make more sense to define a closed curve as $$\gamma:[a,b\rangle \to \mathbb{R}^2,$$ with the condition $$\lim_{t \to b} \gamma(t) = \gamma(a)?$$ In this way, no point on the curve is parametrized twice (assume $\gamma$ is injective), and this is consistent with, e.g., the polar coordinate $\varphi$ which has the domain $\varphi \in [0,2\pi\rangle$.  My question: would the change in the definition of a closed curve alter Stokes theorem in any way?


I would like there to be several buttons in this GUI to play multiple sounds while at the same time editing a text file so the next time the program runs the songs playing upon closing are still playing. I've gotten to one song so far but it won't open and give me this error. I haven't been coding java for that long so I think its something stupid that I've missed.   The code  import javax.swing.*; import java.awt.event.*; import java.awt.*; import java.applet.Applet; import java.applet.AudioClip; import java.net.URL;  public class AddSound extends JFrame {     JButton Play = new JButton("Play");     JButton Loop = new JButton("Loop");     JButton Stop = new JButton("Stop");      URL music1 = AddSound.class.getResource("music1.wav");     AudioClip clip = Applet.newAudioClip(music1);      public AddSound() {         super("AddingSound");         setLayout(new FlowLayout());          Play.addActionListener(new ActionListener() {             public void actionPerformed(ActionEvent e) {                 clip.play();             }          });          Loop.addActionListener(new ActionListener() {             public void actionPerformed(ActionEvent e) {                 clip.loop();             }          });          Stop.addActionListener(new ActionListener() {             public void actionPerformed(ActionEvent e) {                 clip.stop();             }          });         add(Play);         add(Loop);         add(Stop);     }      public static void main(String args[]) {         JFrame frame = new AddSound();         frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);         frame.setSize(90, 90);         frame.setVisible(true);     } }


What is the exact reputation required to vote in a moderator election?

Here are my queries..   What is the exact number of reputation required to vote in a moderator election?  Is it like I should have the same amount of reputation on all the sites where I am a member. Or if I have sufficient reputation on one of the Stack Exchange sites, is that sufficient to cast votes? What are the badges that one should possess in order to cast votes?  Just like the candidates who are competing for the moderator election, should the voters need some basic badges in order to participate in the election?


If energy can't be created and can't destroyed

Then wouldn't be logical that all the energy in the big-bang-created-universe will equal to the energy that was released by the Big Bang?  The sum is zero?  Edit The cited dup is asking "Did the law of conservation of energy apply to the earliest moments of the Big Bang? If so, what theoretical physics supports this?"  I want to know whether the source of all energy is the big bang or not.  thanks!


I've seen similar questions, but not one specifically for vanilla Minecraft 1.10.2.  My dad and I are on the same LAN, same version and have separate accounts, but the multiplayer world doesn't show up (Open to LAN), Multiplayer...  As far as the computers, they are both Mac Airs with El Capitan.  What are we doing wrong? We have played multiplayer heaps of times on previous versions.


Optional argument not getting set to \makebox through expl3 key assignment

The basic idea that I wanted was to create a key to pass a value that would inform \makebox how the contents of the box should be aligned.  Big fail here.    The intended contents of the \makebox are not passed as arguments to \makebox and I seem to have random components of my keys ignored or inserted into the text.  What's happening here?  \documentclass{article} \usepackage{xparse} \ExplSyntaxOn  \tl_new:N  \l_aefl_position_tl \tl_set:Nn \l_aefl_position_tl { [l] }  \keys_define:nn { aefl }     {         pos   .code:n   = {                             \str_case:nnn { #1 }                             {                                 { left   } { \tl_set:Nn \l_aefl_position_tl {[l]} }                                 { center } { \tl_set:Nn \l_aefl_position_tl {}    }                             }                             {                                 { right } { \tl_set:Nn \l_aefl_position_tl {[r]} }                             }                           },     }  \NewDocumentCommand{\aecurrfile}{ o }     {         \group_begin:         \IfNoValueF{#1}{\keys_set:nn { aefl }{#1}}          \makebox[0pt] \l_aefl_position_tl                       { contents ~ of ~ my ~ box }         \group_end:     }  \ExplSyntaxOff \pagestyle{empty} \begin{document}  \begin{tabular}{lcl} unexpected & \verb=[l]=      & \aecurrfile                        \\ unexpected & \verb=[l]=      & Front \aecurrfile[pos=left] Back   \\            &                 & Front \aecurrfile[pos=center] Back \\ unexpected & \verb=right[l]= & Front \aecurrfile[pos=right] Back \end{tabular}  \end{document}   EDIT  Finally, I see why I'm getting the unexpected right in my output.  Argh!


The context Consider the following directory $ tree -a $(pwd) | sed "s,$HOME,~,g" ~/mytest ├── 1 │   ├── 1.txt │   └── 2 │       └── 1_2.txt └── 2     └── 2.txt  3 directories, 3 files  and the following files $ find $(pwd) -type f \ | while read l; do echo "File: $l"; cat $l; done \ | sed "s,$HOME,~,g" File: ~/mytest/1/2/1_2.txt 1 File: ~/mytest/1/1.txt 1 File: ~/mytest/2/2.txt 1  As can be seen above, all files contains the pattern 1. What I want to do is to search a pattern in all directories but the ~/mytest/2 directory. That is, I do want grep to include the ~/mytest/1/2 directory when searching. The problem I first tried executing the following command  grep --exclude-dir=2 -R '1' . but it excludes the ~/mytest/1/2 directory.  According to the manual page of the grep command in my system, the --exclude-dir flag waits for a pattern $ man grep ... --exclude-dir=GLOB     Skip any command-line directory with a name suffix that matches the pattern GLOB.    When searching recursively, skip any subdirectory whose base name matches GLOB.  Ignore any redundant trailing slashes in GLOB. ...  Because of this, I've tried with the following commands but none of them worked.  grep --exclude-dir="./2" -R '1'  but tt doesn't exclude the ~/mytest/2 directory. grep --exclude-dir="./2/*" -R '1' . but it doesn't exclude the ~/mytest/2 directory. grep --exclude-dir="$(pwd)/2" -R '1' .: but it doesn't exclude the ~/mytest/2 directory. grep --exclude-dir="$(pwd)/2/*" -R '1' .: but it doesn't exclude the ~/mytest/2 directory.  The question Which are the flags that would need to be used to make grep exclude an specific directory (A) without making it exclude those directories that have the same name as (A)? Note that in the minimal working example, the answer must output the following $ grep {options} ./1/2/1_2.txt:1 ./1/1.txt:1  Additional context I can accomplish that by running the following command (see code below). However, I'm interested in understanding how to do it just by using grep. I do want to understand why the arguments (which I've tried and which are patterns) passed to the --exclude-dir flag does not cause grep to exclude that specific directory. At the end, they were patterns which only match the ~/mytest/2/ directory. $ find . ! -ipath "./2/*" -type f -exec grep '1' {} + ./1/2/1_2.txt:1 ./1/1.txt:1


Imagine a space ship orbiting the sun at near relativistic speeds, when compared to Earth (say from the reference frame of the sun) there would be x amount of time dilation.  This would mean people on the ship could live for 100's of Earth years.  My question is what would happen if a second ship flew directly away from the Sun and back (ignoring acceleration) at the same speed the orbiting ship is travelling, would the time dilation for the ship that travels in a straight line be the same as that moving in a circle?  The reason I ask is that I was imagining a scenario where intergalactic travel is possible as time dilation means even a journey of light years only ages the crew a fraction of that time, with space stations orbiting certain star systems at similar speeds so that people that don't work on ships can live a similar length of time. I understand that time dilation is all linked to a certain reference frame but working with a reference frame of the sun what would the time dilation be for the different objects taking different paths but at the same speed relative to the sun? If the ship docked back with the space station would they both say the same amount of time had passed?


Is there a way to send and receive SMS when a cellular signal is not available, but WiFi is?  I'm often on-site at locations where the building has a strong WiFi (Internet) connection, but a simple cell signal is spotty at best.


Let $\theta = 2\pi/67$. Now consider the matrix   $$  A =  \begin{pmatrix}   \phantom{-}\cos \theta & \sin \theta \\   -\sin \theta & \cos \theta  \end{pmatrix}. $$   Then the matrix $A^{2010}$ is      \begin{align*}  &\text{(A)}\;  \begin{pmatrix}   \phantom{-}\cos \theta & \sin \theta \\    -\sin \theta & \cos \theta  \end{pmatrix},  &  &\text{(B)}\;  \begin{pmatrix}   1 & 0 \\   0 & 1  \end{pmatrix}, \\  &\text{(C)}\;  \begin{pmatrix}   \phantom{-}\cos^{30} \theta & \sin^{30} \theta \\    -\sin^{30} \theta & \cos^{30} \theta  \end{pmatrix},  &  &\text{(D)}\;  \begin{pmatrix}   \phantom{-}0 & 1 \\   -1 & 0  \end{pmatrix}. \end{align*}   I think answer is B. But I am not sure.


How to read only the second last line of a file

I have a client that updates/writes into myfile.csv arbitrarily.  I've written the following code, I left the MySQL snippet out:  while true do   awk_variables_value_array=`tail -n2 myfile.csv | awk -F, '$7 == "status" {print $4, $5, $10 }'`   var1=${awk_variables_value_array[0]}   var2=${awk_variables_value_array[1]}   var3=${awk_variables_value_array[2]}    if[ "var3" -gt "0" ]   --MYSQL SNIPPET IS--   fi done  Q: tail -n2 reads the last 2 lines, how can I change it is so it's the second last line  the file:  where n is the last line of the file  line 1 line 2 line 3 line 4 .... line n-2 line n-1 line n  current output yields:  line n-1 line n   I would like it so that the output is:  line n-1


Do Demons in Demonform need to Eat/Drink/Sleep?

Demonform is quite inhuman. Fluff-wise, it would not be unreasonable to be, for example, a collection of gleaming steel limbs orbiting a dazzling diamond core, with a glowing, radar-encrusted spun-copper head hovering above.  But I am unsure as to what extent this frees demons from human needs.  Do they need to eat, drink, or sleep?  Can they catch diseases? Or be poisoned?  Obviously, under most circumstances a un-covered demon is going to be under a lot of heat from the God Machine long before starvation or even dying of thirst is a real issue, but I can imagine scenarios where a burned demon might survive days — enough time that thirst could become a real issue. Would it?


A continuous function is called convex on an interval $I\subseteq\mathbb R$ iff $$\forall x,y\in I\;\forall t\in[0,1]:f\big((1-t)x+ty\big)\leq (1-t)f(x)+tf(y).$$ I want to prove that this is equivalent to $$\forall x,y\in I:f\left(\frac{x+y}2\right)\leq \frac{f(x)+f(y)}2.$$ One direction is clear as the second inequality follows from the first one if you choose $t=\frac12$.  However, I am getting stuck proving the reverse direction. How should I proceed here?  By the way, it seems like the second inequality is just a special case of the first one for $t=\frac12$ and is therefore weaker. How can both definitions be equivalent then?


I've accidentally stumbled into the l command in ubuntu which is pretty similar to ls, although the output is slightly different.  For instance, the output of both commands in a directory with the following tree structure is:  Test |_ Folder1 |_ Folder2 |_ File1 |_ File2  ~/Test$ ls File1  File2  Folder1  Folder2  ~/Test$ l File1  File2  Folder1/  Folder2/   Note the slahes at the end of each folder. What exactly is l and which differences does it have with respect to ls?


Here's the situation: I meet a friend and I tell her about yesterday:     “Hey, John!”   “Hi, Sarah!”   “How was yesterday's trip?”   “It was great. Karl took me to the countryside to show me his new house. It reminded me of the/a house I rented in Oxford.”    “...a house I rented in Oxford.” indicates one of the (multiple) houses I rented in Oxford? “...the house I rented in Oxford.” indicates I rented only one house in Oxford?


How to prove (A v B), (A → C), (B → D) therefore (C v D)

Obviously since A → C and B → D then if A v B one of C or D must be true.   My only idea is v must be introduced, but how would I use subproofs to show one of A /\ C or B /\ D is never false if A v B?


iPhone recorded videos getting rotated on Windows systems

I am recording videos on iPhone and uploading them to my Linux server. Users can see these videos on website. If users are seeing videos on mac or iDevices the video is looking fine but when users are seeing that video on windows systems these videos are getting rotated.   I am assuming this is because of some apple's flag in the recorded video which Windows systems are not able to read. Can I record videos in some way so they don't get rotated on Windows systems? Or is there any way I can re-encode videos with proper interface orientation using FFmpeg?  I am open to both FFmpeg or iOS way.


Can I capture only a particular colour with a Canon 650D?

I have a Canon DSLR 650D, and I want to know if there are any settings or features in the camera that will only catch/accept the predefined color. For example, I just want to capture only red color and everything else should be B/W.  Please don't suggest Adobe Photoshop — I want to do this in-camera.


Python referenced local variable before assignment

I am working on a currency converter for my computing GCSE at school and I have no idea what I am doing wrong here.  My code is:  PD = 1.66401 # declare pounds to dollars exchange rate  def Convert(ex): #converting sub... ex = exchange rate     amount = input("Enter amount to convert: ") #get amount to convert     result = round(float(amount) * float(ex),2) #calculate result using PD rate     print("result = " + str(result)) #print result  def Change(ex): #change sub... ex = echange rate     newex = input("Enter new exchange rate: ") #allow user to enter new exchange rate     if ex == PD: #check what exchange rate to change (needed because final version will have alot more options         PD = float(newex) #change exchange rate  #display menu menu = input("1.Convert\n2.Modify exchange rate\nPlease select option: ") if menu == "1":     Convert(PD) #Call sub...convert using pounds to dollars elif menu == "2":     Change(PD) #Call sub...change pounds to dollars exchange rate   When I convert it works correctly but when changing exchange rate i get the following error:  Traceback (most recent call last):   File "F:/USB/Computing/Programming/Python/test2.py", line 18, in <module>     Change(PD) #Call sub...change pounds to dollars echange rate   File "F:/USB/Computing/Programming/Python/test2.py", line 10, in Change     if ex == PD: #check what exchange rate to change (needed because final version will have alot more options UnboundLocalError: local variable 'PD' referenced before assignment   I have searched around but no answer has been very helpful if you could try and keep any explanations as simple as possible and provide an example of where Im going wrong and what i should be doing that would be greatly appreciated.


I'm trying to have some clickable footnotes within tables. I tried using \footnote{}, it does create a link but there's no footnote text associated with it. \footnotemark[number] along with \footnotetext[]{} does create a fotenote but then there's no hyperlink. (I would like to make it clear that I'm trying to have footnotes at the bottom of the page and not footnotes within the table.)  Here's a small code snippet:  \documentclass{report}  \usepackage{hyperref} \begin{document}  \begin{table}[h!]     \centering     \begin{tabular}{|r|r|r|}         \hline         A\footnote{Test!} & B\footnotemark[4] & C\footnotemark[5]\\         \hline         123 & Tim & Jane\\         \hline         456 & Tom & Jung\\         \hline     \end{tabular}     \caption{A table} \end{table}  This is a clickable footnote\footnote{You clicked me!}.  \footnotetext[4]{This is B} \footnotetext[5]{This is C}  \end{document}


C++ very small floating point number, preciscion


Show that $\|.\|_{1/2}$ is not a norm. would anybody guide me that how can i prove or disprove?  thanks


Sections without chapters in a LaTeX document

I have a document generated by doxygen with just \section directives and no chapters, so they're getting numbered as  0.1 Section 1 0.2 Section 2 0.2.1 SubSection 1   How can I skip the chapter number and display 1.1, 1.2, instead?


Problem with finding the GCD in the Field of Polynomials mod p

I am really having trouble working a problem in my course. I will post it and then add what I have thought etc.  Let p be an odd prime, then using the Euclidian Algorithm, calculated the GCD of of $x^{p-1}-1$ and $x^2+1$ in $\mathbb{Z} / p\mathbb{Z}[x]$  Also, how does $p=1 (mod4)$ tell us that  $-1$ is a square in $\mathbb{Z} / p\mathbb{Z}$, infact that $-1$ is a square here if and only if $p=1(mod4)$.  My thoughts:   I know that $$x^{p}-x=(x)(x-1)(x-2)…(x-(p-1))$$ and so that in this sense our roots will be the congruence classes of $1,2,…p-1$  and also that $$x^{p-1}-1=(x-1)(x-2)…(x-(p-1))$$  But I get lost when trying to apply the EA to these polynomials,  like how can I do it when p is arbitrary?  Preferably id like to be able to understand/see how to do the first part first i.e. using division with residue and then move on to the second part. Any insight/hint or solution to this would be great,  Thank you all  Update:  When I try to do division with residue, I just get  $$x^{p-1}-1=(x^2+1)(x^{p-3}-x^{p-5}+x^{p-7}-x^{p-9}...)$$  for example,  $p=7$  $$(x^{6}-1)=(x^2+1)(x^4-x^2+1)$$  for $p=11$  $$(x^{10}-1)=(x^2+1)(x^{8}-x^{6}+x^{4}-x^{2}+1)$$  which for specific cases tells me that 1 is the gcd, but I dont know how to generalize that for the case with arbitrary prime p.


I am writing a server, and I send each action of into a separate thread when the request is received. I do this because almost every request makes a database query. I am using a threadpool library to cut down on construction/destruction of threads. My question is: what is a good cutoff point for I/O threads like these? I know it would just be a rough estimate, but are we talking hundreds? Thousands? How would I go about figuring out what this cutoff would be?  EDIT: Thank you all for your responses, it seems like I am just going to have to test it to find out my thread count ceiling. The question is though: how do I know I've hit that ceiling? What exactly should I measure?


How do you calculate this limit $\lim_{n\to\infty}\sum_{k=1}^{n} \frac{k}{n^2+k^2}$?

How to find the value of $\lim_{n\to\infty}S(n)$, where $S(n)$ is given by $$S(n)=\displaystyle\sum_{k=1}^{n} \dfrac{k}{n^2+k^2}$$   is unable to calculate it.  This is a question from a questions booklet, and the options for the answer are--  $\begin{align} &A) \dfrac{\pi}{2} \\ &B) \log 2 \\ &C) \dfrac{\pi}{4} \\ &D) \dfrac{1}{2} \log 2 \end{align}$


Happy Father's Day to all you Fathers!!! well, I am trying access my old gmail account; i've read all the typical answers that lead me to the same head banging conclusion.  I dont quite remember my password (well, some of it I do...) but I no longer have the phone it was linked to, and all attempts at recovery keep going back to that phone number, or other places I've signed into. Well, there is no other place where i've signed in, & no hope of re-activating the old phone #.  Is there a way to be able to reset the password, or update phone info? Any help would be greatly appreciated!


How to Redirect Pages with Query String?

I want to Redirect as seen below:  https://example.com/p1/p2?sort=p.model&order=ASC&page=2   to  https://example.com/p3/p4?sort=p.model&order=ASC&page=2   Also, I have this code in my .htaccess file :  RedirectMatch 410 ^/p1/p2&   I have used below code, but I just see 410 code for that URL :  RewriteRule ^/p1/p2?sort=p.model&order=ASC&page=2$ /p3/p4?sort=p.model&order=ASC&page=2 [QSD, R=301,L]   So, I have changed RedirectMatch 410 ^/p1/p2& to Redirect 410 ^/p1/p2& , but this time I have seen 404 Code for my Request URI. What should I do?


Writing a Batch File to delete all files

Can somebody tell me how I write a batch file that I can attach to a scheduled task that will delete IIS logs that are older than 2 weeks.


Windows updates and driver search consume massive amounts of RAM.

I have noticed on several Windows 7 machines that Windows updates and Windows driver search can cause svchost.exe to consume excessive amount of RAM.  In the case of Windows updates, it seems that all the updates get downloaded to RAM, cached, and then you experience the joy of installing them while the machine is operational, and again at reboot.  I have these machines set to never download, update, or notify the user of updates, because svchost.exe, TrustedInstaller.exe, and wau...exe all go haywire under any other setting.  svchost.exe will still consume the massive amounts of RAM under any of other the options for Windows updates.  Therefore, I now manually check and install updates once a week.  in the case of Windows driver search, when you plug in a new device, Windows will consume an excessive amount of RAM while it's probing, analyzing, and downloading a driver for the device.  The most prominent example is when I attempted to connect a 3TB drive to a machine.  My laptop was not able to connect to the device.  It was a Core i7 with 4GB of RAM.  I plugged the drive into a desktop with 16GB of RAM.  I don't recall if this machine had crazy RAM usage trying to cess out the drive.  However, the laptop got an upgrade to 12GB of RAM, so I connected the drive to it.  RAM usage for svchost spiked to 3GB.  I've seen similar, but not as extreme, behavior almost any time I plug in a new device.  These machines are all Core i7s of some variety with 12GB of RAM and up.  Not light specs, though maybe that's only average for 2015?  I have researched this phenomenon before, and while I have found many people asking similar questions, I have not found solutions to the problem.  Is there a way to mitigate this behavior?  Relevant links:


How do I explicitly save changes when running Kubuntu 17.04 from a live USB?

I am running Kubuntu 17.04 from a USB drive. Since I don't have a PC of my own, I was wondering how can I save changes that I make in my live session, since starting from scratch is starting to get really annoying each time I run on a different PC. Thanks for your help.