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-10 of 11 results. Next

A203571 Period length 10: [0, 1, 2, 3, 4, 0, 4, 3, 2, 1] repeated.

Original entry on oeis.org

0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0, 1, 2, 3, 4, 0, 4, 3, 2, 1, 0
Offset: 0

Views

Author

Wolfdieter Lang, Jan 11 2012

Keywords

Comments

This sequence can be continued periodically for negative values of n.
This is the fifth sequence of a k-family of sequences P_k, k>=1, which starts with A000007(n+1), n >= 0 (the 0-sequence), A000035, A193680, A193682, for k = 1, ..., 4, respectively.
In general, the sequence P_k, k >= 1 (periodically continued for negative values of n), is used to define the k equivalence classes [0], [1], ..., [k-1], with [j] := {n integer| P_k(n) = j}. Two integers are equivalent if and only if they are mapped by P_k to the same value. For P_5, P_6 and P_7 see the arrays (not the triangles) A090298, A092260 and A113807, respectively. In each of these cases the class [k] should be replaced by the class [0], and also negative n-values are allowed. Multiplication can be done class-wise. E.g., k = 5: P_5(n) = a(n), 7*12 == 3*2 = 6 == 4; a(7*12) = a(a(7)*a(12)) = a(3*2) = 4. This kind of multiplication could be called multiplication Modd n, in order to distinguish it from multiplication mod n. Addition cannot be done class-wise. E.g., k = 5: 7 + 12 = 19 == 1 is not equivalent to 3 + 2 = 5 == 0; a(7+12) = 1 is not equal to a(a(7) + a(12)) = a(3+2) = 0.
Periodic sequences of this type can be also calculated by a(n) = c + floor(q/(p^m-1)*p^n) mod p, where c is a constant, q is the number representing the periodic digit pattern and m is the period length. c, p and q can be calculated as follows: Let D be the array representing the number pattern to be repeated, m = size of D, max = maximum value of elements in D, min = minimum value of elements in D. Then c := min, p := max - min + 1 and q := p^m * Sum_{i=0..(m-1)} (D(i) - min)/p^i. Example: D = (0, 1, 2, 3, 4, 0, 4, 3, 2, 1), c = 0, m = 10, p = 5 and q = 3034180 for this sequence. - Hieronymus Fischer, Jan 04 2013 [Corrected by Rémi Guillaume, Aug 28 2024]
For periodic sequences with terms < 10 one can use the well-known fact that ab..z/99..9 = 0.ab..zab..zab..z... (infinite periodic decimal fraction), this leads to one of the given formulas. For the general case it is sufficient to shift the terms to nonnegative values and to switch to a sufficiently large basis instead of 10 (there are infinitely many choices). - M. F. Hasler, Jan 13 2013

Examples

			a(12) = 12 mod 5 = 2 since 12\5 = floor(12/5) = 2 is even; the sign is +1.
a(7) = -7 mod 5 = 3 since 7\5 = floor(7/5) = 1 is odd; the sign is -1.
		

Crossrefs

Programs

Formula

a(n) = n mod 5 if (-1)^floor(n/5) = +1 else -n mod 5, n >= 0. (-1)^floor(n/5) is the sign corresponding to the parity of the quotient floor(n/5). This quotient is sometimes denoted by n\5.
O.g.f.: x*(1+2*x+3*x^2+4*x^3+4*x^5+3*x^6+2*x^7+x^8)/(1-x^10) = -x*(1 +2*x +3*x^2 +4*x^3 +4*x^5 +3*x^6 +2*x^7 +x^8) / ( (x-1) *(1+x) *(x^4+x^3+x^2+x+1) *(x^4-x^3+x^2-x+1) ).
a(n) = (2/5)*cos(Pi*n) - cos(4*Pi*n/5) - (1/5)*cos(3*Pi*n/5) + (2/5)*5^(1/2)*cos(3*Pi*n/5) - cos(2*Pi*n/5) - (1/5)*cos(Pi*n/5) - (2/5)*5^(1/2)*cos(Pi*n/5) + 2. - Leonid Bedratyuk, May 13 2012
a(n) = floor(123404321/9999999999*10^(n+1)) mod 10. - Hieronymus Fischer, Jan 04 2013
a(n) = floor(151709/2441406*5^(n+1)) mod 5. - Hieronymus Fischer, Jan 04 2013
a(n) = (5-abs(n-(10*ceiling(n/10)-5)))*(ceiling((n+5)/10)-floor((n+5)/10)). - Wesley Ivan Hurt, Mar 26 2014 [corrected by Jason Yuen, Feb 17 2025]
a(n+10) = a(n) for n in Z; a(-n) = a(n) for n in Z. - Rémi Guillaume, Aug 28 2024

