OFFSET
1,1
COMMENTS
I call n a "k-nadir" (or nadir of depth k) of the arithmetical function f if n satisfies f(n-k) > ... > f(n-1) > f(n) < f(n+1) < ... < f(n+k).
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
MATHEMATICA
Select[Range[3, 10^6], DivisorSigma[1, # - 2] > DivisorSigma[1, # - 1] > DivisorSigma[1, # ] < DivisorSigma[1, # + 1] < DivisorSigma[1, # + 2] &]
Flatten[Position[Partition[DivisorSigma[1, Range[675000]], 5, 1], _? (#[[1]]> #[[2]]>#[[3]]<#[[4]]<#[[5]]&), 1, Heads->False]]+2 (* Harvey P. Dale, Jan 04 2022 *)
PROG
(Magma) ds:=DivisorSigma; f:=func<n|ds(1, n) lt ds(1, n+1) and ds(1, n+1) lt ds(1, n+2)>; f1:= func<n|ds(1, n) lt ds(1, n-1) and ds(1, n-1) lt ds(1, n-2)>; [k:k in [3..675000]|f(k) and f1(k)]; // Marius A. Burtea, Feb 19 2020
CROSSREFS
KEYWORD
nonn
AUTHOR
Joseph L. Pe, Nov 14 2002
STATUS
approved