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.

A114457 Smallest k > 0 such that abs(S(k)P(k)-k) equals n, where S(k) is the sum and P(k) is the product of decimal digits of k or 0 if no such k exists.

Original entry on oeis.org

1, 13, 2, 219, 724, 1285, 3, 23, 7789816, 11, 10, 2891, 4, 127, 226, 15, 3248, 163, 52, 31, 5, 33, 262, 12857, 24, 325, 16, 243, 38428, 617, 6, 68177, 172, 0, 62, 2275, 272, 22577, 118, 17, 40, 43, 7, 1339, 136, 25, 154, 143, 128, 125599, 34, 5619, 352, 1483
Offset: 0

Views

Author

Eric W. Weisstein, Nov 28 2005

Keywords

Comments

a(33) > 2*10^9; then sequence continues 62, 2275, 272, 22577, 118, 17, 40, 43, 7, 1339, 136, 25, 154, 143, 128, 125599, 34, 5619, 352, 1483, 18, 145, 8, 15457, 173, 14963, 60, 1727, 517, 1197, 1787456, 235, 642, 53, 116, ... - Robert G. Wilson v, Dec 14 2005
a(33) > 2*10^16. - Floris M. Velleman, Dec 17 2014
a(33) = 0. Modification of David W. Wilson's proof for A038369 shows that if a(33) > 0, then a(33) has at most 84 digits. This allows an exhaustive search of numbers of the form 2^a*3^b*5^c*7^d which shows that no such number exists. Other values of n for which a(n) is currently unknown and may be equal to 0 (based on analysis of numbers with at most 20 digits) are: 69, 111, 127, 146, 168, 172, 233, 243, 249, 273, 279, 281, 316, 327, 372, 533, 557, 579, 587, 621, 623, 647, 649, 676, 683, 713, 721, 816, 819, 821, 827, 861, 872, 917, 926, 927, 928, 939, 983, 996, 999, ... - Chai Wah Wu, Nov 22 2015
a(69) = a(111) = 0. To compute a(111), numbers of at most 85 digits were checked. - Chai Wah Wu, Dec 04 2015

Crossrefs

Cf. A007953 (sum of digits), A007954 (product of digits), A038369.

Programs

  • Mathematica
    a[n_] := Block[{k = 1}, While[id = IntegerDigits@k; Abs[(Plus @@ id)(Times @@ id) - k] != n, k++ ]; k];
    Table[ a[n], {n, 0, 54}] (* Robert G. Wilson v, Dec 14 2005 *)
  • PARI
    f(k) = my(d=digits(k)); abs(sum(j=1, #d, d[j])*prod(j=1,#d, d[j]) - k);
    a(n) = {k = 1; while(f(k) != n, k++); k;} \\ Michel Marcus, Jan 02 2015

Extensions

Added a(33), edited definition and verified a(34)-a(68) by Chai Wah Wu, Nov 22 2015