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-10 of 115 results. Next

A257471 Sequence obtained from A003991 (multiplication table read by antidiagonals) by removing repetitions.

Original entry on oeis.org

1, 2, 3, 4, 6, 5, 8, 9, 10, 12, 7, 15, 16, 14, 18, 20, 21, 24, 25, 28, 30, 11, 27, 32, 35, 36, 22, 40, 42, 13, 33, 45, 48, 49, 26, 44, 50, 54, 56, 39, 55, 60, 63, 64, 52, 66, 70, 72, 17, 65, 77, 80, 81, 34, 78, 84, 88, 90, 19, 51, 75, 91, 96, 99, 100
Offset: 1

Views

Author

Ivan Neretin, Apr 25 2015

Keywords

Comments

A permutation of positive integers.

Examples

			The infinite multiplication table
1...2...3...4...5...
2...4...6...8..10...
3...6...9..12..15...
4...8..12..16..20...
5..10..15..20..25...
...
reads by antidiagonals as follows: 1, 2, 2, 3, 4, 3, 4, 6, 6, 4, 5, 8, 9, 8, 5, ... (A003991). By removing all numbers that were encountered previously, we get 1, 2, 3, 4, 6, 5, 8, 9, ...
		

Crossrefs

Cf. A003991 (multiplication table), A257472 (inverse permutation).

Programs

  • Mathematica
    DeleteDuplicates[Flatten[Table[i * (n - i), {n, 20}, {i, n - 1}]]]

A374817 Irregular table T(n, k), n > 0, k = 1..A000005(n), read by rows; the n-th row lists the numbers m such that A003991(m) = n.

Original entry on oeis.org

1, 2, 3, 4, 6, 5, 7, 10, 11, 15, 8, 9, 16, 21, 22, 28, 12, 14, 29, 36, 13, 37, 45, 17, 20, 46, 55, 56, 66, 18, 19, 23, 27, 67, 78, 79, 91, 30, 35, 92, 105, 24, 26, 106, 120, 25, 38, 44, 121, 136, 137, 153, 31, 34, 47, 54, 154, 171, 172, 190, 32, 33, 57, 65, 191, 210
Offset: 1

Views

Author

Rémy Sigrist, Jul 21 2024

Keywords

Comments

A003991 corresponds to a square array, but we consider it here as a flat sequence (when its values are read according along its antidiagonals).
This sequence is a permutation of the positive integers with inverse A374818.

Examples

			Table T(n, k) begins:
  n   n-th row
  --  ----------------------
   1  1
   2  2, 3
   3  4, 6
   4  5, 7, 10
   5  11, 15
   6  8, 9, 16, 21
   7  22, 28
   8  12, 14, 29, 36
   9  13, 37, 45
  10  17, 20, 46, 55
  11  56, 66
  12  18, 19, 23, 27, 67, 78
  13  79, 91
  14  30, 35, 92, 105
  15  24, 26, 106, 120
		

Crossrefs

See A374799 for a similar sequence.
Cf. A000005, A000217, A003991, A374818 (inverse).

Programs

  • PARI
    \\ See Links section.

Formula

T(n, A000005(n)) = A000217(n).

A375797 Table T(n, k) read by upward antidiagonals. The sequences in each column k is a triangle read by rows (blocks), where each row is a permutation of the numbers of its constituents. Row number n in column k has length n*k = A003991(n,k); see Comments.

Original entry on oeis.org

1, 2, 1, 3, 2, 3, 6, 3, 2, 1, 5, 5, 1, 3, 5, 4, 4, 4, 2, 2, 1, 7, 6, 8, 4, 3, 5, 7, 9, 7, 6, 5, 4, 3, 2, 1, 8, 11, 7, 11, 1, 4, 5, 7, 9, 10, 9, 5, 7, 6, 2, 4, 3, 2, 1, 15, 10, 9, 9, 14, 6, 3, 5, 7, 9, 11, 12, 8, 18, 8, 8, 7, 6, 4, 4, 3, 2, 1, 13, 12, 11, 10, 12, 17, 1, 6, 5, 7, 9, 11, 13, 14, 13, 16, 6, 10, 9, 8, 2, 6, 5, 4, 3, 2, 1
Offset: 1

Views

Author

Boris Putievskiy, Aug 29 2024

Keywords

Comments

A208233 presents an algorithm for generating permutations, where each generated permutation is self-inverse.
The sequence in each column k possesses two properties: it is both a self-inverse permutation and an intra-block permutation of natural numbers.

Examples

			Table begins:
    k=    1   2   3   4   5   6
  -----------------------------------
  n= 1:   1,  1,  3,  1,  5,  1, ...
  n= 2:   2,  2,  2,  3,  2,  5, ...
  n= 3:   3,  3,  1,  2,  3,  3, ...
  n= 4:   6,  5,  4,  4,  4,  4, ...
  n= 5:   5,  4,  8,  5,  1,  2, ...
  n= 6:   4,  6,  6, 11,  6,  6, ...
  n= 7:   7,  7,  7,  7, 14,  7, ...
  n= 8:   9, 11,  5,  9,  8, 17, ...
  n= 9:   8,  9,  9,  8, 12,  9, ...
  n= 10: 10, 10, 18, 10, 10, 15, ...
  n= 11: 15,  8, 11,  6, 11, 11, ...
  n= 12: 12, 12, 16, 12,  9, 13, ...
  n= 13: 13, 13, 13, 13, 13, 12, ...
  n= 14: 14, 19, 14, 23,  7, 14, ...
  n= 15: 11, 15, 15, 15, 15, 10, ...
  n= 16: 16, 17, 12, 21, 30, 16, ...
  n= 17: 20, 16, 17, 17, 17,  8, ...
  n= 18: 18, 18, 10, 19, 28, 18, ...
     ... .
