So as the title reads, i want to create a template class and put methods/functions implementations into the relative source file. After some research on the internet i found some perplexing solution with something about making an extra file and including it in the header.  I know that it is possible to place all the implementations inside header file and it will work just fine. Also a side question to that is: Is it commonly acceptable as the best solution to place all the implementations inside header or not because in a comparison to ADT in C you kinda want to hide the implementation in the source file, is it the same case right here?  A little example: Lets say i want a 2-D plane of dots that are characters and i want to use the following code.  Point.h  #ifndef POINT_H_ #define POINT_H_  template <class T> class Point {     T* x;     T* y; public:     Point(); };  #endif   Point.cpp  #include "Point.h"  template <class T> Point<T>::Point(){     x=new T;     y=new T; }

Quote from :     The only portable way of using templates at the moment is to implement them in header files by using inline functions.   Why is this?  (Clarification: header files are not the only portable solution. But they are the most convenient portable solution.)


so i've checked all the other questions similar to this and i tried them out and they didn't work (how to add minecraft as a firewall exception for instance) and i've searched the question up on youtube and stuff but that didn't work either

My LAN server won't let my cousin join me or me join my cousin. It won't show up on the multiplayer screen - it keeps saying "scanning for LAN servers" but it never finds it. I am at his house and we use different computers but it won't connect. How can I fix this?


I have an array  array=(src/ucode/pkgs/get_ch.c  qa/tests/ucode/chktest.pl  src/ucode/pkgs/get_ch.c src/profile/settings.txt  src/ucode/pkgs/main_pf.c  src/ucode/pkgs/get_ch.c src/ucode/pkgs/main_ch.c src/ucode/pkgs/main_pf.c)   I need to get unique files from that array  src/ucode/pkgs/get_ch.c  qa/tests/ucode/chktest.pl src/profile/settings.txt  src/ucode/pkgs/main_pf.c  src/ucode/pkgs/main_ch.c   Basically I need to delete duplicate strings from the array

If I have a string "1 2 3 2 1" - or an array [1,2,3,2,1] - how can I select the unique values, i.e.  "1 2 3 2 1" produces "1 2 3"    or  [1,2,3,2,1] produces [1,2,3]   Similar to uniq but uniq seems to work on whole lines, not patterns within a line...


I can't remember the name of this show, but I remember the beginning.  A family of three (a mom, a kid and a wise old grampa) moved somewhere(?). I don't know where it was, but the kid wants to go explore then he ends up at a library(?). I think then he touched some kind of (red?) stone tablet, then a monster came out. The kid freaked out and ran away but then an enemy monster attacked then the kid's monster and the enemy monster fight.  The phrase "bob and weave" is commonly used during the first episode.

I'm trying to remember a cartoon tv show where the main boy, a blonde girl, and another boy capture monsters. There was something about a 'veil' between their world and the monster world, but a 'secret society' of sorts stopped the monsters from crossing, or used them to battle the people who wanted to use them for evil led by a wise old lady. I'm pretty sure they trapped monsters into pieces of jewelry or clothing.   Not so sure about this part: and they had these 'supernatural powers' that were connected to their 'aura' and they could travel from place to place with it.   (Another brown haired girl joined because she found out? There was an arc where the blonde got jealous and the monster she controlled attacked the brown haired girl?)  I can't remember much of it, but I remember in the end the 'veil' was broken and monsters flew over the city. And the main boy and the blonde girl held hands... or kissed?


If I have a job that's running/paused in the background, is there a way of printing a snapshot of its activity to standard output?

in bash I have some jobs running, in background. They are always producing random irrelevant error messages that pollute the terminal. I am not always so prompt to start them with the 2>&1 > /dev/null redirect. How can I redirect the output when they are already running?


I am trying to escape the underscore character in a LIKE Statement. I have tried to use the ESCAPE keyword as follows:   COLUMNNAME NOT LIKE '%[\_]xyz%' ESCAPE '\'   but it doesn't work. It is still filtering out %xyz% when I really want it to filter out %_xyz%.  If not by the ESCAPE keyword, how else can this be accomplished?  Any help is appreciated.

How do I escape the underscore character?  I am writing something like the following where clause and want to be able to find actual entries with _d at the end.  Where Username Like '%_d'


I was working on my project and suddenly stdin in PHP stops working. I have code in PHP: test.php <?php  $stdin = file_get_contents('php://input');  echo ">>>>>"; echo $stdin; echo "<<<<<";  and I'm executing it with: echo 'HELLO' | php -f test.php >>>>><<<<<  This works fine: echo 'HELLO' | php -c "echo file_get_contents('php://input');" HELLO  and it doesn't work, I'm spending way too much time on this. Why this simple code doesn't work? Any clues? I'm using Fedora GNU/Linux with php 7.4.19.

I know PHP is usually used for web development, where there is no standard input, but PHP claims to be usable as a general-purpose scripting language, if you do follow it's funky web-based conventions. I know that PHP prints to stdout (or whatever you want to call it) with print and echo, which is simple enough, but I'm wondering how a PHP script might get input from stdin (specifically with fgetc(), but any input function is good), or is this even possible?


We have AWT based application fetching values from DB. Doing upgrade Java6 to 8. At one place in application, we are trying handle exceptions as below -   This part works well for Java6. However for Java8 the if condition is failing even though SQLState ="23000" and VendorCode=2292. I debug in eclipse and got the values at runtime.  One more thing I would like to add; In Java8 I am getting SQLIntegrityConstaintViolationException. However I hope that is not related or causing issue.   catch (SQLException ex)         {          if ((ex.getSQLState() == "23000") && (ex.getErrorCode() == 2292))          throw new PersistentValidationException("DBCustomer: Delete restricted",ex);         else          throw new PersistentUIException("   DBCustomer:delete --- " +             "SQL error occurred.",ex);     }   Any suggestions

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?


There appears to be two sets of card text on Howling Mine, depending on when it was printed. Do they function exactly the same? Or does the old one not matter if it is tapped or not.

While going through the Gatherer database I noticed that the Alpha version of  says,     {1}: You may tap any land, creature, or artifact in play on either side.   whereas the Tenth Edition of the  says,     {1}, {T}: Tap target artifact, creature, or land.   This has me wondering, does the newer Tenth Edition card text retroactively apply to the Alpha card or does the Alpha text still apply when that card is in play? In other words, if I were to play the Alpha version, would I play by its rules, or the newer rules on the Tenth Edition card?


I often find myself not using some of the trickier parts of Stack Exchange, like recommending edits to people's answers, because I participate in a lot of Stack Exchange sites, and they all have different guidelines and rules. Sometimes I get something wrong anyway, but I try to stick to the most commonly acceptable behaviors.  Is that information aggregated anywhere? Has anyone gone through all the Stack Exchange sites and figured out which rule or behavior or expectation quirks are rare or common?  This question is not a duplicate of the main FAQ. The main FAQ covers SE-wide rules. I am looking for the most common non-universal rules across all the separate site FAQs.

Community FAQ For sites in the Stack Exchange 2.0 network To see a list of commonly used words and phrases, see the . For official guidance from Stack Exchange, visit the . Asking questions                            Answering questions                 Accepting answers        Working with posts  What does it mean when a question or answer is...  ?  ?  ?  ?                                       Comments             Etiquette                         Promotion         Editing and Formatting                                    Tagging                      Reputation, badges, and voting                                         Moderation                                                 Searching and RSS feeds        Accounts, registration and logging in                                     Other                                 ()                                 Site-specific entries Stack Overflow             Meta Stack Exchange       Other     External links           Is your question not part of the FAQ? First look at questions tagged  to see if there is a question not in this index that might have the answer you seek. If you still can't find an answer, then see the following instructions for proposing an FAQ question. How can a question be added to this FAQ?  Ask only the question, stated plainly and simply, in the question body. The answer goes in an answer.  Link back to this index. Paste this at the end of the question:  [Return to FAQ index](/q/7931)   Tag as  and .  When a post seems to have hit a mature state, it will have  added by a moderator.  Flag for a moderator to mark community wiki.  Any FAQ post not yet community wiki should be made into a community wiki.  After the post has the  tag added to it, add a link in the above .


When using inverse search, Sumatra PDF opens a new instance of TeXnicCenter.  Sumatra inverse search command is:  "C:\Program Files\TeXnicCenter\TeXnicCenter.exe" /ddecmd "[goto('%f', '%l')]"   According to some advices I tried to change Sumatra advanced settings        ReuseInstance = true   TeXnicCenter settings, define output profiles is:     Latex Tab    C:\Program Files\MiKTeX 2.9\miktex\bin\x64\pdflatex.exe  -synctex=-1 -interaction=nonstopmode "%Wm"   Viewer tab:  C:\Program Files (x86)\SumatraPDF\SumatraPDF.exe -inverse-search -reuse-instance"\"C:\Program Files\TeXnicCenter\TeXnicCenter.exe\" /ddecmd \"[goto('%f','%l')]\""   Project's output   [Open("%bm.pdf",0,1,1)]   Forward search:  [ForwardSearch("%bm.pdf","%Wc",%l,0,0,1)]       I'm using project in TexnicCenter. Main file includes other .tex files. I think this could be the issue. Many thanks for advices!

I wanna use texmaker+sumatra, winEdt8+sumatra and texnic Center+sumatra together. I set the SumatraPDF Inverse-Search option on all editors. But the SumatraPDF Inverse-Search does not work on WinEdt and TexMaker While working on Texnic Center.  TexMaker setting:   winEdt setting:   TexnicCenter setting:


Is there a theorem that tells us that $\widehat{f\circ g}=\hat f(\hat g)?$ Here, $\hat f$ denotes the Fourier transform of $f$.

Given two functions $f$ and $g$, is there a formula for the Fourier transform of $f \circ g$ in terms of the Fourier transforms of $f$ and $g$ individually?  I know you can do this for the sum, the product and the convolution of two functions. But I haven't seen a formula for the composition of two functions.


How to use "into" and "onto" in sentences ? Can we use "onto" in any sense while talking of people and if yes, how ? Do these two quoted words have a common usage anywhere ?

I see both used, at times, almost interchangeably. What are the general guidelines?


I'm trying to run a makefile used by my company, when I type 'make' in my shell I get this error:     Can't locate YAML/Tiny.pm in @INC (you may need to install the YAML::Tiny module) (@INC contains: /Library/Perl/5.18/darwin-thread-multi-2level /Library/Perl/5.18 /Network/Library/Perl/5.18/darwin-thread-multi-2level /Network/Library/Perl/5.18 /Library/Perl/Updates/5.18.2 /System/Library/Perl/5.18/darwin-thread-multi-2level /System/Library/Perl/5.18 /System/Library/Perl/Extras/5.18/darwin-thread-multi-2level /System/Library/Perl/Extras/5.18 .) at ./yaml-html.pl line 21.   BEGIN failed--compilation aborted at ./yaml-html.pl line 21.   And when I run:     sudo cpan install YAML::Tiny   I get:     Reading '/Users/altiire/.cpan/Metadata'     Database was generated on Thu, 13 Aug 2015 04:41:02 GMT   YAML::Tiny is up to date (1.69).   I'm on OS X Yosemite

