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

A089072 Triangle read by rows: T(n,k) = k^n, n >= 1, 1 <= k <= n.

Original entry on oeis.org

1, 1, 4, 1, 8, 27, 1, 16, 81, 256, 1, 32, 243, 1024, 3125, 1, 64, 729, 4096, 15625, 46656, 1, 128, 2187, 16384, 78125, 279936, 823543, 1, 256, 6561, 65536, 390625, 1679616, 5764801, 16777216, 1, 512, 19683, 262144, 1953125, 10077696, 40353607, 134217728, 387420489
Offset: 1

Views

Author

Alford Arnold, Dec 04 2003

Keywords

Comments

T(n, k) = number of mappings from an n-element set into a k-element set. - Clark Kimberling, Nov 26 2004
Let S be the semigroup of (full) transformations on [n]. Let a be in S with rank(a) = k. Then T(n,k) = |a S|, the number of elements in the right principal ideal generated by a. - Geoffrey Critzer, Dec 30 2021
From Manfred Boergens, Jun 23 2024: (Start)
In the following two comments the restriction k<=n can be lifted, allowing all k>=1.
T(n,k) is the number of n X k binary matrices with row sums = 1.
T(n,k) is the number of coverings of [n] by tuples (A_1,...,A_k) in P([n])^k with disjoint A_j, with P(.) denoting the power set.
For nonempty A_j see A019538.
For tuples with "disjoint" dropped see A092477.
For tuples with nonempty A_j and with "disjoint" dropped see A218695. (End)

Examples

			Triangle begins:
  1;
  1,  4;
  1,  8,  27;
  1, 16,  81,  256;
  1, 32, 243, 1024,  3125;
  1, 64, 729, 4096, 15625, 46656;
  ...
		

Crossrefs

Related to triangle of Eulerian numbers A008292.

Programs

  • Haskell
    a089072 = flip (^)
    a089072_row n = map (a089072 n) [1..n]
    a089072_tabl = map a089072_row [1..]  -- Reinhard Zumkeller, Mar 18 2013
    
  • Magma
    [k^n: k in [1..n], n in [1..12]]; // G. C. Greubel, Nov 01 2022
    
  • Mathematica
    Column[Table[k^n, {n, 8}, {k, n}], Center] (* Alonso del Arte, Nov 14 2011 *)
  • SageMath
    flatten([[k^n for k in range(1,n+1)] for n in range(1,12)]) # G. C. Greubel, Nov 01 2022

Formula

Sum_{k=1..n} T(n, k) = A031971(n).
T(n, n) = A000312(n).
T(2*n, n) = A062206(n).
a(n) = (n + T*(1-T)/2)^T, where T = round(sqrt(2*n),0). - Gerald Hillier, Apr 12 2015
T(n,k) = A051129(n,k). - R. J. Mathar, Dec 10 2015
T(n,k) = Sum_{i=0..k} Stirling2(n,i)*binomial(k,i)*i!. - Geoffrey Critzer, Dec 30 2021
From G. C. Greubel, Nov 01 2022: (Start)
T(n, n-1) = A007778(n-1), n >= 2.
T(n, n-2) = A008788(n-2), n >= 3.
T(2*n+1, n) = A085526(n).
T(2*n-1, n) = A085524(n).
T(2*n-1, n-1) = A085526(n-1), n >= 2.
T(3*n, n) = A083282(n).
Sum_{k=1..n} (-1)^k * T(n, k) = (-1)^n * A120485(n).
Sum_{k=1..floor(n/2)} T(n-k, k) = A226065(n).
Sum_{k=1..floor(n/2)} T(n, k) = A352981(n).
Sum_{k=1..floor(n/3)} T(n, k) = A352982(n). (End)

Extensions

More terms and better definition from Herman Jamke (hermanjamke(AT)fastmail.fm), Jul 10 2004
Offset corrected by Reinhard Zumkeller, Mar 18 2013

A347281 a(n) = 2^(n - 1)*permanent(M_n)^2 where M_n is the n X n matrix M_n(j, k) = cos(Pi*j*k/n).

Original entry on oeis.org

1, 2, 4, 0, 36, 288, 144, 18432, 11664, 115200, 144400, 0, 808151184, 133693952, 262440000, 299649466368, 7937314520976, 73575242956800, 21204146201616, 6459752448000000, 212406372892224, 8753824001424826368, 195844025123172289600, 152252829159294763008, 26487254903393025000000
Offset: 1

