I am given the following convergent series asked to find the value of:  $$\sum_{n=1}^{\infty} \left(\frac{4n}{(n^4+n^2 +1)}\right)$$  According to Sum calculators, I have found the value to be 2. Though, I don't know what approach to take to prove this. To aid us in the question, we've been given the following hint:   $$n^4 + n^2 + 1 = (n^2 + 1)^2 − n^2$$   Can someone point me in the right direction?

I am trying to re-learn some basic math and I realize I have forgotten most of it.     Evaluate $$\sum_{n=1}^{\infty} \frac{n}{n^4+n^2+1}$$   Call the terms $S_n$ and the total sum $S$.  $$S_n < \frac{1}{n^3} \Rightarrow \sum_{n=1}^{\infty} \frac{n}{n^4+n^2+1} = S <  \infty$$  $$S_n = \frac{n}{n^4+n^2+1} = \frac{n}{(n^2+1)^2-1}$$  It has been more than a few years since I did these things.   I would like a hint about what method I should try to look for?  Thanks.


I'm looking for Latex command of the symbols that are usually put at the end of a paragraph. For example, it maybe a flower in this below image.        Could you please inform me where to find such symbols?

I'm looking for a free ornaments font. I know about  and pifont. Where can I find more glyphs?


I am very new to Machine Learning, and this is my first project on which I am working. I am trying a binary classification problem, trying to predict claim(yes/no) from an insurance dataset. In my dataset, I have about 7% positive class (1534 Positive datapoints, 21076 Negative datapoints). I have 7 features (2 numerical, 5 categorical).   My model is giving the following performance metrics:               precision    recall  f1-score   support            0       0.95      0.70      0.81      6311           1       0.12      0.52      0.19       472 avg / total       0.89      0.69      0.76      6783   Being a beginner, I am having difficulty understanding how good/bad my model is based on these metrics. How much can I improve my model, given the small and highly skewed dataset which I have? I have taken the following approach: Randomly sample 50-50 splits of the data 10 times, train a Logistic Regression on each, and then average the predictions of all the 10 models.

I've fitted my model and am trying to understand whether it's any good. I've calculated the recommended metrics to assess it ($R^2$/ AUC / accuracy / prediction error / etc) but do not know how to interpret them. In short, how do I tell if my model is any good based on the metric? Is an $R^2$ of 0.6 (for example) sufficient to let me proceed to draw inferences or base scientific/business decisions?     This question is intentionally broad, to cover a wide variety of situations that members frequently encounter; such questions could be closed as duplicates of this one. Edits to broaden the scope beyond the metrics mentioned here are welcome, as are additional answers - particularly those that offer insight about other classes of metrics.


