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!)
A230386 Least sum of a set of n evil numbers (A001969) such that any two or more add to an odious number (A000069). 5
0, 8, 31, 64, 191, 1797, 18463 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Row sums of A230385: see there for the corresponding sets. See A230387 for a "dual" version.
Is this sequence finite, or is there for any n at least one admissible set of n evil numbers, i.e., such that any sum of two or more elements add up to an odious number?
By definition, this is a subsequence of the odious numbers A000069.
LINKS
M. F. Hasler, in reply to V. Shevelev, Peculiar sets of evil numbers (Cf. A001969), SeqFan list, Oct 17 2013
EXAMPLE
The table A230385 reads
n=1: {0} with sum = 0,
n=2: {3, 5} with sum = 8,
n=3: {5, 9, 17} or {9, 10, 12} with sum = 31,
n=4: {5, 9, 17, 33} with sum = 64,
n=5: {33, 34, 36, 40, 48} with sum = 191,
n=6: {257, 264, 278, 288, 326, 384} with sum = 1797.
For example, for n=4, all 11 numbers 5+9=14, 5+17=22, 5+33=38, 9+17=26, 9+33=42, 17+33=50, 5+9+17=31, 5+9+33=47, 5+17+33=55, 9+17+33=59, 5+9+17+33=64 are odious.
n=7: {801, 802, 804, 808, 816, 4896, 9536} with sum = 18463.
PROG
(PARI) (is_A69=n->bittest(hammingweight(n), 0)); A1969=select(n->!is_A69(n), vector(1600, n, n)) /* no 0 here! */; A230386(n, m=9e9)={ local(v=vector(n, i, i), ve=vector(n, i, A1969[i]), t=0, s=vector(n, i, if(i>1, A230386(i-1))), S(v)=sum(j=1, #v, v[j]), ok(e)=!forstep(i=3, 2^#e-1, 2, is_A69( S( vecextract( e, i )))||return), inc(i)=for(j=1, n-i, v[j]=j); for(j=n-i+1, n-1, v[j]++<v[j+1] && return(ve[j]=A1969[v[j]]); ve[j]=A1969[v[j]=j])/*end for*/; ve[n]=A1969[v[n]++])/*end local()*/; while( s[n]+ve[n]<m, for(i=2, n, s[n-i+1]+sum(j=n-i+1, n, ve[j]) < m && ok(vecextract(ve, 2^n-2^(n-i))) && next; inc(i); next(2)); m>S(ve) && /*print*/([m=S(ve), ve]); inc(n)); m} /* This code is very fast up to n=5 and much too slow for n>5. */
CROSSREFS
Sequence in context: A302306 A067950 A303037 * A022273 A302874 A061294
KEYWORD
nonn,more,hard
AUTHOR
EXTENSIONS
a(6) added by M. F. Hasler, Oct 18 2013
a(7) from Donovan Johnson, Oct 27 2013
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 March 29 11:14 EDT 2024. Contains 371278 sequences. (Running on oeis4.)