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.

Previous Showing 11-12 of 12 results.

A081474 Number of distinct lines through the origin in n-dimensional cube of side length n.

Original entry on oeis.org

0, 1, 5, 49, 529, 7471, 112825, 2078455, 42649281, 997784221, 25875851825, 742641202183, 23283999690561, 793616663524231, 29188521870580929, 1152885848976064513, 48659336030073207425, 2185894865613157551481, 104126348669497256201905, 5242869988601103651841105
Offset: 0

Views

Author

Joshua Zucker, Nov 25 2003

Keywords

Comments

Equivalently, lattice points where the GCD of all coordinates = 1.

Examples

			a(3) = 49 because in the 3-dimensional lattice of side length 3, the lines through the origin are determined by all 37 points with at least one coordinate = 3 and 6 permutations of (2,1,0) and 3 permutations each of (2,1,1) and (2,2,1).
		

Crossrefs

Cf. A000225, A001047, A060867, A090020, A090021, A090022, A090023, A090024 are for n dimensions with side length 1, 2, 3, 4, 5, 6, 7, 8, respectively. A049691, A090025, A090026, A090027, A090028, A090029 are this sequence for 2, 3, 4, 5, 6, 7 dimensions. A090030 is the table for n dimensions, side length k.

Programs

  • Maple
    a:= n-> add(numtheory[mobius](i)*((floor(n/i)+1)^n-1), i=1..n):
    seq(a(n), n=0..20);  # Alois P. Heinz, Mar 09 2022
  • Mathematica
    aux[n_, k_] := If[k == 0, 0, (k + 1)^n - k^n - Sum[aux[n, Divisors[k][[i]]], {i, 1, Length[Divisors[k]] - 1}]];lines[n_, k_] := (k + 1)^n - Sum[Floor[k/i - 1]*aux[n, i], {i, 1, Floor[k/2]}] - 1;Table[lines[k, k], {k, 0, 20}]

Formula

a(n) = A090030(n,n).

A090225 T(n,k) = Points in n-dimensional lattice of side length k with at least one coordinate = k and GCD of all coordinates = 1.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 0, 3, 0, 0, 0, 2, 7, 0, 0, 0, 4, 12, 15, 0, 0, 0, 4, 30, 50, 31, 0, 0, 0, 8, 42, 160, 180, 63, 0, 0, 0, 4, 84, 304, 750, 602, 127, 0, 0, 0, 12, 78, 656, 1890, 3304, 1932, 255, 0, 0, 0, 8, 162, 880, 4620, 10864, 14070, 6050, 511, 0, 0, 0, 12, 156, 1680, 8070
Offset: 0

Views

Author

Joshua Zucker, Nov 24 2003

Keywords

Examples

			T(3,2) = 12 because of the six permutations of (2,1,0) and three each of (2,1,1) and (2,2,1).
0;
0,  0;
0,  1,  0;
0,  0,  3,  0;
0,  0,  2,  7,  0;
0,  0,  4, 12, 15, 0;
0,  0,  4, 30, 50, 31,  0;
0,  0,  8, 42,160,180, 63, 0;
0,  0,  4, 84,304,750,602,127, 0;
0,  0, 12, 78,656,1890,3304,1932,255, 0;
		

Crossrefs

Cf. A090030.

Programs

  • Mathematica
    aux[n_, k_] := If[k == 0, 0, (k + 1)^n - k^n - Sum[aux[n, Divisors[k][[i]]], {i, 1, Length[Divisors[k]] - 1}]]

Formula

T(n, 0) = 0; T(n, k) = (k+1)^n - k^n - sum T(n, divisors of k)
Previous Showing 11-12 of 12 results.