A090771 Numbers that are congruent to {1, 9} mod 10.

Original entry on oeis.org

1, 9, 11, 19, 21, 29, 31, 39, 41, 49, 51, 59, 61, 69, 71, 79, 81, 89, 91, 99, 101, 109, 111, 119, 121, 129, 131, 139, 141, 149, 151, 159, 161, 169, 171, 179, 181, 189, 191, 199, 201, 209, 211, 219, 221, 229, 231, 239, 241, 249, 251, 259, 261, 269, 271, 279, 281
Offset: 1

Views

Author

Giovanni Teofilatto, Feb 07 2004

Keywords

Comments

Cf. property described by Gary Detlefs in A113801: more generally, these numbers are of the form (2*h*n + (h-4)*(-1)^n - h)/4 (h, n natural numbers), therefore ((2*h*n + (h-4)*(-1)^n - h)/4)^2-1 == 0 (mod h); in this case, a(n)^2 - 1 == 0 (mod 10). - Bruno Berselli, Nov 17 2010

Crossrefs

Cf. A056020 (n = 1 or 8 mod 9), A175885 (n = 1 or 10 mod 11).
Cf. A045468 (primes), A195142 (partial sums).

Programs

Formula

a(n) = sqrt(40*A057569(n) + 1). - Gary Detlefs, Feb 22 2010
From Bruno Berselli, Sep 16 2010 - Nov 17 2010: (Start)
G.f.: x*(1 + 8*x + x^2)/((1 + x)*(1 - x)^2).
a(n) = (10*n + 3*(-1)^n - 5)/2.
a(n) = -a(-n + 1) = a(n-1) + a(n-2) - a(n-3) = a(n-2) + 10.
a(n) = 10*A000217(n-1) + 1 - 2*Sum_{i=1..n-1} a(i) for n > 1. (End)
a(n) = 10*n - a(n-1) - 10 (with a(1) = 1). - Vincenzo Librandi, Nov 16 2010
a(n) = sqrt(10*A132356(n-1) + 1). - Ivan N. Ianakiev, Nov 09 2012
Sum_{n>=1} (-1)^(n+1)/a(n) = (Pi/10)*cot(Pi/10) = A000796 * A019970 / 10 = sqrt(5 + 2*sqrt(5))*Pi/10. - Amiram Eldar, Dec 04 2021
E.g.f.: 1 + ((10*x - 5)*exp(x) + 3*exp(-x))/2. - David Lovler, Sep 03 2022
From Amiram Eldar, Nov 23 2024: (Start)
Product_{n>=1} (1 - (-1)^n/a(n)) = sqrt(phi+2) (A188593).
Product_{n>=2} (1 + (-1)^n/a(n)) = Pi*phi/5 = A094888/10. (End)

Extensions

Edited and extended by Ray Chandler, Feb 10 2004

A113807 Permutation of natural numbers generated by 7-rowed array shown below.

Original entry on oeis.org

