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.

A345161 If n = Product (p_j^k_j) then a(n) = max (nextprime(p_j) - p_j), where nextprime = A151800.

This page as a plain text file.
%I A345161 #54 Aug 27 2021 13:05:50
%S A345161 1,1,2,1,2,2,4,1,2,2,2,2,4,4,2,1,2,2,4,2,4,2,6,2,2,4,2,4,2,2,6,1,2,2,
%T A345161 4,2,4,4,4,2,2,4,4,2,2,6,6,2,4,2,2,4,6,2,2,4,4,2,2,2,6,6,4,1,4,2,4,2,
%U A345161 6,4,2,2,6,4,2,4,4,4,4,2,2,2,6,4,2,4,2,2,8,2
%N A345161 If n = Product (p_j^k_j) then a(n) = max (nextprime(p_j) - p_j), where nextprime = A151800.
%H A345161 Ilya Gutkovskiy, <a href="/A345161/a345161.jpg">Plot of (1/prime(n)) * Sum_{k=1..n} a(k)</a>
%H A345161 <a href="/index/Pri#prime_indices">Index entries for sequences computed from indices in prime factorization</a>
%H A345161 <a href="/index/Pri#gaps">Index entries for primes, gaps between</a>
%F A345161 If n = Product (p_j^k_j) then a(n) = max (prime(pi(p_j) + 1) - p_j), where pi = A000720.
%F A345161 a(2^j*n) = a(n).
%F A345161 a(n^j) = a(n), j > 0.
%F A345161 a(prime(n)^j) = A001223(n), j > 0.
%F A345161 a(n!) = A327441(n).
%F A345161 a(prime(n)#) = A063095(n).
%F A345161 2 + Sum_{k=1..n-1} a(prime(k)^j) = prime(n), j > 0.
%F A345161 Sum_{d|n} mu(n/d) * a(d) = 0 if n is an even number or an odd number divisible by a square > 1.
%e A345161 a(39) = a(3 * 13) = a(prime(2) * prime(6)), prime(3) - prime(2) = 5 - 3 = 2, prime(7) - prime(6) = 17 - 13 = 4, so a(39) = max(2, 4) = 4.
%t A345161 a[n_] := Max @@ (NextPrime[#[[1]]] - #[[1]] & /@ FactorInteger[n]); Table[a[n], {n, 1, 90}]
%Y A345161 Cf. A000079 (positions of 1's), A000720, A001223, A006530, A061395, A063095, A151800, A327441, A347101, A347102.
%K A345161 nonn
%O A345161 1,3
%A A345161 _Ilya Gutkovskiy_, Aug 26 2021