Original entry on oeis.org
1, 5, 9, 25, 49, 113, 225, 481, 961, 1985, 3969, 8065, 16129, 32513, 65025, 130561, 261121, 523265, 1046529, 2095105, 4190209, 8384513, 16769025, 33546241, 67092481, 134201345, 268402689, 536838145, 1073676289, 2147418113, 4294836225, 8589803521, 17179607041
Offset: 0
-
Table[1+2^(n+2)-2^(1+n/2)+(-1)^(n+1) 2^(1+n/2)-2^((n+1)/2)+(-1)^(n+2) 2^((n+1)/2), {n,0,28}] (*or*)
CoefficientList[Series[(-1 - 2 x + 6 x^2 - 4 x^3)/(-1 + 3 x - 6 x^3 + 4 x^4), {x,0,28}], x] (*or*)
LinearRecurrence[{3, 0, -6, 4}, {1, 5, 9, 25}, 29]
-
Vec((-1-2*x+6*x^2-4*x^3) / (-1+3*x-6*x^3+4*x^4) + O(x^29))
A027383
a(2*n) = 3*2^n - 2; a(2*n+1) = 2^(n+2) - 2.
Original entry on oeis.org
1, 2, 4, 6, 10, 14, 22, 30, 46, 62, 94, 126, 190, 254, 382, 510, 766, 1022, 1534, 2046, 3070, 4094, 6142, 8190, 12286, 16382, 24574, 32766, 49150, 65534, 98302, 131070, 196606, 262142, 393214, 524286, 786430, 1048574, 1572862, 2097150, 3145726, 4194302, 6291454
Offset: 0
After 3 folds one sees 4 fold lines.
Example: a(3) = 6 because the strings 001, 010, 100, 011, 101, 110 have the property.
Binary: 1, 10, 100, 110, 1010, 1110, 10110, 11110, 101110, 111110, 1011110, 1111110, 10111110, 11111110, 101111110, 111111110, 1011111110, 1111111110, 10111111110, ... - _Jason Kimberley_, Nov 02 2011
Example: Partial sums of powers of 2 repeated 2 times:
a(3) = 1+1+2 = 4;
a(4) = 1+1+2+2 = 6;
a(5) = 1+1+2+2+4 = 10.
_Yuchun Ji_, Nov 16 2018
- John P. McSorley: Counting k-compositions of n with palindromic and related structures. Preprint, 2010. [John P. McSorley, Sep 28 2010]
- Vincenzo Librandi, Table of n, a(n) for n = 0..5000
- J. Jordan and R. Southwell, Further Properties of Reproducing Graphs, Applied Mathematics, Vol. 1 No. 5, 2010, pp. 344-350. - From _N. J. A. Sloane_, Feb 03 2013
- Leonard F. Klosinski, Gerald L. Alexanderson and Loren C. Larson, Under misprinted head B3, Amer Math. Monthly, 104(1997) 753-754.
- Laurent Noé, Spaced seed design on profile HMMs for precise HTS read-mapping efficient sliding window product on the matrix semi-group, in Rapide Bilan 2012-2013, LIFL, Université Lille 1 - INRIA Journées au vert 11 et 12 juin 2013.
- Eric Weisstein's World of Mathematics, Cage Graph
- Index entries for sequences obtained by enumerating foldings
- Index entries for linear recurrences with constant coefficients, signature (1,2,-2).
Moore lower bound on the order of a (k,g) cage:
A198300 (square); rows:
A000027 (k=2), this sequence (k=3),
A062318 (k=4),
A061547 (k=5),
A198306 (k=6),
A198307 (k=7),
A198308 (k=8),
A198309 (k=9),
A198310 (k=10),
A094626 (k=11); columns:
A020725 (g=3),
A005843 (g=4),
A002522 (g=5),
A051890 (g=6),
A188377 (g=7). -
Jason Kimberley, Oct 30 2011
Cf.
A000066 (actual order of a (3,g)-cage).
a(n) =
A305540(n+2,2), the second column of the triangle.
Numbers whose binary expansion is a balanced word are
A330029.
The complementary compositions are counted by
A274230(n-1) + 1, with bisections
A060867 (even) and
A134057 (odd).
The following sequences are all essentially the same, in the sense that they are simple transformations of each other, with
A029744 = {s(n), n>=1}, the numbers 2^k and 3*2^k, as the parent:
A029744 (s(n));
A052955 (s(n)-1),
A027383 (s(n)-2),
A354788 (s(n)-3),
A347789 (s(n)-4),
A209721 (s(n)+1),
A209722 (s(n)+2),
A343177 (s(n)+3),
A209723 (s(n)+4);
A060482,
A136252 (minor differences from
A354788 at the start);
A354785 (3*s(n)),
A354789 (3*s(n)-7). The first differences of
A029744 are 1,1,1,2,2,4,4,8,8,... which essentially matches eight sequences:
A016116,
A060546,
A117575,
A131572,
A152166,
A158780,
A163403,
A320770. The bisections of
A029744 are
A000079 and
A007283. -
N. J. A. Sloane, Jul 14 2022
-
import Data.List (transpose)
a027383 n = a027383_list !! n
a027383_list = concat $ transpose [a033484_list, drop 2 a000918_list]
-- Reinhard Zumkeller, Jun 17 2015
-
[2^Floor((n+2)/2)+2^Floor((n+1)/2)-2: n in [0..50]]; // Vincenzo Librandi, Aug 16 2011
-
a[0]:=0:a[1]:=1:for n from 2 to 100 do a[n]:=2*a[n-2]+2 od: seq(a[n], n=1..41); # Zerinvary Lajos, Mar 16 2008
-
a[n_?EvenQ] := 3*2^(n/2)-2; a[n_?OddQ] := 2^(2+(n-1)/2)-2; Table[a[n], {n, 0, 40}] (* Jean-François Alcover, Oct 21 2011, after Quim Castellsaguer *)
LinearRecurrence[{1, 2, -2}, {1, 2, 4}, 41] (* Robert G. Wilson v, Oct 06 2014 *)
Table[Length[Select[Tuples[{0,1},n],And[Max@@Length/@Split[#]<=2,!MatchQ[Length/@Split[#],{_,2,ins:1..,2,_}/;OddQ[Plus[ins]]]]&]],{n,0,15}] (* Gus Wiseman, Nov 28 2019 *)
-
a(n)=2^(n\2+1)+2^((n+1)\2)-2 \\ Charles R Greathouse IV, Oct 21 2011
-
def a(n): return 2**((n+2)//2) + 2**((n+1)//2) - 2
print([a(n) for n in range(43)]) # Michael S. Branicky, Feb 19 2022
More terms from Larry Reeves (larryr(AT)acm.org), Mar 24 2000
A014551
Jacobsthal-Lucas numbers.
Original entry on oeis.org
2, 1, 5, 7, 17, 31, 65, 127, 257, 511, 1025, 2047, 4097, 8191, 16385, 32767, 65537, 131071, 262145, 524287, 1048577, 2097151, 4194305, 8388607, 16777217, 33554431, 67108865, 134217727, 268435457, 536870911, 1073741825, 2147483647, 4294967297, 8589934591
Offset: 0
- G. Everest, A. van der Poorten, I. Shparlinski and T. Ward, Recurrence Sequences, Amer. Math. Soc., 2003; see esp. pp. 180, 255.
- Lind and Marcus, An Introduction to Symbolic Dynamics and Coding, Cambridge University Press, 1995. (General material on subshifts of finite type)
- Kritkhajohn Onphaeng and Prapanpong Pongsriiam. Jacobsthal and Jacobsthal-Lucas Numbers and Sums Introduced by Jacobsthal and Tverberg. Journal of Integer Sequences, Vol. 20 (2017), Article 17.3.6.
- Abdelmoumène Zekiri, Farid Bencherif, Rachid Boumahdi, Generalization of an Identity of Apostol, J. Int. Seq., Vol. 21 (2018), Article 18.5.1.
- T. D. Noe, Table of n, a(n) for n = 0..200
- Kunle Adegoke, Robert Frontczak, and Taras Goy, Partial sum of the products of the Horadam numbers with subscripts in arithmetic progression, Notes on Num. Theor. and Disc. Math. (2021) Vol. 27, No. 2, 54-63.
- Tewodros Amdeberhan, A note on Fibonacci-type polynomials, arXiv:0811.4652 [math.NT], 2008.
- Hacène Belbachir, Amine Belkhir, and Ihab-Eddin Djellas, Permanent of Toeplitz-Hessenberg Matrices with Generalized Fibonacci and Lucas entries, Applications and Applied Mathematics: An International Journal (AAM 2022), Vol. 17, Iss. 2, Art. 15, 558-570.
- Paula Catarino, Helena Campos, and Paulo Vasco. On the Mersenne sequence. Annales Mathematicae et Informaticae, 46 (2016), pp. 37-53.
- Charles K. Cook and Michael R. Bacon, Some identities for Jacobsthal and Jacobsthal-Lucas numbers satisfying higher order recurrence relations, Annales Mathematicae et Informaticae, 41 (2013), pp. 27-39.
- Fatih Erduvan and Refik Keskin, Fibonacci And Lucas Numbers Which Are Product Of Two Jacobsal-Lucas Numbers [sic], Appl. Math. E-Notes (2023) Vol. 23, 60-70.
- M. C. Firengiz and A. Dil, Generalized Euler-Seidel method for second order recurrence relations, Notes on Number Theory and Discrete Mathematics, Vol. 20, 2014, No. 4, 21-32.
- Élis Gardel da Costa Mesquita, Eudes Antonio Costa, Paula M. M. C. Catarino, and Francisco R. V. Alves, Jacobsthal-Mulatu Numbers, Latin Amer. J. Math. (2025) Vol. 4, No. 1, 23-45. See p. 24.
- A. F. Horadam, Jacobsthal and Pell Curves, Fib. Quart. 26, 79-83, 1988.
- A. F. Horadam, Jacobsthal Representation Numbers, Fib Quart. 34, 40-54, 1996.
- D. Jhala, G. P. S. Rathore, and K. Sisodiya, Some Properties of k-Jacobsthal Numbers with Arithmetic Indexes, Turkish Journal of Analysis and Number Theory, 2014, Vol. 2, No. 4, 119-124.
- Thomas Koshy and Ralph P. Grimaldi, Ternary words and Jacobsthal numbers, Fib. Quart., 55 (No. 2, 2017), 129-136.
- Kritkhajohn Onphaeng, Tammatada Khemaratchatakumthorn, and Prapanpong Pongsriiam, Inequalities for Inclusion-Exclusion-Like Sums Involving the Ceiling and the Nearest Integer Functions, Integers (2025) Vol. 25, Art. No. A45. See p. 3.
- Mihai Prunescu and Lorenzo Sauras-Altuzarra, On the representation of C-recursive integer sequences by arithmetic terms, arXiv:2405.04083 [math.LO], 2024. See p. 16.
- Yash Puri and Thomas Ward, Arithmetic and growth of periodic orbits, J. Integer Seqs., Vol. 4 (2001), Article 01.2.1.
- M. Rahmani, The Akiyama-Tanigawa matrix and related combinatorial identities, Linear Algebra and its Applications 438 (2013) 219-230. - From _N. J. A. Sloane_, Dec 26 2012
- Mario Raso, Integer Sequences in Cryptography: A New Generalized Family and its Application, Ph. D. Thesis, Sapienza University of Rome (Italy 2025). See p. 41.
- Yüksel Soykan, On Summing Formulas For Generalized Fibonacci and Gaussian Generalized Fibonacci Numbers, Advances in Research (2019) Vol. 20, No. 2, 1-15, Article AIR.51824.
- Yüksal Soykan, On Summing Formulas for Horadam Numbers, Asian Journal of Advanced Research and Reports (2020) Vol. 8, Issue 1, 45-61.
- Yüksel Soykan, Generalized Fibonacci Numbers: Sum Formulas, Journal of Advances in Mathematics and Computer Science (2020) Vol. 35, No. 1, 89-104.
- Yüksel Soykan, Closed Formulas for the Sums of Squares of Generalized Fibonacci Numbers, Asian Journal of Advanced Research and Reports (2020) Vol. 9, No. 1, 23-39, Article no. AJARR.55441.
- Yüksel Soykan, Closed Formulas for the Sums of Cubes of Generalized Fibonacci Numbers: Closed Formulas of Sum_{k=0..n} W_k^3 and Sum_{k=1..n} W_(-k)^3, Archives of Current Research International (2020) Vol. 20, Issue 2, 58-69.
- Yüksel Soykan, A Study on Generalized Fibonacci Numbers: Sum Formulas Sum_{k=0..n} k * x^k * W_k^3 and Sum_{k=1..n} k * x^k W_-k^3 for the Cubes of Terms, Earthline Journal of Mathematical Sciences (2020) Vol. 4, No. 2, 297-331.
- Yüksel Soykan, On Generalized (r, s)-numbers, Int. J. Adv. Appl. Math. and Mech. (2020) Vol. 8, No. 1, 1-14.
- Yüksel Soykan, Erkan Taşdemir, and İnci Okumuş, On Dual Hyperbolic Numbers With Generalized Jacobsthal Numbers Components, Zonguldak Bülent Ecevit University, (Zonguldak, Turkey, 2019).
- Anetta Szynal-Liana, Iwona Włoch, and Mirosław Liana, Generalized commutative quaternion polynomials of the Fibonacci type, Annales Math. Sect. A, Univ. Mariae Curie-Skłodowska (Poland 2022) Vol. 76, No. 2, 33-44.
- Elif Tan, Luka Podrug, and Vesna Iršič Chenoweth, Horadam-Lucas Cubes, Axioms (2024) Vol. 13, No. 12, 837.
- Kai Wang, On Horadam Sequences and Related Infinite Series, (2020).
- Kai Wang, General Identities for Horadam Sequences, (2020).
- Eric Weisstein's World of Mathematics, Jacobsthal Number.
- Wikipedia, Lucas sequence.
- OEIS Wiki, Autosequence.
- Volkan Yildiz, Some divisibility properties of Jacobsthal numbers, arXiv:2212.08814 [math.CO], 2022.
- Index entries for linear recurrences with constant coefficients, signature (1,2).
- Index entries for Lucas sequences.
- Index entries for sequences related to Chebyshev polynomials.
-
a014551 n = a000079 n + a033999 n
a014551_list = map fst $ iterate (\(x,s) -> (2 * x - 3 * s, -s)) (2, 1)
-- Reinhard Zumkeller, Jan 02 2013
-
[2^n + (-1)^n: n in [0..30]]; // G. C. Greubel, Dec 17 2017
-
f[n_]:=2/(n+1);x=4;Table[x=f[x];Denominator[x],{n,0,5!}] (* Vladimir Joseph Stephan Orlovsky, Mar 12 2010 *)
nxt[{n_,a_}]:={n+1,2a-3(-1)^(n+1)}; Transpose[NestList[nxt,{1,2},40]] [[2]] (* Harvey P. Dale, May 27 2013 *)
LinearRecurrence[{1, 2}, {2, 1}, 40] (* Jean-François Alcover, Jan 07 2019 *)
-
a(n)=2^n+(-1)^n \\ Charles R Greathouse IV, Nov 20 2012
-
[lucas_number2(n,1,-2) for n in range(0, 32)] # Zerinvary Lajos, Apr 30 2009
A020522
a(n) = 4^n - 2^n.
Original entry on oeis.org
0, 2, 12, 56, 240, 992, 4032, 16256, 65280, 261632, 1047552, 4192256, 16773120, 67100672, 268419072, 1073709056, 4294901760, 17179738112, 68719214592, 274877382656, 1099510579200, 4398044413952, 17592181850112, 70368735789056, 281474959933440
Offset: 0
n=5: a(5) = 4^5 - 2^5 = 1024 - 32 = 992 -> '1111100000'.
- Vincenzo Librandi, Table of n, a(n) for n = 0..170
- M. Archibald, A. Blecher, A. Knopfmacher, and M. E. Mays, Inversions and Parity in Compositions of Integers, J. Int. Seq., Vol. 23 (2020), Article 20.4.1.
- Tom Copeland, The Kervaire-Milnor formula
- John Elias, Illustration of initial terms: Twin 2^n hexagonal numbers
- L. H. Harper, Optimal Assignment of Numbers to Vertices, J. SIAM 12(1), p. 131--135, March 1964; alternative link.
- Ross La Haye, Binary Relations on the Power Set of an n-Element Set, Journal of Integer Sequences, Vol. 12 (2009), Article 09.2.6.
- The Sixtieth William Lowell Putnam Mathematical Competition, Question A6, Amer. Math. Monthly 107 (Oct 2000), 721-732; see p. 725.
- Index entries for linear recurrences with constant coefficients, signature (6,-8).
Ratio of successive terms of
A028365.
-
a020522 = (* 2) . a006516 -- Reinhard Zumkeller, Dec 15 2015
-
[4^n - 2^n: n in [0..60]]; // Vincenzo Librandi, Apr 26 2011
-
A020522:=n->4^n-2^n; seq(A020522(n), n=0..50); # Wesley Ivan Hurt, Nov 29 2013
-
Table[4^n - 2^n, {n, 40}] (* or *) LinearRecurrence[{6, -8}, {0, 2}, 40] (* Vladimir Joseph Stephan Orlovsky, Feb 20 2012 *)
-
a(n)=4^n-2^n \\ Charles R Greathouse IV, Jan 30 2012
-
def A020522(n): return (1<Chai Wah Wu, Mar 10 2025
-
[4^n - 2^n for n in range(0,23)] # Zerinvary Lajos, Jun 05 2009
A028243
a(n) = 3^(n-1) - 2^n + 1 (essentially Stirling numbers of second kind).
Original entry on oeis.org
0, 0, 2, 12, 50, 180, 602, 1932, 6050, 18660, 57002, 173052, 523250, 1577940, 4750202, 14283372, 42915650, 128878020, 386896202, 1161212892, 3484687250, 10456158900, 31372671002, 94126401612, 282395982050, 847221500580, 2541731610602, 7625329049532
Offset: 1
- Seiichi Manyama, Table of n, a(n) for n = 1..2096
- Ovidiu Bagdasar, On some functions involving the lcm and gcd of integer tuples, Scientific Publications of the State University of Novi Pazar, Appl. Maths. Inform. and Mech., Vol. 6, 2 (2014), 91-100.
- J. Brandts and C. Cihangir, Counting triangles that share their vertices with the unit n-cube, in Conference Applications of Mathematics 2013 in honor of the 70th birthday of Karel Segeth. Jan Brandts, Sergey Korotov, et al., eds., Institute of Mathematics AS CR, Prague 2013.
- K. S. Immink, Coding Schemes for Multi-Level Channels that are Intrinsically Resistant Against Unknown Gain and/or Offset Using Reference Symbols, Electronics Letters, Volume: 50, Issue: 1, January 2 2014.
- Milan Janjic, Enumerative Formulas for Some Functions on Finite Sets
- Ross La Haye, Binary Relations on the Power Set of an n-Element Set, Journal of Integer Sequences, Vol. 12 (2009), Article 09.2.6.
- P. Melotti, S. Ramassamy and P. Thévenin, Points and lines configurations for perpendicular bisectors of convex cyclic polygons, arXiv:2003.11006 [math.CO], 2020.
- Rajesh Kumar Mohapatra and Tzung-Pei Hong, On the Number of Finite Fuzzy Subsets with Analysis of Integer Sequences, Mathematics (2022) Vol. 10, No. 7, 1161.
- Kevin Ryde, Iterations of the Terdragon Curve, see index "T triple-visited points".
- Eric Weisstein's World of Mathematics, Minimum Vertex Coloring.
- Eric Weisstein's World of Mathematics, Prism Graph.
- Index entries for linear recurrences with constant coefficients, signature (6,-11,6).
-
[3^(n-1) - 2*2^(n-1) + 1: n in [1..30]]; // G. C. Greubel, Nov 19 2017
-
Table[2 StirlingS2[n, 3], {n, 24}] (* or *)
Table[3^(n - 1) - 2*2^(n - 1) + 1, {n, 24}] (* or *)
Rest@ CoefficientList[Series[-2 x^3/(-1 + x)/(-1 + 3 x)/(-1 + 2 x), {x, 0, 24}], x] (* Michael De Vlieger, Sep 24 2016 *)
-
a(n) = 3^(n-1) - 2*2^(n-1) + 1 \\ G. C. Greubel, Nov 19 2017
-
[stirling_number2(i,3)*2 for i in range(1,30)] # Zerinvary Lajos, Jun 26 2008
A274230
Number of holes in a sheet of paper when you fold it n times and cut off the four corners.
Original entry on oeis.org
0, 0, 1, 3, 9, 21, 49, 105, 225, 465, 961, 1953, 3969, 8001, 16129, 32385, 65025, 130305, 261121, 522753, 1046529, 2094081, 4190209, 8382465, 16769025, 33542145, 67092481, 134193153, 268402689, 536821761, 1073676289, 2147385345
Offset: 0
- Paolo P. Lava, Table of n, a(n) for n = 0..1000
- Philippe Gibone, Illustration of a(0)-a(4) (idealized).
- Talmon Silver, Illustration of alternating dragon.
- N. J. A. Sloane, Illustration for a(4) = 9 (scan of an actual cut-up piece of paper)
- N. J. A. Sloane, Illustration for a(5) = 21 (scan of an actual cut-up piece of paper)
- Index entries for linear recurrences with constant coefficients, signature (3,0,-6,4).
This is the main diagonal of
A274635.
Counting fold lines instead of holes gives
A027383.
Cf.
A000712,
A001405,
A008549,
A011782,
A026010,
A052955,
A097613,
A126869,
A138364,
A232580,
A351003.
A160414
Number of "ON" cells at n-th stage in simple 2-dimensional cellular automaton (same as A160410, but a(1) = 1, not 4).
Original entry on oeis.org
0, 1, 9, 21, 49, 61, 97, 133, 225, 237, 273, 309, 417, 453, 561, 669, 961, 973, 1009, 1045, 1153, 1189, 1297, 1405, 1729, 1765, 1873, 1981, 2305, 2413, 2737, 3061, 3969, 3981, 4017, 4053, 4161, 4197, 4305, 4413, 4737, 4773, 4881, 4989, 5313, 5421, 5745
Offset: 0
From _Omar E. Pol_, Sep 24 2015: (Start)
With the positive terms written as an irregular triangle in which the row lengths are the terms of A011782 the sequence begins:
1;
9;
21, 49;
61, 97, 133, 225;
237, 273, 309, 417, 453, 561, 669, 961;
...
Right border gives A060867.
This triangle T(n,k) shares with the triangle A256530 the terms of the column k, if k is a power of 2, for example both triangles share the following terms: 1, 9, 21, 49, 61, 97, 225, 237, 273, 417, 961, etc.
.
Illustration of initial terms, for n = 1..10:
. _ _ _ _ _ _ _ _
. | _ _ | | _ _ |
. | | _|_|_ _ _ _ _ _ _ _ _ _ _|_|_ | |
. | |_| _ _ _ _ _ _ _ _ |_| |
. |_ _| | _|_ _|_ | | _|_ _|_ | |_ _|
. | |_| _ _ |_| |_| _ _ |_| |
. | | | _|_|_ _ _|_|_ | | |
. | _| |_| _ _ _ _ |_| |_ |
. | | |_ _| | _|_|_ | |_ _| | |
. | |_ _| | |_| _ |_| | |_ _| |
. | _ _ | _| |_| |_ | _ _ |
. | | _|_| | |_ _ _| | |_|_ | |
. | |_| _| |_ _| |_ _| |_ |_| |
. | | | |_ _ _ _ _ _ _| | | |
. | _| |_ _| |_ _| |_ _| |_ |
. _ _| | |_ _ _ _| | | |_ _ _ _| | |_ _
. | _| |_ _| |_ _| |_ _| |_ _| |_ |
. | | |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _| | |
. | |_ _| | | |_ _| |
. |_ _ _ _| |_ _ _ _|
.
After 10 generations there are 273 ON cells, so a(10) = 273.
(End)
- Paolo Xausa, Table of n, a(n) for n = 0..10000
- David Applegate, Omar E. Pol and N. J. A. Sloane, The Toothpick Sequence and Other Sequences from Cellular Automata, Congressus Numerantium, Vol. 206 (2010), 157-191. [There is a typo in Theorem 6: (13) should read u(n) = 4.3^(wt(n-1)-1) for n >= 2.]
- Omar E. Pol, Illustration of initial terms
- Omar E. Pol, Illustration of the structure after 24th stage (contains 1729 ON cells)
- N. J. A. Sloane, Catalog of Toothpick and Cellular Automata Sequences in the OEIS
- Index entries for sequences related to cellular automata
Cf.
A001235,
A011541,
A011782,
A000225,
A060867,
A139250,
A147562,
A160117,
A160118,
A160410,
A160412,
A161415,
A160720,
A160727,
A151725,
A256530,
A256534.
-
read("transforms") ; isA000079 := proc(n) if type(n,'even') then nops(numtheory[factorset](n)) = 1 ; else false ; fi ; end proc:
A048883 := proc(n) 3^wt(n) ; end proc:
A161415 := proc(n) if n = 1 then 1; elif isA000079(n) then 4*A048883(n-1)-2*n ; else 4*A048883(n-1) ; end if; end proc:
A160414 := proc(n) add( A161415(k),k=1..n) ; end proc: seq(A160414(n),n=0..90) ; # R. J. Mathar, Oct 16 2010
-
A160414list[nmax_]:=Accumulate[Table[If[n<2,n,4*3^DigitCount[n-1,2,1]-If[IntegerQ[Log2[n]],2n,0]],{n,0,nmax}]];A160414list[100] (* Paolo Xausa, Sep 01 2023, after R. J. Mathar *)
-
my(s=-1, t(n)=3^norml2(binary(n-1))-if(n==(1<Altug Alkan, Sep 25 2015
A090025
Number of distinct lines through the origin in 3-dimensional cube of side length n.
Original entry on oeis.org
0, 7, 19, 49, 91, 175, 253, 415, 571, 805, 1033, 1423, 1723, 2263, 2713, 3313, 3913, 4825, 5491, 6625, 7513, 8701, 9811, 11461, 12637, 14497, 16045, 18043, 19807, 22411, 24163, 27133, 29485, 32425, 35065, 38593, 41221, 45433, 48727, 52831
Offset: 0
a(2) = 19 because the 19 points with at least one coordinate=2 all make distinct lines and the remaining 7 points and the origin are on those lines.
Cf.
A000225,
A001047,
A060867,
A090020,
A090021,
A090022,
A090023,
A090024 are for n dimensions with side length 1, 2, 3, 4, 5, 6, 7, 8, respectively.
A049691,
A090025,
A090026,
A090027,
A090028,
A090029 are this sequence for 2, 3, 4, 5, 6, 7 dimensions.
A090030 is the table for n dimensions, side length k.
-
aux[n_, k_] := If[k == 0, 0, (k + 1)^n - k^n - Sum[aux[n, Divisors[k][[i]]], {i, 1, Length[Divisors[k]] - 1}]];lines[n_, k_] := (k + 1)^n - Sum[Floor[k/i - 1]*aux[n, i], {i, 1, Floor[k/2]}] - 1;Table[lines[3, k], {k, 0, 40}]
a[n_] := Sum[MoebiusMu[k]*((Floor[n/k]+1)^3-1), {k, 1, n}]; Table[a[n], {n, 0, 39}] (* Jean-François Alcover, Nov 28 2013, after Vladeta Jovovic *)
-
a(n)=(n+1)^3-sum(j=2,n+1,a(floor(n/j)))
-
from functools import lru_cache
@lru_cache(maxsize=None)
def A090025(n):
if n == 0:
return 0
c, j = 1, 2
k1 = n//j
while k1 > 1:
j2 = n//k1 + 1
c += (j2-j)*A090025(k1)
j, k1 = j2, n//j2
return (n+1)**3-c+7*(j-n-1) # Chai Wah Wu, Mar 30 2021
A090020
Number of distinct lines through the origin in the n-dimensional lattice of side length 4.
Original entry on oeis.org
0, 1, 13, 91, 529, 2851, 14833, 75811, 383809, 1932931, 9705553, 48648931, 243605089, 1219100611, 6098716273, 30503196451, 152544778369, 762810181891, 3814309582993, 19072323542371, 95363943807649, 476826695752771
Offset: 0
a(2) = 13 because in 2D the lines have slope 0, 1/4, 1/3, 1/2, 2/3, 3/4, 1, 4/3, 3/2, 2, 3, 4 and infinity.
a(n) = T(n,4) from
A090030. Cf.
A000225,
A001047,
A060867,
A090021,
A090022,
A090023,
A090024 are for dimension n with side lengths 1, 2, 3, 5, 6, 7, 8 respectively.
A049691,
A090025,
A090026,
A090027,
A090028,
A090029 are for side length k in 2, 3, 4, 5, 6, 7 dimensions.
-
Table[5^n - 3^n - 2^n + 1, {n, 0, 25}]
LinearRecurrence[{11,-41,61,-30},{0,1,13,91},30] (* Indranil Ghosh, Feb 21 2017 *)
-
def A090020(n): return 5**n-3**n-2**n+1 # Indranil Ghosh, Feb 21 2017
A090022
Number of distinct lines through the origin in the n-dimensional lattice of side length 6.
Original entry on oeis.org
0, 1, 25, 253, 2065, 15541, 112825, 804973, 5692705, 40071781, 281367625, 1972955293, 13823978545, 96820307221, 677949854425, 4746473419213, 33228592555585, 232613204977861, 1628344491013225, 11398619145204733
Offset: 0
a(2) = 25 because in 2D the lines have slope 0, 1/6, 5/6, 1/5, 2/5, 3/5, 4/5, 1/4, 3/4, 1/3, 2/3, 1/2, 1 and their reciprocals.
a(n) = T(n, 5) from
A090030. Cf.
A000225,
A001047,
A060867,
A090020,
A090021,
A090023,
A090024 are for dimension n with side lengths 1, 2, 3, 4, 5, 7, 8 respectively.
A049691,
A090025,
A090026,
A090027,
A090028,
A090029 are for side length k in 2, 3, 4, 5, 6, 7 dimensions.
-
[7^n-4^n-3^n+1: n in [0..20]]; // Wesley Ivan Hurt, Mar 06 2022
-
Table[7^n - 4^n - 3^n + 1, {n, 0, 25}]
-
[7**n-4**n-3**n+1 for n in range(20)] # Gennady Eremin, Mar 06 2022
Showing 1-10 of 48 results.
Comments