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

A081352 Main diagonal of square maze arrangement of natural numbers A081349.

Original entry on oeis.org

1, 7, 11, 21, 29, 43, 55, 73, 89, 111, 131, 157, 181, 211, 239, 273, 305, 343, 379, 421, 461, 507, 551, 601, 649, 703, 755, 813, 869, 931, 991, 1057, 1121, 1191, 1259, 1333, 1405, 1483, 1559, 1641, 1721, 1807, 1891, 1981, 2069, 2163, 2255, 2353, 2449, 2551
Offset: 0

Views

Author

Paul Barry, Mar 19 2003

Keywords

Comments

Conjecture: let a and b be integers such that 0 < a < b so that 0 < a/b is a proper fraction. Define the map f(a,b,D) = a/b + gcd(a,b)/D. Of course, all such a/b can be partially ordered by value, i.e., 1/2 = 0.5 < 2/3 = 4/6 = 6/9 = 0.6666... < 3/4 = 6/8 = 0.75 < 4/5 = 0.8 etc. The map f appears to specify a total strict order on the co-domain for all a/b that is consistent with the given partial order of the domain, i.e., the partial order remains intact, while equivalent fractions are given a total strict order themselves. Moreover, equivalent fractions are strictly ordered by numerator (or denominator), e.g., 1/2 < 2/4 < 3/6 etc. The conditions are that for n >= 4 all of the fractions with denominator b <= n are listed and the minimum integer value of D to achieve the total strict order of the co-domain is 2*C(n-1,2) - (-1)^(n-1). So, a(n-3) = D for n >= 4. Example: given n = 4, we have D = 2*(4-1,2) - (-1)^(4-1) = 2*3 + 1 = 7 = a(4-3) = a(1). Partial order of domain. 1/4 < 1/3 < 1/2 = 2/4 < 2/3 < 3/4. Total order of co-domain. f(1,4,7) = 1/4 + 1/7 = 33/84 < f(1,3,7) = 1/3 + 1/7 = 40/84 < f(1,2,7) = 1/2 + 1/7 = 54/84 < f(2,4,7) = 2/4 + 2/7 = 66/84 < f(2,3,7) = 2/3 + 2/7 = 68/84 < f(3,4,7) = 3/4 + 1/7 = 75/84. Observe that if D = 6, then f(2,4,6) = 2/4 + 2/6 = 10/12 = f(2,3,6) = 2/3 + 1/6. Computation shows the same failure to achieve total strict order of the co-domain for D = 2..5. (As a >= 1, then b >=2, from the above). Computation also shows that the conjecture holds for n = 4..17. - Ross La Haye, Oct 02 2016

Crossrefs

Programs

  • Magma
    I:=[1,7,11,21]; [n le 4 select I[n] else 2*Self(n-1)-2*Self(n-3)+Self(n-4): n in [1..50]]; // Vincenzo Librandi, Aug 08 2013
    
  • Maple
    A081352:=n->(n + 1)*(n + 2) - (-1)^n; seq(A081352(n), n=0..50); # Wesley Ivan Hurt, Feb 26 2014
  • Mathematica
    CoefficientList[Series[(1 + 5 x - 3 x^2 + x^3) / ((1 + x) (1 - x)^3), {x, 0, 60}], x] (* Vincenzo Librandi, Aug 08 2013 *)
  • PARI
    x='x+O('x^99); Vec((1+5*x-3*x^2+x^3)/((1+x)*(1-x)^3)) \\ Altug Alkan, Mar 26 2016

Formula

a(n) = (n + 1)*(n + 2) - (-1)^n = 2*C(n+2, 2) - (-1)^n.
G.f.: (1 +5*x -3*x^2 +x^3) / ((1+x)*(1-x)^3). [Bruno Berselli, Aug 01 2010]
a(n) -2*a(n-1) +2*a(n-3) -a(n-4) = 0 with n>3. [Bruno Berselli, Aug 01 2010]
a(n) = 3*A000982(n + 2) - A000982(n + 3). - Miko Labalan, Mar 26 2016
a(n) = A116940(n) + A236283(n + 1). - Miko Labalan, Dec 04 2016
a(n) = (2*n^2 + 6*n - 2*(-1)^n + (-1)^(2*n) + 3)/2. - Kritsada Moomuang, Oct 24 2019

A081350 First column in maze array of natural numbers A081349.

Original entry on oeis.org

1, 2, 3, 4, 15, 16, 35, 36, 63, 64, 99, 100, 143, 144, 195, 196, 255, 256, 323, 324, 399, 400, 483, 484, 575, 576, 675, 676, 783, 784, 899, 900, 1023, 1024, 1155, 1156, 1295, 1296, 1443, 1444, 1599, 1600, 1763, 1764, 1935, 1936, 2115, 2116, 2303, 2304, 2499
Offset: 0

Views

Author

Paul Barry, Mar 19 2003

Keywords

Comments

Interleaves A000466 with even squares A016742.

Crossrefs

Formula

a(0)=1, a(1)=2, a(n)=(n-1)*(n+(-1)^n), n>1.
G.f.: -(2*x^6-10*x^4+x^3+x^2-x-1)/((1-x)^3*(1+x)^2). [Colin Barker, Sep 03 2012]

A081351 First row in square maze array of natural numbers A081349.

Original entry on oeis.org

