A273015 Ramanujan's largely composite numbers having 3 as the greatest prime divisor.
3, 6, 12, 18, 24, 36, 48, 72, 96, 108
Offset: 1
A355532 Maximal augmented difference between adjacent reversed prime indices of n; a(1) = 0.
0, 1, 2, 1, 3, 2, 4, 1, 2, 3, 5, 2, 6, 4, 2, 1, 7, 2, 8, 3, 3, 5, 9, 2, 3, 6, 2, 4, 10, 2, 11, 1, 4, 7, 3, 2, 12, 8, 5, 3, 13, 3, 14, 5, 2, 9, 15, 2, 4, 3, 6, 6, 16, 2, 3, 4, 7, 10, 17, 2, 18, 11, 3, 1, 4, 4, 19, 7, 8, 3, 20, 2, 21, 12, 2, 8, 4, 5, 22, 3, 2
Offset: 1
Keywords
Comments
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.
The augmented differences aug(q) of a (usually weakly decreasing) sequence q of length k are given by aug(q)i = q_i - q{i+1} + 1 if i < k and aug(q)_k = q_k. For example, we have aug(6,5,5,3,3,3) = (2,1,3,1,1,3).
Examples
The reversed prime indices of 825 are (5,3,3,2), with augmented differences (3,1,2,2), so a(825) = 3.
Links
Crossrefs
Programs
-
Mathematica
primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]]; aug[y_]:=Table[If[i
A086761 Numbers k such that k-th cyclotomic polynomial has exactly 5 nonzero terms.
5, 10, 20, 25, 40, 50, 80, 100, 125, 160, 200, 250, 320, 400, 500, 625, 640, 800, 1000, 1250, 1280, 1600, 2000, 2500, 2560, 3125, 3200, 4000, 5000, 5120, 6250, 6400, 8000, 10000, 10240, 12500, 12800, 15625, 16000, 20000, 20480, 25000, 25600, 31250, 32000
Offset: 1
Keywords
Comments
A206787(a(n)) = 6. - Reinhard Zumkeller, Feb 12 2012
All terms have the form 2^a 5^b with a >= 0 and b > 0. - T. D. Noe, Feb 13 2012
If the above holds for all terms then this sequence is 5 * A003592. - David A. Corneth, Jul 04 2018
Programs
-
Mathematica
Select[Range[1000], Count[CoefficientList[Cyclotomic[#, x], x], 0] == EulerPhi[#] - 4 &] (* T. D. Noe, Feb 13 2012 *)
-
PARI
is(n) = v = Vec(polcyclo(n)); sum(i=1,#v,v[i]!=0) == 5 \\ David A. Corneth, Jul 04 2018
Extensions
More terms from T. D. Noe, Feb 13 2012
A301461 Number of integers less than or equal to n whose largest prime factor is 3.
0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11
Offset: 0
Keywords
Comments
a(n) increases when n has the form 2^a*3^b, with a >= 0 and b > 0.
A distinct sequence can be generated for each prime number; this sequence is for the prime number 3. For an example using another prime number see A301506.
Examples
a(12) = a(2^2 * 3^1); 3 is the largest prime factor, so a(12) exceeds the previous term by 1. For a(13), 13 is a prime, so there is no increase from the previous term.
Programs
-
MATLAB
clear;clc; prime = 3; limit = 10000; largest_divisor = ones(1,limit+1); for k = 0:limit f = factor(k); largest_divisor(k+1) = f(end); end for i = 1:limit+1 FQN(i) = sum(largest_divisor(1:i)==prime); end output = [0:limit;FQN]'
-
Mathematica
Accumulate@ Array[Boole[FactorInteger[#][[-1, 1]] == 3] &, 80, 0] (* Michael De Vlieger, Apr 21 2018 *)
-
PARI
gpf(n) = if (n<=1, n, vecmax(factor(n)[,1])); a(n) = sum(k=1, n, gpf(k)==3); \\ Michel Marcus, Mar 27 2018
Formula
From David A. Corneth, Mar 27 2018: (Start)
a(n) - a(n - 1) = 1 if and only if n is in 3 * A003586. If n isn't in that sequence then a(n) = a(n - 1).
a(3 * n + b) = A071521(n), n > 0, 0 <= b < 3. (End)
A382487 The number of divisors of n whose largest prime factor is 3.
0, 0, 1, 0, 0, 2, 0, 0, 2, 0, 0, 3, 0, 0, 1, 0, 0, 4, 0, 0, 1, 0, 0, 4, 0, 0, 3, 0, 0, 2, 0, 0, 1, 0, 0, 6, 0, 0, 1, 0, 0, 2, 0, 0, 2, 0, 0, 5, 0, 0, 1, 0, 0, 6, 0, 0, 1, 0, 0, 3, 0, 0, 2, 0, 0, 2, 0, 0, 1, 0, 0, 8, 0, 0, 1, 0, 0, 2, 0, 0, 4, 0, 0, 3, 0, 0, 1
Offset: 1
Comments
The number of 3-smooth divisors of n that are not powers of 2.
The number of terms of A065119 that divide n.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
a[n_] := (IntegerExponent[n, 2] + 1) * IntegerExponent[n, 3]; Array[a, 100]
-
PARI
a(n) = (valuation(n, 2) + 1) * valuation(n, 3);
Formula
a(n) = 0 if and only if n is in A001651.
a(n) = 1 if and only if n is in A306771.
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = 1.
In general, the asymptotic mean of the number prime(k+1)-smooth divisors of n that are not prime(k)-smooth, for k >= 1, is (1/(prime(k+1)-1)) * Product_{i=1..k} (prime(i)/(prime(i)-1)).
Dirichlet g.f.: (zeta(s)/(1-1/2^s))*(1/(1-1/3^s) - 1).
A085459 Numbers k such that k-th cyclotomic polynomial has exactly 3 positive coefficients.
3, 9, 10, 20, 27, 40, 50, 80, 81, 100, 160, 200, 243, 250, 320, 400, 500, 640, 729, 800, 1000, 1250, 1280, 1600, 2000, 2187, 2500, 2560, 3200, 4000, 5000, 5120, 6250, 6400, 6561, 8000, 10000, 10240, 12500, 12800, 16000, 19683, 20000, 20480, 25000, 25600
Offset: 1
Comments
Sequence appears to consist of 3^i, i > 0; and 2^i*5^j, i, j > 0. Are there any other terms? - David Wasserman, Feb 01 2005
Examples
9 is a member because the 9th cyclotomic polynomial is P(x) = x^6+x^3+1.
Programs
-
Mathematica
Select[Range@ 5000, Count[CoefficientList[Cyclotomic[#, x], x], ?(# > 0 &)] == 3 &] (* _Michael De Vlieger, Oct 26 2017 *)
-
PARI
n = 0; while (1, n++; p = polcyclo(n, x); d = poldegree(p); c = 0; i = 0; while (c < 4 && i <= d, if (polcoeff(p, i) > 0, c++); i++); if (c == 3, print(n))); \\ David Wasserman, Feb 01 2005
Extensions
More terms from David Wasserman, Feb 01 2005
A280990 Least prime p such that n divides phi(p*n).
2, 2, 3, 2, 5, 3, 7, 2, 3, 5, 11, 3, 13, 7, 31, 2, 17, 3, 19, 5, 7, 11, 23, 3, 5, 13, 3, 7, 29, 31, 31, 2, 67, 17, 71, 3, 37, 19, 13, 5, 41, 7, 43, 11, 31, 23, 47, 3, 7, 5, 103, 13, 53, 3, 11, 7, 19, 29, 59, 31, 61, 31, 7, 2, 131, 67, 67, 17, 139, 71, 71, 3, 73, 37, 31, 19, 463
Offset: 1
Keywords
Comments
n*a(n) are 2, 4, 9, 8, 25, 18, 49, 16, 27, 50, 121, 36, 169, 98, 465, 32, 289, ...
a(n) <= A034694(A007947(n)). If n is in A050384 then a(n) = A034694(n). - Robert Israel, Jan 12 2017
Examples
a(15) = 31 because 15 does not divide phi(p*15) for p < 31 where p is prime and phi(31*15) = 2*4*30 is divisible by 15.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Crossrefs
Programs
-
Maple
f:= proc(n) local p; p:= 2; while numtheory:-phi(p*n) mod n <> 0 do p:= nextprime(p) od: p end proc: map(f, [$1..100]); # Robert Israel, Jan 12 2017
-
Mathematica
lpp[n_]:=Module[{p=2},While[Mod[EulerPhi[p*n],n]!=0,p=NextPrime[p]];p]; Array[lpp,80] (* Harvey P. Dale, Sep 26 2020 *)
-
PARI
a(n)=my(k = 1); while (eulerphi(prime(k)*n) % n != 0, k++); prime(k);
-
PARI
a(n)=my(t=n/gcd(eulerphi(n),n)); if(t==1, return(2)); forstep(p=if(t%2,2*t,t)+1, if(isprime(t), t, oo),lcm(t,2), if(isprime(p), return(p))); t \\ Charles R Greathouse IV, Jan 20 2017
Formula
a(p^k) = p for all primes p and k >= 1. - Robert Israel, Jan 12 2017
a(n) << n^5 by Xylouris' improvement to Linnik's theorem. - Charles R Greathouse IV, Jan 20 2017
A369209 Numbers whose number of divisors has the largest prime factor 3.
4, 9, 12, 18, 20, 25, 28, 32, 36, 44, 45, 49, 50, 52, 60, 63, 68, 72, 75, 76, 84, 90, 92, 96, 98, 99, 100, 108, 116, 117, 121, 124, 126, 132, 140, 147, 148, 150, 153, 156, 160, 164, 169, 171, 172, 175, 180, 188, 196, 198, 200, 204, 207, 212, 220, 224, 225, 228
Offset: 1
Comments
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Crossrefs
Programs
-
Mathematica
gpf[n_] := FactorInteger[n][[-1, 1]]; Select[Range[300], gpf[DivisorSigma[0, #]] == 3 &]
-
PARI
gpf(n) = if(n == 1, 1, vecmax(factor(n)[, 1])); is(n) = gpf(numdiv(n)) == 3;
A384184 Order of the permutation of {0,...,n-1} formed by successively swapping elements at i and 2*i mod n, for i = 0,...,n-1.
1, 2, 1, 4, 2, 2, 2, 8, 3, 4, 5, 4, 6, 4, 6, 16, 4, 6, 9, 8, 4, 10, 28, 8, 10, 12, 9, 8, 14, 12, 12, 32, 5, 8, 70, 12, 18, 18, 24, 16, 10, 8, 7, 20, 210, 56, 126, 16, 110, 20, 60, 24, 26, 18, 120, 16, 9, 28, 29, 24, 30, 24, 60, 64, 6, 10, 33, 16
Offset: 1
Keywords
Comments
a(2*n) = 2*a(n) since the cycle lengths of the permutation with size 2*n is effectively that of size n twice, doubled. Thus, the LCM/order is doubled.
Examples
For n = 11, the permutation is {0,3,4,7,8,1,2,9,10,5,6} and it has order a(11) = 5.
Links
- Mia Boudreau, Table of n, a(n) for n = 1..10000
- Mia Boudreau, Java program, GitHub
Crossrefs
Programs
-
Python
from sympy.combinatorics import Permutation def a(n): L = list(range(n)) for i in range(n): if (j:= (i << 1) % n) != i: L[i],L[j] = L[j],L[i] return Permutation(L).order() # DarĂo Clavijo, Jun 05 2025
Formula
a(2*n) = 2*a(n).
a(2^n) = 2^n.
Conjecture: a(2^n + 2^x) = 2^n * (x-n) if x > n.
a(2^n - 1) = A003418(n-1).
s(2^n + 1) = A000027(n).
a(2*n - 1) = A051732(n).
a(A004626(n)) % 2 = 1.
a(A065119(n)) = n/3.
a(A001122(n)) = (n-1) / 2.
a(A155072(n)) = (n-1) / 4.
a(A001133(n)) = (n-1) / 6.
a(A001134(n)) = (n-1) / 8.
a(A001135(n)) = (n-1) / 10.
a(A225759(n)) = (n-1) / 16.
A367412 Triangle read by rows with all zeros removed where T(n,k) is the number of integer partitions of n with k different semi-sums.
1, 1, 1, 1, 2, 1, 3, 1, 1, 3, 3, 1, 5, 3, 2, 1, 4, 7, 2, 1, 1, 6, 7, 6, 2, 1, 6, 10, 6, 7, 1, 7, 12, 11, 8, 3, 1, 6, 16, 11, 17, 3, 2, 1, 10, 14, 20, 19, 10, 2, 1, 1, 7, 22, 17, 31, 14, 7, 2, 1, 9, 22, 27, 37, 22, 11, 6, 1, 10, 24, 27, 51, 32, 16, 15
Offset: 0
Comments
We define a semi-sum of a multiset to be any sum of a 2-element submultiset. This is different from sums of pairs of elements. For example, 2 is the sum of a pair of elements of {1}, but there are no semi-sums.
Examples
Triangle begins: 1 1 1 1 2 1 3 1 1 3 3 1 5 3 2 1 4 7 2 1 1 6 7 6 2 1 6 10 6 7 1 7 12 11 8 3 1 6 16 11 17 3 2 1 10 14 20 19 10 2 1 1 7 22 17 31 14 7 2 1 9 22 27 37 22 11 6 1 10 24 27 51 32 16 15 1 11 27 39 57 43 27 22 4 1 9 33 34 79 57 36 39 7 2 1 13 31 51 86 77 45 62 14 4 1 Row n = 9 counts the following partitions: (9) (81) (711) (621) (5211) (72) (6111) (531) (4311) (63) (522) (432) (4221) (54) (51111) (33111) (42111) (333) (441) (222111) (3321) (111111111) (411111) (2211111) (32211) (3222) (321111) (3111111) (22221) (21111111)
Crossrefs
Programs
-
Mathematica
DeleteCases[Table[Length[Select[IntegerPartitions[n], Length[Union[Total/@Subsets[#, {2}]]]==k&]], {n,10},{k,0,n}],0,2]
Comments
Crossrefs
Programs
Mathematica