Pillai sequence

It would follow from Goldbach's conjecture that every integer greater than one can be represented as a sum of at most three prime numbers. However, finding such a representation could involve solving instances of the subset sum problem, which is computationally difficult. Instead, Pillai considered the following simpler greedy algorithm for finding a representation of $n$ as a sum of primes: choose the first prime in the sum to be the largest prime $p$ that is at most $n$ , and then recursively construct the remaining sum recursively for $n-p$ . If this process reaches zero, it halts. And if it reaches one instead of zero, it must include one in the sum (even though it is not prime), and then halt. For instance, this algorithm represents 122 as 113 + 7 + 2, even though the shorter representations 61 + 61 or 109 + 13 are also possible.
The $n$ th number in the Pillai sequence is the smallest number whose greedy representation as a sum of primes (and one) requires $n$ terms. These numbers are
Each number $a(n)$ in the sequence is the sum of the previous number $a(n-1)$ with a prime number $p$ , the smallest prime whose following prime gap is larger than $a(n-1)$ . For instance, the number 27 in the sequence is 4 + 23, where the first prime gap larger than 4 is the one between 23 and 29.