I need help proving the following statement: There are $n$ gas stations along a circular road. The total amount of fuel at these stations is exactly the amount needed for a car to complete one loop. Show that there is a point on the road from where the car with initially empty fuel tank can complete a loop. Here is my progress: Note that a successful starting point must always be at one of the gas stations since; otherwise, the car will not be able to move due to the empty fuel tank. Before tackling the proof, consider the following example with four gas stations. Label the gas stations $g_1, g_2, g_3, g_4$ so that the amount of fuel at gas station $g_i$ is $x_i$ for $1 \leq i \leq 4$. Define the distance between consecutive gas stations to be $d(g_i, g_{i+1})$. Then $x_1 + x_2 + x_3 + x_4 = 1$ and $d(g_1, g_{2}) + d(g_2, g_{3}) + d(g_3, g_4) + d(g_4, g_1) = 1$. We want to make $d(g_i, g_{i+1})$ and $x_1, ..., x_4$ arbitrary so; for example, consider $x_1 =0.2,x_2 = 0.3 ,x_3 = 0.4, x_4= 0.1$ and $d(g_1, g_{2}) = 0.3 , d(g_2, g_{3}) = 0.1 , d(g_3, g_4)= 0.2, d(g_4, g_1) = 0.4$. We want to find a starting gas station so that we can get back to it. If the starting point is at $g_2$ and fill the car with fuel, call it $X$, we have $X=0.3$. We can then travel to the next gas station $g_3$ but will be left with $X = 0.3 - d(g_2, g_{3}) = 0.2$. After fueling at $g_3$, $X = 0.7$ and traveling to $g_4$ we have $X= 0.7 - d(g_3, g_4) = 0.5$. After fueling at $g_4$, $X = 0.6$ and traveling to $g_1$ we have $X= 0.6 - d(g_4, g_1) = 0.2$. Therefore, we have completed a loop so at least one starting point exists and that is at $g_2$. claim: If $\sum_{i =1}^k x_i = 1$ and $\sum_{i=1}^k d(g_i, g_{i+1}) = 1$ then there exists an $x_i$ where $i = 1, ..., k$ such that $x_i \geq d(g_i, g_{i+1})$. proof of claim: By way of contradiction suppose $x_i < d(g_i, g_{i+1})$ for some $1 \leq i \leq k$. Then, $\sum_{i=1}^k d(g_i, g_{i+1}) = 1$ implies $\sum_{i = 1}^k x_i < 1$ which is a contradiction. proof of problem: We induct on the number of gas stations. Suppose there is only one gas station along the circular road such that the total amount of fuel at this station is exactly the amount needed for a car to complete one loop. Therefore, there is only one possible starting point for the car which is at the single gas station. Now, suppose there is always a successful starting point when there are $k$ gas stations. That is, for gas stations $g_1, ..., g_k$ with fuel amounts of $x_1, ..., x_k$, respectively, such that $d(g_1, g_2) + ...+ d(g_k, g_1) = 1$ and $x_1 + ... + x_k = 1$. The total amount of fuel at the $k$ stations is exactly the amount needed for a car to complete one loop. We want to show that there is always a successful starting point when there are $k+1$ gas stations so consider a gas station with $k+1$ gas stations. By the claim above, there is at least one gas station that contains enough gas to reach the next gas station, call this gas station $h_1$ and consider the gas station that comes after $h_1$; call it, $h_2$. I am not sure where to go from here. An idea: Combining the fuel from $h_1$, $h_2$ and proceeding up to $h_k$, we have enough fuel for a car with an initial empty fuel tank to make a loop so that a starting point exists, namely at $h_1$. But how do we know that the fuel from $h_2$ will get us to the next gas station?

The exact quantity of gas needed for a car to complete a single loop around a track is distrubuted among $n$ containers placed along the track. Show that there exists a point from which the car can start with an empty tank and complete the loop by collecting gas from tanks it encounters along the way. Assume that there is no limit to the amount of gas the car can carry.  Here is what I did:  Let the track have length $1$. Let $a_1,a_2,\dots a_n$ denote how much gas each of the $n$ gas containers distributed along the track in that order, clockwise. Note that $\sum_{i=1}^n a_i=1$. Let $d_1,d_2,\dots d_n$ denote the distance between containers $a_1,a_2$, containers $a_2,a_3$, $\dots$ and containers $a_n,a_1$, respectively (i.e. $d_i$ denotes the distance between the gas tanks $a_i$ and $a_{i+1}$, in the clockwise direction). Note that we also have $\sum_{i=1}^n d_i=1$. Now let $A_{k,j}=\sum_{i=j}^{j+k-1} a_i, D_{k,j}=\sum_{i=j}^{j+k-1} d_i$, where indices are taken mod $n$.  We would be done if we could show that there exists a $j$ such that the sequence $a_j,a_{j+1},\dots a_n, a_1, \dots a_{j-1}$ majorizes the sequence $d_j,d_{j+1},\dots d_n, d_1, \dots d_{j-1}$ (i.e. $A_{k,j}\geq D_{k,j}$ for all $1\leq k\leq n$). But I'm not sure how to show this. Also, I'm not even sure that this is true, since after you pick the $a_j$ you start with, you still need to pick which direction (clockwise or counterclockwise) around the circle.  Does anyone have any ideas on how to do this (or the problem in general?)


When a question is put "on hold", I verified three or four times (when my answer was ready), most of the "close" voters seem to be rather older programmers. It's not that I'm interested, but I can see their names and I have already lost time with the answer. Is this a fact? Is up there a council of the elders?

Questions can be closed or marked as duplicates.  What does it mean for a question to be "closed"? What does it mean for a question to be marked as a "duplicate"? Who can close a question? What are the reasons for closing a question ? Is closure the end of the road for a question? When are closed questions eligible for deletion?   Related        For more information, see "" in the .


I will be on leave starting on October 4th till October 5th   I will be on leave on October 4th and 5th     I am on leave from October 4th till October 5th

Which one is grammatically correct?   I worked at X company ...   from Aug 2005 to Sep 2007. from A up to B. from A until B. from A till B. between A and B.


I want to create a very simple stored procedure that will only take several IN parameters and insert them into a table. To learn how to do it, I went to  From that I gathered that the procedure below should work, but it does not: CREATE PROCEDURE A (IN B INT) LANGUAGE SQL BEGIN   INSERT INTO TA(A) VALUES(B); END  The error is: An unexpected token "END-OF-STATEMENT" was found following "INTO TA(A) VALUES(B)".  Expected tokens may include:  "<psm_semicolon>".. SQLCODE=-104, SQLSTATE=42601, DRIVER=4.19.80 SQL Code: -104, SQL State: 42601 Error occurred in: CREATE PROCEDURE A (IN B INT) LANGUAGE SQL BEGIN INSERT INTO TA(A) VALUES(B)  When I copied the source code above from SquirrelSQL and pasted it into a new query in IBM Data Studio, it indeed underscored the semicolon at the end of the INSERT statement and displayed the error: DB2 for Linux, UNIX, and Windows: ";" is invalid.  If I comment out the procedure body, it compiles fine, and I can call it successfully. I googled a lot but could not find any material difference between my code and the suggestions found, including here and on SO. Even when I took the sample procedure from the linked page, it did not compile. It throws the error: "MEDIANSALARY" is not valid in the context where it is used.. SQLCODE=-206, SQLSTATE=42703, DRIVER=4.19.80 SQL Code: -206, SQL State: 42703 Error occurred in: SET medianSalary = 0

What is wrong in the below trigger syntax, I am getting this error An unexpected token "INT" was found following " DECLARE NULL_ROW_ID".  Expected tokens may include:  "END-OF-STATEMENT".. SQLCODE=-104, SQLSTATE=42601, DRIVER=3.68.61  CREATE TABLE A (     A_ID INT NOT NUll,     A_CODE VARCHAR(100) NOT NULL,     PRIMARY KEY(A_ID) );  CREATE TABLE B (     B_ID INT NOT NUll,     B_CODE VARCHAR(100) NOT NULL,     A_ID INT,     PRIMARY KEY (B_ID),     FOREIGN KEY (A_ID) REFERENCES A (A_ID)  );  CREATE OR REPLACE TRIGGER B_TRIGGER AFTER UPDATE OF A_ID ON B REFERENCING NEW AS N OLD AS O FOR EACH ROW     WHEN (N.A_ID IS NULL)     BEGIN ATOMIC         DECLARE NULL_ROW_ID INT;         SET NULL_ROW_ID = (SELECT A_ID FROM A WHERE A_CODE = 'Custom Null String');         IF NULL_ROW_ID IS NULL THEN             SIGNAL SQLSTATE '70000' SET MESSAGE_TEXT = 'Custom Null String row not found.';         END IF;     SET N.A_ID = NULL_ROW_ID;     END @   It's on DB2 Express-C 10.5


Just started using Linux Ubuntu 14.04 and when i try to boot it, it gives me this error message. After error message it boots successfully.   The point is, i had this "ath9k.conf" file in directory but i deleted it. Thought that its going to stop giving this error (beginner, sorry), but its not. The error is still here.  I created this ath9k.conf file few days ago because my notebook have a wifi button problem so i found solution to create it and add few lines in it. It didn't help and i forgot to delete it. I successfully fixed that problem by binding my WiFi toggle to another key (instead of Fn+F2, just on F2) because almost every Asus notebook has that problem.  What should i do? That error is just annoying.    If you need more information, let me know.  I'm running Asus X552V.

Alright Ubuntu wizards, I jacked up my system a bit unnecessarily, which is now giving me the chance to learn more about how to fix it...a vicious cycle. Anyway, I have it mostly up and running again to my liking, though I am receiving this (photo attached) prompt when my system boots:  libkmod: ERROR ../libkmod/libkmod-config.c:686 kmod_config_parse: /etc/modprobe.d/blacklist.conf line 56: ignoring bad line starting with 'rt2800usb'   Other users had success with just deleting the bad line from their blacklist.conf file, which I have done. Line 56 no longer exists, but I'm still receiving the same error. So am I missing something? Is there some follow-up command I need to give Ubuntu after saving the conf file?


I have a cloned a customer machine to a Virtual machine. I had access from my code (SqlConnection) to the database through a database-Login where I could use window autentication.   I disabled my Login(I though I could enable it again).  Is there any way to enable the Login?   The solutions I found where you Grant something, all require that you are connected to the instance, but it's also not possible to connect without first a login.  If I had the sa pwd I would be able to login, but I don't know that either.   Is there any other way, I can enable my Login?

I lost the sa password on a machine, and when I log in to the machine directly using an account in the admin group, SQL Server Management Studio will not allow me to log in using Windows authentication.  My plan was to simply log into the server, connect via Windows Authentication, and reset sa to use a new password. Since I cant' connect via Windows Authentication, this won't work.  How else can I reset the sa password?


