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 41-48 of 48 results.

A237719 Numbers n such that k(n) = (n(n+1)/2 mod n) = (antisigma(n) mod n) + (sigma(n) mod n).

Original entry on oeis.org

1, 2, 6, 12, 18, 20, 24, 28, 30, 40, 42, 54, 56, 66, 70, 78, 80, 88, 100, 102, 104, 112, 114, 120, 126, 138, 140, 150, 160, 162, 174, 176, 180, 186, 196, 198, 200, 204, 208, 220, 222, 224, 228, 234, 240, 246, 258, 260, 272, 276, 282, 294, 304, 306, 308, 318, 320
Offset: 1

Views

Author

Jaroslav Krizek, Mar 16 2014

Keywords

Comments

Numbers n such that k(n) = A142150(n) = A229110(n) + A054024(n).
Numbers n such that k(n) = (A000217(n) mod n) = (A024816(n) mod n) + (A000203(n) mod n).
k(n) = 0 for odd n, k(n) = n/2 for even n.
If there are any odd multiply-perfect numbers, they are members of this sequence.
If there is no odd multiply-perfect number, then:
(1) the only odd number in this sequence is 1,
(2) corresponding sequence of numbers k(n): {0; a(n) / 2 for n > 1}.
Supersequence of A159907, A007691 and A000396.

Examples

			12 is in the sequence because k(12) = (12*(12+1)/2) mod 12 = antisigma(12) mod 12 + sigma(12) mod 12; k(12) = 6 = 4 + 2 = n/2.
		

Crossrefs

Programs

  • Magma
    [n: n in [1..320] | IsZero(n*(n+1)div 2 mod n - SumOfDivisors(n) mod n - (n*(n+1)div 2-SumOfDivisors(n)) mod n)]

A257846 a(n) = floor(n/6) * (n mod 6).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 0, 2, 4, 6, 8, 10, 0, 3, 6, 9, 12, 15, 0, 4, 8, 12, 16, 20, 0, 5, 10, 15, 20, 25, 0, 6, 12, 18, 24, 30, 0, 7, 14, 21, 28, 35, 0, 8, 16, 24, 32, 40, 0, 9, 18, 27, 36, 45, 0, 10, 20, 30, 40, 50, 0, 11, 22, 33, 44, 55, 0, 12, 24
Offset: 0

Views

Author

M. F. Hasler, May 10 2015

Keywords

Comments

Equivalently, write n in base 6, multiply the last digit by the number with its last digit removed.

Crossrefs

Cf. A142150 (the base 2 analog), A115273, A257844 - A257850.

Programs

  • Mathematica
    Table[Floor[n/6]*Mod[n, 6], {n, 120}] (* Michael De Vlieger, May 11 2015 *)
  • PARI
    a(n,b=6)=(n=divrem(n,b))[1]*n[2]
    
  • PARI
    concat([0, 0, 0, 0, 0, 0, 0], Vec(x^7*(5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2-x+1)^2*(x^2+x+1)^2) + O(x^100))) \\ Colin Barker, May 11 2015

Formula

a(n) = 2*a(n-6)-a(n-12). - Colin Barker, May 11 2015
G.f.: x^7*(5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2-x+1)^2*(x^2+x+1)^2). - Colin Barker, May 11 2015

A257847 a(n) = floor(n/7) * (n mod 7).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 0, 2, 4, 6, 8, 10, 12, 0, 3, 6, 9, 12, 15, 18, 0, 4, 8, 12, 16, 20, 24, 0, 5, 10, 15, 20, 25, 30, 0, 6, 12, 18, 24, 30, 36, 0, 7, 14, 21, 28, 35, 42, 0, 8, 16, 24, 32, 40, 48, 0, 9, 18, 27, 36, 45, 54, 0, 10, 20
Offset: 0

Views

Author

M. F. Hasler, May 10 2015

Keywords

Comments

Equivalently, write n in base 7, multiply the last digit by the number with its last digit removed.

Crossrefs

Cf. A194757.
Cf. A142150 (the base 2 analog), A115273, A257844 - A257850.

Programs

  • Mathematica
    Table[Floor[n/7]Mod[n,7],{n,0,80}] (* Harvey P. Dale, Nov 12 2022 *)
  • PARI
    a(n,b=7)=(n=divrem(n,b))[1]*n[2]
    
  • PARI
    concat([0,0,0,0,0,0,0,0], Vec(x^8*(6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x^6+x^5+x^4+x^3+x^2+x+1)^2) + O(x^100))) \\ Colin Barker, May 11 2015

Formula

a(n) = 2*a(n-7)-a(n-14). - Colin Barker, May 11 2015
G.f.: x^8*(6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x^6+x^5+x^4+x^3+x^2+x+1)^2). - Colin Barker, May 11 2015

