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

A133048 Powerback(n): reverse the decimal expansion of n, drop any leading zeros, then apply the powertrain map of A133500 to the resulting number.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 2, 1, 4, 9, 16, 25, 36, 49, 64, 81, 3, 1, 8, 27, 64, 125, 216, 343, 512, 729, 4, 1, 16, 81, 256, 625, 1296, 2401, 4096, 6561, 5, 1, 32, 243, 1024, 3125, 7776, 16807, 32768, 59049, 6, 1, 64, 729, 4096, 15625, 46656, 117649
Offset: 0

Views

Author

J. H. Conway and N. J. A. Sloane, Dec 31 2007

Keywords

Comments

a(A221221(n)) = A133500(A221221(n)) = A222493(n). - Reinhard Zumkeller, May 27 2013

Examples

			E.g. 240 -> (0)42 -> 4^2 = 16; 12345 -> 54321 -> 5^4*3^2*1 = 5625.
		

Crossrefs

Cf. A131571 (fixed points), A133059 and A133134 (records); A133500 (powertrain).
Cf. A133144 (length of trajectory), A031346 and A003001 (persistence).
Cf. A031298.

Programs

  • Haskell
    a133048 0 = 0
    a133048 n = train $ dropWhile (== 0) $ a031298_row n where
       train []       = 1
       train [x]      = x
       train (u:v:ws) = u ^ v * (train ws)
    -- Reinhard Zumkeller, May 27 2013
  • Maple
    powerback:=proc(n) local a,i,j,t1,t2,t3;
    if n = 0 then RETURN(0); fi;
    t1:=convert(n, base, 10); t2:=nops(t1);
    for i from 1 to t2 do if t1[i] > 0 then break; fi; od:
    a:=1; t3:=t2-i+1;
    for j from 0 to floor(t3/2)-1 do a := a*t1[i+2*j]^t1[i+2*j+1]; od:
    if t3 mod 2 = 1 then a:=a*t1[t2]; fi;
    RETURN(a); end;
  • Mathematica
    ptm[n_]:=Module[{idn=IntegerDigits[IntegerReverse[n]]},If[ EvenQ[ Length[idn]],Times@@ (#[[1]]^#[[2]]&/@Partition[idn,2]),(Times@@(#[[1]]^#[[2]]&/@Partition[ Most[ idn],2]))Last[idn]]];Array[ptm,70,0] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jul 05 2020 *)

A133474 Inverse binomial transform of (A113405 preceded by 0).

Original entry on oeis.org

0, 0, 0, 1, 6, 24, 81, 252, 756, 2241, 6642, 19764, 59049, 176904, 530712, 1592865, 4780782, 14346720, 43046721, 129146724, 387440172, 1162300833, 3486843450, 10460412252, 31381059609, 94143001680, 282429005040, 847287546561
Offset: 0

Views

Author

Paul Curtz, Nov 29 2007

Keywords

Crossrefs

Programs

  • GAP
    a:=[0,0,1];; for n in [4..30] do a[n]:=6*a[n-1]-12*a[n-2]+9*a[n-3]; od; a; # G. C. Greubel, Nov 21 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 30); [0,0,0] cat Coefficients(R!( x^3/((1-3*x)*(1-3*x+3*x^2)) )); // G. C. Greubel, Nov 21 2019
    
  • Maple
    seq(coeff(series(x^3/((1-3*x)(1-3*x+3*x^2)), x, n+1), x, n), n = 0 .. 40); # G. C. Greubel, Nov 21 2019
  • Mathematica
    LinearRecurrence[{6,-12,9}, {0,0,0,1}, 30] (* G. C. Greubel, Nov 21 2019 *)
  • PARI
    my(x='x+O('x^30)); concat([0,0,0], Vec(x^3/((1-3*x)*(1-3*x+3*x^2)))) \\ G. C. Greubel, Nov 21 2019
    
  • Sage
    def A133474_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P(x^3/((1-3*x)*(1-3*x+3*x^2))).list()
    A133474_list(30) # G. C. Greubel, Nov 21 2019
    

Formula

b(n) = a(n) with one 0; c(n)=1, 3, 6, 9, 9, 0, -27, ... = A057083; b(n+1) = 3*b(n) + c(n)?
From R. J. Mathar, Apr 02 2008: (Start)
O.g.f.: x^3/((1-3*x)*(1-3*x+3*x^2)).
a(n) = 6*a(n-1) - 12*a(n-2) + 9*a(n-3). (End)

A133144 Start with n and repeatedly apply the powerback map of A133048. Sequence gives number of steps to the point where the next number would be one that has appeared before.

Original entry on oeis.org

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

Views

Author

J. H. Conway and N. J. A. Sloane, Jan 01 2008

Keywords

Comments

It is conjectured that every number eventually reaches a fixed point (see A131571) or the cycle of length 2 given by (175 <-> 78125).

Examples

			n, a(n), trajectory
22, 1, [22, 4]
23, 1, [23, 9]
24, 2, [24, 16, 6]
25, 0, [25]
26, 4, [26, 36, 216, 12, 2]
27, 6, [27, 49, 6561, 15625, 194400, 2304, 9]
28, 3, [28, 64, 4096, 0]
29, 2, [29, 81, 1]
30, 1, [30, 3]
31, 1, [31, 1]
32, 1, [32, 8]
33, 7, [33, 27, 49, 6561, 15625, 194400, 2304, 9]
34, 3, [34, 64, 4096, 0]
35, 2, [35, 125, 25]
36, 3, [36, 216, 12, 2]
37, 6, [37, 343, 243, 162, 64, 4096, 0]
38, 3, [38, 512, 10, 1]
39, 7, [39, 729, 567, 588245, 5242880000, 8589934592, 105911076180375000000000, 0]
		

A145608 Numbers a(n)=k such that (1/3)*(5*(2k+1)^2-2) is A057080(n)^2.

Original entry on oeis.org

0, 3, 27, 216, 1704, 13419, 105651, 831792, 6548688, 51557715, 405913035, 3195746568, 25160059512, 198084729531, 1559517776739, 12278057484384, 96664942098336, 761041479302307, 5991666892320123, 47172293659258680, 371386682381749320, 2923921165394735883, 23019982640776137747
Offset: 0

Views

Author

Richard Choulet, Oct 14 2008

Keywords

Crossrefs

Programs

  • Mathematica
    RecurrenceTable[{a[0]==0,a[1]==3,a[n]==8a[n-1]-a[n-2]+3},a,{n,30}] (* or *) LinearRecurrence[{9,-9,1},{0,3,27},30] (* Harvey P. Dale, May 06 2013 *)

Formula

a(n+2) = 8*a(n+1) - a(n) + 3.
a(n) = (A070997(n)-1)/2 = 3*A076765(n-1). - R. J. Mathar, Oct 16 2008
G.f.: -3*x / ( (x-1)*(x^2-8*x+1) ). - R. J. Mathar, Nov 27 2011
a(n) = 9*a(n-1) - 9*a(n-2) + a(n-3); a(0)=0, a(1)=3, a(2)=27. - Harvey P. Dale, May 06 2013

Extensions

Made definition and sequence consistent. Changed offset to 0. - R. J. Mathar, Oct 16 2008
Showing 1-4 of 4 results.