login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A331811 a(n) is the next number after a(n-1) which cannot be represented in the form 2*a(i) and Sum_{j=1..n-1} b_j*a(j) where 0 < i < n, b_j = 1 or 0. The sequence starts: a(1) = 1; a(2) = 2; a(3) = 3; a(4) = 5. 3
1, 2, 3, 5, 12, 25, 49, 73, 171, 195, 512, 658, 1560, 1950, 4826, 6142, 14868, 18768, 45920, 58204, 141660, 179196, 437264, 553672, 1349328, 1707720, 4164392, 5271736, 12851568, 16267008, 39662048, 50205520, 122401584, 154935600, 377748224, 478159264, 1165778688, 1475649888 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
This sequence is a complete sequence.
LINKS
Eric Weisstein's World of Mathematics, Complete Sequence
MATHEMATICA
Nest[Append[#, Block[{k = #[[-1]] + 1}, While[Nand[NoneTrue[#, k == 2 # &], FreeQ[Map[Total, Rest@ Subsets[#]], k]], k++]; k]] & @@ {#, Map[Total, Subsets[#]]} &, {1, 2, 3, 5}, 10] (* Michael De Vlieger, Jan 27 2020 *)
PROG
(PARI) upto(lim)={my(a=[1, 2, 3, 5], b=[]); for(i=1, lim, forsubset(#a, x, b=concat(b, [vecsum(vecextract(a, x))])); b=setminus(vecsort(b, , 8), a); for(j=1, #a, b=concat(b, [2*a[j]]); b=vecsort(b, , 8)); if(setsearch(b, i)==0, a=concat(a, [i]); a=vecsort(a, , 8)) ); a}
{ upto(200) }
CROSSREFS
(C++) See Links section.
Sequence in context: A003428 A191626 A030041 * A284910 A233231 A319912
KEYWORD
nonn
AUTHOR
EXTENSIONS
a(13)-a(14) from Hugo Pfoertner, Jan 27 2020
More terms from Rémy Sigrist, Jan 28 2020
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 00:30 EDT 2024. Contains 371917 sequences. (Running on oeis4.)