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-10 of 12 results. Next

A007970 Rhombic numbers.

Original entry on oeis.org

3, 7, 8, 11, 15, 19, 23, 24, 27, 31, 32, 35, 40, 43, 47, 48, 51, 59, 63, 67, 71, 75, 79, 80, 83, 87, 88, 91, 96, 99, 103, 104, 107, 115, 119, 120, 123, 127, 128, 131, 135, 136, 139, 143, 151, 152, 159, 160, 163, 167, 168, 171, 175, 176, 179
Offset: 1

Views

Author

Keywords

Comments

A191856(n) = A007966(a(n)); A191857(n) = A007967(a(n)). - Reinhard Zumkeller, Jun 18 2011
This sequence gives the values d of the Pell equation x^2 - d*y^2 = +1 that have positive fundamental solutions (x0, y0) with odd y0. This was first conjectured and is proved provided Conway's theorem in the link is assumed and the proof of the conjecture stated in A007869, given there in a W. Lang link, is used. - Wolfdieter Lang, Sep 19 2015
For a proof of Conway's theorem on the happy number factorization see the W. Lang link (together with the link given under A007969). - Wolfdieter Lang, Oct 04 2015

Crossrefs

Every number belongs to exactly one of A000290, A007969, A007970.
Cf. A007968.
Subsequence of A000037, A002145 is a subsequence.
A263008 (T numbers), A263009 (U numbers).