1, 8, 9, 24, 25, 48, 49, 80, 81, 120, 121, 168, 169, 224, 225, 288, 289, 360, 361, 440, 441, 528, 529, 624, 625, 728, 729, 840, 841, 960, 961, 1088, 1089, 1224, 1225, 1368, 1369, 1520, 1521, 1680, 1681, 1848, 1849, 2024, 2025, 2208, 2209, 2400, 2401, 2600
Offset: 0

Views

Author

Paul Barry, Mar 19 2003

Keywords

Comments

Interleaves the odd squares A016754 with 8 times the triangular numbers A000217.

Crossrefs

Programs

Formula

a(n) = (n+1)*(n+2)-(n+1)*(-1)^n = 2*C(n+2,2)-C(n+1,1)*(-1)^n.
G.f.: (x^3-x^2+7*x+1)/((1-x)^3*(1+x)^2). [Colin Barker, Sep 03 2012]

A081353 Diagonal of square maze arrangement of natural numbers A081349.

Original entry on oeis.org

3, 5, 13, 19, 31, 41, 57, 71, 91, 109, 133, 155, 183, 209, 241, 271, 307, 341, 381, 419, 463, 505, 553, 599, 651, 701, 757, 811, 871, 929, 993, 1055, 1123, 1189, 1261, 1331, 1407, 1481, 1561, 1639, 1723, 1805, 1893, 1979, 2071, 2161, 2257, 2351, 2451, 2549
Offset: 0

Views

Author

Paul Barry, Mar 19 2003

Keywords

Crossrefs

Bisections are in A054554, A125202.

Programs

Formula

a(n) = (n+1)*(n+2)+(-1)^n = 2*binomial(n+2,2)+(-1)^n.
G.f.: (3-x)*(1+x^2)/((1-x)^3*(1+x)). [Colin Barker, Sep 03 2012]
From Wesley Ivan Hurt, Aug 09 2015: (Start)
a(n) = 2*a(n-1)-2*a(n-3)+a(n-4), n>4.
a(n) = n^2+3n+3 if n is even, otherwise n^2+3n+1.
a(n) = A137932(n+3) - A109613(n+1). (End)

A093650 Natural numbers arranged in a square maze beginning 1, 2, 3, then moving right, then up, right, down, left, down, right, etc., and read by antidiagonals upwards.

Original entry on oeis.org

1, 2, 6, 3, 5, 7, 12, 4, 8, 20, 13, 11, 9, 19, 21, 30, 14, 10, 18, 22, 42, 31, 29, 15, 17, 23, 41, 43, 56, 32, 28, 16, 24, 40, 44, 72, 57, 55, 33, 27, 25, 39, 45, 71, 73, 90, 58, 54, 34, 26, 38, 46, 70, 74, 110, 91, 89, 59, 53, 35, 37, 47, 69, 75, 109, 111
Offset: 1

Views

Author

Michael Joseph Halm, May 15 2004

Keywords

Examples

			a(3) = 6 because the maze begins 2 under 1, 3 under 2, 4 right of 3, 5 right of 2 and 6 right of 1.
Array begins:
   1   6---7  20 ...
   |   |   |   |
   2   5   8  19 ...
   |   |   |   |
   3---4   9  18 ...
           |   |
  12--11--10  17 ...
   |           |
  13--14--15--16 ...
  ...
		

Crossrefs

Other square mazes: A081344, A081349.

Extensions

More terms from Jinyuan Wang, Jun 15 2022

A329547 Number of natural numbers k <= n such that k^k is a square.

Original entry on oeis.org

1, 2, 2, 3, 3, 4, 4, 5, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 14, 15, 16, 16, 17, 17, 18, 18, 19, 19, 20, 20, 21, 21, 22, 22, 23, 23, 24, 24, 25, 25, 26, 26, 27, 28, 29, 29, 30, 30, 31, 31, 32, 32, 33, 33, 34, 34, 35, 35, 36, 36, 37, 37, 38, 38, 39, 39, 40, 40
Offset: 1

Views

Author

Pablo Hueso Merino, Nov 16 2019

Keywords

Comments

For even k, k^k is always a square. For odd k, k^k is a square if and only if k is a square.
It seems the unrepeated terms form A266304 \ {0}. - Ivan N. Ianakiev, Nov 21 2019
Indices of unrepeated terms are A081349. - Rémy Sigrist, Dec 07 2019

Examples

			a(5) = 3 because among 1^1, 2^2, ..., 5^5 there are 3 squares: 1^1, 2^2, and 4^4.
		

Crossrefs

Programs

  • Mathematica
    Table[Floor[n/2] + Ceiling[Floor[Sqrt[n]]/2], {n, 1, 100}]
  • PARI
    a(n) = sum(k=1, n, issquare(k^k)); \\ Michel Marcus, Nov 17 2019
    
  • PARI
    first(n) = my(res=vector(n), inc); res[1] = 1; for(i=2, n, inc = (1-(i%2)) || issquare(i); res[i] = res[i-1] + inc); res \\ David A. Corneth, Dec 07 2019
    
  • PARI
    a(n) = n\2 + (sqrtint(n)+1)\2 \\ David A. Corneth, Dec 07 2019
    
  • Python
    from math import isqrt
    def A329547(n): return (n>>1)+(isqrt(n)+1>>1) # Chai Wah Wu, Sep 18 2024

Formula

a(n) = floor(n/2) + ceiling(floor(sqrt(n))/2).
Showing 1-6 of 6 results.