In column 3, the first 3 blocks have lengths 3,6 and 9. In column 6, the first 2 blocks have lengths 6 and 12. Each block is a permutation of the numbers of its constituents.
The first 6 antidiagonals are:
  1;
  2,1;
  3,2,3;
  6,3,2,1;
  5,5,1,3,5;
  4,4,4,2,2,1;
		

Crossrefs

Programs

  • Mathematica
    T[n_,k_]:=Module[{L,R,P,result},L=Ceiling[(Sqrt[8*n*k+k^2]-k)/(2*k)]; R=n-k*(L-1)*L/2; P=(((-1)^Max[R,k*L+1-R]+1)*R-((-1)^Max[R,k*L+1-R]-1)*(k*L+1-R))/2; result=P+k*(L-1)*L/2]
    Nmax=18; Table[T[n,k],{n,1,Nmax},{k,1,Nmax}]

Formula

T(n,k) = P(n,k) + k*(L(n,k)-1)*L(n,k)/2 = P(n,k) + A062707(L(n-1),k), where L(n,k) = ceiling((sqrt(8*n*k+k^2)-k)/(2*k)), R(n,k) = n-k*(L(n,k)-1)*L(n,k)/2, P(n,k) = (((-1)^max(R(n,k),k*L(n,k)+1-R(n,k))+1)*R(n,k)-((-1)^max(R(n,k),k*L(n,k)+1-R(n,k))-1)*(k*L(n,k)+1-R(n,k)))/2.
T(n,1) = A188568(n). T(1,k) = A093178(k). T(n,n) = A124625(n). L(n,1) = A002024(n). L(n,2) = A000194(n). L(n,3) = A111651(n). L(n,4) = A371355(n). R(n,1) = A002260(n). R(n,2) = A074294(n).

A204170 Array read by rows: row n lists the coefficients of the characteristic polynomial of the n-th principal submatrix of (i*j), as in A003991.

Original entry on oeis.org

1, -1, 0, -5, 1, 0, 0, 14, -1, 0, 0, 0, -30, 1, 0, 0, 0, 0, 55, -1, 0, 0, 0, 0, 0, -91, 1, 0, 0, 0, 0, 0, 0, 140, -1, 0, 0, 0, 0, 0, 0, 0, -204, 1, 0, 0, 0, 0, 0, 0, 0, 0, 285, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, -385, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 506, -1
Offset: 1

Views

Author

Clark Kimberling, Jan 12 2012

Keywords

Comments

Let p(n)=p(n,x) be the characteristic polynomial of the n-th principal submatrix. The zeros of p(n) are real, and they interlace the zeros of p(n+1). See A202605 and A204016 for guides to related sequences.
p(n,x) = x^n + (-1)^n*s(n)*x^n - 1, where s=A000330 (square pyramidal numbers).

Examples

			Top of the array:
  1, -1;
  0, -5,  1;
  0,  0, 14,  -1;
  0,  0,  0, -30, 1;
		

References

  • (For references regarding interlacing roots, see A202605.)

Crossrefs

Programs

  • Mathematica
    f[i_, j_] := i*j;
    m[n_] := Table[f[i, j], {i, 1, n}, {j, 1, n}]
    TableForm[m[8]] (* 8x8 principal submatrix *)
    Flatten[Table[f[i, n + 1 - i],
      {n, 1, 15}, {i, 1, n}]]  (* A003991 *)
    p[n_] := CharacteristicPolynomial[m[n], x];
    c[n_] := CoefficientList[p[n], x]
    TableForm[Flatten[Table[p[n], {n, 1, 10}]]]
    Table[c[n], {n, 1, 12}]
    Flatten[%]                (* A204170 *)
    TableForm[Table[c[n], {n, 1, 10}]]

A130762 A fold back triangular sequence for A003991: symmetrical folding and addition of.

Original entry on oeis.org

1, 4, 6, 4, 8, 12, 10, 16, 9, 12, 20, 24, 14, 24, 30, 16, 16, 28, 36, 40, 18, 32, 42, 48, 25, 20, 36, 48, 56, 60, 22, 40, 54, 64, 70, 36, 24, 44, 60, 72, 80, 84, 26, 48, 66, 80, 90, 96, 49, 28, 52, 72, 88, 100, 108, 112, 30, 56, 78, 96, 110, 120, 126, 64, 32, 60, 84, 104, 120
Offset: 1

Views

Author

Roger L. Bagula, Jul 13 2007

Keywords

Comments

Row sum is still A000292. These sequences are related to heights of Cartan A_n groups. I spent half the night trying to get this algorithm to work and just barely got this to do what I was doing with ease by hand. The other fold back sequences were analogs for this.

Examples

			{1},
{4},
{6, 4},
{8, 12},
{10, 16, 9},
{12, 20, 24},
{14, 24, 30, 16},
{16, 28, 36, 40},
{18, 32, 42, 48, 25},
{20, 36, 48, 56, 60},
{22, 40, 54, 64, 70, 36},
{24, 44, 60, 72, 80, 84}
		