Hello i'm writing a simple username/password input from the user, but my code is bypassing all the if/ if else statements and going to the else statement. I'm not sure if my syntax is incorrect or whether using an if/else statement is incorrect. Or if I just coded wrong. Please help!  import java.util.Scanner;  public class Passwords {     public static void main (String[] args)     {         Scanner input = new Scanner(System.in);         String[] username = {"admin1", "admin2", "admin3", "admin4", "admin5"};         String[] password = {"pass1", "pass2", "pass3", "pass4", "pass5"};         System.out.println("Please enter in one of the following usernames : admin1, admin2, admin3, admin4, or admin5");         String userinput = input.nextLine();         System.out.println("Please enter in the password corresponding to your username: pass1, pass2, pass3, pass4, or pass5");         String passinput = input.nextLine();         if (userinput == username[0] && passinput == password[0])         {             System.out.println("Access granted!");         }         else if (userinput == username[1] && passinput == password[1])         {             System.out.println("Access granted!");         }         else if (userinput == username[2] && passinput == password[2])         {             System.out.println("Access granted!");         }         else if (userinput == username[3] && passinput == password[3])         {             System.out.println("Access granted!");         }         else if (userinput == username[4] && passinput == password[4])         {             System.out.println("Access granted!");         }             else              {                 System.out.println("Sorry the username or password you entered is incorrect. Please try again");                 System.out.println("Please enter in one of the following usernames : admin1, admin2, admin3, admin4, or admin5");                 String userinput1 = input.next();                 System.out.println("Please enter in the password corresponding to your username: pass1, pass2, pass3, pass4, or pass5");                 String passinput1 = input.next();                 if (userinput1 == username[0] && passinput1 == password[0])                 {                     System.out.println("Access granted!");                 }                 else if (userinput1 == username[1] && passinput1 == password[1])                 {                     System.out.println("Access granted!");                 }                 else if (userinput1 == username[2] && passinput1 == password[2])                 {                     System.out.println("Access granted!");                 }                 else if (userinput1 == username[3] && passinput1 == password[3])                 {                     System.out.println("Access granted!");                 }                    else if (userinput1 == username[4] && passinput1 == password[4])                 {                     System.out.println("Access granted!");                 }                 else                  {                     System.out.println("Sorry, your username/password does not match our database. Contact the administrator.");                 }             }         } }

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


How can I express a method (e.g. dir(os)) like a keyword (e.g. dir_ os)? Is it even possible?  The opposite is quite easy to achieve:  # `assert` expressed like a method def assert_(x): assert x assert_(1 == 1)

Can you add new statements (like print, raise, with) to Python's syntax?  Say, to allow..  mystatement "Something"   Or,  new_if True:     print "example"   Not so much if you should, but rather if it's possible (short of modifying the python interpreters code)


It seems awfully convenient that to be able to ask a clarification or an update, one should have already answered a bunch of unrelated questions. Assuming one answers 10 or 20 questions first, how does that make them any more worthy of commenting on another, unrelated, question? It stands to reason that people with too much time on their hand spending too much time here would have less knowledge about technical subjects, not more... You know, because experience. I tried dipping a toe in the Stack Exchange game today and all I see is a bunch of gatekeeping... You might argue that it helps keep the community "healthy" or whatever excuse. But the results speak for themselves; some questions here will stay unanswered, uncommented forever. Wouldn't being more welcoming to new commenters be more productive? This kind of universal approach to reputation only encourages answering easy questions, and penalizes highly technical questions that will not get many answers or many upvotes. None of this makes sense for a very old and widely known website, which should have matured into being efficient by now... Unless this limitation is actually there to force newcomers to answers questions as a way of gaining enough reputation to do what they actually intended to do in the first place. It seems like I need to clarify that to answer my question, a previously posted question would need to address the obvious benefits of the comment limit, with regards to forcing users to provide engagement to this website.

Users with less than 50 reputation points cannot write comments on questions and answers that they don't own.  Why does this limit exist? But I want to contribute now. What should I do instead? But I can't write a good answer without more information! Shouldn't I be allowed to post comments if I have reputation on a different site? But I saw a new user posting a comment! How did they do it? Why do I need 50 reputation to comment on my own post?   See also:    in the Help Center


The salutation "hi, Joe," often does not have a comma after "hi." "Hi" is not a modifier like "dear." It is not part of a person's title. "Hi" is an interjection and is normally set off with commas. If one would put a comma after "good morning" in "good morning, Joe," then why is the comma after "hi" omitted so often? Is it proper to omit this comma?

Sometimes I see a comma after the proper name:     Hello Mr. Black,      In order to give you....   But my native language is not English and I think that the comma in this phrase should be placed before the proper name:      Hello, Mr. Black.      In order to give you....   What is the correct punctuation in English?


Let $G$ be a group and $g_{1},g_{2} \in G$, then if  $g_{1}g_{2}$ has finite order then we have to prove that $g_{2}g_{1}$ also has finite order too.  I have proved like this-   If $g_{1}g_{2}$ has finite order that means there exists positive integer $n$ such that $(g_{1}g_{2})^n = e$, now we rewrite the equation in a clever way.  $(g_{1}g_{2})^n = e$  $(g_{1}g_{2})(g_{1}g_{2})(g_{1}g_{2})...(g_{1}g_{2})= e$  $g_{1}(g_{2}g_{1})^{n-1} g_{2} = e$  $(g_{2}g_{1})^{n-1} = g_{1}^{-1}g_{2}^{-1}$  Multiplying $g_{2}g_{1}$ on both sides from the left hand side, we get -   $(g_{2}g_{1})^n = g_{2}g_{1}g_{1}^{-1}g_{2}^{-1} = e$  Implying that the element $g_{2}g_{1}$ has finite order too.  Now I am thinking of another approach, that is through homomorphism -   That is can we find a homomorphism between the two  -  Say $\phi$, that is $\phi(g_{1}g_{2}) = g_{2}g_{1}$, which would mean that $\phi(g_{1}) \phi(g_{2}) = g_{2} g_{1}$.  Any candidate for $\phi$, as if I can find a homomorphism then the order of both the elements will be same.

Attempted proof based on  and .  Given: $a,b$ elements of $G$, and $ab$ has finite order $n$.   Hence $\color{magenta}{|ab| = n} \iff (ab)^n = e$.   I must prove that $n$ is the smallest positive integer        such that $(ba)^n = e.$ Notice:  $\begin{align}(\color{darkorange}{a}\color{darkcyan}{b})^n &= e \implies \color{darkorange}{a}\color{darkcyan}{b}(ab)^{n-1} = e \implies  \color{darkcyan}{b}(ab)^{n-1}\color{darkorange}{a} = e \implies (ba)^n = e \end{align} $ $\implies |ba| \le n$.  Now I must prove that there's no positive integer $m$ such that $m<n$ and $(ba)^m = e.$ For a proof by contradiction, suppose $|ba|<\color{magenta}{n}$. Then we could apply the same reasoning to find that $ |ab| ≤ |ba| < \color{magenta}{|ab|}$,  which is absurd. So $|ba| = |ab| = n. \quad \blacksquare$  Questions   Whence does $ |ab| ≤ |ba| $ arise, in the second last line?   What's the intuition of the claim proved?    How do you prognosticate that $|ba|<\color{magenta}{n}$ is impossible, and that you should prove it by contradiction?


When the Rings of Power were being handed out, the only races that were given magic rings were the Men, Elves and Dwarves.     It began with the forging of the Great Rings. Three were given to the Elves, immortal, wisest...fairest of all beings. Seven to the Dwarf Lords, great miners and craftsmen of the mountain halls. And Nine...nine rings were gifted to the race of Men who, above all else, desire power.   So why didn't Hobbits receive any Rings?

Simple: every other race in Middle Earth has rings, why do Hobbits and Orcs not?