Programs

  • Haskell
    a007970 n = a007970_list !! (n-1)
    a007970_list = filter ((== 2) . a007968) [0..]
    -- Reinhard Zumkeller, Oct 11 2015
  • Mathematica
    r[b_, c_] := (red = Reduce[x > 0 && y > 0 && b*x^2 + 2 == c*y^2, {x, y}, Integers] /. C[1] -> 1 // Simplify; If[Head[red] === Or, First[red], red]);
    f[n_] := f[n] = If[! IntegerQ[Sqrt[n]], Catch[Do[{b, c} = bc; If[ (r0 = r[b, c]) =!= False, {x0, y0} = {x, y} /. ToRules[r0]; If[OddQ[x0] && OddQ[y0], Throw[n]]]; If[ (r0 = r[c, b]) =!= False, {x0, y0} = {x, y} /. ToRules[r0]; If[OddQ[x0] && OddQ[y0], Throw[n]]], {bc, Union[Sort[{#, n/#}] & /@ Divisors[n]]} ]]];
    A007970 = Reap[ Table[ If[f[n] =!= Null, Print[f[n]]; Sow[f[n]]], {n, 1, 180}] ][[2, 1]](* Jean-François Alcover, Jun 26 2012 *)

Formula

a(n) = A191856(n)*A191857(n); A007968(a(n))=2. - Reinhard Zumkeller, Jun 18 2011
a(n) is in the sequence if a(n) = D*E with positive integers D and E, such that E*U^2 - D*T^2 = 2 has an integer solution with U*T odd (without loss of generality one may take U and T positive). See the Conway link. D and E are given in A191856 and A191857, respectively. - Wolfdieter Lang, Oct 05 2015

Extensions

159 and 175 inserted by Jean-François Alcover, Jun 26 2012

A000171 Number of self-complementary graphs with n nodes.

Original entry on oeis.org

1, 0, 0, 1, 2, 0, 0, 10, 36, 0, 0, 720, 5600, 0, 0, 703760, 11220000, 0, 0, 9168331776, 293293716992, 0, 0, 1601371799340544, 102484848265030656, 0, 0, 3837878966366932639744, 491247277315343649710080, 0, 0
Offset: 1

Views

Author

Keywords

Comments

a(n) = A007869(n)-A054960(n), where A007869(n) is number of unlabeled graphs with n nodes and an even number of edges and A054960(n) is number of unlabeled graphs with n nodes and an odd number of edges.

References

  • F. Harary and E. M. Palmer, Graphical Enumeration, Academic Press, NY, 1973, p. 139, Table 6.1.1.
  • R. C. Read and R. J. Wilson, An Atlas of Graphs, Oxford, 1998.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A008406 (triangle of coefficients of the "graph polynomial").

Programs

  • Mathematica
    < -1, {n, 1, 20}]  (* Geoffrey Critzer, Oct 21 2012 *)
    permcount[v_] := Module[{m = 1, s = 0, k = 0, t}, For[i = 1, i <= Length[v], i++, t = v[[i]]; k = If[i > 1 && t == v[[i - 1]], k + 1, 1]; m *= t*k; s += t]; s!/m];
    edges[v_] := 4 Sum[Sum[GCD[v[[i]], v[[j]]], {j, 1, i - 1}], {i, 2, Length[v]}] + 2 Total[v];
    a[n_] := Module[{s = 0}, Switch[Mod[n, 4], 2|3, 0, _, Do[s += permcount[4 p]*2^edges[p]*If[OddQ[n], n*2^Length[p], 1], {p, IntegerPartitions[ Quotient[n, 4]]}]; s/n!]];
    Array[a, 40] (* Jean-François Alcover, Aug 26 2019, after Andrew Howroyd *)
  • PARI
    permcount(v) = {my(m=1,s=0,k=0,t); for(i=1,#v,t=v[i]; k=if(i>1&&t==v[i-1],k+1,1); m*=t*k;s+=t); s!/m}
    edges(v) = {4*sum(i=2, #v, sum(j=1, i-1, gcd(v[i],v[j]))) + 2*sum(i=1, #v, v[i])}
    a(n) = {my(s=0); if(n%4<2, forpart(p=n\4, s+=permcount(4*Vec(p)) * 2^edges(p) * if(n%2, n*2^#p, 1))); s/n!} \\ Andrew Howroyd, Sep 16 2018

Formula

a(4n) = A003086(2n).
a(4*n+1) = A047832(n), a(4*n+2) = a(4*n+3) = 0. - Andrew Howroyd, Sep 16 2018

Extensions

More terms from Ronald C. Read and Vladeta Jovovic

A054960 Number of unlabeled graphs with n nodes and an odd number of edges.

Original entry on oeis.org

0, 1, 2, 5, 16, 78, 522, 6168, 137316, 6002584, 509498932, 82545585936, 25251015681176, 14527077828617744, 15713242984902154384, 32000507852263778595584, 122967932076766466336249888, 893788862572805850273939095424, 12318904626562502262191503745716384
Offset: 1

Views

Author

N. J. A. Sloane, May 24 2000

Keywords

Crossrefs

Cf. A007869 for graphs with an even number of edges.

Programs

  • Mathematica
    Table[Total[Table[NumberOfGraphs[n,m],{m,1,Binomial[n,2],2}]],{n,1,15}]  (* Geoffrey Critzer, Oct 20 2012 *)

Formula

a(n) = (A000088(n) - A000171(n))/2.

Extensions

More terms from Vladeta Jovovic, Jul 19 2000
Terms a(18) and beyond from Andrew Howroyd, Sep 17 2018

A054928 Number of complementary pairs of directed graphs on n nodes. Also number of unlabeled digraphs with n nodes and an even number of arcs.

Original entry on oeis.org

1, 2, 10, 114, 4872, 770832, 441038832, 896679948304, 6513978501814144, 170630215981070456064, 16261454692532635025585792, 5683372715412701087902846672384, 7334542846356464937798016155801130496, 35157828307617499760694672217473135511928832
Offset: 1

Views

Author

N. J. A. Sloane, May 24 2000

Keywords

Crossrefs

Programs

  • Mathematica
    permcount[v_] := Module[{m = 1, s = 0, k = 0, t}, For[i = 1, i <= Length[v], i++, t = v[[i]]; k = If[i > 1 && t == v[[i - 1]], k + 1, 1]; m *= t*k; s += t]; s!/m];
    edges[v_] := Sum[2*GCD[v[[i]], v[[j]]], {i, 2, Length[v]}, {j, 1, i - 1}] + Total[v - 1];
    b[n_] := (s = 0; Do[s += permcount[p]*2^edges[p], {p, IntegerPartitions[n]}]; s/n!);
    edges4[v_] := 4 Sum[Sum[GCD[v[[i]], v[[j]]], {j, 1, i - 1}], {i, 2, Length[v]}] + Sum[2 v[[i]] - 1, {i, 1, Length[v]}];
    c[n_] := (s = 0; Do[s += permcount[2 p]*2^edges4[p]*If[OddQ[n], n *4^Length[p], 1], {p, IntegerPartitions[n/2 // Floor]}]; s/n!);
    a[n_] := (b[n] + c[n])/2;
    Array[a, 14] (* Jean-François Alcover, Aug 26 2019, using Andrew Howroyd's code for b=A000273 and c=A003086 *)

Formula

Average of A000273 and A003086.

Extensions

More terms from Vladeta Jovovic, Jul 19 2000
Terms a(14) and beyond from Andrew Howroyd, Sep 17 2018

A055969 Number of unlabeled digraphs with n nodes and an odd number of arcs.

Original entry on oeis.org

0, 1, 6, 104, 4736, 770112, 440994608, 896679244544, 6513978322585408, 170630215971902124288, 16261454692523251085611648, 5683372715412699486531047331840, 7334542846356464931239079919515090432, 35157828307617499760690834338506768579289088
Offset: 1

Views

Author

Vladeta Jovovic, Jul 19 2000

Keywords

Crossrefs

Programs

Formula

a(n) = (A000273(n)-A003086(n))/2.

Extensions

Terms a(14) and beyond from Andrew Howroyd, Sep 17 2018

A055973 Number of unlabeled digraphs with loops (relations) on n nodes and with an even number of arcs.

Original entry on oeis.org

1, 1, 6, 52, 1540, 145984, 48467296, 56141454464, 229148555640864, 3333310786076963968, 174695272746896566439424, 33301710992539090379269318144, 23278728241293494584257987458067456, 60084295633556503802059558812644803074048, 576025077880237078776946976495257043823396069376
Offset: 0

Views

Author

Vladeta Jovovic, Jul 19 2000

Keywords

Comments

Also relations considered equivalent when isomorphic and when complemented. - Christian G. Bower, Jan 05 2004

Crossrefs

Formula

a(2*n) = (A000595(2*n) + A047832(n))/2; a(2*n+1) = A000595(2*n+1)/2.
a(n) = (A000595(n) + A000171(2*n+1))/2.
a(n) = sum {1*s_1+2*s_2+...=n, 1*t_1+2*t_2=2} (fixA[s_1, s_2, ...;t_1, t_2]/(1^s_1*s_1!*2^s_2*s_2!*...*1^t_1*t_1!*2^t_2*t_2!)) where fixA[...] = prod {i, j>=1} ( (sum {d|lcm(i, j)} (d*t_d))^(gcd(i, j)*s_i*s_j)) - Christian G. Bower, Jan 05 2004

Extensions

a(0)=1 prepended and terms a(13) and beyond from Andrew Howroyd, Apr 19 2020

A230367 Number of colorings of the edges of the complete graph on n unlabeled vertices using at most three interchangeable colors under the symmetries of the full edge permutation group.

Original entry on oeis.org

1, 3, 15, 142, 4300, 384199, 98654374, 70130880569, 136638863494089, 730439999032117301, 10764688922047900738650, 439762062635963206090747374, 50066701349010686289507943943535, 15962815411172611585301863116082363362, 14314975828662356561039590680011420432741442, 36247244119877673111912410070361564495415461430358
Offset: 2

Views

Author

Marko Riedel, Dec 20 2013

Keywords

References

  • Harary and Palmer, Graphical Enumeration, Chapter Six.

Crossrefs

Cf. A007869.

A233748 Number of colorings of the edges of the complete graph on n unlabeled vertices using at most four colors up to permutation of the colors.

Original entry on oeis.org

1, 3, 22, 513, 67685, 37205801, 74992370359, 543437207831908, 14224090440652751128, 1355263603548588163939892, 473629305416562052216063601182, 611217587951920565260750675133929534, 2929826971690847578421964010597063713803102, 52431093582529289457516130655642218612938867242516
Offset: 2

Views

Author

Marko Riedel, Dec 20 2013

Keywords

References

  • Harary and Palmer, Graphical Enumeration, Chapter Six.

Crossrefs

Cf. A007869.

Extensions

Definition clarified by Andrew Howroyd, Feb 04 2024

A233894 Number of colorings of the edges of the complete graph on n unlabeled vertices using at most five interchangeable colors under the symmetries of the full edge permutation group.

Original entry on oeis.org

1, 3, 24, 956, 370438, 794610689, 7713545142724, 334331083961076765, 65276369289196100770910, 57946272822007395195661933018, 235778940244496842474046899073666629, 4427916979407079482171816367439500693634123, 386083248154389925434229068715450099160359622470252
Offset: 2

Views

Author

Marko Riedel, Dec 20 2013

Keywords

References

  • Harary and Palmer, Graphical Enumeration, Chapter Six.

Crossrefs

Cf. A007869.

Extensions

More terms from Marko Riedel Feb 04 2024

A309116 a(n) = number of cographs on n points.

Original entry on oeis.org

1, 3, 25, 1299, 1974452, 94345468975, 152799292695935115, 10526127565809458484649781, 38375912431199015810067477044326371, 9002076475560099357419498216602893054297145089, 162015966626938926212463690033352243299416773774432388589099
Offset: 2

Views

Author

Michael De Vlieger, Jul 13 2019

Keywords

Comments

Here, a cograph is basically a partition of unlabeled edges of the complete graph on n unlabeled vertices. - Andrey Zabolotskiy, Aug 27 2022

Crossrefs

Cf. partitions into no more than 2..5 parts: A007869, A230367, A233748, A233894.

Programs

  • Mathematica
    cycleIndSymm[n_] := cycleIndSymm[n] = CoefficientRules[CycleIndexPolynomial[ SymmetricGroup[n], x /@ Range[n]], x /@ Range[n]];
    cycleIndEdge[n_] := cycleIndEdge[n] = CoefficientRules[Sum[Last[t] With[{tt = First[t]}, With[{ind = Flatten@Position[tt, Except[0], Heads -> False]}, Product[x[LCM@@p]^(GCD@@p Times@@tt[[p]]), {p, Subsets[ind, {2}]}] Product[With[{e = tt[[k]]}, x[k]^(k e (e-1)/2 + Quotient[k-1, 2] e) If[EvenQ[k], x[k/2]^e, 1]], {k, ind}]]], {t, cycleIndSymm[n]}], x /@ Range[n (n-1)/2]];
    v[n_, m_] := With[{dv = Divisors /@ Range[m]}, Sum[Last[a] With[{ra = Flatten@Position[First@a, Except[0], Heads -> False]}, Sum[Last[b] Product[(dv[[va]].b[[1, dv[[va]]]])^a[[1, va]], {va, ra}], {b, cycleIndSymm[m]}]], {a, cycleIndEdge[n]}]];
    a[2] = 1; a[3] = 3;
    a[n_] := 1 + v[n, -1 + n (n-1)/2];
    Table[a[n], {n, 2, 7}] (* Andrey Zabolotskiy, Feb 06 2024, after Marko Riedel *)

Extensions

a(6)-a(9) from Andrey Zabolotskiy, Aug 27 2022
a(10) from Andrey Zabolotskiy, Feb 06 2024
a(11)-a(12) from Andrey Zabolotskiy, Feb 26 2025
Showing 1-10 of 12 results. Next