Views

Author

Hugo Pfoertner, Sep 18 2021

Keywords

Examples

			a(7) = -3384288*cos(Pi/7) - 3460896*sin(Pi/14) - 45888*cos(2*Pi/7) - 28224*cos(15*Pi/7) + 48384*cos(17*Pi/7) + 1706400 + 3458400*sin(3*Pi/14) = 144. - _Chai Wah Wu_, Sep 19 2021
		

Crossrefs

Programs

  • PARI
    P(n)=matpermanent(matrix(n,n,j,k,cos((Pi*j*k)/n)));
    for(k=1,25,print1(round(2^(k-1)*P(k)^2),", "))

A165156 n^(2*n-1)-(2*n-1)^n.

Original entry on oeis.org

0, -1, 118, 13983, 1894076, 361025495, 96826261890, 35181809198207, 16677063111790072, 9999993868933742199, 7400249593980659558990, 6624737245034612579099807, 7056410013376700546645974068
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    p=1;lst={};Do[AppendTo[lst,n^p-p^n];p=p+2,{n,4!}];lst
    Table[n^(2n-1)-(2n-1)^n,{n,20}] (* Harvey P. Dale, Aug 10 2023 *)

Formula

a(n) = A085524(n)-A085528(n-1).

Extensions

Definition corrected by R. J. Mathar, Sep 06 2009

A259926 a(n) = n^(2*n) - n^(2*n - 1).

Original entry on oeis.org

0, 8, 486, 49152, 7812500, 1813985280, 581334062442, 246290604621824, 133417453597332552, 90000000000000000000, 74002499442581601012110, 72872109936441607122321408, 84676920178401799992368876316, 114656931713301654695784797437952, 178967655284025147557258605957031250
Offset: 1

Views

Author

Ilya Gutkovskiy, Jul 09 2015

Keywords

Crossrefs

Programs

  • Magma
    [n^(2*n) - n^(2*n - 1): n in [1..20]]; // Vincenzo Librandi, Jul 10 2015
  • Mathematica
    Table[n^(2 n) - n^(2 n - 1), {n, 15}]
    Array[#^(2 #) - #^(2 # - 1)&, 15] (* Vincenzo Librandi, Jul 10 2015 *)
  • PARI
    vector(20, n, n^(2*n) - n^(2*n-1)) \\ Michel Marcus, Jul 09 2015
    
  • Sage
    [n**(2*n) - n**(2*n - 1) for n in range(1, 20)] # Anders Hellström, Jul 10 2015
    

Formula

a(n) = A062206(n) - A085524(n).
a(n) = n^A005843(n) - n^A005408(n-1).
a(n) = n! * [x^n] LambertW(-n*x)^2 / (1 + LambertW(-n*x)). - Ilya Gutkovskiy, Mar 24 2020

A355858 a(n) = n^(2*n-1) mod (2*n-1).

Original entry on oeis.org

0, 2, 3, 4, 8, 6, 7, 2, 9, 10, 8, 12, 18, 26, 15, 16, 29, 2, 19, 5, 21, 22, 8, 24, 18, 32, 27, 32, 50, 30, 31, 8, 63, 34, 26, 36, 37, 32, 30, 40, 80, 42, 8, 11, 45, 32, 35, 22, 49, 35, 51, 52, 8, 54, 55, 14, 57, 87, 8, 2, 94, 77, 68, 64, 113, 66, 53, 107, 69
Offset: 1

Views

Author

Jonas Kaiser, Jul 20 2022

Keywords

Comments

If a(n) = n then 2*n-1 is prime or Fermat pseudoprime to base 2.

Crossrefs

Programs

  • Mathematica
    a[n_] := PowerMod[n, 2*n - 1, 2*n - 1]; Array[a, 100] (* Amiram Eldar, Jul 23 2022 *)
  • PARI
    a(n)=n^(2*n-1)%(2*n-1)
    
  • PARI
    a(n)=lift(Mod(n, 2*n-1)^(2*n-1)) \\ Rémy Sigrist, Jul 21 2022
    
  • Python
    def a(n): return pow(n, 2*n-1, 2*n-1)
    print([a(n) for n in range(1, 70)]) # Michael S. Branicky, Jul 23 2022
Showing 1-5 of 5 results.