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.

A038444 Sums of 2 distinct powers of 10.

Original entry on oeis.org

11, 101, 110, 1001, 1010, 1100, 10001, 10010, 10100, 11000, 100001, 100010, 100100, 101000, 110000, 1000001, 1000010, 1000100, 1001000, 1010000, 1100000, 10000001, 10000010, 10000100, 10001000, 10010000, 10100000, 11000000, 100000001, 100000010, 100000100
Offset: 1

Views

Author

Keywords

Crossrefs

Subsequence of A052216 and of A007088.
Cf. A018900.

Programs

  • Haskell
    a038444 n = a038444_list !! (n-1)
    a038444_list = 11 : f [11] 90 where
       f xs@(x:_) z = ys ++ f ys (10 * z) where
                      ys = (x + z) : map (* 10) xs
    -- Reinhard Zumkeller, Jan 28 2015
    
  • Maple
    seq(seq(10^d + 10^j, j=0..d-1), d=1..10); # Robert Israel, Oct 14 2016
  • Mathematica
    Sort[Total/@Subsets[10^Range[0,7],{2}]] (* Harvey P. Dale, Apr 20 2012 *)
  • PARI
    a(n)= 10^(n-1-binomial(sqrtint(n*8)\/2, 2)) + 10^((sqrtint(n*8)+1)\2); \\ Ruud H.G. van Tol, Nov 29 2024
    
  • Python
    from math import isqrt
    def A038444(n): return 10**(m:=isqrt(n<<3)+1>>1)+10**(n-1-(m*(m-1)>>1)) # Chai Wah Wu, Mar 11 2025

Formula

G.f.: (10*x - 55*x^2 + Sum_{d>=1} (4*10^d+5)*x^((d^2-d)/2+1) - Sum_{d>=1} (445*10^(d-1)+5)*x^((d^2-d)/2+2))/(5*(1-x)*(1-10*x)). - Robert Israel, Oct 14 2016

Extensions

Offset corrected by Reinhard Zumkeller, Jan 28 2015