P441
projecteuler.net

The Inverse Summation of Coprime Couples

ℹ️Published on Sunday, 20th October 2013, 10:00 am; Solved by 396;
Difficulty rating: 65%

For an integer $M$, we define $R(M)$ as the sum of $1/(p \cdot q)$ for all the integer pairs $p$ and $q$ which satisfy all of these conditions:

  • $1 \leq p \lt q \leq M$
  • $p + q \geq M$
  • $p$ and $q$ are coprime.

We also define $S(N)$ as the sum of $R(i)$ for $2 \leq i \leq N$.
We can verify that $S(2) = R(2) = 1/2$, $S(10) \approx 6.9147$ and $S(100) \approx 58.2962$.

Find $S(10^7)$. Give your answer rounded to four decimal places.



Soluzione

Last modified: May 27, 2025. Website built with Franklin.jl and the lovely Julia programming language.