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

A100450 Number of ordered triples (i,j,k) with |i| + |j| + |k| <= n and gcd(i,j,k) <= 1.

Original entry on oeis.org

1, 7, 19, 51, 99, 195, 291, 483, 675, 963, 1251, 1731, 2115, 2787, 3363, 4131, 4899, 6051, 6915, 8355, 9507, 11043, 12483, 14595, 16131, 18531, 20547, 23139, 25443, 28803, 31107, 34947, 38019, 41859, 45315, 49923, 53379, 58851, 63171, 68547
Offset: 0

Views

Author

N. J. A. Sloane, Nov 21 2004

Keywords

Comments

Note that gcd(0,m) = m for any m.
I would also like to get the sequences of the numbers of distinct sums i+j+k (also distinct products i*j*k) over all ordered triples (i,j,k) with |i| + |j| + |k| <= n; also over all ordered triples (i,j,k) with |i| + |j| + |k| <= n and gcd(i,j,k) <= 1.
Also the sequences of the numbers of distinct sums i+j+k (also distinct products i*j*k) over all ordered triples (i,j,k) with i >= 0, j >= 0, k >= 0 and i + j + k = n; also over all ordered triples (i,j,k) with i >= 0, j >= 0, k >= 0, i + j + k = n and gcd(i,j,k) <= 1.
Also the number of ordered triples (i,j,k) with i >= 0, j >= 0, k >= 0, i + j + k = n and gcd(i,j,k) <= 1.
From Robert Price, Mar 05 2013: (Start)
The sequences that address the previous comments are:
Distinct sums i+j+k with or without the GCD qualifier results in a(n)=2n+1 (A005408).
Distinct products i*j*k without the GCD qualifier is given by A213207.
Distinct products i*j*k with the GCD qualifier is given by A213208.
With the restriction i,j,k >= 0 ...
Distinct sums or products equal to n is trivial and always equals one (A000012).
Distinct sums <= n results in a(n)=n (A001477).
Distinct products <= n without the GCD qualifier is given by A213213.
Distinct products <= n with the GCD qualifier is given by A213212.
Ordered triples with sum = n without the GCD qualifier is A000217(n+1).
Ordered triples with sum = n with the GCD qualifier is A048240.
Ordered triples with sum <= n without the GCD qualifier is A000292.
Ordered triples with sum <= n with the GCD qualifier is A048241. (End)
This sequence (A100450) without the GCD qualifier results in A001845. - Robert Price, Jun 04 2013

Crossrefs

Programs

  • Maple
    f:=proc(n) local i,j,k,t1,t2,t3; t1:=0; for i from -n to n do for j from -n to n do t2:=gcd(i,j); for k from -n to n do if abs(i) + abs(j) + abs(k) <= n then t3:=gcd(t2,k); if t3 <= 1 then t1:=t1+1; fi; fi; od: od: od: t1; end;
  • Mathematica
    f[n_] := Length[ Union[ Flatten[ Table[ If[ Abs[i] + Abs[j] + Abs[k] <= n && GCD[i, j, k] <= 1, {i, j, k}, {0, 0, 0}], {i, -n, n}, {j, -n, n}, {k, -n, n}], 2]]]; Table[ f[n], {n, 0, 40}] (* Robert G. Wilson v, Dec 14 2004 *)

Formula

G.f.: (3 + Sum_{k>=1} (moebius(k)*((1+x^k)/(1-x^k))^3))/(1-x). - Vladeta Jovovic, Nov 22 2004. [Sketch of proof: Let b(n) = number of ordered triples (i, j, k) with |i| + |j| + |k| = n and gcd(i, j, k) <= 1. Then a(n) = A100450(n) = partial sums of b(n) and Sum_{d divides n} b(d) = 4*n^2+2 = A005899(n) with g.f. ((1+x)/(1-x))^3.]

A213208 Number of distinct products i*j*k over all triples (i,j,k) with |i| + |j| + |k| <= n and gcd(i,j,k) <= 1.

Original entry on oeis.org

1, 1, 1, 3, 5, 9, 11, 19, 23, 33, 39, 51, 57, 75, 87, 103, 117, 143, 155, 187, 207, 235, 259, 297, 319, 363, 395, 441, 473, 525, 555, 615, 659, 721, 765, 831, 875, 959, 1017, 1091, 1147, 1239, 1291, 1397, 1467, 1553, 1631, 1743, 1813, 1937, 2023, 2141, 2233, 2379, 2465
Offset: 0

Views

Author

Robert Price, Mar 01 2013

Keywords

Comments

This sequence is in reply to an extension request made in A100450.
Note that gcd(0,m) = m for any m.

Crossrefs

