Is there any elegant function f such that f(n) is the n th prime? I found many function generating prime numbers but all of them uses the knowledge of n-1 prime numbers that we already found or in a more inefficient way.  My question is not about existence of prime generating function but about the efficiency of such functions. Neglecting all other overheads, just the need to use all previously found primes making any algorithm to have $\Omega(n^2)$ running time.  Is there any efficient formula? If not, is there any argument supporting that you have to use all n-1 primes?
Is there a known mathematical equation to find the nth prime? I've solved for it making a computer program, but was wondering there was a mathematical equation that you could use to solve for the nth prime?
I am trying to change the page size in the QGIS 3.0 Composer but I am not able to see the Composition tab.  I have right clicked an empty space in the toolbar but did not see anything about composition.  I am using Windows 7.  I tried looking at the QGIS docs but they are still in testing. Few days back I have installed ecryptfs, created a private directory using it. Now my Ubuntu login became super slow. I have tried removing ecryptfs from Synaptic. I found It, it can not be deleted that way. Somewhere I have read about this command  ecryptfs-setup-private --undo   But this command displays a rather confusing list of commands on terminal. I don't want to mess up my installation, neither want to loose my administrator account.  Now my question is, how can I safely remove /home/user/Private (.Private) and remove ecryptfs encryption ? What is the maximum value of $n$ if $n + 5$ divides $n^5 + 5$, $n$ being a natural number? I tried to solve by binomial theorem but it failed. I wish to familiarize myself with the capabilities of QGIS up to and beyond QGIS version 3.0.   Can you recommend some good web resources and tutorials that would show me QGIS' capabilities?   I am interested in both using QGIS through its GUI and in developing applications using QGIS. How can I get the Cartesian product (every possible combination of values) from a group of lists?  Input:   somelists = [    [1, 2, 3],    ['a', 'b'],    [4, 5] ]   Desired output:  [(1, 'a', 4), (1, 'a', 5), (1, 'b', 4), (1, 'b', 5), (2, 'a', 4), (2, 'a', 5) ...] Importing google-play-services lib into Intellij IDEA 12 (and 13) Proof Verification: Converse of Intermediate Value Theorem Writing to NTFS drive in Linux I've got an external USB drive that is formatted with NTFS mounted on ~/tmp.  I can read it just fine, but cannot write to it, even as root (temp is a folder on the USB drive):  [root@Plugbox temp]# touch test touch: cannot touch `test': Permission denied [root@Plugbox temp]#   However, if I do a cat /proc/mounts, it looks like I do have NTFS read/write support:  [root@Plugbox temp]# grep /dev/sdb1 /proc/mounts /dev/sdb1 /root/tmp ntfs rw,relatime,uid=0,gid=100,umask=02,nls=utf8,errors=continue,mft_zone_multiplier=1 0 0 [root@Plugbox temp]#   Finally, if I go to the folder above temp, it looks like I should have plenty of permissions to write to the folder:  [root@Plugbox tmp]# ls -al total 61500764 ... drwxrwxr-x 1 root users           0 Apr 19  2010 temp ... [root@Plugbox tmp]#   What am I missing? How Can I add HTML And CSS Into PDF I have an HTML (not XHTML) document that renders fine in Firefox 3 and IE 7.  It uses fairly basic CSS to style it and renders fine in HTML.  I'm now after a way of converting it to PDF.  I have tried:   : it had huge problems with tables.  I factored out my large nested tables and it helped (before it was just consuming up to 128M of memory then dying--thats my limit on memory in php.ini) but it makes a complete mess of tables and doesn't seem to get images.  The tables were just basic stuff with some border styles to add some lines at various points; : I actually had better luck with this.  It rendered some of the images (all the images are Google Chart URLs) and the table formatting was much better but it seemed to have some complexity problem I haven't figured out yet and kept dying with unknown node_type() errors.  Not sure where to go from here; and : this seems to work fine on basic HTML but has almost no support for CSS whatsoever so you have to do everything in HTML (I didn't realize it was still 2001 in Htmldoc-land...) so it's useless to me.   I tried a Windows app called Html2Pdf Pilot that actually did a pretty decent job but I need something that at a minimum runs on Linux and ideally runs on-demand via PHP on the Webserver.  What am I missing, or how can I resolve this issue? Prove that $\lambda = 0$ is an eigenvalue if and only if A is singular. I'm trying to prove that statement: Prove that $\lambda = 0$ is an eigenvalue if and only if $A$ is singular.  I'm not sure if my proof is totally correct:  Suppose that $\lambda = 0$ if det(A) = $\lambda_1 \cdot \lambda_2 . . .\lambda_n = 0$ then A is singular.  If anyone could show me a better proof that would help. Is GNU's Java Compiler (GCJ) dead? Vote to close a deleted question - bug? I just successfully added my Close vote to a question on Stack Overflow that had already been deleted by the author.  The question can be found .        The only purpose I see for such functionality is perhaps to stop someone from escaping the initial surge of wrath from critics, then subsequently undeleting their question.  And that would be a pretty strange thing to guard against.  It seems far more likely that this is an oddity that was overlooked.  So I'm just curious - is voting to close a deleted question a bug, or is it ?  If by design, what is the rationale behind it? Does untapping an attacker stop its attack? How can I prove that the Cartesian product of two countable sets is also countable? What should children call a step-grandparent? My mom remarried to a great guy who has been absolutely wonderful to my kids. Ever since my mom and he were dating my kids have called him Mr. Joe. Lately my mom has been bugging me to get the kids to call him Grampa.  I agree that he deserves more respect than Mr.  The problem is that he isn't their real grampa so I don't really want them calling him that. Does anybody have any suggestions on what we should have the kids call him? They are 9 and 12 years old.  EDIT: I appreciate the comments regarding different variations of grampa and hearing how others have no issues with calling their step-granddad grampa. But I was hoping maybe someone has some suggestions for names that show the importance of the step-granddad without calling him some variation of the grampa name but still has a feeling of warmth and family in the name (I hope that makes sense). create multilingual node programmatically i'm trying to create a multilingual node using a php script.  I'm doing this:   $node = new stdClass();  $node-&gt;title = "Test ".mktime();  $node-&gt;type = "job";  $node-&gt;language = 'de'; // Or e.g. 'en' if locale is enabled  $node-&gt;uid = $user-&gt;uid;   $node-&gt;status = 1; //(1 or 0): published or not  $node-&gt;promote = 0; //(1 or 0): promoted to front page  $node-&gt;comment = 1; //2 = comments on, 1 = comments off  $node-&gt;path = array('alias' =&gt; 'das-ist-ein-test-'.mktime());  $node-&gt;body[$node-&gt;language][0]['value']   = "Body Body Body";  $node-&gt;body[$node-&gt;language] = text_summary("Body Body Body");  $node-&gt;body[$node-&gt;language]  = 'filtered_html';  node_save($node);   As long as i set $node->language to 'und' everything is working fine. But as soon as I set the language to 'de' or 'en' (both languages are activated in my Drupal installation) the body text doesn't get saved.  So my question is: can anybody provide me with a working example of how to store a multlingual node (de,en) into Drupal using program code.  Thank you Can't install Oracle JDK 9 I uninstalled jdk packages and now can't install them back. I managed to install oracle-java7-installer and oracle-java8-installer but can't install oracle-java9-installer. It seems that my computer tries to download wrong version of oracle-java9-installer 177 when version i would be able to download is 178.    $ wget http://download.java.net/java/jdk9/archive/178/binaries/jdk-9+178_linux-x64_bin.tar.gz --2017-07-21 11:00:02--  http://download.java.net/java/jdk9/archive/178/binaries/jdk-9+178_linux-x64_bin.tar.gz Connecting to 10.144.1.10:8080... connected. Proxy request sent, awaiting response... 200 OK Length: 293348142 (280M) [application/x-gzip] Saving to: 'jdk-9+178_linux-x64_bin.tar.gz'  jdk-9+178_linux-x64_bin.tar.gz     1%[&gt;                                                          ]   5.42M  5.04MB/s               ^C  $ wget http://download.java.net/java/jdk9/archive/177/binaries/jdk-9+177_linux-x64_bin.tar.gz --2017-07-21 11:00:16--  http://download.java.net/java/jdk9/archive/177/binaries/jdk-9+177_linux-x64_bin.tar.gz Connecting to 10.144.1.10:8080... connected. Proxy request sent, awaiting response... 404 Not Found 2017-07-21 11:00:17 ERROR 404: Not Found.   Can you help? apt-get tries to install Oracle JDK 9.  I run Ubuntu 16.04 in virtual machine hosted by win7  Full error message:  sudo apt-get install oracle-java9-installer Reading package lists... Done Building dependency tree        Reading state information... Done oracle-java9-installer is already the newest version (9b177-1~webupd8~0). 0 upgraded, 0 newly installed, 0 to remove and 147 not upgraded. 1 not fully installed or removed. After this operation, 0 B of additional disk space will be used. Do you want to continue? [Y/n] Y Setting up oracle-java9-installer (9b177-1~webupd8~0) ... Using wget settings from /var/cache/oracle-jdk9-installer/wgetrc Downloading Oracle Java 9... --2017-07-21 10:54:11--  http://download.java.net/java/jdk9/archive/177/binaries/jdk-9+177_linux-x64_bin.tar.gz Connecting to 10.144.1.10:8080... connected. Proxy request sent, awaiting response... 404 Not Found 2017-07-21 10:54:13 ERROR 404: Not Found.  download failed Oracle JDK 9 is NOT installed. dpkg: error processing package oracle-java9-installer (--configure):  subprocess installed post-installation script returned error exit status 1 Errors were encountered while processing:  oracle-java9-installerE: Sub-process /usr/bin/dpkg returned an error code (1) Show that $f(z)=0$. Suppose that $f:\mathbb{C}\rightarrow\mathbb{C}$ is analytic on the open unit disc and continuous on the closed unit disc. Assume that $f(z)=0$ on an arc of the circle $\{z\in\mathbb{C}:|z|=1\}$. Show that $f(z)=0$. Prove that $\frac{1}{\sin^2 z } = \sum\limits_{n= -\infty} ^ {+\infty} \frac{1}{(z-\pi n)^2} $ Android app "Unknown error" when uploading photo Spent a half hour on this. Android 5.1.1 latest version SE app (Play Store won't let me update so latest).   Tried to upload photo into an answer. "Something went wrong".  Did tricks to reduce photo size to 275k -- same.    45k rep on the stack.  Here is the photo..... oh wait.  How do I solve?