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.

A326515 Number of factorizations of n into factors > 1 where every factor has the same average of prime indices.

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 3, 2, 1, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 3, 1, 1, 2, 1, 7, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1, 1, 2, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 2
Offset: 1

Views

Author

Gus Wiseman, Jul 12 2019

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.

Examples

			The a(900) = 9 factorizations:
  (3*3*10*10),
  (3*3*100), (3*10*30), (9*10*10),
  (3*300), (9*100), (10*90), (30*30),
  (900).
		

Crossrefs

Programs

  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    Table[Length[Select[facs[n],SameQ@@Mean/@primeMS/@#&]],{n,100}]
  • PARI
    avgpis(n) = { my(f=factor(n)); f[,1] = apply(primepi,f[,1]); (1/bigomega(n))*sum(i=1,#f~,f[i,2]*f[i,1]); };
    has_same_average_of_pis(facs) = if(!#facs, 1, my(avg=0); for(i=1,#facs,if(!avg, avg=avgpis(facs[i]), if(avg!=avgpis(facs[i]), return(0)))); (1));
    A326515(n, m=n, facs=List([])) = if(1==n, has_same_average_of_pis(facs), my(s=0, newfacs); fordiv(n, d, if((d>1)&&(d<=m), newfacs = List(facs); listput(newfacs,d); s += A326515(n/d, d, newfacs))); (s)); \\ Antti Karttunen, Jan 20 2025

Extensions

Data section extended to a(105) by Antti Karttunen, Jan 20 2025