I get this error:  Can't locate Foo.pm in @INC  Is there an easier way to install it than downloading, untarring, making, etc?


'scolding' means 'speaking angrily to someone because of his or her unpleasant behavior, but that word from the sentence below, I guess, should be translated differently.   Here is the sentence, which is from 'Baker's blue-jay yarn' by Mark Twain:     And there's yet another thing; in the one little particular of scolding - just good, clean, out-and-out scolding - a blue-jay can lay over anything, human or divine. Yes, sir, a jay is everything that a man is.

Dictionary says 'lay over' means 'a short stop in a journey', 'stopover', but  I don't understand this sentence translating 'lay over' as 'stopover'.   Here is the sentence, which is from 'Baker's blue-jay yarn' by Mark Twain:     And there's yet another thing; in the one little particular of scolding - just good, clean, out-and-out scolding - a blue-jay can lay over anything, human or divine. Yes, sir, a jay is everything that a man is.


Does the following correctly express the difference between "as" vs. "like" in this context?     As in the previous week, Jimmy climbed the tree.   Jimmy climbed the tree and he also did it one week earlier.     Jimmy climbed the tree like in the previous week.   Jimmy climbed the tree and he did it the same way one week earlier.

Is there any difference between the following couples of sentences?     Dress as you would if you were having guests.   Dress like if you were having guests.        She kissed him goodbye, as usual.   She kissed him goodbye, like the usual.        Sweet as she is, she doesn't pay his bills.   Sweet like she is, she doesn't pay his bills.


I'm from India and all my life I've pronounced 'often' with 't' silent. Since we follow British English, I assume British people say it the same way? I guess in American English, one pronounces it with 't'. What are the rules about this word in other varieties of English?

I heard people saying "Of-fen" as well as "Of-ton". Till now I have been using the first one but few days ago I had an interviewer who pronounced often "Of-Ton" while interviewing.


In Python 2.7.11, I am creating a two-dimensional list in this way:    array1 = [[0]*2]*2   array2 = [[0 for i in range(2)] for j in range(2)]     Both of them give me [[0,0], [0,0]], but when it comes to modification, they yield different answers:    array1[0][0] = 1   array2[0][0] = 1     Now array1 = [[1,0], [1,0]], array2 = [[1,0], [0,0]]. Apparently array2 is what I expected, but any idea on why array1 behaves differently? I am assuming that array1 is copying the first row to create the matrix and therefore any modification to one of the rows will also affect other rows. But I have been using [None]*size to initialize a one dimensional list and it works fine all the time.

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


from where I come from ,they taught us in high school that it is possible to project holograms in thin air simply by illuminating the hologram with the "correct light" , and having a semi transparent medium in the path of the reflecting light "e.g. Water vapor or smoke" resulting in something like this image  -is this true & if not is there any technology that can project such 3dImages in thin air ?

Is there some law of physics that strictly prohibits the projection of 2D or 3D images into thin air (such as holograms in movies) or is a solution to achieve this still up for grabs by an eventual discoverer?


I have a mini amp and several powe adapters. Can I wire 2 6 volt DC power supplies together for the required 12v DC the amp needs? If so, how? And it suggests 2 amps. Are amps cumulative, and does it matter if they are different? the only relevant video i could find on you tube didnt quite fit my situation and i ended with more questuins than answers

How can I connecting two different DC power sources together? for example 15Vdc(5Amp) with 5Vdc(2Amp). I want to make one DC source (20Vdc,7Amp) by more powerful supplies.


