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.

Showing 1-7 of 7 results.

A028846 Numbers whose product of digits is a power of 2.

Original entry on oeis.org

1, 2, 4, 8, 11, 12, 14, 18, 21, 22, 24, 28, 41, 42, 44, 48, 81, 82, 84, 88, 111, 112, 114, 118, 121, 122, 124, 128, 141, 142, 144, 148, 181, 182, 184, 188, 211, 212, 214, 218, 221, 222, 224, 228, 241, 242, 244, 248, 281, 282, 284, 288, 411, 412, 414, 418, 421, 422, 424, 428, 441, 442, 444, 448
Offset: 1

Views

Author

Keywords

Comments

Numbers using only digits 1, 2, 4, and 8. - Michel Lagneau, Dec 01 2010

Examples

			28 is in the sequence because 2*8 = 2^4. - _Michel Lagneau_, Dec 01 2010
		

Crossrefs

Programs

  • Haskell
    a028846 n = a028846_list !! (n-1)
    a028846_list = f [1] where
       f ds = foldr (\d v -> 10 * v + d) 0 ds : f (s ds)
       s [] = [1]; s (8:ds) = 1 : s ds; s (d:ds) = 2*d : ds
    -- Reinhard Zumkeller, Jan 13 2014
    
  • Mathematica
    Select[Range[1000], IntegerQ[Log[2, Times @@ (IntegerDigits[#])]] &] (* Michel Lagneau, Dec 01 2010 *)
  • PARI
    is(n)=#setminus(Set(digits(n)), [1,2,4,8])==0 \\ Charles R Greathouse IV, Apr 24 2025
  • Python
    from itertools import count, islice, product
    def agen(): yield from (int("".join(p)) for d in count(1) for p in product("1248", repeat=d))
    print(list(islice(agen(), 64))) # Michael S. Branicky, Aug 21 2022
    
  • Python
    def A028846(n):
        m = (k:=3*n+1).bit_length()-1>>1
        return sum(10**j<<((k-(1<<(m<<1)))//(3<<(j<<1))&3) for j in range(m)) # Chai Wah Wu, Jun 28 2025
    

Formula

Given a(0) = 0 and n = 4k - r, where 0 <= r <= 3, a(n) = 10*a(k-1) + 2^(3-r). - Clinton H. Dan, Aug 21 2022

Extensions

More terms from Scott Lindhurst (ScottL(AT)alumni.princeton.edu)

A061427 Geometric mean of the digits = 3. In other words, the product of the digits is = 3^k where k is the number of digits.

Original entry on oeis.org

3, 19, 33, 91, 139, 193, 319, 333, 391, 913, 931, 1199, 1339, 1393, 1919, 1933, 1991, 3139, 3193, 3319, 3333, 3391, 3913, 3931, 9119, 9133, 9191, 9313, 9331, 9911, 11399, 11939, 11993, 13199, 13339, 13393, 13919, 13933, 13991, 19139, 19193
Offset: 1

Views

Author

Amarnath Murthy, May 03 2001

Keywords

Examples

			319 is a term as the geometric mean of digits is (3*1*9) = 27 = 3^3.
		

Crossrefs

Programs

  • Haskell
    a061427 n = a061427_list !! (n-1)
    a061427_list = g [1] where
       g ds = if product ds == 3 ^ length ds
              then foldr (\d v -> 10 * v + d) 0 ds : g (s ds) else g (s ds)
       s [] = [1]; s (9:ds) = 1 : s ds; s (d:ds) = 3*d : ds
    -- Reinhard Zumkeller, Jan 13 2014
  • Mathematica
    Select[Range[20000],GeometricMean[IntegerDigits[#]]==3&] (* Harvey P. Dale, Dec 11 2011 *)

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), May 16 2001

A061430 Geometric mean of the digits is an integer: k-digit numbers such that the product of the digits is a number of the form m^k.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 14, 19, 20, 22, 28, 30, 33, 40, 41, 44, 49, 50, 55, 60, 66, 70, 77, 80, 82, 88, 90, 91, 94, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 118, 120, 124, 130, 139, 140, 142, 150, 160, 170, 180, 181, 188, 190, 193
Offset: 1

Views

Author

Amarnath Murthy, May 03 2001

Keywords

Examples

			694 is a term as (6*9*4)^(1/3) = 6 is an integer.
		

Crossrefs

Programs

  • Haskell
    a061430 n = a061430_list !! (n-1)
    a061430_list = filter g [0..] where
       g u = round (fromIntegral p ** (1 / fromIntegral k)) ^ k == p where
             (p, k) = h (1, 0) u
             h (p, l) 0 = (p, l)
             h (p, l) v = h (p * r, l + 1) v' where (v', r) = divMod v 10
    -- Reinhard Zumkeller, Jan 13 2014
  • Mathematica
    Select[Range[0,200],IntegerQ[GeometricMean[IntegerDigits[#]]]&] (* Harvey P. Dale, Feb 15 2012 *)

Extensions

More terms from Naohiro Nomoto, May 11 2001

A061428 Geometric mean of the digits = 4. In other words, the product of the digits is = 4^k where k is the number of digits.

Original entry on oeis.org

4, 28, 44, 82, 188, 248, 284, 428, 444, 482, 818, 824, 842, 881, 1488, 1848, 1884, 2288, 2448, 2484, 2828, 2844, 2882, 4188, 4248, 4284, 4428, 4444, 4482, 4818, 4824, 4842, 4881, 8148, 8184, 8228, 8244, 8282, 8418, 8424, 8442, 8481, 8814, 8822, 8841, 12888
Offset: 1

Views

Author

Amarnath Murthy, May 03 2001

Keywords

Examples

			248 is a term as the geometric mean of digits is (2*4*8) = 64 = 4^3.
		

Crossrefs

Programs

  • Haskell
    a061428 n = a061428_list !! (n-1)
    a061428_list = g [1] where
       g ds = if product ds == 4 ^ length ds
              then foldr (\d v -> 10 * v + d) 0 ds : g (s ds) else g (s ds)
       s [] = [1]; s (8:ds) = 1 : s ds; s (d:ds) = 2*d : ds
    -- Reinhard Zumkeller, Jan 13 2014
    
  • Python
    from math import prod
    from sympy.utilities.iterables import multiset_combinations, multiset_permutations
    def auptod(maxdigits):
      n, digs, alst, powsexps2 = 0, 1, [], [(1, 0), (2, 1), (4, 2), (8, 3)]
      for digs in range(1, maxdigits+1):
        target, okdigs = 4**digs, set()
        mcstr = "".join(str(d)*(digs//max(1, r//2)) for d, r in powsexps2)
        for mc in multiset_combinations(mcstr, digs):
          if prod(map(int, mc)) == target:
            n += 1
            okdigs |= set("".join(mp) for mp in multiset_permutations(mc, digs))
        alst += sorted(map(int, okdigs))
      return alst
    print(auptod(4)) # Michael S. Branicky, Apr 28 2021

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), May 16 2001

A069512 Geometric mean of digits = 2 and digits are in nondecreasing order.

Original entry on oeis.org

2, 14, 22, 118, 124, 222, 1128, 1144, 1224, 2222, 11148, 11228, 11244, 12224, 22222, 111188, 111248, 111444, 112228, 112244, 122224, 222222, 1111288, 1111448, 1112248, 1112444, 1122228, 1122244, 1222224, 2222222, 11111488, 11112288, 11112448, 11114444
Offset: 1

Views

Author

Amarnath Murthy, Mar 30 2002

Keywords

Comments

No number is obtainable by permuting the digits of other members - only one with ascending order of digits is included. Product of the digits = 2^k where k is the number of digits.

Examples

			1128 is a term but 2118 is not.
		

Crossrefs

Programs

  • Mathematica
    a = {}; b = 2; Do[c = Apply[ Times, IntegerDigits[n]]/b^Floor[ Log[10, n] + 1]; If[c == 1 && Position[a, FromDigits[ Sort[ IntegerDigits[n]]]] == {}, Print[n]; a = Append[a, n]], {n, 1, 10^7}]
  • Python
    from math import prod
    from sympy.utilities.iterables import multiset_combinations
    def aupton(terms):
      n, digits, alst, powsexps2 = 0, 1, [], [(1,0), (2,1), (4,2), (8,3)]
      while n < terms:
        target = 2**digits
        mcstr = "".join(str(d)*(digits//max(1, r)) for d, r in powsexps2)
        for mc in multiset_combinations(mcstr, digits):
          if prod(map(int, mc)) == target:
            n += 1
            alst.append(int("".join(mc)))
            if n == terms: break
        else: digits += 1
      return alst
    print(aupton(34)) # Michael S. Branicky, Feb 14 2021

Extensions

Edited and extended by Robert G. Wilson v, Apr 01 2002
a(31) corrected by and a(33) and beyond from Michael S. Branicky, Feb 14 2021

A061429 Geometric mean of the digits = 6. In other words, the product of the digits is = 6^k where k is the number of digits.

Original entry on oeis.org

6, 49, 66, 94, 389, 398, 469, 496, 649, 666, 694, 839, 893, 938, 946, 964, 983, 2899, 2989, 2998, 3689, 3698, 3869, 3896, 3968, 3986, 4499, 4669, 4696, 4949, 4966, 4994, 6389, 6398, 6469, 6496, 6649, 6666, 6694, 6839, 6893, 6938, 6946, 6964, 6983, 8299
Offset: 1

Views

Author

Amarnath Murthy, May 03 2001

Keywords

Comments

The smallest number containing all the possible digits is 123468889999999. - Jianing Song, Nov 21 2019

Examples

			694 is a term as the geometric mean of digits is (6*9*4)^(1/3)= 6.
		

Crossrefs

Programs

  • Haskell
    a061429 n = a061429_list !! (n-1)
    a061429_list = filter (h 1 1) [1..] where
       h 0   = False
       h u v 0 = u == v
       h u v w = h (r * u) (6 * v) w' where (w', r) = divMod w 10
    -- Reinhard Zumkeller, Jan 13 2014
  • Mathematica
    Select[Range[9000],GeometricMean[IntegerDigits[#]]==6&] (* Harvey P. Dale, May 29 2021 *)

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), May 16 2001

A285094 Corresponding values of geometric means of digits of numbers from A061430.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 0, 2, 4, 0, 3, 0, 2, 4, 6, 0, 5, 0, 6, 0, 7, 0, 4, 8, 0, 3, 6, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 0, 2, 0, 3, 0, 2, 0, 0, 0, 0, 2, 4, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 2, 0, 0, 2, 4, 0, 0, 0, 0, 4, 0
Offset: 0

Views

Author

Jaroslav Krizek, Apr 14 2017

Keywords

Crossrefs

Cf. A061430 (numbers with integer geometric mean of digits in base 10).
Sequences of numbers n such that a(n) = k for k = 0 - 9: A011540 (k = 0), A002275 (k = 1), A061426 (k = 2), A061427 (k = 3), A061428 (k = 4), A002279 (k = 5), A061429 (k = 6), A002281 (k = 7), A002282 (k = 8), A002283 (k = 9).

Programs

  • Magma
    [0] cat [Floor(&*Intseq(n) ^ (1/#Intseq(n))): n in [1..100000] | IsIntegral(&*Intseq(n) ^ (1/#Intseq(n)))];
Showing 1-7 of 7 results.