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.

A322841 Number of positive integers less than n with more distinct prime factors than n.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 2, 0, 3, 0, 0, 5, 5, 0, 6, 0, 0, 0, 9, 0, 10, 0, 11, 0, 12, 0, 13, 13, 1, 1, 1, 1, 17, 1, 1, 1, 20, 0, 21, 2, 2, 2, 24, 2, 25, 2, 2, 2, 28, 2, 2, 2, 2, 2, 33, 0, 34, 3, 3, 36, 3, 0, 38, 4, 4, 0, 41, 5, 42, 5, 5, 5, 5, 0, 47, 6, 48
Offset: 1

Views

Author

Gus Wiseman, Dec 28 2018

Keywords

Examples

			Column n lists the a(n) positive integers less than n with more distinct prime factors than n:
  1  2  3  4  5  6  7  8  9  10  11  12  13  14  15  16  17  18  19  20
  ---------------------------------------------------------------------
                    6  6  6      10      12          15  15      18
                                  6      10          14  14      15
                                          6          12  12      14
                                                     10  10      12
                                                      6   6      10
                                                                  6
		

Crossrefs

Programs

  • Maple
    b:= proc(n) option remember; nops(numtheory[factorset](n)) end:
    a:= proc(n) option remember;
          (t-> add(`if`(b(i)>t, 1, 0), i=1..n-1))(b(n))
        end:
    seq(a(n), n=1..100);  # Alois P. Heinz, Dec 28 2018
  • Mathematica
    Table[Length[Select[Range[n],PrimeNu[#]>PrimeNu[n]&]],{n,100}]
  • PARI
    a(n) = my(omegan=omega(n)); sum(k=1, n-1, omega(k) > omegan); \\ Michel Marcus, Dec 29 2018
    
  • PARI
    first(n) = {my(t = 1, pp = 1, res = vector(n)); forprime(p = 2, oo, pp*=p; if(pp > n, v = vector(t); break); t++); for(i = 1, n, o = omega(i); res[i] = v[o+1]; for(j = 1, o, v[j]++)); res} \\ David A. Corneth, Dec 29 2018