cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A075574 a(1) = 1, then the smallest number (obviously even) greater than the previous term such that every partial sum is prime.

This page as a plain text file.
%I A075574 #12 Sep 19 2021 13:20:45
%S A075574 1,2,4,6,10,14,16,18,26,30,36,48,52,54,56,58,60,66,74,78,88,90,96,104,
%T A075574 106,108,122,126,144,154,156,158,172,188,190,192,206,210,214,228,240,
%U A075574 242,250,258,260,262,284,286,288,290,298,300,302,318,324,328,332,340
%N A075574 a(1) = 1, then the smallest number (obviously even) greater than the previous term such that every partial sum is prime.
%H A075574 Harvey P. Dale, <a href="/A075574/b075574.txt">Table of n, a(n) for n = 1..1000</a>
%p A075574 A075574:=proc(n) local i,j,k,t,s; j:=1; s:=1; t:=1; for i to n do k:=s; s:=nextprime(s+j); j:=s-k; t:=t,j; od; t; end; # _Floor van Lamoen_, Oct 21 2005
%t A075574 nxt[{ps_,a_}]:=Module[{c=a+2},While[!PrimeQ[ps+c],c+=2];{ps+c,c}]; Join[ {1},NestList[nxt,{3,2},60][[All,2]]] (* _Harvey P. Dale_, Sep 19 2021 *)
%Y A075574 Cf. A073659, A073660.
%K A075574 nonn
%O A075574 1,2
%A A075574 _Amarnath Murthy_, Sep 25 2002
%E A075574 More terms from _David Wasserman_, Jan 20 2005