Linked Questions

5 votes
0 answers

The inverse function of "Prime" [duplicate]

Consider p such that PrimeQ[p] == True. How do I compute n such that Prime[n] == p? In other words, what is the inverse ...
Jorge Leitao's user avatar
2 votes
0 answers

What are the limits of the Prime-functions? [duplicate]

Will Prime and PrimePi test up to 3 * 10^12? Where can I find the limits for these funtions? ...
martin's user avatar
  • 8,678
5 votes
0 answers

How Prime[n] is implemented and why is that bounded? [duplicate]

How is Prime[n] implemented in Mathematica? I have just observed that calculating large primes is quite fast (but not in O(1) ...
mvxxx's user avatar
  • 151
2 votes
0 answers

Why can't I use OmegaPrime to find the Limit of Prime[n]? [duplicate]

I've looked at these links already; What are the limits of the Prime-functions? What is so special about Prime? which gave an answer for earlier versions of Mathematica. Yet when I try to input ...
user24719's user avatar
  • 137
2 votes
0 answers

Internals of Prime function [duplicate]

Does anyone knows how exactly Prime works ? For example how Prime[1000000000] is calculated ? The only information I found was ...
Oto's user avatar
  • 61
0 votes
0 answers

Largest n in Prime[n] [duplicate]

What is the largest integer $n$ that the function Prime[n] can take?
Jamai-Con's user avatar
  • 153
21 votes
5 answers

How to find the domain and range of a function with Mathematica?

I'm studying calculus and in some exercises I am asked to find the domain and range of a function. Does Mathematica have already a built-in function for this? I can imagine some ways of doing so, ...
Red Banana's user avatar
  • 5,329
13 votes
5 answers

Double series over primes

I'm very curious if the following double series over primes has a closed form: $$\sum_{k \in \mathcal{P}}\sum_{n \in \mathcal{P}}\frac{1}{k\;n(k+n)^2}$$ where $\mathcal{P}$ denotes the set of all ...
user 1357113's user avatar
  • 1,415
8 votes
4 answers

Determining occurrence of a sequence of numbers in the first 50,000 primes

I have to determine how many of the first 50,000 prime numbers (digits) contain the sequence 5, 4, 3, in that order. The numbers don't have to necessarily be consecutive. For example, 566453 is a ...
Claire's user avatar
  • 161
10 votes
4 answers

Generate PrimePower counting function

Is there a way to generate a counting function for prime powers - i.e. to create a similar function to PrimePi, but including prime powers. The following will, of ...
martin's user avatar
  • 8,678
20 votes
2 answers

Parallelization problem in LinearSolve and Minimize

My CPU has got 8 cores (it is Intel Core i7-2600 3.40 GHz). When I try to solve a linear matrix equation using LinearSolve for large matrices, Mathematica just uses 4 cores to solve the problem (CPU ...
mak maak's user avatar
  • 369
15 votes
2 answers

Why does iterating Prime in reverse order require much more time?

Say I would like to display the $10$ greatest primes that are less than $10^5$. I could do the following: ...
cartonn's user avatar
  • 1,005
7 votes
2 answers

Approximation to the prime counting function

Is there a function similar to PrimePi that gives approximate value for large numbers? In particular, I need a reasonably good approximation for $\pi(x)$, where $x\...
user avatar
5 votes
2 answers

Can I use NextPrime[n] up to n=10^14?

I would like to perform computations with primes up to $n=10^{14}$. To do so, I would like to go through all primes, from $2$ to $10^{14}$ and perform some calculation on each prime. I saw that one ...
Klangen's user avatar
  • 1,009
5 votes
3 answers

Prime factor counting function

Is there any way I can speed up this prime factor counting function? (I am looking for all numbers in a range with 3 prime factors (counted with multiplicity).) ...
martin's user avatar
  • 8,678

15 30 50 per page