Crossrefs

Programs

  • Mathematica
    (* first A003991*) a = Table[Table[(n - i)*(1 + i), {i, 0, n - 1}], {n, 1, 20}]; (* then fold back from that*) Table[Table[If[ Mod[n, 2] == 1, a[[n]][[m]] + a[[n]][[Length[a[[n]]] - m]] - n, If[m - Floor[ n/2] == 0, (a[[n]][[m]] + a[[ n]][[Length[a[[n]]] - m]] - n)/ 2, a[[n]][[m]] + a[[n]][[Length[a[[n]]] - m]] - n]], {m, 1, Floor[n/ 2]}], {n, 1, Length[a]}]; Flatten[%]

Formula

a0(n,m) = (n-m)*(1+m) Doubling of all elements a(n,m)=2*a0(n,m)-> m->Floor[n/2] except for the uneven middle element on odd sequences in n.

A000012 The simplest sequence of positive numbers: the all 1's sequence.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 0

Views

Author

N. J. A. Sloane, May 16 1994

Keywords

Comments

Number of ways of writing n as a product of primes.
Number of ways of writing n as a sum of distinct powers of 2.
Continued fraction for golden ratio A001622.
Partial sums of A000007 (characteristic function of 0). - Jeremy Gardiner, Sep 08 2002
An example of an infinite sequence of positive integers whose distinct pairwise concatenations are all primes! - Don Reble, Apr 17 2005
Binomial transform of A000007; inverse binomial transform of A000079. - Philippe Deléham, Jul 07 2005
A063524(a(n)) = 1. - Reinhard Zumkeller, Oct 11 2008
For n >= 0, let M(n) be the matrix with first row = (n n+1) and 2nd row = (n+1 n+2). Then a(n) = absolute value of det(M(n)). - K.V.Iyer, Apr 11 2009
The partial sums give the natural numbers (A000027). - Daniel Forgues, May 08 2009
From Enrique Pérez Herrero, Sep 04 2009: (Start)
a(n) is also tau_1(n) where tau_2(n) is A000005.
a(n) is a completely multiplicative arithmetical function.
a(n) is both squarefree and a perfect square. See A005117 and A000290. (End)
Also smallest divisor of n. - Juri-Stepan Gerasimov, Sep 07 2009
Also decimal expansion of 1/9. - Enrique Pérez Herrero, Sep 18 2009; corrected by Klaus Brockhaus, Apr 02 2010
a(n) is also the number of complete graphs on n nodes. - Pablo Chavez (pchavez(AT)cmu.edu), Sep 15 2009
Totally multiplicative sequence with a(p) = 1 for prime p. Totally multiplicative sequence with a(p) = a(p-1) for prime p. - Jaroslav Krizek, Oct 18 2009
n-th prime minus phi(prime(n)); number of divisors of n-th prime minus number of perfect partitions of n-th prime; the number of perfect partitions of n-th prime number; the number of perfect partitions of n-th noncomposite number. - Juri-Stepan Gerasimov, Oct 26 2009
For all n>0, the sequence of limit values for a(n) = n!*Sum_{k>=n} k/(k+1)!. Also, a(n) = n^0. - Harlan J. Brothers, Nov 01 2009
a(n) is also the number of 0-regular graphs on n vertices. - Jason Kimberley, Nov 07 2009
Differences between consecutive n. - Juri-Stepan Gerasimov, Dec 05 2009
From Matthew Vandermast, Oct 31 2010: (Start)
1) When sequence is read as a regular triangular array, T(n,k) is the coefficient of the k-th power in the expansion of (x^(n+1)-1)/(x-1).
2) Sequence can also be read as a uninomial array with rows of length 1, analogous to arrays of binomial, trinomial, etc., coefficients. In a q-nomial array, T(n,k) is the coefficient of the k-th power in the expansion of ((x^q -1)/(x-1))^n, and row n has a sum of q^n and a length of (q-1)*n + 1. (End)
The number of maximal self-avoiding walks from the NW to SW corners of a 2 X n grid.
When considered as a rectangular array, A000012 is a member of the chain of accumulation arrays that includes the multiplication table A003991 of the positive integers. The chain is ... < A185906 < A000007 < A000012 < A003991 < A098358 < A185904 < A185905 < ... (See A144112 for the definition of accumulation array.) - Clark Kimberling, Feb 06 2011
a(n) = A007310(n+1) (Modd 3) := A193680(A007310(n+1)), n>=0. For general Modd n (not to be confused with mod n) see a comment on A203571. The nonnegative members of the three residue classes Modd 3, called [0], [1], and [2], are shown in the array A088520, if there the third row is taken as class [0] after inclusion of 0. - Wolfdieter Lang, Feb 09 2012
Let M = Pascal's triangle without 1's (A014410) and V = a variant of the Bernoulli numbers A027641 but starting [1/2, 1/6, 0, -1/30, ...]. Then M*V = [1, 1, 1, 1, ...]. - Gary W. Adamson, Mar 05 2012
As a lower triangular array, T is an example of the fundamental generalized factorial matrices of A133314. Multiplying each n-th diagonal by t^n gives M(t) = I/(I-t*S) = I + t*S + (t*S)^2 + ... where S is the shift operator A129184, and T = M(1). The inverse of M(t) is obtained by multiplying the first subdiagonal of T by -t and the other subdiagonals by zero, so A167374 is the inverse of T. Multiplying by t^n/n! gives exp(t*S) with inverse exp(-t*S). - Tom Copeland, Nov 10 2012
The original definition of the meter was one ten-millionth of the distance from the Earth's equator to the North Pole. According to that historical definition, the length of one degree of latitude, that is, 60 nautical miles, would be exactly 111111.111... meters. - Jean-François Alcover, Jun 02 2013
Deficiency of 2^n. - Omar E. Pol, Jan 30 2014
Consider n >= 1 nonintersecting spheres each with surface area S. Define point p on sphere S_i to be a "public point" if and only if there exists a point q on sphere S_j, j != i, such that line segment pq INTERSECT S_i = {p} and pq INTERSECT S_j = {q}; otherwise, p is a "private point". The total surface area composed of exactly all private points on all n spheres is a(n)*S = S. ("The Private Planets Problem" in Zeitz.) - Rick L. Shepherd, May 29 2014
For n>0, digital roots of centered 9-gonal numbers (A060544). - Colin Barker, Jan 30 2015
Product of nonzero digits in base-2 representation of n. - Franklin T. Adams-Watters, May 16 2016
Alternating row sums of triangle A104684. - Wolfdieter Lang, Sep 11 2016
A fixed point of the run length transform. - Chai Wah Wu, Oct 21 2016
Length of period of continued fraction for sqrt(A002522) or sqrt(A002496). - A.H.M. Smeets, Oct 10 2017
a(n) is also the determinant of the (n+1) X (n+1) matrix M defined by M(i,j) = binomial(i,j) for 0 <= i,j <= n, since M is a lower triangular matrix with main diagonal all 1's. - Jianing Song, Jul 17 2018
a(n) is also the determinant of the symmetric n X n matrix M defined by M(i,j) = min(i,j) for 1 <= i,j <= n (see Xavier Merlin reference). - Bernard Schott, Dec 05 2018
a(n) is also the determinant of the symmetric n X n matrix M defined by M(i,j) = tau(gcd(i,j)) for 1 <= i,j <= n (see De Koninck & Mercier reference). - Bernard Schott, Dec 08 2020

