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-10 of 10 results.

A305800 Filter sequence for a(prime) = constant sequences.

Original entry on oeis.org

1, 2, 2, 3, 2, 4, 2, 5, 6, 7, 2, 8, 2, 9, 10, 11, 2, 12, 2, 13, 14, 15, 2, 16, 17, 18, 19, 20, 2, 21, 2, 22, 23, 24, 25, 26, 2, 27, 28, 29, 2, 30, 2, 31, 32, 33, 2, 34, 35, 36, 37, 38, 2, 39, 40, 41, 42, 43, 2, 44, 2, 45, 46, 47, 48, 49, 2, 50, 51, 52, 2, 53, 2, 54, 55, 56, 57, 58, 2, 59, 60, 61, 2, 62, 63, 64, 65, 66, 2, 67, 68, 69, 70, 71, 72, 73, 2, 74, 75, 76, 2, 77, 2, 78, 79, 80, 2, 81, 2, 82, 83, 84, 2, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96
Offset: 1

Views

Author

Antti Karttunen, Jun 14 2018

Keywords

Comments

Restricted growth sequence transform of A239968.
In the following, A stands for this sequence, A305800, and S -> T (where S and T are sequence A-numbers) indicates that for all i, j: S(i) = S(i) => T(i) = T(j).
For example, the following implications hold:
A -> A300247 -> A305897 -> A077462 -> A101296,
A -> A290110 -> A300250 -> A101296.

Crossrefs

Differs from A296073 for the first time at n=125, as a(125) = 96, while A296073(125) = 33.
Cf. also A305900, A305801, A295300, A289626 for other "upper level" filters.

Programs

  • Mathematica
    Join[{1},Table[If[PrimeQ[n],2,1+n-PrimePi[n]],{n,2,150}]] (* Harvey P. Dale, Jul 12 2019 *)
  • PARI
    A305800(n) = if(1==n,n,if(isprime(n),2,1+n-primepi(n)));

Formula

a(1) = 1; for n > 1, a(n) = 2 for prime n, and a(n) = 1+n-A000720(n) for composite n.

A077462 Prime factor configuration patterns.

Original entry on oeis.org

0, 1, 2, 2, 3, 2, 4, 2, 5, 3, 4, 2, 6, 2, 4, 4, 7, 2, 8, 2, 6, 4, 4, 2, 9, 3, 4, 5, 6, 2, 10, 2, 11, 4, 4, 4, 12, 2, 4, 4, 9, 2, 10, 2, 6, 6, 4, 2, 13, 3, 8, 4, 6, 2, 14, 4, 9, 4, 4, 2, 15, 2, 4, 6, 16, 4, 10, 2, 6, 4, 10, 2, 17, 2, 4, 8, 6, 4, 10, 2, 13, 7, 4
Offset: 0

Views

Author

Michael Somos, Nov 07 2002

Keywords

Comments

Call two numbers equivalent if they have the same prime factorization exponents (in the same order). This sequence enumerates the equivalence classes.
A055932(a(n)) = A071364(n). - David Wasserman, Dec 21 2004
From Antti Karttunen, Jun 13 2018: (Start)
After a(0) = 0, this is the restricted growth sequence transform of A071364. The latter sequence is an "ordered variant" of A046523, and because A101296 is the rgs-transform of A046523, it follows that for all i, j: a(i) = a(j) => A101296(i) = A101296(j).
(End)

Examples

			12 = 2^2*3^1 has exponents {2,1}, and is the first number with that pattern, so its value is one more than the largest previous value; a(12) = 6. Contrast that with 18 = 2^1*3^2 having exponents {1,2}, which is different from {2,1}, so a(18) is not equal to a(12). - _Franklin T. Adams-Watters_, Aug 01 2012
		

Crossrefs

One more than A079616.

