login
a(n) = max {k >= 1 | sigma(k) <= n}.
6

%I #47 Mar 28 2020 15:09:51

%S 1,1,2,3,3,5,5,7,7,7,7,11,11,13,13,13,13,17,17,19,19,19,19,23,23,23,

%T 23,23,23,29,29,31,31,31,31,31,31,37,37,37,37,41,41,43,43,43,43,47,47,

%U 47,47,47,47,53,53,53,53,53,53,59,59,61,61,61,61,61,61,67,67,67,67,71,71

%N a(n) = max {k >= 1 | sigma(k) <= n}.

%C Old name was "Extended 'previous prime' version 2".

%C This is the same as A151799 if n >= 3 and falls back to 1, if no prime smaller than n exists.

%C a(n+1) is the largest number k such that A007955(k) <= n, where A007955 is the product of divisors. - _Jaroslav Krizek_, Apr 01 2010

%C For every k >= 1, the equation n - a(n) = k has infinitely many solutions. - _Bernard Schott_, Mar 05 2019

%D P. Tauvel, Exercices d'Algèbre Générale et d'Arithmétique, Dunod, 2004, Exercice 18 p. 204.

%H Enrique Pérez Herrero, <a href="/A136548/b136548.txt">Table of n, a(n) for n = 1..5000</a>

%F a(n) = A006530(A000142(n-1)). - _Michel Marcus_, Jun 20 2014

%F For n > 1, a(n) < n. If p is prime, a(p+1) = p. - _Bernard Schott_, Mar 05 2019

%t A136548[1]:= 1; A136548[2]:= 1; A136548[n_]:= Prime[PrimePi[n-1]]; Array[A136548,50] (* _Enrique Pérez Herrero_, Jul 23 2011 *)

%Y Cf. A000203 (sigma), A000142, A006530, A151799.

%K nonn,easy

%O 1,3

%A _Roger L. Bagula_, Mar 26 2008

%E Definition clarified by _N. J. A. Sloane_, Mar 14 2019 based on a suggestion from _Jaroslav Krizek_, Mar 01 2010.