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

A259053 Number of triangles with sides pairwise relatively prime and one maximal side being n; permutations of sides are not considered distinct.

Original entry on oeis.org

1, 0, 0, 0, 1, 0, 3, 2, 4, 1, 11, 2, 17, 6, 8, 9, 32, 6, 42, 12, 22, 15, 64, 12, 56, 25, 49, 25, 107, 12, 124, 51, 64, 45, 86, 27, 180, 59, 91, 45, 225, 30, 250, 81, 96, 87, 302, 55, 263, 82
Offset: 1

Views

Author

Vincent J. Matsko, Jun 29 2015

Keywords

Crossrefs

First differences of A259446.

Programs

  • Mathematica
    triangles[n_] := Module[{count = 0},
       For[a = 1, a <= n, a++,
        For[b = a, b <= n, b++,
         If[(a + b > n) && CoprimeQ[a, b, n], count++]]];
       count];
    triangles[#] & /@ Range[50]
  • PARI
    a(n)=if(n==1, return(1)); sum(a=3,n-2, if(gcd(a,n)==1, my(an=a*n); sum(b=max(a+1,n-a+1), n-1, gcd(an, b)==1))) \\ Charles R Greathouse IV, Jun 29 2015
Showing 1-1 of 1 results.