My spouse is a teacher in NJ. He is 61 years old. We file federal income taxes as married filing jointly. His w-2 shows, in box 14 (other) a pension plan with code 414(h). It shows an amount of just over $6,000. We want to get a tax benefit for the year 2014 by starting two individual IRAs at the bank, one each, for the maximum allowed. I will start one for $6,500, according to how I understand the limits (I am 60 years of age. We are confused about what my husband is permitted to do because different people have told us differently, and going to the IRS site is very hard to understand. My husband asked the person at the school who is the resource for tax questions, and was told he could still do an individual Ira for the maximum amount. However a friend who also assists me doing my tax return, said that as long as box 13 (pension) is checked off, that he cannot. What is correct?

My husband is a teacher in New Jersey; 61 years of age. He has a pension plan listed on w-2 in box 14 (other). It is coded as 414(h). He asked the tax advise person at the school if he could still contribute maximum yearly amount to an individual Ira and was told yes. An accountant we know told us this was incorrect. Can he deduct the amount placed in individual Ira?


I'm casting methods into a delegate event.   TriggerPressed += new InteractionEventHandler(DetectManipulation);   When I try to remove some of the methods however, it seems like it doesn't always remove properly.  TriggerPressed -= DetectManipulation;   The event still gets triggered even with the method supposedly disassociated.  I'd like to be able to somehow print out the list of methods under a given delegate. Is there some way I can do this? Or am I not understanding something?  Thank you.

I need to copy the subscribers of one event to another event. Can I get the subscribers of an event (like MyEvent[0] returning a delegate)?  If this is not possible I would use the add accessor to add the delegates to a list. Would that be the best solution?


Any idea about gettin the real encoding of a file like .html .txt .java and etc in java?  Since some source codes are not utf-8,I wantto  change them to utf-8.

With reference to the following thread:   What is the best way to programatically determine the correct charset encoding of an inputstream/file ?  I have tried using the following:  File in =  new File(args[0]); InputStreamReader r = new InputStreamReader(new FileInputStream(in)); System.out.println(r.getEncoding());   But on a file which I know to be encoded with ISO8859_1 the above code yields ASCII, which is not correct, and does not allow me to correctly render the content of the file back to the console.


When I use the lstlisting environment from the listings package, there is a bit of extra space between characters, even in a monospaced font.  For code, I use a monospaced font (basicstyle=\ttfamily), and I want to obtain the same horizontal spacing as in an ordinary verbatim environment.  For algorithms, I use a variable-width font, and I want to have the same horizontal spacing as in ordinary text.  MWE illustrating a code snippet in a monospaced font (I see the same output for the lstlistings blocks if I don't include the alltt package):  \documentclass{minimal} \usepackage{alltt} \usepackage{listings}  \begin{document} \setlength{\parindent}{0pt}  What I want to typeset: \begin{alltt} \textbf{int} hello_world = 3;      \textit{/* alltt */} \end{alltt} \vspace{1em}  What I want to type: \begin{lstlisting}[basicstyle=\ttfamily,language=C] int hello_world = 3;      /* lstlisting (ttfamily, C) */ \end{lstlisting} \vspace{1em}  Default listing, for reference: \begin{lstlisting} int hello_world = 3;      /* lstlisting (default) */ \end{lstlisting}  \end{document}     How do I obtain the desired character spacing?

I want to write shell Code in my LaTeX document. I'm using the listings package, with a code sample adapted from :  \documentclass{report}  \usepackage{color} \usepackage{xcolor} \usepackage{listings}  \usepackage{caption} \DeclareCaptionFont{white}{\color{white}} \DeclareCaptionFormat{listing}{\colorbox{gray}{\parbox{\textwidth}{#1#2#3}}} \captionsetup[lstlisting]{format=listing,labelfont=white,textfont=white}  % This concludes the preamble  \begin{document}  \begin{lstlisting}[label=some-code,caption=Some Code]    NETWORKING=YES  HOSTNAME= f e −19. l o c a l d o m a i n  } \end{lstlisting}  \end{document}   The problem is that there is some extra space between every character when I generate a PDF. I would like the code without this space. The extra space is visible in the the part HOSTNAME=.


This is a 3D view of a 2m x 2m x 2m cube, created by scaling up a standard cube from the grid center. The grey plane are the gridlines. It looks as if the 3D View camera can't pull backward enough. What's wrong?

I'm having an odd issue - When I try to zoom in on a detail using my MMB, the "camera" in the 3D view seems to be cutting off the exterior surface of my object and showing me the inside instead. I'd expect this behavior, but only when I was much more zoomed in.  If I zoom out a bit (one click on the scroll wheel) then I can see the exterior as I intend.  Is there any way to adjust this behavior?  Thanks!


The Equation is   $$2\sqrt[3]{2x-1}=x^3+1$$  I divided by $2$ and then cubed both sides,   $$2x-1=\frac{x^9+3x^6+3x^3+1}{8}$$  Now, if I make the substitution $y=x^3$ the equation becomes more complicated.  I need help to proceed from here. Thanks

Solve the following equation over the reals:$$ x^3  + 1 = 2\sqrt[3]{{2x - 1}} $$ I noticed that 1 is a trivial solution, then I tried raising the equation to the 3rd, then dividing the polynomial by $(x-1)$.. But I can't see the solution, how do I go from here?


I deleted this file /etc/apt/apt.conf.d/20auto-upgrades. I thought it was a swap file. What should I do? Reinstalling the unattended-upgrades apt didn't work.  /usr/sbin/dpkg-reconfigure: unattended-upgrades is broken or not fully installed root@****:/var/log/unattended-upgrades#

I would like to restore LightDM to its default state, because for some reason /etc/lightdm/unity-greeter.conf is now an empty file.  Deleting /etc/lightdm/unity-greeter.conf and then running sudo apt-get install --reinstall unity-greeter doesn't create a new config file as you might expect.   How can I restore a missing config file?


I am trying to use multirow to use to rows for a heading but for some reason, the line is still remaining in the middle. Here's my LaTeX table: \begin{table} \centering \begin{tabular}{|c|c|c|c|c|} \hline \multicolumn{5}{|c|}{Manual vs old ICY}\\ \hline \multirow{ 2}{*}{Model}& \multicolumn{2}{|c|}{Senescent}&  \multicolumn{2}{|c|}{Young}\\ \hline &Raw Count  &\%\ day3/day0 &Raw Count  &\%\ day3/day0\\ \hline Manual vs old ICY&0.6482 &0.5074 &0.4397 &0.08118\\ \hline Manual vs new ICY&0.6482 &0.5074 &0.4397 &0.08118\\ \hline Manual vs VGG16&0.6482 &0.5074 &0.4397 &0.08118\\ \hline \end{tabular} \label{ManualvsoldICY} \end{table}

In a table, how can I draw a horizontal line that goes only through some of the cells? I mean a line like the one in the Foo and in the Bar area of this table:  +----+-----+ |Foo |1 |2 | |    |1 |2 | |    +--+--+ |    |1 |2 | |    |1 |2 | +----+-----+ |Bar |1 |2 | |    |1 |2 | |    +--+--+ |    |1 |2 | |    |1 |2 | +----+--+--+


Tried to boot live USB with Ubuntu 14.04.1 LTS. After selecting boot from USB and selecting Install Ubuntu it then goes back to the motherboard splash screen. Pressing F12 to select boot menu and doing it again will just repeat the process. The machine already has Windows 8.1 on it and has a Gigabyte Z77-D3H motherboard. Thanks.

I'm absolutely new to Linux. I would like to know how to install Ubuntu alongside the pre-installed Windows 8+ OS.  Should I do it with Wubi, or through the Live USB/DVD?  What steps do I need to take to correctly install Ubuntu?


How to open pdf or any other files (I mean that word, excel, etc) in Mobaxterm? I have tried to open it through cd and vi, but I was not able to access it. Could anyone help me out with this?  Thank you

I want to open pdf files from within the virtual console and view them in the console itself. Are there any applications that allow that ?


I've taken apart my pocket calculator, and I'd like to know what IC is inside the black blob. Is there an IC commonly used in such applications?

In low-cost mass-produced items I often run into black blobs of what looks like resin applied directly on top of something on the PCB. What are these things exactly? I suspect this is some kind of custom IC that is layed out directly on the PCB to save on the plastic  housing/connector pins. Is this correct? If so, what is this technique called?    This is a photograph of the inside of a cheap digital multimeter. The black blob is the only non-basic piece of circuitry present, along with an op-amp (top) and a single bipolar junction transistor.


How do I save the output of a command to a file?  Is there a way without using any software? I would like to know how.

I want to write batch or something, that will write output of top into a file on login.  I did top >> output-file, but it contains some strange character!  Can somebody give a simple tutorial about how to write batch file in Linux?


Possible Duplicate:          I'm looking for good places to find illustrations (not photos). Any places online with free illustrations that you would recommend? I'm looking for "Caricatures", backgrounds, cartoonish.

Is there a free library of vector graphics for commercial use?


I'm stumped. When I do the following query exactly as shown, I get an error:      function update_rater($rater_result) {     $pdo = new PDO('mysql:host='.DB_SERVER.'; dbname='.DB_NAME, DB_USER, DB_PASS);     $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);     $pdo->exec('SET NAMES "utf8"');      foreach ($rater_result as $update)     {         $sample[] = array (                 'name'=>$rater_result['name'],                 'rating'=>$rater_result['rating'],                 'hits'=>$rater_result['hits'],                 'parkid'=>$rater_result['parkid'],                 'logname'=>$rater_result['logname'],                 'uname' =>$rater_result['uname']);     }     $id = $update['parkid'];         $parkid = $update['parkid'];         $rating = $update['rating'];         $hits = 1;         $uname = $update['uname'];      $sql = "INSERT INTO stars (parkid, rating, hits, logname)         VALUES ($parkid, $rating, $hits, $uname)";                    $result = $pdo->query($sql); }      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   MySQL server version for the right syntax to use near ')' at line 2'   in /home/ride4w5/public_html/test_site/includes/functions.php:343   Stack trace: #0   /home/ride4w5/public_html/test_site/includes/functions.php(343):   PDO->query('INSERT INTO sta...') #1   /home/ride4w5/public_html/test_site/includes/rater/1.php(62):   update_rater(Array) #2 {main} thrown in   /home/ride4w5/public_html/test_site/includes/functions.php on line 343   However, if I do EXACTLY the same query, but change the final VALUE to either a string or a number, it works just fine. Any variable throws the error. Why is the error being thrown only for a variable and not for a value? The other variables don't cause any problem.  EDIT:   It is not ANY variable, it is just $uname that causes the problem. But if I do an   echo $uname;  exit();    it echos the variable properly. What does it not like?   Edit:  $uname comes from   $user->session_begin();  $auth->acl($user->data);  $user->setup();  $request->enable_super_globals();  $username = $user->data['username'];  $uname = $username;

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


I have a Schengen Visa issued by the Poland embassy for 20 days category C and single entry.  I have hotel reservation from 25 to 01 for this event in Poland and I have my friend in the Netherlands who can accommodate me; so I want to ask can I take my first fight to the Netherlands rather than Poland?

In case, if I get a multiple-entry Schengen visa in one of the embassies in Ukraine, Kyiv - should my first trip be to the country which issued the visa?  Any there any requirements of this sort? Does this condition vary depending on embassy which issued the visa?  What are the possible consequences on not visiting that country first? Does it somehow depend on country where the embassy is (i.e. non-Schengen and not EU members)?


This regular expression does exactly what I want, except it produces lots of undefined entries. Is there a way to fix it so that it does not generate undefined entries?   var s = "on 2020-1-22 radio station 7-1207 was at -27db"; var regex = /(?<![a-zA-Z0-9+-])([+-][0-9]+[.]?[0-9]*)|([0-9]+[.]?[0-9]*)/; var m = s.split(regex); console.log(m);    output: ["on ",undefined,"2020","-",undefined,"1","-",undefined,"22"," radio station ",undefined,"7","-",undefined,"1207"," was at ","-27",undefined,"db"] desired output: ["on ","2020","-","1","-","22"," radio station ","7","-","1207"," was at ","-27","db"]

How do I remove empty elements from an array in JavaScript?   Is there a straightforward way, or do I need to loop through it and remove them manually?


Can any lens be used along with an adapter to shoot macro using Canon EOS M100 ? Please guide me regarding this.

I am a photography newbie and have only a 18 - 135mm canon kit lens at my disposal. I wanted to take macro shots but can't really afford a macro lens right now. One very optimistic goal of mine is to capture a single snow flake this winter.   Is there any cheap(er) way to take macro shots? Also, any specific advice from anyone one how to go about photographing a single snow flake.


I have given the same font size(2em) to all divs. But the font size in #left and #right is obviously bigger. I have no idea why the browser gives this result.  Here's a code snippet:    div {   color: white;   font-size: 2em; }  #header {   width: 100%;   height: 120px;   background: #99ff00; }  #main {   width: 100%;   height: 400px;   background: #99ff99; }  #left {   width: 30%;   height: 100%;   float: left;   background: #999999; }  #right {   width: 70%;   height: 100%;   float: left;   background: #553344; }  #footer {   clear: both;   width: 100%;   height: 80px;   background: #66ff66; }
header

left

right

footer

I heard you should define sizes and distances in your stylesheet with em instead of in pixels. So the question is why should I use em instead of px when defining styles in css? Is there a good example that illustrates this?


Am studying in 8th grade and I studied electrostatic force which says opposite charge attracts and same charges repel  But in an atom electron is just situated above the proton and it doesn't attracts.Why?

I'm having trouble understanding the simple "planetary" model of the atom that I'm being taught in my basic chemistry course.   In particular,    I can't see how a negatively charged electron can stay in "orbit" around a positively charged nucleus. Even if the electron actually orbits the nucleus, wouldn't that orbit eventually decay?  I can't reconcile the rapidly moving electrons required by the planetary model with the way atoms are described as forming bonds. If electrons are zooming around in orbits, how do they suddenly "stop" to form bonds.     I understand that certain aspects of quantum mechanics  to address these problems, and that there are  of atoms. My question here is whether the planetary model itself addresses these concerns in some way (that I'm missing) and whether I'm right to be uncomfortable with it.


When landing at night on most planes they say that due to safety regulations the lights will be dimmed and if you want to continue reading you can use your overhead lamp(it could be that this only happens in Europe I am not sure). I wonder what is the reason for this? What safety does dimming the lights add?

I wondered for a long time why the light inside an aircraft is always turned off when taking off or landing.


