A087503
a(n) = 3*(a(n-2) + 1), with a(0) = 1, a(1) = 3.
Original entry on oeis.org
1, 3, 6, 12, 21, 39, 66, 120, 201, 363, 606, 1092, 1821, 3279, 5466, 9840, 16401, 29523, 49206, 88572, 147621, 265719, 442866, 797160, 1328601, 2391483, 3985806, 7174452, 11957421, 21523359, 35872266, 64570080, 107616801, 193710243, 322850406, 581130732
Offset: 0
See
A133629 for general formulas with respect to the recurrence rule parameter p.
-
[(3/2)*(3^Floor((n+1)/2)+3^Floor(n/2)-3^Floor((n-1)/2)-1): n in [0..40]]; // Vincenzo Librandi, Aug 16 2011
-
A087503 := proc(n)
option remember;
if n <=1 then
op(n+1,[1,3]) ;
else
3*procname(n-2)+3 ;
end if;
end proc:
seq(A087503(n),n=0..20) ; # R. J. Mathar, Sep 10 2021
-
RecurrenceTable[{a[0]==1,a[1]==3,a[n]==3(a[n-2]+1)},a,{n,40}] (* or *) LinearRecurrence[{1,3,-3},{1,3,6},40] (* Harvey P. Dale, Jan 01 2015 *)
-
def A087503(n): return (3+((n+1&1)<<1))*3**(n+1>>1)-3>>1 # Chai Wah Wu, Sep 02 2025
Edited by
N. J. A. Sloane, May 04 2010. I merged two essentially identical entries with different offsets, so some of the formulas may need to be adjusted.
A112030
a(n) = (2 + (-1)^n) * (-1)^floor(n/2).
Original entry on oeis.org
3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1, -3, -1, 3, 1
Offset: 0
-
A112030 := proc(n)
(2 + (-1)^n) * (-1)^floor(n/2) ;
end proc: # R. J. Mathar, Jul 09 2013
-
LinearRecurrence[{0, -1}, {3, 1}, 100] (* Jean-François Alcover, Nov 24 2020 *)
-
a(n)=[3,1,-3,-1][n%4+1] \\ Charles R Greathouse IV, Aug 21 2011
-
def A112030(n): return (3, 1, -3, -1)[n&3] # Chai Wah Wu, Jan 31 2023
A228405
Pellian Array, A(n, k) with numbers m such that 2*m^2 +- 2^k is a square, and their corresponding square roots, read downward by diagonals.
Original entry on oeis.org
0, 1, 1, 0, 1, 2, 2, 2, 3, 5, 0, 2, 4, 7, 12, 4, 4, 6, 10, 17, 29, 0, 4, 8, 14, 24, 41, 70, 8, 8, 12, 20, 34, 58, 99, 169, 0, 8, 16, 28, 48, 82, 140, 239, 408, 16, 16, 24, 40, 68, 116, 198, 338, 577, 985, 0, 16, 32, 56, 96, 164, 280, 478, 816, 1393, 2378
Offset: 0
With row # as n. and column # as k, and n, k =>0, the array begins:
0, 1, 0, 2, 0, 4, 0, 8, ...
1, 1, 2, 2, 4, 4, 8, 8, ...
2, 3, 4, 6, 8, 12, 16, 24, ...
5, 7, 10, 14, 20, 28, 40, 56, ...
12, 17, 24, 34, 48, 68, 96, 136, ...
29, 41, 58, 82, 116, 164, 232, 328, ...
70, 99, 140, 198, 280, 396, 560, 792, ...
169, 239, 338, 478, 676, 956, 1352, 1912, ...
408, 577, 816, 1154, 1632, 2308, 3264, 4616, ...
- Seiichi Manyama, Antidiagonals n = 0..139, flattened
- MacTutor, D'Arcy Thompson on Greek irrationals
- D'Arcy Thompson, Excess and Defect: Or the Little More and the Little Less, Mind, New Series, Vol. 38, No. 149 (Jan., 1929), pp. 43-55 (13 pages). See page 50.
A239030
T(n,k)=Number of nXk 0..2 arrays with no element equal to the sum of elements to its left or one plus the sum of the elements above it, modulo 3.
Original entry on oeis.org
1, 1, 2, 1, 3, 2, 1, 4, 4, 4, 1, 5, 7, 11, 4, 1, 6, 11, 28, 16, 8, 1, 7, 16, 59, 54, 43, 8, 1, 8, 22, 110, 149, 212, 64, 16, 1, 9, 29, 189, 354, 806, 428, 171, 16, 1, 10, 37, 306, 757, 2592, 2195, 1652, 256, 32, 1, 11, 46, 473, 1495, 7265, 9319, 11768, 3410, 683, 32, 1, 12, 56
Offset: 1
Some solutions for n=5 k=4
..2..0..0..0....2..0..0..0....2..0..0..0....2..0..0..0....2..0..0..0
..2..0..0..0....1..2..2..0....2..0..0..0....1..0..2..2....1..2..2..0
..1..0..2..2....2..1..2..0....1..0..2..2....2..0..1..2....2..1..2..0
..2..0..1..1....2..0..1..2....1..0..2..1....2..0..0..1....2..0..1..2
..1..0..2..2....1..0..2..2....2..0..0..0....1..0..2..1....1..2..2..1
A056451
Number of palindromes using a maximum of five different symbols.
Original entry on oeis.org
1, 5, 5, 25, 25, 125, 125, 625, 625, 3125, 3125, 15625, 15625, 78125, 78125, 390625, 390625, 1953125, 1953125, 9765625, 9765625, 48828125, 48828125, 244140625, 244140625, 1220703125, 1220703125, 6103515625, 6103515625, 30517578125, 30517578125, 152587890625, 152587890625
Offset: 0
- M. R. Nester (1999). Mathematical investigations of some plant interaction designs. PhD Thesis. University of Queensland, Brisbane, Australia. [See A056391 for pdf file of Chap. 2]
-
[5^Floor((n+1)/2): n in [0..40]]; // Vincenzo Librandi, Aug 16 2011
-
LinearRecurrence[{0,5},{1,5},30] (* or *) Riffle[5^Range[0, 20], 5^Range[20]] (* Harvey P. Dale, Jul 28 2018 *)
Table[5^Ceiling[n/2], {n,0,40}] (* Robert A. Russell, Nov 07 2018 *)
-
vector(40, n, n--; 5^floor((n+1)/2)) \\ G. C. Greubel, Nov 07 2018
A059053
Number of chiral pairs of necklaces with n beads and two colors (color complements being equivalent); i.e., turning the necklace over neither leaves it unchanged nor simply swaps the colors.
Original entry on oeis.org
0, 0, 0, 0, 0, 0, 0, 1, 2, 7, 12, 31, 58, 126, 234, 484, 906, 1800, 3402, 6643, 12624, 24458, 46686, 90157, 172810, 333498, 641340, 1238671, 2388852, 4620006, 8932032, 17302033, 33522698, 65042526, 126258960, 245361172, 477091232
Offset: 0
For a(7) = 1, the chiral pair is AAABABB-AAABBAB.
For a(8) = 2, the chiral pairs are AAAABABB-AAAABBAB and AAABAABB-AAABBAAB.
-
Prepend[Table[DivisorSum[n, EulerPhi[#] StirlingS2[n/# + If[Divisible[#,2],1,0], 2] &] / (2n) - StirlingS2[1+Floor[n/2],2] / 2, {n, 1, 40}],0] (* Robert A. Russell, Oct 02 2018 *)
-
a(n) = {if(n<1, 0, (sumdiv(n, k, eulerphi(2*k) * 2^(n/k)) / (2*n) - 2^(n\2))/2)}; \\ Andrew Howroyd, Nov 03 2019
A074872
Inverse BinomialMean transform of the Fibonacci sequence A000045 (with the initial 0 omitted).
Original entry on oeis.org
1, 1, 5, 5, 25, 25, 125, 125, 625, 625, 3125, 3125, 15625, 15625, 78125, 78125, 390625, 390625, 1953125, 1953125, 9765625, 9765625, 48828125, 48828125, 244140625, 244140625, 1220703125, 1220703125, 6103515625, 6103515625, 30517578125, 30517578125, 152587890625
Offset: 1
A135318
The Kentucky-2 sequence: a(n) = a(n-2) + 2*a(n-4), with a[0..3] = [1, 1, 1, 2].
Original entry on oeis.org
1, 1, 1, 2, 3, 4, 5, 8, 11, 16, 21, 32, 43, 64, 85, 128, 171, 256, 341, 512, 683, 1024, 1365, 2048, 2731, 4096, 5461, 8192, 10923, 16384, 21845, 32768, 43691, 65536, 87381, 131072, 174763, 262144, 349525, 524288, 699051, 1048576, 1398101, 2097152, 2796203
Offset: 0
Let i=0 and m=3. Then U^3 = (2,0,3;0,8,0;6,0,5), and the first-row sum (corresponding to i=0) is 2 + 0 + 3 = 5. Hence a(n) = a(2*m+i) = a(2*3+0) = a(6) = 2 + 3 = 5.
- Vincenzo Librandi, Table of n, a(n) for n = 0..5000
- Minerva Catral et al., Generalizing Zeckendorf's Theorem: The Kentucky Sequence, arXiv:1409.0488 [math.NT], 2014. See 1.3 p. 2, same sequence without the first 2 terms.
- Shaoshi Chen, Hanqian Fang, Sergey Kitaev, and Candice X.T. Zhang, Patterns in Multi-dimensional Permutations, arXiv:2411.02897 [math.CO], 2024. See pp. 2, 17.
- L. E. Jeffery, Unit-primitive matrices.
- Eric Weisstein's World of Mathematics, Cycle Graph
- Eric Weisstein's World of Mathematics, Pebbling Number
- Index entries for linear recurrences with constant coefficients, signature (0,1,0,2).
-
[(2^Floor(n/2)*(5-(-1)^n)+(-1)^Floor(n/2)*(1+(-1)^n))/6: n in [0..50]]; // Vincenzo Librandi, Aug 10 2011
-
a:= n-> (<<0|1>, <2|1>>^(iquo(n, 2, 'm')). <<1, 1+m>>)[1,1]:
seq(a(n), n=0..50); # Alois P. Heinz, May 30 2022
-
LinearRecurrence[{0,1,0,2},{1,1,1,2},40] (* Harvey P. Dale, Oct 14 2015 *)
A215870
T(n,k) = Number of permutations of 0..floor((n*k-2)/2) on odd squares of an n X k array such that each row, column, diagonal and (downwards) antidiagonal of odd squares is increasing.
Original entry on oeis.org
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 5, 4, 4, 1, 1, 1, 1, 5, 12, 10, 4, 1, 1, 1, 1, 14, 29, 78, 20, 8, 1, 1, 1, 1, 14, 110, 262, 189, 50, 8, 1, 1, 1, 1, 42, 290, 3001, 1642, 1233, 100, 16, 1, 1, 1, 1, 42, 1274, 11694, 26451, 15485, 2988, 250, 16, 1, 1, 1, 1, 132
Offset: 1
Some solutions for n=6, k=4:
..x..0..x..1....x..0..x..2....x..0..x..2....x..0..x..1....x..0..x..1
..2..x..3..x....1..x..3..x....1..x..3..x....2..x..3..x....2..x..3..x
..x..4..x..5....x..4..x..6....x..4..x..5....x..4..x..6....x..4..x..6
..6..x..7..x....5..x..7..x....6..x..7..x....5..x..7..x....5..x..7..x
..x..8..x.10....x..8..x.10....x..8..x.10....x..8..x.10....x..8..x..9
..9..x.11..x....9..x.11..x....9..x.11..x....9..x.11..x...10..x.11..x
A216218
Square array T, read by antidiagonals: T(n,k) = 0 if n-k>=2 or if k-n>=2, T(1,0) = T(0,0) = T(0,1) = 1, T(n,k) = T(n-1,k) + T(n,k-1).
Original entry on oeis.org
1, 1, 1, 0, 2, 0, 0, 2, 2, 0, 0, 0, 4, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 8, 8, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 0
Square array begins:
1, 1, 0, 0, 0, 0, 0, 0, ... row n=0
1, 2, 2, 0, 0, 0, 0, 0, ... row n=1
0, 2, 4, 4, 0, 0, 0, 0, ... row n=2
0, 0, 4, 8, 8, 0, 0, 0, ... row n=3
0, 0, 0, 8, 16, 16, 0, 0, ... row n=4
0, 0, 0, 0, 16, 32, 32, 0, ... row n=5
...
Comments