cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-4 of 4 results.

A354940 Square array A(n, k) = A354930(n, k)/n, read by falling antidiagonals.

Original entry on oeis.org

1, 2, 3, 3, 5, 4, 4, 7, 7, 5, 5, 9, 13, 9, 3, 7, 11, 16, 13, 6, 7, 8, 13, 19, 17, 8, 13, 4, 9, 17, 25, 21, 11, 19, 5, 3, 11, 19, 31, 25, 13, 25, 8, 9, 5, 13, 23, 37, 29, 16, 31, 11, 11, 7, 11, 16, 25, 43, 37, 23, 37, 15, 17, 10, 31, 3, 17, 27, 49, 41, 26, 43, 19, 19, 14, 41, 4, 13, 19, 29, 61, 49, 31, 49, 22, 25, 16, 51, 6, 25, 7
Offset: 1

Views

Author

Antti Karttunen, Jun 15 2022

Keywords

Comments

Array is read by descending antidiagonals with (n,k) = (1,1), (1,2), (2,1), (1,3), (2,2), (3,1), etc.

Examples

			The top left 15x16 corner of the array:
n\k  |  1   2   3   4   5   6   7   8    9   10   11   12   13   14   15
-----+---------------------------------------------------------------------
   1 |  1,  2,  3,  4,  5,  7,  8,  9,  11,  13,  16,  17,  19,  23,  25,
   2 |  3,  5,  7,  9, 11, 13, 17, 19,  23,  25,  27,  29,  31,  37,  41,
   3 |  4,  7, 13, 16, 19, 25, 31, 37,  43,  49,  61,  64,  67,  73,  79,
   4 |  5,  9, 13, 17, 21, 25, 29, 37,  41,  49,  53,  57,  61,  73,  81,
   5 |  3,  6,  8, 11, 13, 16, 23, 26,  31,  36,  41,  43,  46,  51,  53,
   6 |  7, 13, 19, 25, 31, 37, 43, 49,  61,  67,  73,  79,  97, 103, 109,
   7 |  4,  5,  8, 11, 15, 19, 22, 25,  29,  32,  39,  43,  47,  50,  53,
   8 |  3,  9, 11, 17, 19, 25, 27, 33,  41,  43,  49,  57,  59,  67,  73,
   9 |  5,  7, 10, 14, 16, 19, 23, 25,  28,  32,  37,  41,  43,  46,  50,
  10 | 11, 31, 41, 51, 61, 71, 81, 91, 101, 121, 131, 141, 151, 171, 181,
  11 |  3,  4,  6,  9, 12, 15, 17, 23,  25,  28,  31,  34,  37,  45,  47,
  12 | 13, 25, 37, 49, 61, 73, 85, 97, 109, 121, 145, 157, 169, 181, 193,
  13 |  7,  8,  9, 11, 14, 20, 22, 23,  27,  33,  37,  40,  46,  47,  48,
  14 |  5, 15, 19, 29, 43, 47, 57, 61,  71,  89,  99, 103, 113, 127, 131,
  15 |  4,  8, 16, 19, 23, 31, 38, 46,  49,  53,  61,  64,  76,  79,  83,
  16 |  7, 11, 13, 17, 23, 27, 29, 33,  43,  49,  59,  61,  65,  71,  75,
		

Crossrefs

Cf. A354932 (column 1).
Rows 1 .. 7 (some of these are conjectural): A000961, A061345 (without its initial 1), A137827, A354934, A354935, A354936, A354937, A354938, A354939.

Programs

  • PARI
    up_to = 105;
    A345992(n) = for(m=1, oo, if((m*(m+1))%n==0, return(gcd(n,m))));
    memoA354930sq = Map();
    A354930sq(n, k) = { my(v=0); if(!mapisdefined(memoA354930sq,[n,k-1],&v),if(1==k, v=0, v = A354930sq(n, k-1))); for(i=1+v,oo,if(A345992(i)==n,mapput(memoA354930sq,[n,k],i); return(i))); };
    A354940sq(n, k) = (A354930sq(n, k)/n);
    A354940list(up_to) = { my(v = vector(up_to), i=0); for(a=1,oo, for(col=1,a, i++; if(i > up_to, return(v)); v[i] = A354940sq(col,(a-(col-1))))); (v); };
    v354940 = A354940list(up_to);
    A354940(n) = v354940[n];

A345992 Let m = A344005(n) = smallest m such that n divides m*(m+1); a(n) = gcd(n,m).

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 5, 1, 1, 2, 1, 4, 3, 2, 1, 8, 1, 2, 1, 7, 1, 5, 1, 1, 11, 2, 7, 4, 1, 2, 3, 5, 1, 6, 1, 11, 9, 2, 1, 3, 1, 2, 17, 4, 1, 2, 5, 7, 3, 2, 1, 15, 1, 2, 9, 1, 5, 11, 1, 4, 23, 14, 1, 8, 1, 2, 3, 19, 7, 6, 1, 5, 1, 2, 1, 4, 17, 2, 29, 8, 1, 9, 13, 23, 3, 2, 19, 32, 1, 2, 11, 4, 1, 17
Offset: 1

Views

Author

Keywords

Comments

