login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A076563 a(n) = n - greatest prime divisor of n, for n>1. 12

%I #26 Aug 07 2022 17:48:00

%S 0,0,2,0,3,0,6,6,5,0,9,0,7,10,14,0,15,0,15,14,11,0,21,20,13,24,21,0,

%T 25,0,30,22,17,28,33,0,19,26,35,0,35,0,33,40,23,0,45,42,45,34,39,0,51,

%U 44,49,38,29,0,55,0,31,56,62,52,55,0,51,46,63,0,69,0,37,70,57,66,65,0,75

%N a(n) = n - greatest prime divisor of n, for n>1.

%H Michael De Vlieger, <a href="/A076563/b076563.txt">Table of n, a(n) for n = 2..10000</a>

%F a(p) = 0 for prime p.

%F a(n) = n - A006530(n). - _Michel Marcus_, Jan 16 2015

%t Table[n-Last@(First/@FactorInteger[n]),{n,2,200}] (* _Vladimir Joseph Stephan Orlovsky_, Apr 08 2011 *)

%o (PARI) a(n) = n - vecmax(factor(n)[,1]); \\ _Michel Marcus_, Aug 07 2022

%o (Python)

%o from sympy import factorint

%o def a(n): return n - max(factorint(n))

%o print([a(n) for n in range(2, 81)]) # _Michael S. Branicky_, Aug 07 2022

%Y Cf. A006530, A070229.

%K easy,nonn

%O 2,3

%A _Zak Seidov_, Oct 19 2002

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 29 04:59 EDT 2024. Contains 371264 sequences. (Running on oeis4.)