Programs

  • Mathematica
    fList = {{0}}; Join[{0, 1}, Table[e = Transpose[FactorInteger[n]][[2]]; pos = Position[fList, e]; If[pos == {}, AppendTo[fList, e]; Length[fList], pos[[1, 1]]], {n, 2, 100}]] (* T. D. Noe, Aug 01 2012 *)
  • PARI
    a(n)=local(vn); if(n<1,return(0)); vn=factor(n)[,2]; for(i=1,n,if(vn==factor(i)[,2],return(#Set(vector(i,j,factor(j)[,2])))))
    
  • PARI
    up_to = 100000;
    rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
    A071364(n) = { my(f = factor(n)); for (i=1, #f~, f[i, 1] = prime(i)); factorback(f); }; \\ From A071364
    v077462 = rgs_transform(vector(up_to,n,A071364(n)));
    A077462(n) = if(!n,n,v077462[n]); \\ Antti Karttunen, Jun 13 2018

A300250 Restricted growth sequence transform of A297174: a filter sequence recording the prime signatures of divisors of n, with divisors ordered by their magnitude.

Original entry on oeis.org

1, 2, 2, 3, 2, 4, 2, 5, 3, 4, 2, 6, 2, 4, 4, 7, 2, 8, 2, 9, 4, 4, 2, 10, 3, 4, 5, 9, 2, 11, 2, 12, 4, 4, 4, 13, 2, 4, 4, 14, 2, 15, 2, 9, 6, 4, 2, 16, 3, 8, 4, 9, 2, 17, 4, 14, 4, 4, 2, 18, 2, 4, 6, 19, 4, 15, 2, 9, 4, 11, 2, 20, 2, 4, 8, 9, 4, 15, 2, 21, 7, 4, 2, 22, 4, 4, 4, 23, 2, 24, 4, 9, 4, 4, 4, 25, 2, 8, 9, 26, 2, 15, 2, 23, 11
Offset: 1

Views

Author

Antti Karttunen, Mar 07 2018

Keywords

Comments

This sequence gives a coarser partitioning of natural numbers than A290110, and finer than A101296:
For all i, j:
A290110(i) = A290110(j) => a(i) = a(j) => A101296(i) = A101296(j).

Examples

			Divisors of 462 are 1, 2, 3, 6, 7, 11, 14, 21, 22, 33, 42, 66, 77, 154, 231, 462.
Divisors of 858 are 1, 2, 3, 6, 11, 13, 22, 26, 33, 39, 66, 78, 143, 286, 429, 858.
If one takes the smallest prime-signature representative (A046523) of each these, one gets in both cases [1, 2, 2, 6, 2, 2, 6, 6, 6, 6, 30, 30, 6, 30, 30, 210]. E.g. 462 = 2*3*7*11 and 858 = 2*3*11*13, which both have the same prime signature as 210 = 2*3*5*7. And similarly for all the other divisors, from which follows that a(462) = a(858).
On the other hand, for 12 = 2*2*3 the divisors are 1, 2, 3, 2*2, 2*3, 2*2*3, and for 18 = 2*3*3 the divisors are 1, 2, 3, 2*3, 3*3, 2*3*3, and because the prime signatures differ both in the fourth and in the fifth places, a(18) != a(12).
		

Crossrefs

Differs from similar A290110 for the first time at n=858.

Programs

  • PARI
    up_to = 65537;
    rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
    write_to_bfile(start_offset,vec,bfilename) = { for(n=1, length(vec), write(bfilename, (n+start_offset)-1, " ", vec[n])); }
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); };  \\ From A046523
    v101296 = rgs_transform(vector(up_to, n, A046523(n)));
    A101296(n) = v101296[n];
    A297174(n) = { my(s=0,i=-1); fordiv(n, d, if(d>1, i += (A101296(d)-1); s += 2^i)); (s); };
    write_to_bfile(1,rgs_transform(vector(up_to,n,A297174(n))),"b300250.txt");

A365406 Numbers j whose largest divisor <= sqrt(j) is a power of 2.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 13, 14, 16, 17, 19, 20, 22, 23, 24, 26, 28, 29, 31, 32, 34, 37, 38, 41, 43, 44, 46, 47, 52, 53, 58, 59, 61, 62, 64, 67, 68, 71, 72, 73, 74, 76, 79, 80, 82, 83, 86, 88, 89, 92, 94, 96, 97, 101, 103, 104, 106, 107, 109, 112, 113, 116, 118, 122, 124, 127, 128, 131, 134, 136, 137
Offset: 1

Views

Author

Omar E. Pol, Oct 10 2023

Keywords

Comments

Also indices of the powers of 2 in A033676.
Also numbers in increasing order from the columns k of A163280 where k is a power of 2.
Observation: at least the first 82 terms of the subsequence of terms with no middle divisors (that is 3, 5, 7, 10, ...) coincide with at least the first 82 terms of A246955.
For the definition of middle divisor see A067742.
From Peter Munn, Oct 26 2023: (Start)
Most of the early terms are in A342081, which consists of powers of 2 together with products of a prime and a power of 2 where the prime is the larger. The exceptions are 24, 72, 80, 96, 112, ... .
The odd terms clearly consist of 1 and the odd primes. We can fully characterize the even terms by their A290110 values, which depend on the relative sizes of a number's divisors. A290110 provides a refinement of the classification of numbers by prime signature (cf. A212171): see the example below for numbers with the same prime signature as 48.
(End)

Examples

			From _Peter Munn_, Oct 26 2023: (Start)
The table below looks at numbers j with prime signature (4, 1), showing the presence of j and its characterization by A290110(j):
    j             A290110(j)  present
    48 = 2^4 * 3      16         no
    80 = 2^4 * 5      21        yes
   112 = 2^4 * 7      21        yes
   162 = 2 * 3^4      36         no
   176 = 2^4 * 11     38         no
   208 = 2^4 * 13     38         no
   272 = 2^4 * 17     51        yes
   304 = 2^4 * 19     51        yes
   368 = 2^4 * 23     51        yes
  ...
Clearly any odd composite number is exempted, for example:
   891 = 3^4 * 11     21         no
  6723 = 3^4 * 83     51         no
Note that A290110(j) = 36 for j = 2 * p^4, prime p; and A290110(j) = 51 for j = 2^4 * p, prime p >= 17.
(End)
		

Crossrefs

Cf. A342081 (a subsequence), A365408 (complement), A365716 (characteristic function).

Programs

  • Mathematica
    q[n_] := Module[{d = Divisors[n], mid}, mid = d[[Ceiling[Length[d]/2]]]; mid == 2^IntegerExponent[mid, 2]]; Select[Range[150], q] (* Amiram Eldar, Oct 11 2023 *)
  • PARI
    f(n) = local(d); if(n<2, 1, d=divisors(n); d[(length(d)+1)\2]); \\ A033676
    isp2(n) = 2^logint(n,2) == n;
    isok(k) = isp2(f(k)); \\ Michel Marcus, Oct 11 2023
    
  • Python
    from itertools import count, islice
    from sympy import divisors
    def A365406_gen(startvalue=1): # generator of terms >= startvalue
        return filter(lambda i:(a:=(d:=divisors(i))[len(d)-1>>1])==1<A365406_list = list(islice(A365406_gen(),30)) # Chai Wah Wu, Oct 18 2023

A366250 Numbers k that are not powerful and do not have a strictly superior squarefree divisor.

Original entry on oeis.org

48, 54, 96, 160, 162, 192, 224, 250, 320, 375, 384, 405, 448, 486, 567, 640, 686, 704, 768, 832, 896, 960, 1029, 1080, 1200, 1215, 1250, 1280, 1350, 1408, 1440, 1458, 1500, 1536, 1620, 1664, 1701, 1715, 1792, 1875, 1920, 2016, 2058, 2160, 2176, 2250, 2268, 2352
Offset: 1

Views

Author

Peter Munn and Michael De Vlieger, Feb 08 2024

Keywords

Comments

A number k does not have a strictly superior squarefree divisor if and only if k is at least as large as the square of rad(k), the largest squarefree divisor of k. All powerful numbers (A001694) have this property. This sequence lists the other such numbers.
Let rad(k) = A007947(k), the largest squarefree divisor, i.e., the squarefree kernel of k. A341645 lists the numbers without a strictly superior squarefree divisor.
A341645 = { k : rad(k) <= k/rad(k) } = { k : A007947(k) <= A003557(k) }, and it is evident that rad(k) <= k/rad(k) is true for powerful k, that is, k in A001694.
Since A001694 contains A001597, the above is also true for perfect powers k; A001597 is a proper subset of A341645.
This sequence contains "weak" k (in A052485) such that rad(k) < k/rad(k).
The presence of a number, k, in this sequence depends only upon A290110(k), i.e., upon the factorization pattern of its sequence of divisors as defined in A191743.
Let S = A006939 and let P = A002110. Almost all superprimorials are in this sequence: S \ {1, 2, 12, 360} is a proper subset. S(i) = S(i-1)*P(i), where S(i-1) = A003557(S(i)) and P(i) = rad(S(i)), and for i > 4, S(i-1) > P(i). Since prime(i) | S(i) but prime(i)^2 does not divide S(i), S(i) is not powerful. Corollary: almost all superprimorials are in A341645, since this sequence is a proper subset of A341645.

Examples

			Let b(n) = A364702(n).
a(1) = b(1) = 48 since rad(48) < 48/rad(48), 6 < 8.
b(2) = 50 is not in the sequence since rad(50) > 50/rad(50), 10 > 5.
a(2) = b(3) = 54 since 6 < 9, etc.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[2, 2400], And[! AllTrue[#2[[All, -1]], # > 1 &], #1 >= Apply[Times, #2[[All, 1]]^2]] & @@ {#, FactorInteger[#]} &]
  • PARI
    isok(m) = if (!ispowerful(m), my(d=divisors(m)); #select(x->(issquarefree(x) && (x^2>m)), d) == 0); \\ Michel Marcus, Feb 11 2024

Formula

Set difference of A341645 and A001694.
Intersection of A341645 and A364702 where the latter is a proper subset of A052485.
Sequence contains infinite intersections of A052485 and { k = m*s : s is squarefree, rad(m) | s, 1 < s < m }.
{a(n)} = union of { k = s*m : s > 1 is squarefree, rad(m) | s, m >= s, k is not powerful }.
{a(n)} = { k in A364702 : k >= rad(k)^2 }.

A355445 Numbers of the form p^2 * q where p and q are primes with p^2 < q.

Original entry on oeis.org

20, 28, 44, 52, 68, 76, 92, 99, 116, 117, 124, 148, 153, 164, 171, 172, 188, 207, 212, 236, 244, 261, 268, 279, 284, 292, 316, 332, 333, 356, 369, 387, 388, 404, 412, 423, 428, 436, 452, 477, 508, 524, 531, 548, 549, 556, 596, 603, 604, 628, 639, 652, 657, 668, 692, 711, 716, 724, 725, 747, 764, 772, 775, 788, 796
Offset: 1

Views

Author

Antti Karttunen, Jul 02 2022

Keywords

Comments

Numbers whose number of divisors of n (A000005) is equal to 3 + the number of prime factors of n (with multiplicity, A001222), and the third smallest divisor is a square of a prime (A001248).

Examples

			20 = 2^2 * 5 is included because 2 < 5, and of the divisors of 20, [1, 2, 4, 5, 10, 20], the third one (4) is a square of prime as 2^2 < 5.
		

Crossrefs

Setwise difference A096156 \ A355446. Subsequence of A119315.
Positions of 9's in A290110 and in A300250.
Cf. A000005, A001222, A001248, A355443 (characteristic function).

Programs

  • Mathematica
    Select[Range[800], (f = FactorInteger[#])[[;; , 2]] == {2, 1} && f[[1, 1]]^2 < f[[2, 1]] &] (* Amiram Eldar, Jul 07 2022 *)
  • PARI
    A355443(n) = ((numdiv(n) == (3+bigomega(n))) && issquare(divisors(n)[3]));
    isA355445(n) = A355443(n);

A383961 Square array read by upward antidiagonals: T(n,k) is the n-th number whose largest odd divisor is its k-th divisor, n >= 1, k >= 1.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 8, 7, 9, 15, 16, 11, 10, 20, 18, 32, 13, 12, 21, 50, 36, 64, 17, 14, 27, 81, 45, 30, 128, 19, 22, 28, 88, 63, 42, 105, 256, 23, 24, 33, 98, 75, 54, 135, 60, 512, 29, 25, 35, 104, 99, 66, 165, 84, 120, 1024, 31, 26, 39, 136, 117, 70, 189, 108, 140, 90
Offset: 1

Views

Author

Omar E. Pol, May 16 2025

Keywords

Comments

This is a permutation of the positive integers.
From Peter Munn, May 18 2025: (Start)
Numbers with the same factorization pattern of their sequence of divisors (see A290110) and the same parity appear here in the same column.
For example, each column k > 2 includes the subsequence 2^(k-2) * p for all prime p > 2^(k-2).
(End)

Examples

			The corner 15 X 15 of the square array is as follows:
      1,  3,  6,  15,  18,  36,  30, 105,  60, 120,  90, 315,  816, 1360, 180, ...
      2,  5,  9,  20,  50,  45,  42, 135,  84, 140, 126, 324,  880, 1520, 210, ...
      4,  7, 10,  21,  81,  63,  54, 165, 108, 168, 150, 432,  912, 1632, 252, ...
      8, 11, 12,  27,  88,  75,  66, 189, 132, 220, 198, 440, 1040, 1760, 270, ...
     16, 13, 14,  28,  98,  99,  70, 195, 156, 240, 216, 495, 1056, 1824, 300, ...
     32, 17, 22,  33, 104, 117,  72, 200, 162, 260, 234, 520, 1104, 1840, 330, ...
     64, 19, 24,  35, 136, 147,  78, 231, 204, 308, 264, 525, 1120, 1904, 378, ...
    128, 23, 25,  39, 152, 153, 100, 255, 225, 340, 280, 528, 1144, 2000, 390, ...
    256, 29, 26,  40, 176, 171, 102, 273, 228, 364, 294, 560, 1232, 2080, 396, ...
    512, 31, 34,  44, 184, 175, 110, 285, 276, 380, 306, 585, 1248, 2128, 462, ...
   1024, 37, 38,  51, 208, 207, 114, 297, 348, 405, 312, 616, 1392, 2208, 468, ...
   2048, 41, 46,  52, 232, 243, 130, 345, 372, 460, 336, 624, 1456, 2288, 510, ...
   4096, 43, 48,  55, 242, 245, 138, 351, 400, 476, 342, 675, 1458, 2320, 546, ...
   8192, 47, 49,  56, 248, 261, 144, 357, 441, 480, 350, 680, 1488, 2464, 570, ...
  16384, 53, 58,  57, 296, 272, 154, 375, 444, 500, 408, 693, 1496, 2480, 588, ...
  ...
		

Crossrefs

Column 1 gives A000079.
Column 2 gives A065091.
Column 3 consists of (A001248 U A091629 U A100484)\{4}.
Column 4 consists of numbers >= 15 in (A001749 U A030078 U A046388 U A070875).
Row 1 gives A383402.

Programs

  • Mathematica
    f[n_] := If[OddQ[n], DivisorSigma[0, n], FirstPosition[Divisors[n], n/2^IntegerExponent[n, 2]][[1]]]; seq[m_] := Module[{t = Table[0, {m}, {m}], v = Table[0, {m}], c = 0, k = 1, i, j}, While[c < m*(m + 1)/2, i = f[k]; If[i <= m, j = v[[i]] + 1; If[j <= m - i + 1, t[[i]][[j]] = k; v[[i]]++; c++]]; k++]; Table[t[[j]][[i - j + 1]], {i, 1, m}, {j, 1, i}] // Flatten]; seq[11] (* Amiram Eldar, May 16 2025 *)

A355446 Numbers of the form p^2 * q where p and q are primes with p < q < p^2.

Original entry on oeis.org

12, 45, 63, 175, 275, 325, 425, 475, 539, 575, 637, 833, 931, 1127, 1421, 1519, 1573, 1813, 2009, 2057, 2107, 2299, 2303, 2783, 2873, 3211, 3509, 3751, 3887, 4477, 4901, 4961, 5203, 5239, 5491, 5687, 6253, 6413, 6647, 6929, 7139, 7267, 7381, 7943, 8107, 8303, 8381, 8591, 8833, 8957, 8959, 9559, 9971, 10043, 10309, 10469
Offset: 1

Views

Author

Antti Karttunen, Jul 02 2022

Keywords

Comments

Numbers whose number of divisors of n (A000005) is equal to 3 + the number of prime factors of n (with multiplicity, A001222), and the fourth smallest divisor is a square of a prime (A001248).

Examples

			12 = 2^2 * 3 is included because 2 < 3, and of the divisors of 12, [1, 2, 3, 4, 6, 12], the fourth one (4) is a square of prime as 2^2 > 3.
		

Crossrefs

Setwise difference A096156 \ A355445.
Positions of 6's in A290110 and in A300250.
Subsequence of A066680, and of A355455.
A251720 is a subsequence.
Cf. A000005, A001222, A001248, A355444 (characteristic function).

Programs

  • Mathematica
    Select[Range[10^4], (f = FactorInteger[#])[[;; , 2]] == {2, 1} && f[[1, 1]]^2 > f[[2, 1]] &] (* Amiram Eldar, Jul 07 2022 *)
  • PARI
    A355444(n) = ((numdiv(n) == (3+bigomega(n))) && issquare(divisors(n)[4]));
    isA355446(n) = A355444(n);

A319070 a(n) is the area of the surface made of the rectangles with vertices (d, n/d), (D, n/d), (D, n/D), (d, n/D) for all (d, D), pair of consecutive divisors of n.

Original entry on oeis.org

0, 1, 4, 4, 16, 7, 36, 12, 24, 19, 100, 17, 144, 39, 44, 32, 256, 33, 324, 41, 72, 103, 484, 40, 160, 147, 108, 65, 784, 57, 900, 80, 152, 259, 228, 66, 1296, 327, 204, 93, 1600, 99, 1764, 137, 160, 487, 2116, 92, 504, 165, 332, 185, 2704, 135, 388
Offset: 1

Views

Author

Luc Rousseau, Sep 09 2018

Keywords

Examples

			The divisors of n=12 are {1, 2, 3, 4, 6, 12}. The widths of the rectangles from the definition are obtained by difference: {1, 1, 1, 2, 6}. By symmetry, their heights are the same, but in reverse order: {6, 2, 1, 1, 1}. The sought total area is the sum of products width*height of each rectangle, in other words it is the dot product 1*6 + 1*2 + 1*1 + 2*1 + 6*1. Result: 17. So, a(12)=17.
		

Crossrefs

Cf. A191743, A290110 (introducing factorization patterns of sequences of divisors).
Cf. A165900 (the Fibonacci polynomial).

Programs

  • Mathematica
    a[n_] := Module[{x = Differences[Divisors[n]]}, Plus @@ (x*Reverse[x])];
    Table[a[n], {n, 1, 55}]
  • PARI
    arect(n, d, D) = (D-d)*(n/d - n/D);
    a(n) = my(vd = divisors(n)); sum(k=1, #vd-1, arect(n, vd[k], vd[k+1])); \\ Michel Marcus, Oct 28 2018

Formula

a(1) = 0.
a(p) = (p-1)^2 for p a prime number.
a(p^k) = (p-1)^2*k*p^(k-1) for p^k a prime power.
a(p*q) = 2*(p-1)^2*q + (q-p)^2 for p and q primes (p < q).
a(n) = (n/2 - 1)^2 + 3 if n=2*p with p a prime greater than 2.
a(n) = (n/p + F(p-1))^2 + p^2 - F(p-1)^2 if n = p*q, p < q primes; where F denotes the Fibonacci polynomial, F(x) = x^2 - x - 1 (see A165900).
For more complex factorization patterns of n, the formula depends on the factorization pattern of the sequence of divisors of n (see A191743 or A290110), e.g.:
a(p^2*q) = 4*p*q*(p-1)^2 + (q-p^2)^2 if 1 < p < p^2 < q < p*q < p^2*q,
but
a(p^2*q) = 2*p*q*(p-1)^2 + 2*p*(q-p)^2 + (p^2-q)^2 if 1 < p < q < p^2 < p*q < p^2*q.
a(n) = Sum_{i=1..tau(n)-1} (d_[tau(n)-i+1] - d_[tau(n)-i])*(d_[i+1] - d_[i]), where {d_i}, i=1..tau(n) is the increasing sequence of divisors of n. - Ridouane Oudra, Oct 17 2021

A355474 Square array T(m,n) = Card({ (i, j) : 1 <= i <= m, 1 <= j <= min(n, i), GCD(i, j) = 1 }), read by antidiagonals upwards.

Original entry on oeis.org

1, 2, 1, 3, 2, 1, 4, 4, 2, 1, 5, 5, 4, 2, 1, 6, 7, 6, 4, 2, 1, 7, 8, 9, 6, 4, 2, 1, 8, 10, 10, 10, 6, 4, 2, 1, 9, 11, 13, 11, 10, 6, 4, 2, 1, 10, 13, 15, 15, 12, 10, 6, 4, 2, 1, 11, 14, 17, 17, 17, 12, 10, 6, 4, 2, 1, 12, 16, 19, 20, 20, 18, 12, 10, 6, 4, 2, 1
Offset: 1

Views

Author

Luc Rousseau, Jul 03 2022

Keywords

Comments

Also the number of regions in the 0 < x < y sector of the plane that are delimited by the lines with equations i*x + j*y = 0, where i and j are integers, not both 0, and |i| <= m, |j| <= n. This remark is motivated by Factorization Patterns (FPs) and Factorization Patterns of Sequences of Divisors (FPSD) concerns, as defined in A191743 and A290110. This is the case k=2 of a more general problem where k is omega(z)=A001221(z), the number of distinct primes dividing z, for which we would define T(n1,n2,...,nk) instead of T(m,n). The idea is the following: two numbers (e.g., 12 and 20) can have the same FP (p^2*q) without having the same FPSD ([1 < p < q < p^2 < p*q < p^2*q] != [1 < p < p^2 < q < p*q < p^2*q]). T(m,n) tells how many distinct FPSDs share the same FP of the p^m*q^n form. See the illustration for (m,n) = (2,1), section Links.

Examples

			Let m=2 and n=1. There are exactly two lattice points (i, j) that satisfy 1 <= i <= 2 and 1 <= j <= min(1, i) and GCD(i, j) = 1, namely (1, 1) and (2, 1). So T(2,1) = 2.
Array begins:
  m\n|  1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17
  ---+----------------------------------------------------
   1 |  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1  1
   2 |  2  2  2  2  2  2  2  2  2  2  2  2  2  2  2  2  2
   3 |  3  4  4  4  4  4  4  4  4  4  4  4  4  4  4  4  4
   4 |  4  5  6  6  6  6  6  6  6  6  6  6  6  6  6  6  6
   5 |  5  7  9 10 10 10 10 10 10 10 10 10 10 10 10 10 10
   6 |  6  8 10 11 12 12 12 12 12 12 12 12 12 12 12 12 12
   7 |  7 10 13 15 17 18 18 18 18 18 18 18 18 18 18 18 18
   8 |  8 11 15 17 20 21 22 22 22 22 22 22 22 22 22 22 22
   9 |  9 13 17 20 24 25 27 28 28 28 28 28 28 28 28 28 28
  10 | 10 14 19 22 26 27 30 31 32 32 32 32 32 32 32 32 32
  11 | 11 16 22 26 31 33 37 39 41 42 42 42 42 42 42 42 42
  12 | 12 17 23 27 33 35 40 42 44 45 46 46 46 46 46 46 46
  13 | 13 19 26 31 38 41 47 50 53 55 57 58 58 58 58 58 58
  14 | 14 20 28 33 41 44 50 53 57 59 62 63 64 64 64 64 64
  15 | 15 22 30 36 44 47 54 58 62 64 68 69 71 72 72 72 72
  16 | 16 23 32 38 47 50 58 62 67 69 74 75 78 79 80 80 80
  17 | 17 25 35 42 52 56 65 70 76 79 85 87 91 93 95 96 96
		

Crossrefs

Programs

  • PARI
    T(m, n) = sum(i=1, m, sum(j=1, min(n, i), gcd(i, j)==1))
    for(d=2,10,for(n=1,d-1,my(m=d-n);print1(T(m,n),", ")))

Formula

T(n,n) = A002088(n).
Showing 1-10 of 10 results.