Examples

			1 + 1/(1 + 1/(1 + 1/(1 + 1/(1 + ...)))) = A001622.
1/9 = 0.11111111111111...
From _Wolfdieter Lang_, Feb 09 2012: (Start)
Modd 7 for nonnegative odd numbers not divisible by 3:
A007310: 1, 5, 7, 11, 13, 17, 19, 23, 25, 29, 31, 35, 37, ...
Modd 3:  1, 1, 1,  1,  1,  1,  1,  1,  1,  1,  1,  1,  1, ...
(End)
		

References

  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See p. 186.
  • J.-M. De Koninck & A. Mercier, 1001 Problèmes en Théorie Classique des Nombres, Problème 692 pp. 90 and 297, Ellipses, Paris, 2004.
  • Xavier Merlin, Méthodix Algèbre, Exercice 1-a), page 153, Ellipses, Paris, 1995.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, pages 277, 284.
  • S. Wolfram, A New Kind of Science, Wolfram Media, 2002; p. 55.
  • Paul Zeitz, The Art and Craft of Mathematical Problem Solving, The Great Courses, The Teaching Company, 2010 (DVDs and Course Guidebook, Lecture 6: "Pictures, Recasting, and Points of View", pp. 32-34).

Crossrefs

Programs

  • Haskell
    a000012 = const 1
    a000012_list = repeat 1 -- Reinhard Zumkeller, May 07 2012
    
  • Magma
    [1 : n in [0..100]];
    
  • Maple
    seq(1, i=0..150);
  • Mathematica
    Array[1 &, 50] (* Joseph Biberstine (jrbibers(AT)indiana.edu), Dec 26 2006 *)
  • Maxima
    makelist(1, n, 1, 30); /* Martin Ettl, Nov 07 2012 */
    
  • PARI
    {a(n) = 1};
    
  • Python
    print([1 for n in range(90)]) # Michael S. Branicky, Apr 04 2022

Formula

a(n) = 1.
G.f.: 1/(1-x).
E.g.f.: exp(x).
G.f.: Product_{k>=0} (1 + x^(2^k)). - Zak Seidov, Apr 06 2007
Completely multiplicative with a(p^e) = 1.
Regarded as a square array by antidiagonals, g.f. 1/((1-x)(1-y)), e.g.f. Sum T(n,m) x^n/n! y^m/m! = e^{x+y}, e.g.f. Sum T(n,m) x^n y^m/m! = e^y/(1-x). Regarded as a triangular array, g.f. 1/((1-x)(1-xy)), e.g.f. Sum T(n,m) x^n y^m/m! = e^{xy}/(1-x). - Franklin T. Adams-Watters, Feb 06 2006
Dirichlet g.f.: zeta(s). - Ilya Gutkovskiy, Aug 31 2016
a(n) = Sum_{l=1..n} (-1)^(l+1)*2*cos(Pi*l/(2*n+1)) = 1 identically in n >= 1 (for n=0 one has 0 from the undefined sum). From the Jolley reference, (429) p. 80. Interpretation: consider the n segments between x=0 and the n positive zeros of the Chebyshev polynomials S(2*n, x) (see A049310). Then the sum of the lengths of every other segment starting with the one ending in the largest zero (going from the right to the left) is 1. - Wolfdieter Lang, Sep 01 2016
As a lower triangular matrix, T = M*T^(-1)*M = M*A167374*M, where M(n,k) = (-1)^n A130595(n,k). Note that M = M^(-1). Cf. A118800 and A097805. - Tom Copeland, Nov 15 2016