1, 13, 2, 15, 12, 3, 27, 16, 11, 4, 29, 26, 17, 10, 5, 41, 30, 25, 18, 9, 6, 43, 40, 31, 24, 19, 8, 7, 55, 44, 39, 32, 23, 20, 14, 57, 54, 45, 38, 33, 22, 21, 69, 58, 53, 46, 37, 34, 28, 71, 68, 59, 52, 47, 36, 35, 83, 72, 67, 60, 51, 48, 42, 85, 82, 73, 66, 61, 50, 49
Offset: 1

Views

Author

Giovanni Teofilatto, Jan 22 2006

Keywords

Comments

For such arrays A_k see the k-family of 2k-periodic sequences P_k defined in a comment on A203571. There the k residue classes mod n have been defined. The present array is A_7 if the last class, starting with 7, is taken as first class [0] after adding a 0 in front. Then one obtains a permutation of the nonnegative integers. However, each complete residue class also includes its negative members. - Wolfdieter Lang, Feb 02 2012

Examples

			1 13 15 27 29 41 43 55 57 69 71 83 85 ... (A113801)
2 12 16 26 30 40 44 54 58 68 72 82 86 ... (A113802)
3 11 17 25 31 39 45 53 59 67 73 81 87 ... (A113803)
4 10 18 24 32 38 46 52 60 66 74 80 88 ... (A113804)
5  9 19 23 33 37 47 51 61 65 75 70 89 ... (A113805)
6  8 20 22 34 36 48 50 62 64 76 78 90 ... (A113806)
7 14 21 28 35 42 49 56 63 70 77 84 91 ... (A008589)
		

Crossrefs

Extensions

A-numbers added for array rows by Wolfdieter Lang, Dec 15 2011
More terms from Ray Chandler, Dec 15 2011

A092260 Permutation of natural numbers generated by 6-rowed array shown below.

Original entry on oeis.org

1, 11, 2, 13, 10, 3, 23, 14, 9, 4, 25, 22, 15, 8, 5, 35, 26, 21, 16, 7, 6, 37, 34, 27, 20, 17, 12, 47, 38, 33, 28, 19, 18, 49, 46, 39, 32, 29, 24, 59, 50, 45, 40, 31, 30, 61, 58, 51, 44, 41, 36, 71, 62, 57, 52, 43, 42, 73, 70, 63, 56, 53, 48, 83, 74, 69, 64, 55, 54, 85, 82, 75
Offset: 1

Views

Author

Giovanni Teofilatto, Feb 19 2004

Keywords

Comments

1 11 13 23 25 35 37 47 49 59... (A091998)
2 10 14 22 26 34 38 46 50 58... (A091999)
3 9 15 21 27 33 39 45 51 57... (A016945)
4 8 16 20 28 32 40 44 52 56... (A092259)
5 7 17 19 29 31 41 43 53 55... (A092242)
6 12 18 24 30 36 42 48 54 60... (A008588, excluding initial term)
For such arrays A_k, here A_6, see a W. Lang comment on A113807, the A_7 case. However, to get the array A_6 one should take the last line as the first one and add a 0 in front (thus obtaining a permutation of the nonnegative integers). - Wolfdieter Lang, Feb 02 2012

Crossrefs

Extensions

Edited and extended by Ray Chandler, Feb 21 2004

A084101 Expansion of (1+x)^2/((1-x)*(1+x^2)).

Original entry on oeis.org

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

Views

Author

Paul Barry, May 15 2003

Keywords

Comments

Partial sums of A084099. Inverse binomial transform of A000749 (without leading zeros).
From Klaus Brockhaus, May 31 2010: (Start)
Periodic sequence: Repeat 1, 3, 3, 1.
Interleaving of A010684 and A176040.
Continued fraction expansion of (7 + 5*sqrt(29))/26.
Decimal expansion of 121/909.
a(n) = A143432(n+3) + 1 = 2*A021913(n+1) + 1 = 2*A133872(n+3) + 1.
a(n) = A165207(n+1) - 1.
First differences of A047538.
Binomial transform of A084102. (End)
From Wolfdieter Lang, Feb 09 2012: (Start)
a(n) = A045572(n+1) (Modd 5) := A203571(A045572(n+1)), n >= 0.
For general Modd n (not to be confused with mod n) see a comment on A203571. The nonnegative members of the five residue classes Modd 5, called [m] for m=0,1,...,4, are shown in the array A090298 if there the last row is taken as class [0] after inclusion of 0.
(End)