Programs

  • Maple
    h:= proc() true end:
    b:= proc(n) local c, i, j, p;
          c:=0;
          for i to iquo(n, 3) do
            for j from i to iquo(n-i, 2) do
              if igcd(i, j, n-i-j)=1 then p:= i*j*(n-i-j);
                if h(p) then h(p):= false; c:=c+1 fi
              fi
            od
          od; c
        end:
    a:= proc(n) a(n):= `if`(n=0, 1, a(n-1) +2*b(n)) end:
    seq(a(n), n=0..60);  # Alois P. Heinz, Mar 01 2013
  • Mathematica
    f[n_] := Length[ Union[ Flatten[ Table[ If[ Abs[i] + Abs[j] + Abs[k] <= n&& GCD[i, j, k] <= 1, i*j*k, 0], {i, -n, n}, {j, -n, n}, {k, -n, n}], 2]]]; Table[ f[n], {n, 0, 100}]

A213212 Number of distinct products i*j*k over all triples (i,j,k) with i,j,k >= 0 and i+j+k <= n and gcd(i,j,k) <= 1.

Original entry on oeis.org

1, 1, 1, 2, 3, 5, 6, 10, 12, 17, 20, 26, 29, 38, 44, 52, 59, 72, 78, 94, 104, 118, 130, 149, 160, 182, 198, 221, 237, 263, 278, 308, 330, 361, 383, 416, 438, 480, 509, 546, 574, 620, 646, 699, 734, 777, 816, 872, 907, 969, 1012, 1071, 1117, 1190, 1233, 1307, 1361
Offset: 0

Views

Author

Robert Price, Mar 02 2013

Keywords

Comments

This sequence is in reply to an extension request made in A100450.
Note that gcd(0,m) = m for any m.

Crossrefs

Programs

  • Maple
    h:= proc() true end:
    b:= proc(n) local c, i, j, p;
          c:=0;
          for i to iquo(n, 3) do
            for j from i to iquo(n-i, 2) do
              if igcd(i, j, n-i-j)=1 then p:= i*j*(n-i-j);
                if h(p) then h(p):= false; c:=c+1 fi
              fi
            od
          od; c
        end:
    a:= proc(n) a(n):= `if`(n=0, 1, a(n-1) +b(n)) end:
    seq(a(n), n=0..60);  # Alois P. Heinz, Mar 02 2013
  • Mathematica
    f[n_] := Length[ Union[ Flatten[ Table[ If[ i+j+k <= n&& GCD[i, j, k] <= 1, i*j*k, 0], {i, 0, n}, {j, 0, n}, {k, 0, n}], 2]]]; Table[ f[n], {n, 0, 200}]

Formula

a(n) = (A213208(n) + 1)/2.

A213213 Number of distinct products i*j*k over all triples (i,j,k) with i,j,k>=0 and i+j+k <= n.

Original entry on oeis.org

1, 1, 1, 2, 3, 5, 7, 10, 13, 18, 22, 28, 33, 40, 46, 56, 64, 75, 84, 97, 109, 125, 137, 156, 170, 192, 210, 232, 251, 276, 296, 322, 347, 376, 400, 435, 463, 498, 529, 567, 600, 641, 674, 720, 758, 808, 849, 901, 942, 1001, 1051, 1110, 1157, 1225, 1275
Offset: 0

Views

Author

Robert Price, Mar 02 2013

Keywords

Comments

This sequence is in reply to an extension request made in A100450.

Crossrefs

Programs

  • Maple
    h:= proc() true end:
    b:= proc(n) local c, i, j, p;
          c:=0;
          for i to iquo(n, 3) do
            for j from i to iquo(n-i, 2) do p:= i*j*(n-i-j);
              if h(p) then h(p):= false; c:=c+1 fi
            od
          od; c
        end:
    a:= proc(n) a(n):= `if`(n=0, 1, a(n-1) +b(n)) end:
    seq(a(n), n=0..60);  # Alois P. Heinz, Mar 02 2013
  • Mathematica
    f[n_] := Length[ Union[ Flatten[ Table[ If[ i+j+k <= n, i*j*k, 0], {i, 0, n}, {j, 0, n}, {k, 0, n}], 2]]]; Table[ f[n], {n, 0, 200}]

Formula

a(n) = (A213207(n)+1)/2.

A225531 Number of ordered pairs (i, j) with i, j >= 0, i + j <= n and gcd(i, j) <= 1.

Original entry on oeis.org

1, 3, 4, 6, 8, 12, 14, 20, 24, 30, 34, 44, 48, 60, 66, 74, 82, 98, 104, 122, 130, 142, 152, 174, 182, 202, 214, 232, 244, 272, 280, 310, 326, 346, 362, 386, 398, 434, 452, 476, 492, 532, 544, 586, 606, 630, 652, 698, 714, 756, 776
Offset: 0

