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-2 of 2 results.

A085215 Square array A(x,y) = the number whose factorial expansion A007623 is that of x and y concatenated; zero expanded as empty string; read by ascending antidiagonals: A(0,0), A(1,0), A(0,1), A(2,0), A(1,1), A(0,2), ...

Original entry on oeis.org

0, 1, 1, 2, 3, 2, 3, 7, 8, 3, 4, 9, 26, 9, 4, 5, 13, 32, 27, 10, 5, 6, 15, 50, 33, 28, 11, 6, 7, 25, 56, 51, 34, 29, 30, 7, 8, 27, 122, 57, 52, 35, 126, 31, 8, 9, 31, 128, 123, 58, 53, 150, 127, 32, 9, 10, 33, 146, 129, 124, 59, 246, 151, 128, 33, 10, 11, 37, 152, 147, 130, 125, 270, 247, 152, 129, 34, 11
Offset: 0

Views

Author

Antti Karttunen, Jun 23 2003

Keywords

Examples

			From _M. F. Hasler_, Nov 27 2018: (Start)
The array starts:
   0   1   2   3   4   5  6 ...
   1   3   8   9  10  11 30 ...
   2   7  26  27  28  29 ...
   3   9  32  33  34  ...
   4  13  50  51  ...
  (...)  (End)
A(4,3) = 51 which has a factorial expansion '2011' (2*24+0*6+1*2+1*1), a concatenation of factorial expansions of 4, '20' and of 3, '11'. Similarly, A(3,4) = 34 which has a factorial expansion '1120' (1*24+1*6+2*2+0*1). See A085217 for the corresponding factorial expansions.
		

Crossrefs

Transpose: A085216. Variant: A085219. Can be used to compute A085201. Cf. A000142, A007623, A084558, A025581, A002262.

Programs

  • PARI
    A085215(x,y)=A322001(eval(Str(A007623(x),A007623(y)))) \\ M. F. Hasler, Nov 27 2018. N.B. This has the same caveat as Hasler's formula. See below for program that is correct for all x, y >= 0. - Antti Karttunen, Mar 24 2025
    
  • PARI
    up_to = 78;
    A085215sq(x,y) = { my(i=2,j=2,z=0,f=1); while(y>0, z += (y%i)*f; f *= i; y \= i; i++); while(x>0, z += (x%j)*f; f *= i; x \= j; i++; j++); (z); };
    A085215list(up_to) = { my(v = vector(up_to), i=0); for(a=0, oo, for(col=0, a, i++; if(i > up_to, return(v)); v[i] = A085215sq(a-col, col))); (v); };
    v085215 = A085215list(up_to);
    A085215(n) = v085215[1+n]; \\ Antti Karttunen, Mar 24 2025

Formula

A(x,y) = A322001(concat(A007623(x), A007623(y))), where A322001 is a left inverse of A007623. - M. F. Hasler, Nov 27 2018. Note: this formula is valid only with x and y such that A322001(A007623(x)) = x and A322001(A007623(y)) = y, i.e., at least for all x,y <= 36287999. See N. J. A. Sloane's Jun 04 2012 comment in A007623. - Antti Karttunen, Feb 23 2025

Extensions

More terms added by Antti Karttunen, Mar 24 2025

A156230 Sum of the products of the digits of n and the positions of the digits m in n starting from the last digit.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 3
Offset: 1

Views

Author

Cino Hilliard, Feb 06 2009

Keywords

Comments

Starts to differ from A081594 when n>=100. [From R. J. Mathar, Feb 19 2009]

Examples

			a(19) = 9*1 + 1*2 = 11.
		

Programs

  • Maple
    A156230 := proc(n)
        local dgs;
        dgs := convert(n,base,10) ;
        add(i*op(i,dgs),i=1..nops(dgs)) ;
    end proc:
    seq(A156230(n),n=1..100) ; # R. J. Mathar, Dec 02 2018
  • Mathematica
    pdn[n_]:=Module[{idn=IntegerDigits[n]},Total[idn Range[Length[idn],1,-1]]]; Array[pdn,80] (* Harvey P. Dale, Aug 22 2012 *)
  • PARI
    gr(n) = v=Vec((rev(n)));sum(x=1,length(v),x*eval(v[x]))
    gr1(n) = for(j=1,n,print1(gr(j)","))
    rev(str) = /* Get the reverse of the input string
    */ {
    local(tmp,s,j);
    tmp = Vec(Str(str));
    s="";
    forstep(j=length(tmp),1,-1,
    s=concat(s,tmp[j]));
    return(s)
    }

Formula

Let n = d(1)d(2)...d(m) where d(1),d(2),...,d(m) are the digits of n. Then a(n) = m*d1+(m-1)*d2+...+d(m).

Extensions

Changed the description, formula and Pari code Cino Hilliard, Feb 08 2009
More terms to separate from A322001. - R. J. Mathar, Dec 02 2018
Showing 1-2 of 2 results.