Examples

			From _Wolfdieter Lang_, Feb 09 2012: (Start)
Modd 5 of nonnegative odd numbers restricted mod 5:
A045572: 1, 3, 7, 9, 11, 13, 17, 19, 21, 23, ...
Modd 5:  1, 3, 3, 1,  1,  3,  3,  1,  1,  3, ...
(End)
		

Crossrefs

Cf. A084102.
Cf. A010684 (repeat 1, 3), A176040 (repeat 3, 1), A178593 (decimal expansion of (7+5*sqrt(29))/26), A143432 (expansion of (1+x^4)/((1-x)*(1+x^2))), A021913 (repeat 0, 0, 1, 1), A133872 (repeat 1, 1, 0, 0), A165207 (repeat 2, 2, 4, 4), A047538 (congruent to 0, 1, 4 or 7 mod 8), A084099 (expansion of (1+x)^2/(1+x^2)), A000749 (expansion of x^3/((1-x)^4-x^4)). - Klaus Brockhaus, May 31 2010

Programs

  • Magma
    R:=PowerSeriesRing(Integers(), 100); Coefficients(R!( (1+x)^2/((1-x)*(1+x^2)) )); // G. C. Greubel, Feb 28 2019
    
  • Mathematica
    CoefficientList[Series[(1+x)^2/((1-x)(1+x^2)),{x,0,110}],x] (* or *) PadRight[{},110,{1,3,3,1}] (* Harvey P. Dale, Nov 21 2012 *)
  • PARI
    x='x+O('x^100); Vec((1+x)^2/((1-x)*(1+x^2))) \\ Altug Alkan, Dec 24 2015
    
  • Sage
    ((1+x)^2/((1-x)*(1+x^2))).series(x, 100).coefficients(x, sparse=False) # G. C. Greubel, Feb 28 2019

Formula

a(n) = binomial(3, n mod 4). - Paul Barry, May 25 2003
From Klaus Brockhaus, May 31 2010: (Start)
a(n) = a(n-4) for n > 3; a(0) = a(3) = 1, a(1) = a(2) = 3.
a(n) = (4 - (1+i)*i^n - (1-i)*(-i)^n)/2 where i = sqrt(-1). (End)
E.g.f.: 2*exp(x) + sin(x) - cos(x). - Arkadiusz Wesolowski, Nov 04 2017
a(n) = 2 - (-1)^(n*(n+1)/2). - Guenther Schrack, Feb 26 2019

A088520 Permutation of natural numbers generated by 3-rowed array shown below.

Original entry on oeis.org

1, 5, 2, 7, 4, 3, 11, 8, 6, 13, 10, 9, 17, 14, 12, 19, 16, 15, 23, 20, 18, 25, 22, 21, 29, 26, 24, 31, 28, 27, 35, 32, 30, 37, 34, 33, 41, 38, 36, 43, 40, 39, 47, 44, 42, 49, 46, 45, 53, 50, 48, 55, 52, 51, 59, 56, 54, 61, 58, 57, 65, 62, 60, 67, 64, 63, 71, 68, 66, 73, 70, 69
Offset: 1

Views

Author

Giovanni Teofilatto, Nov 14 2003

Keywords

Comments

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

References

  • M. Cerasoli, F. Eugeni and M. Protasi, Elementi di Matematica Discreta, Bologna 1988
  • Emanuele Munarini and Norma Zagaglia Salvi, Matematica Discreta,UTET, CittaStudiEdizioni, Milano 1997

