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.

A079849 First differences of A079848.

This page as a plain text file.
%I A079849 #7 Sep 11 2023 17:39:03
%S A079849 1,2,6,12,14,10,50,4,48,62,22,120,30,104,154,116,40,122,178,66,218,28,
%T A079849 72,296,220,290,130,552,80,322,158,400,302,528,520,170,268,236,576,
%U A079849 454,600,470,766,224,1090,666,180,764,868,606,572,294,738,70,918,1122,1196
%N A079849 First differences of A079848.
%o A079849 (Python)
%o A079849 from itertools import islice
%o A079849 from sympy import nextprime
%o A079849 def A079849_gen(): # generator of terms
%o A079849     aset2, alist, k, m = set(), [2], 2, 2
%o A079849     while (k:=nextprime(k)):
%o A079849         bset2 = set()
%o A079849         for a in alist:
%o A079849             if (b:=k-a) in aset2:
%o A079849                 break
%o A079849             bset2.add(b)
%o A079849         else:
%o A079849             yield k-m
%o A079849             alist.append(m:=k)
%o A079849             aset2.update(bset2)
%o A079849 A079849_list = list(islice(A079849_gen(),30)) # _Chai Wah Wu_, Sep 11 2023
%Y A079849 Cf. A079848.
%K A079849 nonn
%O A079849 1,2
%A A079849 _Amarnath Murthy_, Feb 18 2003
%E A079849 Extended by _Ray Chandler_, Feb 11 2007