A257848 a(n) = floor(n/8) * (n mod 8).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 0, 2, 4, 6, 8, 10, 12, 14, 0, 3, 6, 9, 12, 15, 18, 21, 0, 4, 8, 12, 16, 20, 24, 28, 0, 5, 10, 15, 20, 25, 30, 35, 0, 6, 12, 18, 24, 30, 36, 42, 0, 7, 14, 21, 28, 35, 42, 49, 0, 8, 16, 24, 32, 40, 48, 56, 0, 9
Offset: 0

Views

Author

M. F. Hasler, May 10 2015

Keywords

Comments

Equivalently, write n in base 8, multiply the last digit by the number with its last digit removed.

Crossrefs

Cf. A142150 (the base 2 analog), A115273, A257844 - A257850.

Programs

  • Mathematica
    Table[Floor[n/8]Mod[n,8],{n,0,90}] (* or *) LinearRecurrence[{0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,-1},{0,0,0,0,0,0,0,0,0,1,2,3,4,5,6,7},90] (* Harvey P. Dale, Nov 05 2023 *)
  • PARI
    a(n,b=8)=(n=divrem(n,b))[1]*n[2]
    
  • PARI
    concat([0,0,0,0,0,0,0,0,0], Vec(x^9*(7*x^6+6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2+1)^2*(x^4+1)^2) + O(x^100))) \\ Colin Barker, May 11 2015
    
  • Python
    def A257848(n): return (n>>3)*(n&7) # Chai Wah Wu, Jan 19 2023

Formula

a(n) = 2*a(n-8)-a(n-16). - Colin Barker, May 11 2015
G.f.: x^9*(7*x^6+6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2+1)^2*(x^4+1)^2). - Colin Barker, May 11 2015

A359329 Number of diagonals in a regular polygon with n sides not passing through the center.

Original entry on oeis.org

0, 0, 5, 6, 14, 16, 27, 30, 44, 48, 65, 70, 90, 96, 119, 126, 152, 160, 189, 198, 230, 240, 275, 286, 324, 336, 377, 390, 434, 448, 495, 510, 560, 576, 629, 646, 702, 720, 779, 798, 860, 880, 945, 966, 1034, 1056, 1127, 1150, 1224, 1248, 1325, 1350, 1430, 1456, 1539, 1566, 1652, 1680
Offset: 3

Views

Author

Luk De Clercq, Dec 26 2022

Keywords

Crossrefs

A014106 and A054000 interleaved.

Programs

  • Mathematica
    Table[(n*(n - 4 + BitGet[n, 0]))/2, {n, 3, 100}] (* Paolo Xausa, Oct 02 2024 *)
  • Python
    def A359329(n): return (n*(n-4)+n*(n&1))>>1 # Chai Wah Wu, Jan 23 2023

Formula

If n is odd, a(n) = (n^2 - 3*n)/2; if n is even, a(n) = (n^2 - 4*n)/2.
a(n) = A000096(n-3) - A142150(n-3).
G.f.: x^5*(5 + x - 2*x^2)/((1 - x)^3*(1 + x)^2). - Stefano Spezia, Jan 04 2023

A367205 Number of nonnegative sequences of integers S with the properties that (1) sum(S) + length(S) = n and (2) there exists a nonnegative sequence whose Euler transform begins with S starting at index 1.

Original entry on oeis.org

1, 2, 3, 6, 9, 16, 27, 45, 74, 125, 205, 343, 564, 934, 1535, 2536, 4165, 6855, 11249, 18465
Offset: 1

Views

Author

Peter Kagey, Nov 10 2023

Keywords

Comments

a(n) <= 2^(n-1), which is the number of nonnegative sequences S with sum(S) + length(S) = n.
The candidate sequences are related to the row n of A228369, by subtracting 1 from each term.

Examples

			For n = 4 the a(4) = 6 sequences are
1) (0,0,0,0) because (1,0,0,0,0,...) = Euler(0,0,0,0,...),
2) (0,0,1)   because (1,0,0,1,...)   = Euler(0,0,1,...),
3) (0,1,0)   because (1,0,1,0,...)   = Euler(0,1,0,...),
4) (0,2)     because (1,0,2,...)     = Euler(0,2,...),
5) (1,1)     because (1,1,1,...)     = Euler(1,0,...) and
6) (3)       because (1,3,...)       = Euler(3,...).
The lexicographically earliest such sequences are:
1) A000007 = Euler(0,0,0,0,...)
2) A079978 = Euler(0,0,1,0,...)
3) A000035 = Euler(0,1,0,0,...)
4) A142150 = Euler(0,2,0,0,...)
5) A000012 = Euler(1,0,0,0,...)
6) A000217 = Euler(3,0,0,0,...)
Note that (2,0) and (1,0,0) are not the 1-indexed prefix of the Euler transform of a nonnegative sequence.
		

Crossrefs