Crossrefs

Extensions

Corrected and extended by Ray Chandler, Nov 16 2003

A090773 Numbers that are congruent to {4, 6} mod 10.

Original entry on oeis.org

4, 6, 14, 16, 24, 26, 34, 36, 44, 46, 54, 56, 64, 66, 74, 76, 84, 86, 94, 96, 104, 106, 114, 116, 124, 126, 134, 136, 144, 146, 154, 156, 164, 166, 174, 176, 184, 186, 194, 196, 204, 206, 214, 216, 224, 226, 234, 236, 244, 246, 254, 256, 264, 266, 274, 276, 284
Offset: 1

Views

Author

Giovanni Teofilatto, Feb 07 2004

Keywords

Crossrefs

Programs

  • Mathematica
    #+{4,6}&/@(10Range[0,50])//Flatten (* or *) LinearRecurrence[{1,1,-1},{4,6,14},100] (* Harvey P. Dale, Jun 05 2017 *)

Formula

a(n) = 2 * A047221(n) = 5*n-5/2-3*(-1)^n/2.
a(n) = 10*n-a(n-1)-10 (with a(1)=4). - Vincenzo Librandi, Nov 16 2010
G.f.: 2*x*(2+x+2*x^2) / ( (1+x)*(x-1)^2 ). - R. J. Mathar, Oct 08 2011
Sum_{n>=1} (-1)^(n+1)/a(n) = sqrt(1-2/sqrt(5))*Pi/10. - Amiram Eldar, Dec 28 2021
From Amiram Eldar, Nov 23 2024: (Start)
Product_{n>=1} (1 - (-1)^n/a(n)) = cosec(2*Pi/5) (A179290).
Product_{n>=1} (1 + (-1)^n/a(n)) = cosec(Pi/5)/2 (A300074). (End)

Extensions

Edited and extended by Ray Chandler, Feb 10 2004

A115302 Permutation of natural numbers generated by 3-rowed array shown below.

Original entry on oeis.org

1, 4, 2, 7, 5, 3, 10, 8, 6, 13, 11, 9, 16, 14, 12, 19, 17, 15, 22, 20, 18, 25, 23, 21, 28, 26, 24, 31, 29, 27, 34, 32, 30, 37, 35, 33, 40, 38, 36, 43, 41, 39, 46, 44, 42, 49, 47, 45, 52, 50, 48, 55, 53, 51, 58, 56, 54, 61, 59, 57, 64, 62, 60
Offset: 1

Views

Author

Giovanni Teofilatto, Mar 05 2006

Keywords

Comments

1 4 7 10 13 16 19 22 25...a(n)=3n+1 => A016777
2 5 8 11 14 17 20 23 26...a(n)=3n+2 => A016789
3 6 9 12 15 18 21 24 27...a(n)=3n => A008585
Reversing the direction of the diagonals gives A143097. - Jeremy Gardiner, Oct 14 2012.

References

  • M. Cerasoli, F. Eugeni and M. Protasi, Elementi di Matematica Discreta, Bologna 1988
  • Emanuele Munarini and Norma Zagaglia Salvi, Matematica Discreta,UTET, CittaStudiEdizioni, Milano 1997

Crossrefs

Formula

For n > 1, a(n+5) = a(n) + 6, iff a(n+5)=1.

A090243 Permutation of natural numbers generated by 4-rowed array shown below.

Original entry on oeis.org

1, 7, 2, 11, 6, 3, 13, 10, 5, 4, 19, 14, 9, 8, 23, 18, 15, 12, 25, 22, 17, 16, 31, 26, 21, 20, 35, 30, 27, 24, 37, 34, 29, 28, 43, 38, 33, 32, 47, 42, 39, 36, 49, 46, 41, 40, 55, 50, 45, 44, 59, 54, 51, 48, 61, 58, 53, 52, 67, 62, 57, 56, 71, 66, 63, 60, 73, 70, 65, 64, 79, 74
Offset: 1

