login
Search: author:"arran fernandez"
     Sort: relevance | references | number | modified | created      Format: long | short | data
Smallest of the most frequently occurring numbers in 1-to-n multiplication table.
+0
10
1, 2, 2, 4, 4, 6, 6, 6, 6, 6, 6, 12, 12, 12, 12, 12, 12, 36, 36, 60, 60, 60, 60, 24, 24, 24, 24, 24, 24, 60, 60, 60, 60, 60, 60, 60, 60, 60, 60, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120
OFFSET
1,2
LINKS
Branden Aldridge, Table of n, a(n) for n = 1..20000 (terms 1..1000 from Reinhard Zumkeller, terms 1001..10000 from Reinhard Zumkeller and Charles R Greathouse IV)
Benjamin Dickman, What number appears most often in an n X n multiplication table?, Mathematics StackExchange, May 2014.
EXAMPLE
M(n) is the array in which m(x,y)= x*y for x = 1 to n and y = 1 to n. In m(10), the most frequently occurring numbers are 6, 8, 10, 12, 18, 20, 24, 30,40, each occurring 4 times. The smallest of these numbers is 6, so a(10) = 6.
PROG
(Haskell)
import Data.List (sort, group, sortBy, groupBy)
import Data.Function (on)
a057144 n = head $ last $ head $ groupBy ((==) `on` length) $
reverse $ sortBy (compare `on` length) $
group $ sort [u * v | u <- [1..n], v <- [1..n]]
-- Reinhard Zumkeller, Jun 22 2013
(PARI) T(n, f=factor(n))=my(k=#f~); f[, 1]=primes(k+1)[2..k+1]~; f[1, 1]=6; factorback(f)
listA025487(Nmax)=vecsort(concat(vector(logint(Nmax, 2), n, select(t->t<=Nmax, if(n>1, [factorback(primes(#p), Vecrev(p))|p<-partitions(n)], [1, 2])))))
ct(n, k)=sumdiv(n, d, max(d, n/d)<=k)
a(n)=if(n==1, return(1)); my(v=listA025487(n^2), r, t, at); for(i=1, #v, t=ct(v[i], n); if(t>r, r=t; at=v[i])); at \\ Charles R Greathouse IV, Feb 05 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
_Arran Fernandez_, Aug 13 2000
EXTENSIONS
More terms from Larry Reeves (larryr(AT)acm.org), Apr 18 2001
STATUS
approved
Occurrences of most frequently occurring number in 1-to-n multiplication table.
+0
8
1, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4, 6, 6, 6, 6, 6, 6, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 16, 16, 16, 16, 16, 16, 16, 16
OFFSET
1,2
LINKS
Branden Aldridge, Table of n, a(n) for n = 1..20000 (terms 1..1000 from Reinhard Zumkeller, terms 1001..10000 from Reinhard Zumkeller and Charles R Greathouse IV).
EXAMPLE
M(n) is the array in which m(x,y)= x*y for x = 1 to n and y = 1 to n. In m(5), the most frequently occurring number is 4. It occurs 3 times, so a(5) = 3.
PROG
(Haskell)
import Data.List (group, sort)
a057142 n = head $ reverse $ sort $ map length $ group $
sort [u * v | u <- [1..n], v <- [1..n]]
-- Reinhard Zumkeller, Jun 22 2013
(PARI) T(n, f=factor(n))=my(k=#f~); f[, 1]=primes(k+1)[2..k+1]~; f[1, 1]=6; factorback(f)
listA025487(Nmax)=vecsort(concat(vector(logint(Nmax, 2), n, select(t->t<=Nmax, if(n>1, [factorback(primes(#p), Vecrev(p))|p<-partitions(n)], [1, 2])))))
ct(n, k)=sumdiv(n, d, max(d, n/d)<=k)
a(n)=if(n==1, return(1)); my(v=listA025487(n^2), r, t); for(i=1, #v, t=ct(v[i], n); if(t>r, r=t)); r \\ Charles R Greathouse IV, Feb 05 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
_Arran Fernandez_, Aug 13 2000
EXTENSIONS
More terms from Larry Reeves (larryr(AT)acm.org), Apr 18 2001
STATUS
approved
Largest of the most frequently occurring numbers in 1-to-n multiplication table.
+0
7
1, 2, 6, 4, 4, 12, 12, 24, 24, 40, 40, 24, 24, 24, 60, 60, 60, 36, 36, 60, 60, 60, 60, 120, 120, 120, 120, 168, 168, 120, 120, 120, 120, 120, 120, 180, 180, 180, 180, 120, 120, 120, 120, 120, 360, 360, 360, 360, 360, 360, 360, 360, 360, 360, 360, 360, 360, 360
OFFSET
1,2
LINKS
Branden Aldridge, Table of n, a(n) for n = 1..20000 (first 1000 terms from Reinhard Zumkeller).
EXAMPLE
M(n) is the array in which m(x,y)= x*y for x = 1 to n and y = 1 to n. In M(10), the most frequently occurring numbers are 6, 8, 10, 12, 18, 20, 24, 30,40, each occurring 4 times. The largest of these numbers is 40, so a(10) = 40.
PROG
(Haskell)
import Data.List (group, sort, sortBy)
import Data.Function (on)
a057143 n = head $ head $ reverse $ sortBy (compare `on` length) $
group $ sort [u * v | u <- [1..n], v <- [1..n]]
-- Reinhard Zumkeller, Jun 22 2013
CROSSREFS
KEYWORD
nonn
AUTHOR
_Arran Fernandez_, Aug 13 2000
EXTENSIONS
More terms from Larry Reeves (larryr(AT)acm.org), Apr 18 2001
STATUS
approved
Omega(6n-1) + Omega(6n+1).
+0
3
2, 2, 2, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 3, 3, 2, 2, 3, 4, 4, 3, 2, 4, 2, 3, 3, 3, 4, 2, 4, 2, 2, 4, 3, 4, 3, 2, 3, 2, 5, 3, 3, 3, 2, 4, 2, 4, 3, 4, 3, 2, 3, 5, 3, 3, 5, 2, 3, 3, 3, 3, 3, 4, 3, 3, 3, 3, 4, 2, 5, 2, 3, 3, 3, 4, 2, 3, 5, 3, 3, 3, 3, 3, 3
OFFSET
1,1
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
FORMULA
a(n) = A001222(6n-1) + A001222(6n+1). - Michel Marcus, Sep 04 2013
EXAMPLE
For n=1, Omega(6n-1) + Omega(6n+1) = Omega(5) + Omega(7) = 1+1 = 2, so a(1)=2.
MATHEMATICA
For[x=6, x<601, x+=6, S=0; T=0; For[k=1, k< Length[FactorInteger[x-1]]+1, k++, S+= FactorInteger[x-1][[k]][[2]]]; For[m=1, m<Length[FactorInteger[x+1]]+1, m++, T+= FactorInteger[x+1][[m]][[2]]]; Print[x/6, " ", S+T]]
Table[Total[PrimeOmega/@(6n+{1, -1})], {n, 60}] (* Harvey P. Dale, May 22 2013 *)
PROG
(PARI) a(n) = bigomega(6*n-1) + bigomega(6*n+1); \\ Michel Marcus, Sep 04 2013
CROSSREFS
Cf. A145194.
KEYWORD
nonn,easy
AUTHOR
_Arran Fernandez_, Oct 03 2008
EXTENSIONS
More terms from Michel Marcus, Sep 04 2013
STATUS
approved
a(n) = a(n-1) + a(n-4); first four terms are 0,1,2,3.
+0
2
0, 1, 2, 3, 3, 4, 6, 9, 12, 16, 22, 31, 43, 59, 81, 112, 155, 214, 295, 407, 562, 776, 1071, 1478, 2040, 2816, 3887, 5365, 7405, 10221, 14108, 19473, 26878, 37099, 51207, 70680, 97558, 134657, 185864, 256544, 354102, 488759, 674623, 931167, 1285269
OFFSET
0,3
FORMULA
a(n) = a(n-1) + a(n-4); a(0)=0, a(1)=1, a(2)=2, a(3)=3
a(n+1)=sum{k=0..n, binomial(n-k, floor(k/3))} - Paul Barry, Jul 06 2004
G.f.: x(1+x+x^2)/(1-x-x^4). a(n)=A003269(n)+A003269(n-1)+A003269(n-2). [From R. J. Mathar, Nov 25 2008]
EXAMPLE
The sequence begins 0,1,2,3. a(5) = a(5-1) + a(5-4) = a(4)+a(1)= 3+0 =3. a(6) = a(6-1) + a(6-4) = a(5) + a(2) = 3+1 = 4.
MATHEMATICA
LinearRecurrence[{1, 0, 0, 1}, {0, 1, 2, 3}, 50] (* Harvey P. Dale, Oct 08 2012 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
_Arran Fernandez_, Jan 02 2003
STATUS
approved
Integers n for which Omega(6n-1)>2 and Omega(6n+1)>2
+0
1
141, 421, 479, 596, 629, 746, 801, 804, 904, 966, 981, 1016, 1042, 1051, 1119, 1121, 1142, 1146, 1154, 1261, 1289, 1296, 1324, 1329, 1384, 1399, 1406, 1454, 1471, 1493, 1499, 1560, 1576, 1597, 1637, 1646
OFFSET
1,1
LINKS
EXAMPLE
(6*141)-1 = 845, which has >2 prime factors (counted with multiplicity), namely 5,13 and 13. (6*141)+1 = 847, which has >2 prime factors (counted with multiplicity), namely 7,11 and 11. So 141 is in the sequence.
MATHEMATICA
For[x = 6, x < 10001, x += 6, If[PrimeQ[x - 1] == True, y = "P", S = 0; F = FactorInteger[x - 1]; For[k = 1, k < Length[F] + 1, k++, S += F[[k]][[2]]]; If[S == 2, y = "A", y = "N"]]; If[PrimeQ[x + 1] == True, z = "P", S = 0; F = FactorInteger[x + 1]; For[k = 1, k < Length[F] + 1, k++, S += F[[k]][[2]]]; If[S == 2, z = "A", z = "N"]]; If[y == "N" && z == "N", Print[x/6]]]
Select[Range[2000], PrimeOmega[6#+1]>2&&PrimeOmega[6#-1]>2&] (* Harvey P. Dale, Apr 26 2016 *)
CROSSREFS
Cf. A001222.
KEYWORD
nonn
AUTHOR
_Arran Fernandez_, Oct 03 2008
STATUS
approved
Least k for which Omega(6k-1) + Omega(6k+1) >= n.
+0
1
1, 1, 4, 20, 41, 104, 479, 1146, 7603, 16521, 91146, 188021, 188021, 1861979, 14122396, 43294271, 203450521, 203450521, 5877278646, 5900065104, 16886393229
OFFSET
1,3
COMMENTS
a(22) <= 170499674479. a(23) <= 1307169596354. a(24) <= 3178914388021. a(25) <= 3178914388021. a(26) <= 43614705403646 [From Donovan Johnson, Feb 17 2010]
EXAMPLE
When k=1,2 and 3, Omega(6k-1) + Omega(6k+1) = 2. When k=4, Omega(6k-1) + Omega(6k+1) = 3, so a(3)=4.
MATHEMATICA
Maxie=0; For[x=6, x<10000001, x+=6, S=0; T=0; For[k=1, k< Length[FactorInteger[x-1]]+1, k++, S+= FactorInteger[x-1][[k]][[2]]]; For[m=1, m< Length[FactorInteger[x+1]]+1, m++, T+= FactorInteger[x+1][[m]][[2]]]; If[S+T>Maxie, Print[x/6, " ", S+T]; Maxie=S+T]]
CROSSREFS
KEYWORD
nonn
AUTHOR
_Arran Fernandez_, Oct 03 2008
EXTENSIONS
a(15)-a(21) from Donovan Johnson, Feb 17 2010
STATUS
approved
Continued fraction expansion of the smallest positive solution of Gamma(-x)=Gamma(-2x)
+0
0
0, 2, 1, 50, 3, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 3, 2, 1, 34, 1, 4, 1, 1, 6, 2, 3, 6, 3, 43, 1, 1, 1, 5, 1, 1, 2, 2, 1, 1, 1, 3, 1, 15, 3, 2, 3, 5, 5, 1, 8, 1, 5, 1, 3, 2, 1, 2, 1, 1, 1, 1, 42, 3, 6, 12, 1, 2, 4, 8, 1, 7, 2, 1, 2, 3, 1, 154, 1, 1, 1, 1, 11, 1, 4, 3, 1, 8, 5, 2, 3, 2
OFFSET
0,2
EXAMPLE
0.335514419... = 0+1/(2+1/(1+...))
MATHEMATICA
ContinuedFraction[FindRoot[Gamma[-x] - Gamma[-2x] == 0, {x, 0.3}, WorkingPrecision -> 100]]
PROG
(PARI) contfrac(solve(x=.3, .4, gamma(-x)-gamma(-2*x))) \\ Charles R Greathouse IV, Jul 26 2013
KEYWORD
nonn,cofr
AUTHOR
_Arran Fernandez_, Jul 26 2013
STATUS
approved

Search completed in 0.013 seconds