Im trying to add validation on my textbox in my code by using if else condition Ive added focusListener on the textbox that will check the condition  when I remove the focus from textbox Ive also created a label beside the chekbox which will display text according to the condition If the text inside the textbox is not equal to "hi" then it should print "hello" in the label beside textbox otherwise it should print "bye" import java.awt.*;   import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.FocusAdapter; import java.awt.event.FocusEvent; import javax.swing.*;  public class regframe extends JFrame implements ActionListener {          private static final long serialVersionUID = 1L;     JTextField t1,t2;     JLabel l1,l2,l3,l4;     JButton b;      regframe()     {            getContentPane().setBackground(Color.BLACK);         l1=new JLabel("Enter First Num:");         l1.setBounds(50,50,150,20);         l1.setForeground(Color.WHITE);         l1.setFont(new Font("Verdana",Font.BOLD,12));         add(l1);          t1=new JTextField();         t1.setBounds(180,50,100,20);         t1.setBackground(Color.BLACK);         t1.setForeground(Color.WHITE);         t1.setBorder(BorderFactory.createMatteBorder(0, 0, 1, 0,Color.YELLOW));         t1.setCaretColor(Color.CYAN);         t1.setFont(new Font("Verdana",Font.BOLD,12));         t1.addActionListener(this);         add(t1);                  l3=new JLabel();         l3.setBounds(290,50,150,20);         l3.setForeground(Color.CYAN);         l3.setOpaque(false);         l3.setFont(new Font("Verdana",Font.BOLD,10));         add(l3);          t1.addFocusListener(new FocusAdapter()          {             public void focusLost(FocusEvent e)             {                 if(t1.getText()!="hi")                 {                     l3.setText("hello");                 }                 else                 {                     l3.setText("bye");                 }             }         });                   l2=new JLabel("Enter Second Num:");         l2.setBounds(50,80,150,20);         l2.setForeground(Color.WHITE);         l2.setFont(new Font("Verdana",Font.BOLD,12));         add(l2);                  t2=new JTextField();         t2.setBounds(180,80,100,20);         t2.setBackground(Color.BLACK);         t2.setForeground(Color.WHITE);         t2.setBorder(BorderFactory.createMatteBorder(0, 0, 1, 0,Color.YELLOW));         t2.setCaretColor(Color.CYAN);         t2.setFont(new Font("Verdana",Font.BOLD,12));         add(t2);                          b=new JButton("Submit");         b.setBounds(100,120,100,20);         b.setBackground(Color.CYAN);             b.setForeground(Color.BLACK);         add(b);          setLocation(300,200);         setSize(700,250);         setLayout(null);         setTitle("Registration");         setVisible(true);         setDefaultCloseOperation(EXIT_ON_CLOSE);              }          public static void main(String args[])     {         new regframe();     }      public void actionPerformed(ActionEvent arg0)      {                       } }  But when I run the code, It always display "hello" even when I write "hi" inside the textbox   Please Help

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


Is there a way to modify the lock screen to show a custom message and/or take a picture (/w the webcam) when incorrect password was typed in? (Like it was shown in the movie Goodbye World)  (And does anyone know where are the files used by the lockscreen? - I mean codes)

I am using a laptop . I was thinking to have a support in my Ubuntu machine.  When an incorrect password is entered, a picture is taken later revealing who has been trying to gain access.  I have searched around and the only thing I have found is stuff to do this on Macs. Is It possible to write a script for Ubuntu to do same .  If possible then what is a script or Software to make this happen.


Prove that every triangle-free graph is  $\lceil 2\sqrt{n}\rceil$ colorable

I'm struggling with the following question;     For every graph $G$ such that $K_3 \not\subseteq G$ (i.e. $G$ does not contain a triangle), prove that $\chi(G) \leq 2\sqrt{n} +1$ (where $\chi(G)$ denotes the chromatic number).   Any hints? I really cannot see the connection between the triangle-free nature of $G$ and a chromatic number being bounded above by $O(\sqrt{n})$.


I can think of at least two different ways to understand eigenfunctions of operators in quantum mechanics. But neither one seems to provide a good explanation for why we take the position-basis representation of $|y\rangle$, the eigenvector of the position operator $\hat{x}$ with eigenvalue $y$, to be the Dirac delta function $\delta (x-y)$:  Perspective 1: The eigenfunctions of position are those functions which satisfy the eigenvector equation $\hat{x}|\psi\rangle = y |\psi\rangle$, expressed in the position basis. So we have, upon multiplication by the bra $\langle x|$ to move to the position basis:  $$\langle x | \hat{x} | \psi \rangle = \langle x | y | \psi \rangle \tag{1}$$ $$x \psi (x) = y \psi (x)\tag{2}$$ $$(x-y) \psi(x) = 0\tag{3}$$  Here I have taken for granted that the action of the position operator in the position basis is to multiply functions by $x$. So this equation tells us that the eigenfunction $\psi(x) = \langle x |\psi \rangle$ must be zero everywhere except for $x=y$. But it doesn't seem to give us any information about the value of $\psi(x)$ at $x=y$.  Perspective 2: The eigenfunctions of position are the position-basis representations of those state vectors for which we can assign a definite value of position. That is, for systems described by such a state vector, an ideal position measurement could only ever result in one particular value $y$ of position, with probability 1. The probability density "function" that best describes this situation is $P(x)=\delta(x-y)$. But the probability density over the possible values of position upon measurement is given by $P(x) = |\langle x | \psi \rangle|^2=|\psi(x)|^2$. So we have, up to a phase factor, that $\psi(x)=\sqrt{\delta(x-y)}$, which isn't a meaningful mathematical expression as far as I can tell. Alternately, the eigenfunction can't be $\psi(x) = \delta(x-y)$ as we usually claim, because then $P(x) = \delta(x-y)^2$, which doesn't seem to have a rigorous mathematical meaning either.  Both of these routes seem to lead to a dead end. So my question is, how can we claim that the functions $\delta(x-y)$ are eigenfunctions of position? I think that an analogous question can be asked for any other observable that takes on a continuous range of values, such as momentum.

We know that the Dirac function $$\delta(a)=\lim_{a \rightarrow 0} \delta_{a}(x)$$ can be written as an infinitesimally narrow Gaussian: $$  \delta_{a}(x) := \frac{1}{\sqrt{2\pi a^2}}e^{-x^2/2a^2}$$  Our professor told us that for any value $a>0$, the physical position eigenfunction is $$\psi_{x_0}(x)\cong N_1\delta_a(x-x_0).$$  How can I show that $\psi_{x_0}$ is a physical position eigenfunction?


I don't have much knowledge about financial markets but I was wondering how banks offering credit cards make profit? One possible way is interests on late payments but let's say if most of the people who own credit cards pay on time, will these banks still make lots of money? Or is there any other financial instrument built on credit cards?

How do credit card companies make profit by giving us credit for 40-50 days (India). I purchase something on my credit card and I pay it to the credit card company after some days. How are they going to make profit with this where I'm not paying any service charge to them?  I'm asking this for couple of reasons.   I heard that credit card companies charge the merchant with some percentage of the bill amount. Is this true? If that is true then why cant we get that percentage directly from the merchant by paying cash. We can get this percentage by getting discount in bill. isn't it? If they get profit from late fees or interest charges if customer makes late payment or pays long after due date. If this is the way they get profit, is this big amount compared to what they offer in credit to the customer?   Please put some points from your side to make me aware of this system, so that I can get maximum from a credit card company.


