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.

A331761 a(n) = Sum_{i=1..n, j=1..n, gcd(i,j)=2} (n+1-i)*(n+1-j).

Original entry on oeis.org

0, 1, 4, 15, 32, 71, 124, 211, 320, 499, 716, 999, 1328, 1799, 2340, 3023, 3792, 4767, 5852, 7135, 8544, 10319, 12260, 14471, 16864, 19775, 22916, 26467, 30272, 34587, 39188, 44347, 49824, 56195, 62948, 70311, 78080, 86975
Offset: 1

Views

Author

N. J. A. Sloane, Feb 04 2020

Keywords

Crossrefs

Cf. A115004.
The main diagonal of A331762.

Programs

  • Mathematica
    Table[Sum[Boole[GCD[i, j] == 2] (n + 1 - i) (n + 1 - j), {i, n}, {j, n}], {n, 38}] (* Michael De Vlieger, Feb 04 2020 *)
  • Python
    from sympy import totient
    def A331761(n): return (n-1)**2 + 2*sum(totient(i)*(n+1-2*i)*(n+1-i) for i in range(2,n//2+1)) # Chai Wah Wu, Aug 16 2021

Formula

Conjecture: As n -> oo, a(n) ~ C*n^4/Pi^2, where C is about 0.3775. - N. J. A. Sloane, Jul 03 2020
a(n) = (n-1)^2 + 2*Sum_{i=2..floor(n/2)} (n+1-2*i)*(n+1-i)*phi(i). - Chai Wah Wu, Aug 16 2021

A335679 Array read by antidiagonals: T(m,n) (m>=1, n>=1) = number of edges in figure formed by taking m equally spaced points on a line and n equally spaced points on a parallel line, and joining each of the m points to each of the n points by a line segment.

Original entry on oeis.org

1, 3, 3, 5, 8, 5, 7, 15, 15, 7, 9, 24, 28, 24, 9, 11, 35, 47, 47, 35, 11, 13, 48, 69, 80, 69, 48, 13, 15, 63, 97, 119, 119, 97, 63, 15, 17, 80, 128, 170, 178, 170, 128, 80, 17, 19, 99, 165, 225, 257, 257, 225, 165, 99, 19, 21, 120, 205, 292, 340, 372, 340, 292, 205, 120, 21
Offset: 1

Views

Author

Keywords

Comments

The case m=n (the main diagonal) is dealt with in A331757. A306302 has illustrations for the diagonal case for m = 1 to 15.
Also A335678 has colored illustrations for many values of m and n.

Examples

			The initial rows of the array are:
1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, ...
3, 8, 15, 24, 35, 48, 63, 80, 99, 120, 143, 168, ...
5, 15, 28, 47, 69, 97, 128, 165, 205, 251, 300, 355, ...
7, 24, 47, 80, 119, 170, 225, 292, 365, 448, 537, 638, ...
9, 35, 69, 119, 178, 257, 340, 443, 555, 683, 819, 975, ...
11, 48, 97, 170, 257, 372, 493, 644, 809, 998, 1197, 1426, ...
13, 63, 128, 225, 340, 493, 654, 857, 1078, 1331, 1595, 1901, ...
15, 80, 165, 292, 443, 644, 857, 1124, 1415, 1748, 2095, 2498, ...
17, 99, 205, 365, 555, 809, 1078, 1415, 1782, 2203, 2640, 3149, ...
19, 120, 251, 448, 683, 998, 1331, 1748, 2203, 2724, 3265, 3896, ...
21, 143, 300, 537, 819, 1197, 1595, 2095, 2640, 3265, 3914, 4673, ...
...
The initial antidiagonals are:
1
3, 3
5, 8, 5
7, 15, 15, 7
9, 24, 28, 24, 9
11, 35, 47, 47, 35, 11
13, 48, 69, 80, 69, 48, 13
15, 63, 97, 119, 119, 97, 63, 15
17, 80, 128, 170, 178, 170, 128, 80, 17
19, 99, 165, 225, 257, 257, 225, 165, 99, 19
21, 120, 205, 292, 340, 372, 340, 292, 205, 120, 21
23, 143, 251, 365, 443, 493, 493, 443, 365, 251, 143, 23
...
		

Crossrefs

This is one of a set of five arrays: A335678, A335679, A335680, A335681, A335682.
For the diagonal case see A306302 and A331757.

Formula

Comment from Max Alekseyev, Jun 28 2020 (Start):
T(m,n) = 2*A114999(m-1,n-1) - A331762(m-1,n-1) + m*n + m + n - 2 for all m, n >= 1. This follows from the Alekseyev-Basova-Zolotykh (2015) article.
Proof: Here is the appropriate modification of the corresponding comment in A306302: Assuming that K(m,n) has vertices at (i,0) and (j,1), for i=0..m-1 and j=0..n-1, the projective map (x,y) -> ((1-y)/(x+1), y/(x+1)) maps K(m,n) to the partition of the right triangle described by Alekseyev et al. (2015), for which Theorem 13 gives the number of regions, line segments, and intersection points. (End)

A335680 Array read by antidiagonals: T(m,n) (m>=1, n>=1) = number of vertices in figure formed by taking m equally spaced points on a line and n equally spaced points on a parallel line, and joining each of the m points to each of the n points by a line segment.

Original entry on oeis.org

2, 3, 3, 4, 5, 4, 5, 8, 8, 5, 6, 12, 13, 12, 6, 7, 17, 21, 21, 17, 7, 8, 23, 30, 35, 30, 23, 8, 9, 30, 42, 51, 51, 42, 30, 9, 10, 38, 55, 73, 75, 73, 55, 38, 10, 11, 47, 71, 96, 109, 109, 96, 71, 47, 11, 12, 57, 88, 125, 143, 159, 143, 125, 88, 57, 12, 13, 68, 108, 156, 187, 209, 209, 187, 156, 108, 68, 13
Offset: 1

Views

Author

Keywords

Comments

The case m=n (the main diagonal) is dealt with in A331755. A306302 has illustrations for the diagonal case for m = 1 to 15.
Also A335678 has colored illustrations for many values of m and n.

Examples

			The initial rows of the array are:
  2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, ...
  3, 5, 8, 12, 17, 23, 30, 38, 47, 57, 68, 80, ...
  4, 8, 13, 21, 30, 42, 55, 71, 88, 108, 129, 153, ...
  5, 12, 21, 35, 51, 73, 96, 125, 156, 192, 230, 274, ...
  6, 17, 30, 51, 75, 109, 143, 187, 234, 289, 346, 413, ...
  7, 23, 42, 73, 109, 159, 209, 274, 344, 426, 510, 609, ...
  8, 30, 55, 96, 143, 209, 275, 362, 455, 564, 674, 805, ...
  9, 38, 71, 125, 187, 274, 362, 477, 600, 744, 889, 1062, ...
  10, 47, 88, 156, 234, 344, 455, 600, 755, 937, 1119, 1337, ...
  11, 57, 108, 192, 289, 426, 564, 744, 937, 1163, 1389, 1660, ...
  12, 68, 129, 230, 346, 510, 674, 889, 1119, 1389, 1659, 1984, ...
  ...
The initial antidiagonals are:
  2
  3, 3
  4, 5, 4
  5, 8, 8, 5
  6, 12, 13, 12, 6
  7, 17, 21, 21, 17, 7
  8, 23, 30, 35, 30, 23, 8
  9, 30, 42, 51, 51, 42, 30, 9
  10, 38, 55, 73, 75, 73, 55, 38, 10
  11, 47, 71, 96, 109, 109, 96, 71, 47, 11
  12, 57, 88, 125, 143, 159, 143, 125, 88, 57, 12
  ...
		

Crossrefs

This is one of a set of five arrays: A335678, A335679, A335680, A335681, A335682.
For the diagonal case see A306302 and A331755.

Formula

Comment from Max Alekseyev, Jun 28 2020 (Start):
T(m,n) = A114999(m-1,n-1) - A331762(m-1,n-1) + m + n for all m, n >= 1. This follows from the Alekseyev-Basova-Zolotykh (2015) article.
Proof: Here is the appropriate modification of the corresponding comment in A306302: Assuming that K(m,n) has vertices at (i,0) and (j,1), for i=0..m-1 and j=0..n-1, the projective map (x,y) -> ((1-y)/(x+1), y/(x+1)) maps K(m,n) to the partition of the right triangle described by Alekseyev et al. (2015), for which Theorem 13 gives the number of regions, line segments, and intersection points. (End)
Max Alekseyev's formula is an analog of Proposition 9 of Legendre (2009), and gives an explicit formula for this array. - N. J. A. Sloane, Jun 30 2020

A335683 Array read by antidiagonals: T(n,k) (n >= 1, k >= 1) = Sum_{i=1..n, j=1..k, gcd(i,j)=2} (n+1-i)*(k+1-j).

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 2, 2, 0, 0, 4, 4, 4, 0, 0, 6, 8, 8, 6, 0, 0, 9, 12, 15, 12, 9, 0, 0, 12, 18, 22, 22, 18, 12, 0, 0, 16, 24, 33, 32, 33, 24, 16, 0, 0, 20, 32, 44, 48, 48, 44, 32, 20, 0, 0, 25, 40, 58, 64, 71, 64, 58, 40, 25, 0, 0, 30, 50, 72, 84, 94, 94, 84, 72, 50, 30, 0
Offset: 1

Views

Author

N. J. A. Sloane, Jul 02 2020

Keywords

Examples

			The array begins:
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
0, 1, 2, 4, 6, 9, 12, 16, 20, 25, 30, 36, ...
0, 2, 4, 8, 12, 18, 24, 32, 40, 50, 60, 72, ...
0, 4, 8, 15, 22, 33, 44, 58, 72, 90, 108, 129, ...
0, 6, 12, 22, 32, 48, 64, 84, 104, 130, 156, 186, ...
0, 9, 18, 33, 48, 71, 94, 123, 152, 190, 228, 271, ...
0, 12, 24, 44, 64, 94, 124, 162, 200, 250, 300, 356, ...
0, 16, 32, 58, 84, 123, 162, 211, 260, 325, 390, 462, ...
0, 20, 40, 72, 104, 152, 200, 260, 320, 400, 480, 568, ...
0, 25, 50, 90, 130, 190, 250, 325, 400, 499, 598, 707, ...
0, 30, 60, 108, 156, 228, 300, 390, 480, 598, 716, 846, ...
0, 36, 72, 129, 186, 271, 356, 462, 568, 707, 846, 999, ...
...
The initial antidiagonals are:
[0]
[0, 0]
[0, 1, 0]
[0, 2, 2, 0]
[0, 4, 4, 4, 0]
[0, 6, 8, 8, 6, 0]
[0, 9, 12, 15, 12, 9, 0]
[0, 12, 18, 22, 22, 18, 12, 0]
[0, 16, 24, 33, 32, 33, 24, 16, 0]
[0, 20, 32, 44, 48, 48, 44, 32, 20, 0]
[0, 25, 40, 58, 64, 71, 64, 58, 40, 25, 0]
[0, 30, 50, 72, 84, 94, 94, 84, 72, 50, 30, 0]
...
		

Crossrefs

A331762 is the same array displayed as a triangle.
Showing 1-4 of 4 results.