# K-th Twin prime

1. Sep 3, 2006

### lokofer

k-th "Twin prime"...

Is not there a formula for the k-th "twin prime" ?..as far as i know for the normal primes satisfying "Wilson's theorem":

$$(p-1)!+1=mod(p)$$ you can get an "exact" (but difficul to compute) formula in the form:

$$p_k = \sum_{n=2}^{2^{k}}(\frac{k}{1+\pi(n)})^{1/n}$$ or similar..

But Why is not there this formula for the "twin primes" ? in fact they also satisfy a congruence....:grumpy:

2. Sep 3, 2006

### HallsofIvy

Staff Emeritus
If there were a formula for the "nth twin prime" then there would be a proof that there exist an infinite number of twin primes wouldn't there?

3. Sep 4, 2006

### lokofer

- The question is "hallsoftivy" why you can get a formula for the k-th "normal" prime (see mathworld) from the "congruence" equation but you can't get a similar one for the k-th "twin" prime...

4. Sep 4, 2006

### CRGreathouse

HallsofIvy was just showing that a solution to your problem would be a solution to a major unsolved problem, and as such
1. It's unsolved
2. It's hard.

5. Sep 4, 2006

### shmoe

What he's asking for wouldn't necessarily solve the twin prime problem. It's not hard to come up with an elementary looking sum (or rather a sum using only elementary functions) for the counting function of the twin primes, but it's not something that you can work with at all effectively.

You might want to take a moment and prove that the expression you have there for the kth prime works. What known facts about the primes are necessary? Are analagous results known for twin primes?

6. Sep 5, 2006

### lokofer

- By the way as it happens with "normal" primes.... the set of twin primes satisfy a congruence:

$$4((m-1)!+1)+m=0 mod (m(m+2))$$

EDIT: If i'm not wrong the "twin prme number function " using the expression above is:

$$\pi_{2} (n)= A+ \sum_{k=2}^{n}[cos^{2}(\pi)([\frac{ 4((k-1)!+1)+k}{k(k+2)}]- \frac{4((k-1)!+1)+k}{k(k+2)})]$$

[x]=floor function.

Last edited: Sep 5, 2006
7. Sep 5, 2006

### CRGreathouse

How would that not prove the twin prime conjecture? If there was a formula for the kth twin prime there must be infinitely many, right? Even if the formula is computationally worthless if it's valid it would be enough.

Now a n&s condition wouldn't be enough, of course; I presume that's what jose claims this formula is. (It's clearly necessary, but I can't quite prove to myself that it's sufficient -- could there be other roots getting involved? It seems to work just fine, though.)

8. Sep 5, 2006

### HallsofIvy

Staff Emeritus
Precisely which formula are you talking about. There are several, none of which can be written in "closed" form. For that matter- "mark off each prime while counting until you reach k. The number you just marked off is the kth prime" is a perfectly valid formula. Of course, that assumes that there is a "kth" prime.

In order to have a similar or any formula for the "kth twin prime", you would have to first know that there is always a "kth twin prime". In other words, that there are an infinite number of twin primes.

9. Sep 5, 2006

### shmoe

I'm saying that you can't make any claims about something that you don't even have. Of course if you have any function that outputs a strictly increasing infinite sequence of twin primes then you'd be done. Maybe I'm being too liberal in what I'd consider a formula for twin primes.

the wilson's theroem like mod condition he gave is necessary and sufficient, attributed to Clement, and not too difficult to prove.

10. Sep 5, 2006

### CRGreathouse

The function you posted looks right to me and bears out experimentation, and shmoe says it's by Clement and true.

The expression you posted for finding the n-th twin prime isn't right as written -- what did you mean to take the cosine of? What's A? Maybe once you change this we can test it. I look forward to that.

Last edited: Sep 5, 2006
11. Sep 6, 2006

### lokofer

- Sorry to all "forumers" posting here the expression was:

$$\pi_2 (n)=-1+\sum_{k=2}^{n}[Cos^{2}\pi[\frac{4((k-1)!+1)+k}{k(k+2)}]]$$

the problem is to "invert" this function to obtain the "latest" (if exist) "twin prime"..is clearer now? A=-1 (constant) and [x], (x)! are the floor function and the factorial...

- For the case of "normal primes" they managed to get an expression involving: $$| \frac{n}{1+\pi (k)} |^{1/n}$$ (inside a sum ) to get the p(n) prime but can the same be made for "twin primes"?

Last edited: Sep 6, 2006
12. Sep 6, 2006

### shmoe

Have you tried to prove this sum gets the k-th prime as I suggested before? Not because I don't believe it's true, but because you will learn something about what known facts about the primes were needed in the proof. Then ask why the same thing won't work with the current knowledge of twin primes.

13. Sep 6, 2006

### -Job-

We can build an algorithm that outputs the kth pair of twin primes, so why not a mathematical expression? I think there ought to be a mathematical expression that outputs the kth pair of twin primes, though it would be meaningless because it's not going to tell us anything new. For example, we wouldn't know if a kth pair of twin primes exists, so the math function could just go on forever, searching in vain.

14. Sep 7, 2006

### lokofer

If we had that "twin prime " theorem fails then, we could amazingly find an exact expression as a "Eigenfunction expansion" let be the integral:

$$\frac{logZ(s)}{s}-\frac{Kh(s)}{1}=\int_{a}^{\infty}dt \frac{E_{2}(t)-K}{e^{st}-1}$$ $$E_{2}(t)=\pi_{2}(e^{t})$$ where a=ln(2)=0.69314718..

With $$Z(s)=\prod_{p,p+2}(1-p^{-s})^{-1}$$ product extended to all "twin primes" ) and $$h(s)=\int_{a}^{\infty}dt (exp(st)-1)^{-1}$$ $$E_{2} (p_{k})=K$$ where "p_k" would be the "last" twin prime.

Then the function $$\pi_{2} (t)-K$$ would be on L^2 (a,oo) space, and the Kernel inside the Integral equation is symmetric hence we could obtain a set of orthonormal eigenfunctions and real eigenvalues for K(s,t) the "solution" for teh density of "twin primes" (if there are just a finite number of them is)

$$E_{2} (t)-K= \sum_{n} \lambda _{n} C_{n} \phi_{n} (t)$$

and $$C_{n} = (\frac{logZ(s)}{s}-\frac{Kh(s)}{1}, \phi_{n} )$$ scalar product.

Of course from this you could "obtain" Brunn's constant in the form:

$$\sum_{n}^{\infty} \lambda _{n}C(n)d(n)= B_{2}$$

B2=1.902160583104..

Of course unless "twin prime" is correct and the sum above does not converge to Brun's constant $$d(n)= (exp(-x), \phi_{n} (x) )$$

EDIT: I have corrected the "wrong" terms..hope now it's understandable.

Last edited: Sep 7, 2006