By definition, a(n)*A345993(n) = n.
a(n) is even iff n/2 is in A344000. This is true, but essentially trivial, and does not provide any insight into either sequence.
Empirical: For n >= 3, a(n) <= n/3, and a(n) = n/3 iff n is in 3*{2^odd, primes == -1 mod 6}.
If n = 2*p^k where p is an odd prime then m = A344005(n) = p^k - 1 and a(n) = 2. Conversely, it appears that if a(n) = 2 then n is twice an odd prime power. (Corrected by Antti Karttunen, Jun 14 2022)
a(n) = 1 if n is a prime power. - Chai Wah Wu, Jun 01 2022
From Antti Karttunen, Jun 14 2022: (Start)
Conversely, if a(n) = 1 [i.e., A345993(n) = n] then n is a power of prime. (This follows from N. J. A. Sloane's Jul 11 2021 theorem given in A344005).
Apparently, a(n) = 3 iff n = A354984(k) = 3*A137827(k), for some k >= 1.
(End)

Crossrefs

Cf. A011772, A137827, A182665, A344000, A344005, A345993, A345994, A345995, A354930, A354931 (the least occurrence of each n=1..), A354984.
Cf. also A007528, A051119, A284600.

Programs

  • Maple
    # load Findm from A344005
    ans:=[];
    for n from 1 to 40 do t1:=Findm(n)[1]; ans:=[op(ans), igcd(n,t1)]; od:
    ans;
  • Mathematica
    smd[n_]:=Module[{m=1},While[Mod[m(m+1),n]!=0,m++];GCD[n,m]]; Array[smd,110] (* Harvey P. Dale, Jan 07 2022 *)
  • PARI
    f(n) = my(m=1); while ((m*(m+1)) % n, m++); m; \\ A344005
    a(n) = gcd(n,f(n)); \\ Michel Marcus, Aug 06 2021
    (Python 3.8+)
    from math import gcd, prod
    from itertools import combinations
    from sympy import factorint
    from sympy.ntheory.modular import crt
    def A345992(n):
        if n == 1:
            return 1
        plist = tuple(p**q for p, q in factorint(n).items())
        return 1 if len(plist) == 1 else gcd(n,int(min(min(crt((m, n//m), (0, -1))[0], crt((n//m, m), (0, -1))[0]) for m in (prod(d) for l in range(1, len(plist)//2+1) for d in combinations(plist, l))))) # Chai Wah Wu, Jun 01 2022

Formula

a(n) = gcd(n, A182665(n)) = gcd(A182665(n), A344005(n)). - Antti Karttunen, Jun 13 2022

A354931 a(n) = the least k for which A345992(k) = n.

Original entry on oeis.org

1, 6, 12, 20, 15, 42, 28, 24, 45, 110, 33, 156, 91, 70, 60, 112, 51, 342, 76, 140, 231, 198, 69, 168, 325, 234, 108, 476, 87, 930, 124, 96, 561, 170, 315, 1116, 185, 418, 195, 360, 123, 714, 172, 220, 585, 1426, 141, 336, 245, 850, 204, 988, 159, 270, 385, 1064, 1311, 522, 177, 3660, 488, 434, 504, 320, 715, 1254
Offset: 1

Views

Author

Antti Karttunen, Jun 14 2022

Keywords

Crossrefs

Column 1 of A354930.

Programs

  • Mathematica
    s[n_] := Module[{m = 1}, While[!Divisible[m*(m+1), n], m++]; GCD[n, m]]; a[n_] := Module[{k = n}, While[s[k] != n, k+=n]; k]; Array[a,60] (* Amiram Eldar, Jun 15 2022 *)
  • PARI
    A345992(n) = gcd(n,A344005(n));
    A354931(n) = for(k=1,oo,if(A345992(k)==n,return(k)));

Formula

a(n) = n * A354932(n).

A354984 Numbers that are 3 * prime powers congruent to 1 (mod 3).

Original entry on oeis.org

12, 21, 39, 48, 57, 75, 93, 111, 129, 147, 183, 192, 201, 219, 237, 291, 309, 327, 363, 381, 417, 453, 471, 489, 507, 543, 579, 597, 633, 669, 687, 723, 768, 813, 831, 849, 867, 921, 939, 993, 1011, 1029, 1047, 1083, 1101, 1119, 1137, 1191, 1227, 1263, 1299, 1317, 1371, 1389, 1461, 1497, 1569, 1587, 1623, 1641, 1713
Offset: 1

Views

Author

Antti Karttunen, Jun 15 2022

Keywords

Comments

Numbers k of the form 9m+3 such that k/3 = p^k, with p a prime and k >= 1.

Crossrefs

Intersection of A017197 and 3*A246655.
Cf. A137827, A354983 (characteristic function).
Row 3 of A354930 (conjectured).

Programs

  • Mathematica
    Select[Range[2000], Mod[#, 9] == 3 && PrimePowerQ[#/3] &] (* Amiram Eldar, Jun 15 2022 *)
  • PARI
    A354983(n) = ((3==(n%9)) && isprimepower(n/3));
    isA354984(n) = A354983(n);

Formula

a(n) = 3 * A137827(n).
Showing 1-4 of 4 results.