If $I$ is an ideal in a ring $R$ such that $I$ is not finitely generated and every ideal properly containing $I$ is finitely generated, then $I$ is prime.   Let $I$ be a non-finitely generated ideal and let $a,b\in{R}$ such that $a,b\notin{I}$. Then $a\in{I'}$ such that $I'$ is finitely generated and $I'$ properly contains $I$; $b\in{I''}$ such that $I''$ is finitely generated and $I''$ properly contains $I$. I am having difficulties in showing that $ab\notin{I}$.   Would you help me, please? Thank you in advance.

I've been doing some old exam problems and I've come across a problem that I've answered, but my gut is telling me that there's something I'm glossing over.     Let $R$ be a commutative ring with identity and let $U$ be an ideal that is maximal among non-finitely generated ideals of $R$. I wish to show that $U$ is a prime ideal.   Assume that $U$ is not prime. Let $x, y\not\in U$ be such that $xy\in U$. $U$ is contained in a maximal ideal $M$ and $xy\in M$, so either $x$ or $y$ is in $M$; assume $x\in M$. The condition $U\subset M$ then implies that there is a ring homomorphism $$\varphi: R/M\to R/U$$  Since $R/M$ is a field, $\varphi$ is injective. Hence, $\varphi(x)\in U$. This is a contradiction, so $U$ must be prime.  The thing that worries me is that I never explicitly used the hypothesis that $U$ was not finitely generated or the result that $M$ must be finitely generated.


In Adobe Illustrator CS5:   I want a "depth effect" to an object with the straight-from-the-front perspective. But with the Free Transform-tool it seems to only be possible to drag one corner each time to the middle which makes it very hard to get it symmetrical.   Is there any way to get it symmetrical?    Edit:  I've tired to place a centred rectangle to have something to snap to. But it turns out that when I drag the other corner, the first corner then change position:

I have a flat object.    I want to fit it on a laptop screen.  I can't use the perspective grid because it only deals with a straight line axis and the screen doesn't have any edges on a straight line.  I can't find a way to rotate or skew the perspective grid.    If I skew the object it doesn't work as I need to make each corner skew independently.    In Photoshop I can use Transform > Perspective.  Does Illustrator CS5 have a similar function?  I want to put the recycling symbol on all three screens.  What's the easiest way?


Now, for every new application, even those free ones,I have to confirm for pay money. And then App Store asks to enter my credit card information. If I disagree and hit "Cancel", installation process is interrupted and I can't install any application, even free one.

I haven't been installing anything on my iPad Mini for the past few weeks. But previously, I just had to tap on "Install", enter my Apple ID password and go.  Now, for every new application, even those free ones, I have to confirm each time, that I'm 17 or over. And then App Store asks to enter my credit card information. If I disagree and hit "Cancel", installation process is interrupted and I can't install any application, even free one.  I don't trust Apple at all and I'm not willing to share my credit card information, especially that I'm installing only free applications.  I'm pretty sure that I haven't changed anything in the configuration of my iPad Mini for ages.   Am I missing some significant change to the App Store or this is some kind of bug or virus? Is there anything I can do in this situation? How can I install a free application from the App Store, without having to share my credit card information with Apple?


I'm having problems trying to find the pnp4nagios package. I don't know what to do.   apt-get install pnp4nagios -y

When I try to install any package through the command line, I get an error.   $ sudo apt-get install <package> Reading package lists... Done Building dependency tree        Reading state information... Done E: Unable to locate package <package>   Can anyone help me on this?


I have a several strings that I want to split by spaces when not inside parentheses.  For example  sentence = "blah (blah2 (blah3))|blah4 blah5"   should produce  ["blah", "(blah2 (blah3))|blah4", "blah5"]   I've tried:  re.split(r"\s+(?=[^()]*(?:\(|$))", sentence)   but it produces:  ['blah', '(blah2', '(blah3))|blah4', 'blah5']

I have a string which is like this:  this is "a test"   I'm trying to write something in Python to split it up by space while ignoring spaces within quotes. The result I'm looking for is:  ['this','is','a test']   PS. I know you are going to ask "what happens if there are quotes within the quotes, well, in my application, that will never happen.


If I am a Drunken Master Monk and I have one source each of both advantage and disadvantage, can I still use Drunkard's Luck to remove the disadvantage as per the class feature:       When you make an ability check, attack roll, or a saving throw and have disadvantage on the roll, you can spend 2 ki points to cancel the disadvantage for that roll. (XGtE 34)     and thereby have advantage? or am I not allowed to use Drunkard's Luck because the disadvantage is already cancelled out by the advantage per this rule:     If circumstances cause a roll to have both advantage and disadvantage, you are considered to have neither of them, and you roll one d20.

As I understand it:   if you have Advantage from two different sources, you simply have Advantage (no stacking) if you have advantage from one source, and disadvantage from one source, they cancel out.     So what if you have advantage from two or more sources, and disadvantage from one source?  My assumption is that you simply have advantage, or put another way, you have Advantage on a roll when the # of Advantages > # of Disadvantages (and vice versa).  Is that correct?


Prove that if $A,B$ are  similar matrices then they have same minimal polynomial.   My try:  We have $B=PAP^{-1}$ for some $P$.  Let the minimal polynomial of $A$ be $m_A(x)=a_0+a_1x+\ldots +a_nx^n$  and the minimal polynomial of $B$ be $m_B(x)=b_0+b_1x+\ldots +b_mx^m$.  Now, $m_B(B)=0\implies b_0I+b_1(PAP^{-1})+\ldots +b_m(PA^mP^{-1})=0\implies P(b_0I+b_1A+b_2A^2+\ldots b_mA^m)P^{-1}=0\implies b_0I+b_1A+b_2A^2+\ldots b_mA^m=0\implies m_B(A)=0$.  Hence $m_A(x)|m_B(x)$.  Also charcteristic polynomials of $A,B$ say $C_A(x),C_B(x)$are same.  Now $m_B(x)|C_B(x)=C_A(x)$.Also $m_A(x)$ is the smallest degree monic polynomial which divides $C_A(x)$.Also $m_B(x)|C_A(x)$.  Hence $m_B(x)=m_A(x)$  Please check whether the proof is correct or not.Really need some help.

I guess that I'm missing here something...  How to prove that, if two matrices are similar, then their minimal polynomials are the same one.   Thanks!


I have an install script to set up dependencies for a project, this means installing packages using pip and apt. My prefered method is to run the script as sudo ./install but then how do I drop sudo for pip (do I need to with --user)? #!/bin/sh  if [ $(id -u) -ne 0 ]; then     echo Please run as root     exit fi apt install pkg_a pkg_b pkg_c  # Is this fine? How do I drop sudo here? pip install --user pkg_d pkg_e pkg_f  The alternative is to have sudo in the script but I prefer the first option if it's possible #!/bin/sh  sudo apt install pkg_a pkg_b pkg_c pip install --user pkg_d pkg_e pkg_f

The "--up" option in OpenVPN is normally used for routing etc. And so it is processed before OpenVPN drops root privileges to run as nobody. However, I am invoking shell scripts that need to run as an unprivileged user.  How do I do that? I have studied , especially polynomial's and tylerl's answers, but I do not understand how to implement. I am working in Centos 6.5, and suid is blocked, both as "chmod u+s" and as "setuid()".  There is an OpenVPN plugin ("openvpn-down-root.so") which enables scripts invoked by the "--down" option to run as root. There could be an equivalent, such as "openvpn-up-user.so", but I have not found it.  Edit0  Per Nikola Kotur's answer, I've installed . Although the chpst command works in terminal, in the up script it fails with "command not found". What works is "sudo chpst" plus setting the proper display and language. Please see  Given that, the up script needs these four lines:  LANG="en_US.UTF-8"; export LANG GDM_LANG="en_US.UTF-8"; export GDM_LANG DISPLAY=:0; export DISPLAY sudo chpst -u user -U user /home/user/unprivileged.sh &   Edit1  Per 0xC0000022L's comment, I find that "sudo -u user" works as well as "sudo chpst -u user -U user":  LANG="en_US.UTF-8"; export LANG GDM_LANG="en_US.UTF-8"; export GDM_LANG DISPLAY=:0; export DISPLAY sudo -u user /home/user/unprivileged.sh &   I'll study man sudoers and update if/when I get sudo alone to work.


I have few files created with ArcGIS in .mxd format.  Now I dont have ArcGIS and want to work with QGIS along with these .mxd file formats.   How can I solve this problem (along with each step to be taken)?

I recently tried to use QGIS and I wondered if you can convert a draft ArcGIS map (*.mxd file) into a QGIS project (*.qgs file).   This would avoid thematize the entire project.


I always wonder why the words Put and Cut are pronounced differently.

"Put" and "but" both end in the same letters, so why don't they rhyme? Did they start out with the same sound, and then one of them changed? Or did they start out with different sounds, and just got spelled with the same letter because there weren't enough vowel letters to represent all of the vowel sounds in English?


This question is basically a spin off from my friend's question - "What are we basically seeing? Is it the atom or the nucleus?" (He had referred to the huge amount of empty space inside the atoms). I replied that it must be the electronic transitions between different orbitals. It gets energy from outside, it then goes in some orbit inside, but it is unstable there, so it releases energy and comes back to its original orbit. If the corresponding wavelength matches a particular colour, we detect it. (Typical explanation based on Bohr's model).  Now another question arises that what we must be touching (suppose if we touch the keyboard), because most of the space inside the atom is empty. The size of the nucleus is almost 100,000 times less than the atom. So are we touching the atoms or the nucleus? Or the lattice arrangement of atoms? What about liquids then?  Another thing I know is that frictional & other contact forces have electromagnetic origins but I don't know exactly how. Can someone please explain?

If you've ever been annoyingly poked by a geek, you might be familiar with the semi-nerdy obnoxious response of      "I'm not actually touching you! The electrons in the atoms of my   skin are just getting really close to yours!"   Expanding on this a little bit, it seems the obnoxious geek is right. After all, consider Zeno's paradox. Every time you try to touch two objects together, you have to get them halfway there, then quarter-way, etc. In other words, there's always a infinitesimal distance in between the two objects.   Atoms don't "touch" each other; even the protons and neutrons in the nucleus of an atom aren't "touching" each other.  So what does it mean for two objects to touch each other?   Are atoms that join to form a molecule "touching"? I suppose the atoms are touching, because their is some overlap, but the subatomic particles are just whizzing around avoiding each other. If this is the case, should "touching" just be defined relative to some context? I.e, if I touch your hand, our hands are touching, but unless you pick up some of my DNA, the molecules in our hands aren't touching? And since the molecules aren't changing, the atoms aren't touching either?  Is there really no such thing as "touching"?


consider that an attacker has the public key $(n, e)$, where $n$ is $1024$ bits long, the $32$ largest bits of $p$ (where $n = p \cdot q$), as well as $u = p^{-1} \pmod q$. Is there an attack that would allow this attacker to perform an attack on rsa and therefore be able to decrypt a message or retrieve the private key $(n, d)$?

Let $N=pq$ where $p$ and $q$ are safe primes. If the adversary knows the inverse of $p$ mod $q$ and the inverse of $q$ mod $p$, can this help him factor $N$ or break the textbook RSA?


So I am searching for a field $K$ with these properties:  $1.$ $K$ is infinite.   $2.$ $K$ is not algebraically closed.  $3.$ $K$ is algebraic over a finite field.   I do not think the answer will be a trivial one.

I have recently started studying algebraic field extensions and I got to know that algebraic closures $\overline{F}$ of finite fields $F$ are infinite. Therefore, I've asked myself the following question and couldn't come up with an answer.  Suppose $F$ was a finite field, i.e. $|F| < \infty$. Is it possible to construct an algebraic extension $F'$ of $F$ sucht that $|F'| = \infty$ and $F' \subsetneq \overline{F}$? Meaning, that $F'$ is not algebraically closed.


I have a span tag as follows:  <span>&times;</span>  In JavaScript, if I check   $("span").html()  Response is: "-"  Is there any way I can compare   $("span").html() == "&times;"   instead of $("span").html() == "-"?

I have the following html code:
&uArr;Header title
   I would like to toggle between up arrow and down arrow each time the user clicks the span tag.   function expandCollapse(id) {        var arrow = $("#"+id+" span").html(); // I have tried with .text() too     if(arrow == "&dArr;") {              $("#"+id+" span").html("&uArr;");                    } else {                 $("#"+id+" span").html("&dArr;");                    } }   My function is going always the else path. If I make a javacript:alert of arrow variable I am getting the html entity represented as an arrow. How can I tell jQuery to interpret the  arrow variable as a string and not as html.


In the following statement, what would be the null and alternative hypothesis? The researcher wants to test (at the 1% level), whether the true mean score is at least 5 points.  I got confused because I have learned that Ha is not supposed to have the equal sign so even if it says at least, is it okay to write this hypothesis?:  $$ H_0: \mu = 5 \\ H_a: \mu > 5 $$

After taking a statistics course and then trying to help fellow students, I noticed one subject that inspires much head-desk banging is interpreting the results of statistical hypothesis tests.  It seems that students easily learn how to perform the calculations required by a given test but get hung up on interpreting the results.  Many computerized tools report test results in terms of "p values" or "t values".  How would you explain the following points to college students taking their first course in statistics:   What does a "p-value" mean in relation to the hypothesis being tested?  Are there cases when one should be looking for a high p-value or a low p-value? What is the relationship between a p-value and a t-value?


There was a  that collided with an edit by the OP. The OP had added information to the question, but the suggested edit was missing this, so in the comparison it was like the edit removed this part.  I wanted to approve the suggested edit and also improve it by re-adding the missing part. Meanwhile, the suggested edit had been rejected by 3 people. As a result, the things changed by the suggested edit are now attributed to me.  Either the suggested edit should have been included in the revision history anyway, or it shouldn't be possible for 3 people to reject it while someone else is improving it.  (The question has also been removed now, so it's 10k+ to view it I believe)

I just made some minor edits to the text of .  I didn't edit the tags at all.  When I completed my edits, my edit showed as:    Now, I think those tags were present before I started my edit, and so were probably slipped in by the OP in their edit grace window.  I have no problem with that tagging, but I don't like seeing edits attributed to me that I didn't make.  So, what the heck?


After an security audit of our Windows Server farm we got this notice:     Disable support for any RC4-based cipher suites.   The most information I can find is this    Does anyone have any further instructions or recommendations beyond this?  Thanks much