Programs

  • Mathematica
    A367205[n_] :=
     Select[EulerInvTransform /@ (Map[# - 1 &, #] & /@
         Join @@ Permutations /@ IntegerPartitions[n]),
      AllTrue[#, # >= 0 &] &]

A377825 Number of distinct permutations of the terms of the n-th row of Pascal's triangle with alternating signs.

Original entry on oeis.org

1, 2, 3, 24, 30, 720, 630, 40320, 22680, 3628800, 1247400, 479001600, 97297200, 87178291200, 10216206000, 20922789888000, 1389404016000, 6402373705728000, 237588086736000, 2432902008176640000, 49893498214560000, 1124000727777607680000, 12623055048283680000
Offset: 0

Views

Author

Ryan Jean, Nov 08 2024

Keywords

Comments

Note that for any given n, there are n+1 terms in that row.

Examples

			For n = 0, a(0) = 1 since there is just one term.
For n = 1, the signed row terms are {1, -1} so a(1) = 2 permutations.
For n = 2, the signed row terms are {1, -2, 1} which have only a(2) = 3 distinct permutations.
For n = 3, the signed row terms are {1, -3, 3, -1} which have a(3) = 24 permutations.
		

Crossrefs

Bisections are: A007019, A010050.

Programs

  • Maple
    seq((n+1)! / (2^((n*(1+(-1)^n)) / 4)), n=0..22); # Georg Fischer, Dec 19 2024
  • Mathematica
    A377825[n_] := (n+1)!/2^((n*(1 + (-1)^n))/4); Array[A377825, 25, 0] (* Paolo Xausa, Dec 20 2024 *)

Formula

a(n) = (n+1)! / (2^((n*(1+(-1)^n)) / 4)).
E.g.f.: 2*(x^6+x^5-4*x^3-3*x^2+4*x+2)/((x-1)^2*(x+1)^2*(x^2-2)^2). - Alois P. Heinz, Nov 09 2024
a(n) = (n+1)!/A072345(n-1) for n > 0. - Stefano Spezia, Nov 09 2024
Sum_{n>=0} 1/a(n) = cosh(1) + sinh(sqrt(2))/sqrt(2) - 1. - Amiram Eldar, Dec 25 2024

Extensions

a(22) corrected by Georg Fischer, Dec 19 2024

A316744 a(n) is the smallest number having exactly n ways to be represented as sum of at least two consecutive positive integers and expressible as sum of n consecutive positive integers, or 0 if no such number exists.

Original entry on oeis.org

9, 15, 162, 45, 729, 105, 900, 405, 9765625, 495, 1062882, 9477, 3969, 945, 344373768, 3825, 387420489, 7695, 34650, 413343, 81402749386839761113321, 7245, 202500, 732421875, 38025, 25515, 919973073089479921953602, 58725, 0, 29295, 23619600, 473513931, 60886809, 17325, 300189270593998242
Offset: 2

Views

Author

Jianing Song, Jul 13 2018

Keywords

Comments

a(n) is the smallest number such that A069283(n) == n*(n-1)/2 == A142150(n) (mod n). Or equivalently, a(n) is the smallest number of the form 2^t*s, where s is an odd number with exactly n + 1 divisors and divisible by A000265(n), t = 0 for odd n and A007814(n) - 1 for even n.
Let n = 2^e_0*Product_{i=1..m} p_i^e_i where p_i are odd primes; n + 1 = Product_{j=1..s} q_j where q_j are primes, then a(n) != 0 iff there is an injection f from {1,2,..,m} to {1,2,...,s} such that q_f(i) >= e_i + 1 for all 1 <= i <= m, implying s >= m. If such an injection does exist, then the number of k having exactly n ways to be represented as sum of at least two consecutive positive integers and expressible as sum of n consecutive positive integers is finite iff s = m, in which case the number of k is equal to the number of injections such that if i < j and e_i = e_j then q_f(i) <= q_f(j).
If A038547(n) is divisible by A000265(n), then a(n) = 2^t*A038547(n), t defined as above.
If n + 1 is a Fermat prime, then a(n) = (n/2)*3^n. If n = p - 1 = 2^e*q with p, q primes, then a(n) = 2^(e-1)*q^n, which is relatively large.

Examples

			a(2) = 9 = 4 + 5 = 2 + 3 + 4.
a(3) = 15 = 7 + 8 = 4 + 5 + 6 = 1 + 2 + 3 + 4 + 5.
a(4) = 162 = 53 + 54 + 55 = 39 + 40 + 41 + 42 = 14 + 15 + 16 + ... + 22 = 8 + 9 + 10 + ... + 19.
If a number k has exactly 30 ways to be represented as sum of at least two consecutive positive integers, then it must have exactly 31 odd divisors. On the other hand, the sum of 30 consecutive positive integers is congruent to 15 mod 30, so k must be of the form p^30 where p is an odd prime, which obviously cannot be divisible by 15. So a(30) = 0.
Let n = 225 = 3^2*5^2, n + 1 = 226 = 2*113, so e_1 = 2, e_2 = 2, q_1 = 2, q_2 = 113. An injection from {1,2} to {1,2} such that q_f(1) >= e_1 + 1 and q_f(2) >= e_2 + 1 does not exist, so a(225) = 0.
		

Crossrefs

Previous Showing 41-48 of 48 results.