P518
projecteuler.net

Prime Triples and Geometric Sequences

ℹ️Published on Saturday, 30th May 2015, 04:00 pm; Solved by 1764;
Difficulty rating: 20%

Let $S(n) = \sum a + b + c$ over all triples $(a, b, c)$ such that:

  • $a$, $b$ and $c$ are prime numbers.
  • $a \lt b \lt c \lt n$.
  • $a+1$, $b+1$, and $c+1$ form a geometric sequence.

For example, $S(100) = 1035$ with the following triples:

$(2, 5, 11)$, $(2, 11, 47)$, $(5, 11, 23)$, $(5, 17, 53)$, $(7, 11, 17)$, $(7, 23, 71)$, $(11, 23, 47)$, $(17, 23, 31)$, $(17, 41, 97)$, $(31, 47, 71)$, $(71, 83, 97)$

Find $S(10^8)$.



Soluzione

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