[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
login
Search: a054576 -id:a054576
     Sort: relevance | references | number | modified | created      Format: long | short | data
a(n) = A000045(A032742(n)) / A000045(A054576(n)), where A000045(n) gives the n-th Fibonacci number, A032742(n) = the largest proper divisor of n, and A054576(n) = A032742(A032742(n)).
+20
5
1, 1, 1, 1, 1, 2, 1, 3, 2, 5, 1, 4, 1, 13, 5, 7, 1, 17, 1, 11, 13, 89, 1, 18, 5, 233, 17, 29, 1, 122, 1, 47, 89, 1597, 13, 76, 1, 4181, 233, 123, 1, 842, 1, 199, 122, 28657, 1, 322, 13, 15005, 1597, 521, 1, 5777, 89, 843, 4181, 514229, 1, 1364, 1, 1346269, 842, 2207, 233, 39602, 1, 3571, 28657, 709805, 1, 5778, 1, 24157817, 15005, 9349, 89, 271442, 1, 15127, 5777
OFFSET
1,6
COMMENTS
A000045 is a divisibility sequence, which guarantees that the result of the division is an integer.
LINKS
FORMULA
a(n) = A105800(n) / A280688(n) = A105800(n) / A105800(A032742(n)).
a(n) = A000045(A032742(n)) / A000045(A054576(n)).
a(n) = A280690(A032742(n)).
PROG
(Scheme) (define (A280689 n) (/ (A105800 n) (A280688 n)))
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jan 11 2017
STATUS
approved
+20
3
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 3, 1, 2, 1, 5, 1, 1, 1, 8, 1, 1, 2, 13, 1, 5, 1, 21, 1, 1, 1, 34, 1, 1, 1, 55, 1, 13, 1, 89, 5, 1, 1, 144, 1, 5, 1, 233, 1, 34, 1, 377, 1, 1, 1, 610, 1, 1, 13, 987, 1, 89, 1, 1597, 1, 13, 1, 2584, 1, 1, 5, 4181, 1, 233, 1, 6765, 34, 1, 1, 10946, 1, 1, 1, 17711, 1, 610, 1, 28657, 1, 1, 1, 46368, 1, 13, 89, 75025, 1, 1597
OFFSET
1,12
LINKS
FORMULA
a(n) = A000045(A054576(n)).
a(n) = A280686(A105800(n)).
a(n) = A105800(A032742(n)).
PROG
(Scheme, two alternatives)
(define (A280688 n) (A280686 (A105800 n)))
(define (A280688 n) (A105800 (A032742 n)))
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jan 11 2017
STATUS
approved
a(n) = A015518(A032742(n)) / A015518(A054576(n)).
+20
2
1, 1, 1, 2, 1, 7, 1, 10, 7, 61, 1, 26, 1, 547, 61, 82, 1, 703, 1, 242, 547, 44287, 1, 730, 61, 398581, 703, 2186, 1, 58807, 1, 6562, 44287, 32285041, 547, 19682, 1, 290565367, 398581, 59050, 1, 4780783, 1, 177146, 58807, 23535794707, 1, 531442, 547, 3472494301, 32285041, 1594322, 1, 387400807, 44287, 4782970, 290565367, 17157594341221, 1, 14348906, 1
OFFSET
1,4
COMMENTS
A015518 is a divisibility sequence, which guarantees that the result of the division is an integer.
a(n) is a function of A032742(n).
LINKS
FORMULA
a(n) = A015518(A032742(n)) / A015518(A054576(n)).
PROG
(Scheme) (define (A280691 n) (/ (A015518 (A032742 n)) (A015518 (A054576 n))))
CROSSREFS
Cf. also A280689.
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jan 11 2017
STATUS
approved
Lpf(n): least prime dividing n (when n > 1); a(1) = 1. Or, smallest prime factor of n, or smallest prime divisor of n.
+10
1035
1, 2, 3, 2, 5, 2, 7, 2, 3, 2, 11, 2, 13, 2, 3, 2, 17, 2, 19, 2, 3, 2, 23, 2, 5, 2, 3, 2, 29, 2, 31, 2, 3, 2, 5, 2, 37, 2, 3, 2, 41, 2, 43, 2, 3, 2, 47, 2, 7, 2, 3, 2, 53, 2, 5, 2, 3, 2, 59, 2, 61, 2, 3, 2, 5, 2, 67, 2, 3, 2, 71, 2, 73, 2, 3, 2, 7, 2, 79, 2, 3, 2, 83, 2, 5, 2, 3, 2, 89, 2, 7, 2, 3, 2, 5, 2, 97
OFFSET
1,2
COMMENTS
Also, the largest number of distinct integers such that all their pairwise differences are coprime to n. - Max Alekseyev, Mar 17 2006
The unit 1 is not a prime number (although it has been considered so in the past). 1 is the empty product of prime numbers, thus 1 has no least prime factor. - Daniel Forgues, Jul 05 2011
a(n) = least m > 0 for which n! + m and n - m are not relatively prime. - Clark Kimberling, Jul 21 2012
For n > 1, a(n) = the smallest k > 1 that divides n. - Antti Karttunen, Feb 01 2014
For n > 1, records are at prime indices. - Zak Seidov, Apr 29 2015
The initials "lpf" might be mistaken for "largest prime factor" (A009190), using "spf" for "smallest prime factor" would avoid this. - M. F. Hasler, Jul 29 2015
n = 89 is the first index > 1 for which a(n) differs from the smallest k > 1 such that (2^k + n - 2)/k is an integer. - M. F. Hasler, Aug 11 2015
From Stanislav Sykora, Jul 29 2017: (Start)
For n > 1, a(n) is also the smallest k, 1 < k <= n, for which the binomial(n,k) is not divisible by n.
Proof: (A) When k and n are relatively prime then binomial(n,k) is divisible by n because k*binomial(n,k) = n*binomial(n-1,k-1). (B) When gcd(n,k) > 1, one of its prime factors is the smallest; let us denote it p, p <= k, and consider the binomial(n,p) = (1/p!)*Product_{i=0..p-1} (n-i). Since p is a divisor of n, it cannot be a divisor of any of the remaining numerator factors. It follows that, denoting as e the largest e > 0 such that p^e|n, the numerator is divisible by p^e but not by p^(e+1). Hence, the binomial is divisible by p^(e-1) but not by p^e and therefore not divisible by n. Applying (A), (B) to all considered values of k completes the proof. (End)
From Bob Selcoe, Oct 11 2017, edited by M. F. Hasler, Nov 06 2017: (Start)
a(n) = prime(j) when n == J (mod A002110(j)), n, j >= 1, where J is the set of numbers <= A002110(j) with smallest prime factor = prime(j). The number of terms in J is A005867(j-1). So:
a(n) = 2 when n == 0 (mod 2);
a(n) = 3 when n == 3 (mod 6);
a(n) = 5 when n == 5 or 25 (mod 30);
a(n) = 7 when n == 7, 49, 77, 91, 119, 133, 161 or 203 (mod 210);
etc. (End)
For n > 1, a(n) is the leftmost term, other than 0 or 1, in the n-th row of A127093. - Davis Smith, Mar 05 2019
REFERENCES
D. S. Mitrinovic et al., Handbook of Number Theory, Kluwer, Section IV.1.
LINKS
Daniel Forgues, Table of n, a(n) for n = 1..100000 (terms 1..10000 from T. D. Noe)
A. E. Brouwer, Two number theoretic sums, Stichting Mathematisch Centrum. Zuivere Wiskunde, Report ZW 19/74 (1974): 3 pages. [Copy included with the permission of the author.]
David Singmaster, Letter to N. J. A. Sloane, Oct 3 1982.
Eric Weisstein's World of Mathematics, Least Prime Factor
FORMULA
A014673(n) = a(A032742(n)); A115561(n) = a(A054576(n)). - Reinhard Zumkeller, Mar 10 2006
A028233(n) = a(n)^A067029(n). - Reinhard Zumkeller, May 13 2006
a(n) = A027746(n,1) = A027748(n,1). - Reinhard Zumkeller, Aug 27 2011
For n > 1: a(n) = A240694(n,2). - Reinhard Zumkeller, Apr 10 2014
a(n) = A000040(A055396(n)) = n / A032742(n). - Antti Karttunen, Mar 07 2017
a(n) has average order n/(2 log n) [Brouwer] - N. J. A. Sloane, Sep 03 2017
MAPLE
A020639 := proc(n) if n = 1 then 1; else min(op(numtheory[factorset](n))) ; end if; end proc: seq(A020639(n), n=1..20) ; # R. J. Mathar, Oct 25 2010
MATHEMATICA
f[n_]:=FactorInteger[n][[1, 1]]; Join[{1}, Array[f, 120, 2]] (* Robert G. Wilson v, Apr 06 2011 *)
Join[{1}, Table[If[EvenQ[n], 2, FactorInteger[n][[1, 1]]], {n, 2, 120}]] (* Zak Seidov, Nov 17 2013 *)
Riffle[Join[{1}, Table[FactorInteger[n][[1, 1]], {n, 3, 101, 2}]], 2] (* Harvey P. Dale, Dec 16 2021 *)
PROG
(PARI) A020639(n) = { vecmin(factor(n)[, 1]) } \\ [Will yield an error for n = 1.] - R. J. Mathar, Mar 02 2012
(PARI) A020639(n)=if(n>1, if(n>n=factor(n, 0)[1, 1], n, factor(n)[1, 1]), 1) \\ Avoids complete factorization if possible. Often the smallest prime factor can be found quickly even if it is larger than primelimit. If factoring takes too long for large n, use debugging level >= 3 (\g3) to display the smallest factor as soon as it is found. - M. F. Hasler, Jul 29 2015
(Haskell)
a020639 n = spf a000040_list where
spf (p:ps) | n < p^2 = n
| mod n p == 0 = p
| otherwise = spf ps
-- Reinhard Zumkeller, Jul 13 2011
(Sage)
def A020639_list(n) : return [1] + [prime_divisors(n)[0] for n in (2..n)]
A020639_list(97) # Peter Luschny, Jul 16 2012
(Scheme) (define (A020639 n) (if (< n 2) n (let loop ((k 2)) (cond ((zero? (modulo n k)) k) (else (loop (+ 1 k))))))) ;; Antti Karttunen, Feb 01 2014
(Sage) [trial_division(n) for n in (1..100)] # Giuseppe Coppoletta, May 25 2016
(Python)
from sympy import factorint
def a(n): return 1 if n == 1 else min(factorint(n))
print([a(n) for n in range(1, 98)]) # Michael S. Branicky, Dec 09 2021
CROSSREFS
Cf. A090368 (bisection).
Cf. A046669 (partial sums), A072486 (partial products).
Cf. A127093.
KEYWORD
nonn,easy,nice,core,changed
EXTENSIONS
Deleted wrong comment from M. Lagneau in 2012, following an observation by Gionata Neri. - M. F. Hasler, Aug 11 2015
Edited by M. F. Hasler, Nov 06 2017
Expanded definition to make this easier to find. - N. J. A. Sloane, Sep 21 2020
STATUS
approved
a(1) = 1; for n > 1, a(n) = largest proper divisor of n (that is, for n>1, maximum divisor d of n in range 1 <= d < n).
+10
251
1, 1, 1, 2, 1, 3, 1, 4, 3, 5, 1, 6, 1, 7, 5, 8, 1, 9, 1, 10, 7, 11, 1, 12, 5, 13, 9, 14, 1, 15, 1, 16, 11, 17, 7, 18, 1, 19, 13, 20, 1, 21, 1, 22, 15, 23, 1, 24, 7, 25, 17, 26, 1, 27, 11, 28, 19, 29, 1, 30, 1, 31, 21, 32, 13, 33, 1, 34, 23, 35, 1, 36, 1, 37, 25, 38, 11, 39, 1, 40
OFFSET
1,4
COMMENTS
It seems that a(n) = Max_{j=n+1..2n-1} gcd(n,j). - Labos Elemer, May 22 2002
This is correct: No integer in the range [n+1, 2n-1] has n as its divisor, but certainly at least one multiple of the largest proper divisor of n will occur there (e.g., if it is n/2, then at n + (n/2)). - Antti Karttunen, Dec 18 2014
The slopes of the visible lines made by the points in the scatter plot are 1/2, 1/3, 1/5, 1/7, ... (reciprocals of primes). - Moosa Nasir, Jun 19 2022
LINKS
Rémi Eismann, Table of n, a(n) for n = 1..10000 (first 1000 terms from T. D. Noe)
Moosa Nasir, Slopes.
Eric Weisstein's World of Mathematics, Proper Divisor.
FORMULA
a(n) = n / A020639(n).
Other identities and observations:
A054576(n) = a(a(n)); A117358(n) = a(a(a(n))) = a(A054576(n)); a(A008578(n)) = 1, a(A002808(n)) > 1. - Reinhard Zumkeller, Mar 10 2006
a(n) = A130064(n) / A006530(n). - Reinhard Zumkeller, May 05 2007
a(m)*a(n) < a(m*n) for m and n > 1. - Reinhard Zumkeller, Apr 11 2008
a(m*n) = max(m*a(n), n*a(m)). - Robert Israel, Dec 18 2014
From Antti Karttunen, Mar 31 2018: (Start)
a(n) = n - A060681(n).
For n > 1, a(n) = A003961^(r)(A246277(n)), where r = A055396(n)-1 and A003961^(r)(n) stands for shifting the prime factorization of n by r positions towards larger primes.
For all n >= 1, A276085(a(A276086(n))) = A276151(n).
(End)
Sum_{k=1..n} a(k) ~ c * n^2, where c = (1/2) * Sum_{k>=1} A005867(k-1)/(prime(k)*A002110(k)) = 0.165049... . - Amiram Eldar, Nov 19 2022
MAPLE
A032742 :=proc(n) option remember; if n = 1 then 1; else numtheory[divisors](n) minus {n} ; max(op(%)) ; end if; end proc: # R. J. Mathar, Jun 13 2011
1, seq(n/min(numtheory:-factorset(n)), n=2..1000); # Robert Israel, Dec 18 2014
MATHEMATICA
f[n_] := If[n == 1, 1, Divisors[n][[-2]]]; Table[f[n], {n, 100}] (* Vladimir Joseph Stephan Orlovsky, Mar 03 2010 *)
Join[{1}, Divisors[#][[-2]]&/@Range[2, 80]] (* Harvey P. Dale, Nov 29 2011 *)
a[n_] := n/FactorInteger[n][[1, 1]]; Array[a, 100] (* Amiram Eldar, Nov 26 2020 *)
Table[Which[n==1, 1, PrimeQ[n], 1, True, Divisors[n][[-2]]], {n, 80}] (* Harvey P. Dale, Feb 02 2022 *)
PROG
(PARI) a(n)=if(n==1, 1, n/factor(n)[1, 1]) \\ Charles R Greathouse IV, Jun 15 2011
(Haskell)
a032742 n = n `div` a020639 n -- Reinhard Zumkeller, Oct 03 2012
(Scheme) (define (A032742 n) (/ n (A020639 n))) ;; Antti Karttunen, Dec 18 2014
(Python)
from sympy import factorint
def a(n): return 1 if n == 1 else n//min(factorint(n))
print([a(n) for n in range(1, 81)]) # Michael S. Branicky, Jun 21 2022
CROSSREFS
Maximal GCD of k positive integers with sum n for k = 2..10: this sequence (k=2,n>=2), A355249 (k=3), A355319 (k=4), A355366 (k=5), A355368 (k=6), A355402 (k=7), A354598 (k=8), A354599 (k=9), A354601 (k=10).
KEYWORD
nonn,easy,nice,changed
AUTHOR
Patrick De Geest, May 15 1998
EXTENSIONS
Definition clarified by N. J. A. Sloane, Dec 26 2022
STATUS
approved
Numbers with at most 2 prime factors (counted with multiplicity).
+10
68
1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 13, 14, 15, 17, 19, 21, 22, 23, 25, 26, 29, 31, 33, 34, 35, 37, 38, 39, 41, 43, 46, 47, 49, 51, 53, 55, 57, 58, 59, 61, 62, 65, 67, 69, 71, 73, 74, 77, 79, 82, 83, 85, 86, 87, 89, 91, 93, 94, 95, 97, 101, 103, 106, 107, 109, 111, 113, 115, 118
OFFSET
1,2
COMMENTS
A001222(a(n)) <= 2; A054576(a(n)) = 1. - Reinhard Zumkeller, Mar 10 2006
Products of two noncomposite numbers. - Juri-Stepan Gerasimov, Apr 15 2010
Also, numbers with permutations of all divisors only with coprime adjacent elements: A109810(a(n)) > 0. - Reinhard Zumkeller, May 24 2010
A060278(a(n)) = 0. - Reinhard Zumkeller, Apr 05 2013
1 together with numbers k such that sigma(k) + phi(k) - d(k) = 2k - 2. - Wesley Ivan Hurt, May 03 2015
Products of two not necessarily distinct terms of A008578 (the same relation between A000040 and A001358). - Flávio V. Fernandes, May 28 2021
LINKS
Felix Fröhlich, Table of n, a(n) for n = 1..10000 (first 1000 terms from Reinhard Zumkeller)
Andreas Weingartner, Uniform distribution of alpha*n modulo one for a family of integer sequences, arXiv:2303.16819 [math.NT], 2023.
MAPLE
with(numtheory): A037143:=n->`if`(bigomega(n)<3, n, NULL): seq(A037143(n), n=1..200); # Wesley Ivan Hurt, May 03 2015
MATHEMATICA
Select[Range[120], PrimeOmega[#] <= 2 &] (* Ivan Neretin, Aug 16 2015 *)
PROG
(Haskell)
a037143 n = a037143_list !! (n-1)
a037143_list = 1 : merge a000040_list a001358_list where
merge xs'@(x:xs) ys'@(y:ys) =
if x < y then x : merge xs ys' else y : merge xs' ys
-- Reinhard Zumkeller, Dec 18 2012
(PARI) is(n)=bigomega(n)<3 \\ Charles R Greathouse IV, Apr 29 2015
(Python)
from math import isqrt
from sympy import primepi, primerange
def A037143(n):
def f(x): return int(n-2+x-primepi(x)-sum(primepi(x//k)-a for a, k in enumerate(primerange(isqrt(x)+1))))
kmin, kmax = 1, 2
while f(kmax) >= kmax:
kmax <<= 1
while True:
kmid = kmax+kmin>>1
if f(kmid) < kmid:
kmax = kmid
else:
kmin = kmid
if kmax-kmin <= 1:
break
return kmax # Chai Wah Wu, Aug 23 2024
CROSSREFS
Union of A008578 and A001358. Complement of A033942.
A101040(a(n))=1 for n>1.
Subsequence of A037144. - Reinhard Zumkeller, May 24 2010
A098962 and A139690 are subsequences.
KEYWORD
nonn
EXTENSIONS
More terms from Henry Bottomley, Aug 15 2001
STATUS
approved
Positive integers with at least 3 prime factors (counted with multiplicity).
+10
36
8, 12, 16, 18, 20, 24, 27, 28, 30, 32, 36, 40, 42, 44, 45, 48, 50, 52, 54, 56, 60, 63, 64, 66, 68, 70, 72, 75, 76, 78, 80, 81, 84, 88, 90, 92, 96, 98, 99, 100, 102, 104, 105, 108, 110, 112, 114, 116, 117, 120, 124, 125, 126, 128, 130, 132, 135, 136, 138, 140, 144
OFFSET
1,1
COMMENTS
A001055(a(n)) > 2; e.g., for a(3)=18 there are 4 factorizations: 1*18 = 2*9 = 2*3*3 = 3*6. - Reinhard Zumkeller, Dec 29 2001
A001222(a(n)) > 2; A054576(a(n)) > 1. - Reinhard Zumkeller, Mar 10 2006
Also numbers such that no permutation of all divisors exists with coprime adjacent elements: A109810(a(n))=0. - Reinhard Zumkeller, May 24 2010
A211110(a(n)) > 3. - Reinhard Zumkeller, Apr 02 2012
A060278(a(n)) > 0. - Reinhard Zumkeller, Apr 05 2013
Volumes of rectangular cuboids with each side > 1. - Peter Woodward, Jun 16 2015
If k is a term then so is k*m for m > 0. - David A. Corneth, Sep 30 2020
Numbers k with a pair of proper divisors of k, (d1,d2), such that d1 < d2 and gcd(d1,d2) > 1. - Wesley Ivan Hurt, Jan 01 2021
FORMULA
Numbers of the form Product p_i^e_i with Sum e_i >= 3.
a(n) ~ n. - Charles R Greathouse IV, May 04 2013
MAPLE
with(numtheory): A033942:=n->`if`(bigomega(n)>2, n, NULL): seq(A033942(n), n=1..200); # Wesley Ivan Hurt, Jun 23 2015
MATHEMATICA
Select[ Range[150], Plus @@ Last /@ FactorInteger[ # ] > 2 &] (* Robert G. Wilson v, Oct 12 2005 *)
Select[Range[150], PrimeOmega[#]>2&] (* Harvey P. Dale, Jun 22 2011 *)
PROG
(Haskell)
a033942 n = a033942_list !! (n-1)
a033942_list = filter ((> 2) . a001222) [1..]
-- Reinhard Zumkeller, Oct 27 2011
(PARI) is(n)=bigomega(n)>2 \\ Charles R Greathouse IV, May 04 2013
(Python)
from sympy import factorint
def ok(n): return sum(factorint(n).values()) > 2
print([k for k in range(145) if ok(k)]) # Michael S. Branicky, Sep 10 2022
(Python)
from math import isqrt
from sympy import primepi, primerange
def A033942(n):
def f(x): return int(n+primepi(x)+sum(primepi(x//k)-a for a, k in enumerate(primerange(isqrt(x)+1))))
kmin, kmax = 1, 2
while f(kmax) >= kmax:
kmax <<= 1
while True:
kmid = kmax+kmin>>1
if f(kmid) < kmid:
kmax = kmid
else:
kmin = kmid
if kmax-kmin <= 1:
break
return kmax # Chai Wah Wu, Aug 23 2024
CROSSREFS
Cf. A014612.
A101040(a(n))=0.
A033987 is a subsequence; complement of A037143. - Reinhard Zumkeller, May 24 2010
Subsequence of A080257.
See also A002808 for 'Composite numbers' or 'Divisible by at least 2 primes'.
KEYWORD
nonn
AUTHOR
EXTENSIONS
Corrected by Patrick De Geest, Jun 15 1998
STATUS
approved
Number of occurrences of n-th prime in A065308, where A065308(j) = prime(j - pi(j)).
+10
27
3, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 1, 1, 2, 2, 1, 1, 2, 1, 1, 1, 1, 2, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 1, 1, 2, 2, 1, 1, 1, 1, 2, 1, 1, 2, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 2, 1, 1, 1, 1, 2, 2
OFFSET
1,1
COMMENTS
Seems identical to A054546. Each odd prime arises once or twice!?
First differences of A018252 (positive nonprime numbers). Including 0 gives A054546. Removing 1 gives A073783. - Gus Wiseman, Sep 15 2024
LINKS
MATHEMATICA
t=Table[Prime[w-PrimePi[w]], {w, a, b}] Table[Count[t, Prime[n]], {n, c, d}]
Differences[Select[Range[100], !PrimeQ[#]&]] (* Gus Wiseman, Sep 15 2024 *)
PROG
(PARI) { p=1; f=2; m=1; for (n=1, 1000, a=0; p=nextprime(p + 1); while (p==f, a++; m++; f=prime(m - primepi(m))); write("b065310.txt", n, " ", a) ) } \\ Harry J. Smith, Oct 16 2009
CROSSREFS
For twin 2's see A169643.
Positions of 1's are A375926, complement A014689 (except first term).
Other families of numbers and their first-differences:
For prime numbers (A000040) we have A001223.
For composite numbers (A002808) we have A073783.
For nonprime numbers (A018252) we have A065310 (this).
For perfect powers (A001597) we have A053289.
For non-perfect-powers (A007916) we have A375706.
For squarefree numbers (A005117) we have A076259.
For nonsquarefree numbers (A013929) we have A078147.
For prime-powers inclusive (A000961) we have A057820.
For prime-powers exclusive (A246655) we have A057820(>1).
For non-prime-powers inclusive (A024619) we have A375735.
For non-prime-powers exclusive (A361102) we have A375708.
KEYWORD
nonn
AUTHOR
Labos Elemer, Oct 29 2001
STATUS
approved
Smallest prime factor of greatest proper divisor of n.
+10
17
1, 1, 1, 2, 1, 3, 1, 2, 3, 5, 1, 2, 1, 7, 5, 2, 1, 3, 1, 2, 7, 11, 1, 2, 5, 13, 3, 2, 1, 3, 1, 2, 11, 17, 7, 2, 1, 19, 13, 2, 1, 3, 1, 2, 3, 23, 1, 2, 7, 5, 17, 2, 1, 3, 11, 2, 19, 29, 1, 2, 1, 31, 3, 2, 13, 3, 1, 2, 23, 5, 1, 2, 1, 37, 5, 2, 11, 3, 1, 2, 3, 41, 1, 2, 17, 43, 29, 2, 1, 3, 13, 2, 31, 47
OFFSET
1,4
COMMENTS
For n > 1: a(n) = 1 iff n is prime; a(A001358(n)) = A084127(n); a(A025475(n)) = A020639(A025475(n)). [corrected by Peter Munn, Feb 19 2017]
When n is composite, this is the 2nd factor when n is written as a product of primes in nondecreasing order. For example, 12 = 2*2*3, so a(12) = 2. - Peter Munn, Feb 19 2017
For all sufficiently large n the median value of a(1), a(2), ... a(n) is A281889(2) = 7. - Peter Munn, Jul 12 2019
LINKS
FORMULA
a(n) = A020639(A032742(n)).
A117357(n) = A020639(A054576(n)); A117358(n) = A032742(A054576(n)) = A054576(n)/A117357(n). - Reinhard Zumkeller, Mar 10 2006
If A001222(n) >= 2, a(n) = A027746(n,2), otherwise a(n) = 1. - Peter Munn, Jul 13 2019
MATHEMATICA
PrimeFactors[ n_ ] := Flatten[ Table[ # [ [ 1 ] ], {1} ] & /@ FactorInteger[ n ] ]; f[ n_ ] := Block[ {gpd = Divisors[ n ][ [ -2 ] ]}, If[ gpd == 1, 1, PrimeFactors[ gpd ][ [ 1 ] ] ] ]; Table[ If[ n == 1, 1, f[ n ] ], {n, 1, 95} ]
(* Second program: *)
Table[If[Or[PrimeQ@ n, n == 1], 1, FactorInteger[n/SelectFirst[Prime@ Range@ PrimePi[Sqrt@ n], Divisible[n, #] &]][[1, 1]] ], {n, 94}] (* Michael De Vlieger, Aug 14 2017 *)
PROG
(PARI) lpf(n)=if(n>1, factor(n)[1, 1], 1)
a(n)=lpf(n/lpf(n)) \\ Charles R Greathouse IV, May 09 2013
(PARI) a(n)=if(n<4||isprime(n), return(1)); my(f=factor(n)); if(f[1, 2]>1, f[1, 1], f[2, 1]) \\ Charles R Greathouse IV, May 09 2013
(Scheme) (define (A014673 n) (A020639 (/ n (A020639 n)))) ;; Code for A020639 given under that entry - Antti Karttunen, Aug 12 2017
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Jun 24 2003
STATUS
approved
a(n) = A032742(A032742(A032742(n))) = ((n/lpf(n))/lpf(n/lpf(n)))/lpf((n/lpf(n))/lpf(n/lpf(n))), where lpf=A020639, least prime factor.
+10
7
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 3, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 6, 1, 1, 1, 1, 1, 3, 1, 7, 1, 1, 1, 5, 1, 1, 1, 8, 1, 1, 1, 1, 1, 1, 1, 9, 1, 1, 1, 1, 1, 1, 1, 10, 3, 1, 1, 7, 1, 1, 1, 11, 1, 5, 1, 1, 1, 1, 1, 12, 1, 1, 1, 5, 1, 1, 1
OFFSET
1,16
LINKS
Eric Weisstein's World of Mathematics, Least Prime Factor
FORMULA
a(n) = A032742(A032742(A032742(n))) = A032742(A054576(n)) = A054576(n)/A115561(n).
a(A037144(n)) = 1, a(A033987(n)) > 1.
MATHEMATICA
f[n_] := n/FactorInteger[n][[1, 1]]; (* f is A032742 *)
a[n_] := f@ f@ f@ n;
Array[a, 100] (* Jean-François Alcover, Dec 09 2021 *)
Table[Nest[#/FactorInteger[#][[1, 1]]&, n, 3], {n, 110}] (* Harvey P. Dale, Oct 10 2024 *)
PROG
(Scheme) (define (A117358 n) (A032742 (A032742 (A032742 n)))) ;; Antti Karttunen, Dec 07 2017
KEYWORD
nonn,changed
AUTHOR
Reinhard Zumkeller, Mar 10 2006
STATUS
approved

Search completed in 0.012 seconds