A059897 Symmetric square array read by antidiagonals: A(n,k) is the product of all factors that occur in one, but not both, of the Fermi-Dirac factorizations of n and k.

Original entry on oeis.org

1, 2, 2, 3, 1, 3, 4, 6, 6, 4, 5, 8, 1, 8, 5, 6, 10, 12, 12, 10, 6, 7, 3, 15, 1, 15, 3, 7, 8, 14, 2, 20, 20, 2, 14, 8, 9, 4, 21, 24, 1, 24, 21, 4, 9, 10, 18, 24, 28, 30, 30, 28, 24, 18, 10, 11, 5, 27, 2, 35, 1, 35, 2, 27, 5, 11, 12, 22, 30, 36, 40, 42, 42, 40, 36, 30, 22, 12, 13, 24, 33
Offset: 1

Views

Author

Marc LeBrun, Feb 06 2001

Keywords

Comments

Old name: Square array read by antidiagonals: T(i,j) = product prime(k)^(Ei(k) XOR Ej(k)) where Ei and Ej are the vectors of exponents in the prime factorizations of i and j; XOR is the bitwise operation on binary representation of the exponents.
Analogous to multiplication, with XOR replacing +.
From Peter Munn, Apr 01 2019: (Start)
(1) Defines an abelian group whose underlying set is the positive integers. (2) Every element is self-inverse. (3) For all n and k, A(n,k) is a divisor of n*k. (4) The terms of A050376, sometimes called Fermi-Dirac primes, form a minimal set of generators. In ordered form, it is the lexicographically earliest such set.
The unique factorization of positive integers into products of distinct terms of the group's lexicographically earliest minimal set of generators seems to follow from (1) (2) and (3).
From (1) and (2), every row and every column of the table is a self-inverse permutation of the positive integers. Rows/columns numbered by nonmembers of A050376 are compositions of earlier rows/columns.
It is a subgroup of the equivalent group over the nonzero integers, which has -1 as an additional generator.
As generated by A050376, the subgroup of even length words is A000379. The complementary set of odd length words is A000028.
The subgroup generated by A000040 (the primes) is A005117 (the squarefree numbers).
(End)
Considered as a binary operation, the result is (the squarefree part of the product of its operands) times the square of (the operation's result when applied to the square roots of the square parts of its operands). - Peter Munn, Mar 21 2022

Examples

			A(864,1944) = A(2^5*3^3,2^3*3^5) = 2^(5 XOR 3) * 3^(3 XOR 5) = 2^6 * 3^6 = 46656.
The top left 12 X 12 corner of the array:
   1,  2,  3,  4,  5,  6,  7,  8,   9,  10,  11,  12
   2,  1,  6,  8, 10,  3, 14,  4,  18,   5,  22,  24
   3,  6,  1, 12, 15,  2, 21, 24,  27,  30,  33,   4
   4,  8, 12,  1, 20, 24, 28,  2,  36,  40,  44,   3
   5, 10, 15, 20,  1, 30, 35, 40,  45,   2,  55,  60
   6,  3,  2, 24, 30,  1, 42, 12,  54,  15,  66,   8
   7, 14, 21, 28, 35, 42,  1, 56,  63,  70,  77,  84
   8,  4, 24,  2, 40, 12, 56,  1,  72,  20,  88,   6
   9, 18, 27, 36, 45, 54, 63, 72,   1,  90,  99, 108
  10,  5, 30, 40,  2, 15, 70, 20,  90,   1, 110, 120
  11, 22, 33, 44, 55, 66, 77, 88,  99, 110,   1, 132
  12, 24,  4,  3, 60,  8, 84,  6, 108, 120, 132,   1
From _Peter Munn_, Apr 04 2019: (Start)
The subgroup generated by {6,8,10}, the first three integers > 1 not in A050376, has the following table:
    1     6     8    10    12    15    20   120
    6     1    12    15     8    10   120    20
    8    12     1    20     6   120    10    15
   10    15    20     1   120     6     8    12
   12     8     6   120     1    20    15    10
   15    10   120     6    20     1    12     8
   20   120    10     8    15    12     1     6
  120    20    15    12    10     8     6     1
(End)
		

Crossrefs

Cf. A284567 (A000142 or A003418-analog for this operation).
Rows/columns: A073675 (2), A120229 (3), A120230 (4), A307151 (5), A307150 (6), A307266 (8), A307267 (24).
Particularly significant subgroups or cosets: A000028, A000379, A003159, A005117, A030229, A252895. See also the lists in A329050, A352273.
Sequences that relate this sequence to multiplication: A000188, A007913, A059895.

Programs

  • Mathematica
    a[i_, i_] = 1;
    a[i_, j_] := Module[{f1 = FactorInteger[i], f2 = FactorInteger[j], e1, e2}, e1[] = 0; Scan[(e1[#[[1]]] = #[[2]])&, f1]; e2[] = 0; Scan[(e2[#[[1]]] = #[[2]])&, f2]; Times @@ (#^BitXor[e1[#], e2[#]]& /@ Union[f1[[All, 1]], f2[[All, 1]]])];
    Table[a[i - j + 1, j], {i, 1, 15}, {j, 1, i}] // Flatten (* Jean-François Alcover, Jun 19 2018 *)
  • PARI
    T(n,k) = {if (n==1, return (k)); if (k==1, return (n)); my(fn=factor(n), fk=factor(k)); vp = setunion(fn[,1]~, fk[,1]~); prod(i=1, #vp, vp[i]^(bitxor(valuation(n, vp[i]), valuation(k, vp[i]))));} \\ Michel Marcus, Apr 03 2019
    
  • PARI
    T(i, j) = {if(gcd(i, j) == 1, return(i * j)); if(i == j, return(1)); my(f = vecsort(concat(factor(i)~, factor(j)~)), t = 1, res = 1); while(t + 1 <= #f, if(f[1, t] == f[1, t+1], res *= f[1, t] ^ bitxor(f[2, t] , f[2, t+1]); t+=2; , res*= f[1, t]^f[2, t]; t++; ) ); if(t == #f, res *= f[1, #f] ^ f[2, #f]); res } \\ David A. Corneth, Apr 03 2019
    
  • PARI
    A059897(n,k) = if(n==k, 1, core(n*k) * A059897(core(n,1)[2],core(k,1)[2])^2) \\ Peter Munn, Mar 21 2022
  • Scheme
    (define (A059897 n) (A059897bi (A002260 n) (A004736 n)))
    (define (A059897bi a b) (let loop ((a a) (b b) (m 1)) (cond ((= 1 a) (* m b)) ((= 1 b) (* m a)) ((equal? (A020639 a) (A020639 b)) (loop (A028234 a) (A028234 b) (* m (expt (A020639 a) (A003987bi (A067029 a) (A067029 b)))))) ((< (A020639 a) (A020639 b)) (loop (/ a (A028233 a)) b (* m (A028233 a)))) (else (loop a (/ b (A028233 b)) (* m (A028233 b)))))))
    ;; Antti Karttunen, Apr 11 2017
    

Formula

For all x, y >= 1, A(x,y) * A059895(x,y)^2 = x*y. - Antti Karttunen, Apr 11 2017
From Peter Munn, Apr 01 2019: (Start)
A(n,1) = A(1,n) = n
A(n, A(m,k)) = A(A(n,m), k)
A(n,n) = 1
A(n,k) = A(k,n)
if i_1 <> i_2 then A(A050376(i_1), A050376(i_2)) = A050376(i_1) * A050376(i_2)
if A(n,k_1) = n * k_1 and A(n,k_2) = n * k_2 then A(n, A(k_1,k_2)) = n * A(k_1,k_2)
(End)
T(k, m) = k*m for coprime k and m. - David A. Corneth, Apr 03 2019
if A(n*m,m) = n, A(n*m,k) = A(n,k) * A(m,k) / k. - Peter Munn, Apr 04 2019
A(n,k) = A007913(n*k) * A(A000188(n), A000188(k))^2. - Peter Munn, Mar 21 2022

Extensions

New name from Peter Munn, Mar 21 2022

A204016 Symmetric matrix based on f(i,j) = max(j mod i, i mod j), by antidiagonals.

Original entry on oeis.org

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

Views

Author

Clark Kimberling, Jan 10 2012

Keywords

Comments

A204016 represents the matrix M given by f(i,j) = max{(j mod i), (i mod j)} for i >= 1 and j >= 1. See A204017 for characteristic polynomials of principal submatrices of M, with interlacing zeros.
Guide to symmetric matrices M based on functions f(i,j) and characteristic polynomial sequences (c.p.s.) with interlaced zeros:
f(i,j)..........................M.........c.p.s.
C(i+j,j)........................A007318...A045912
min(i,j)........................A003983...A202672
max(i,j)........................A051125...A203989
(i+j)*min(i,j)..................A203990...A203991
|i-j|...........................A049581...A203993
max(i-j+1,j-i+1)................A143182...A203992
min(i-j+1,j-i+1)................A203994...A203995
min(i(j+1),j(i+1))..............A203996...A203997
max(i(j+1)-1,j(i+1)-1)..........A203998...A203999
min(i(j+1)-1,j(i+1)-1)..........A204000...A204001
min(2i+j,i+2j)..................A204002...A204003
max(2i+j-2,i+2j-2)..............A204004...A204005
min(2i+j-2,i+2j-2)..............A204006...A204007
max(3i+j-3,i+3j-3)..............A204008...A204011
min(3i+j-3,i+3j-3)..............A204012...A204013
min(3i-2,3j-2)..................A204028...A204029
1+min(j mod i, i mod j).........A204014...A204015
max(j mod i, i mod j)...........A204016...A204017
1+max(j mod i, i mod j).........A204018...A204019
min(i^2,j^2)....................A106314...A204020
min(2i-1, 2j-1).................A157454...A204021
max(2i-1, 2j-1).................A204022...A204023
min(i(i+1)/2,j(j+1)/2)..........A106255...A204024
gcd(i,j)........................A003989...A204025
gcd(i+1,j+1)....................A204030...A204111
min(F(i+1),F(j+1)),F=A000045....A204026...A204027
gcd(F(i+1),F(j+1)),F=A000045....A204112...A204113
gcd(L(i),L(j)),L=A000032........A204114...A204115
gcd(2^i-1,2^j-2)................A204116...A204117
gcd(prime(i),prime(j))..........A204118...A204119
gcd(prime(i+1),prime(j+1))......A204120...A204121
gcd(2^(i-1),2^(j-1))............A144464...A204122
max(floor(i/j),floor(j/i))......A204123...A204124
min(ceiling(i/j),ceiling(j/i))..A204143...A204144
Delannoy matrix.................A008288...A204135
max(2i-j,2j-i)..................A204154...A204155
-1+max(3i-j,3j-i)...............A204156...A204157
max(3i-2j,3j-2i)................A204158...A204159
floor((i+1)/2)..................A204164...A204165
ceiling((i+1)/2)................A204166...A204167
i+j.............................A003057...A204168
i+j-1...........................A002024...A204169
i*j.............................A003991...A204170
..abbreviation below: AOE means "all 1's except"
AOE f(i,i)=i....................A204125...A204126
AOE f(i,i)=A000045(i+1).........A204127...A204128
AOE f(i,i)=A000032(i)...........A204129...A204130
AOE f(i,i)=2i-1.................A204131...A204132
AOE f(i,i)=2^(i-1)..............A204133...A204134
AOE f(i,i)=3i-2.................A204160...A204161
AOE f(i,i)=floor((i+1)/2).......A204162...A204163
...
Other pairs (M, c.p.s.): (A204171, A204172) to (A204183, A204184)
See A202695 for a guide to choices of symmetric matrix M for which the zeros of the characteristic polynomials are all positive.

Examples

			Northwest corner:
  0 1 1 1 1 1 1 1
  0 1 2 2 2 2 2 2
  1 2 0 3 3 3 3 3
  1 2 3 0 4 4 4 4
  1 2 3 4 0 5 5 5
  1 2 3 4 5 0 6 6
  1 2 3 4 5 6 0 7
		

Crossrefs

Programs

  • Mathematica
    f[i_, j_] := Max[Mod[i, j], Mod[j, i]];
    m[n_] := Table[f[i, j], {i, 1, n}, {j, 1, n}]
    TableForm[m[8]] (* 8x8 principal submatrix *)
    Flatten[Table[f[i, n + 1 - i],
    {n, 1, 12}, {i, 1, n}]]  (* A204016 *)
    p[n_] := CharacteristicPolynomial[m[n], x];
    c[n_] := CoefficientList[p[n], x]
    TableForm[Flatten[Table[p[n], {n, 1, 10}]]]
    Table[c[n], {n, 1, 12}]
    Flatten[%]               (* A204017 *)
    TableForm[Table[c[n], {n, 1, 10}]]

A325698 Numbers with as many even as odd prime indices, counted with multiplicity.

Original entry on oeis.org

1, 6, 14, 15, 26, 33, 35, 36, 38, 51, 58, 65, 69, 74, 77, 84, 86, 90, 93, 95, 106, 119, 122, 123, 141, 142, 143, 145, 156, 158, 161, 177, 178, 185, 196, 198, 201, 202, 209, 210, 214, 215, 216, 217, 219, 221, 225, 226, 228, 249, 262, 265, 278, 287, 291, 299
Offset: 1

Views

Author

Gus Wiseman, May 17 2019

Keywords

Comments

These are Heinz numbers of the integer partitions counted by A045931.
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.
The integers in the multiplicative subgroup of positive rational numbers generated by the products of two consecutive primes (A006094). The sequence is closed under multiplication, prime shift (A003961), and - where the result is an integer - under division. Using these closures, all the terms can be derived from the presence of 6. For example, A003961(6) = 15, A003961(15) = 35, 6 * 35 = 210, 210/15 = 14. Closed also under A297845, since A297845 can be defined using squaring, prime shift and multiplication. - Peter Munn, Oct 05 2020

Examples

			The sequence of terms together with their prime indices begins:
    1: {}
    6: {1,2}
   14: {1,4}
   15: {2,3}
   26: {1,6}
   33: {2,5}
   35: {3,4}
   36: {1,1,2,2}
   38: {1,8}
   51: {2,7}
   58: {1,10}
   65: {3,6}
   69: {2,9}
   74: {1,12}
   77: {4,5}
   84: {1,1,2,4}
   86: {1,14}
   90: {1,2,2,3}
   93: {2,11}
   95: {3,8}
		

Crossrefs

Positions of 0's in A195017.
A257992(n) = A257991(n).
Closed under: A003961, A003991, A297845.
Subsequence of A028260, A332820.

Programs

  • Mathematica
    Select[Range[100],Total[Cases[If[#==1,{},FactorInteger[#]],{p_,k_}:>k*(-1)^PrimePi[p]]]==0&]
  • PARI
    is(n) = {my(v = vector(2), f = factor(n));for(i = 1, #f~,v[1 + primepi(f[i, 1])%2]+=f[i, 2]);v[1] == v[2]} \\ David A. Corneth, Oct 06 2020
    
  • Python
    from sympy import factorint, primepi
    def ok(n):
        v = [0, 0]
        for p, e in factorint(n).items(): v[primepi(p)%2] += e
        return v[0] == v[1]
    print([k for k in range(300) if ok(k)]) # Michael S. Branicky, Apr 16 2022 after David A. Corneth

A003989 Triangle T from the array A(x, y) = gcd(x,y), for x >= 1, y >= 1, read by antidiagonals.

Original entry on oeis.org

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

Views

Author

Keywords

Comments

For m < n, the maximal number of nonattacking queens that can be placed on the n by m rectangular toroidal chessboard is gcd(m,n), except in the case m=3, n=6.
The determinant of the matrix of the first n rows and columns is A001088(n). [Smith, Mansion] - Michael Somos, Jun 25 2012
Imagine a torus having regular polygonal cross-section of m sides. Now, break the torus and twist the free ends, preserving rotational symmetry, then reattach the ends. Let n be the number of faces passed in twisting the torus before reattaching it. For example, if n = m, then the torus has exactly one full twist. Do this for arbitrary m and n (m > 1, n > 0). Now, count the independent, closed paths on the surface of the resulting torus, where a path is "closed" if and only if it returns to its starting point after a finite number of times around the surface of the torus. Conjecture: this number is always gcd(m,n). NOTE: This figure constitutes a group with m and n the binary arguments and gcd(m,n) the resulting value. Twisting in the reverse direction is the inverse operation, and breaking & reattaching in place is the identity operation. - Jason Richardson-White, May 06 2013
Regarded as a triangle, table of gcd(n - k +1, k) for 1 <= k <= n. - Franklin T. Adams-Watters, Oct 09 2014
The n-th row of the triangle is 1,...,1, if and only if, n + 1 is prime. - Alexandra Hercilia Pereira Silva, Oct 03 2020

Examples

			The array A begins:
  [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]
  [1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2]
  [1, 1, 3, 1, 1, 3, 1, 1, 3, 1, 1, 3, 1, 1, 3, 1]
  [1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4]
  [1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1]
  [1, 2, 3, 2, 1, 6, 1, 2, 3, 2, 1, 6, 1, 2, 3, 2]
  [1, 1, 1, 1, 1, 1, 7, 1, 1, 1, 1, 1, 1, 7, 1, 1]
  [1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 8]
  [1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1]
  [1, 2, 1, 2, 5, 2, 1, 2, 1, 10, 1, 2, 1, 2, 5, 2]
  [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1]
  [1, 2, 3, 4, 1, 6, 1, 4, 3, 2, 1, 12, 1, 2, 3, 4]
  ...
The triangle T begins:
  n\k 1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 ...
  1:  1
  2:  1  1
  3:  1  2  1
  4:  1  1  1  1
  5:  1  2  3  2  1
  6:  1  1  1  1  1  1
  7:  1  2  1  4  1  2  1
  8:  1  1  3  1  1  3  1  1
  9:  1  2  1  2  5  2  1  2  1
 10:  1  1  1  1  1  1  1  1  1  1
 11:  1  2  3  4  1  6  1  4  3  2  1
 12:  1  1  1  1  1  1  1  1  1  1  1  1
 13:  1  2  1  2  1  2  7  2  1  2  1  2  1
 14:  1  1  3  1  5  3  1  1  3  5  1  3  1  1
 15:  1  2  1  4  1  2  1  8  1  2  1  4  1  2  1
 ...  - _Wolfdieter Lang_, May 12 2018
		

References

  • R. L. Graham, D. E. Knuth and O. Patashnik, Concrete Mathematics, Addison-Wesley, 2nd ed., 1994, ch. 4.
  • D. E. Knuth, The Art of Computer Programming, Addison-Wesley, section 4.5.2.

Crossrefs

Rows, columns and diagonals: A089128, A109007, A109008, A109009, A109010, A109011, A109012, A109013, A109014, A109015.
A109004 is (0, 0) based.
Cf. also A091255 for GF(2)[X] polynomial analog.
A(x, y) = A075174(A004198(A075173(x), A075173(y))) = A075176(A004198(A075175(x), A075175(y))).
Antidiagonal sums are in A006579.

Programs

  • GAP
    Flat(List([1..15],n->List([1..n],k->Gcd(n-k+1,k)))); # Muniru A Asiru, Aug 26 2018
  • Maple
    a:=(n,k)->gcd(n-k+1,k): seq(seq(a(n,k),k=1..n),n=1..15); # Muniru A Asiru, Aug 26 2018
  • Mathematica
    Table[ GCD[x - y + 1, y], {x, 1, 15}, {y, 1, x}] // Flatten (* Jean-François Alcover, Dec 12 2012 *)
  • PARI
    {A(n, m) = gcd(n, m)}; /* Michael Somos, Jun 25 2012 */
    

Formula

Multiplicative in both parameters with a(p^e, m) = gcd(p^e, m). - David W. Wilson, Jun 12 2005
T(n, k) = A(n - k + 1, k) = gcd(n - k + 1, k), n >= 1, k = 1..n. See a comment above and the Mathematica program. - Wolfdieter Lang, May 12 2018
Dirichlet generating function: Sum_{n>=1} Sum_{k>=1} gcd(n, k)/n^s/k^c = zeta(s)*zeta(c)*zeta(s + c - 1)/zeta(s + c). - Mats Granvik, Feb 13 2021
The LU decomposition of this square array = A051731 * transpose(A054522) (see Johnson (2003) or Chamberland (2013), p. 1673). - Peter Bala, Oct 15 2023
Showing 1-10 of 115 results. Next