I hope that these code  express my question more clearly.  double xxxx(const double* const array){ //... } int main(){ double* array = new double [5]; xxxx(array); }   Is it actually create a new const array in the stack and heap by the input of the function?

How far do you go with const?  Do you just make functions const when necessary or do you go the whole hog and use it everywhere?  For example, imagine a simple mutator that takes a single boolean parameter:  void SetValue(const bool b) { my_val_ = b; }   Is that const actually useful?  Personally I opt to use it extensively, including parameters, but in this case I wonder if it's worthwhile?  I was also surprised to learn that you can omit const from parameters in a function declaration but can include it in the function definition, e.g.:  .h file  void func(int n, long l);   .cpp file  void func(const int n, const long l)   Is there a reason for this? It seems a little unusual to me.


Suppose we have $f \in \mathbf{C}[x_1,...,x_n]$ and that $f(z_1,...,z_n) = 0$.   Is it true that $f \in (x_1-z_1,...,x_n-z_n)$. Where this is the ideal generated by $x_i - z_i$.   For a single variable polynomial this clearly holds due to the fundamental theorem of algebra.

Let $R$ be a commutative ring, $a_1, ..., a_n$ its elements and  $\phi: R[x_1, ..., x_n] \to R$  defined by  $ \phi(f(x_1, ..., x_n)) = f(a_1, ... ,a_n)$  a ring homomorphism.  Prove: $\ker \phi = (x_1-a_1, ..., x_n-a_n)$  It is obvious that $(x_1 - a_1, ..., x_n -a_n) \subseteq \ker \phi$. I'm not sure how to prove the converse.  At this point I don't know any division algorithms for multivariable polynomials, only for the ones in $R[x]$(and the book from where I taken the exercise doesn't assume the reader to know something beyond basics of rings and ideals, and the division algorithm for $R[x]$). Though I know this could be solved for $i = 1$ by dividing by $x-a$:   Let $f(x) \in \ker \phi$, divide by $x-a: f(x) = q(x)(x-a) + r, f(a) = r = 0$, so $f(x) = q(x)(x-a) \in (x-a)$.


What does the expression "to stick the finger high in the air" mean? It is used in the text about politics.

Could anyone give me an explanation of the meaning of "get one's finger in the air" and the usage of it?


This is the code, where I get several errors, when I add the other case or a deafult. I can't find any basic error like a missing semicolon or so, and the code works properly when I have only one case. I searched trough switch tutorials, but I didn't find anything about vectors and switch statements mixed is a problem.     int main() { int r;  while (cin >> r) {     switch (r)      {        case 3:     int y = 0;     cout << "Please enter some numbers, and I will put them in order." << endl;      vector<int> nums;     int x;     while(cin >> x)     {         nums.push_back(x);         y++;     }     sort(nums.begin(), nums.end());     int z = 0;     while(z < y)     {         cout << nums[z] << ", ";         z++;         if(z > 23)             cout << "\n" << "User... What r u doin... User... STAHP!" << endl;     }     cout << "\n" << "You entered "<< nums.size() << " numbers." << endl;     cout << "Here you go!" << endl;     break;      //In the following line I get the "jump to case label" error.      //I use Dev C++ software.         case 4:     cout << "it works!!!" << endl;     break;      } } system ("PAUSE"); return 0; }   What am I missing?

I've always wondered this - why can't you declare variables after a case label in a switch statement?  In C++ you can declare variables pretty much anywhere (and declaring them close to first use is obviously a good thing) but the following still won't work:  switch (val)   {   case VAL:     // This won't work   int newVal = 42;     break; case ANOTHER_VAL:     ...   break; }     The above gives me the following error (MSC):     initialization of 'newVal' is skipped by 'case' label   This seems to be a limitation in other languages too.  Why is this such a problem?


It's established within the MCU that Mjolnir can sit on a shelf in the helicarrier and can be lifted by an elevator.   (Someone else can edit this question to include references, if they like.)   And obviously it can stick to the ground.   Plus, it is used to pin Loki without crushing him.   So it has the incredible power to "freeze" itself (for lack of a better term)  to various objects and vehicles (elevator, helicarrier, planet).   It other words, it can stick to anything that is stationary in some normal frame of reference for people.   Can Thor stick it to objects that we don't normally think of as a frame of reference, or in a non-vertical orientation? For example, could he stick it to a baseball bat?  A flagpole?   The ceiling?  Hulk?   If not, when does something stop being horizontal?  When does the floor stop being the floor and start being a wall or a pile of rubble?

In the Thor movie, Thor puts Mjolnir  on top of Loki at the end of the movie to stop him from moving.  Why did this not crush Loki?  And if it did not crush him, why could he not just roll out from under it?


I'm trying to convert all my non-prepared queries into prepared statements.  In the following code I have commented out the working old query, above it is the new prepared statement. However it's not working for me. Does anyone see anything wrong with this?  <?php require_once 'pdocon.php';  if (isset($_POST['card_id'])) {     $card_id = ($_POST['card_id']);     $rowname = ($_POST['rowname']);     $rowothervalue = ($_POST['rowothervalue']);      $stmt = $conn->prepare("UPDATE cards SET :rowname = :rowothervalue WHERE id= :card_id");      $stmt->bindParam(':rowname', $rowname);     $stmt->bindParam(':rowothervalue', $rowothervalue);     $stmt->bindParam(':card_id', $card_id);      $stmt->execute();      // $status_sql='UPDATE cards SET '.$rowname.' = '.$rowothervalue.' WHERE id=' . $card_id . '';     // $status_result = $conn->query($status_sql); }  $conn = null; ?>

Why can't I pass the table name to a prepared PDO statement?  $stmt = $dbh->prepare('SELECT * FROM :table WHERE 1'); if ($stmt->execute(array(':table' => 'users'))) {     var_dump($stmt->fetchAll()); }   Is there another safe way to insert a table name into a SQL query? With safe, I mean that I don't want to do  $sql = "SELECT * FROM $table WHERE 1"


Where can I ask questions about the code of a Wordpress plugin?  Can I ask it on Stack Overflow?

There seems to be more than a few computer science/programming Stack Exchange networks (is that the correct term?). Stack Overflow, being the first, has by far the most users, questions, and answers.  What is the reasoning for creating the others, and are there clear guidelines for which kinds of questions should be posted? I can see a large amount of potential overflow, many cases of people not getting a good answer to their question, because the person who has the answer isn't browsing that particular network at the moment.  I understand that they were probably created for organizational purposes, but wouldn't it almost make more sense to just have them as categories under Stack Overflow, keep them separated but still connected, instead of making people have to create multiple 'account's, one for each network?  I am sure there was a very good reason to break them up, but as someone that is new to SE, it can be somewhat intimidating to decide which one to post in to ensure you get a good answer. For example, if I am a computer science student, my first instinct might to be to post in the computer science network, until I see that it literally has 1% of the users as the Stack Overflow network, which still seems to be for programming/computer science related questions.  So my second instinct would then to be to post it into the Stack Overflow site on the basis that I have a significantly higher chance of my question being seen and getting a good answer. Then I notice that there is also a 'programmers' network, and I don't even begin to know where that fits in. I, and I am assuming most people, will probably just post on Stack Overflow to be safe.  My question is, other than the short little description blurb of each one, is there a clear cut set of guidelines which what each network is intended for, what kinds of questions should go to each one, and is anything being done to encourage people to post in these newer, smaller (more specialized?) networks as opposed to just posting in big daddy Stack Overflow?  Now again, this is for computer science/programming/"why isn't this code doing what I want?" related questions, I am not saying that if I had a question about Linux or WordPress or something I would have the same confusion.


im making a comment system in my website. However, the commentor can break the system by typing special characters such as quotes, double quotes, semi-colons,colons etc. This is not a duplicate, i want to make sure that htmlentities are converted before it get to the database, i could use str_replace but it actually prints the literal code. for example:     "  like this example:  $str ="Hi there bro what's up, im a "MEGA""; $comment = $str; echo $comment;   however it spits out errors, because they break the query because of the quotation marks.

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 was recently introduced to the world of conic sections, and I came across two different "definitions" for an ellipse and a hyperbola. I was wondering if there was an easy way to prove that they happen to be "equivalent". First, it was established that: Given a line $r$, a point $F$ not in $r$, and $e \in \mathbb R^+_*$, an ellipse/hyperbola is the locus of the points $P \in \mathbb R^2$ such that $\overline{PF} = e\overline{Pr}$ (where $e<1$ for the ellipse and $e>1$ for the hyperbola) What I would like to verify is that the set of points $\bigg\{(x,y) \in \mathbb R^2: \dfrac{x^2}{a^2} \pm \dfrac{y^2}{b^2} =1\bigg\}$ satisfy the definition given. Any thoughts? Thanks in advance.

(NOTE: This is my attempt at answering  and  , but I rewrote it in order to make it easier for me to solve. Also, I've made . Note that .)  We have two definitions of an ellipse and a hyperbola.   An ellipse is the locus of points that has a constant ratio of distance between a focus (point) and a directrix (line), where that constant ratio is between 0 and 1.     Here, the eccentricity is $\frac C A$, which, by this definition, must be a constant less than 1 for every point on the ellipse.   A hyperbola is the locus of points that has a constant ratio of distance between a focus (point) and a directrix (line), where that constant ratio is greater than 1.     Here, the eccentricity is $\frac{C_1}{A_1}=\frac{C_2}{A_2}$, which, by this definition, must be a constant greater than 1 for each point on the hyperbola.   An ellipse is the locus of points which has a constant sum of distances between two foci.     Here, the eccentricity is $\frac{F}{D_1+D_2}$. According to this definition, $D_1+D_2$ is a constant for every point on the ellipse, so we’ll just call it $D$. Obviously, $F$ is constant since it is just the distance between the foci, which doesn’t change.   The hyperbola is the locus of points which has a constant difference of distances between two foci.     Here, the eccentricity is $\frac{F}{D_2-D_1}$. According to this definition, $D_2-D_1$ is a constant for every point on the hyperbola, so again, we’ll just call it $D$. Obviously, $F$ is constant since it is just the distance between the foci, which doesn’t change.  My question is:  $$\text{How do I prove these definitions are equivalent?}$$


As a math student, it is hard for me to explain the beauty of math to non-mathematicians. So I wonder, how can one explain the elegance of abstract mathematics to somebody without a special background in math, but who is genuinely interested in understanding the joy that comes with it? To make this clear: I am not asking about how to present knowledge in an understandable way so that your friend actually knows what a manifold is for the rest of her/his life. It's more about giving a VERY general idea of why some crazy people (called mathematicians) would consider an induction proof elegant or even beautiful. This should be adressing adults who got through high school, so I suppose more advanced concepts than  or  are desirable. Something that might take an hour to explain but is worth the effort. What beautiful theorems or ideas do you know of that make sense intuitively to non-mathematicians when explained in the right way? Which of them are obviously beautiful, even if one doesn't know all the details about it?

I'm a children's book writer and illustrator, and I want to to create a book for young readers that exposes the beauty of mathematics. I recently read Paul Lockhart's essay  and found that I, too, lament the uninspiring quality of my elementary math education.  I want to make a book that discredits the notion that math is merely a series of calculations, and inspires a sense of awe and genuine curiosity in young readers.  However, I myself am mathematically unsophisticated.     What was the first bit of mathematics that made you realize that math is beautiful?   For the purposes of this children's book, accessible answers would be appreciated.


Say you have a database record, with a field operation, which can have the values checkIn or checkOut. If you have one of the two records, how do you call the other record?  I thought of complement and counter_record, but I would appreciate more ideas.

Is there a word for one side in a pair? In a conversation it would the the interlocutor, but I'm looking for a generic term.


I have a networked computer that is used as a remote print/scan server (which is shared by numerous users) Is there any way I can block the machines internet access while still allowing it to connect to our local network?  edit-  Essentially, its a Windows XP machine shared between myself and 5 others in my department (a workaround to share a scanner without purchasing a network enabled scanner) VNC server is set up on the acting 'server' computer and each user is using a vnc client to access the machine. The machine has its own account and I would like to disable internet access. Is there a way I can disable all internet access from the computer itself without changing group policy settings?

I'm looking for a command (or command line program) to toggle (disable/enable) internet access to the outside world in Windows XP machines. It should temporarily block internet access but leave the LAN working.   I looked for ways to change the DNS, but browsers like Chrome keep their own cache. The machines are configured via DHCP.


Is there a way I can change the way files are currently "sorted by name", to include common non-alphabetical characters like +-_?  I don't mind getting my hands dirty if someone can point me to the script that's responsible for sorting the files (probably a python script?).    @muru helpfully pointed to  as being responsible for sorting filenames in Nautilus' sources. I can't see anything wrong with it given that it uses strcmp, so maybe the problem happens before that because of some string sanitization?  To be clear with the question: I would expect the order {"_name 1", "_name 3", "name 2"} but Nautilus currently sorts these names as {"_name 1", "name 2", "_name 3"}.

What I describe here is not about a problem with my Nautilus. (it is the default behavour)  I understand why Nautilus sorts the Name-column (ascending) so that "6 cats" occuring before "10 dogs"... Its collation sequence is treating a group of numeric-digits as a single number-value and not as individual characters.    That's fine... I can see some value in it, but personally I find it to be confusing,    And I have no idea why Nautilus completely ignores many leading non-alpha-numeric characters.. ie.!@$%^_:"- etc. as typed via as standard US keyboard.. By "ignore", I mean "---two camels" sorts to be immediately above "two camels", as if the "---" didn't exist... (strange !?).    How can I change the default collating sequence?...     gconf-editor /apps/nautilus/list_view shows some sort options, but does not offer a choice of collation option.... I hope there is an way to do this (otherwise Windows Explorer is one-up on this issue :( Windows allows you to choose the conventional collation sequence (via the registry)


Subject.  Or are there any problems/changes in some V20 books? I have always been a fan of weak vampires, but I like V20 more than Revised. I speak about mechanics rather than setting.

I have been interested in Vampire for a few years but have just finally found some friends that would be willing to play such a game and came across older books for the game. As I have never played a roleplaying game and plan on being the game master, I would like to use some of the stories already made for the game.  I have heard that the 20th anniversary is the way to go when it comes to the core book, but it seems much easier to pick up the supplements for older versions and also there are just more supplements for the older versions.  Can I use those those stories with the new rules or will i have to buy an older book. I have right now Alien Hunger and Awakening: Diablerie Mexico.


My 2013 MacBook Pro allowed me to convert audio from old cassette tapes and vinyl to digital by using a 3.5mm Male To Male Stereo Audio Cable from the player's headphone jack into the headphone jack of the MacBook Pro 2013.  In the System Preferences, you could change the headphone jack to function as input rather than output.  Easy. You could use Quicktime to record and other apps.  I found some old vinyl albums that I want to convert to digital but my 2015 MacBook Pro does not seem to be able to do what I mentioned above.  Playing the music  over the air and recording using the internal microphone would not be acceptable.    Suggestions to accomplish this?

I would be very grateful if you could help me clarify - I used to use a software program for recording vinyl mixes on my old Macbook called - Audacity. Recently I've replaced this old Mac with a new Macbook Pro which does not have a phono jack, "line in” port, only a USB port and the same software does not pick up the sound any more, from my vinyl mixes.   Do you know a way to get my new Mac to accept the sound from the original phono outputs of the same mixer to the new USB port? I've already bought the generic cable and can't get it to recognise the new USB port as an official input.   Your guidance is greatly appreciated, as there is no current USB input availabilty option within the generic Mac settings - under "sound" settings. This basically means I can not work out how to accept input, via USB & I can not record, until I solve this problem?


Does 32-bit Windows 7 Home Premium automatically support PAE, for accessible RAM larger than 4GB? Or do I have to manually do some change?

I know that Windows XP 32-bit can be configured, through , to support more than 3.5 GB of RAM.  Is there a good tutorial to do this with Windows 7 32-bit?  As to why I don't simply use 64-bit Windows 7: The software for my Internet connection (cell phone-as-modem) will only work in 32-bit environments.


Am developing a website, I have used many anchor link in menu navigation and given absolute URL. Somewhere I read we can also use relatives URL in menu navigation.  From SEO point of view, which is better for menu navigation absolute or relative URLs?

Our site's navigation links are currently in relative form:     The SEO company I mentioned in my  recommends we change them to absolute links:     This is to "ensure search engines get the correct and working URL for the pages". Is this really something that should be taken into account or is this another case of extra work with no added benefit?


given a list of non-zero integers like, [2, 3, 4, 2]  generate a list of all the permutations possible where each element above reflects its maximum variance (I am sure there is a better way to express this, but I don't have the math background); each element in the above array can be considered a dimension; the above 2 would allow for values 0 and 1; the 3 would allow for values 0, 1 and 2, etc  the result would be a list of zero-based tuples:  [(0, 0, 0, 0), (0, 0, 0, 1), (0, 0, 1, 0), (0, 0, 1, 1), (0, 0, 2, 0)...    and so on till (1, 2, 3, 1)]  the length of the array could vary, from 1 element to x

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


It was a bit weird as I remember it - a boy was lost on a planet, was with a pet, looked a bit like a llama, went under a dome shaped thing that looked like purple trees entwined. He had this egg shaped speak with him (think it was red and white) that he called Mic.  I think it was communicating with the ship that was coming to rescue him.  The Llama creature went into a cave and got eaten by tentacles.  I think the boy eventually got rescued, and I also remember something about faceless humanoid things with wings…. Never been able to find or identify it and I would really like to know what it is and if it’s as weird as I remember it…?

A guy on a space ship picks up a distress call, a boy is stranded on a planet with a hostile environment. He & his crew go to the rescue, stopping on the way to pick up an old man who comes with them. Most of the top of the old guy's skull is metal, from an old injury.  They've various adventures on the way (their ship is boarded by pirates/bandits/hostile forces at one point).  They get to the planet with the boy. They've limited time to save him as the planet is being moved back in time. (I can't remember why) When they find the boy, he's being attacked by giant wasp-type-things.   The boy is injured on the top of his head. The old guy dies protecting him. The boy gets shifted back in time with the planet and - you guessed it - survives, grows up and turns out to be the old guy.  Now that I've remembered some of it, the bits I can't remember are driving me crazy. I'd love to see this again, if I could identify it I might be able to track down a copy.  I'd swear I saw this mid 80's on morning TV, but it I could be out by 5 years either way. Thanks


From time to time I find that when I copy/paste a command from a web page (or from the Terminal window itself) the pasted command is not recorded in bash history. For example, just now I did this:  cd foo     git push --set-upstream origin master cd ../foo2     git push --set-upstream origin master cd ../foo3/     git push --set-upstream origin master cd ../foo4     git push --set-upstream origin master   (Note: I typed the cd commands manually - the git push commands were pasted).  However when I type history I see this:   2008  cd foo  2009  cd ../foo2  2010  cd ../foo3/  2011  cd ../foo4  2012  history   Bash version:  GNU bash, version 4.3.11(1)-release (x86_64-pc-linux-gnu)   Linux version:  Ubuntu 14.04 LTS   Terminal version:  Gnome Terminal 3.6.2   This is kind-of annoying, because for one thing history does not show exactly what I did. Secondly, I can't just up-arrow to recall the command I just pasted.  Why is it doing this, and how can I stop it?

If I perform a sequence of commands like:  $ ls $ grep abc file.txt   and then use the up arrow key to get the previous one, the terminal will show the last cmd (which is the grep here)  But if I do something like this:  $ ls $   grep abc file.txt   where grep is preceded by spaces, pressing up gives ls, not grep.  Why is this?


This morning I got the silver  badge :            ...        Unfortunately, I haven't earned this particular badge yet. I have 318 votes on 124 answers. Then wondered if  had synonyms, like  and so on, but this is not the case — and even if it was, I should have got the badge for some time already.  I saw this old question, back from Jan 2011 ->  - the "official" statement to this old question was :       Our tag storage is denormalized, we have a second table that stores the a postId -> tagId list. For some reason we had a few dupes in there (probably cause android was merged with android-sdk).      That had a cascading effect that caused some tag badges to be assigned early.      I just added a primary key constraint on the denormalized table, so there is no chance of dupe rows anymore.   This bug seems not to completely have been wiped out, perhaps it has returned — in any case, something does not seem completely right. I got an upvote on the  tag yesterday, forcing the system to recalculate, this is the right part.

On Stack Overflow, I have 428  questions answered with a total score of 775 as of the writing of this post.     It seems that this is happening to a lot more people than just me.       (Only possibly related)?


In a typical neural network , bias is usally added like this   v = activation ( w1*x1+ ... + Wb*b)   However, I am not really sure how it is done in convolutional layer. My one thought is that it is added with each convoltional operation for a neuron. Is that correct?

Should we add bias to each entry of the convolution then sum, or add bias once at end of calculating the convolution in CNNs?


From  I used the following codes to add an empty INTENTIONALLY LEFT BLANK page if a section ended in an odd number of pages, as well as if the total document would end in an odd number of pages (because for some reason it doesn't add the blankpage to the last section)  \newcommand*{\blankpage}{% %\setlength{\topskip}{0pt}%    % \setlength{\parskip}{0pt}% \vspace*{\fill} { \centering INTENTIONALLY LEFT BLANK.\par} \vspace{\fill}}  \makeatletter  \renewcommand*{\cleardoublepage}{\clearpage\if@twoside \ifodd\c@page\else \blankpage \newpage \if@twocolumn\hbox{}\newpage\fi\fi\fi} \makeatother  \AtEndDocument{%   \ifthenelse{\isodd{\pageref{LastPage}}}{\null\blankpage}{}}   Now here's my own question: the code made by the famous @DavidCarlisle seems to hint that if a two column setup is used, it would still place the "INTENT...BLANK" part right in the middle of the page. And it did! And then suddenly, it stopped doing it and started placing it on the left side of the page which I would guess to be centered in the left column. So how can I overrule the two columns and still have the sentence placed in the middle? The last page seems to be doing it right even though the \end{multicols} is after that last section.

I have a scrbook document with an openright option, i.e. every once in a while a blank left page appears in the document. Not that I really want to do this, but how could I include the infamous "This page has been intentionally left blank" in those blank pages cleanly, i.e. without too many hacks?  Bonus points for including a different famous quote on each blank page instead of the dull default ;)


This  gave an example of a continuous $f: E \rightarrow F$ which is bijective but has noncontinuous inverse. In the example, neither $E$ nor $F$ was a Banach space, are there any examples where $E$ or $F$ is a Banach space (of course, none exist if both $E$ and $F$ are Banach, by an application of the open mapping theorem).

The Open Mapping Theorem says that a linear continuous surjection between Banach spaces is an open mapping. I am writing some lecture notes on the Open Mapping Theorem. I guess it would be nice to have some counterexamples. After all, how can you appreciate it's meaning without a nice counterexample showing how the conclusion could fail and why the conclusion is not obvious at all.  Let $\ell^1 \subset \mathbb{R}^\infty$ be the set of sequences $(a_1, a_2, \dotsc)$, such that $\sum |a_j| < \infty$. If we consider the $\ell^1$ norm $\|\cdot\|_1$ and the supremum norm $\|\cdot\|_s$, then, $(\ell^1, \|\cdot\|_1)$ is complete, while $(\ell^1, \|\cdot\|_s)$ is not complete.  In this case, the identity $$   \begin{array}{rrcl}     \mathrm{id}:& (\ell^1, \|\cdot\|_1)& \to &(\ell^1, \|\cdot\|_s)     \\                 & x & \mapsto & x   \end{array} $$ is a continuous bijection but it is not open.  I want a counterexample in the opposite direction. That is, I want a linear continuous bijection $T: E \to F$ between normed spaces $E$ and $F$ such that $F$ is Banach but $T$ is not open. This is equivalent to finding a vector space $E$ with non-equivalent norms $\|\cdot\|_c$ and $\|\cdot\|_n$, such that $E$ is complete when considered the norm $\|\cdot\|_c$, and such that $$   \|\cdot\|_c   \leq   \|\cdot\|_n. $$ The Open Mapping Theorem implies that $\|\cdot\|_n$ is not complete.  So, is anyone aware of such a counterexample?


How can I change my username in Minecraft 1.6 or later? , but that method doesn't work anymore since the way the game launches has completely changed. Is it still possible to set your username using a command, script, or anything else?  (Solutions tailored to Mac OS X specifically are appreciated.)

This post pretty much summarizes my question :   I know for a fact that Mac and Linux are both Unix based  And the commands for Linux should work for Mac, but with limited knowledge for programming I couldn't get it to work.  EDIT: Just saw this -  currently working on it


Is there an Upsert API call to create/ update a subscriber in 1 API call? It will save us a lot of resources.

Is there an option to create and Opt-in a user in the same API call?  At the moment I can find it only in 2 separate calls. Create then Opt-in to a keyword.  It will save us a lot of resources.


I'm noob in math. If 0.333(3) is 1/3, 0.666(6) is 2/3, then 0.999(9) is what?  If 3/3 and 0.999(9) is the same, then how can I express one of them without expressing the other?

I'm told by smart people that $$0.999999999\ldots=1$$ and I believe them, but is there a proof that explains why this is?


Hello I have a question regarding resistance. I have a 5v supply and I want it to be brought down to 1v at a certain part in the circuit. How do I Know how much resistance I need to go from 5v to 1v? Thanks - Jack.

How would one go about using a 12 V DC power source to power something which needs 4.5 V DC using resistors? Is there a way to determine how much adding a resistor would drop the voltage?


I was doing first post reviews, and saw a question that I assumed must have been answered before, so I went through the flag process of looking for dupes. However instead of showing me search results where I could assess whether it was a dupe, I was informed I had failed a review audit. Had I been unable to find a dupe I would have actually voted the question up for being high quality, but because I searched first, that search triggered an audit failure.  It seems the search results need to be shown before revealing the question to be an audit. Otherwise doing thorough research is deemed a failure.

Few arguments against it:   Pressing the flag button doesn't mean actually submitting it (as in every test/form). There might be an unknown duplicate, if you assume it's the first post (as you were told) it might be worthy to flag it. You might want to look if someone else thought it was duplicate by "making half way" to flagging it.   Why pressing the flag button makes you fail an audit? I think it shouldn't.  Edit:  The implementation difficulty (fake flagging UI) and the tips about how avoid failing (and reviewing!) by skipping the answer adds some insight, but still doesn't answer the question why it's not a valid review.    Moreover, I would like to add one more,  describes a reviewer that failed an audit while trying to flag a question as off topic. The question was clearly off topic, and still after 1300 views no one flagged it.


All I truly want a package manager for is to install an app in a location of my choice, make symlinks if I want them, and remove everything when I'm done with the app. Keeping track of all the user-modifiable files for each app and saving those when I "remove" would be nice too.  Yet there are 5-10 different package managers each with their own "ecosystem" of apps, and there are also a lot of apps I come across while browsing the web that say "here, download this .tgz!"; sure I'll click, but now I have a .tgz!  Does anything sort of like a "universal" package manager exist? Something with few features, just install and uninstall would be perfect as long as it will install/uninstall whatever I throw at it: .deb, .rpm, .tgz, .gem, etc.  All I want is install/uninstall through a single interface, a la App Store!

There are a lot of language-specific package managers like cpan for perl, cabal for haskell etc. When we want to install some software, it can sometimes be installed from a corresponding repo, with installation instruction just like (say, ) npm install yaxy or cpan something or cabal install something.   These package managers have slightly different syntaxes, they all need root privileges and/or custom setup, or (in case of Yaxy) just a newer version of interpreter (nodejs packaged by Ubuntu was too old to run it).  Is there a wrapper for different package managers that unifies/automates setup for different package managers?  Edit: what I want is a way to execute installation command like that npm install yaxy and make it working without manual installing system npm+nodejs, getting non-functional executable, finding the simplest way to install fresher nodejs on my system, reinstalling...


I understand that environments are very nice where the content is complex.  But for simple cases, the \begin and \end and duplication of the environment name gets quite wordy and dominates the actual content.  Is there a non-environment command to create a matrix, like exists for \frac?  Compare:  \begin{bmatrix}       \chi_2 \\       \chi_3 \end{bmatrix} = \chi_1 + \begin{bmatrix}                              t_2 - t_1 & 0 \\                              t_3 - t_1 & t_3 - t_2                          \end{bmatrix} \begin{bmatrix}                                             \nu_1 \\                                             \nu_2                                        \end{bmatrix}   to a hypothetical  \bcolvec{\chi_2}{\chi_3}        = \chi_1 + \inbmatrix{t_2 - t_1 & 0}{t_3 - t_2 & t_2 - t_1} \bcolvec{\nu_2}{\nu_3}

I would like to define a command which typesets a column vector.  For one vector I can have something like:  \left( \begin{array}{c} a\\ b\\ \end{array} \right)   I would like the command to produce such a vector, for either 2 or 3 arguments. \colvec{a}{b}{c} should produce the same vector as above only with one more entry where \colvec{a}{b} will produce the above vector. How should I do it? I tried to overload a command name but that's impossible.


I have an issue with cycles render where it doesn't seem to be rendering fully the eye just look dotty.    Here is a image of the rendered mesh and eye. I would prefer if it can be fully rendered instead of a dotty look. How can I achieve that?

My model has a clear plastic (or glass) dome with objects inside.  The objects appear dark.  I've tried the glass shader with color 100% RGB, with very small IOR, and using just a refraction shader.    I know Cycles has problems with caustics, but I just want broad illumination to fall clean through the glass.  The light-to-column path can ignore refraction, but is blocked or tremendously attenuated. The camera-column path needs refraction, and seems to work fine anyway.  This demo image offers all optical paths of interest:   light upon object, seen directly light upon object, seen through glass (looks okay) light through glass onto object, seen directly. This is the shadow on the lit side of the column just below the glass tubing.  I expect full illumination, but there is shadow.  There is some light, but it's diffuse light from the floor. light through glass onto object, seen through glass. This     I did at one point try non-progressive rendering, and find extremely coarse light where there shouldn't be shadow, but this is not a practical way to make nice images. I've even tried cranking up certain sampling settings to many thousands, but still get bad noise though less, at the cost of long render times. I  would like to finish my creations sometime before "Star Trek, the Generation After the Next" becomes real life, if you know what I mean.  The next image is an example. I think Transmission in Sampling was 5000, but not sure.    I'm using Cycles in Blender 2.67 on a quad core Linux machine, 16GB RAM. Machine limits have never been a problem for 3D rendering.  Possibly, I screwed up some setting when I made my startup file, and just need to fix it. OTOH maybe this is just a limitation of path tracing, or of the way Cycles does it. If that's the case, what to real-world Blender artists do when they need to produce images on a budget and schedule?  What is the practical real-world fix?


I want to make an exe app that shutdown Windows. It's for starting it from McMyAdmin 2. How can I do it? (I've tried it making this app (), but I get this error:  The system cannot find the file specified    at System.Diagnostics.Process.StartWithShellExecuteEx(ProcessStartInfo startInfo)    at McMyAdmin.TimedEvents.DoExec(String EventData, Boolean SendToConsole, String Args)   Could you help me? Thanks! Javier

What's the best way to shut down the computer from a C# program?  I've found a few methods that work - I'll post them below - but none of them are very elegant. I'm looking for something that's simpler and natively .net.


How to write following inline formula in LaTeX: r~[0,1]

Possible Duplicate:          I have tried using \text{\~{}} to draw a tilde in math mode. However, this only produces a superscript tilde.  I have looked around at many pages such as this one:   and surprisingly, I can't find where to draw a tilde in math mode (not under or above a character - just a single tilde character). If I just use ~, then nothing appears.


I am travelling to Europe from May 7th to 25th. Below is my itinerary:   Italy: 7th to 14th May Czech Republic: 14th to 18th May Belgium : 18th to 21st May Netherlands : 21st to 25th May   I have applied for my visa from Italy, and already got it. The issue is the visa duration is from 5th May to 3rd June and the duration of stay is 15 days, which only covers my trip till Belgium, ie 7th to 21st May. It does not cover the remaining 4 days, and the Italian consulate said they cannot extend.  Can I apply for a visa from the Netherlands consulate? Since my duration of stay and validity will be over by the 21st of May? Or because the visa is from the 5th May to 3rd June, will it count as two active visas?   Since the Italian consulate cannot extend, should I apply for a new visa from the Netherlands consulate?   Also, I have taken a sabbatical from work. What kind of papers would I require for the Netherlands?

My daughter applied at the Italian Consulate in Philadelphia, and they gave her two entries for 20 days (we thought it was for 20 days each entry). She was in Italy 12 days, then went to England for 1 week and flew to Venice to take a 10-day cruise. She couldn't make it because they said she has only 8 remaining days, but she still has a land tour already paid this week.  What can she do? Can she extend the Schengen visa for 12 more days? Right now, she is in Madrid, but next week she has to fly from Barcelona to Paris to start with the tour. What would happen if she decides to take the tour with the expired visa? She is a US permanent resident.


I'm working on Ubuntu 14.04 and suddenly, Ubuntu Software Center stopped working. When I click on icon from launcher, it's blinking. When I try to open it from terminal with the command, 'sudo apt-get remove software-center', I'm getting the following error:  E: Encountered a section with no Package: header E: Problem with MergeList /var/lib/apt/lists/dl.google.com_linux_chrome_deb_dists_stable_main_i18n_Translation-en%5fIN E: The package lists or status file could not be parsed or opened.   Please tell me how to resolve it.  Thanks in advance.

The computer gave me this output in a window:  E: Encountered a section with no Package: header E: Problem with MergeList /var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_natty_main_binary-i386_Packages E: The package lists or status file could not be parsed or opened.   How can I fix this?


I am trying to get a list of subscribers via cursor based pagination. This is my first time using cursor based pagination, so I may be over complicating & I hope you'll identify that if so!  Here is my function for reference:  def get_subscribers():     subscribers = [] # Create empty list for appending collected      url = 'https://api.twitch.tv/helix/subscriptions'      token = refresh_token(config.refresh_token)      headers = {         'Client-id':config.client_id,         'Authorization': 'Bearer {}'.format(token)     }      params = {         'broadcaster_id':config.channel_id,     }      req = requests.request('GET', url, params=params, headers=headers)     response = req.json()     subs = response['data']     next = response['pagination']['cursor']     for sub in subs:         print('Appending {0} to Subscriber List.'.format(sub['user_name']))         subscribers.append(sub)      while subs is not None:         params = {             'broadcaster_id':config.channel_id,             'after':next         }          req = requests.request('GET', url, params=params, headers=headers)         response = req.json()         subs = response['data']         next = response['pagination']['cursor']          for sub in subs:             print('Appending {0} to Subscriber List.'.format(sub['user_name']))             subscribers.append(sub)      return subscribers   Here's an example response on the first request:  {   "data": [     {       "broadcaster_id": "67961343",       "broadcaster_name": "xJOKERx",       "is_gift": false,       "plan_name": "Channel Subscription (xJOKERx): $24.99 Sub",       "tier": "3000",       "user_id": "67961343",       "user_name": "xJOKERx"     },     {       "broadcaster_id": "67961343",       "broadcaster_name": "xJOKERx",       "is_gift": false,       "plan_name": "Channel Subscription (xJOKERx)",       "tier": "1000",       "user_id": "147283917",       "user_name": "killming"     },     {       "broadcaster_id": "67961343",       "broadcaster_name": "xJOKERx",       "is_gift": false,       "plan_name": "Channel Subscription (xJOKERx)",       "tier": "1000",       "user_id": "100417968",       "user_name": "King_gilbster"     },     {       "broadcaster_id": "67961343",       "broadcaster_name": "xJOKERx",       "is_gift": false,       "plan_name": "Channel Subscription (xJOKERx)",       "tier": "1000",       "user_id": "81318617",       "user_name": "ParagonWing"     },   ],   "pagination": {     "cursor": "eyJiIjpudWxsLCJhIjp7Ik9mZnNldCI6MjB9fQ"   } }   Here is an example response on the "final" page:  {   "data": [],   "pagination": {     "cursor": "eyJiIjp7Ik9mZnNldCI6MTYwfSwiYSI6eyJPZmZzZXQiOjIwMH19"   } }   So what I'm doing is making my initial request then saying while the list is not None continue making requests while using the last cursor for offset.  The problem with this is the list is never None. What condition could be met for this to stop the while loop?   I am also open to alternatives not requiring a while loop.

For example, if passed the following:  a = []   How do I check to see if a is empty?


how to switch linux distros without loosing data. I am using Kubuntu kde plasma and it stucks sometimes. For gaming it is not good.

Recently I installed Ubuntu 12.10 x64 Server Edition on my PC. Unfortunately, I attempted to install a lightweight desktop but due to the fact that I have an old graphics card, the PC does not perform so well. I am thinking of re-installing an Ubuntu version but I do not want to lose the contents in my home folder. Is there any way to do that with a Live CD?


What's the difference between "state" and "country"   Why is it the Arab states but some Asian countries? Are the two words interchageble?

I came across an article talking about the difference between state and country, when they mean nation, like ,  and .  The article says that the USA and the UK can be referred to as country while North Korea can only be referred to as state.  The rationale behind that is     country means people with citizen rights + elected government + land   while     state means only government.   Because in my native language, there is no difference between state and country when they are translated as nation, I am curious to know whether the point the article tries to make is true or not, or to what extent it is true.    Edit:  The people in Libya are now fighting for their rights. When they say we love Libya, they certainly do not refer to Great Socialist People's Libyan Arab Jamahiriya.  How to distinguish that Libya from the GSPLAJ? According to the article, the former may be called country while the latter may be called state.


Many people have mentioned that the difference between StringBuffer and StringBuilder in Java. StringBuffer contains synchronized methods. And people say things like "if a buffer is used by many threads, use StringBuffer." But is the use of StringBuffer really going to guarantee "thread-safety"?

What is the main difference between StringBuffer and StringBuilder? Is there any performance issues when deciding on any one of these?


I want to move all the *.xxx file created in a directory to another directory. But, I want that as soon as the files are created, they should move to another directory. Please Help. Thanks in advance.

There is a directory A whose contents are changed frequently by other people.  I have made a personal directory B where I keep all the files that have ever been in A.  Currently, I just occasionally run rsync to get the files to be backed up from A to B. However, I fear the possibility that some files will get added in A, and then removed from A before I get the chance to copy them over to B.  What is the best way to prevent this from occurring? Ideally, I'd like to have my current backup script run every time the contents of A get changed.


This problem is really annoying me and I have no clue why it occurs.  I have an Asus n56vv laptop with 8GB of RAM running Windows 8.1 x64, and here's the problem: often when I run certain games or applications I receive the following warning popup:     Close programs to prevent information loss   Your computer is running low on memory, save your files and close these programs:"   Followed by the program I was currently running.  Now, this would be perfectly acceptable if I really was running out of memory, but this is NEVER the case. Every time this happens I check the task manager and about half of the memory is unused (~4GB). Also, this tends to happen even on old/tiny programs that definitely don't require a large amount of memory. For example: it regularly happens with Worms Armageddon, a game from 1999 which requires 32MB of RAM.  So clearly it's not really a "low memory" problem, something else is going on here, in fact  if further proof is needed, let me testify that I always dismiss the warning and continue using the application and I never ran out of memory ever.  Everywhere I search online it is stated that this is caused by too little memory being assigned to the Page File, but I tried changing it and it doesn't seem to make a difference, in fact every time I check the PageFile used is always the minimum, since theres enough real RAM in the system that nothing ever needs to use the PageFile.

I keep getting this annoying low memory warning/prompt to close games I play. It happens very often and I still have ~6 gigs of ram free. I disabled virtual memory because it was putting stuff on the pagefile when I had 10 gigs free ram so that spiked my disk usage.  Is there any way to disable this warning? I have 16GB ram so it shouldn't be an issue. I would prefer to keep pagefiles off because my HD is very loud so it's nice to keep it spun down as much as possible.  I don't want to disable it completely. Ideally, I would like it to go off when I have ~2GB left rather than 6, but if this isn't viable, I may just disable it completely.


Doing some close vote reviews today, I came across an audit question that I (arguably) failed. While looking over the question, I noticed an extraneous semicolon in the "STOP!" box at the very end.

There is a (very minor) typo in the Close Votes review audit failure message. The message is presented as follows:  STOP! Look and Listen. This was an audit, designed to see if you were paying attention. You didn't pass. There are no major problems with this question. You should click Leave Open, or make minor corrections via Edit. Don't worry, we've already handled this post appropriately – but please take a minute to look it over closely, keeping in mind the guidance above.;  The ; at the end is a typo and is in the actual message that was displayed.


I think this should be fairy straightforward. I am trying to set the contents of a kml file as a scalar (called $kml). At the moment it only stored the first line of kml. How can I make it ignore line breaks and read in the whole file?  I currently have:   $kml = "Scotland_one_inch_1st.kml";  open INPUT, "$kml"; $content = <INPUT>; close INPUT;   thanks

I have a small text file that I'd like to read into a scalar variable exactly as it is in the file (preserving line separators and other whitespace).  The equivalent in Python would be something like  buffer = ""  try:     file = open("fileName", 'rU')     try:         buffer += file.read()     finally:         file.close() except IOError:     buffer += "The file could not be opened."   This is for simply redisplaying the contents of the file on a web page, which is why my error message is going into my file buffer.


How to find orbit of bent light in the simplest gravity model by solving the null geodesic equation either by Newton's physical or by Einstein's GR?    To compare we have the simplest model of a two body problem for planetary motion.. (without any Lagrange points of Three Body gravitational dynamics and more)

I understand that a black hole bends the fabric of space time to a point that no object can escape.   I understand that light travels in a straight line along spacetime unless distorted by gravity. If spacetime is being curved by gravity then light should follow that bend in spacetime.  In Newton's Law of Universal Gravitation, the mass of both objects must be entered, but photon has no mass, why should a massless photon  be affected by gravity in by Newton's equations?  What am I missing?


Consider:  b = (int) a;    // C-like cast notation b = int (a);    // Functional notation

A question related to :  What cast syntax style do you prefer in C++?   C-style cast syntax: (int)foo C++-style cast syntax: static_cast<int>(foo) constructor syntax: int(foo)   They may not translate to exactly the same instructions (do they?) but their effect should be the same (right?).  If you're just casting between the built-in numeric types, I find C++-style cast syntax too verbose. As a former Java coder I tend to use C-style cast syntax instead, but my local C++ guru insists on using constructor syntax.  What do you think?


I have an algorithm to calculate pi. However, my console can only display a certain precision value. How can I make it display more digits? I was thinking of using std::to_string() but it only displays one more decimal place. In what way can I make it display more digits? This is my algorithm: double pi15(int precision){     double output = 0;          for (int n=0;n<=precision;n++){         output += (exp(-1.0,n%2)/exp(1024.0,n))*(-(32.0/(4.0*n+1.0))-(1.0/(4.0*n+3.0))+(256.0/(10.0*n+1.0))-(64.0/(10.0*n+3.0))-(4.0/(10.0*n+5.0))-(4.0/(10.0*n+7.0))+(1.0/(10.0*n+9.0)));         std::cout << std::to_string(output/64) << std::endl;     }     return output/64; }

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


I'm using MySQL Community Server 5.7.15-log and MySQL Connector/ODBC 5.3.6 on Windows 2012 and getting a lot of these messages:     [Note] Aborted connection X to db: 'Y' user: 'Z' host:   'localhost' (Got an error reading communication packets)   I have max_allowed_packet set to 1G:  mysql> SHOW GLOBAL VARIABLES LIKE 'max_allowed_packet'; +--------------------+------------+ | Variable_name      | Value      | +--------------------+------------+ | max_allowed_packet | 1073741824 | +--------------------+------------+ 1 row in set (0.14 sec)  mysql>      Any advice?

I get this warning in mysql,   [Warning] Aborted connection 21 to db: 'MyDB' user: 'MyUser' host: 'localhost' (Got an error reading communication packets)   I have been through few topics in google and according to some suggestion I increased the max_allowed_packet from 128 to 512 to 1024 still the same behaviour.   I am using Drupal 7, and yes there are lots of blob data types, but 1024 Mb of max_allowed_packet should be enough in my opinion.  Any other workaround how to overcome this warning ?  EDIT:  Added some settings as @Rolando's suggestions/answer, I still get the same warning.  My mysql config looks like this:  [client] port        = 3306 socket      = /tmp/mysql.sock default-character-set = utf8  [mysqld] port        = 3306 socket      = /tmp/mysql.sock skip-external-locking key_buffer_size = 16K  max_allowed_packet = 1024M  table_open_cache = 128  sort_buffer_size = 64K read_buffer_size = 256K read_rnd_buffer_size = 256K net_buffer_length = 2K thread_stack = 192K # Query cache disabled thread_cache_size = 8 myisam-recover = BACKUP max_connections = 100 thread_concurrency = 10 tmp_table_size = 128M max_heap_table_size = 128M log_error                = /var/log/mysql/mysql-error.log log_slow_queries        = /var/log/mysql/mysql-slow.log long_query_time = 2  log_warnings = 2  server-id   = 1 binlog-format = row replicate-same-server-id = 0 auto-increment-increment = 2 auto-increment-offset = 1 log_bin = mysql-bin log-slave-updates relay-log=mysqld-relay-bin expire_logs_days        = 10 max_binlog_size         = 100M  innodb_data_home_dir = /var/db/mysql innodb_data_file_path = ibdata1:10M:autoextend innodb_log_group_home_dir = /var/db/mysql innodb_buffer_pool_size = 8G character-set-server = utf8 #innodb_additional_mem_pool_size = 2M innodb_log_file_size = 2047M innodb_log_buffer_size = 32M innodb_flush_log_at_trx_commit = 2 innodb_thread_concurrency = 8 innodb_lock_wait_timeout = 50 innodb_flush_method = O_DIRECT  [mysqldump] quick quote-names max_allowed_packet = 16M default-character-set = utf8  [mysql] default-character-set = utf8  [myisamchk] key_buffer_size = 32M sort_buffer_size = 32M  [mysqlhotcopy] interactive-timeout  [mysqld_save] syslog   My application uses only InnoDB, but there are few database like mysql, which came with the standard mysql installations are only the ones which uses MyISAM engine type, I guess that should not be my concern though.  As you can see I have replication too, the warning is the same one in replicated server too, whose config is identical as this.


I hope to seek some advice on marrying my partner who is from South Africa. We have been together 2 years and she has visited me twice in the UK where I am born and lived my whole life. Am I allowed to marry her now whilst she is here but she is only on a visitor visa and I want to surprise her.

I am planning to go to the UK with a standard visitor visa.  I will meet my girlfriend there. If we all of a sudden decide to marry, can we?   My girlfriend is Lithuanian who just works and lives there; she doesn't have a residence permit. I am a Palestinian who lives in Lebanon


Basically I am remaking snake for a high school computer science project. I am trying to add a sound effect every time the the snake and the ball hit. I just need to put in the sound at this point. Which classes should I use for sound that are up to date in java and where I can play the sound whenever I need it.

I want to be able to play sound files in my program. Where should I look?


Mitosis is a complex mechanism that, through mutations and crossover, determines how a chromosome is composed. But at that point, the number of chromosomes is already determined: how can this number evolve through generations? What mechanism is involved?

I am aware of the basics of evolutionary theory, however I don't understand how mutations can add genes over time.   Am I correct in thinking that creatures within the same species who mutate to have an additional gene in their genome would normally be infertile?  Or am I misunderstanding that?  Can someone explain the process of the creation of genetic material through evolution?  Citation to a decent academic paper or book on the matter would be appreciated too.


I have a file called -.  I want to display its contents.  One way is to do  cat ./-   since cat - reads from standard input. However, why are cat "-" and cat '-' also interpreted by the shell as cat -?

I downloaded  to my webserver and unzipped it.  It contains a folder named -. I assumed I know how to deal with that, but I don't.  I tried cd -- -, but that doesn't have the desired effect. Using quotes doesn't seem to affect it either. I put slashes all over the place, to no avail.  What's the proper way to change into this folder?


I downloaded Chrome deb package from official website. Whet I open using software center and click install, the button shows "installing" and reverts in a few seconds. Running 16.04

. An update has been issued. If you still cannot install, ensure you have updated fully, and then restart your computer.   I am trying to install downloaded DEB packages. Each time, I see a warning like this:    And clicking install just loads and nothing changes.  This shows for all the packages I try and install. How can I install a package?


here's the entire processing file -  float camX = 0; float camY = 0; float camZ = 0; float camS = 1; float camA = 0;  float dist(float x,float y){   return sqrt(pow(x,2)+pow(y,2)); } float angle(float x,float y){   if(x<0){         return (3*PI/2)-atan(y/x);     } else {         return (PI/2)-atan(y/x);     } }    class Vert{   float x;   float z;   Vert(float x, float z){     this.x=x;     this.z=z;   }   float getX(){     return x;   }   float getZ(){     return z;   } } class Shape{   float x;   float y;   float z;   ArrayList<Vert> verts;   float h;  Shape(float x,float y,float z,ArrayList<Vert> verts,float h){    this.x=x;    this.y=y;    this.z=z;    this.verts = verts;    this.h = h;  }  float getX(){    return x;  }  float getY(){    return y;  }   float getZ(){    return z;  }  ArrayList<Vert> getVerts(){    return verts;   }  float getHeight(){  return h; } ArrayList<Vert> getSlice(float sy){    if(sy>=y&&sy<=y+height){       return verts;     } else {      return null;      } }  }   ArrayList<Shape> shapes;   Vert transVert(float vx,float vy,float vz,float cx,float cy,float cz,float cs,float ca){   float a = angle(cx-vx,cz-vz);   float d = dist(cx-vx,cz-vz);   println(a+" , "+d);   return new Vert((width/2)+(cx+sin((a+ca))*d*cs),(height/2)-(cz+cy+vy+cos((a+ca))*d*cs)); }   void drawSlice(float sy,float cx,float cy,float cz,float cs,float ca){   for(int si = 0;si < shapes.size();si ++){     Shape shape = shapes.get(si);     ArrayList<Vert> slice = shape.getSlice(sy);     beginShape();     for(int i = 0;i < slice.size();i ++){       Vert vi = transVert(slice.get(i).getX()+shape.getX(),sy+shape.getY(),slice.get(i).getZ()+shape.getZ(),cx,cy,cz,cs,ca);       vertex(vi.getX(),vi.getZ());     }     endShape(CLOSE);   } }  void drawSpace(float y1,float y2,float res,float cx,float cy,float cz,float cs,float ca){    for(float sy = y1;sy < y2;sy += res){      drawSlice(sy,cx,cy,cz,cs,ca);    } }  void setup(){   size(400,400);   ArrayList<Vert> vs = new ArrayList<Vert>();   vs.add(new Vert(-50,0));   vs.add(new Vert(0,-50));   vs.add(new Vert(50,0));   vs.add(new Vert(0,50));   shapes.add(new Shape(0,0,0,vs,20));   shapes.add(new Shape(100,0,50,vs,20)); } void draw(){   background(255);   drawSpace(-10,30,5,camX,camY,camZ,camS,camA); }   i'm getting nullpoint exceptions at the shapes.add lines, but not the vs.add lines? is the spaes array somehow out of range? i need it to be a public arraylist  i've been having lots of trouble with arraylists that i've never had before, hence why i'm using such a messy method of adding individual elements instead of doing it in one line- so i guess any advice would be useful - thanks

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


I have recently dual boot'd my new rig for my data science stuff. So yea...I'm purely new here Ubuntu (Tho. I hear'd Linux/Ubuntu already lol). I'm currently running an Ubuntu 20.04 LTS with a kernel ver. of 5.4.0-42-generic. As of the moment, I'm running with an ethernet cable and ofc problems with regards to installing the ethernet drivers from Realtek. Firstly, I checked the network description which indicates a network unclaimed... $ sudo lshw -C network *-network UNCLAIMED           description: Ethernet controller    product: RTL8125 2.5GbE Controller    vendor: Realtek Semiconductor Co., Ltd.    physical id: 0    bus info: pci@0000:05:00.0    version: 04    width: 64 bits    clock: 33MHz    capabilities: pm msi pciexpress msix vpd cap_list    configuration: latency=0    resources: ioport:f000(size=256) memory:fc500000-fc50ffff memory:fc510000-fc513fff  As I scoured in previous forums, you can easily download the drivers from this -> . I DID! the steps from the README file only to hit a road block yet again. By running the autorun.sh file from the command line, it just says $ sudo ./autorun.sh Check old driver and unload it. Build the module and install ./autorun.sh: 31: make: not found  I give it a shot find out my ethernet card and it says $ lspci -knn | grep Eth -A3 05:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8125 2.5GbE Controller [10ec:8125] (rev 04)     Subsystem: ASUSTeK Computer Inc. RTL8125 2.5GbE Controller [1043:87d7]     Kernel modules: r8169 06:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:2484] (rev a1)  I'm literally needing some help or someone who can thoroughly guide me on how to 'install' the ethernet drivers on this one. :C Regards, astro_cgha

So I did a fresh install of Ubuntu 20.04 on a computer with the new RTL8125B Realtek network card and I cannot get the network to work. I was very suprised since this is supposed to be the new feature of the 5.4 kernel (I have 5.4.0-26-generic installed). Does anyone have any idea on how to get it working? Thank you. $ lspci -knn | grep Eth -A3 06:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8125 2.5GbE Controller [10ec:8125] (rev 04) Subsystem: ASUSTeK Computer Inc. RTL8125 2.5GbE Controller [1043:87d7] Kernel modules: r8169 07:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 470/480/570/570X/580/580X/590] [1002:67df] (rev e7)  $ dmesg | grep -i r8169 [    0.911236] r8169 0000:06:00.0: unknown chip XID 641


I've had this problem for a while. When I import a vector object to Photoshop, it doesn't have the smooth curve that's needed. I believe this is a feature that can be controlled, but I can't find anything to help me. Could someone tell me how I can fix this?

I am using Adobe CC(2015) latest version and the behaviour of the smart objects isn't normal. When I paste a vector from Illustrator to Photoshop, the vector looks low quality or rough.   ORIGINAL  IN PHOTOSHOP   However, if I click over the smart object layer(in Photoshop)and this is opened in Illustrator, the vectors looks as the original one.   VECTOR OPENED IN ILLUSTRATOR FROM PHOTOSHOP SMART OBJECT   How can I solve this?


My MBP runs very hot and I thought the fans were broken because there's no air blowing out the back and no fan noise as I used to hear in my older MBP so I installed  Apparently, the fans are running mostly at around ~1200rpm and the temps are 50-55c, is this normal? should I modify the settings? I can even feel the heat just from using the keyboard.

My MacBook has been overheating for over a year now. More recently it has begun to perform alarms and automatic shutdowns.  Also on startup there is (a moment) where I see a black screen with source code of some sort before the screen resumes with the grey bootup screen.  Today I have installed Mac Fan Control, and realize that the fan still works on my computer, hopefully I can prevent anymore burning (smell) from the laptop. Previously I had smcFanControl but it stopped pushing the fan above 2000 so I just thought that my fan didnt work for a long time  I also had my laptop/fan cleaned with air so I dont believe there is any blockage recently.  I have a screenshot showing the current temperatures, I would like to know what temperatures are ideal, safe or average and I will do my best to prolong the life of my laptop by keeping my fans spinning above 2000+ and being more mindful and keeping Activity Monitor open!    macOS Sierra 10.12.5 (16F73) MacBook Pro (13-inch, Late 2011) Processor 2.4 GHz Intel Core i5 Memory 4 GB 1333 MHz DDR3 Graphics Intel HD Graphics 3000 384 MB


I am the only user on my PC and do not want to enter my password.  How do I disable?  I do not want to enter a password every time my screen saver starts or I install any aps.

Here are my circumstances:   I am running Ubuntu 12.04. I have one user account.   I absolutely hate the password requirement. How do I disable this requirement such that my Linux computer will behave more like Windows in this respect? I do not want to hear that I shouldn't this because it is not secure. This is my desire so the concern of security is effectively null and void.


I think I have just lost a USB stick. Is there a way to view all the file transfers made from a PC to the external drive, so I can double check everything that was on the drive? Very unlikely, but there are important files that could have been on it.  Does the event viewer log these type of events?  Any help would be appreciated, think I'll stick to cloud storage from now on...

Is it possible to find out which files are transferred to an external usb flash drive in certain period of time?   To be more clear. If I/someone have a flash drive and take some data from me. How do I know which files are copied? Finding out file copy hostory could be also a work around.


My original problem is the following: given the ring $$ R:=\left\{\begin{bmatrix}q & 0\\ r & s\end{bmatrix}\;:\;q\in\Bbb Q,\;r,s,\in\Bbb R\right\} =:\begin{bmatrix}\Bbb Q & \Bbb 0\\ \Bbb R & \Bbb R\end{bmatrix} $$ I have to show that it is a left artinian ring, i.e. seen as a left module on itself, $_RR$, is artinian, i.e. the lattice of its submodules $\mathcal{L}(_RR)$, partially ordered by inclusion $\subseteq$ is an artinian poset.  So I tried to figure out how the submodules of $_RR$ are, and after some elementary computation I deduced that $$ \mathcal{L}(_RR)=\left\{\begin{bmatrix}A & 0\\ B & C\end{bmatrix}\;:\;A\;\mbox{is a $_{\Bbb Q}\Bbb Q$-submodule},A\subseteq B,\\ \;B,C\;\mbox{are $_{\Bbb R}\Bbb R$-submodules}\right\} $$ thus a descending chain of submodules of $_RR$ is of the type $$ \begin{bmatrix}A_0 & 0\\ B_0 & C_0\end{bmatrix}\ \supseteq \begin{bmatrix}A_1 & 0\\ B_1 & C_1\end{bmatrix}\ \supseteq\cdots\;\;\;\;\;\;\;\;\;(*) $$ where $\{A_i\}_{i\ge0}$ is a descending chain of $_{\Bbb Q}\Bbb Q$-submodules and $\{B_i\}_{i\ge0},\;\{C_i\}_{i\ge0}$ are descending chains of $_{\Bbb R}\Bbb R$-submodules. Thus if $_{\Bbb Q}\Bbb Q$ and $_{\Bbb R}\Bbb R$ were artinian, then $(*)$ would be stationary, thus my ring $R$ would be left artinian. Is my argument correct? How can I prove that $_{\Bbb Q}\Bbb Q$ and $_{\Bbb R}\Bbb R$ are artinian modules?

Let $R$ be the subring of $M_2(\mathbb{R})$ defined by $$R=\left\{\begin{pmatrix}a&b\\0&d\end{pmatrix}\mid a\in\mathbb{Q},b,d\in\mathbb{R}\right\}$$  Show that $R$ is right-Artinian but not left-Artinian.  The "obvious" approach to show it is not left-Artinian is to find an $A\in R$ such that $$RA\supset R(A^2)\supset R(A^3)\supset\dots$$  is an infinite decreasing chain of proper left submodules of $R$ (as a module over itself). However, after spending a lot of time in this endeavor I've come to the conclusion that no such element $A$ exists (I can post a proof if anybody is interested but it'd be long and not worth the time for me otherwise). Does anybody have an idea for another approach I can take to this? I have no idea what else submodules of $R$ would look like.


I met some odd usage of preposition "for". I guess it's old style, or high style. I give examples for better understanding:  About this time legend among the Hobbits first becomes history with a reckoning of years. For it was in the one thousand six hundred and first year of the Third Age that the Fallohide brothers Marcho and Blanco, set out from Bree.  J.R.R. Tolkien  But the Hobbits may have learned it direct from the Elves, the teachers of Men in their youth. For the Elves of the High Kindred had not yet forsaken Middle-earth...  J.R.R. Tolkien  In the study of logic, we do not so much look at these kinds of reasoning: instead, logic concerns itself with reasons for believing something instead of something else. For beliefs are special.  Routledge. Logic. An Introduction. It would be great, if someone explain me how  to understand the authors in these cases. Thank you.

I am not a native speaker. On a previous question of mine, I thanked for an answer by saying:     So the phrase is not an idiom, since it is applied in its literal sense.   I consciously chose since over because, because — well, I like that usage of since, even though I know that some (native speakers) don't like it. Nonetheless, that choice got me thinking for a while, and it occurred to me that I even could have used more alternatives, namely as or for, without changing the meaning.   So, on a general note, here are the alternatives:        Statement A (is true), because statement B (is true).   Statement A (is true), since statement B (is true).   Statement A (is true), as statement B (is true).   Statement A (is true), for statement B (is true).      Are these completely interchangeable? Or interchangeable in certain situations? Or can you point out any (not-so-)subtle differences between any of them? Are there even more synonyms?


Show that $(1-2^{1-z})\zeta(z)=\sum\limits_{s=1}^\infty \frac{(-1)^s}{s^z}=\frac{1}{\Gamma(z)}\int\limits_{0}^\infty \frac{t^{z-1}}{e^t+1}dt$ for Re$(z)>0$.  Not sure how to get started on this, we have covered some of the formulas for the $\zeta$ function but I don't really have any intuition regarding them.

I want to show that we can continue Riemann's zeta function to Re$(s)>0$, $s\neq 1$ by the following formula \begin{align} (1-2^{1-s})\zeta(s)&=\left(1-2\frac{1}{2^s}\right)\left(\frac1{1^s}+\frac1{2^s}+\ldots \right) \\ &=\frac1{1^s}+\frac1{2^s}+\ldots -2\left(\frac1{2^s}+\frac1{4^s}+\ldots \right)\\ &=\frac1{1^s}-\frac1{2^s}+\frac1{3^s}-\frac1{4^s}+\ldots  \\ &=\sum_{n=1}^\infty (-1)^{n-1}\frac1{n^s}. \end{align} In order to do that, I need to show that the series converges for Re$(s)>0$, except $s=\frac{2k\pi i}{\ln 2}+1$, $k\in \mathbb{Z}$, which are removable singularities. Any ideas on how to do that?


I watched the Bleach anime first, and I heard that the continuation is only in the manga. So if it's possible, I'd like to know which chapter corresponds to the end of the anime to start reading. I don't want to dig through and reread the chapters which overlap with the anime.

I want to watch Bleach, but the anime has a lot of filler content not in the manga. I'd rather not watch the filler content and only watch the episodes which are directly related to the plot. To be clear, I'm defining a filler episode as one which is not based on any story in the manga or based on extra manga chapters which have nothing to do with the overarching story.  Which episodes are filler?


The title says it all. This is not homework. Haven't made much progress - I know that with $K=F_2(t)$, $L=K(\sqrt t)$ (i.e. adjoining the square root of $t$ to the function field with coefficients in the finite field on two elements), $L/K$ is not a separable extension. This suggests looking at extensions $M$ of $L$ that are not normal over $K$. Does such an extension exist? Or is there a better example?

I was asked to prove or disprove that if a field extension is not normal then it is separable. I can't see why this would be true so I want to disprove it with an example of a non-normal inseparable field extension. I am wondering if there is a simple example of such an extension, or even any examples at all. I know that any inseparable extension $L/K$ has to be such that $K$ is infinite and of positive characteristic, so a good place to start would be $K=\mathbb F_p(T)$, but I'm unsure how to prove that an extension of this is inseparable, and even unsure how to come up with a non-normal example, since my usual approach is to exploit that $K$ is a subfield of $\mathbb R$ (so e.g. $\mathbb Q(\sqrt[3]2)/\mathbb Q$ is not normal as $x^3-2$ has $\sqrt[3]2$ as a root but the other two roots are in $\mathbb C \setminus \mathbb R$ and $\mathbb Q(\sqrt[3]2)\subset \mathbb R$). However with $K$ as above, $K \nsubseteq \mathbb R. $


I have finished the game, but I've got a gap in my inventory:    What am I missing?

I've finished the game, got all the items except one. This is the one to the right of the green shark fin. What and where is it?


How can I install Windows 7 and remove Ubuntu 14.04? I do not have dual boot or anything, when I first installed Ubuntu on my "experiment desktop", I formated my entire harddrive.  Any help with this is very much appreciated, the answers I found so far by searching for it, almost everybody mentioned how to do it by dual boot.

I have absolutely no experience with Linux, and I desperately need to get my computer back up and running again with Windows.  How do I remove Ubuntu and reinstall Windows?    Editor's note: many of the answers are about removing Ubuntu from dual-boot but keeping Windows (which is a bit complicated), while other answers are about removing Ubuntu from single-boot (which is easy: basically just format the disk while installing Windows). The question as written is ambiguous between dual-boot or single-boot.


Experienced users should not be shown the top-of-screen pop-down message reminding them to upvote a question if they find it helpful.  This is particularly annoying when that reminder comes right after closing out the login pop-down message after arriving at a random stackexchange site from Google.  This network should not slow down and annoy experienced users with excessive messages. This message, in particular, is only useful to new users.

My reputation in StackOverflow is among the top 1% of users. I'm not as active as I used to be, but I still come back to the site from time to time. Unfortunately, I find that when I do return, I get a message "Welcome back, you can upvote!" To be frank, this reminds me of the paperclip on Word 98. I am well aware that I can upvote (or edit comments, or delete posts, or downvote, or undelete posts, or flag, or... pretty much everything)  If reputation could we either get rid of the message entirely or at least get rid of the "you can vote" part of the message?  While I'm at it, I would also appreciate it if a high rep level meant that I could skip the "You've down voted someone! Please add a suggestion to try to make it better." Once again, I am more than aware how the system works, I do not need JavaScript annoying me about it.


I have a program which I am writing which in one particular case enters every if-statement. But it isn't supposed to. I govern whether or not it should do just that by a boolean value which i send with the reference to the method. But it still won't work properly.  Here is the code snippet of the two methods included:      void tilStasjon(String startStasjon){          boolean sjekkStasjon=true;         while(sjekkStasjon){             System.out.println("Vennligst tast inn til-stasjonen: ");             String sluttStasjon=input.next().toLowerCase();             if(stasjonerMap.containsKey(sluttStasjon)){                 if(sluttStasjon!="ringen"){                     sjekkStasjon=false;                     beregnRuter(startStasjon, sluttStasjon);                 }             }else{                   System.out.println("Stasjon ikke funnet.");                 sjekkStasjon=true;             }         }     }      void beregnRuter(String startStasjon, String sluttStasjon){          Stasjon til=stasjonerMap.get(startStasjon);         Stasjon fra=stasjonerMap.get(sluttStasjon);         ArrayList<Linje> fraLinjeListe=new ArrayList<Linje>(fra.linjeList);         ArrayList<Linje> tilLinjeListe=new ArrayList<Linje>(til.linjeList);         int tilStasjonsNummer, fraStasjonsNummer;         int retning;         double tid= 0.0;         String endeStasjonsNavn;         boolean overgang=false;          tilStasjonsNummer=0;         fraStasjonsNummer=0;          for (int i = 0; i < fraLinjeListe.size(); i++) {             for (int j = 0; j < tilLinjeListe.size(); j++) {                 if(fra.linjeList.get(i).equals(til.linjeList.get(j))){                     System.out.println(fra.linjeList.get(i).linjeNummer);                     Linje aktuellLinje=linjerMap.get(fra.linjeList.get(i).linjeNummer);                     tilStasjonsNummer=aktuellLinje.stasjonsNummer(til);                     fraStasjonsNummer=aktuellLinje.stasjonsNummer(fra);                     retning=tilStasjonsNummer-fraStasjonsNummer;                     tid=beregnTid(retning, overgang, aktuellLinje);                      endeStasjonsNavn=aktuellLinje.endestasjon(retning);                     System.out.println("Ta T-bane linje " + aktuellLinje.linjeNummer + " fra " + startStasjon + " til " + sluttStasjon + " i retning " + endeStasjonsNavn + ". Estimert reisetid: " + tid);                              }                }         }     }   Below here is the method where the problem occurs. It enters both the outer if and else-if. Why is that?      double beregnTid(int retning, boolean overgang, Linje aktuellLinje){         double tidMellomStasjoner;         double tid=0.0;         int absRetning=Math.abs(retning);         double tidOvergang;          if(overgang=false){             if(aktuellLinje.type==0){                 System.out.println(absRetning);                 tidMellomStasjoner=1.8;                 tid=tidMellomStasjoner*absRetning;             }else if(aktuellLinje.type==1){                 tidMellomStasjoner=1.4;                 tid=tidMellomStasjoner*absRetning;             }         }else if(overgang=true){             if(aktuellLinje.type==0){                 System.out.println("Test");                 tidOvergang=7.5;                 tidMellomStasjoner=1.8;                 tid=(tidMellomStasjoner*absRetning)+tidOvergang;             }else if(aktuellLinje.type==1){                 tidOvergang=5.0;                 tidMellomStasjoner=1.4;                 tid=(tidMellomStasjoner*absRetning)+tidOvergang;             }         }         return tid;      } }

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?


Using tar, is it possible to compress stdin text and have the compressed data appear in stdout? Example:  $ echo "test" | tar c -  <compressed blob here>   I'm using macOS Mojave.

I'm going to tell you exactly what I need in order to clarify the cryptic question in the title. I'm currently making scheduled MySQL backups of all my databases with something like:  mysqldump ... | gzip -c > mysql-backup.gz   This is ok, but I'm willing to make a separate file for each single database, since that will make it easier to take a look at dumped data or restore a single database:  for db in $dbs; do mysqldump ... $db | gzip -c > mysql-backup-$db.gz; done   I'd like to store all of the dumps for each single backup in a single .tar file, i.e. mysql-backup.tar.gz with all the dumped databases inside. I know I can simply leave .sql files uncompressed and then tar -cz *.sql, but 1) I'm searching for a way that doesn't need to temporarly store big files. In my current script, in fact, mysqldump is piped into gzip, so no big file is created.   2) Is there a similar way in which I can create .tar.gz from stdin?   3) Is tar -c *.sql.gz eqivalent to tar -cz *.sql?