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.

A293011 a(n) is the smallest positive k such that f(k) = n*g(k) where f = A007953 and g = A000120, or 0 if no such k exists.

Original entry on oeis.org

1, 2, 6, 4, 32, 48, 16, 8, 288, 64, 128, 8196, 256, 2048, 16896, 278528, 2097664, 589824, 4096, 8192, 8388609, 16384, 536870944, 268435488, 65536, 32768, 268959744, 17179869440, 524288, 4294967298, 1048576, 8589934594, 8589934596
Offset: 1

Views

Author

Altug Alkan, Sep 28 2017

Keywords

Comments

Conjecture: a(n) > 0 for all n >= 1.
Numbers n such that a(n) is not a power of 2 are 3, 6, 9, 12, 15, 16, 17, 18, ...
a(21) = 8388609 = 2^23 + 1 is the second odd term of this sequence after a(1) = 1.
Smallest n such that a(n + 1) = a(n) + 2 is 32 and a(32) = 2*(2^32 + 1).
For n <= 170, A000120(a(n)) <= 2. - Robert Israel, Nov 22 2019

Examples

			a(9) = 288 = 2^8 + 2^5 because A007953(288) = 2 + 8 + 8 = 18, 18 / 2 = 9 and 288 is the least number with this property.
		

Crossrefs

Programs

  • Maple
    # This code returns a(n) if A000120(a(n)) <= 3 and it can prove that no
    # smaller number with A000120 >= 4 can have A007953 large enough. If it
    # can't prove that, it returns FAIL.
    sdd:= n -> convert(convert(n,base,10),`+`):
    g:= proc(n) local found, k1, k2, k3, x, y, m,bd;
      found:= false;
      for k1 from 1 while not found do
        for k2 from 0 to k1-1 do
          x:= 2^k1 + 2^k2;
          if sdd(x) = 2*n then found:= true; break fi
      od od;
      for k1 from 0 to ilog2(x) do
        if sdd(2^k1) = n then x:= 2^k1; break fi
      od;
      m:= ilog10(x);
      bd:= floor(x/10^m)+9*m;
      if bd <= 3*n then return x fi;
      found:= false;
      for k1 from 2 to ilog2(x) while not found do
        for k2 from 1 to k1-1 while not found do
          for k3 from 0 to k2-1 do
             y:= 2^k1 + 2^k2 + 2^k3;
             if y > x or sdd(y) = 3*n then found:= true; break fi;
      od od od;
      if found then x:= min(x,y) fi;
      bd:= floor(x/10^m)+9*m;
      if bd <= 4*n then x else FAIL fi;
    end proc:
    map(g, [$1..50]); # Robert Israel, Nov 22 2019
  • PARI
    a(n) = {my(k=1); while ((hammingweight(k))*n != sumdigits(k), k++); k; }