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

A007898 a(n) = psi_c(n), where Product_{k>1} 1/(1-1/k^s)^A007897(k) = Sum_{k>0} psi_c(k)/k^s.

Original entry on oeis.org

1, 1, 2, 3, 3, 4, 4, 7, 7, 6, 6, 12, 7, 8, 12, 16, 9, 15, 10, 18, 16, 12, 12, 32, 17, 14, 22, 24, 15, 30, 16, 34, 24, 18, 24, 48, 19, 20, 28, 48, 21, 40, 22, 36, 45, 24, 24, 78, 32, 37, 36, 42, 27, 54, 36, 64, 40, 30, 30, 96, 31, 32, 60, 78, 42, 60, 34, 54
Offset: 1

Views

Author

Felix Weinstein (wain(AT)ana.unibe.ch)

Keywords

Examples

			G.f. = x + x^2 + 2*x^3 + 3*x^4 + 3*x^5 + 4*x^6 + 4*x^7 + 7*x^8 + 7*x^9 + ...
		

References

  • F. V. Weinstein, The Fibonacci Partitions, preprint, 1995.

Crossrefs

Programs

  • Mathematica
    dircon[v_, w_] := Module[{lv = Length[v], lw = Length[w], fv, fw}, fv[n_] := If[n <= lv, v[[n]], 0]; fw[n_] := If[n <= lw, w[[n]], 0]; Table[ DirichletConvolve[fv[n], fw[n], n, m], {m, Min[lv, lw]}]];
    a[n_] := Module[{A, v, w, m}, If[n<1, 0, v = Table[Boole[k == 1], {k, n}]; For[k = 2, k <= n, k++, m = Length[IntegerDigits[n, k]] - 1; A = Product[ {p, e} = pe; If[p == 2, If[e<3, e, 2^(e-2) + 2], 1 + p^(e-1) (p-1)/2], {pe, FactorInteger[k]}]; A = (1-x)^-A + x O[x]^m // Normal; w = Table[0, {n}]; For[i = 0, i <= m, i++, w[[k^i]] = Coefficient[A, x, i]]; v = dircon[v, w]]; v[[n]]]];
    Array[a, 68] (* Jean-François Alcover, Nov 12 2018, from PARI *)
  • PARI
    {a(n) = my(A, v, w, m, p, e); if( n<1, 0, v = vector(n, k, k==1); for(k=2, n, m = #digits(n, k) - 1; A = factor(k); A = prod( j=1, matsize(A)[1], if( p = A[j,1], e = A[j,2]; if( p==2, if( e<3, e, 2^(e-2) + 2), 1 + p^(e-1) * (p-1) / 2))); A = (1 - x)^ -A + x * O(x^m); w = vector(n); for(i=0, m, w[k^i] = polcoeff(A, i)); v = dirmul(v, w)); v[n])}; /* Michael Somos, May 26 2014 */

Extensions

New definition by Michel Marcus, May 12 2014
Definition edited by N. J. A. Sloane, May 26 2014

A007896 Psi_c(n), where Product_{k>1} 1/(1-1/k^s)^phi(k) = Sum_{k>0} psi_c(k)/k^s.

Original entry on oeis.org

1, 1, 2, 3, 4, 4, 6, 7, 9, 8, 10, 12, 12, 12, 16, 18, 16, 19, 18, 24, 24, 20, 22, 32, 30, 24, 34, 36, 28, 40, 30, 42, 40, 32, 48, 60, 36, 36, 48, 64, 40, 60, 42, 60, 76, 44, 46, 86, 63, 66, 64, 72, 52, 82, 80, 96, 72, 56, 58, 128, 60, 60, 114, 104, 96, 100
Offset: 1

Views

Author

Felix Weinstein (wain(AT)ana.unibe.ch)

Keywords

Comments

Phi(k) is the Euler totient function A000010.

Examples

			The left-hand side (a Dirichlet generating function) is
1/((1-1/2^s)*(1-1/3^s)^2*(1-1/4^s)^2*(1-1/5^s)^4*(1-1/6^s)^2*(1-1/7^s)^6* ...)
= 1 + 1/2^s + 2/3^s + 3/4^s + 4/5^s + 4/6^s + 6/7^s + 7/8^s + 9/9^s + ...,
whose coefficients are 1, 1, 2, 3, 4, 4, 6, 7, 9, ... . - _N. J. A. Sloane_, May 26 2014
G.f. = x + x^2 + 2*x^3 + 3*x^4 + 4*x^5 + 4*x^6 + 6*x^7 + 7*x^8 + 9*x^9 + ...
		

References

  • Felix Weinstein, The Fibonacci Partitions, preprint, 1995

Crossrefs

Programs

  • Mathematica
    dircon[v_, w_] := Module[{lv = Length[v], lw = Length[w], fv, fw}, fv[n_] := If[n <= lv, v[[n]], 0]; fw[n_] := If[n <= lw, w[[n]], 0]; Table[ DirichletConvolve[fv[n], fw[n], n, m], {m, Min[lv, lw]}]];
    a[n_] := Module[{A, v, w, m}, If[n<1, 0, v = Table[Boole[k == 1], {k, n}]; For[k = 2, k <= n, k++, m = Length[IntegerDigits[n, k]] - 1; A = (1 - x)^-EulerPhi[k] + x*O[x]^m // Normal; w = Table[0, {n}]; For[i = 0, i <= m, i++, w[[k^i]] = Coefficient[A, x, i]]; v = dircon[v, w]]; v[[n]]]];
    Array[a, 66] (* Jean-François Alcover, Nov 12 2018, from PARI *)
  • PARI
    {a(n) = my(A, v, w, m); if( n<1, 0, v = vector(n, k, k==1); for(k=2, n, m = #digits(n, k) - 1; A = (1 - x)^ -eulerphi(k) + x * O(x^m); w = vector(n); for(i=0, m, w[k^i] = polcoeff(A, i)); v = dirmul(v, w)); v[n])}; /* Michael Somos, May 26 2014 */

Extensions

Definition corrected by Felix Weinstein (wain(AT)ana.unibe.ch), May 14 2014

A180783 Number of distinct solutions of Sum_{i=1..1} (x(2i-1)*x(2i)) == 1 (mod n), with x() in {1,2,...,n-1}.

Original entry on oeis.org

0, 1, 2, 2, 3, 2, 4, 4, 4, 3, 6, 4, 7, 4, 6, 6, 9, 4, 10, 6, 8, 6, 12, 8, 11, 7, 10, 8, 15, 6, 16, 10, 12, 9, 14, 8, 19, 10, 14, 12, 21, 8, 22, 12, 14, 12, 24, 12, 22, 11, 18, 14, 27, 10, 22, 16, 20, 15, 30, 12, 31, 16, 20, 18, 26, 12, 34, 18, 24, 14, 36, 16, 37, 19, 22, 20, 32, 14, 40, 20, 28
Offset: 1

Views

Author

R. H. Hardin, formula from Max Alekseyev in the Sequence Fans Mailing List, Sep 20 2010

Keywords

Comments

Except for the first term, this appears to be the number of pairs of integers i,j with 1 <= i <= n, 1 <= j <= i, such that i+j == i*j (mod n), for n=1,2,3,... - John W. Layman, Oct 19 2011
Layman's observation holds since i+j == i*j (mod n) is equivalent to (i-1)*(j-1) == 1 (mod n). - Max Alekseyev, Oct 22 2011
For i > 1, equal to the number of elements x relatively prime to n such that x mod n >= x^(-1) mod n. - Jeffrey Shallit, Jun 14 2018
Differs from A007897 for n = 1, 35, 45 etc. - Georg Fischer, Sep 20 2020

Examples

			Solutions for product of a single 1..10 pair = 1 (mod 11) are (1*1) (2*6) (3*4) (5*9) (7*8) (10*10).
		

Crossrefs

Column 1 of A180793.

Formula

a(n) = (A000010(n) + A060594(n)) / 2.

A175378 G.f. x^4*(2*x^2-1)/( (x^2-1)*(x^2+x-1)*(2*x^3-2*x^2+2*x-1) ).

Original entry on oeis.org

0, 0, 0, 0, 1, 3, 5, 8, 14, 26, 45, 75, 125, 212, 358, 598, 993, 1651, 2745, 4552, 7526, 12426, 20501, 33787, 55605, 91404, 150118, 246350, 403929, 661763, 1083393, 1772512, 2898182, 4735938, 7734765, 12626059, 20600733, 33597188, 54769606
Offset: 0

Views

Author

R. J. Mathar, Apr 24 2010

Keywords

Crossrefs

Programs

  • Magma
    I:=[0, 0, 0, 0, 1, 3, 5]; [n le 7 select I[n] else 3*Self(n-1) - 2*Self(n-2) - Self(n-3) + 3*Self(n-4) - 4*Self(n-5) + 2*Self(n-7): n in [1..40]]; // Vincenzo Librandi, Dec 20 2012
  • Mathematica
    LinearRecurrence[{3,-2,-1,3,-4,0,2},{0,0,0,0,1,3,5},40] (* Harvey P. Dale, Mar 07 2012 *)
    CoefficientList[Series[x^4*(2*x^2 - 1)/((x^2 - 1)*(x^2 + x - 1)*(2*x^3 - 2*x^2 + 2*x - 1)), {x, 0, 40}], x] (* Vincenzo Librandi, Dec 20 2012 *)

Formula

a(n) = 3*a(n-1) -2*a(n-2) -a(n-3) +3*a(n-4) -4*a(n-5) +2*a(n-7).
Showing 1-4 of 4 results.