Thursday, May 16, 2024

 200

In one week, I had a triple  experience with the number 200: I made my 200th post to my math blog ( https://jamesmacmath.blogspot.com), donated my 200th  blood product, and made my 200th contribution to the On-Line Encyclopedia of Integer Sequences OEIS-(https://oeis.org/search?q=James+C.+McMahon+&sort=created&go=Search ).


Thursday, May 9, 2024

Unification of Different Fields of Mathematics

(Image: https://www.iconfinder.com/roywj)


During WWII, AndrĂ© Weil proposed an idea for linking three fields of mathematics: number theory, geometry, and finite fields.

For the full story, please see the following link it Quanta Magazine's  article describing the unification of three major branches of mathematics: A Rosetta Stone of Mathematics. 

Also related, is the work begun by Robert Langlands, known as the Langlands program.

A371030 Contribution to the OEIS

 

A371030n written in compositorial base.0
0, 1, 2, 3, 10, 11, 12, 13, 20, 21, 22, 23, 30, 31, 32, 33, 40, 41, 42, 43, 50, 51, 52, 53, 100, 101, 102, 103, 110, 111, 112, 113, 120, 121, 122, 123, 130, 131, 132, 133, 140, 141, 142, 143, 150, 151, 152, 153, 200, 201, 202, 203, 210, 211, 212, 213 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
0,3
COMMENTS
Compositorial base is a mixed-radix representation using the composite numbers (A002808) from least to most significant.
Places reading from right have values (1, 4, 24, 192, ...) = compositorial numbers (A036691).
a(n) = concatenation of decimal digits of n in compositorial base. This concatenated representation is unsatisfactory for large n (above 172799), when coefficients of 10 or greater start to appear.
LINKS
EXAMPLE
a(35)=123; 35 = 1*24 + 2*4 + 3*1.
MATHEMATICA
Table[FromDigits@ IntegerDigits[n, MixedRadix[Reverse@ ResourceFunction["Composite"]@ Range@ 8]], {n, 0, 55}]
CROSSREFS
Sequence in context: A301382 A288657 A055655 * A276326 A007090 A102859
KEYWORD
nonn,base,less
AUTHOR
James C. McMahon, Mar 08 2024
STATUS
approved

A370831 Contribution to the OEIS

 

A370831Alternating sum of composites.0
4, 2, 6, 3, 7, 5, 9, 6, 10, 8, 12, 9, 13, 11, 14, 12, 15, 13, 17, 15, 18, 16, 19, 17, 21, 18, 22, 20, 24, 21, 25, 23, 26, 24, 27, 25, 29, 26, 30, 27, 31, 29, 33, 30, 34, 31, 35, 33, 36, 34, 38, 36, 39, 37, 40, 38, 42, 39, 43, 41, 44, 42, 45, 43, 47, 44, 48, 45, 49, 46 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,1
COMMENTS
Unlike equivalent sequence for primes, A008347, there are repeated terms.
LINKS
FORMULA
a(n) = A002808(n) - a(n-1), for n>1.
EXAMPLE
a(4) = 9 - 8 + 6 - 4 = 3.
MATHEMATICA
Join[{4}, a[1]=4; a[n_]:=ResourceFunction["Composite"][n] - a[n-1]; Table[a[n], {n, 2, 70}]] (* or with signs *) R=70; a[1]=4; a[n_]:=a[n-1]-ResourceFunction["Composite"][n] *(-1)^n; Table[a[n], {n, 70}]
CROSSREFS
Sequence in context: A246879 A302794 A247361 * A297307 A163238 A097362
KEYWORD
nonn
AUTHOR
James C. McMahon, Mar 02 2024
STATUS
approved

A368805 Contribution to the OEIS

 

A368805Primes whose digits are prime in both base 9 and base 10.0
2, 3, 5, 7, 23, 227, 277, 2777, 5333, 5573, 23537, 23753, 25373, 225527, 25737557, 27775337, 27775357, 35275777, 35277233, 37333757, 227773753, 227775533, 232372577, 233752577, 252777737, 337777277, 25322233723, 25322237323, 25322237357, 25322237723, 25322327753, 25322327777, 25322532523 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,1
COMMENTS
Subsequence of A019546.
LINKS
EXAMPLE
2777 is in this sequence because it is prime, all its digits are prime and 2777 in base 9 is 3725, whose digits are all prime.
MATHEMATICA
Select[Range[2.1*10^7], PrimeQ[#]&&AllTrue[IntegerDigits[#], PrimeQ]&&AllTrue[IntegerDigits[#, 9], PrimeQ]&] (* or *)
seq1[dignum_, b_] := Module[{s = {}}, Do[s = Join[s, Select[FromDigits[#, b] & /@ Tuples[{2, 3, 5, 7}, k], PrimeQ]], {k, 1, dignum}]; s]; seq[maxdig9_] := Select[Intersection[seq1[maxdig9, 9], seq1[maxdig9, 10]], # <= 9^maxdig9 &]; seq[11] (* Amiram Eldar, Jan 06 2024 *)
PROG
(Python)
from gmpy2 import digits, is_prime
from itertools import count, islice, product
def bgen():
yield from [2, 3, 5, 7]
for d in count(2):
for f in product("2357", repeat=d-1):
for last in "37":
yield int("".join(f)+last)
def agen(): yield from (t for t in bgen() if is_prime(t) and set(digits(t, 9)) <= set("2357"))
print(list(islice(agen(), 33))) # Michael S. Branicky, Jan 07 2024
CROSSREFS
Sequence in context: A343834 A070029 A360497 * A262339 A110094 A088054
KEYWORD
nonn,base
AUTHOR
James C. McMahon, Jan 06 2024
STATUS
approved

A366693 Contribution to the OEIS

 

A366693Minimal number of primorials or their negatives that add to n.2
0, 1, 1, 2, 2, 2, 1, 2, 2, 3, 3, 3, 2, 3, 3, 4, 4, 4, 3, 4, 4, 4, 3, 3, 2, 3, 3, 3, 2, 2, 1, 2, 2, 3, 3, 3, 2, 3, 3, 4, 4, 4, 3, 4, 4, 5, 5, 5, 4, 5, 5, 5, 4, 4, 3, 4, 4, 4, 3, 3, 2, 3, 3, 4, 4, 4, 3, 4, 4, 5, 5, 5, 4, 5, 5, 6, 6, 6, 5, 6, 6, 6, 5, 5, 4, 5, 5, 5 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
0,4
LINKS
EXAMPLE
5 = 6 - 1 (two primorials), so a(5) = 2.
27 = 30 - 2 - 1 (three primorials), so a(27) = 3.
MATHEMATICA
a[nthPrimorials_Integer?NonNegative (* Increase nthPrimorials to use more positive and negative primorials in sum *), numberOfPrimorials_Integer?NonNegative (* Increase numberOfPrimorials to increase cap of minimal number of primorials *)] := a[nthPrimorials, numberOfPrimorials] = Module[{A002110, f, h, s}, A002110[nthPrimorials] = Join[{1}, Denominator[Accumulate[1/Prime[Range[nthPrimorials]]]]]; A002110[n_] := A002110[n] = Join[{1}, Denominator[Accumulate[1/Prime[Range[n]]]]]; f[n_] := f[n] = Flatten[Table[p*r, {p, A002110[n - 1]}, {r, {1, -1}}]]; h[n_, u_] := h[n, u] = Sort[Select[DeleteDuplicates[Flatten[Table[Sum[p[j], {j, 1, u}], ##] & @@ Table[{p[j], f[n]}, {j, 1, u}]]], # > 0 &]]; s = Table[Infinity, {A002110[nthPrimorials][[-1]]}]; Monitor[Do[If[s[[k]] > k, s[[k]] = l], {l, 1, numberOfPrimorials}, {k, h[nthPrimorials, l]}], {l, k}]; s = Join[{0}, s]; If[MemberQ[s, Infinity], s[[1 ;; Position[s, Infinity][[1, 1]] - 1]], s]]; a[6, 6] (* Robert P. P. McKone, Oct 21 2023 *)
CROSSREFS
Sequence in context: A261915 A109037 A366136 * A147680 A192895 A210685
KEYWORD
nonn,look
AUTHOR
James C. McMahon, Oct 16 2023
STATUS
approved

A366136 Contribution to the OEIS

 

A366136Minimal number of factorials or their negatives that add to n.2
0, 1, 1, 2, 2, 2, 1, 2, 2, 3, 3, 3, 2, 3, 3, 4, 3, 3, 2, 3, 3, 3, 2, 2, 1, 2, 2, 3, 3, 3, 2, 3, 3, 4, 4, 4, 3, 4, 4, 5, 4, 4, 3, 4, 4, 4, 3, 3, 2, 3, 3, 4, 4, 4, 3, 4, 4, 5, 5, 5, 4, 5, 5, 6, 5, 5, 4, 5, 5, 5, 4, 4, 3, 4, 4, 5, 5, 5, 4, 5, 5, 6, 5, 5, 4, 5, 5 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
0,4
LINKS
EXAMPLE
11 = 6 + 6 - 1 (three factorials), so a(11) = 3.
15 = 6 + 6 + 2 + 1 or 15 = 24 - 6 - 2 - 1 (four factorials), so a(15) = 4.
MATHEMATICA
seq[m_] := Module[{s = Table[m!, {m!}], d, b, sum}, Do[d = PadLeft[Most@ IntegerDigits[k, MixedRadix[Range[m, 1, -1]]], m]; Do[b = 2*PadLeft[ IntegerDigits[i, 2], m] - 1; sum = Total[b * d * Range[m, 1, -1]!]; If[0 < sum <= m!, s[[sum]] = Min[s[[sum]], Total[d]]], {i, 1, 2^m - 1}], {k, 1, 2*m!}]; Join[{0}, s]]; seq[5] (* Amiram Eldar, Oct 03 2023 *)
CROSSREFS
Sequence in context: A204018 A261915 A109037 * A366693 A147680 A192895
KEYWORD
nonn,look
AUTHOR
James C. McMahon, Sep 30 2023
STATUS
approved

A365472 Contribution to the OEIS

 

A365472Numbers whose digits are either all primes or all nonprimes.1
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 14, 16, 18, 19, 22, 23, 25, 27, 32, 33, 35, 37, 40, 41, 44, 46, 48, 49, 52, 53, 55, 57, 60, 61, 64, 66, 68, 69, 72, 73, 75, 77, 80, 81, 84, 86, 88, 89, 90, 91, 94, 96, 98, 99, 100, 101, 104, 106, 108, 109, 110, 111, 114 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,3
COMMENTS
Complement of A365589.
Union of A046034 and A084984.
LINKS
MATHEMATICA
a[n_Integer?NonNegative] := Select[Range[0, n], Module[{digits, primeDigits}, digits = IntegerDigits[#]; primeDigits = MemberQ[{2, 3, 5, 7}, #] & /@ digits; AllTrue[primeDigits, Identity] || AllTrue[primeDigits, Not]] &]; a[114] (* Robert P. P. McKone, Sep 13 2023 *)
CROSSREFS
Sequence in context: A252494 A030294 A125668 * A034894 A263564 A061430
KEYWORD
nonn,base
AUTHOR
James C. McMahon, Sep 11 2023
STATUS
approved

A365471 Contribution to the OEIS

 

A365471Numbers whose digits are not all primes.1
0, 1, 4, 6, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 24, 26, 28, 29, 30, 31, 34, 36, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 54, 56, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 74, 76, 78, 79, 80, 81, 82, 83, 84, 85, 86 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,3
COMMENTS
Complement of A046034.
Union of A084984 and A365589.
LINKS
MATHEMATICA
a[n_Integer?NonNegative] := Select[Range[0, n], Not[AllTrue[MemberQ[{2, 3, 5, 7}, #] & /@ IntegerDigits@#, Identity]] &]; a[86] (* Robert P. P. McKone, Sep 13 2023 *)
Select[Range[0, 100], AnyTrue[IntegerDigits[#], !PrimeQ[#]&]&] (* Harvey P. Dale, Dec 22 2023 *)
CROSSREFS
Sequence in context: A225668 A091985 A091984 * A228651 A045762 A320985
KEYWORD
base,nonn
AUTHOR
James C. McMahon, Sep 11 2023
STATUS
approved

A365589 Contribution to the OEIS

 

A365589Numbers that have at least one prime digit and at least one nonprime digit.2
12, 13, 15, 17, 20, 21, 24, 26, 28, 29, 30, 31, 34, 36, 38, 39, 42, 43, 45, 47, 50, 51, 54, 56, 58, 59, 62, 63, 65, 67, 70, 71, 74, 76, 78, 79, 82, 83, 85, 87, 92, 93, 95, 97, 102, 103, 105, 107, 112, 113, 115, 117, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,1
COMMENTS
The first 44 terms coincide with A085556 (Number of prime digits = number of nonprime digits). a(45) = 102; A085556(45) = 1022.
LINKS
MATHEMATICA
Select[Range[132], ContainsAny[IntegerDigits[#], {2, 3, 5, 7}] && ContainsAny[IntegerDigits[#], {0, 1, 4, 6, 8, 9}]&] (* James C. McMahon, Oct 08 2023 *)
CROSSREFS
Cf. A085556, A118950, A365472 (complement).
Sequence in context: A096514 A074163 A076979 * A085520 A085556 A175225
KEYWORD
nonn,base
AUTHOR
James C. McMahon, Sep 10 2023
STATUS
approved

A364831 Contribution to the OEIS

 

A364831Primes whose digits are prime and in nonincreasing order.1
2, 3, 5, 7, 53, 73, 733, 773, 5333, 7333, 7753, 55333, 75533, 75553, 77773, 733333, 755333, 775553, 7553333, 7555333, 7775533, 7777753, 55555333, 55555553, 77755553, 555553333, 755555533, 773333333, 777555553, 777773333, 777775333, 777775553, 777777773 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,1
COMMENTS
Intersection of A028867 and A019546.
The subsequence for primes whose digits are prime and in strictly decreasing order has just six terms: 2 3 5 7 53 73 (see A177061).
LINKS
MATHEMATICA
Select[Prime[Range[3100000]], AllTrue[d = IntegerDigits[#], PrimeQ] && GreaterEqual @@ d &]
PROG
(Python)
from itertools import count, islice, chain, combinations_with_replacement
from sympy import isprime
def A364831_gen(): # generator of terms
yield 2
yield from chain.from_iterable((sorted(s for d in combinations_with_replacement('753', l) if isprime(s:=int(''.join(d)))) for l in count(1)))
A364831_list = list(islice(A364831_gen(), 30)) # Chai Wah Wu, Sep 10 2023
CROSSREFS
Sequence in context: A214179 A178237 A118842 * A244595 A244597 A237439
KEYWORD
nonn,base
AUTHOR
James C. McMahon, Aug 09 2023
STATUS
approved

A362678 Contribution to the OEIS

 

A362678Primes whose digits are prime and in nondecreasing order.1
2, 3, 5, 7, 23, 37, 223, 227, 233, 257, 277, 337, 557, 577, 2237, 2333, 2357, 2377, 2557, 2777, 3557, 5557, 22277, 22777, 23333, 23357, 23557, 25577, 33377, 33577, 222337, 222557, 223337, 223577, 233357, 233557, 233777, 235577, 333337, 335557, 355777 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,1
COMMENTS
Intersection of A009994 and A019546.
The subsequence for primes whose digits are prime and in strictly increasing order has just eight terms: 2 3 5 7 23 37 257 2357 (see A177061).
LINKS
MAPLE
M:= 7: # for terms with <+ M digits
R:= NULL:
for d from 1 to M do
S:= NULL:
for x2 from 0 to d do
for x3 from 0 to d-x2 do
for x5 from 0 to d-x2-x3 do
x7:= d-x2-x3-x5;
x:= parse(cat(2$x2, 3$x3, 5$x5, 7$x7));
if isprime(x) then S:= S, x fi;
od od od;
R:= R, op(sort([S]));
od:
R; # Robert Israel, Jul 04 2023
MATHEMATICA
Select[Prime[Range[31000]], AllTrue[d = IntegerDigits[#], PrimeQ] && LessEqual @@ d &] (* Amiram Eldar, Jul 07 2023 *)
PROG
(Python)
from sympy import isprime
from itertools import count, combinations_with_replacement as cwr, islice
def agen(): yield from (filter(isprime, (int("".join(c)) for d in count(1) for c in cwr("2357", d))))
print(list(islice(agen(), 50))) # Michael S. Branicky, Jul 05 2023
(PARI) isok(p) = if (isprime(p), my(d=digits(p)); (d == vecsort(d)) && (#select(isprime, d) == #d)); \\ Michel Marcus, Jul 07 2023
CROSSREFS
Sequence in context: A100552 A210566 A155873 * A106711 A235110 A048398
KEYWORD
nonn,base
AUTHOR
James C. McMahon, Jul 03 2023
STATUS
approved

A362272 Contribution to the OEIS

 

A362272a(1) = 1, then multiply, subtract, and add 2, 3, 4; 5, 6, 7; ... in that order.6
1, 2, -1, 3, 15, 9, 16, 128, 119, 129, 1419, 1407, 1420, 19880, 19865, 19881, 337977, 337959, 337978, 6759560, 6759539, 6759561, 155469903, 155469879, 155469904, 4042217504, 4042217477, 4042217505, 117224307645, 117224307615, 117224307646, 3751177844672, 3751177844639 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,2
LINKS
FORMULA
a(1)=1; for n > 1,
a(n) = a(n-1) * n if n mod 3 = 2,
a(n-1) - n if n mod 3 = 0,
a(n-1) + n if n mod 3 = 1.
EXAMPLE
a(2) = 1 * 2 = 2;
a(3) = 2 - 3 = -1;
a(4) = -1 + 4 = 3.
MATHEMATICA
FoldList[If[Mod[#2, 3]==2, #1*#2, If[Mod[#2, 3]==0, #1-#2, #1+#2]]&, 1, Range[2, 33]] (* James C. McMahon, Oct 09 2023 *)
PROG
(Python)
from itertools import count, islice
def A362272_gen(): # generator of terms
yield (a:=1)
for n in count(2, 3):
yield (a:=a*n)
yield (a:=a-n-1)
yield (a:=a+n+2)
A362272_list = list(islice(A362272_gen(), 20)) # Chai Wah Wu, Apr 19 2023
CROSSREFS
Other operation orders: A077382, A077383, A362269, A362270, A362271.
Sequence in context: A366591 A007447 A153189 * A095852 A283748 A209365
KEYWORD
sign
AUTHOR
James C. McMahon, Apr 19 2023
STATUS
approved

A362271 Contribution to the OEIS

 

A362271a(1) = 1, then add, subtract and multiply 2, 3, 4; 5, 6, 7; ... in that order.6
1, 3, 0, 0, 5, -1, -7, 1, -8, -80, -69, -81, -1053, -1039, -1054, -16864, -16847, -16865, -320435, -320415, -320436, -7049592, -7049569, -7049593, -176239825, -176239799, -176239826, -4934715128, -4934715099, -4934715129, -152976168999, -152976168967, -152976169000 (listgraphrefslistenhistoryedittextinternal format)
OFFSET
1,2
LINKS
FORMULA
a(1)=1; for n > 1,
a(n) = a(n-1) + n if n mod 3 = 2,
a(n-1) - n if n mod 3 = 0,
a(n-1) * n if n mod 3 = 1.
EXAMPLE
a(2) = 1 + 2 = 3;
a(3) = 3 - 3 = 0;
a(4) = 0 * 4 = 0.
MATHEMATICA
FoldList[If[Mod[#2, 3]==2, #1+#2, If[Mod[#2, 3]==0, #1-#2, #1*#2]]&, 1, Range[2, 33]] (* James C. McMahon, Oct 09 2023 *)
PROG
(Python)
from itertools import count, islice
def A362271_gen(): # generator of terms
yield (a:=1)
for n in count(2, 3):
yield (a:=a+n)
yield (a:=a-n-1)
yield (a:=a*(n+2))
A362271_list = list(islice(A362271_gen(), 20)) # Chai Wah Wu, Apr 19 2023
CROSSREFS
Other operation orders: A077382, A077383, A362269, A362270, A362272.
Sequence in context: A092669 A255986 A011400 * A115013 A072736 A135090
KEYWORD
sign
AUTHOR
James C. McMahon, Apr 13 2023
STATUS
approved

Women in Mathematics

(Image: Hypatia by  Jules Maurice Gaspard , public domain) I recently re-read Instant Mathematics (see prior post:   https://jamesmacmath.bl...

Popular in last 30 days