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.

A268134 If a(n) is squarefree (and n > 1), then a(n+1) = a(n) + a(n-1), else a(n+1) is the smallest positive integer not occurring earlier.

This page as a plain text file.
%I A268134 #7 Jan 27 2016 12:23:57
%S A268134 1,2,3,5,8,4,6,10,16,7,23,30,53,83,136,9,11,20,12,13,25,14,39,53,92,
%T A268134 15,107,122,229,351,17,368,18,19,37,56,21,77,98,22,120,24,26,50,27,28,
%U A268134 29,57,86,143,229,372,31,403,434,837,32,33,65,98,34,132,35,167,202,369,36,38,74,112,40,41,81,42,123,165
%N A268134 If a(n) is squarefree (and n > 1), then a(n+1) = a(n) + a(n-1), else a(n+1) is the smallest positive integer not occurring earlier.
%C A268134 A variant of the sequence A267758 where the relation has to hold for prime numbers rather than for squarefree numbers. In contrast to that sequence we have many duplicate terms here (which we could exclude explicitely in order to get a permutation of the positive integers).
%H A268134 M. F. Hasler, <a href="/A268134/b268134.txt">Table of n, a(n) for n = 1..1000</a>
%o A268134 (PARI) {a(n,show=0,is=x->issquarefree(x),a=[1],L=0,U=[])=while(#a<n,show&&if(type(show)=="t_STR",write(show,#a," ",a[#a]),print1(a[#a]","));if(a[#a]>L+1,U=setunion(U,[a[#a]]),L++;while(#U&&U[1]<=L+1,U=U[^1];L++));a=concat(a,if(!is(a[#a])||#a<2,L+1,a[#a]+a[#a-1])));if(type(show)=="t_VEC",a,a[#a])}
%K A268134 nonn,look
%O A268134 1,2
%A A268134 _M. F. Hasler_, Jan 26 2016