In my form, I start things by running an executable file loader.exe(another project in visual studio) which prints some information on console over time until it terminates. What I want to do is: I want to read console while it continues executing and display the latest output(percentage with some extra info) in a text box textBoxConsole1 in my form application so that the user can be aware of the progress.  EDIT: Currently, it is a bit complicated. It displays some of the output, then displays additional output and then displays the whole remaining output. Not as same as the loader.exe does.  In this thread    Mr.Passant said:  "This is pretty normal, the process will switch to buffered output when you redirect its output. If it doesn't spit out a lot a text then that buffer doesn't fill up enough to cause it to be flushed. Nothing you can do about it if you can't fix the program's code."   So how much is this "enough" exactly? My Code:   private void buttonConnect_Click(object sender, EventArgs e)     {         Thread findThread = new Thread(findProcedure);         findThread.Start();     }      public void findProcedure()     {         Process process = new Process();         process.StartInfo.FileName = PATH;         process.StartInfo.UseShellExecute = false;         process.StartInfo.RedirectStandardOutput = true;         process.StartInfo.RedirectStandardError = true;         process.StartInfo.RedirectStandardInput = true;         process.StartInfo.CreateNoWindow = true;          process.OutputDataReceived += new DataReceivedEventHandler((sender, e) =>         {             if (!String.IsNullOrEmpty(e.Data))             {                 //textBoxConsole1.Text = e.Data; //Cross-thread validation exception                 //use thread safe set method instead                 setConsole1(e.Data);             }         });           process.ErrorDataReceived += new DataReceivedEventHandler((sender, e) =>         {             if (!String.IsNullOrEmpty(e.Data))             {                 setConsole3(e.Data);             }         });          process.Start();         process.BeginOutputReadLine();         process.BeginErrorReadLine();          process.WaitForExit();     }   And my thread-safe set method:  public void setConsole1(string str)     {         if (this.textBoxConsole1.InvokeRequired)         {             SetTextCallback d = new SetTextCallback(setConsole1);             this.Invoke(d, new object[] { str });         }         else         {             textBoxConsole1.AppendText(str);             textBoxConsole1.AppendText(Environment.NewLine);         }     }   Error data handler method setConsole3 is the same as setConsole1 but sets to another box.

I need to spawn a child process that is a console application, and capture its output.  I wrote up the following code for a method:  string retMessage = String.Empty; ProcessStartInfo startInfo = new ProcessStartInfo(); Process p = new Process();  startInfo.CreateNoWindow = true; startInfo.RedirectStandardOutput = true; startInfo.RedirectStandardInput = true;  startInfo.UseShellExecute = false; startInfo.Arguments = command; startInfo.FileName = exec;  p.StartInfo = startInfo; p.Start();  p.OutputDataReceived += new DataReceivedEventHandler (     delegate(object sender, DataReceivedEventArgs e)     {         using (StreamReader output = p.StandardOutput)         {             retMessage = output.ReadToEnd();         }     } );  p.WaitForExit();  return retMessage;   However, this does not return anything. I don't believe the OutputDataReceived event is being called back, or the WaitForExit() command may be blocking the thread so it will never callback.  Any advice?  EDIT: Looks like I was trying too hard with the callback. Doing:  return p.StandardOutput.ReadToEnd();    Appears to work fine.


Okay, after an hour of search, I hope asking myself will give me some answer. Basically, I want to write a tiny program that can swap my desktop resolution between 1920x1080 and 1280x800 automatically by running a simple script.  I started with:  public partial class MainWindow : Window {     public MainWindow()     {         InitializeComponent();          this.Loaded += SwapResol;     }      private void SwapResol(object sender, EventArgs e)     {         double width = System.Windows.SystemParameters.PrimaryScreenWidth;         if(width == 1920)         {             //set it to 1280x800         }         if(width == 1280)         {             //set it to 1920x1080         }          this.Close();     } }   When I realized that System.Windows.SystemParameters.PrimaryScreenWidth (and height) both only have getters implemented. If I run any script as an admin, is there a way to change the resolution in code? I have found tons of questions about getting the resolution and using it for the program but nothing on setting it. Does Windows even allow changing it some other way than using the 'standard method'?   question already exists, but the suggested answer seems to refer solving the problem in C++ by not using .NET.

Is there a way to programmatically change the screen resolution or enable/disable multiple monitors in Windows XP?  For example to change from 1024x768 with one monitor to 1280x104 on two monitors?  I would be most interested in a win32 function to do this but anything that can be tied to a windows shortcut would suffice.


I can usually connect my server via SSH using the Putty.exe interface:     But when trying the same via command line:  "C:\Program Files\PuTTY\putty.exe" -ssh myuser@mysite.com:2222   I get this error:     What's wrong?

I'd like to create a shortcut for connecting to my web server + logging in on Putty. The following has always worked for me but I recently have gotten a new web host that connects with a port other than the default 22, thus my normal target line doesn't work anymore:  "C:\Program Files\PuTTY\putty.exe" <user>@<host> -pw <password>   How do I to specify the port?


In a third-person narrative, I want to punctuate the following sentence:     Wasn't art supposed to impact the reader in an emotional way, she wondered.   How would that line be punctuated? I know I could use italics, but my question is, should it be,     Wasn't art supposed to impact its audience in an emotional way? she wondered.    or what? nothing seems entirely right to me. I know I could just change the whole thing—"She wondered whether or not art was ... yada yada ..."; but she is thinking this in response to someone and it's almost a rhetorical question, so I'd like it to remain the way I have it, but be punctuated properly—if that's possible. Grr.

If a sentence contains a complete question, but ends with a statement, should it be punctuated with a question mark?  Example:      Could she go to the store, he wondered


This is a bit of a silly question, but, is there a way of creating new symbols in LaTeX? Is it possible to make an emoji TeX-able? I want to label Burgers' equation in an align environment with a hamburger (like the burger emoji you may find on your smart phone).

I'm trying to display Emoji Characters inside my XeLaTeX Document. It seems to work for some glyphs like the numbers and pound sign but not for all. Here is a MWE:  \documentclass{scrartcl}  \usepackage{fontspec}  \setmainfont{Apple Color Emoji} % The emoji Font   \begin{document} \char"0030{}  %Works \char"1F60D{} % Doesent Work should out put SMILEY FACE WITH HEART SHAPED EYES \end{document}   What is the reason for this strange behavior and is there a way to include Emojis in XeLaTeX?  Edit:   It seems the Character is there. It is selectable but not visible. I can copy&paste it.


I have lists containing sequence of numbers like below: list_1 = [4.5 ,4.5 ,4, 4 ,4, 5, 5, 5] list_2 = [6.5 ,7 ,7 ,8 ,8] list_3 = [14.5 ,15 ,15 , 15.5]   I want to remove duplicates from those list in a way that if list contain repetition keep only one occurrence, and preserve the order: list_1 = [4.5 ,4, 5] list_2 = [6.5 ,7 ,8] list_3 = [14.5 ,15 , 15.5]

Is there a built-in that removes duplicates from list in Python, whilst preserving order? I know that I can use a set to remove duplicates, but that destroys the original order. I also know that I can roll my own like this:  def uniq(input):   output = []   for x in input:     if x not in output:       output.append(x)   return output   (Thanks to  for that .)  But I'd like to avail myself of a built-in or a more Pythonic idiom if possible.  Related question:


In another question of mine, I reported that Ubuntu wasn't working well, and the only answer I got said that Ubuntu 17.10 has bad memory usage, and recommended I move from Ubuntu to Xubuntu, Lubuntu, etc.  My question is, should I move to a different Linux system (I want a faster yet beautiful one) or move to a older Ubuntu version? I have tried 16.04 (with unity) and now I have the 17.10, both of them give me problems.  Once again, my specs are:   2 GB of RAM Intel Core 2 Duo CPU T6570 2.10GHz x 2 64 bits 500 GB of Memory My graphics card is NVIDIA GeForce 9300M GS - 256 MB, Núcleo: 580 MHz, Memoría: 702 MHz, GDDR3 VRAM, 7.15.11.7482 (ForceWare 174.82), it seems that Ubuntu doesn't recognize it, what Linux distro will?

For a given hardware configuration, how do I find out if Ubuntu will run on it? What considerations should I take into account when choosing an Ubuntu version and  such as:    with a lighter desktop than the usual Gnome and Unity  with the even lighter LXDE desktop   Obviously Ubuntu does not run on some processor architectures. So how do I go about choosing the right version and derivate. How can I find out the minmal system requirements?


I want to show $$\langle a,b\mid ab^2＝b^3a, ba^2＝a^3\rangle$$ is isomorphic to a trivial group.  My text book proved this like following.  $bab^2a＝a^4b^2a\to ba＝a^4b^2$  $a^4b^2a＝a^3b$ (omitted some process), so $ab^2a＝b$  $b^2a^2＝1, a＝a^4b^3a b^3a^2＝1, b^3＝b^2\to b＝1, a＝1$  This proof is too difficult for me to imitate because there is no oriented strategy of each process. Firstly, I cannot understand why we should start from $bab^2a$.  Other way to prove is also appreciated, I would be happy if you could give me an strategy of deformation.

Suppose $a$ and $b$ are elements of a group $G$. If $a^{-1}b^{2}a=b^{3}$ and $b^{-1}a^{2}b=a^{3}$, prove $a=e=b$.   I've been trying to prove but still inconclusive. Please prove to me.  Thanks very much for proof.


By looking for jobs with the '.net' tag, i.e., this URL:  I've come across many jobs that don't have it. They don't have the tag and they don't have the '.net' text in their content either.  A current example is this one:

I am attempting to search jobs by tag on StackOverflow Careers. On SO, this is done using square brackets, but that is simply doing a keyword search, and I still get results that don't have the tag I am looking for.  For example, when I search for the keyword "android", I get this:        which is the same as when I search for the keyword "[android]":        Is there a format I can use to search jobs by tag? If not, I believe this would be a nice feature (seems intuitive for the Stack Exchange invite-only job site).


Find the sum of the series $$\cos x + \cos 2x + \cdots + \cos (n-1)x.$$ You must calculate the sum of this series only by multiplying through by $2\sin\left(\frac{x}{2}\right)$.  Now I've heard of finding the sum of a trig series by finding real and imaginary parts etc., but I have no idea how to do it this way.

I just wanted to evaluate  $$ \sum_{k=0}^n \cos k\theta $$  and I know that it should give  $$  \cos\left(\frac{n\theta}{2}\right)\frac{\sin\left(\frac{(n+1)\theta}{2}\right)}{\sin(\theta / 2)}   $$  I tried to start by writing the sum as  $$ 1 + \cos\theta + \cos 2\theta + \cdots  + \cos n\theta $$  and expand each cosine by its series representation. But this soon looked not very helpful so I need some clue about how this partial sum is calculated more efficiently ...


When I first watched "Attack of the Clones" and "Revenge of the Sith", I thought that there are a number of situations where Obi-Wan Kenobi makes life difficult for himself by failing to use the Force (we'll excuse him in "Phantom Menace", since he is still an apprentice). Two that come to mind right now are:   Fight against Jango Fett on Kamino. He just uses his lightsaber to deflect Fett's blaster shots, instead of using the Force to fling the blaster of Fett's hand, or straight up throwing him against a wall until he's knocked unconscious. Fight against Gen. Grievous after both have lost their lightsabers. Five minutes earlier, OWK had shown he has enough Force command to fling Grievous around a huge hangar like a doll, but now he insists on trying to punch an opponent made of metal with his bare hands.   Is there an in-universe reason for these decisions?

I understand that the Jedi use the Force for self defence, but still, couldn't they just use the Force to snap their foes' necks and be done with it? Like when Jaina Solo was hunting down Darth Caedus. Or even when Caedus was duelling Grand Master Skywalker. If he just used the Force to snap Skywalker's neck (like he did to poor Lieutenant Tebut), it will all be over very fast.  Is there a canon reason why Jedi and Sith don't use their powers to directly harm their opponents?


I want to put a camera on my roof and possibly record for 24 hours. What do I need and how can this be done? I think generally, people take photos correct? I am thinking I might have to hook up a 1TB harddrive some how.

I have 238gb of timelapse photos which was taken over a period of twenty days and all the photos are split up into 20 folders. I would like to put this together into a timelapse, I tried using Premiere Pro but that is taking very very long, any tips on putting it together fast btw Im on a Mac, thanks.


Proving that  $$\sum_{n=2}^\infty \frac{1}{P_n -1} =1$$ Where $P_n$ is the nth perfect power.  I think Goldbach has proved this, and I can't even find his proof anywhere. All the results are of the Goldbach conjucture  and that none of this man's other works is even visible through that. Kind of sad. Also the , the oeis on perfect powers has said the same that Goldbach proved it but no reference nor citation to back it up. Any help?  Also is it also possible to find like;  $$\sum_{n=1}^\infty \frac{1}{P_n^2 -1} $$ etc with powers too?

If $ A = \{ m^n| \text{  } m, n \in Z  \text {  and  } m, n \ge 2 \} $, then how find $\sum_{k \in A} \frac{1}{k-1} $?


There are different ways of scaling variables in k-means clustering. I can divide all variable by sum of that column, I can take z score,I can have (max(var)-value)/(max(var)-min(var) etc. How selection of variable scaling/normalising would change clustering result? I have done clustering on 1 million rows with 20 continuous variables. And the wss/tss  is different for different scaling methods.      What is the reason from Algo perspective ?

K-means is a widely used method in cluster analysis. In my understanding, this method does NOT require ANY assumptions, i.e., give me a dataset and a pre-specified number of clusters, k, and I just apply this algorithm which minimizes the sum of squared errors (SSE), the within cluster squared error.  So k-means is essentially an optimization problem.  I read some material about the drawbacks of k-means.  Most of them say that:   k-means assumes the variance of the distribution of each attribute (variable) is spherical;  all variables have the same variance; the prior probability for all k clusters is the same, i.e., each cluster has roughly equal number of observations;   If any one of these 3 assumptions are violated, then k-means will fail.  I could not understand the logic behind this statement. I think the k-means method makes essentially no assumptions, it just minimizes the SSE, so I cannot see the link between minimizing the SSE and those 3 "assumptions".


Let $A, B, C, D \in M_n(F)$, such that $C$ and $D$ are invertible and $CD=DC$. Prove: \begin{vmatrix} A & B \\  C & D \end{vmatrix} = $|AD - BC|$ What is the direction? Thanks.

Let $A,B,C$ and $D$ be $n \times n$ matrices such that $AC = CA$. Prove that $$\det \begin{pmatrix} A & B\\ C & D\end{pmatrix} = \det(AD-CB)$$   The solution is to first assume that $A$ is invertible and then consider the product $$\begin{pmatrix} I & O\\ -CA^{-1} & I \end{pmatrix}\begin{pmatrix} A & B\\ C & D \end{pmatrix}=\begin{pmatrix} A & B\\ O & D-CA^{-1}B \end{pmatrix}$$ then it is not hard to prove that the claim is true if $A$ in invertible. Finally, we use the fact that the set $GL_n$ form a dense open subset of $M_n$ to get rid of the invertibility assumption. My question is: how to come up with such a weird matrix $\begin{pmatrix} I & O\\ -CA^{-1} & I \end{pmatrix}$? thank you so much. Is there any other problems that uses the technique of assuming invertibility? (one of which i know is to prove $\det (I+AB) = \det(I+BA)$), thanks in advance


=IF(AND(TIME(HOUR(B5), MINUTE(B5), SECOND(B5))>TIMEVALUE("6:30 PM"), D5=1), (TIME(hours(C5), MINUTE(C5), SECOND(C5))-TIMEVALUE("9:30 AM")), (TIME(hours(C5), MINUTE(C5), SECOND(C5))-TIMEVALUE("9:30 AM")+TIMEVALUE("9:00 AM")))   Giving error as You've entered too few argument   Kindly help.

I gave a formula like    IF(N3=0,"N/A",IF(Q3=0,IF(M3<=N3,"FAIL","PASS")),IF(M3>=O3,”PASS”,”FAIL”),0)    and its  showing error message as "To many arguments for this function".


I'm trying to completely delete Flow from my Org (all versions etc.) with destructiveChanges. However, when flow is added to destructiveChanges, I get the following error: Insufficient access rights on cross-reference id. Here is how my destructiveChanges look like:     <types>         <name>Flow</name>         <members>XYZ_Flow</members>     </types>

I'm trying to delete some old flow which are inactive via workbench. DestructiveChanges.xml <?xml version="1.0" encoding="UTF-8"?> <Package xmlns="http://soap.sforce.com/2006/04/metadata">     <types>         <members>Advanced_Round_Robin</members>         <name>Flow</name>     </types>Ï </Package>  package.xml <?xml version="1.0" encoding="UTF-8"?> <Package xmlns="http://soap.sforce.com/2006/04/metadata">       <version>48.0</version> </Package>  I've added both file in zip and in workbench when I deploy using this zip file I get below error.  insufficient access rights on cross-reference id   What permission I need to have to perform this action? Also is there way I can delete few version of same flow only? Like keep only last 3-4 version and delete all previous version of given flow? Thank you.


In the Harry Potter series, why do they select Muggleborns to also learn magic at the Hogwarts School of Witchcraft and Wizardry and other schools in the wizard world?

Leaving aside ethical and moral considerations, the whole policy of Salazar Slytherin's "we should not teach muggle-born magic-capable children" seems to be completely counter-productive to the whole "Let's not allow Muggles to know about existence of magical world" idea.  To wit, muggle-born wizards are obviously capable of performing magic (there were several examples in the book) even without wands/training, and many of them are powerful enough as far as their magical ability that it's likely to get noticed.   So, short of killing off every child that has latent magical abilities (or at least those with abilities beyond some threshold) or charming them so they are unable to do any magic, wouldn't refusal to teach them all how to PROPERLY use magic and what the rules are merely get a lot more chances for Muggles to see magic being performed which totally goes against the whole "Let's not allow Muggles realize that there are magic users around" that drives a lot of the Wizarding rules?  UPDATE Just to clarify - this question is about the idea of Salazar Slytherin himself and not the modern-day Death Eaters/Voldemort.


Prove that every nonempty open subset of $\mathbb{R}$ can be expressed as a countable disjoint union of open intervals:  $G=\bigcup_{k}(a_k,b_k,),$  where the range on $k$ can be finite or infinite. Furthermore, show that this expression is unique except for the numbering of the component intervals. (Hint: for any $x\in G$, show that there exists a largest open interval $A_x$ such that $x\in A_x$ and $A_x \subset G.$)  Can you give me the proof using above hint? and another problem is:  In the notation of above problem, prove that $\lambda(G)=\sum_{k}(b_k-a_k).$

Let $U$ be an open set in $\mathbb R$. Then $U$ is a countable union of disjoint intervals.    This question has probably been asked. However, I am not interested in just getting the answer to it. Rather, I am interested in collecting as many different proofs of it which are as diverse as possible. A professor told me that there are many. So, I invite everyone who has seen proofs of this fact to share them with the community. I think it is a result worth knowing how to prove in many different ways and having a post that combines as many of them as possible will, no doubt, be quite useful. After two days, I will place a bounty on this question to attract as many people as possible. Of course, any comments, corrections, suggestions, links to papers/notes etc. are more than welcome.


When I call a Python unit test I can see all the stdout directly e.g. how remote APIs are called etc., if I use the -s switch.  python3 -m pytest -s some_test.py   However if I run a script with same code which I prototyped in the test script, the stdout comes only at the end.  python3 script.py   How to make script.py to print to stdout as it comes from pytest?

Is output buffering enabled by default in Python's interpreter for sys.stdout?  If the answer is positive, what are all the ways to disable it?  Suggestions so far:   Use the -u command line switch Wrap sys.stdout in an object that flushes after every write Set PYTHONUNBUFFERED env var sys.stdout = os.fdopen(sys.stdout.fileno(), 'w', 0)   Is there any other way to set some global flag in sys/sys.stdout programmatically during execution?


I have installed devel kint module on my drupal 8. Everything is fine with the module.  But my problem is how should I interpret the output of kint correctly. Especially when I want to render field within file entity.  Here is the scenario:   I have a form created with YAMLForm in my front. In that form user can upload image. User submit the form. When I debug data with kint, I can see the url of the image, but I am unnable to display it thru .   Please find below a screenshot of the kint output    I have tryied with the following but no chance :  {{ file_url(data.picture['#value']['#file'].entity['#values'].uri['x-default']) }} {{ file_url(data.picture.0['#item'].entity.uri.value) }} {{ file_url(data.picture.entity.fileuri) }}   I've Googled for hours but couldn't find any clues.  Thanks in advance for your help.

I want to render an image as a background image via an inline style in twig. I created a field called bg_image and attached it to the standard plain page.  After fiddling around for hours I was able to get the Image URL in node.html.twig  {{ file_url(node.field_bg_image.0.entity.uri.value) }}   but I could not get it to work inside field--field-bg_image.html.twig  Can I get the node from there anyhow, so I can then get the image?  How can I get the image URL to use as inline style? I thought maybe I can pass a variable from field--field-bg_image.html.twig to image.html.twig and then just render  {{ uri }}   instead of  <img{{ attributes.addClass(classes) }} />   but I could not get it to pass the variable there unless I use includes  {% include 'image.html.twig' with {'image': image, 'isFromField': isFromField} %}   (isFromField is true, when it comes from the field--field-bg_image.html.twig) But that didn't work either. The Image was never rendered that way.  Would be very glad if you can help - my php knowledge is very basic. Thanks


I had an exam this morning. Last week the teacher had warned us that her exams are tough; this scared me. I wanted to see what her exams were like, so to study I searched through the exam repository at my school for an old midterm. Unfortunately, the exam repository only has final exams (including this course). Then I googled "(course code) (school name) midterm", and a couple of links came up. One was an online repository (not associated with my school) where people can upload old exams. I found a lot of old midterms for this course. These midterms were all in the same format but the exact questions were different in most cases. These midterms also had the answer key. I studied them to get an idea of how much the professor expected of us and to help resolve my confusion about some concepts. The practice midterms REALLY helped clarify things for me.   Last night, a student in the class posted a past midterm in a student-run Facebook group for the class. This exam did not have the official answers on it, but it did have the ones given by the student who took the test that year. After taking the test today, I noticed that some of the questions on this midterm were identical to the ones I studied online. It dawned on me that I may have committed an academic offense.  I am wondering, is studying past exams given in the course cheating? What if those exams are found in an non-school-sponsored repository online?

This happened to me in my 2nd year of grad school, in a STEM field. As many do, our professor gave the class the last year's final, to give us an idea of what areas to study and what to expect, etc, which he obviously isn't required to do and is very nice of him.  Now, the reason he gives us last year's one is because, at the end of the year, he returns your test, so he knows that most of the ones floating around are the ones from last year.  However, as many older professors (in my experience, but maybe younger ones too) do, he also reuses exams from previous years (not even concepts or the same problems with different parameters, just literal copies), since the material and curriculum of this course is very well established/so old that nothing needs to change. I don't blame him for this; if you teach the same course on and off over 20 years, coming up with good exam questions over and over again would be annoying.  Now, what my question regards is, I realized a student in my class had past tests from not just the last time the class was taught, but literally the past 5 years. I don't know how to say this part as diplomatically as possible, but this student came from a country that about nearly half our program comes from. The other half (aside a few outliers) is from the U.S. I don't mention this to demonize or stereotype anyone; I believe it's relevant because the students from this country (in my program) are almost uniformly very tight knit, and seem to often share resources between each other and across years more than is normal amongst everyone else. The relevance is that one group has resources that others don't.  So my question is, is this ethical (for the student to do, I mean) ?  Just to put some relevant ideas/arguments/details down:   Assume (and I believe it was the case) that in the scenario I've written, the rest of the students (the ones who don't have the past tests) don't know about the students that have the past tests, so they can't do something simple like ask them. I think many will argue that if the professor didn't want this happening, he wouldn't reuse tests, or at least as exactly as he does. However, I don't think this changes the ethics of the situation: the point is, in this situation, you can get away with it, but is it right? I imagine the professor would not approve of this (actually, recently, another professor said in regards to his final "I know there are past ones floating around, please don't look at them", so at least he disapproved), but an argument could also be made for the possibility of him approving: It's not as though having the previous tests just makes it a given that you'll ace it, it's still a lot of work to figure out all the problems such that you can reliably do them later (he doesn't give back the answers to the tests, only the tests themselves). I could imagine a professor being okay with students getting a better grade on the final if it meant they learned more and worked to get it. This professor never actually said not to, so the student wasn't explicitly disobeying anyone. This question really has two subquestions, but they're very similar: a) Would it be ethical if everyone had these pasts tests (that the professor did not know about/give)? And b), Is it ethical if only a subset of the class has these tests. Obviously if you say no to (a) you say no to (b), but you might feel as though the concept of using past tests isn't wrong, but some students having an unfair advantage is.


Let $M$ be an $R$-module, where we may assume that $R$ is an integral domain.  Let $N$ be a submodule of $M$.  Suppose that $M/N\cong M$. Can we conclude that $N=0$?  (If no, what are some sufficient conditions that make it true?)  Update: I learn that for "infinite dimensional" cases it can fail. How about when $M$ is finitely generated, does it work?  Thanks a lot.

My question is as in the title: is there an example of a (unital but not necessarily commutative) ring $R$ and a left $R$-module $M$ with nonzero submodule $N$, such that $M \simeq M/N$?  What if $M$ and $N$ are finitely-generated? What if $M$ is free? My intuition is that if $N$ is a submodule of $R^n$, then $R^n/N \simeq R^n$ implies $N=0$. It seems like $N\neq 0$ implies $R^n/N$ has nontrivial relations, so $R^n/N$ can't be free.  If $R^n/N \simeq R^n$, we'd have an exact sequence  $0 \rightarrow N \hookrightarrow R^n \twoheadrightarrow R^n/N \simeq R^n \rightarrow 0$  which splits since $R^n$ is free, so $R^n \simeq R^n \oplus N$. Does this imply $N=0$? What if we assume $R$ is commutative, or even local? Maybe Nakayama can come in handy.  I'm interested in noncommutative examples too. Thanks!


"He is racist towards black people."  "He is racist against black people."  "Towards" and "against" are antonyms, so why do they mean the same thing here?

After I found this website, I have a chance to ask questions I used to hesitate to use in a sentence as I am not a native English speaker even though I am really interested in learning English.  Anyways,  Can these sentences be legit and give the same meaning?   I feel something towards her. I feel something against her.   Do they have same meaning and also where can we not use against and towards interchangeably if we can use them interchangeably sometimes.  Edit:  Okay, it seems while feelings are coming to play they cause different meaning but where can I not use them interchangeably when there is no feelings involved?


I reproduce an error with the following simple file.   It says:      field has incomplete type 'Foo'  bar.h:      class Foo;  class Bar{     private:         int x_;         Foo foo_; // error: incomplete type      public:         void setx(int x) {x_ = x;};         void increment(int);  };   class Foo{  public:     void run(int y,Bar& bar) {bar.setx(y);}; };  void Bar::increment(int i){foo_.run(i,*this);}   Member foo_ must not be a reference or a pointer. The reason for this is that in my actual code,  I cannot initialize Foo in the initialization list of Bar.

I am looking for the definition of when I am allowed to do forward declaration of a class in another class's header file:  Am I allowed to do it for a base class, for a class held as a member, for a class passed to member function by reference, etc. ?


When Kaneki's hair turned from brown to white, was it because because of the stress ? Or maybe because of his change of heart. A lot of anime and manga use hair-colors to describe someones personality, so maybe it was symbolic like, his hair turned white because he admitted that he has to change his personality.. Does someone know the real reason or?

At the start of the series, Kaneki's hair is dark brown, except in the OP, where it we see an image of him with white hair. In episode 11, we see a final scene of Kaneki, his hair having turned white. This turns out to be a preview of things to come, his hair being brown at the start of episode 12.  However, during episode 12, we see a scene, theoretically taking place in Kaneki's mind, or as a hallucination, wherein his hair fades from brown to white.    After this scene, however, this color change seems to manifest in the real world, too. (Kaneki's clothes also seem to invert colors.)  What caused Kaneki's hair (and/or clothes) to change color in the actual real world during this episode?


Does an object rotate around its COM when no torque is given?  For example if I were to throw a baseball bat in the air(I will hold it by the end of its shaft while I am throwing it and swing it upwards in order to give it angular momentum, and after I release it, the only force that acts on the bat is gravity),  Would it immediately start to rotate around its COM the moment I release it?

If a sphere has a torque vector coming out of it at point A, would the sphere rotate about its center or the axis of the torque vector?


Trying to solve the linear system below for $x,y$ and $z$ in terms of $a,b,c$ and $\zeta_3$: $x+y+z=a$ $x+{\zeta_3}y+{\zeta_3}z=b$ $x+{\zeta_3}^2y+{\zeta_3}^2z=c$ where $\zeta_3=-1/2+-i(\frac{\sqrt 3}{2})$ i.e. ${\zeta_3}^3=1$ From a book by the Russian author Smirnoff (translated by Silverman) - the author says the answer is $x=(a+b+c)/3$; $y=(a+b{\zeta_3}^2+c{\zeta_3})/3$; $z=(a+b{\zeta_3}+c{\zeta_3}^2)/3$ Got part of the way with Gaussian elimination, but couldn’t figure out how to use the information about e to finish the solution.  Any thoughts?

In Cardano's derivation of a root of the cubic polynomial $f(X)=X^3+bX+c$ he splits the variable $X$ into two variables $u$ and $v$ together with the relationship that $u+v=X$. From this he finds that $x=u+v$, where  $$u=\sqrt[3]{\frac{-c}{2}+\sqrt{\frac{c^2}{4}+\frac{b^3}{27}}}$$ and $$v=\sqrt[3]{\frac{-c}{2}-\sqrt{\frac{c^2}{4}+\frac{b^3}{27}}}$$  is a root of $f(X)$.      Is there an intuitive explanation for why Cardano splits the variable $X$ into two parts, $u$ and $v$?


How do I split a string with multiple separators in JavaScript? I'm trying to split on both commas and : colon but,  js's split function only supports one separator.  Example :  materialA:125,materialB:150,materialC:175   I want to split both these values into array like  materiaA,materialB,materialC   and second  125,150,175   Or anybody can give me idea how could I multiply these numbers with a constant to get like   materialA:1250, materialB:1500,materialC:1750.

How do I split a string with multiple separators in JavaScript? I'm trying to split on both commas and spaces, but AFAIK JavaScript's split() function only supports one separator.


Prove $0<(1+\frac{1}{n})<3$ and hence prove $99^{100}>100^{99}$.  I did the first part and showed $0<\frac{1}{n^{n-1}}\le3$ and hence $0<(1+\frac{1}{n})<3$. But for the second bit, I don't know how to incorporate the first bit to help me prove th inequality.

Which of the numbers $99^{100}$ & $100^{99}$ is the larger? Solve without using logarithms.


I am hosting multiple servers behind one public IP. (Mostly in Proxmox VE) Currently, all the services are on separate ports. I would like to use multiple domains to reach different services and am not sure how/ if I can do this. I have looked at squid reverse proxy but it only works with HTTP/HTTPS I'm not sure if a local DNS could help. Although I am planning on setting up a local PowerDNS server anyway.

This is a  about hostname-awareness and proxying.   I know that some protocols are hostname-aware; that is, when I connect to the HTTP server at www.example.com it knows I want www.example.com's HTTP service, not www.example.net's, even though they are on the same IP address.  How can I do this for protocol foo?  (Temporary note: this question appears pursuant to .)


I am trying to remember the name of a tale or novel by Isaac Asimov. I am positive I've read this some years ago, but for the life of me, I can't recall the name.  In the story, one of the characters, some kind of diplomat, speaks profusely. Only after recording and analysing his speech, the main character(s) come to the conclusion that there is no actual information to all his verbosity. He was a master at speaking without actually saying a thing.

I'm looking for a book that starts with the premise that (once the population size had exceeded a certain number) the future development of mankind (revolutions and wars in so and so many years, colonization of other planets in so and so many years, and so on) could be predicted completely by applied statistics. (IIRC, they used slide rules for those exact predictions, but that is certainly owed to the time the story was written). Next, the predictability was used to take a few tiny measures that would change mankind's fate in a favourable way. After a long time, the predictive system fails(?) because a mutation occurs in some person(s).  And now is the part where I'm not sure if it belongs to this or another story: The mutation results in the ability to "beam" by thinking of a place where one has been before...


I have a laptop with windows 7. One day i cannot access windows. So I'M trying to use Ubuntu 13.10 live USB ("try only" version) to retrieve important files in the internal hard disk.  when I try to open the internal hard disk it says that:  Unable to access "86Gb Volume"  Error mounting /dev/sda2 at /media/ubuntu/34BC6628BC65E538: Command-line `mount -t "ntfs" -o "uhelper=udisks2,nodev,nosuid,uid=999,gid=999,dmask=0077,fmask=0177" "/dev/sda2" "/media/ubuntu/34BC6628BC65E538"' exited with non-zero exit status 13: ntfs_attr_pread_i: ntfs_pread failed: Input/output error Failed to read NTFS $Bitmap: Input/output error NTFS is either inconsistent, or there is a hardware fault, or it's a SoftRAID/FakeRAID hardware. In the first case run chkdsk /f on Windows then reboot into Windows twice. The usage of the /f parameter is very important! If the device is a SoftRAID/FakeRAID then first activate it and mount a different device under the /dev/mapper/ directory, (e.g. /dev/mapper/nvidia_eahaabcc1). Please see the 'dmraid' documentation for more details.   Help me, please

I replaced a buggy Windows Vista installation with Ubuntu. All works fine except that the main HD where I had all my files are now inaccessible. Here is the error message I get:   Error mounting: mount exited with exit code 13: ntfs_attr_pread_i: ntfs_pread failed: Input/output error Failed to read NTFS $Bitmap: Input/output error NTFS is either inconsistent, or there is a hardware fault, or it's a SoftRAID/FakeRAID hardware. In the first case run chkdsk /f on Windows then reboot into Windows twice. The usage of the /f parameter is very important! If the device is a SoftRAID/FakeRAID then first activate it and mount a different device under the /dev/mapper/ directory, (e.g. /dev/mapper/nvidia_eahaabcc1). Please see the 'dmraid' documentation for more details   Is it necessarily a hardware problem? If not, is there a way to repair the HD from Ubuntu?


I don't know if this is correct because "are" is present tense and "played" is past tense.

I'm doing a school exercise where I have to give an explanation of the underlined (or in this case bold) verb usage in given sentences, following this format:     I was waiting.      past continuous (or progressive) =   subject + was / were + verb + ‘-ing’ (or present participle)   The last sentence I am to anaylse is giving me trouble:     Toyota cars are made in Japan.   I've indentified the tense as present simple, and  cars is clearly the subject, and "are" at least one of the verbs. But what is the rule for past participles in simple present tense? I've done fairly extensive searches online and found grammar websites that give examples of the same format as present simple tense, but none that give any explanation or rule for how the past participle is used in this case.  My best guess for the desired analysis is:     cars are made      Simple present =    subject + is / are + past participle   But this is only an inference, and I don't know if it accurately reflects any actual grammatical rule.  Any help will be appreciated. (And don't worry, I'm allowed to use the internet, several links are even included with the exercise, so you're not helping me cheat)


I have finished destroying all the Crimson Hearts and have gone to the guide to see what to do next and the guide is telling me to keep destroying them. I think it's a bug and I can't find out ANYWHERE what to do next.

I'm kind of stuck in Terraria. I have full silver armor and 12 hearts (gold/silver gear).  I have just killed the Eye of Cthulhu.  I was thinking about gathering gold armor, but gold is damn scarce. I have tried searching for floating islands (at 406 altitude) but if I go to far I get attacked by Harpies, and I can't build a sky bridge and fight them at the same time.  My meteorite landed in corruption and it's impossible to collect it (I get swarmed by meteor heads with no way to run).  So what is the most natural progression? Should I try and find gold (where?), try to kill the Eater of Worlds, try to mine meteorite or try to fight off imps and collect some hellstone?


I came across that limit: $\lim_{s\to\infty} s\bigg(\big(1+\frac{1}{s}\big)^{s} - e\bigg)$ I tried to solve it using l'Hospital's rule: $\lim_{s\to\infty} s\bigg(\big(1+\frac{1}{s}\big)^{s} - e\bigg) = \lim_{t\to0} \frac{1}{t} \bigg(\big(1+t\big)^{\frac{1}{t}} - e\bigg) = \lim_{t\to0} e^{\frac{1}{t}\log(1+t)}\big(\frac{1}{t(t+1)} - \frac{\log(1+t)}{t^{2}}\big)$ I used l'Hospital's rule after the second equality. However I got nothing really valuable. Do you have any ideas how to solve that problem?

I am stuck on how to calculate the following limit: $$\lim_{x\to\infty}x\left(\left(1 + \frac{1}{x}\right)^x - e\right).$$  Definitely, it has to be through l'Hôpital's rule. We know that $\lim_{x\to\infty} (1+(1/x))^x = e$. So, I wrote the above expression as $$\lim_{x\to\infty}\frac{\left(1 + \frac{1}{x}\right)^x - e}{1/x}.$$Both numerator and denominator tend to zero as x tends to infinity. I applied l'Hôpital's rule twice, but I got the limit equal to infinity which is clearly wrong. In the book, it says that the limit should be $-e/2$.  Any help please? Also, in case someone managed to solve it, please tell me which numerator and denominator did you apply your l'Hôpital's rule to in both cases? Thanks a lot  Also, guys can you tell me how to write equations in this forum? Thanks.


I couldn't find any way to get, through the API, a list of all questions that are duplicate of what other question.  For example, for the question with ID 10369, I want to obtain the question with ID 10372 (or the other way around, at least).  Is there a way to do so, other than scraping the page?

I am interested to see a list of all questions that were closed because being a dup of another question.  I strongly want to research a particular question and reading all the answers inside the dups will help me a lot.  Is there such feature? if not, this is a feature request


I need help in evaluating the following sum:  $$\sum_{i = 0}^n i^5 $$  I can evaluate series when they are arithmetic or geometric but I don't know how to solve this one.

Is there explicit formula for the expression $1^n + 2^n + \dotsc + k^n\,$?  I know that for $n=1$ the explicit formula becomes $S=k(k+1)/2$ and for $n=3$ the formula becomes $S^2$. But what about general $n$?  I know there is a way using the Taylor expansion of $f(x)=1/(1-x)=1+x+x^2+\dotsc\;$, by differentiating it and then multiplying by $x$ and then differentiating again. Repeating this $n$ times, we get  $$\frac{d}{dx}(x\frac{d}{dx}(\dots x\frac{d}{dx}f(x))\dots )=1+2^nx^n+3^nx^n\dots.$$  Now do the same process but with the function $g(x)=x^{k+1}f(x)$. Then subtract them and we get $1+2^nx^n+\dots k^nx^n$. Because we have the explicit formulas $f(x)$ and $g(x)$ we can find the explicit formula by this process for arbitrary $n$. A big problem is that as $n$ grows, it is going take a lot of time finding the explicit formula. My question is therefore: are there other ways?


Given the sequence $a_1 =1, a_{n+1}=a_n+e^{-a_n}$.   Prove that $b_n:=a_n-\ln(n)$ converges.   I have just known $\lim a_n =\infty$. I have tried to prove $b_{n+1} \leq b_n$ but I didn't make it. Help me, thank you so much

Let the sequence $(x_n)_{n \geq 0}$ defined by  \begin{cases} x_0=2017 \\ x_{n+1}=x_n+e^{-2018x_n} \end{cases} for every $n \ge 0$. Calculate $$\lim_{n\to \infty}x_n \text{ and }  \lim_{n\to \infty}\frac{\ln(2018+n)}{x_n}$$  I proved that $\displaystyle \lim_{n\to \infty}x_n=\infty$, but I don't realise how to find the second limit. I tried Cesaro-Stolz lema, but it doesn't work. Please help me!


Let $f:\mathbb{R}^2\to\mathbb{R}$ be defined by $f(x,y)=\sqrt{|xy|}$. Show that $f$ is not differentiable at $(0,0)$.   If you could start me out on how to show this, that would help a lot.

I want to show that $f(x,y) = \sqrt{|xy|}$ is not differentiable at $0$.  So my idea is to show that $g(x,y) = |xy|$ is not differentiable, and then argue that if $f$ were differentiable, then so would $g$ which is the composition of differentiable functions $\cdot^2$ and $g$.  But I'm stuck as to how to do this.  In the one variable case, to show that $q(x) = |x|$ is not differentiable, I can calculate the limit $\frac{|x + h| - |x|}{h}$ as $h\to 0^+$ and $h\to 0^-$, show that the two one-sided limits are distinct, and conclude that the limit $$\lim_{h\to 0}\frac{|x + h| - |x|}{h}$$ does not exist.  The reason this is easier is that I do not have to have in mind the derivative of the function $q$ in order to calculate it.  But in the case of $g(x,y) = |xy|$, to show that $g$ is not differentiable at $0$, I would need to show that there does not exist a linear transformation $\lambda:\mathbb{R}^{2}\to\mathbb{R}$ such that  $$\lim_{(h,k)\to (0,0)}\frac{\left||hk| - \lambda(h,k)\right|}{|(h,k)|} = 0$$  I thought of assuming that I had such a $\lambda$, and letting $(h,k)\to (0,0)$ along both $(\sqrt{t},\sqrt{t})$ and $(-\sqrt{t},-\sqrt{t})$ as $t\to 0^{+}$, but this didn't seem to go anywhere constructive.


I retrieved an old math book and I'm delighted to share following exercise.     The pencils in a box of crayons always have the same color.   Proof by induction on the number $n$ of pencils in the box:   This is true when $n=1$. All the pencils, only one, havs the same color. Suppose the result true for a box having $n+1$ crayons. Remove one. Remains $n$ crayons. By induction hypothesis they all have the same color. Put back the crayon you removed and remove another one. The $n$ remaining crayons in the box have again the same color by induction hypothesis. Hence the two crayons that were removed have the same color. Therefore all the $n+1$ crayons have the same color.   Can you find what's wrong here?

Hello guys I have this problem which has been really bugging me. And it goes as follows:  Using induction, we want to prove that all human beings have the same hair colour. Let       S(n) be the statement that “any group of n human beings has the same hair colour”.  Clearly S(1) is true: in any group of just one, everybody has the same hair colour.  Now assume S(k), that in any group of k everybody has the same hair colour. If we replace any one in the group with someone else, they still make a total of k and hence have the same hair colour. This works for any initial group of people, meaning that any group of k + 1 also has the same hair colour. Therefore S(k + 1) is true.  I cant seem to figure out where the problem lies in this proof. I have tried a few things and I have concluded the base case is correct. But other than that I can't seem to disprove this proof.


I have installed both exfat-fuse and exfat-utils.  However, when I go to gparted, and attempt to format a partition as exFAT, the exfat option is greyed out when attempting to create or format a partition.      Why is this so?  How can I use gparted to create an exfat partition?

When I go to Gparted and try to format my pendrive to exfat,the option is greyed out and I am not able to select it however I can choose other file systems such as ext4,ntfs,etc.  Why is that ?


mhn@mhn-Inspiron-560s:~/Desktop$ sudo apt-get install openmpi-3.0.1rc2 Reading package lists... Done Building dependency tree        Reading state information... Done E: Unable to locate package openmpi-3.0.1rc2 E: Couldn't find any package by regex 'openmpi-3.0.1rc2'

How can I install applications like Google Chrome on Ubuntu?  Are there any commands to install an application?    Index of answers:


I'm writing a code for a simple forum, topics are listed and there is a possibility to add a new topic on the fly by clicking a link (image) in which a form will be added into an empty div (via .html()), how can i catch form submitting event from this particular form?   code below:
New Subject
   Some EExplanation

No Topics currently

Add a new topic

   my Script is the following:     is there a way to catch form submit event from this code?

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


This  popped up, and got for sure quickly downvoted and delete-voted in 7 minutes. Anyway: it reads:     I am undertaking a research study on the use of communication API tools and am looking for help. It will take no more than 2 minutes of your time. We are offering a prize for respondents. ... link ... some more details   As the author is disclosing his identity - am I correct in not flagging this as SPAM?  Edit: the core of my question is if flagging as spam is appropriate - as  for example clearly states that spam is about commercial advertisement. The only reference to "survey == spam?" is an answer that says "flagged it as spam" - without giving any further arguments why that is appropriate.   Given the severe consequences of flagging as spam - I think a more canonical (argument based) answer is needed.

Is it OK to post a questionnaire on Stack Exchange sites?  I'm currently working on a project at my uni and need some empirical information about workouts. I want to explain more about the project, but that will come if it's "legal" to post a questionnaire here.


Sometimes the symbol := is used to denote a definition. For example, X:=Y+Z means that X is defined to be Y+Z.  When using LaTeX, can I just use $:=$, or do I need to do something special?

I like to use $:=$ for "is defined to be equal to", but this is never typeset with the symmetry one would like, as the colon is always too low relatively to the equals sign. Is there any way of getting this to appear correctly?


I'm using Ubuntu 14.10 and would like to be able to have different screen resolutions on different workspaces. I was thinking of writing a script/daemon that calls xrandr whenever it detects a switch – the question is, how does one detect a change?

I'm using i3-wm on my ubuntu laptop. My screen size is 3200x1800. Which is great for something but horrible for other things. (Netflix vs gvim).  I'd like to change the resolution of one of my work-spaces, or multiple ones. But I have no idea if that is even possible... can I use compton to do this or maybe another program?


Under    settings  text messages  send/receive    I had 3 phone numbers listed - mine and my children.  I am not sure how this setup occurred although they have iPhones that use and are associated with my email and Apple ID.    Recently my Apple ID was changed and I lost this functionality.  I'm wondering how to get these phone numbers back.  I am interested in monitoring my children's texts using this feature.

My sisters and I all have iPhones under the same account. I also have an iPad under the same account. I am trying to get the iMessage on my iPad compatible with my phone number, not email address.   The only phone number choice to choose from is my sister's iPhone number. How can I choose my phone number for iMessage on my iPad?


dropped phone grrr.  Screen cracked, it lights up but, I can't swipe the screen. I have linked to Kies, got my Contacts over, But, I can't seem to find Texts/sms. Any help greatly appreciated. Sue Samsung Galaxy Fame.

I just broke the screen of my (unrooted) Galaxy S.  How do I get back my SMS and contacts?   PS: I tried Kies but it won't detect my phone for some reason. (Kies works fine with another Galaxy I possess but not this one)


The number of real solutions of $2\cos(\frac{x^2+x}{2})=2^x+2^{-x} $  is   (1) 0  (2) 1   (3) 2  (4) infinitely many .  My work :   $$ 1\geq \cos\left(\frac{x^2+x}{2}\right)=\frac{2^x+2^{-x} }{2}\geq 1  \qquad \text{by (AM-GM).} $$  So $\frac{x^2+x}{2}=2n\pi$ for all $n\in \mathbb{Z}$ . Now discriminant $=1+2n\pi$  is always positive for $n\geq0$  . But the equation is a quadratic so it has only two solution . Hence the answer must be 2 .  PS: I'm aware that the this problem is already on the site but i posted as there were no complete solution .

Consider the function   $$ f(x) = 2\cos((x^2+x)/6) - 2^x - 2^{-x}. $$  Clearly $x= 0$ is a root of equation so number of real roots can not be 0 but how to figure out question how many ? From where does this observation start?


For example, "I found that LA is not an island." (Truth always)  or "I ensured them that car insurance is necessary." (Truth in past and now still)  Do I have to use "was" instead of "is" for tense agreement?

I'm describing a situation that happened in the past. To explain it, I want to use a description that is both true now and true when the situation happened.  Specifically, I want something like:     She touched me where my neck met my collarbone.   Since my neck is still attached to my collarbone (thankfully), I'm wondering if I shouldn't use the present tense here instead:     She touched me where my neck meets my collarbone.   Which is preferable, and why?


How can i add datetime.time objects to each other? Lets say i have:  import datetime as dt  a = dt.time(hour=18, minute=15) b = dt.time(hour=0, minute=15)  #c = a+b???   c should be equal to datetime.time(hour=18, minute=30)  Edit:  I have a function that gets as arguments datetime.time objects and should return datetime.time object that is sum of passed arguments. As i am only dealing with hours and minutes i wrote this:  def add_times(t1, t2):     hours = t1.hour + t2.hour     minutes = t1.minute + t2.minute     hours += minutes // 60     minutes %= 60     new_time = datetime.time(hour=hours, minute=minutes)     return new_time   But it is a dirty way and i am sure there is a legit way of doing it.  How do i achieve that?

Given a datetime.time value in Python, is there a standard way to add an integer number of seconds to it, so that 11:34:59 + 3 = 11:35:02, for example?  These obvious ideas don't work:  >>> datetime.time(11, 34, 59) + 3 TypeError: unsupported operand type(s) for +: 'datetime.time' and 'int' >>> datetime.time(11, 34, 59) + datetime.timedelta(0, 3) TypeError: unsupported operand type(s) for +: 'datetime.time' and 'datetime.timedelta' >>> datetime.time(11, 34, 59) + datetime.time(0, 0, 3) TypeError: unsupported operand type(s) for +: 'datetime.time' and 'datetime.time'   In the end I have written functions like this:  def add_secs_to_time(timeval, secs_to_add):     secs = timeval.hour * 3600 + timeval.minute * 60 + timeval.second     secs += secs_to_add     return datetime.time(secs // 3600, (secs % 3600) // 60, secs % 60)   I can't help thinking that I'm missing an easier way to do this though.  Related


You may have played NES Console games when you were younger -- I know I did. I remember playing Duck Hunt, for one:   (source: )    Duck Hunt came with a peripheral called the NES Zapper:    How does it work? How did the NES, which was far less advanced than modern pointing consoles like the Wii, know where we were aiming?

I'm told that the original  works fine on all CRT screens, but fails to register successful hits on a plasma or LCD screen. Why is this? Is there a fix for it?


I completed the online application form for a UK visa. After I hit submit, I realized that the amount of money I wrote on my application is incorrect. Is there anything I can do to make a correction?

I'm from the Philippines, and I plan on travelling to the UK with my sister to visit a relative.  I have just submitted my visa application and have already paid online, when I noticed that I've made a clerical error. In the 'visit or stay' portion of section "Do you have any friends or relatives in the UK?", I clicked the 'no' box, instead of 'yes'.  My sister's application is correct. She selected 'yes'. Our appointment is due next month. I am planning to email them about this, and also inform them on the day of application submission.  Is this the right path to take?


I reinstalled Windows 7 today. I have a live USB with Ubuntu 13.04 made with universal USB manager. I want to install Ubuntu alongside Windows 7.  I have 320GB hard drive in which 100 gig is for Windows (already allocated), 120GB for my files (already allocated), 100GB for Ubuntu (yet to allocate).  I don't get the option dual boot with Windows 7 while trying with live USB (Ubuntu 13.04).   I tried selecting the 100GB unallocated and in NTFS format in the Something Else option, but it says no root file system selected.  Why don't I get the option to install Ubuntu alongside Windows and how can I fix this?

Whenever I startup from the LinuxLive USB, and try to install Ubuntu 12.04, it only gives me two options instead of the usual 3 or 4. My options are "Replace Windows 7 with Ubuntu" and "Something Else". Whenever I go into "Something else", it looks extremely confusing. How do I install it side-by-side while using the "Something else" section? These are my partitions.   /dev/sda /dev/sda1 ntfs (104Mb, System Required Partition) /dev/sda2 ntfs (1000097Mb, Windows 7 Partition)   Or should I try reinstalling my installer on a CD rather than USB and maybe then it will have the "Install alongside" function?


It tried to attack Peter Pettigrew by sensing "it" as evil. I doubt a real-life cat will try to protect it's owner from a threat he is naive about. What is the extent of its magic (it sensed Peter as more than a rodent) and intelligence (its peristent)?

When Hermione first got her pet thing Crookshanks, there was a mention that it looked kinda like a cat, but wasn't.  Was it ever revealed what Crookshanks really was?


Both numbers are above $8,$ their HCF is $8$ and their LCM is $80.$ Find the two possible numbers. I'm very stuck on this question and was wondering if there was an easy way to answer it

These two exercises I encountered recently seem to develop some type of connection between GCD and LCM I can't quite figure out. Exercise 1:  Find all the numbers $x$ and $y$ such that: $a) \ GCD(x,y)=15, \ LCM(x,y)=150$ $b) \ GCD(x,y)=120 \ LCM(x,y)=1320$ $c) \ GCD(x,y)=100 \ LCM(x,y)=990$  Exercise 2:   Find all the numbers $m,n$ such that $GCD(m,n)=pq , \ LCM(m,n)=p^2qs$  where $p,q,s$ are prime  The first thing that is known to me is that $GCD(x,y) \cdot LCM(x,y)= x \cdot y$ Also $LCM(x,y)$ is at most $x \cdot y$ while $GCD(x,y)$ is at most $\max \{x,y\}$. Last thing is that $GCD(x,y)|LCM(x,y)$. Using all this I tried to solve the first exercise: $a)$ First two obvious pairs are $x=15, y=150$ and $y=15, x=150$. Now neither of the numbers can be bigger than $150$ or smaller than $15$. So we are looking for numbers in the range $15-150$ that satisfy $x \cdot y = 15 \cdot 150$ Another such pair is $(x,y)=(30,75), \ (x,y)=(75,30)$. Similarly for $b)$ we find that the only possible values are permutations of the set {$120,1320$} and in $c)$ since $100$ does not divide $990$ no such numbers exist. Now exercise 2 is what made me think there is actually another connection I'm not quite aware of since now it's about arbitrary prime numbers and the previous method doesn't work anymore. My intuition is that it has something to do with $GCD$ or $LCM$ of the $GCD(x,y), \ LCM(x,y)$


Usually there is a format for page titles:  {{page_name}} | {{organization_name}}   Sometimes the delimiter is a bar, a hyphen, a slash...  Sometimes the organization comes first.  I would think that the organization second makes sense, since most websites will have a unique favicon that will act as the organizational logo.  I would also guess that hyphens would work as a delimiter, since it works well in urls to make them more SEO friendly.  Wondering if there are any other thoughts on this.

Are there any best practices for choosing the title of web pages? There are a lot of resources online oriented toward SEO, but not toward users.  My impression is that most sites have something similar to Product - Page. But there are cases when switching this around is more useful. For example, if mail clients displayed the title like this:  Inbox (3) - Gmail  Instead of:  Gmail - Inbox (3)  You would be able to see the message count, even if the title was cut off. (I'm pretty sure Gmail used to do this).  I assume the title is mostly ignored by users except when:   using boorkmarks finding the right tab in the browser   What are the considerations for users when choosing a web page title? Are there different considerations for the home page, pages behind a login, etc?


Does it make sense to keep track of largest known prime?  In other words:  Are there any (more or less practical) situations, where we need the largest known prime? (except of the "situation" of searching of even bigger prime)

It always takes a  and money to find the next . Why is it so important to do this work and what is the application those numbers?


Starting photography was in the back of my head for the last couple of years. Now that a new year is approaching I want to make this happen. I just want to say that I have no idea where do I begin. The only camera that I own at the moment is that of my cell phone.  I am really interested in black/white photography and people seem to think that's a good place to start. I managed to save around 450 euros so that's my budget. Any input you have for me it would be greatly appreciated.

I am new to photography, and need a little advice. I currently have a .   To get rolling, where do I go from here? Does the camera matter? Is this camera enough to start with?


We migrated our site from HTTP to HTTPS. Then we verified our property in search console and submit the new sitemap with HTTPS URLs.   After submission it has the error "Your Sitemap or Sitemap index file doesn't properly declare the namespace."    This appears to be because we used https://www.sitemaps.org/schemas/sitemap/0.9 instead of http://www.sitemaps.org/schemas/sitemap/0.9. Is this really important to use the HTTP version of that URL in sitemap?   That URL is redirected to HTTPS and google is also supporting HTTPS.

I have the schema with this:  <sitemapindex xmlns="https://www.sitemaps.org/schemas/sitemap/0.9">   Is it correct or should be:  <sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">   if all my web pages are on HTTPS?


Suppose we are to cut a unit circle into n equal area pieces. We can cut curves if we wish. What is the minimum distance we must cut? What strategy minimises this distance? Note: The shape of the pieces doesn't matter, nor does the number of cuts.  When n=2, clearly we simply cut a diameter, yielding a distance cut (C) of 2.  When n=3 and n=4, it seems that the optimal cutting method is simply to make equally spaced n radial cuts.  However, there must be a different strategy for some higher n. For instance, with n=10, it would be better to cut a second circle, of area Pi/2, and circumference Pi*sqrt 2, and 5 radial cuts; rather than 10 radial cuts.  So, what is the relationship between n and the distance, and what is the general optimal strategy?

A unit disk is divided into $n$ equal pieces, that is, each piece has area $\dfrac\pi n$.    equal "pieces" means equal  area  Let  $l_1, l_2,\dotsc,l_n$ be the perimeters of the $n$ parts, respectively.   What is the least value of $l_1+l_2+\dotsb+l_n$?   That is, how to calculate $L_n=\min\{l_1+l_2+\dotsb+l_n\}$ ?    For $n=8$, as far as I know, $L_8\lt 2\pi+16$  Any help will be appreciated!


First of all, I searched for info about this on travel.stackexchange and various websites but I can't seem to find a definite and unambiguous answer.  I'm an Afghan citizen traveling to Finland and my flight has a stop in Germany. I have a Finnish residence permit for study, but I haven't entered Finland yet so there is no stamp or anything on my passport.   Will I require a transit visa for the stop? Where can I find more info on this?

I found many related questions on this site but I am still not sure about the rules. How can I decide if I need a visa to transit? Schengen members as of May 2021 are as follows:  Austria Belgium Czech Republic Denmark (excluding Greenland and the Faroe Islands - but an open border with the Schengen Area is maintained) Estonia Finland France (excluding overseas departments and collectivities) Germany Greece Hungary Iceland Italy Latvia Liechtenstein Lithuania Luxembourg Malta Netherlands (excluding Aruba, Curaçao, Sint Maarten and the Caribbean Netherlands) Norway (excluding Svalbard) Poland Portugal Slovakia Slovenia Spain (except Ceuta and Melilla) Sweden Switzerland


Next semester I will take a course about Ring and Module Theory. Can anyone tell me the best texbooks and problems books about it. I only know some famous problems books such as Exercises in Classical Ring Theory, Exercises in Modules and Rings, Exercises in Basic Ring Theory.

I am very interested in studying modules, which I have studied algebra, is basic theory of groups and rings, of Hungerford and Dummit. I was reading the Dummit the module, but I still struggled a bit in the section and the tensor product of exact sequences, as in the book of Atiyah. They know a simple book to begin with?


List<ChartView> data = new List<ChartView>();     var chartData = new object[data.length+1];     chartData[0] = new object[]                    {                        "Chart",                        "Standard",                        "BL"                    };     int j = 0;     foreach (var i in data)     {          j++;          chartData[j] = new object[]                          {                              i.particulars,                             i.originalDocuments,                             i.filingOfEntries,                             i.assessmentOfDuties,                              i.paymentOfDuties,                              i.releasing,                              i.gatePass,                              i.delivery                          };      }   How can i add new data in object without deleting the old data. In the above code charttData[0] have 3 value Chart,Standard,BL. I need to add new string to the set of object. It should become Chart,Standard,BL,Sample.  I am working on dynamic line chart like this. The number of lines must be dynamic it could be 1,2 or morethan 10.   Please note that this question is not about  (which was earlier suggested as duplicate).

How to add new item in existing string array in C#.net?  I need to preserve the existing data.


Can we prove that $\sum_{n=1}^\infty \frac{1}{n^2}=\frac{\pi^2}{6}$ without using Fourier series?

As I have heard people did not trust Euler when he first discovered the formula (solution of the ) $$\zeta(2)=\sum_{k=1}^\infty \frac{1}{k^2}=\frac{\pi^2}{6}.$$ However, Euler was Euler and he gave other proofs.   I believe many of you know some nice proofs of this, can you please share it with us?


As field of reals $\mathbb{R}$ can be made  a vector space over field of complex numbers $\mathbb{C}$ but not in the usual way. In the same way can we make the ring of integers $\mathbb{Z}$ as a vector space the field of rationals $\mathbb{Q}$? It is clear if it forms a vector space, then $\dim_{\mathbb{Q}}\mathbb{Z}$ will be finite. Now i am stuck. Please help me. Thanks in advance.

This is an exercise from Chapter 3 of Golan's linear algebra book.  Problem: Show $\mathbb{Z}$ is not a vector space over a field.  Solution attempt:  Suppose there is a such a field and proceed by contradiction. I will write multiplication $FV$, where $F$ is in the field and $V$ is an element of $\mathbb{Z}$.   First we rule out the case where the field has characteristic 2. We would have   $$0=(1_F+1_F)1=1_F1+1_F1=2$$  a contradiction.  Now, consider the case where the field does not have characteristic 2. Then there is an element $2^{-1}_F$ in the field, and   $1=2_F(2^{-1}_F1)=2^{-1}_F1+2^{-1}_F1$  Now $2^{-1}_F1\in\mathbb{Z}$ as it is an element of the vector space, but there is no element $a\in\mathbb{Z}$ with $2a=1$, so we have a contradiction.  Is this correct?


The 80gb is not in the computer. How do I make it read and use the full tb?

Previously, I have installed Windows 7 on my 320 GB laptop with three partitions 173, 84 and 63 GB each. The 63 GB partition was where the Windows was installed. The rest were for file containers.  Now I changed my OS to Ubuntu 12.04 LTS. I installed Ubuntu by replacing the entire Windows 7 on the 63 GB partition. The rest of the partitions remain as an NTFS Windows partition and I can still access them both (the 173 and 84 GB partitions).  Now I want to change the two partitions of Windows into an Ubuntu format partitions plus most importantly, I want to extend the 63 GB partition to more than a 100 GB because at the moment I am running out of disk space. Whenever I try to install any application, especially using wine, it always complains for a shortage of disk space.  How do I do the extending activity before I entirely format my laptop again and lose all the important files on my partitions?


Let $H$ be a hilbert space over the complex numbers. Let $T:H\to H$ be a linear bounded operator prove that $$\| T\|= \sup_{\| f\|=1} |\langle Tf,f \rangle|.$$   Obviously $\sup_{\| f\|=1} |\langle Tf,f\rangle| \le \| T\|$ by C-S inequality. But how about the other inequality?

I am trying to prove that $\|A\|=\sup_{||x||=1}|\langle x,Ax\rangle|$ for some selfadjoint bounded operator A on a Hilbertspace.  Can anyone give me a hint how to prove it.


I have encountered an issue with my code, while developing a project. I dynamically add a login form to a certain div in the DOM-Tree. It is all nice and fine, all elements are generated and all attributes are added, but I cannot access either of the fields, let alone submit it. Can somebody please spot the issue within? loginArea.click((e) => {     e.preventDefault();      loginArea         .empty()         .append(             $(document.createElement('form'))                 .attr({id: 'user__loginform'})                 .append(                     $(document.createElement('p'))                     .addClass('user__action')                     .text('Please enter your credentials!')                 )                 .append(                     $(document.createElement('input'))                     .prop({                         type: 'email',                         id: 'login_mail',                     })                     .attr({                         placeholder: 'Please enter a valid e-mail adress!',                         required: true,                         form: 'user__loginform'                     })                 )                 .append(                     $(document.createElement('input'))                     .prop({                         type: 'text',                         id: 'login_pw',                     })                     .attr({                         placeholder: 'Please enter a password!',                         minglength: 9,                         maxlength: 16,                         required: true,                         form: 'user__loginform'                     })                 )                 .append(                     $(document.createElement('input'))                     .attr({                         form: 'user__loginform',                         type: 'submit',                         value: 'Login'                     })                 )         ) });  Thank you a lot in advance EDIT: Incorporating the input I have received, I have shortened the function to this, and added .off() at the end. This seems to solve the issue I had, as for now the dynamically generated input can be filled out. signupArea.click((e) => {     e.preventDefault();     let formTemplate = `
             <form id="user__registform">
Please enter your preferred credentials!
                 <input type="email" id="regist_mail" placeholder="Please enter a valid e-mail!" required="required" form="user__registform">                 <input type="text" id="regist_pw" placeholder="Please enter a password!" minglength="9" maxlength="16" required="required" form="user__registform">                 <input form="user__registform" type="submit" value="Register" class="user__regist--submit">             </form>
     `;     signupArea.html(formTemplate);     signupArea.off(); });

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


In  on Hilbert's 10th problem in the March 2008 Notices of the AMS, Bjorn Poonen uses the equation  $$x^{1729}y^{1093}z^{196884} - 163xyzt^{262537412640768000} = 561$$  to suggest how deep the rabbit hole (of integer solutions to polynomial equations) goes. Clearly this is a cheeky equation. I recognize 1729 as the , 163 as the 9th (and greatest) , and 196884 as the linear coefficient in the  (and so, by Monstrous Moonshine, also 1 more than the degree of the smallest irreducible representation of the Monster group). Of course this made me curious about the others. Internet searches told me that 1093 is the smallest  and  262537412640768000 appears in the  for fast approximation of $\pi$. But all I could find out about 561 was that it's the area code of Palm Beach, FL.     What's the number-theoretic significance of 561?   Addendum: This question has been marked as a duplicate of  asking "Why is 561 the smallest Carmichael number?" This is not a duplicate of that question, since a person who has the present question (as I did when I asked it) does not know that 561 is the smallest Carmichael number.

A composite integer n is a Carmichael number if the only Fermat   witnesses for $n$ are those $a \in \mathbb Z_n^+$ which are not   coprime with $n$. The smallest example of such a number is $561 = 3 ·  11 · 17$   I think I understand the definition, but I don't quite understand why is the smallest Carmichael number is the above mentioned number. Please clarify.


I'm getting the following error while updating:  W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/natty-backports/main/binary-i386/Packages  404  Not Found W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/natty-backports/restricted/binary-i386/Packages  404  Not Found W: Failed to fetch gzip:/var/lib/apt/lists/partial/in.archive.ubuntu.com_ubuntu_dists_precise-security_main_binary-i386_Packages  Hash Sum mismatch E: Some index files failed to download. They have been ignored, or old ones used instead.   If I try to update from update manager it shows: Failed to download repository information Check your Internet connection.  I have absolutely no idea what to do next. Please help.

When I check for updates, I get a "Failed To Download Repository Information" error.   This is what comes up under details:   W: Failed to fetch gzip:/var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_natty_main_source_Sources  Hash Sum mismatch,  E: Some index files failed to download. They have been ignored, or old ones used instead.


I have a polygon with a North_America_Lambert_Conformal_Conic coordinate system and a point shapefile which had a WGS 1984(DD) coordinate system.   I defined projection and projected both of them to North_America_Lambert_Conformal_Conic coordinate system. The two shapefiles do not overlay. If checked in the screen shot of ArcGIS 10.2, only one of the layer appears (whichever I have zoomed to).  Can someone please guide me on how I can get this to shapes to line up or overlay?   My intention is to do a spatial join on them so that I can count some point features within the polygons.

I put 4 different layers into my ArcMap document, but only one of them will show up on the map! I should be seeing the other 3 layers as well. When I do a Zoom to layer, I can see one layer, but I cannot figure out how to make the other 3 show up at once on top of each other.  Before I opened ArcMap, I used ArcCatalog where I right-clicked 3/4 of the shapefiles and  clicked Properties → Coordinate system → Import and then clicked on my Trees layer, which has the coordinate system I want the other 3 to have. But when I opened ArcMap the 4 layers did not overlap, nor could I move them above or below each other.


I had submitted a manuscript to an Elsevier Journal in February 9, 2016. Usually it takes time of around 1 week to get the manuscript number assigned something like XXXX-D-16-XXX and status changes from "Submitted to Journal" to something else like "With Editor".  However, after waiting for 1.5 months, it didn't change and no number is assigned. Hence, I mailed to the Elsevier support. They replied with as usual "we forwarded your query to journal manager...". I waited for 15 more days. I mailed again. No reply from journal side. The mailing happened 3-4 times with follow-ups and remainders, but, it was only from my side. Still no response from Journal.  I also sent mail to chief editors very politely and waited for status to come from their side. But, after 10 more days of waiting no response came.  I sent final mail stating that "We are withdrawing our manuscript."  Is this type of behavior expected from reputed publisher like Elsevier. One research student can't waste 3 months of time biting nail to get the manuscript number or a response.  Please do help with your suggestions? What should I do? Should I submit to another journal? Please note that I have not yet obtained the confirmation of my manuscript withdrawn from the journal.  This is not a duplicate question. I searched thoroughly academia.SE before posting question.

What steps does a manuscript typically go through from submission to publication (or rejection) in a typical journal? How are these steps referred to, in particular by editorial systems, and how long do they each typically take?  Note that this question is about the typical situation and hence not about:   Journals with an atypical workflow, e.g. those that allow for an instantaneous reviewer–author interaction. Exceptional steps or rare occurrences such as withdrawal or .   This is a canonical question on this topic as per . Due to its nature, it is rather broad and not exemplary for a regular question on this site. Please feel free to improve this question.


I am working an application with Java, Hibernate and Postgres. The point of my question is the pass of throws because I don't catch Exception generated, ¿What I must correct?  public void seleccionarEquipo() throws Exception {     try{          this.integrantes = consultarIntegrantes();     }catch(Exception e){         System.out.println("{ERROR: " + e.toString() + "}");     } }  public List<Usuario> consultarIntegrantes() throws Exception {     System.out.println("calling...");     List<Usuario> usuarios = new ArrayList<Usuario>();     Session session = NewHibernateUtil.getSessionFactory().openSession();     Transaction transaction = session.beginTransaction();     try {         System.out.println("try...");         Query query = session.createQuery("Anything");         usuarios = query.list();     } catch (Exception e) {         System.out.println("error detected");         throw e;     }finally{         transaction.commit();         session.close();         return usuarios;     } }   Output:  Info:   calling... Info:   try... Info:   error detected   My application doesn't execute: System.out.println("{ERROR: " + e.toString() + "}");. What I do?  Thank you!

I was surprised recently to find that it's possible to have a return statement in a finally block in Java.  It seems like lots of people think it's a bad thing to do as described in ''. Scratching a little deeper, I also found '' which shows some pretty horrible examples of other types of flow control in finally blocks.  So, my question is, can anyone give me an example where a return statement (or other flow control) in a finally block produces better / more readable code?


I have this little problem, that I cannot figure out which arguments to pass to Type.GetMethod in order to get back the MethodInfo of a generic method on a non generic type. Specifically, I have this type definition:  public static class A {   public static B F<T>(bool dummy)   {   }   public static B F<T>(IEnumerable<T> arg)   {   ...   } }   I have tried several takes at Type.GetMethod, but none would return the MethodInfo of the F method.  I am aware that I can invoke Type.GetMethods or even Type.FindMember, but I am interested in Type.GetMethod.  Any ideas?  Thanks.  EDIT  Actually, my code is a bit more complex. The generic method is overloaded, so I cannot use the Type.GetMethod with just the function name. I tried these variants:  typeof(A).GetMethod("F", BindingFlags.Static | BindingFlags.Public, null, new Type[]{ typeof(IEnumerable<>) }, null) typeof(A).GetMethod("F`1", BindingFlags.Static | BindingFlags.Public, null, new Type[]{ typeof(IEnumerable<>) }, null) typeof(A).GetMethod("F[T]", BindingFlags.Static | BindingFlags.Public, null, new Type[]{ typeof(IEnumerable<>) }, null) typeof(A).GetMethod("F[[T]]", BindingFlags.Static | BindingFlags.Public, null, new Type[]{ typeof(IEnumerable<>) }, null)

Consider type like this one  public interface IHaveGenericMethod {    T1 Method<T1>(T1 parm);    T2 Method<T1,T2>(T1 parm);    int Method2(int parm); }   How do I get a methodInfo for its methods? for a regular non-generic method, like method2, I can go with  typeof(IHaveGenericMethod).GetMethod("methodName",new Type[]{typeof(itsParameters)});   for a generic method though, I can't, since it's parameters are not types per-se. So, how do I do that? I know that I can call  typeof(IHaveGenericMethod).GetMethods()   to get all methods of that type, and then iterate over that collection and do some matching, but it's ugly. Is there a better way?


I am using Drupal 7 and want to export my Drupal database from local and import this database on another server.  The issue I'm facing is the exported database size is 80M and the server importation limit is 32M (I do not have any permission to increase the limit size).  Can I just truncate tables like cache_fields, menu...etc?  The watchdog table is 40M in size, can I clear it ?

I have inherited a client site that has an extremely large database for no reason. There is a moderate amount of content and very little enabled modules. However, the database is too large for moving around easily and I want to clean it out.  I have cleared out the standard cache tables, syslog and accesslog.  Are there any other tables I can safely truncate in a standard Drupal site?


I didn't lose the Downloads folder, just the files. When I clicked inside the folder, poof! Everything just disappeared, leaving nothing but an empty Downloads folder. They're not in Trash. When I do Command-R and load an older backup. Same thing! It shows me the files are there, but when I click to enter the folder, everything inside Downloads disappears, again.   I've lost the Downloads folder itself a few times before and was always able to drag it back into the window. Now the problem has a new wrinkle. Dang it! Anybody have a solution?  $ ls ~ Desktop Documents Downloads DownloadsTHAT'S THE WAY THE WIND BLOWS BY JOHN LATINI, YPSILANTI, MI Dropbox Library Movies Music Pictures Public hewletts 2018.dvdcrtproj iCloud Drive (Archive)  $ ls ~/Downloads ~$2018_ KATHYFORSTE.docx  Harrys-iMac:~ harryhewlett$ ls ~/Downloads Downloads/ DownloadsTHAT'S THE WAY THE WIND BLOWS BY JOHN LATINI, YPSILANTI, MI/ Harrys-iMac:~ harryhewlett$ ls ~/Downloads Downloads/ DownloadsTHAT'S THE WAY THE WIND BLOWS BY JOHN LATINI, YPSILANTI, MI/ Harrys-iMac:~ harryhewlett$ ls ~/Downloads  Harrys-iMac:~ harryhewlett$ ls -lF ~ total 0 drwx------@  4 harryhewlett  staff   128 Dec 20 06:39 Desktop/ drwx------@ 14 harryhewlett  staff   448 Feb  2  2018 Documents/ drwx------+  5 harryhewlett  staff   160 Dec 20 06:44 Downloads/ drwxr-xr-x   3 harryhewlett  staff    96 Dec  5 18:45 DownloadsTHAT'S THE WAY THE WIND BLOWS BY JOHN LATINI, YPSILANTI, MI/ drwx------@ 43 harryhewlett  staff  1376 Dec 20 06:43 Dropbox/ drwx------@ 71 harryhewlett  staff  2272 Dec 24 04:09 Library/ drwx------+ 12 harryhewlett  staff   384 Sep 15 16:12 Movies/ drwx------+ 10 harryhewlett  staff   320 Oct 19 12:39 Music/ drwx------+ 14 harryhewlett  staff   448 Nov  2 22:22 Pictures/ drwxr-xr-x+  5 harryhewlett  staff   160 Jun 29  2015 Public/ drwxr-xr-x@ 10 harryhewlett  staff   320 Jun 14  2018 hewletts 2018.dvdcrtproj/ drwxr-xr-x  21 harryhewlett  staff   672 Feb  2  2018 iCloud Drive (Archive)/ Harrys-iMac:~ harryhewlett$  Harrys-iMac:~ harryhewlett$ ls -lF ~/Downloads total 8 -rw-r--r--@ 1 harryhewlett  staff  162 Oct 17 15:33 ~$2018_ KATHYFORSTE.docx Harrys-iMac:~ harryhewlett$   Harrys-iMac:~ harryhewlett$ ls -l ~/Downloads* /Users/harryhewlett/Downloads: total 8 -rw-r--r--@ 1 harryhewlett  staff  162 Oct 17 15:33 ~$2018_ KATHYFORSTE.docx  /Users/harryhewlett/DownloadsTHAT'S THE WAY THE WIND BLOWS BY JOHN LATINI, YPSILANTI, MI: Harrys-iMac:~ harryhewlett$

I did something stupid apparently and lost my Downloads folder both from Dock and then when I opened Finder to drag it down to the Dock it somehow got deleted in the desktop.  Now although I can see the folder exists (e.g. by searching in Spotlight) I do not know how to restore it in the Dock and in Finder as well. Any help please?


We're going to implement what I consider to be a fairly large and processor intense application in a few months and our Windows team is recommending that we deploy it on VM Ware.  The application will have 5000 users, most of which will be running this application all day as the primary application they need to do their job.  They will be scanning images which will be sent up to this application for processing.    The application has 4 parts: A web server, an extract server, an application server and a database server.  The application server will be bearing the burden of doing optical character recognition against the 2 to 3 million images per day.   The application software vendor has not certified on VM and they don't have any experience with VM, although they seem to be open to supporting us on it.    I am not too concerned about the web servers or extract servers.  But the application server part of the application states that it requires 3 Windows servers with 20 CPU cores and 32GB of RAM each.  The SQL Server database also requires 20 CPU cores and 32GB.     I am not concerned about the network.  We have a fast network and these images are not going to be very large.  I am mostly concerned with CPU (for OCR) and I/O since all of these images need to be written to the database.    We do have a large VMWare platform (using the latest VMWare software) running hundreds of small applications, but our new application will be the largest by far.  The current largest application that we currently have on VM only has about 200 users.  So, we are concerend that we're going to push our VMWare environment much harder than it has ever been driven before.  And I want to make sure that our end users are not impacted in any way by growing pains (e.g. slowness, outages) as we learn how to support this large application on VMWare.    My questions now are as follows.   Would we be better off running this on dedicated Windows machines rather than in a shared VMWare environment, at least at first? Alternatively, should we insist on having our own dedicated VMWare platform at first so that we're not sharing with other applications during the roll-out period.  And then once we see how it performs and how many resources it really needs, then we can start considering sharing. If we do decide to run on VMWare, what are the likely downsides?  For example, is it likely that the end users will experience slower performance?  I've read that VMWare can introduce latency.   Should we bring in a consultant from VMWare to analyze our environment to make sure that it's properly sized and tuned?   Any recommendations on how best to proceed or other things to consider would be greatly appreciated.

This is a  about  Related:      I have a question regarding capacity planning. Can the Server Fault community please help with the following:   What kind of server do I need to handle some number of users? How many users can a server with some specifications handle? Will some server configuration be fast enough for my use case? I'm building a social networking site: what kind of hardware do I need? How much bandwidth do I need for some project? How much bandwidth will some number of users use in some application?


Find the value of $\cos 1^\circ + \cos 2^\circ + \cos 3^\circ +.....+\cos 180^\circ $  My Attempt: $$=\cos 1^\circ + \cos 2^\circ + \cos 3^\circ +....+\cos 180^\circ $$ $$= \cos 1^\circ + \cos 2^\circ + \cos 3^\circ +....-1$$  How do I complete it?

Possible Duplicate:          Prove $$\cos(\alpha) + \cos(\alpha + \beta) + \cos(\alpha + 2\beta) + \dots + \cos[\alpha + (n-1)\beta] = \frac{\cos(\alpha + \frac{n-1}{2}\beta) \cdot \sin\frac{n\beta}{2}}{\sin\frac{\beta}{2}} $$


I am looking for a word to describe a situation where one wants to do good things but ends up with something bad.  It generally happens with me, I always think of doing something good but sometimes end up with something bad.

I want to say "someone (or something) intends to help, but instead it makes things worse". Is there any succinct expression or phrase for this?  Thanks.


I recently had this integral in my homework and don't really know how to proceed.   $\int^1_0\frac{\ln (1+x^{2+ \sqrt3})}{x+1}dx$  So far I figured that $ \int^1_0\frac{\ln (1+x^{a})}{x+1}dx= \int^1_0\frac{\ln (1+x^{-a})}{x+1}dx+a\frac{\pi^2}{12}$,   but this doesn't seem too useful.

I am trying to find a closed form for  $$\int_0^1 \frac{\log \left( 1+x^{2+\sqrt{3}}\right)}{1+x}\mathrm dx = 0.094561677526995723016 \cdots$$  It seems that the answer is $$\frac{\pi^2}{12}\left( 1-\sqrt{3}\right)+\log(2) \log \left(1+\sqrt{3} \right)$$  Mathematica is unable to give a closed form for the indefinite integral.  How can we prove this result? Please help me.  EDIT  Apart from this result, the following equalities are also known to exist: $$\begin{align*} \int_0^1 \frac{\log \left( 1+x^{4+\sqrt{15}}\right)}{1+x}\mathrm dx &=\frac{\pi^2}{12} \left( 2-\sqrt{15}\right)+\log \left( \frac{1+\sqrt{5}}{2}\right)\log \left(2+\sqrt{3} \right) \\ &\quad +\log(2)\log\left( \sqrt{3}+\sqrt{5}\right) \\ \int_0^1 \frac{\log \left( 1+x^{6+\sqrt{35}}\right)}{1+x}\mathrm dx &= \frac{\pi^2}{12} \left( 3-\sqrt{35}\right)+\log \left(\frac{1+\sqrt{5}}{2} \right)\log \left(8+3\sqrt{7} \right) \\ &\quad +\log(2) \log \left( \sqrt{5}+\sqrt{7}\right) \end{align*}$$  Please take a look .


This might be a super stupid question, but my math courses are long gone and I am stuck completely solving some math puzzles for fun. Just as a hobby, no homework involved.  I want to calculate the number of ways N coins can be partitioned. I have learned that there is an extra section of  for this and Euler was involved too, of course.  I can calculate the generalized pentagonal numbers using  $$ g_k = k(3k-1)/2 $$  but I have no clue how to calculate an actual value for $P(n)$. I see a lot of endless series but no solution. Could someone point to to some resources on how to work actually with these?

The function p(n) counts the number of ways a number can be made up of smaller numbers. For example, the p(5) = 7 because you can make 5 in the following ways:  1-1-1-1-1  1-1-1-2  3-2  3-1-1  2-2-1  1-4  5  According to Wikipedia, the generating function for this, counting the possible partitioning of a number, is as follows:    After much effort, I have been unable to make any sense of this, or contort it in such a way that it actually answer the question: what is p(n) when n = 1000?. There is a great deal about this expression that I do not understand. Please answer any of the following which, given your expertise, you can.   n is the argument of this function, the number for which we are counting the partitions. What is x here? Where does it come from? Same for k? What is the significance of k? Why does it go from 1 to infinity?  What is the significance of the small dot on the right side? We see the sign on the left "Sigma" so often, but the sign on the right (Big Pi) appears, at least for me, in very few places. Why is this? On the right we see that we get the product of the expression for every value of k from = 1 to infinity. How does this make sense? If we go from 1 to infinity, isn't the resulting value necessarily infinite? It is known that actually getting a series of numbers from a generating function can be non-trivial. Is it even possible to solve for p(n) using this equation? Or does it simply explain the pattern with no means of getting the numbers? How can this be implemented in a computer language, one that is general, and not math-based, for example in Python, or in JavaScript? Is it possible? Can you provide an implementation of this generating function in computer code? (See PS) What is p(1000)? How do you know? Generally, in solving generating functions, using a "Taylor series" is proposed as a possible solution. How would you explain this to someone who does not know what a Taylor series is? Is this problem even solvable without a deep knowledge of that subject? Is it correct to call this an "equation"? Or is a generating function fundamentally a different thing?   PS I am asking this question because it is my hobby. I am NOT in a university and asking you to do my work, NOR am I employed, either as a mathematician or otherwise. This is fun for me, and I hope answering it is fun for you!


Here's the problem:   Prove that $(a,b,c) = ((a,b),c)$, where $(\cdot)$ denotes the GCD.  This problem looks so trivial at staring, but rigorously proving it turns out to be difficult task for me. I know of $2$ ways of defining GCD (of, say $b$ and $c$): The least positive value of $(bx_1 + cy_1)$; or the common divisor which is divisible by every other common divisor. This definition can extend to more than $2$ numbers also. So, I let $g$ be any common divisor of $a$, $b$ and $c$, and $G$ be the greatest of them. Hence, matters are left to merely proving $G = ((a,b),c)$. It is quite easily seen that $G|(a,b)$ and $G|c$. Hence, $G|((a,b),c)$. But it leaves the proof to: $((a,b),c)|G$, which I can't prove. Perhaps it is proving: $g|((a,b),c)$, for any $g$ (which is defined above). This can lead to another proof, but I didn't find a way out! Please help!

Prove $\gcd(a,b,c)=\gcd(\gcd(a,b),c)$ for $0\ne a,b,c\in \Bbb{Z}$. I tried solving it with sets but I sense there are some details I am missing. I would truly appreciate your reference.