OFFSET
1,2
EXAMPLE
The perfect powers (A001597) are:
1, 4, 8, 9, 16, 25, 27, 32, 36, 49, 64, 81, 100, 121, 125, 128, 144, 169, 196, ...
with first differences (A053289):
3, 4, 1, 7, 9, 2, 5, 4, 13, 15, 17, 19, 21, 4, 3, 16, 25, 27, 20, 9, 18, 13, ...
with positions of first appearances (A376268):
1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 16, 17, 18, 19, 21, 23, 24, 27, 28, 29, ...
MATHEMATICA
perpowQ[n_]:=n==1||GCD@@FactorInteger[n][[All, 2]]>1;
q=Differences[Select[Range[1000], perpowQ]];
Select[Range[Length[q]], !MemberQ[Take[q, #-1], q[[#]]]&]
CROSSREFS
The complement is A376519.
A053707 lists first differences of consecutive prime-powers.
A333254 lists run-lengths of differences between consecutive primes.
Other families of numbers and their first differences:
KEYWORD
nonn
AUTHOR
Gus Wiseman, Sep 28 2024
STATUS
approved