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

A306454 a(n) = A261327(n)/A013946(n).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 25, 1, 1, 25, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 169, 1, 1, 1, 1, 1, 1, 25, 1, 1, 25, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 25, 1, 1, 25, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 289, 1, 1, 1, 1, 1, 841, 1, 1, 1, 25, 1, 1, 25, 1, 1, 1
Offset: 1

Views

Author

Paul Curtz, Feb 16 2019

Keywords

Comments

Are all terms odd squares?
b(n) = A013946(n)*A261327(n) = 25, 4, 169, 25, 841, 100, 2809, 289, 7225, 676, 625, ... . Are all terms squares?
a(n) = A008833(n^2+4) if n is odd and A008833((n^2+4)/4) if n is even, so a(n) is always an odd square. - Jianing Song, Feb 27 2019
Are the square roots only primes?
The sequence of period 4: repeat [25, 1, 1, 25] appears apparently every 25 terms.
From Robert Israel, Mar 20 2019: (Start)
The first term whose square root is not 1 or a prime is a(261) = 25^2.
a(11+25*k) is divisible by 25. The first term where a(11+25*k) > 25 is a(261)=a(11+25*10)=625.
The first term where a(12+25*k) > 1 is a(1212)=a(12+25*48)=169.
The first term where a(13+25*k) > 1 is a(213)=a(13+25*8)=289.
a(14+25*k) is divisible by 25. The first term where a(14+25*k) > 25 is a(364)=a(14+25*14)=625.
All prime factors of members of the sequence are in A002144. For any p in A002144, there is k with 1 <= k < p^2/2 such that p^2 | a(n) if and only if n == k or -k (mod p^2). (End)

Examples

			A261327(n) = 5, 2, 13, 5, 29, 10, 53, 17, 85, 26, 125, 37, 173, 50, ... .
A013946(n) = 5, 2, 13, 5, 29, 10, 53, 17, 85, 26,   5, 37, 173,  2, ... .
		

Crossrefs

Programs

A261327 a(n) = (n^2 + 4) / 4^((n + 1) mod 2).

Original entry on oeis.org

1, 5, 2, 13, 5, 29, 10, 53, 17, 85, 26, 125, 37, 173, 50, 229, 65, 293, 82, 365, 101, 445, 122, 533, 145, 629, 170, 733, 197, 845, 226, 965, 257, 1093, 290, 1229, 325, 1373, 362, 1525, 401, 1685, 442, 1853, 485, 2029, 530, 2213, 577, 2405, 626, 2605, 677
Offset: 0

Views

Author

Paul Curtz, Aug 15 2015

Keywords

Comments

Using (n+sqrt(4+n^2))/2, after the integer 1 for n=0, the reduced metallic means are b(1) = (1+sqrt(5))/2, b(2) = 1+sqrt(2), b(3) = (3+sqrt(13))/2, b(4) = 2+sqrt(5), b(5) = (5+sqrt(29))/2, b(6) = 3+sqrt(10), b(7) = (7+sqrt(53))/2, b(8) = 4+sqrt(17), b(9) = (9+sqrt(85))/2, b(10) = 5+sqrt(26), b(11) = (11+sqrt(125))/2 = (11+5*sqrt(5))/2, ... . The last value yields the radicals in a(n) or A013946.
b(2) = 2.41, b(3) = 3.30, b(4) = 4.24, b(5) = 5.19 are "good" approximations of fractal dimensions corresponding to dimensions 3, 4, 5, 6: 2.48, 3.38, 4.33 and 5.45 based on models. See "Arbres DLA dans les espaces de dimension supérieure: la théorie des peaux entropiques" in Queiros-Condé et al. link. DLA: beginning of the title of the Witten et al. link.
Consider the symmetric array of the half extended Rydberg-Ritz spectrum of the hydrogen atom:
0, 1/0, 1/0, 1/0, 1/0, 1/0, 1/0, 1/0, ...
-1/0, 0, 3/4, 8/9, 15/16, 24/25, 35/36, 48/49, ...
-1/0, -3/4, 0, 5/36, 3/16, 21/100, 2/9, 45/196, ...
-1/0, -8/9, -5/36, 0, 7/144, 16/225, 1/12, 40/441, ...
-1/0, -15/16, -3/16, -7/144, 0, 9/400, 5/144, 33/784, ...
-1/0, -24/25, -21/100, -16/225, -9/400, 0, 11/900, 24/1225, ...
-1/0, -35/36, -2/9, -1/12, -5/144, -11/900, 0, 13/1764, ...
-1/0, -48/49, -45/196, -40/441, -33/784, -24/1225, -13/1764, 0, ... .
The numerators are almost A165795(n).
Successive rows: A000007(n)/A057427(n), A005563(n-1)/A000290(n), A061037(n)/A061038(n), A061039(n)/A061040(n), A061041(n)/A061042(n), A061043(n)/A061044(n), A061045(n)/A061046(n), A061047(n)/A061048(n), A061049(n)/A061050(n).
A144433(n) or A195161(n+1) are the numerators of the second upper diagonal (denominators: A171522(n)).
c(n+1) = a(n) + a(n+1) = 6, 7, 15, 18, 34, 39, 63, 70, 102, 111, ... .
c(n+3) - c(n+1) = 9, 11, 19, 21, 29, 31, ... = A090771(n+2).
The final digit of a(n) is neither 4 nor 8. - Paul Curtz, Jan 30 2019