Views

Author

Robert Price, May 09 2013

Keywords

Comments

This sequence is in reply to an extension request made in A100449.
Note that gcd(0,m) = m for any m.

Crossrefs

Programs

  • Mathematica
    f[n_] := Length[Complement[Union[Flatten[Table[If[i + j <= n && GCD[i, j] <= 1, {i, j}], {i, 0, n}, {j, 0, n}], 1]], {Null}]]; Table[f[n], {n, 0, 100}]
  • PARI
    alist(N) = my(c=2); vector(N, i, if(1==i, 1, c+=eulerphi(i-1))); \\ Ruud H.G. van Tol, Jul 09 2024

A225530 Number of ordered pairs (i,j) with i,j >= 0, i + j = n and gcd(i,j) <= 1.

Original entry on oeis.org

1, 2, 1, 2, 2, 4, 2, 6, 4, 6, 4, 10, 4, 12, 6, 8, 8, 16, 6, 18, 8, 12, 10, 22, 8, 20, 12, 18, 12, 28, 8, 30, 16, 20, 16, 24, 12, 36, 18, 24, 16, 40, 12, 42, 20, 24, 22, 46, 16, 42, 20, 32, 24, 52, 18, 40, 24, 36, 28, 58, 16, 60, 30, 36, 32, 48, 20, 66
Offset: 0

Views

Author

Robert Price, May 09 2013

Keywords

Comments

This sequence is in reply to an extension request made in A100449.
Note that gcd(0,m) = m for any m.
Apparently a(n) = A000010(n), n >= 2. - R. J. Mathar, May 11 2013

Crossrefs

Programs

  • Mathematica
    f[n_]:=Length[Complement[Union[Flatten[Table[If[i+j==n&&GCD[i, j]<=1, {i,j}], {i, 0, n}, {j, 0, n}], 1]], {Null}]]; Table[f[n], {n, 0, 100}]

A225523 Number of distinct products i*j over all pairs (i,j) with |i| + |j| <= n.

Original entry on oeis.org

1, 1, 3, 5, 9, 11, 17, 21, 27, 33, 39, 43, 53, 59, 69, 79, 89, 97, 107, 117, 131, 143, 157, 167, 183, 195, 209, 223, 237, 249, 269, 283, 301, 317, 335, 353, 373, 389, 409, 427, 449, 465, 491, 509, 535, 557, 581, 603, 631, 657, 679
Offset: 0

Views

Author

Robert Price, May 09 2013

Keywords

Comments

This sequence is in reply to an extension request made in A100449.

Crossrefs

Programs

  • Mathematica
    f[n_]:=Length[Complement[Union[Flatten[Table[If[Abs[i]+Abs[j]<=n,{i*j}],{i,-n,n},{j,-n,n}],1]],{Null}]]; Table[f[n],{n,0,100}]

A225527 Number of distinct products i*j over all pairs (i,j) with i,j>=0 and i+j <= n.

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 9, 11, 14, 17, 20, 22, 27, 30, 35, 40, 45, 49, 54, 59, 66, 72, 79, 84, 92, 98, 105, 112, 119, 125, 135, 142, 151, 159, 168, 177, 187, 195, 205, 214, 225, 233, 246, 255, 268, 279, 291, 302, 316, 329, 340, 352, 367, 377, 392
Offset: 0

Views

Author

Robert Price, May 09 2013

Keywords

Comments

This sequence is in reply to an extension request made in A100449.

Crossrefs

Programs

  • Mathematica
    f[n_]:=Length[Complement[Union[Flatten[Table[If[i+j≤n,{i*j}],{i,0,n},{j,0,n}],1]],{Null}]]; Table[f[n],{n,0,100}]

A225529 Number of distinct products i*j over all pairs (i,j) with i,j >= 0 and i+j <= n and gcd(i,j) <= 1.

Original entry on oeis.org

1, 1, 2, 3, 4, 6, 7, 9, 11, 14, 16, 20, 22, 26, 29, 32, 35, 41, 44, 50, 54, 59, 63, 70, 74, 80, 85, 92, 98, 108, 112, 121, 129, 137, 144, 153, 158, 170, 177, 186, 192, 204, 210, 222, 231, 240, 249, 262, 270, 284, 293, 305, 315, 331, 340, 353
Offset: 0

Views

Author

Robert Price, May 09 2013

Keywords

Comments

Note that gcd(0,m) = m for any m.

Crossrefs

Programs

  • Mathematica
    f[n_]:=Length[Complement[Union[Flatten[Table[If[i+j≤n&&GCD[i,j]<=1, {i*j}], {i, 0, n}, {j, 0, n}], 1]], {Null}]]; Table[f[n], {n, 0, 100}]
Showing 1-9 of 9 results.