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!)
A063041 Image of n under Collatz-2 map, a generalization of the classical '3x+1' - function: instead of dividing an even number by 2 a nonprime will be divided by its smallest prime factor and a prime will be multiplied not by 3 but by its prime-predecessor, before one is added. 7
3, 7, 2, 16, 3, 36, 4, 3, 5, 78, 6, 144, 7, 5, 8, 222, 9, 324, 10, 7, 11, 438, 12, 5, 13, 9, 14, 668, 15, 900, 16, 11, 17, 7, 18, 1148, 19, 13, 20, 1518, 21, 1764, 22, 15, 23, 2022, 24, 7, 25, 17, 26, 2492, 27, 11, 28, 19, 29, 3128, 30, 3600, 31, 21, 32, 13, 33, 4088, 34, 23 (list; graph; refs; listen; history; text; internal format)
OFFSET
2,1
LINKS
FORMULA
a(n) = if n prime then (n * pp(n) + 1) else (n / lpf(n)) for n > 1 where pp(n) = if n > 2 then Max{p prime | p < n} else 1; [prime-predecessor] and lpf(n) = if n > 2 then Min{p prime | p < n and p divides n} else 1; [where lpf = A020639].
If A010051(n) = 1 [when n is a prime], a(n) = 1 + (A064989(n)*n), otherwise a(n) = A032742(n). - Antti Karttunen, Jan 23 2017
EXAMPLE
a(17) = 17 * 13 = 222 as 17 is prime and 13 is the largest prime < 17; a(4537) = 349 as 4537 = 13 * 349 hence lpf(4537) = 13; other examples in A063042, A063043, A063044.
For n=2, its prime-predecessor is taken as 1 (because 2 is the first prime), thus a(2) = (1*2)+1 = 3.
MATHEMATICA
Join[{3}, Table[If[PrimeQ[n], n*Prime[PrimePi[n]-1]+1, n/Min[First/@FactorInteger[n]]], {n, 3, 69}]] (* Jayanta Basu, May 27 2013 *)
PROG
(Scheme) (define (A063041 n) (if (= 1 (A010051 n)) (+ 1 (* (A064989 n) n)) (A032742 n))) ;; Antti Karttunen, Jan 23 2017
(Python)
from sympy import isprime, prevprime, primefactors
def f(n): return 1 if n == 2 else prevprime(n)
def a(n): return n*f(n)+1 if isprime(n) else n//min(primefactors(n))
print([a(n) for n in range(2, 70)]) # Michael S. Branicky, Apr 17 2023
CROSSREFS
Cf. A063042, A063043, A063044, A280707 (trajectories starting from 3, 17, 29 and 47).
Sequence in context: A318467 A324713 A245611 * A257729 A328502 A308480
KEYWORD
nonn,easy
AUTHOR
Reinhard Zumkeller, Jul 07 2001
EXTENSIONS
More terms from Matthew Conroy, Jul 15 2001
Description clarified by Antti Karttunen, Jan 23 2017
STATUS
approved

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 April 25 07:41 EDT 2024. Contains 371964 sequences. (Running on oeis4.)