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 51-60 of 126 results. Next

A070091 Number of isosceles integer triangles with perimeter n and relatively prime side lengths.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, May 05 2002

Keywords

Comments

a(n) = A051493(n) - A005044(n-6).

Examples

			For n=15 there are A005044(15)=7 integer triangles: [1,7,7], [2,6,7], [3,5,7], [3,6,6], [4,4,7], [4,5,6] and [5,5,5]: four are isosceles: [1<7=7], [3<6=6], [4=4<7] and [5=5=5], but GCD(3,6,6)>1 and GCD(5,5,5)>1, therefore a(15)=2.
		

Crossrefs

Programs

  • Mathematica
    m = 81 (* max perimeter *);
    sides[per_] := Select[Reverse /@ IntegerPartitions[per, {3}, Range[ Ceiling[per/2]]], #[[1]] < per/2 && #[[2]] < per/2 && #[[3]] < per/2 &];
    triangles = DeleteCases[Table[sides[per], {per, 3, m}], {}] // Flatten[#, 1] & // SortBy[Total[#] m^3 + #[[1]] m^2 + #[[2]] m + #[[1]] &] ;
    a[n_] := Count[triangles, t_ /; Total[t] == n && Length[Union[t]] < 3 && GCD @@ t == 1];
    Table[a[n], {n, 1, m}] (* Jean-François Alcover, Oct 05 2021 *)

A070095 Number of acute integer triangles with perimeter n and prime side lengths.

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 2, 0, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 2, 0, 2, 0, 2, 0, 1, 1, 2, 0, 2, 1, 3, 0, 2, 0, 2, 0, 2, 1, 3, 0, 3, 0, 2, 0, 2, 0, 3, 0, 2, 1, 2, 0, 2, 1, 3, 0, 1, 0, 3, 0, 3, 0, 2, 0, 3, 1, 4, 0, 3, 0, 3, 0, 1, 1, 3, 0, 3, 1, 4, 0
Offset: 1

Views

Author

Reinhard Zumkeller, May 05 2002

Keywords

Examples

			For n=17 there are A005044(17)=8 integer triangles: [1,8,8], [2,7,8], [3,6,8], [3,7,7], [4,5,8], [4,6,7], [5,5,7] and [5,6,6]: the two consisting of primes ([3,7,7] and [5,5,7]) are also acute, therefore a(17)=2.
		

Crossrefs

Programs

  • Mathematica
    Table[Sum[Sum[(PrimePi[i] - PrimePi[i - 1]) (PrimePi[k] - PrimePi[k - 1]) (PrimePi[n - i - k] - PrimePi[n - i - k - 1]) (1 - Sign[Floor[(n - i - k)^2/(i^2 + k^2)]]) Sign[Floor[(i + k)/(n - i - k + 1)]], {i, k, Floor[(n - k)/2]}], {k, Floor[n/3]}], {n, 100}] (* Wesley Ivan Hurt, May 13 2019 *)

Formula

a(n) = A070088(n) - A070103(n).
a(n) = Sum_{k=1..floor(n/3)} Sum_{i=k..floor((n-k)/2)} (1 - sign(floor((n-i-k)^2/(i^2+k^2)))) * sign(floor((i+k)/(n-i-k+1))) * A010051(i) * A010051(k) * A010051(n-i-k). - Wesley Ivan Hurt, May 13 2019

A070105 Number of integer triangles with perimeter n and prime side lengths which are obtuse and scalene.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, May 05 2002

Keywords

Comments

a(n) = 0 if n is even. - Robert Israel, Jul 26 2024

Crossrefs

Programs

  • Maple
    f:= proc(n) local a,b,q,bmin,bmax,t;
      t:= 0;
      if n::even then return 0 fi;
      for a from 1 to n/3 by 2 do
        if not isprime(a) then next fi;
        bmin:= max(a+1,(n+1)/2-a); if bmin::even then bmin:= bmin+1 fi;
        q:= (n^2-2*n*a)/(2*(n-a));
        if q::integer then bmax:= min((n-a)/2, q-1) else bmax:= min((n-a)/2, floor(q)) fi;
        t:= t + nops(select(b -> isprime(b) and isprime(n-a-b), [seq(b,b=bmin .. bmax,2)]))
      od;
      t
    end proc:
    map(f, [$1..100]); # Robert Israel, Jul 26 2024

A070106 Number of integer triangles with perimeter n which are obtuse and isosceles.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 3, 2, 2, 3, 3, 2, 3, 3, 3, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 3, 3, 4, 4, 3, 3, 4, 4, 3, 4, 4
Offset: 1

Views

Author

Reinhard Zumkeller, May 05 2002

Keywords

Comments

a(n)=A070101(n)-A024156(n); a(n)=A059169(n)-A070098(n).

Examples

			For n=11 there are A005044(11)=4 integer triangles: [1,5,5], [2,4,5], [3,3,5] and [3,4,4]; only one of the two obtuses ([2,4,5] and [3,3,5]) is also isosceles; therefore a(11)=1.
		

Crossrefs

A070108 Number of integer triangles with perimeter n and prime side lengths which are obtuse and isosceles.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, May 05 2002

Keywords

Examples

			a(k)<=1 until k = 140, for k = 141 there are A005044(141)=432 integer triangles, a(141)=2 as
[37=37<67]: 37+37+67 = 141 and 2*(37^2)<67^2 and 37, 67 are primes,
[41=41<59]: 41+41+59 = 141 and 2*(41^2)<59^2 and 41, 59 are primes.
		

Crossrefs

A107576 a(n)=perimeter of n-th triangle listed at A107572.

Original entry on oeis.org

9, 11, 12, 13, 13, 14, 15, 15, 15, 16, 16, 17, 17, 17, 17, 18, 18, 18, 19, 19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22, 22, 23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 25, 25, 25, 25, 25, 25, 25, 25, 25, 25, 26, 26, 26, 26, 26, 26
Offset: 1

Views

Author

Clark Kimberling, May 16 2005

Keywords

Comments

The number of perimeters equal to n+6 is A005044(n).

Examples

			The first 5 integer-sided scalene triangles (a,b,c) with a<b<c are (2,3,4), (2,4,5), (3,4,5), (2,5,6), (3,4,6), of which the perimeters are 9,11,12,13,13.
		

Crossrefs

A334717 Largest possible short leg length of a Pythagorean triangle with perimeter A010814(n).

Original entry on oeis.org

3, 6, 5, 9, 8, 12, 7, 15, 20, 18, 16, 21, 15, 24, 27, 14, 30, 28, 33, 40, 36, 25, 33, 39, 32, 42, 48, 45, 13, 48, 36, 40, 51, 39, 60, 54, 20, 28, 57, 65, 60, 63, 60, 66, 45, 69, 80, 44, 72, 75, 17, 66, 78, 64, 81, 88, 84, 51, 87, 100, 96, 90, 26, 93, 85, 84, 19, 96, 65, 49, 99
Offset: 1

Views

Author

Wesley Ivan Hurt, May 08 2020

Keywords

Examples

			a(1) = 3; There is one integer-sided right triangle with perimeter A010814(1) = 12, [3,4,5] with short leg length 3.
a(2) = 6; There is one integer-sided right triangle with perimeter A010814(2) = 24, [6,8,10] with short leg length 6.
		

Crossrefs

A336757 Number of primitive integer-sided triangles whose sides a < b < c are in arithmetic progression with a perimeter = n.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 2, 0, 0, 1, 0, 0, 3, 0, 0, 2, 0, 0, 3, 0, 0, 2, 0, 0, 5, 0, 0, 2, 0, 0, 6, 0, 0, 3, 0, 0, 4, 0, 0, 4, 0, 0, 8, 0, 0, 3, 0, 0, 4, 0, 0, 4, 0, 0, 6, 0, 0, 5, 0, 0, 11, 0, 0, 4
Offset: 1

Views

Author

Bernard Schott, Sep 20 2020

Keywords

Comments

Equivalently: number of primitive integer-sided triangles such that b = (a+c)/2 with a < c and perimeter = n.
As the perimeter of these triangles = 3*b where b is the middle side, a(n) >= 1 iff n = 3*b, with b >= 3.
When b is prime, all the triangles of perimeter n = 3*b are primitive, hence in this case: a(n) = A024164(n).
For the corresponding triples (primitive or not), miscellaneous properties and references, see A336750.

Examples

			a(9) = 1 for the smallest such triangle (2, 3, 4).
a(12) = 1 for the Pythagorean triple (3, 4, 5).
a(15) = 2 for the two triples (3, 5, 7) and (4, 5, 6).
a(18) = 1 for the triple (5, 6, 7); the other triple (4, 6, 8) corresponding to a perimeter = 18 is not a primitive triple.
		

Crossrefs

Cf. A336750 (triples, primitive or not), A336755 (primitive triples), A336756 (perimeters of primitive triangles).
Cf. A024164 (number of such triangles, primitive or not).
Similar sequences: A005044 (integer-sided triangles), A024155 (right triangles), A070201 (with integral inradius).

Formula

For n = 3*b, b >= 3, a(n) = A023022(b) = A000010(b)/2, otherwise a(n) = 0.

A008742 Molien series for 3-dimensional group [3,3 ]+ = 332.

Original entry on oeis.org

1, 0, 1, 1, 2, 1, 4, 2, 5, 4, 7, 5, 10, 7, 12, 10, 15, 12, 19, 15, 22, 19, 26, 22, 31, 26, 35, 31, 40, 35, 46, 40, 51, 46, 57, 51, 64, 57, 70, 64, 77, 70, 85, 77, 92, 85, 100, 92, 109, 100, 117, 109, 126, 117, 136
Offset: 0

Views

Author

Keywords

Comments

a(n) is also the number of integer-sided triangles having perimeter n + 3, modulo rotations but not reflections. - James East, Oct 16 2017

Examples

			For n = 6, there are 4 rotation-classes of perimeter-9 triangles: 441, 432, 423, 333. Note that 432 and 423 are reflections of each other, but these are not rotationally equivalent. So a(6) = 4. - _James East_, Oct 16 2017
		

Crossrefs

Cf. A005044, A293819 (k-gon triangle), A293820 (polygons), A293821 (quadrilaterals), A293822 (pentagons), A293823 (hexagons)

Programs

  • GAP
    a:=[1,0,1,1,2,1,4];; for n in [8..60] do a[n]:=2*a[n-2]+a[n-3]-a[n-4] -2*a[n-5]+a[n-7]; od; a; # G. C. Greubel, Aug 03 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 60); Coefficients(R!( (1+x^6)/((1-x^2)*(1-x^3)*(1-x^4)) )); // G. C. Greubel, Aug 03 2019
    
  • Mathematica
    CoefficientList[Series[(1+x^6)/((1-x^2)*(1-x^3)*(1-x^4)), {x, 0, 60}], x] (* Vaclav Kotesovec, Apr 29 2014 *)
  • PARI
    my(x='x+O('x^60)); Vec((1+x^6)/((1-x^2)*(1-x^3)*(1-x^4))) \\ G. C. Greubel, Aug 03 2019
    
  • Sage
    ((1+x^6)/((1-x^2)*(1-x^3)*(1-x^4))).series(x, 60).coefficients(x, sparse=False) # G. C. Greubel, Aug 03 2019
    

Formula

G.f.: (1+x^6)/((1-x^2)*(1-x^3)*(1-x^4)).
a(n) ~ 1/24*n^2. - Ralf Stephan, Apr 29 2014
a(n) = 1 - 19*n/24 - 5*n^2/24 + 4/3*floor(n/3) + (n/2+3/4)*floor(n/2) + 2/3*floor((n+1)/3). - Vaclav Kotesovec, Apr 29 2014
a(n) = floor((n^2+3*n+20)/24+(2*n+3)*(-1)^n/16). - Tani Akinari, Jun 20 2014
G.f.: (1-x^2+x^4)/((1+x+x^2)*(1+x)^2*(1-x)^3). - R. J. Mathar, Dec 18 2014

A070097 Number of integer triangles with perimeter n and prime side lengths which are both acute and scalene.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, May 05 2002

Keywords

Crossrefs

Previous Showing 51-60 of 126 results. Next