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.

A262067 a(n) = n^n - (n-2)^n.

This page as a plain text file.
%I A262067 #23 Sep 08 2022 08:46:13
%S A262067 2,4,26,240,2882,42560,745418,15097600,347066882,8926258176,
%T A262067 253930611002,7916100448256,268352394448322,9828088361009152,
%U A262067 386707997366768618,16268790735900180480,728714136550643404802,34624041592426892361728
%N A262067 a(n) = n^n - (n-2)^n.
%C A262067 Inspired by multi-dimensional cubes: For n>1, the number of lattice points on the surface of a k-dimensional cube with side-length n is f(n,k) = n^k - (n-2)^k. a(n) = f(n,n).
%F A262067 a(n) = A000312(n) - A008788(n-2).
%e A262067 For n = 2, a(n) = n^n - (n-2)^n = 2^2 - (2-2)^2 = 4.
%p A262067 A262067:=n->n^n - (n-2)^n: seq(A262067(n), n=1..20); # _Wesley Ivan Hurt_, Sep 10 2015
%t A262067 Array[#^# - (# - 2)^# &, {18}] (* _Michael De Vlieger_, Sep 10 2015 *)
%o A262067 (PARI) a(n) = n^n - (n-2)^n;
%o A262067 vector(40, n, a(n))
%o A262067 (Magma) [n^n - (n-2)^n : n in [1..20]]; // _Wesley Ivan Hurt_, Sep 10 2015
%Y A262067 Cf. A000312, A008788.
%Y A262067 For sequences with "Number of points on surface of k-dimensional cube," cf. A130130 (k=1), A008574 (k=2, shifted), A005897 (k=3), A008511 (k=4), A008512 (k=5), A008513 (k=6).
%K A262067 nonn,easy
%O A262067 1,1
%A A262067 _Altug Alkan_, Sep 10 2015