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.

A344879 a(n) = A344875(n) / A344878(n), where A344875(n) is multiplicative with a(2^e) = 2^(1+e) - 1, and a(p^e) = p^e -1 for odd primes p, and A344878(n) gives the least common multiple of the same factors.

This page as a plain text file.
%I A344879 #13 Jun 15 2022 14:35:58
%S A344879 1,1,1,1,1,1,1,1,1,1,1,1,1,3,2,1,1,1,1,1,2,1,1,1,1,3,1,1,1,2,1,1,2,1,
%T A344879 2,1,1,3,2,1,1,6,1,1,4,1,1,1,1,3,2,1,1,1,2,3,2,1,1,2,1,3,2,1,4,2,1,1,
%U A344879 2,6,1,1,1,3,2,1,2,6,1,1,1,1,1,2,4,3,2,5,1,4,6,1,2,1,2,1,1,3,2,1,1,2,1,3,4
%N A344879 a(n) = A344875(n) / A344878(n), where A344875(n) is multiplicative with a(2^e) = 2^(1+e) - 1, and a(p^e) = p^e -1 for odd primes p, and A344878(n) gives the least common multiple of the same factors.
%H A344879 Antti Karttunen, <a href="/A344879/b344879.txt">Table of n, a(n) for n = 1..65537</a>
%t A344879 f[2, e_] := 2^(e + 1) - 1; f[p_, e_] := p^e - 1; a[1] = 1; a[n_] := Times @@ (fct = f @@@ FactorInteger[n])/LCM @@ fct; Array[a, 100] (* _Amiram Eldar_, Jun 03 2021 *)
%o A344879 (PARI)
%o A344879 A344875(n) = { my(f=factor(n)~); prod(i=1, #f, (f[1, i]^(f[2, i]+(2==f[1, i]))-1)); };
%o A344879 A344878(n) = if(1==n,n, my(f=factor(n)~); lcm(vector(#f, i, (f[1, i]^(f[2, i]+(2==f[1, i]))-1))));
%o A344879 A344879(n) = (A344875(n) / A344878(n));
%o A344879 (Python)
%o A344879 from math import prod, lcm
%o A344879 from sympy import factorint
%o A344879 def A344879(n): return prod(a := tuple(p**(e+int(p==2))-1 for p, e in factorint(n).items()))//lcm(*a) # _Chai Wah Wu_, Jun 15 2022
%Y A344879 Cf. A344875, A344878.
%K A344879 nonn
%O A344879 1,14
%A A344879 _Antti Karttunen_, Jun 03 2021