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.

A264441 Length of row n of the irregular triangle A133995 (positive integers <= n which are neither divisors of n nor coprime to n).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 3, 1, 5, 4, 4, 1, 7, 1, 7, 6, 9, 1, 9, 3, 11, 6, 11, 1, 15, 1, 11, 10, 15, 8, 16, 1, 17, 12, 17, 1, 23, 1, 19, 16, 21, 1, 23, 5, 25, 16, 23, 1, 29, 12, 25, 18, 27, 1, 33, 1, 29, 22, 26, 14, 39, 1, 31, 22, 39, 1
Offset: 1

Views

Author

Wolfdieter Lang, Jan 16 2016

Keywords

Crossrefs

Programs

  • Maple
    seq(max(1, n - numtheory:-tau(n) - numtheory:-phi(n) + 1), n=1..100); # Robert Israel, Jan 28 2016
  • Mathematica
    a[1] = a[4] = 1; a[n_] := If[PrimeQ[n], 1, n + 1 - DivisorSigma[0, n] - EulerPhi[n]]; Array[a, 100] (* Jean-François Alcover, Jan 18 2016 *)
  • PARI
    A264441(n) = max(1,n+1-numdiv(n)-eulerphi(n)); \\ Antti Karttunen, Mar 04 2018, after code in A045763.

Formula

a(1) = 1, a(4) = 1 and a(n) = 1 if n is a prime (n from A000040) else a(n) = A045763(n).
a(n) = max(1, A045763(n)). - Robert Israel, Jan 28 2016