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.

Previous Showing 21-30 of 37 results. Next

A201630 a(n) = a(n-1) + 2*a(n-2) with n>1, a(0)=2, a(1)=7.

Original entry on oeis.org

2, 7, 11, 25, 47, 97, 191, 385, 767, 1537, 3071, 6145, 12287, 24577, 49151, 98305, 196607, 393217, 786431, 1572865, 3145727, 6291457, 12582911, 25165825, 50331647, 100663297, 201326591, 402653185, 805306367, 1610612737, 3221225471, 6442450945, 12884901887
Offset: 0

Views

Author

Bruno Berselli, Dec 03 2011

Keywords

References

  • B. Satyanarayana and K. S. Prasad, Discrete Mathematics and Graph Theory, PHI Learning Pvt. Ltd. (Eastern Economy Edition), 2009, p. 73 (problem 3.3).

Crossrefs

Programs

  • Magma
    [n le 2 select 5*n-3 else Self(n-1)+2*Self(n-2): n in [1..33]];
    
  • Mathematica
    LinearRecurrence[{1, 2}, {2,7}, 33]
  • Maxima
    a[0]:2$ a[1]:7$ a[n]:=a[n-1]+2*a[n-2]$ makelist(a[n], n, 0, 32);
    
  • PARI
    v=vector(33); v[1]=2; v[2]=7; for(i=3, #v, v[i]=v[i-1]+2*v[i-2]); v
    
  • SageMath
    def A201630(n): return 3*2**n - (-1)**n
    print([A201630(n) for n in range(31)]) # G. C. Greubel, Feb 07 2025

Formula

G.f.: (2+5*x)/((1+x)*(1-2*x)).
a(n) = 3*2^n - (-1)^n.
a(n) = 7 + 2*Sum_{i=0..n-2} a(i), for n>0.
a(n) = A097581(A042948(n+1)).
a(n+2) - a(n) = a(n+1) + a(n) = A005010(n).
E.g.f.: 3*exp(2*x) - exp(-x). - G. C. Greubel, Feb 07 2025

A100851 Triangle read by rows: T(n,k) = 2^n * 3^k, 0 <= k <= n, n >= 0.

Original entry on oeis.org

1, 2, 6, 4, 12, 36, 8, 24, 72, 216, 16, 48, 144, 432, 1296, 32, 96, 288, 864, 2592, 7776, 64, 192, 576, 1728, 5184, 15552, 46656, 128, 384, 1152, 3456, 10368, 31104, 93312, 279936, 256, 768, 2304, 6912, 20736, 62208, 186624, 559872, 1679616, 512, 1536, 4608, 13824, 41472, 124416, 373248, 1119744, 3359232, 10077696
Offset: 0

Views

Author

Reinhard Zumkeller, Nov 20 2004

Keywords

Examples

			From _Stefano Spezia_, Apr 28 2024: (Start)
Triangle begins:
   1;
   2,  6;
   4, 12,  36;
   8, 24,  72, 216;
  16, 48, 144, 432, 1296;
  32, 96, 288, 864, 2592, 7776;
  ...
(End)
		

Crossrefs

Programs

Formula

T(n,0) = A000079(n).
T(n,1) = A007283(n) for n>0.
T(n,2) = A005010(n) for n>1.
T(n,n) = A000400(n) = A100852(n,n).
Sum_{k=0..n} T(n, k) = A016129(n).
T(2*n, n) = A001021(n). - Reinhard Zumkeller, Mar 04 2006
G.f.: 1/((1 - 2*x)*(1 - 6*x*y)). - Stefano Spezia, Apr 28 2024
From G. C. Greubel, Nov 11 2024: (Start)
Sum_{k=0..n} (-1)^k*T(n, k) = A053524(n+1).
Sum_{k=0..floor(n/2)} T(n-k, k) = (1/2)*((1-(-1)^n)*A248337((n+1)/2) + (1 + (-1)^n)*A016149(n/2)).
Sum_{k=0..floor(n/2)} (-1)^k*T(n-k, k) = (1/2)*(-1)^floor(n/2)*( (1+(-1)^n) *A051958((n+2)/2) + 2*(1-(-1)^n)*A051958((n+1)/2)). (End)
Sum_{n>=0, k=0..n} 1/T(n,k) = 12/5. - Amiram Eldar, May 12 2025

A247283 Positions of subrecords in A048673.

Original entry on oeis.org

5, 7, 9, 15, 18, 27, 36, 54, 72, 108, 144, 216, 288, 432, 576, 864, 1152, 1728, 2304, 3456, 4608, 6912, 9216, 13824, 18432, 27648, 36864, 55296, 73728, 110592, 147456, 221184, 294912, 442368, 589824, 884736, 1179648, 1769472, 2359296, 3538944, 4718592, 7077888
Offset: 1

Views

Author

Antti Karttunen, Sep 11 2014

Keywords

Comments

Odd bisection seems to be A116453 (i.e. A005010, 9*2^n from a(3)=9 onward).
After terms 7 and 15, even bisection from a(6)=27 onward seems to be A175806 (27*2^n).

Examples

			The fourth (A246360(4) = 5) and the fifth (A246360(5) = 8) record of A048673 (1, 2, 3, 5, 4, 8, ...) occur at A029744(4) = 4 and A029744(5) = 6 respectively. In range between, the maximum must occur at 5, thus a(4-3) = a(1) = 5. (All the previous records of A048673 are in consecutive positions, 1, 2, 3, 4, thus there are no previous subrecords).
The ninth (A246360(9) = 68) and the tenth (A246360(10) = 122) record of A048673 occur at A029744(9) = 24 and A029744(10) = 32 respectively. For n in range 25 .. 31 the values of A048673 are: 25, 26, 63, 50, 16, 53, 19, of which 63 is the maximum, and because it occurs at n = 27, we have a(9-3) = a(6) = 27.
		

Crossrefs

A247284 gives the corresponding values.

Programs

  • PARI
    \\ Compute A245449, A246360, A247283 and A247284 at the same time:
    default(primelimit,(2^31)+(2^30));
    A003961(n) = my(f = factor(n)); for (i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); factorback(f); \\ From Michel Marcus
    A048673(n) = (A003961(n)+1)/2;
    n = 0; i2 = 0; i3 = 0; ir = 0; prevmax = 0; submax = 0; while(n < 2^32, n++; a_n = A048673(n); if((A048673(a_n) == n), i2++; write("b245449.txt", i2, " ", n)); if((a_n > prevmax), if(submax > 0, i3++; write("b247283.txt", i3, " ", submaxpt); write("b247284.txt", i3, " ", submax)); prevmax = a_n; submax = 0; ir++; write("b029744_empirical.txt", ir, " ", n); write("b246360_empirical.txt", ir, " ", a_n), if((a_n > submax), submax = a_n; submaxpt = n)));
    
  • Scheme
    (definec (A247283 n) (max_pt_in_range A048673 (+ (A029744 (+ n 3)) 1) (- (A029744 (+ n 4)) 1)))
    (define (max_pt_in_range intfun lowlim uplim) (let loop ((i (+ 1 lowlim)) (maxnow (intfun lowlim)) (maxpt lowlim)) (cond ((> i uplim) maxpt) (else (let ((v (intfun i))) (if (> v maxnow) (loop (+ 1 i) v i) (loop (+ 1 i) maxnow maxpt)))))))

Formula

a(n) = A064216(A247284(n)).
Conjectures from Chai Wah Wu, Jul 30 2020: (Start)
a(n) = 2*a(n-2) for n > 6.
G.f.: x*(3*x^5 - x^3 + x^2 - 7*x - 5)/(2*x^2 - 1). (End)

A259713 a(n) = 3*2^n - 2*(-1)^n.

Original entry on oeis.org

1, 8, 10, 26, 46, 98, 190, 386, 766, 1538, 3070, 6146, 12286, 24578, 49150, 98306, 196606, 393218, 786430, 1572866, 3145726, 6291458, 12582910, 25165826, 50331646, 100663298, 201326590, 402653186, 805306366, 1610612738, 3221225470, 6442450946, 12884901886
Offset: 0

Views

Author

Paul Curtz, Jul 03 2015

Keywords

Comments

Inverse binomial transform of 3^n, with 3 (second term) excluded.
a(n) mod 9 gives A010689.

Crossrefs

Programs

  • Magma
    [3*2^n-2*(-1)^n: n in [0..40]]; // Vincenzo Librandi, Jul 04 2015
  • Mathematica
    Table[3 2^n - 2 (-1)^n, {n, 0, 50}] (* Vincenzo Librandi, Jul 04 2015 *)
    LinearRecurrence[{1,2},{1,8},40] (* Harvey P. Dale, Aug 19 2020 *)
  • PARI
    Vec(-(7*x+1)/((x+1)*(2*x-1)) + O(x^100)) \\ Colin Barker, Jul 03 2015
    

Formula

a(n) = a(n-1) + 2*a(n-2) for n>1, a(0)=1, a(1)=8.
a(n) = 2*a(n-1) - 6*(-1)^n for n>0, a(0)=1.
a(4n+2) = 10*A182460(n); a(2n) = A096045(n), a(2n+1) = A140788(n).
a(n) = 3*A014551(n+1) - A201630(n).
a(n+2) - a(n) = a(n) + a(n+1) = A005010(n).
G.f.: -(7*x+1) / ((x+1)*(2*x-1)). - Colin Barker, Jul 03 2015

Extensions

Typo in data fixed by Colin Barker, Jul 03 2015

A253145 Triangular numbers (A000217) omitting the term 1.

Original entry on oeis.org

0, 3, 6, 10, 15, 21, 28, 36, 45, 55, 66, 78, 91, 105, 120, 136, 153, 171, 190, 210, 231, 253, 276, 300, 325, 351, 378, 406, 435, 465, 496, 528, 561, 595, 630, 666, 703, 741, 780, 820, 861, 903, 946, 990, 1035, 1081, 1128, 1176, 1225, 1275
Offset: 0

Views

Author

Paul Curtz, Mar 23 2015

Keywords

Comments

The full triangle of the inverse Akiyama-Tanigawa transform applied to (-1)^n*A062510(n)=3*(-1)^n*A001045(n) yielding a(n) is
0, 3, 6, 10, 15, 21, 28, 36, ...
-3, -6, -12, -20, -30, -42, -56, ... essentially -A002378
3, 12, 24, 40, 60, 84, ... essentially A046092
-9, -24, -48, -80, -120, ... essentially -A033996
15, 48, 96, 160, ...
-33, -96, -192, ...
63, 192, ...
-129, ...
etc.
First column: (-1)^n*A062510(n).
The following columns are multiples of A122803(n)=(-2)^n. See A007283(n), A091629(n), A020714(n+1), A110286, A175805(n), 4*A005010(n).
An autosequence of the first kind is a sequence whose main diagonal is A000004 = 0's.
b(n) = 0, 0 followed by a(n) is an autosequence of the first kind.
The successive differences of b(n) are
0, 0, 0, 3, 6, 10, 15, 21, ...
0, 0, 3, 3, 4, 5, 6, 7, ... see A194880(n)
0, 3, 0, 1, 1, 1, 1, 1, ...
3, -3, 1, 0, 0, 0, 0, 0, ...
-6, 4, -1, 0, 0, 0, 0, 0, ...
10, -5, 1, 0, 0, 0, 0, 0, ...
-15, 6, -1, 0, 0, 0, 0, 0, ...
21, -7, 1, 0, 0, 0, 0, 0, ...
The inverse binomial transform (first column) is the signed sequence. This is general.
Also generalized hexagonal numbers without 1. - Omar E. Pol, Mar 23 2015

Crossrefs

Programs

Formula

Inverse Akiyama-Tanigawa transform of (-1)^n*A062510(n).
a(n) = (n+1)*(n+2)/2 for n > 0. - Charles R Greathouse IV, Mar 23 2015
a(n+1) = 3*A001840(n+1) + A022003(n).
a(n) = A161680(n+2) for n >= 1. - Georg Fischer, Oct 30 2018
From Stefano Spezia, May 28 2025: (Start)
G.f.: x*(3 - 3*x + x^2)/(1 - x)^3.
E.g.f.: exp(x)*(2 + 4*x + x^2)/2 - 1. (End)

A336745 Numbers m that divide the product phi(m) * sigma(m) * tau(m), where phi is the Euler totient function (A000010), sigma is the sum of divisors function (A000203) and tau is the number of divisors function (A000005).

Original entry on oeis.org

1, 2, 6, 8, 9, 12, 18, 24, 28, 32, 36, 40, 54, 72, 80, 84, 96, 108, 117, 120, 128, 135, 144, 162, 196, 200, 216, 224, 234, 240, 243, 252, 270, 288, 324, 360, 384, 400, 405, 448, 468, 486, 496, 512, 540, 576, 588, 600, 625, 640, 648, 672, 675, 720, 756, 768, 775, 810, 819
Offset: 1

Views

Author

Bernard Schott, Aug 02 2020

Keywords

Comments

If s and t are terms with gcd(s, t) = 1, then s*t is another term as phi, sigma and tau are multiplicative functions.
The only prime term is 2 because prime p must divide 2*(p-1)*(p+1) to be a term.

Examples

			For 24, phi(24) = 8, sigma(24) = 60 and tau(24) = 8, then 8*60*8 / 24 = 160, hence 24 is a term.
		

Crossrefs

Subsequences: A000396 (perfect numbers), A005820 (tri-perfect), A027687 (4-perfect), A046060 (5-multiperfect), A046061 (6-multiperfect), A007691 (multiply-perfect numbers), A336715 (m divides phi(m)*tau(m)), A004171, A005010.

Programs

  • Maple
    with(numtheory):
    filter:= m -> irem(tau(m)*phi(m)*sigma(m), m) =0:
    select(filter,[$1..850]);
  • Mathematica
    Select[Range[1000], Divisible[Times @@ DivisorSigma[{0, 1}, #] * EulerPhi[#], #] &] (* Amiram Eldar, Aug 02 2020 *)
  • PARI
    isok(m) = !(eulerphi(m)*sigma(m)*numdiv(m) % m); \\ Michel Marcus, Aug 05 2020

A340717 Lexicographically earliest sequence of nonnegative integers with as many distinct values as possible such that for any n >= 0, a(rev(n)) = a(n) (where rev(n) = A030101(n) corresponds to the binary reversal of n).

Original entry on oeis.org

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

Views

Author

Rémy Sigrist, Jan 17 2021

Keywords

Comments

The condition "with as many distinct values as possible" means here that for any distinct m and n, provided the orbits of m and n under the map x -> rev(x) do not merge, then a(m) <> a(n).

Examples

			The first terms, alongside rev(n), are:
  n   a(n)  rev(n)
  --  ----  ------
   0     0       0
   1     1       1
   2     1       1
   3     2       3
   4     1       1
   5     3       5
   6     2       3
   7     4       7
   8     1       1
   9     5       9
  10     3       5
  11     6      13
  12     2       3
  13     6      11
  14     4       7
  15     7      15
		

Crossrefs

See A340716 for similar sequences.

Programs

  • PARI
    See Links section.

Formula

a(2*n) = a(n).
a(n) = 1 iff n is a power of 2.
a(n) = 2 iff n belongs to A007283.
a(n) = 3 iff n belongs to A020714.
a(n) = 4 iff n belongs to A005009.
a(n) = 5 iff n belongs to A005010.
a(A340718(n)) = n (and this is the first occurrence of n in the sequence).

A156067 a(0)=1. a(n)= -2^(n-1)-3*(-1)^n, n>1.

Original entry on oeis.org

1, 2, -5, -1, -11, -13, -35, -61, -131, -253, -515, -1021, -2051, -4093, -8195, -16381, -32771, -65533, -131075, -262141, -524291, -1048573, -2097155, -4194301, -8388611, -16777213, -33554435, -67108861, -134217731, -268435453, -536870915, -1073741821, -2147483651
Offset: 0

Views

Author

Paul Curtz, Feb 03 2009

Keywords

Comments

The main diagonal of the array of A153130 and its successive differences.
A154589 is the second upper diagonal of the array.

Programs

  • Mathematica
    Join[{1},LinearRecurrence[{1,2},{2,-5},40]] (* Harvey P. Dale, Dec 11 2011 *)

Formula

a(n)= +a(n-1) +2*a(n-2), n>2.
G.f.: x*(-2+7*x) / ( (1+x)*(2*x-1) ).
a(n) == A153130(n) (mod 9).
a(n+1)-2*a(n) = (-1)^n*9, n>0.
a(n) = A154589(n)-3*(-1)^n.
a(n)+a(n+3) = -A005010(n-1) = -9*A131577(n).
a(2*n)+a(2*n+1) = -3*2^(2n-1) = -A002023(n-2).

A239303 Triangle of compressed square roots of Gray code * bit-reversal permutation.

Original entry on oeis.org

1, 3, 1, 6, 1, 5, 6, 9, 1, 10, 12, 18, 1, 17, 10, 12, 18, 33, 1, 34, 20, 24, 36, 66, 1, 65, 34, 20, 24, 36, 66, 129, 1, 130, 68, 40, 48, 72, 132, 258, 1, 257, 130, 68, 40, 48, 72, 132, 258, 513, 1, 514, 260, 136, 80
Offset: 1

Views

Author

Tilman Piesk, Mar 14 2014

Keywords

Comments

The permutation that turns a natural ordered into a sequency ordered Walsh matrix of size 2^n is the product of the Gray code permutation A003188(0..2^n-1) and the bit-reversal permutation A030109(n,0..2^n-1).
(This permutation of 2^n elements can be represented by the compression vector [2^(n-1), 3*[2^(n-2)..4,2,1]] with n elements.)
This triangle shows the compression vectors of the unique square roots of these permutations, which correspond to symmetric binary matrices with 2n-1 ones.
(These n X n matrices correspond to graphs that can be described by permutations of n elements, which are shown in A239304.)
Rows of the square array:
T(1,n) = 1,3,6,6,12,12,24,24,48,48,96,96,192,192,384,384,... (compare A003945)
T(2,n) = 1,1,9,18,18,36,36,72,72,144,144,288,288,576,576,... (compare A005010)
Columns of the square array:
T(m,1) = 1,1,5,10,10,20,20,40,40,80,80,160,160,320,320,... (compare A146523)
T(m,2) = 3,1,1,17,34,34,68,68,136,136,272,272,544,544,... (compare A110287)

Examples

			Triangular array begins:
   1
   3   1
   6   1   5
   6   9   1  10
  12  18   1  17  10
  12  18  33   1  34  20
Square array begins:
   1   3   6   6  12  12
   1   1   9  18  18  36
   5   1   1  33  66  66
  10  17   1   1 129 258
  10  34  65   1   1 513
  20  34 130 257   1   1
The Walsh permutation wp(8,12,6,3) = (0,8,12,4, 6,14,10,2, 3,11,15,7, 5,13,9,1) permutes the natural ordered into the sequency ordered Walsh matrix of size 2^4.
Its square root is wp(6,9,1,10) = (0,6,9,15, 1,7,8,14, 10,12,3,5, 11,13,2,4).
So row 4 of the triangular array is (6,9,1,10).
		

Crossrefs

A280173 a(0) = 1, a(n+1) = 2*a(n) + periodic sequence of length 2: repeat [5, -4].

Original entry on oeis.org

1, 7, 10, 25, 46, 97, 190, 385, 766, 1537, 3070, 6145, 12286, 24577, 49150, 98305, 196606, 393217, 786430, 1572865, 3145726, 6291457, 12582910, 25165825, 50331646, 100663297, 201326590, 402653185, 805306366, 1610612737, 3221225470, 6442450945, 12884901886
Offset: 0

Views

Author

Paul Curtz, Dec 28 2016

Keywords

Comments

a(n) mod 9 = period 2: repeat [1, 7].
The last digit from 7 is of period 4: repeat [7, 0, 5, 6].
The bisection A096045 = 1, 10, 46, ... is based on Bernoulli numbers.
a(n) is a companion to A051049(n).
With an initial 0, A051049(n) is an autosequence of the first kind.
With an initial 2, this sequence is an autosequence of the second kind.
See the reference.
Difference table:
1, 7, 10, 25, 46, 97, ... = this sequence.
6, 3, 15, 21, 51, 93, ... = 3*A014551(n)
-3, 12, 6, 30, 42, 102, ... = -3 followed by 6*A014551(n).
The main diagonal of the difference table gives A003945: 1, 3, 6, 12, 24, ...

Examples

			a(0) = 1, a(1) = 2*1 + 5 = 7, a(2) = 2*7 - 4 = 10, a(3) = 2*10 + 5 = 25.
		

Crossrefs

Programs

  • Maple
    seq(3*2^n-(-1)^n*(1+irem(n+1,2)),n=0..32); # Peter Luschny, Dec 29 2016
  • Mathematica
    LinearRecurrence[{2,1,-2},{1,7,10},50] (* Paolo Xausa, Nov 13 2023 *)
  • PARI
    Vec((1 + 5*x - 5*x^2) / ((1 - x)*(1 + x)*(1 - 2*x)) + O(x^40)) \\ Colin Barker, Dec 28 2016

Formula

a(2n) = 3*4^n - 2, a(2n+1) = 6*4^n + 1.
a(n+2) = a(n) + 9*2^n, a(0) = 1, a(1) = 7.
a(n) = 2*A051049(n+1) - A051049(n).
From Colin Barker, Dec 28 2016: (Start)
a(n) = 3*2^n - 2 for n even.
a(n) = 3*2^n + 1 for n odd.
a(n) = 2*a(n-1) + a(n-2) - 2*a(n-3) for n>2.
G.f.: (1 + 5*x - 5*x^2) / ((1 - x)*(1 + x)*(1 - 2*x)).
(End)
Previous Showing 21-30 of 37 results. Next