<s>[INST] Using induction to prove sum of certain number-theoretic function. For any positive integer $ n > 1$, let $P(n)$ denote the largest prime not exceeding $n$.
Let $N(n)$ denote the next prime larger than $P(n)$. (For example $P(10) = 7$ and
$N(10) = 11$, while $P(11) = 11$ and $N(11) = 13$.) If $n + 1$ is a prime number, prove
that the value of the sum
$$ \frac{1}{P(2)N(2)} + \frac{1}{P(3)N(3)} + \cdot\cdot\cdot + \frac{1}{P(n)N(n)} = \frac{n-1}{2n+2}$$
Can I use induction on two consecutive primes $k+1$ and $k+q+1$?
If so, then here is my proof:
Since the result holds true for $n=2$ and $n=4$, suppose that it holds true for $n=k$ with $k+1$ being prime. Then,
$$\sum_{2}^{k}{\frac{1}{P(n)N(n)}} = \frac{k-1}{2(k+1)}$$
Then suppose that $k+q+1$ is the next prime greater than $k+1$, then $\forall m$ such that $ k+1 \leq m < k+q+1$, 
$P(m) = k+1$ and $N(m) = k+q+1$.
Therefore, 
$$\sum_{2}^{k+q}{\frac{1}{P(n)N(n)}} = \sum_{2}^{k}{\frac{1}{P(n)N(n)}} + \sum_{k+1}^{k+q}{\frac{1}{P(n)N(n)}} = \frac{k-1}{2(k+1)} +\frac{q}{(k+1)(k+q+1)}$$
Which, on manupulation yields
$$\sum_{2}^{k+q}{\frac{1}{P(n)N(n)}}=\frac{k+q-1}{2(k+q+1)}$$ Hence completes the proof.
Is this correct or am I missing something?
 [/INST] I checked it and didn't find any mistakes. Nice identity!
I don't think you used any facts about primes anywhere, so if it's true it would be true for any sub-sequence of natural numbers.
</s>