Views

Author

Giovanni Teofilatto, Jan 24 2004

Keywords

Comments

1 7 11 13 19 23 25 31 35 37 43 47 ...
2 6 10 14 18 22 26 30 34 38 42 46 ...
3 5 9 15 17 21 27 29 33 39 41 45 ...
4 8 12 16 20 24 28 32 36 40 44 48 ...

References

  • M. Cerasoli, F. Eugeni and M. Protasi, Elementi di Matematica Discreta, Bologna 1988
  • Emanuele Munarini and Norma Zagaglia Salvi, Matematica Discreta,UTET, CittaStudiEdizioni, Milano 1997

Crossrefs

Extensions

Corrected and extended by Ray Chandler, Jan 30 2004

A090772 Numbers that are congruent to {2, 8} mod 10.

Original entry on oeis.org

2, 8, 12, 18, 22, 28, 32, 38, 42, 48, 52, 58, 62, 68, 72, 78, 82, 88, 92, 98, 102, 108, 112, 118, 122, 128, 132, 138, 142, 148, 152, 158, 162, 168, 172, 178, 182, 188, 192, 198, 202, 208, 212, 218, 222, 228, 232, 238, 242, 248, 252, 258, 262, 268, 272, 278, 282
Offset: 1

Views

Author

Giovanni Teofilatto, Feb 07 2004

Keywords

Comments

Their square ends in the digit 4. - Kausthub Gudipati, Sep 08 2011
10*a(n) = 20, 80, 120, 180, 220, ... are the only numbers written in French ending in "vingt(s)". - Paul Curtz, Aug 02 2018

Crossrefs

Programs

  • Magma
    m:=50; R:=PowerSeriesRing(Integers(), m); Coefficients(R!(2*x*(1+3*x+x^2)/((1+x)*(1-x)^2))); // G. C. Greubel, Aug 08 2018
  • Mathematica
    Union@ Flatten@ Outer[Plus, {2, 8}, 10 Range[0, 28]] (* or *)
    CoefficientList[Series[2 (1 + 3x + x^2)/((1 + x) (1 - x)^2), {x, 0, 57}], x] (* Michael De Vlieger, Aug 02 2018 *)
    LinearRecurrence[{1, 1, -1}, {2, 8, 12}, 61] (* Robert G. Wilson v, Aug 08 2018 *)
  • PARI
    is(n) = #setintersect([2, 8], [n%10]) > 0 \\ Felix Fröhlich, Aug 02 2018
    
  • PARI
    Vec(2*x*(1+3*x+x^2)/((1+x)*(1-x)^2) + O(x^60)) \\ Felix Fröhlich, Aug 02 2018
    

Formula

a(n) = 2 * A047209(n).
a(n) = 10*n - a(n-1) - 10 (with a(1)=2). - Vincenzo Librandi, Nov 16 2010
G.f.: 2*x*(1+3*x+x^2)/((1+x)*(1-x)^2). - Bruno Berselli, Sep 08 2011
a(1) = 2. For n > 1, a(n) = a(n-1) + A226294(n). - Felix Fröhlich, Aug 02 2018
Sum_{n>=1} (-1)^(n+1)/a(n) = sqrt(1+2/sqrt(5))*Pi/10. - Amiram Eldar, Dec 28 2021
E.g.f.: 2 + ((10*x - 5)*exp(x) + exp(-x))/2. - David Lovler, Sep 03 2022
From Amiram Eldar, Nov 23 2024: (Start)
Product_{n>=1} (1 - (-1)^n/a(n)) = tan(3*Pi/10) (A019952).
Product_{n>=1} (1 + (-1)^n/a(n)) = cosec(2*Pi/5)/2 (= A179290 / 2). (End)

Extensions

Edited and extended by Ray Chandler, Feb 10 2004
Showing 1-10 of 11 results. Next