I have just used www.ssllabs.com and ran a few tests - my server is capped to a B grade because my server accepts RC4     This server accepts the RC4 cipher, which is weak. Grade capped to B.   I've researched and found that to disable RC4 I need to add 3 keys, and set their enabled dword to 0  and   I have done this for RC4 40/128, RC 56/128 and RC4 64/128  I then restarted my server. When the server was up again, I verified the Registry Changes were done, and they are - all 3 exist and all 3 have their enabled value set to 0.  I return to ssllabs, clear the cache, re-run the test and it returns the same result (capped to B due to RC4 being enabled).   At this stage, I'm not sure what this means - if SSLLabs showing incorrect results (I'm going to assume not), have I disabled RC 4.  How can I tell if I have successfully disabled RC4  Edit  I also saw the KB about this  so trying now... I've done the same registry changes but, when I try to download the 64 bit version for W2008 R2 Standard, it fails to install with error message     The update is not applicable to your computer


I'm building an application using React an Apollo 2 and I'm trying to write a script to generate static html files for server-side rendering.  I'm currently using this logic to render my React component on the server and it's working fine:  export default (Page) => (req, res) => {     const App = (         <ApolloProvider client={client(fetch)}>                              <Page />                      </ApolloProvider>     );      getDataFromTree(App).then(() => {         const data = {             html: ReactDOMServer.renderToString(App),             seo: { title: "Home", description: "" }         };         res.render("index", { data });     }); }   But I wanted to generate the .html files so I could serve them statically, without running this method every time. I tried to compile the result of renderToString to an .ejs file and then write to a file using fs, but it didn't work. This is the code:  const component = ReactDOMServer.renderToString(App); const template = ejs.compile(fs.readFileSync(path.join(__dirname, 'landing_template.ejs'), 'utf-8')); const html = template({ component });  fs.writeFile(     path.join(__dirname, "../views/landing.ejs"),     html,      err => {         if(err) console.log(err);         else console.log("done."); });   The file was written successfully but If I open my Page Source the part added by the compile method is grayed out and seems to be ignored:    I also tried just reading the file and replacing the string using .replace and inserting a dummy div, but it's always the same result.  // using compile const template = ejs.compile(fs.readFileSync(path.join(__dirname, 'landing_template.ejs'), 'utf-8')); const html = template({ component });  const template = ejs.compile(fs.readFileSync(path.join(__dirname, 'landing_template.ejs'), 'utf-8')); const html = template({ component: "
teste
" });  // using readFile const template = fs.readFileSync(path.join(__dirname, 'landing_template.ejs'), 'utf-8'); const html = template.replace("<%- component %>", component);  const template = fs.readFileSync(path.join(__dirname, 'landing_template.ejs'), 'utf-8'); const html = template.replace("<%- component %>", "
teste
");  // maybe this is the problem? fs.writeFile(     path.join(__dirname, "../views/landing.ejs"),     html,     { encoding: "utf8" },     err => {         if(err) console.log(err);         else console.log("done."); });     I guess the browser is not recognizing this new text as HTML and failing to parse it. Does any one know a way I can make this work?  Thanks!

What is the reason browsers do not correctly recognize:  <script src="foobar.js" /> <!-- self-closing script element -->   Only this is recognized:  <script src="foobar.js"></script>   Does this break the concept of XHTML support?  Note: This statement is correct at least for all IE (6-8 beta 2).


So you're in the TARDIS in a car park, and for some reason the TARDIS falls over and lands door side down. You are not a Time Lord, so you can't just press the "right yourself" button (if there even is one) but you are able to open the doors and stand on the concrete surface of the car park. Now, let's suppose you want to lift the TARDIS to its upright position. Are you lifting the weight of the police box, or the weight of all the rooms inside the TARDIS? Edit: I'm not asking how much the TARDIS weighs, I'm asking whether it's the internal or external weight that would apply in these circumstances.

Lady Romana is quoted as saying a TARDIS weights 5x10^6 kilograms, but I've also read that she was mistaken in this or that she was referring to the inside.  The Doctor's TARDIS has been moved a number of times and has landed on soft ground and not sunk in at all.  This indicates the full weight of the interior is not felt from the exterior.  But in The Parting of the Ways, Rose, Jackie, and Mickey use a large truck with chains to free up part of the interior of the TARDIS, and when they pull with the truck, the TARDIS doesn't just get pulled along on the ground, so, at least when the door is open, there's some connection between the weight inside and the outside shell.  I've searched for this and Romana's answer is the only one I find, but if that were true and it weight that much on the outside, people could not pick it up and move it.  How much does the Doctor's TARDIS weight from the outside?


According to Wikipedia, $^44$ has $8.1 \cdot 10^{153}$ digits. How can I calculate the number of digits for an arbitrarily large tetration, such as $^{11}11$?  Thank you!

As you read in the title, I need a technique for counting number of digits in .   For example:  ${3^{(3)}}^3 = 7625597484987 $(13 digits)  ${7^{(7)}}^7 = $How many digits (approximately)?  ${{11}^{(11)}}^{11} $= How many digits (approximately)?  Is there any technique for calculation?


I am working on a board that includes an Atmega328 which needs to read data from an SD card. I am having problems. Here is a diagram:    I believe the issue may stem from the voltage divider that is connected to The hex converter  (74HC4050D) and the micro SD card. However I have tried removing that and connecting a regulated 3.3V signal in it place and it still does not work. Does anyone have any idea what I am doing wrong? Help is greatly appreciated!

Once again I need your help in my project. I have a 4,5v powered circuit. I put a voltage divider with 2 resistors in series to reduce my initial voltage of 4.5 V to 3.4 V (to feed an XBee module).  The issue is that if I do not connect the xbee, the voltage divider reduces the input voltage to the desired voltage(3.4 V), but when I connect the XBee module, the resulting voltage divider voltage drops to a value very low (0.85 V), making the XBee malfunction. Surely it is a basic mistake, I am asking something that is very clear, but I'm newbies.   Basic Circuit:  Vin(4.5 V)-----R2(10 kΩ)---------R1(33 kΩ)--------GROUND                        |                        |                  Vout desired (3.4 V)                        |                        |                       XBee


There is a script in different unix servers for space cleanup. I dont want to connect all servers everytime, and want to run the script by connecting to only one unix server. Can you please assist on it.

I have to run a local shell script (windows/Linux) on a remote machine. I have SSH configured on both machine A and B. My script is on machine A which will run some of my code on a remote machine, machine B. The local and remote computers can be either Windows or Unix based system. Is there a way to run do this using plink/ssh?


How would I find this limit?  $\lim_{n \to \infty}\ n\ \sin\ (2\pi en!)$, where $e$ is the exponential.

I tried and got this   $$e=\sum_{k=0}^\infty\frac{1}{k!}=\lim_{n\to\infty}\sum_{k=0}^n\frac{1}{k!}$$ $$n!\sum_{k=0}^n\frac{1}{k!}=\frac{n!}{0!}+\frac{n!}{1!}+\cdots+\frac{n!}{n!}=m$$ where $m$ is an integer. $$\lim_{n\to\infty}n\sin(2\pi en!)=\lim_{n\to\infty}n\sin\left(2\pi n!\sum_{k=0}^n\frac{1}{k!}\right)=\lim_{n\to\infty}n\sin(2\pi m)=\lim_{n\to\infty}n\cdot0=0$$  Is it correct?


Let $f:[a,\infty)\to\mathbb R$ be a continuous function such that $\int_a^\infty f(x)dx$ exists finitely , then is it true that $\lim_{x \to \infty}f(x)$ exists and is equal to $0$ ? If not , then what if we restrict the range of $f$ to be non-negative only ?

I'm trying to prove  the following claim:     If $f$ is continuous  and $\displaystyle\int_a^\infty |f(x)|\;dx$ is finite then $\lim\limits_{ x \to \infty } f(x)=0$.   Here the counter example of all these sine functions won't do, since  their infinite integral does not converge absolutely.   Any hints for a proof?


I have Apache running for a Joomla! site The site is CBSL, under www (so www\cbsl\index.php) To access it my user have to code http:\mysite\cbsl Is there a way to configure Apache so that http:\mysite is sufficient ?

This is a  about Apache's mod_rewrite.   Changing a request URL or redirecting users to a different URL than the one they originally requested is done using mod_rewrite. This includes such things as:   Changing HTTP to HTTPS (or the other way around) Changing a request to a page which no longer exist to a new replacement. Modifying a URL format (such as ?id=3433 to /id/3433 ) Presenting a different page based on the browser, based on the referrer, based on anything possible under the moon and sun. Anything you want to mess around with URL   Everything You Ever Wanted to Know about Mod_Rewrite Rules but Were Afraid to Ask!  How can I become an expert at writing mod_rewrite rules?   What is the fundamental format and structure of mod_rewrite rules? What form/flavor of regular expressions do I need to have a solid grasp of? What are the most common mistakes/pitfalls when writing rewrite rules? What is a good method for testing and verifying mod_rewrite rules? Are there SEO or performance implications of mod_rewrite rules I should be aware of? Are there common situations where mod_rewrite might seem like the right tool for the job but isn't? What are some common examples?   A place to test your rules  The  web site is a great place to play around with your rules and test them. It even shows the debug output so you can see what matched and what did not.


Suppose we have the set $M_{\alpha\in(0,1)} = \left\{\boldsymbol{x}\in \mathbb{R}^3: \boldsymbol{x} = f(\alpha)+\lambda g(\alpha), \lambda\in \mathbb{R} \right\},$ where $f,g:\mathbb{R} \rightarrow \mathbb{R}^3$. Intuitively, $M_{\alpha}$ is a line in the three-dimensional space. Then, is there a suitable metric $d(M_{\alpha'},M_{\alpha''})$ for $\alpha',\alpha'' \in (0,1)$ that we can use? I asked a simpler question in this post, , where sup-norm was recommended. However, $\lambda$ now is no longer bounded, and thus, sup-norm cannot be used. I wonder if there is any other metric out there that can be used here and involves $L^2-$norm? Update: One potential metric that I have in mind is $d(M_{\alpha'},M_{\alpha''}) = ||f(\alpha')-f(\alpha'')|| + ||g(\alpha') - g(\alpha'')||$. Please correct me if there is any flaws in this. Sketch of the proof: Let $(\mathcal{S},d)$ be the metric space.  $d(M_{\alpha'},M_{\alpha''})=0$ iff $||f(\alpha')-f(\alpha'')|| = 0$ and $||g(\alpha') - g(\alpha'')||=0$ iff $f(\alpha')=f(\alpha'')$ and $g(\alpha') = g(\alpha'')$ iff $\alpha'=\alpha''$ iff $M_{\alpha'}=M_{\alpha''}.$ $d(M_{\alpha'},M_{\alpha''})=||f(\alpha')-f(\alpha'')|| + ||g(\alpha') -g(\alpha'')||=||f(\alpha'')-f(\alpha')|| + ||g(\alpha'') - g(\alpha')||=d(M_{\alpha''},M_{\alpha'}).$ Let $M_{\alpha'}, M_{\alpha''}, M_{\alpha'''} \in \mathcal{S}$, $$d(M_{\alpha'}, M_{\alpha''})+d(M_{\alpha''}, M_{\alpha'''})=||f(\alpha')-f(\alpha'')|| + ||g(\alpha') - g(\alpha'')||+||f(\alpha'')-f(\alpha''')|| + ||g(\alpha'') - g(\alpha''')|| \geq ||f(\alpha')-f(\alpha'')+f(\alpha'')-f(\alpha''')||+ ||g(\alpha') - g(\alpha'')+g(\alpha'') - g(\alpha''')|| = ||f(\alpha')-f(\alpha''')|| + ||g(\alpha') - g(\alpha''')|| = d(M_{\alpha'}, M_{\alpha'''}).$$  Hence, $d$ is a valid metric. Thanks in advance for any help!

I would like a metric $d(\;)$ between pairs of (infinite) lines in $\mathbb{R}^3$, with these properties:   If two lines $L_1$ and $L_2$ are parallel and separated by distance $x$, then $d(L_1,L_2) = x$. $d(L_1,L_2)$ increases with the degree of skewness between the lines, i.e., the angle $\theta$ between their projections onto a plane orthogonal to the shortest segment connecting them (dashed below), where $\theta=0$ for parallel lines and $\theta=\pi/2$ for orthogonal lines.         Intuitively, I would like the metric to be related to the repulsive force between two electrically charged lines (but it need not be exactly the actual physical force).  Have such metrics been considered in the literature? If so, I'd appreciate descriptions and/or pointers—Thanks!  Update1. It turns out that the natural ad hoc definition (from the comments) fails to be a metric. For example, below, a sufficiently large value of $a$ ensures the triangle inequality will be violated:       So this question may be more difficult than it initially appeared...  Update2.  The  have revealed that in fact there is no metric that satisfies my two conditions (and is continuous w.r.t. $\theta$)!


Background  About a year ago I bought a desktop computer with Windows 7 pre-installed. Shortly after I burned the Ubuntu16.04 OS on a flash drive, and partitioned my hard drive to give Ubuntu almost the entire size, but still dual boot with Windows. I'm now wanting to re-partition my hard drive so my Windows 7 partition and Ubuntu partition are equal in size.  Hard Drive  I have included a picture of my hard drive partitions here.    1) System Re Partition 1   size:  105MB  device: /dev/sda1  Partition Type: HPFS/NTFS (Bootable)  Contents: NTFS-Not Mounted  2) Filesystem Partition 2   size:  49GB  device: /dev/sda2  Partition Type: HPFS/NTFS   Contents: NTFS-Not Mounted  3) Extended Partition 3  size:  431GB  device: /dev/sda3  Partition Type: Extended  Contents: Extended Partition  4) Filesystem Partition 5   size:  414GB - 366 GB free (11.7% full)  device: /dev/sda5  Partition Type: Linux  Contents: Ext4(version1.0) - Moounted at Filesystem Root  5) Swap Partition 6   size:  17 GB  device: /dev/sda6  Partition Type: Linux Swap  Contents: Swap (version 1) - Active  Question  1) Assuming my windows OS is on Partition 2, should I take memory from Partition 5?  2) What is the Extended Partition used for? It appears to just be the sum of Partition 5 (Ubuntu) and 6 (Swap)   UPDATE On boot, I've noticed that my windows OS is on /dev/sda1 (System Repartition 1) NOT /dev/sda2 (Filesystem Partition 2). So what is the purpose of /dev/sda2?  Thanks again for your help.

I have backups up everything, but I'm still uneasy about the process and would like confirmation. I'd rather do this one time correctly. I want to shrink /dev/sda6/ by 200GB and reallocate it to /dev/sda2. I boot a LiveCD and turn off LinuxSwap (locked otherwise). I've been reading that it is very hard to move "left" when partitioning and other AskUbuntu threads are confusing me. Do I need to resize /dev/sda6 by 200GB "preceding" (rather than "following"), and then resize /dev/sda4 by 200GB? A little guidance would ease my nerves of messing everything up. Thank you ahead of time.


I am working on a minigame on my Spigot server and can't seem to find out how to make right-click events like servers do. For example, I want to be able to receive speed effects after right-clicking sugar, but I currently have repeating command blocks that detect if a player meets "SelectedItem"requirements.  Some use teleporting armor stands to trigger when they right-click them, but that seems like a hassle. Others use carrots on a stick and retexture it to detect its use, but I don't want custom resource packs on my server.  Do servers use these methods to detect right-clicks? There must be another way.

Is there a way so that I make make it when I left click/right click with a certain item it applies an effect? I know that you can apply attributes to wearing armor and things but I want it so when you use the item it applies an effect on your player.  For example, let's say I want something so that when I right click with a certain item (let's say an iron ingot that was given to me) I'll then have a jump boost for 10 seconds. So kinda like a potion in a way.  Is this possible with command blocks/commands/any mods?


Currently I have a user called "git", which has access to its home folder and all folders inside (they are git repos). I need to create another user with access to just one of the folders of the "git" user.  When I googled it all answer point to changing the ownership of the folder to the new user, but I'm afraid I might screw up the existing user by doing that.  I tried by setting the permissions to the folder to 664, which is supposed to give read permission to "others", but I get permission denied when I login with the new user and try to cd into the folder.  Can someone tell me how to do this properly?  Cheers

I want the transmission-daemon to have permission to write to a directory called /opt/www/ that already has the owner set to www-data(in order for the web server to serve files in it)  The transmission daemon responds with a permission denied error when I set it to my download directory. How can I give it permission to write in this directory while maintaining the www-data ownership?  Sorry if it's a bit confusing I will clarify if I was unclear. Thanks!  Basically: /opt/www needs www-data to be able to be served as a webpage, but at the same time I want transmission to be able to write files to that folder. How can I do that? By default transmission runs on the user debian-transmission


$R$ is a commutative ring with unit and $M$ is a finitely generated free $R$-module. Is the submodule of $M$ also finitely generated?

I'm looking for an example of a finitely generated module with submodules that are not finitely generated.  I've found  dealing with group (i.e. an example of a finitely generated group with subgroups that are not finitely generated). But I can't figure out whether that question do help to this one.  And I actually want to find a more "module-like" example rather than an example derived from a 'strange' group.  Can you please help? Thank you!


I am writing a contributions page of my thesis and thus I would like to use the referencing system built into LaTeX to format a few journal entries. Is there anyway to place individual BibTeX entries mid document?   For example I would like to write a paragraph of text, followed by a full reference on its own line, followed by another paragraph of text.   Thanks.

I would like to take the full citation of a reference in my BibTeX file and write commentary in-line after it.  A \fullcitation{id} command would be perfect.  I would like to use it as:  \fullcitation{id1}   This paper talks about A with applications to B.  \fullcitation{id2}   This paper considers how C affects A.  Whenever the \fullcitation{id} command appears, I want it to be replaced with the full reference, including authors, title, journal, and date.  Is this possible?


I know there's been a lot of discussion about password strength and indicators when signing up. I often find that when I forget a password for a site, its because I can't remember which set of rules were in place for that site (ie, >10 chars, special chars, no numbers) and if I knew those rules, Id remember which algorithm I used for my password.   To me, it seems like it's worth giving the user a hint about what the password rules were, before forcing them to go through the whole forgot password process. I'm finally able to implement something like this on our site, but I was curious about the UX of it.         – Wireframes created with   With that said, has anyone seen this done in practice/know of a reason not too?  Edit 1:  I've often thought the argument against this falls under the vague umbrella of security-- "If we display this information it will be easier to crack the password"-- but I can obtain the same information by attempting to create a new account

Different websites have different password requirements   Some are content with a combination of just lower case words  Some require a combination of lower case and upper case words Some require numbers in your password Some require special charecters   Now I have a number of different passwords modified to suit the website requirements but I often get mixed up about whether the password was      word@%(some numbers) or just word(some numbers)    and I end up often resetting my password or not even logging in.  Now my question is would be wrong or bad design to display the password guidelines next to the login screen ? I understand it might actually make it unsafe to an extent since it also gives guidelines to someone with malicious intent about how a password might be structured but is this a case where security trumps usability or what is the equitable balance between the two.  Edit: Please note that I am talking about the scenario of password guidelines being displayed when a person is trying to log in (having established an account) and not when he is trying to sign up ( I strongly believe password guidelines are very important then)


class parent {   public:     virtual void print()     {       printf("STUFF");     } };  class child : public parent {    public:      virtual void print()      {         printf("other stuff");      }  };   int main()  {     parent par = new child;     par.print();   }   When ever I try this, it always uses the parent function instead of the child function. I was trying to get it to use the child function instead.

Someone mentioned it in the IRC as the slicing problem.


i've got this code, how can I stop func2 from func1? something like Thread(target = func1).stop() doesn't work  import threading from threading import Thread  def func1():     while True:         print 'working 1'  def func2():     while True:         print 'Working2'  if __name__ == '__main__':     Thread(target = func1).start()     Thread(target = func2).start()

Is it possible to terminate a running thread without setting/checking any flags/semaphores/etc.?


The watch button has those details and i'm no really sure how to do them.

Having a difficult time finding the correct name for this, but I have some photos.  I'm specifically trying to model a sniper scope, and some of the circular rings on it have ridges on them, but I'm not sure how to model the ridges/grooves.  Like this:    Or these google searches might show what I'm trying to explain better:  Sniper scope:   Camera Dial:   Essentially a ring with ridges on it, I'm not sure how to model it.  The poke tool is definitely not working for me, and I cannot add loop cuts to everything. What's the best method for going about modeling this?


So, here we have two converging sequences. It is obvious that from certain point our $x_n$ will be extremely close to $a$ and $y_n$ will be extremely close to $b$. Hence, we have infinite number of their reversed products which are extremely close to $ab$, there are only finite number of products for fixed $\epsilon$ which are not in $(ab - \epsilon, ab + \epsilon)$. Okay, these are intuitive assumptions, but how to prove it formally?

When $\lim_{n\to\infty} x_n = a$, and $\lim_{n\to\infty} y_n = b$, find the limit, $$\lim_{n\to\infty} \frac{x_1 y_n + x_2 y_{n-1} + \cdots + x_n y_1}{n}.$$ Thank you for your help in advance.


Where can I purchase video codecs for Ubuntu rather than downloading video codecs from an unknown source? I would like to purchase it.

I'm new to Ubuntu. I tried installing it with Windows 8.1, but failed I lost all my files.  I have successfully formatted my PC and installed Ubuntu, but how do I install codecs to play audio and videos files ?


I need to send the values of some variables from a Python script to a program "a.exe" written on C. To understand, the source of "a.exe" is here:  #include <stdio.h> int main(){ double x1,x2; scanf("%lf  %lf", &x1, &x2); printf("%lf+%lf=%lf", x1,x2,x1+x2); return 0; }   The only thing I managed to find is to send the keyboard input, not variables:  import subprocess p = subprocess.Popen("a.exe", stdout=subprocess.PIPE) print ( p.stdout.read() )   That script works but I need to send to "a.exe" the values of variables xx1,xx2 instead. The script should look something like this:  import subprocess xx1=1.;xx2=2. p = subprocess.Popen("a.exe", stdout=subprocess.PIPE) ############   it seems that there must exist a very simple solution. What to put instead of the line with ############ (or what to do in fact) so as it worked?

How do you call an external command (as if I'd typed it at the Unix shell or Windows command prompt) from within a Python script?


We want to update following items on Ubuntu. But our server is not connected to Internet due to security reason. What alternatives do we have?   Python & python 3 NodeJS PHP Python Computer vision (openCV) MongoDB Nginx Loopback Tensorflow Theano Java Zebra crossing Highlighter component dependencies Barcode reader dependencies NodeJS packages Python packages

I have a friend who has got a computer that is not connected to the Internet. Is there any way to install software offline easily?


I have an Acer Aspire laptop running Windows 8.1. I do not have a CD/DVD drive nor a USB stick. What I would like to know is how to install Ubuntu on a partition of your main hard drive without a CD/DVD or USB drive. I've looked all over the web and haven't found anything.

Please read entire post CAREFULLY before answering.  This question will make you confused if you don't.  Information (May skip :P)   OS : Windows NT 6.2 (Windows 8 K) Equipped hard disk   Total 1TB, 1 disk C: (Simple Layout, NTFS, Boot, Pagefile, Crash dump, Main): total 488,039,776,256 bytes, used 93,473,599,488 bytes D: (Simple Layout, NTFS, Main): total 486,859,075,584 bytes, used 8,426,016,768 bytes hidden: Ask if needed  Brand(manufacturer): Samsung Electronics Processor(CPU): Intel(R) Core(TM) i5-3230M CPU @ 2.60GHz RAM: 8GB , 64-bit , OS 64-bit   Question (READ THEM ALL VERY CAREFULLY)   Is there any way to install Ubuntu on this computer without any external disk (CD, USB drive, etc) Note : This computer is 64-bit, so  did not help me. WUBI does not support UEFI, and This computer uses it. No Virtual PC programs like VirtualBox or VMWare, because it takes memory.   EDIT : I already found a USB drive in my home, so now it is installed on my computer xD


Prove that if $f$ is defined and continuous in $[a,+∞)$ and if there exists a finite limit $\lim_{x→+∞}f(x)$, then $f$ is uniformly continuous in $[a,+∞)$  I know that since there exists a finite limit $\lim_{x→+∞}f(x)$, so $f(x)$ is convergent. How can I use this to prove it's uniformly continuous?

I am working on a homework problem from Avner Friedman's Advanced Calculus (#1 page 68) which asks     Suppose that $f(x)$ is a continuous function on the interval $[0,\infty)$. Prove that if $\lim_{x\to\infty} f(x)$ exists (as a real number), then $f(x)$ is uniformly continuous on this interval.   Intuitively, this argument makes sense to me. Since the limit of $f(x)$ exists on $[0,\infty)$, we will be able to find a $\delta > |x_0 - x_1|$ and this implies that, for any $\epsilon>0$, we have $\epsilon > |f(x_0) - f(x_1)|$ (independent of the points chosen). I am aware that the condition of uniform continuity requires that $\delta$ can only be a function of $\epsilon$, not $x$.   What information does the existence of a real-valued limit provide that implies $f(x)$ is uniformly continuous on this interval?


Is there a way to exclude a module from a Drush update so it can be ignored when running eg 'drush up' ?  I ask because Rules 2.8 is causing problems with Drupal Commerce but it would be great if everything else could still be updated with Drush.

In a current project I have had to patch the life out of a few modules (node hierarchy, workbench access and a few more). These modules are now absolutely perfect for the project's needs and are very unlikely to break with future updates to core.  That being said, when the app is handed over the clients will have full (user 1) access to the system and will therefore be warned when these modules have available updates. And they will update them, no matter how many times I beg them not to (oh how easy life would be without clients!).  Is there a way (perhaps in the modules' .info files) to persuade the update manager not to check for updates for these modules?  EDIT  I'm aware of the project status url key that's available for the .info file so I guess I could set that to a non-existent URL but I'd much rather do this in a clean way if possible.


How to completely disable automount of any USB HDD? I would prefer mount them via the sudo mount /dev/sde8 /mnt/... method.  I have tried to write an udev rule to /etc/udev/rules.d/85-no-automount.rules  SUBSYSTEM=="usb", ENV{UDISKS_AUTO}="0"   but have not helped.

I am using Ubuntu 11.10 (64 bits) and I do not want to mount automatically USB thumb drives in my system. I tried the command dconf-editor and gconf-editor but there isn't the icon to disable it in nautilus preferences (apps|nautilus|preferences|media_automount).  Thanks.


When I try to read data with the same RandomAccessFile object nothing is returned, however when I create a new Object and read that file it works fine, why is this occurring? class RandomAccess{ public static void main(String[] args) {     try(RandomAccessFile rand = new RandomAccessFile("random.txt","rw")){         rand.writeInt(2);         System.out.println(rand.readInt()); // this does not return anything         //RandomAccessFile input = new RandomAccessFile("random.txt","rw");         //System.out.println(input.readInt()); -> this correctly returns '2'     }     catch (IOException e){      }  }  }

I have the following fields:   Inventory control (16 byte record)   Product ID code (int – 4 bytes) Quantity in stock (int – 4 bytes) Price (double – 8 bytes)    How do I create a fixed length random access file using the above lengths? I tried some examples online, but I either get an EOF exception or random address values when I try to access them.  I tried some more examples and couldn't understand the concept very well. I'm trying a project with it and will try to explore more on it.  Here is some example data. There might be holes in the data where No. in stock could be 23 == 023.            Quantity ID. No.   In Stock   Price  -------   --------   ------  1001       476      $28.35  1002       240      $32.56  1003       517      $51.27  1004       284      $23.75  1005       165      $32.25   Thanks for the help.


Currently doing a introductory degree level physics course, they were talking about how changes in gravity/gravitational field cause changes so quickly that if you assigned it the "graviton" said boson would have to be breaking the speed of limit in order for the changes to be possible.  My question, is there any research or current theory's that are at all successful in resolving this issue ?

My understanding is that light can not escape from within a black hole (within the event horizon).  I've also heard that information cannot propagate faster than the speed of light.  It would seem to me that the gravitational attraction caused by a black hole carries information about the amount of mass within the black hole.  So, how does this information escape?  Looking at it from a particle point of view: do the gravitons (should they exist) travel faster than the photons?


Hello how can i view the system elapsed time ? Example: ubuntu is turned on at 10:00 now it would be 12:00 , elapsed time is : 2 hours how can i get this information ?

Possible Duplicate:          Well sometimes for testing purposes I want to know the up time but don't know where to look. How do I check for this?


Yes, I know, can't be answered, blah, blah, blah.... but here are a few of my theories. I know, plenty of other questions like this, but before marking this as a duplicate, consider this, my mathematical friends:   We know that $ x/x = 1 $. We also know that $ 0/x = 0 $.   Then, considering these to facts, $$ 0/0 $$ could be    $ 1 $, because $ x/x = 1 $ or $ 0 $, because $ 0/x = 0 $   Then, of course we can consider $ x/0 $, where $ x $ can be any real number. Then $ 0/0 $ can be $ 0 $ or $ 1 $, and then the rest according to theory, is $ \infty $ or $ \text {undefined} $. Then how come we say $ \dfrac {x}{0} = \infty $? Or is this only true being $ x \neq 0 $?  Or is it that just for practical sense, we just say that $ x/0 = \infty $? Is it because it is just because it is not computationally possible? Or is it just because $$ \dfrac {5}{\dfrac {1}{2}} = 5(\dfrac {2}{1}) = 10 $$  and then $$ \dfrac {5}{\dfrac {1}{100}} = 500 $$ and then $$ \dfrac {5}{\dfrac {1}{100000}} = 500000 $$ and so the numbers keep on going to $ \infty $ as we get closer to $ 0 $?   I know there are lots of possible answers but then the theory that $ \dfrac {x}{0} = \infty $ even though $ \dfrac {0}{0} $ could be 1 or 0, that just does not make sense to me. I will appreciate any answers / at lease possible answers, because I understand that this is just a very controversial topic of mathematics.

I came up some definitions I have sort of difficulty to distinguish. In parentheses are my questions.   $\dfrac {x}{0}$ is Impossible (  If it's impossible it can't have neither infinite solutions or even one. Nevertheless, both $1.$ and $2.$ are divided by zero, but only $2. $ has infinite solutions so as $1.$ has none solution, how and why ?) $\dfrac {0}{0}$ is Undefined and has infinite solutions. (How come one be Undefined and yet has infinite solutions ?) $\dfrac {0}{x}$ and $x \ne 0$, it's okay for me, no problem, but if someone else wants to add something about it, feel free to do it.


I've scheduled a daily 1:00 AM shutdown of my MacBook but an app interrupts the process with a prompt that I need to manually answer before the shutdown can continue. How do I force an automatic override of this prompt or prevent it from appearing in the first place so the machine can shutdown successfully?  The app in question is Audio HiJack on macOS - Sierra.

I could not find any relatively simple way to log out of a public use Mac quickly with many tabs open and unsaved document in the background without resorting to sudo shutdown -h now.  The reason I ask is that sometimes a user will have his/her account logged into the iMacs here at school and they would try to log off and then leave, thinking it has completed but the process is interrupted by Safari and Office apps, leaving their account, mounts, and websites still accessible to the next person who sits down.  Obviously a shortcut string would be nice instead of posting a note telling the person to type arcane things in a terminal. For example, just having them try to find Terminal.app is going to be a chore.  This doesn't seem to make sense because the user can just quit each app and click a few dialog boxes but unlike you and I to whom repeatedly pounding Command-Q while hitting the spacebar and D keys are probably second nature.


$f$ is an entire function, suppose:  $$\lim_{z\to\infty}\frac{\Re f}{z} =0$$  Can we proof $f$ is constant? Thanks!

I'm having trouble with the following exercise from Ahlfors' text (not homework)  "If $f(z)$ is analytic in a neighborhood of $\infty$ and if $z^{-1} \Re f(z) \to0$ as $z \to \infty$, show that $\lim_{z \to \infty} f(z)$ exists. (In other words, the isolated singularity at $\infty$ is removable)  Hint: Show first, by use of Cauchy's integral formula, that $f = f_1 +f_2$ where $f_1(z) \to 0$ for $z \to \infty$ and $f_2(z)$ is analytic in the whole plane.  My attempt:  $f$ is analytic in the exterior of some disk $\{|z|\geq R_0 \}$. For large enough $|z|$ the circle $C_1(z)$ around $z$ with radius one lies in the domain of analyticity, and we can apply Cauchy's integral formula:  $$f(z)=\frac{1}{2\pi i}\oint_{C_1(z)}\frac{f(\zeta)}{\zeta-z} \mathrm{d} \zeta=\frac{1}{2 \pi i} \oint_{C_1(z)}\frac{\Re f(\zeta)}{\zeta-z} \mathrm{d} \zeta+\frac{1}{2\pi} \oint_{C_1(z)}\frac{\Im f(\zeta)}{\zeta-z} \mathrm{d} \zeta. $$ I want to say that the last expression is exactly the decomposition $f_1+f_2$. Indeed, using Cauchy's estimate (and the fact about the real part) one can show that the first integral tends to zero for large $|z|$, but I can't understand how to define the other one for all $z \in \mathbb C$.  In fact, even if I have such a decomposition, I don't think that it will suffice: For instance $f(z)=f_1(z)+f_2(z)$ with $f_1(z)=0,f_2(z)=\exp(z)$ has an essential singularity at $\infty$.  Thank you for any directions.