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.

A077477 Least positive integers not excluded by the rule that if n is present then 2n+1 and 3n+1 are not allowed.

This page as a plain text file.
%I A077477 #19 Jul 13 2013 16:34:32
%S A077477 1,2,6,8,9,10,11,12,14,15,16,18,20,22,24,26,27,30,32,35,36,38,39,40,
%T A077477 42,44,47,48,50,51,52,54,56,57,58,59,60,62,63,64,66,68,69,70,72,74,75,
%U A077477 76,78,80,83,84,86,87,88,90,92,93,94,96
%N A077477 Least positive integers not excluded by the rule that if n is present then 2n+1 and 3n+1 are not allowed.
%C A077477 What is the limit of a(n)/n?
%C A077477 With 10000 terms, one gets a(n)/n -> 1.63317... - _Jean-François Alcover_ Dec 11 2012
%H A077477 Reinhard Zumkeller, <a href="/A077477/b077477.txt">Table of n, a(n) for n = 1..10000</a>
%e A077477 a(5)=9 since 9 is not equal to 2*a(k)+1 nor 3*a(k)+1 for 1<=k<5; and since 9 is allowed to be present, then 19(=2*9+1) and 28(=3*9+1) are to be excluded.
%t A077477 s = {1}; Do[u = Union[s, 2s + 1, 3s + 1]; c = Complement[Range[u // Last], u] // First; AppendTo[s, c], {10000}]; s (* _Jean-François Alcover_, Dec 11 2012 *)
%o A077477 (Haskell)
%o A077477 import Data.List (delete)
%o A077477 a077477 n = a077477_list !! (n-1)
%o A077477 a077477_list = f [1..] where
%o A077477    f (x:xs) = x : f (delete (2*x + 1) $ delete (3*x + 1) xs)
%o A077477 -- _Reinhard Zumkeller_, Sep 14 2011
%Y A077477 Cf. A002977.
%K A077477 easy,nice,nonn
%O A077477 1,2
%A A077477 _Paul D. Hanna_, Nov 08 2002