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-5 of 5 results.

A294017 Partial sums of A294016.

Original entry on oeis.org

1, 5, 12, 26, 43, 73, 106, 154, 211, 285, 362, 472, 585, 719, 872, 1056, 1243, 1473, 1706, 1984, 2285, 2615, 2948, 3354, 3773, 4225, 4704, 5240, 5779, 6403, 7030, 7720, 8441, 9203, 9992, 10892, 11795, 12743, 13726, 14810, 15897, 17093, 18292, 19572, 20919, 22319, 23722, 25278, 26851, 28511, 30214, 32010, 33809
Offset: 1

Views

Author

Omar E. Pol, Oct 22 2017

Keywords

Comments

a(n) is also the volume of another version of the pyramid with n levels (starting from the top) described in A245092. Both pyramids have the same top view and the same front view, but in this pyramid the volume in the n-th level is equal to A294016(n) instead of A024916(n).

Crossrefs

Programs

  • Python
    from math import isqrt
    def A294017(n): return (((s:=isqrt(n))**2*(s+1)*((s+1)*((s<<1)+1)-6*(n+1))>>1) + sum((q:=n//k)*(-k*(q+1)*(3*k+(q<<1)+1)+3*(n+1)*((k<<1)+q+1)) for k in range(1,s+1)))//3-n*(n+1)*((n<<1)+1)//6 # Chai Wah Wu, Oct 22 2023

Formula

a(n) = A175254(n) - A072481(n).

A294015 Sum of the even divisors of 2n, minus the (n-1)st odd number.

Original entry on oeis.org

1, 3, 3, 7, 3, 13, 3, 15, 9, 17, 3, 33, 3, 21, 19, 31, 3, 43, 3, 45, 23, 29, 3, 73, 13, 33, 27, 57, 3, 85, 3, 63, 31, 41, 27, 111, 3, 45, 35, 101, 3, 109, 3, 81, 67, 53, 3, 153, 17, 87, 43, 93, 3, 133, 35, 129, 47, 65, 3, 217, 3, 69, 83, 127, 39, 157, 3, 117, 55, 149, 3, 247, 3, 81, 99, 129, 39, 181, 3, 213, 81, 89, 3, 281
Offset: 1

Views

Author

Omar E. Pol, Oct 28 2017

Keywords

Comments

a(n) = 3 if and only if n is prime.

Crossrefs

Partial sums give A294016.

Programs

  • Mathematica
    a[n_] := 2*(DivisorSigma[1, n] - n) + 1; Array[a, 100] (* Amiram Eldar, Mar 30 2024 *)
  • PARI
    a(n) = 2*sigma(n) - 2*n + 1; \\ Michel Marcus, Oct 29 2017

Formula

a(n) = A074400(n) - A005408(n-1) = 2*A000203(n) - 2*n + 1 = A000203(n) - A235796(n).
Sum_{k=1..n} a(k) = (Pi^2/6 - 1) * n^2 + O(n*log(n)). - Amiram Eldar, Mar 30 2024
a(n) = 2*A001065(n) + 1 = A091818(n) + 1. - Omar E. Pol, Dec 01 2024

A294628 a(n) = 8*(sigma(n) - n + (1/2)).

Original entry on oeis.org

4, 12, 12, 28, 12, 52, 12, 60, 36, 68, 12, 132, 12, 84, 76, 124, 12, 172, 12, 180, 92, 116, 12, 292, 52, 132, 108, 228, 12, 340, 12, 252, 124, 164, 108, 444, 12, 180, 140, 404, 12, 436, 12, 324, 268, 212, 12, 612, 68, 348, 172, 372, 12, 532, 140, 516, 188, 260, 12, 868, 12, 276
Offset: 1

Views

Author

Omar E. Pol, Nov 05 2017

Keywords

Crossrefs

Programs

  • GAP
    List([1..10^5],n->8*(Sigma(n)-n+(1/2))); # Muniru A Asiru, Mar 04 2018
  • Maple
    with(numtheory): seq(sigma(8*n-1)/8, n=1..10^3); # Muniru A Asiru, Mar 04 2018
  • Mathematica
    a[n_] := 8 (DivisorSigma[1, n] - n) + 4; Array[a, 62] (* Robert G. Wilson v, Dec 12 2017 *)

Formula

a(n) = 4*A294015(n).
a(n) = 8*(A001065(n) + (1/2)).
a(n) = 8*(A000203(n) - n + (1/2)).
a(n) = A239050(n) - 4*A235796(n).
a(n) = A017113(n-1) - 8*A235796(n).

A294629 Partial sums of A294628.

Original entry on oeis.org

4, 16, 28, 56, 68, 120, 132, 192, 228, 296, 308, 440, 452, 536, 612, 736, 748, 920, 932, 1112, 1204, 1320, 1332, 1624, 1676, 1808, 1916, 2144, 2156, 2496, 2508, 2760, 2884, 3048, 3156, 3600, 3612, 3792, 3932, 4336, 4348, 4784, 4796, 5120, 5388, 5600, 5612, 6224, 6292, 6640, 6812, 7184, 7196, 7728, 7868, 8384
Offset: 1

Views

Author

Omar E. Pol, Nov 05 2017

Keywords

Comments

a(n) is also the volume (and the number of cubes) in the n-th level (starting from the top) of the stepped pyramid described in A294630.
Number of terms less than 10^k, k=1,2,3,...: 1, 5, 19, 61, 195, 623, 1967, 6225, ... - Muniru A Asiru, Mar 04 2018

Examples

			Illustration of initial terms (n = 1..6):
.                                                  _ _ _ _ _ _
.                                _ _ _ _         _|     |     |_
.                _ _ _ _       _|   |   |_      |       |       |
.      _ _      |   |   |     |    _|_    |     |      _|_      |
.     |_|_|     |_ _|_ _|     |_ _|   |_ _|     |_ _ _|   |_ _ _|
.     |_|_|     |   |   |     |   |_ _|   |     |     |_ _|     |
.               |_ _|_ _|     |_    |    _|     |       |       |
.       4                       |_ _|_ _|       |_      |      _|
.                  16                             |_ _ _|_ _ _|
.                                  28
.                                                      56
.
.                                        _ _ _ _ _ _ _ _
.             _ _ _ _ _ _              _|       |       |_
.            |     |     |           _|         |         |_
.         _ _|     |     |_ _       |           |           |
.        |      _ _|_ _      |      |          _|_          |
.        |     |       |     |      |        _|   |_        |
.        |_ _ _|       |_ _ _|      |_ _ _ _|       |_ _ _ _|
.        |     |       |     |      |       |_     _|       |
.        |     |_ _ _ _|     |      |         |_ _|         |
.        |_ _      |      _ _|      |           |           |
.            |     |     |          |_          |          _|
.            |_ _ _|_ _ _|            |_        |        _|
.                                       |_ _ _ _|_ _ _ _|
.                 68
.                                              120
.
Note that for n >= 2 the structure has a hole (or hollow) in the center.
a(n) is the number of ON cells in the n-th diagram.
		

Crossrefs

For other related diagrams see A294630 (partial sums), A294016 and A237593.

Programs

  • GAP
    List([1..1000],n->Sum([1..n],k->8*(Sigma(k)-k+(1/2)))); # Muniru A Asiru, Mar 04 2018
    
  • Maple
    with(numtheory): seq(sum(8*(sigma(k)-k+(1/2)),k=1..n),n=1..1000); # Muniru A Asiru, Mar 04 2018
  • Mathematica
    f[n_] := 8 (DivisorSigma[1, n] - n) + 4; Accumulate@Array[f, 56] (* Robert G. Wilson v, Dec 12 2017 *)
  • PARI
    a(n) = 4*(sum(k=1, n, n\k*k) - sum(k=2, n, n%k)) \\ Iain Fox, Dec 10 2017
    
  • PARI
    first(n) = my(res = vector(n)); res[1] = 4; for(x=2, n, res[x] = res[x-1] + 8*(sigma(x) - x + (1/2))); res; \\ Iain Fox, Dec 10 2017
    
  • Python
    from math import isqrt
    def A294629(n): return -(s:=isqrt(n))**2*(s+1)+sum((q:=n//k)*((k<<1)+q+1) for k in range(1,s+1))-n**2<<2 # Chai Wah Wu, Oct 22 2023

Formula

a(n) = 4*A294016(n).
a(n) = A016742(n) - 8*A004125(n).
a(n) = A016742(n) - 4*A067436(n).
a(n) = A243980(n) - 4*A004125(n).
a(n) = A243980(n) - 2*A067436(n).

A294630 Partial sums of A294629.

Original entry on oeis.org

4, 20, 48, 104, 172, 292, 424, 616, 844, 1140, 1448, 1888, 2340, 2876, 3488, 4224, 4972, 5892, 6824, 7936, 9140, 10460, 11792, 13416, 15092, 16900, 18816, 20960, 23116, 25612, 28120, 30880, 33764, 36812, 39968, 43568, 47180, 50972, 54904, 59240, 63588, 68372, 73168, 78288, 83676, 89276, 94888, 101112
Offset: 1

Views

Author

Omar E. Pol, Nov 05 2017

Keywords

Comments

a(n) is also the volume of a stepped pyramid with n levels which is another version of the stepped pyramid described in A244050. Both pyramids have the same top view and the same front view, that is to say externally both pyramids are equal, but this pyramid with n levels contains a central chamber whose volume is 4*A072481(n). For more information about the central chamber see the diagrams in A294629.
a(n) is the number of unit cubes of the pyramid with n levels.

Examples

			Illustration of the top view of the pyramid with 16 levels and 4224 unit cubes:
.                 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.                |  _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _  |
.                | |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _| |
.             _ _| |  _ _ _ _ _ _ _ _ _ _ _ _ _ _  | |_ _
.           _|  _ _| |_ _ _ _ _ _ _ _ _ _ _ _ _ _| |_ _  |_
.         _|  _|  _| |  _ _ _ _ _ _ _ _ _ _ _ _  | |_  |_  |_
.        |  _|   |_ _| |_ _ _ _ _ _ _ _ _ _ _ _| |_ _|   |_  |
.   _ _ _| |  _ _|     |  _ _ _ _ _ _ _ _ _ _  |     |_ _  | |_ _ _
.  |  _ _ _|_| |      _| |_ _ _ _ _ _ _ _ _ _| |_      | |_|_ _ _  |
.  | | |  _ _ _|    _|_ _|  _ _ _ _ _ _ _ _  |_ _|_    |_ _ _  | | |
.  | | | | |  _ _ _| |  _| |_ _ _ _ _ _ _ _| |_  | |_ _ _  | | | | |
.  | | | | | | |  _ _|_|  _|  _ _ _ _ _ _  |_  |_|_ _  | | | | | | |
.  | | | | | | | | |  _ _|   |_ _ _ _ _ _|   |_ _  | | | | | | | | |
.  | | | | | | | | | | |  _ _|  _ _ _ _  |_ _  | | | | | | | | | | |
.  | | | | | | | | | | | | |  _|_ _ _ _|_  | | | | | | | | | | | | |
.  | | | | | | | | | | | | | | |  _ _  | | | | | | | | | | | | | | |
.  | | | | | | | | | | | | | | | |   | | | | | | | | | | | | | | | |
.  | | | | | | | | | | | | | | | |_ _| | | | | | | | | | | | | | | |
.  | | | | | | | | | | | | | |_|_ _ _ _|_| | | | | | | | | | | | | |
.  | | | | | | | | | | | |_|_  |_ _ _ _|  _|_| | | | | | | | | | | |
.  | | | | | | | | | |_|_    |_ _ _ _ _ _|    _|_| | | | | | | | | |
.  | | | | | | | |_|_ _  |_  |_ _ _ _ _ _|  _|  _ _|_| | | | | | | |
.  | | | | | |_|_ _  | |_  |_ _ _ _ _ _ _ _|  _| |  _ _|_| | | | | |
.  | | | |_|_ _    |_|_ _| |_ _ _ _ _ _ _ _| |_ _|_|    _ _|_| | | |
.  | |_|_ _ _  |     |_  |_ _ _ _ _ _ _ _ _ _|  _|     |  _ _ _|_| |
.  |_ _ _  | |_|_      | |_ _ _ _ _ _ _ _ _ _| |      _|_| |  _ _ _|
.        | |_    |_ _  |_ _ _ _ _ _ _ _ _ _ _ _|  _ _|    _| |
.        |_  |_  |_  | |_ _ _ _ _ _ _ _ _ _ _ _| |  _|  _|  _|
.          |_  |_ _| |_ _ _ _ _ _ _ _ _ _ _ _ _ _| |_ _|  _|
.            |_ _  | |_ _ _ _ _ _ _ _ _ _ _ _ _ _| |  _ _|
.                | |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _| |
.                | |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _| |
.                |_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _|
.
Note that the above diagram contains a hidden pattern, simpler, which emerges from the front view of every corner of the stepped pyramid. For more information about the hidden pattern see A237593 and A245092.
		

Crossrefs

Programs

  • GAP
    List([1..50],n->Sum([1..n],m->Sum([1..m],k->8*(Sigma(k)-k+(1/2))))); # Muniru A Asiru, Mar 04 2018
    
  • Maple
    with(numtheory): seq(sum(sum(8*(sigma(j)-j+(1/2)),j=1..k),k=1..n),n=1..50); # Muniru A Asiru, Mar 04 2018
  • Mathematica
    f[n_] := 8 (DivisorSigma[1, n] - n) + 4; Accumulate@ Accumulate@ Array[f, 48] (* Robert G. Wilson v, Dec 12 2017 *)
  • Python
    from math import isqrt
    def A294630(n): return ((((s:=isqrt(n))**2*(s+1)*((s+1)*((s<<1)+1)-6*(n+1))>>1) + sum((q:=n//k)*(-k*(q+1)*(3*k+(q<<1)+1)+3*(n+1)*((k<<1)+q+1)) for k in range(1, s+1))<<2)-(n*(n+1)*((n<<1)+1)<<1))//3 # Chai Wah Wu, Nov 01 2023

Formula

a(n) = 4*A294017(n).
a(n) = A002492(n) - 8*A072481(n).
a(n) = A244050(n) - 4*A072481(n).
Showing 1-5 of 5 results.