Crossrefs

Programs

  • Magma
    [Numerator(1+n^2/4): n in [0..60]]; // Vincenzo Librandi, Aug 15 2015
    
  • Maple
    A261327:=n->numer((4 + n^2)/4); seq(A261327(n), n=0..60); # Wesley Ivan Hurt, Aug 15 2015
  • Mathematica
    LinearRecurrence[{0, 3, 0, -3, 0, 1}, {1, 5, 2, 13, 5, 29}, 60] (* Vincenzo Librandi, Aug 15 2015 *)
    a[n_] := (n^2 + 4) / 4^Mod[n + 1, 2]; Table[a[n], {n, 0, 52}] (* Peter Luschny, Mar 18 2022 *)
  • PARI
    vector(60, n, n--; numerator(1+n^2/4)) \\ Michel Marcus, Aug 15 2015
    
  • PARI
    Vec((1+5*x-x^2-2*x^3+2*x^4+5*x^5)/(1-x^2)^3 + O(x^60)) \\ Colin Barker, Aug 15 2015
    
  • PARI
    a(n)=if(n%2,n^2+4,(n/2)^2+1) \\ Charles R Greathouse IV, Oct 16 2015
    
  • Python
    [(n*n+4)//4**((n+1)%2) for n in range(60)] # Gennady Eremin, Mar 18 2022
  • Sage
    [numerator(1+n^2/4) for n in (0..60)] # G. C. Greubel, Feb 09 2019
    

Formula

a(n) = numerator(1 + n^2/4). (Previous name.) See A010685 (denominators).
a(2*k) = 1 + k^2.
a(2*k+1) = 5 + 4*k*(k+1).
a(2*k+1) = 4*a(2*k) + 4*k + 1.
a(4*k+2) = A069894(k). - Paul Curtz, Jan 30 2019
a(-n) = a(n).
a(n+2) = a(n) + A144433(n) (or A195161(n+1)).
a(n) = A168077(n) + period 2: repeat 1, 4.
a(n) = A171621(n) + period 2: repeat 2, 8.
From Colin Barker, Aug 15 2015: (Start)
a(n) = (5 - 3*(-1)^n)*(4 + n^2)/8.
a(n) = n^2/4 + 1 for n even;
a(n) = n^2 + 4 for n odd.
a(n) = 3*a(n-2) - 3*a(n-4) + a(n-6) for n>5.
G.f.: (1 + 5*x - x^2 - 2*x^3 + 2*x^4 + 5*x^5)/ (1 - x^2)^3. (End)
E.g.f.: (5/8)*(x^2 + x + 4)*exp(x) - (3/8)*(x^2 - x + 4)*exp(-x). - Robert Israel, Aug 18 2015
Sum_{n>=0} 1/a(n) = (4*coth(Pi)+tanh(Pi))*Pi/8 + 1/2. - Amiram Eldar, Mar 22 2022

Extensions

New name by Peter Luschny, Mar 18 2022

A181434 First column in matrix inverse of a mixed convolution of A052542.

Original entry on oeis.org

1, -3, -1, 0, -1, 1, -1, 0, 0, 1, -1, 0, -1, 1, 1, 0, -1, 0, -1, 0, 1, 1, -1, 0, 0, 1, 0, 0, -1, -1, -1, 0, 1, 1, 1, 0, -1, 1, 1, 0, -1, -1, -1, 0, 0, 1, -1, 0, 0, 0, 1, 0, -1, 0, 1, 0, 1, 1, -1, 0, -1, 1, 0, 0, 1, -1, -1, 0, 1, -1, -1, 0, -1, 1, 0, 0, 1
Offset: 1

Views

Author

Mats Granvik, Oct 20 2010

Keywords

Comments

It appears that except for the second term, the sequence is identical to the Möbius function.
Explicit numeric calculation confirms this up to at least n=1085. - R. J. Mathar, Oct 06 2017

Crossrefs

Programs

  • Maple
    b := proc(n)
        option remember;
        local c;
        c := 2;
        if n <= 2 then
            n;
        elif n = 3 then
            c^2 ;
        else
            c*procname(n-1)+procname(n-2) ;
        end if;
    end proc:
    A := proc(n,k)
        if n >= k then
            b(n-k+1) ;
        else
            0 ;
        end if;
    end proc:
    B := proc(n,k)
        if modp(n,k) = 0 then
            1;
        else
            0;
        end if;
    end proc:
    AB := proc(n,k)
        option remember;
        add( A(n,j)*B(j,k),j=1..n) ;
    end proc:
    ABinv := proc(n,k)
        option remember;
        if k > n then
            0;
        elif k = n then
            1;
        else
            -add( AB(n,j)*procname(j,k),j=k..n-1) ;
        end if;
    end proc:
    A181434 := proc(n)
        ABinv(n,1) ;
    end proc:
    for n from 1 do
        printf("%d %d\n",n,ABinv(n,1)) ;
    end do: # R. J. Mathar, Oct 06 2017
  • Mathematica
    Clear[t, n, k, nn, b, A, c]; nn = 77; c = 2; b[0] = 1; b[1] = 1; b[n_] := b[n] = c*b[n - 1] + b[n - 2]; t[n_, 1] = If[n >= 1, b[n], 0]; t[n_, k_] := t[n, k] = If[n >= k, Sum[t[n - i, k - 1], {i, 1, k - 1}] - Sum[t[n - i, k], {i, 1, k - 1}], 0]; MatrixForm[A = Table[Table[t[n, k], {k, 1, nn}], {n, 1, nn}]]; Inverse[A][[All, 1]] (* Mats Granvik, Sep 15 2017 *)
  • PARI
    A181434(n)=if(n==2,-3,moebius(n)) \\ M. F. Hasler, Sep 15 2017. - This program seems to be based on a formula that is so far only conjectural? - Antti Karttunen, Oct 06 2017

Formula

From Mats Granvik, Sep 16 2017: (Start)
a(n) as the matrix inverse of a mixed convolution: Let c = 2 and let the sequence b be defined by the recurrence: b(1) = 1, b(2) = c, b(3) = c^2; for n >= 4, b(n) = c*b(n-1) + b(n-2), so b(n) = A052542(n-1), and let the lower triangular matrix A be: If n >= k then A(n,k) = b(n - k + 1) else A(n,k) = 0, and let B be the lower triangular matrix A051731. Then the matrix inverse (A.B)^-1 will have a(n) as its first column.
The matrix product T = A.B can be defined as follows: Let c = 2 and the sequence b be defined by the recurrence b(0) = 1, b(1) = 1; for b >= 2, b(n) = c*b(n - 1) + b(n - 2), so b(n) = A001333(n); and let T be the lower triangular matrix defined by the recurrence: T(n, 1) = If n >= 1 then T(n, 1) = b(n) else T(n, 1) = 0; for k >= 2, T(n, k) = If n >= k then (Sum_{i=1..k-1} T(n - i, k - 1) - T(n - i, k)) else 0. (Then the matrix inverse of T will have a(n) as its first column.)
(End)

A181435 First column in matrix inverse of a mixed convolution of A052906.

Original entry on oeis.org

1, -4, -1, 0, -1, 1, -1, 0, 0, 1, -1, 0, -1, 1, 1, 0, -1, 0, -1, 0, 1, 1, -1, 0, 0, 1, 0, 0, -1, -1, -1, 0, 1, 1, 1, 0, -1, 1, 1, 0, -1, -1, -1, 0, 0, 1, -1, 0, 0, 0, 1, 0, -1, 0, 1, 0, 1, 1, -1, 0, -1, 1, 0, 0, 1, -1, -1, 0, 1, -1, -1, 0, -1, 1, 0, 0, 1
Offset: 1

Views

Author

Mats Granvik, Oct 20 2010

Keywords

Comments

It appears that except for the second term, the sequence is identical to the Möbius function.

Crossrefs

Programs

  • Maple
    b := proc(n)
        option remember;
        local c;
        c := 3;
        if n <= 3 then
            op(n,[1,c,c^2]) ;
        else
            c*procname(n-1)+procname(n-2) ;
        end if;
    end proc:
    A := proc(n,k)
        if n >= k then
            b(n-k+1) ;
        else
            0 ;
        end if;
    end proc:
    B := proc(n,k)
        if modp(n,k) = 0 then
            1;
        else
            0;
        end if;
    end proc:
    AB := proc(n,k)
        option remember;
        add( A(n,j)*B(j,k),j=1..n) ;
    end proc:
    ABinv := proc(n,k)
        option remember;
        if k > n then
            0;
        elif k = n then
            1;
        else
            -add( AB(n,j)*procname(j,k),j=k..n-1) ;
        end if;
    end proc:
    A181435 := proc(n)
        ABinv(n,1) ;
    end proc:
    for n from 1 do
        printf("%d %d\n",n,ABinv(n,1)) ;
    end do: # R. J. Mathar, Oct 06 2017
  • Mathematica
    Clear[t, n, k, nn, b, A, c]; nn = 77; c = 3; b[0] = 1; b[1] = 1; b[n_] := b[n] = c*b[n - 1] + b[n - 2]; t[n_, 1] = If[n >= 1, b[n], 0]; t[n_, k_] := t[n, k] = If[n >= k, Sum[t[n - i, k - 1], {i, 1, k - 1}] - Sum[t[n - i, k], {i, 1, k - 1}], 0]; MatrixForm[A = Table[Table[t[n, k], {k, 1, nn}], {n, 1, nn}]]; Inverse[A][[All, 1]] (* Mats Granvik, Sep 16 2017 *)

Formula

From Mats Granvik, Sep 16 2017: (Start)
a(n) as the matrix inverse of a mixed convolution: Let c = 3 and let the sequence b be defined by the recurrence: b(1) = 1, b(2) = c, b(3) = c^2; for n >= 4, b(n) = c*b(n-1) + b(n-2), so b(n) = A052906(n-1), and let the lower triangular matrix A be: If n >= k then A(n,k) = b(n - k + 1) else A(n,k) = 0, and let B be the lower triangular matrix A051731. Then the matrix inverse (A.B)^-1 will have a(n) as its first column.
The matrix product T = A.B can be defined as follows: Let c = 3 and the sequence b be defined by the recurrence b(0) = 1, b(1) = 1; for b >= 2, b(n) = c*b(n - 1) + b(n - 2); and let T be the lower triangular matrix defined by the recurrence: T(n, 1) = If n >= 1 then T(n, 1) = b(n) else T(n, 1) = 0; for k >= 2, T(n, k) = If n >= k then (Sum_{i=1..k-1} T(n - i, k - 1) - T(n - i, k)) else 0. (Then the matrix inverse of T will have a(n) as its first column.)
(End)

A087642 Sequence of squarefree n such that Q(sqrt(n)) has no element with a fully periodical continued fraction of period 1.

Original entry on oeis.org

3, 6, 7, 11, 14, 15, 19, 21, 22, 23, 30, 31, 33, 34, 35, 38, 39, 42, 43, 46, 47, 51, 55, 57, 59, 62, 66, 67, 69, 70, 71, 77, 78, 79, 83, 86, 87, 91, 93, 94, 95, 102, 103, 105, 107, 110, 111, 114, 115, 118, 119, 123, 127, 129, 131, 133, 134, 138, 139, 141, 142, 143, 146
Offset: 3

Views

Author

Thomas Baruchel, Sep 16 2003

Keywords

Comments

Diophantine equation x^2 - n.y^2 + 4 = 0 has no solution (x,y) for a given squarefree n. Squarefree n not in the sequence A013946. Same sequence with square factors allowed is A087643.

Examples

			3 is in the sequence because no [k,k,k,k,...] is in Q(sqrt(3))
5 is not in the sequence since Q(sqrt(5)) contains [1,1,1,1,...]
		

Crossrefs

Showing 1-5 of 5 results.