login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A262067 a(n) = n^n - (n-2)^n. 2
2, 4, 26, 240, 2882, 42560, 745418, 15097600, 347066882, 8926258176, 253930611002, 7916100448256, 268352394448322, 9828088361009152, 386707997366768618, 16268790735900180480, 728714136550643404802, 34624041592426892361728 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

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).

LINKS

Table of n, a(n) for n=1..18.

FORMULA

a(n) = A000312(n) - A008788(n-2).

EXAMPLE

For n = 2, a(n) = n^n - (n-2)^n = 2^2 - (2-2)^2 = 4.

MAPLE

A262067:=n->n^n - (n-2)^n: seq(A262067(n), n=1..20); # Wesley Ivan Hurt, Sep 10 2015

MATHEMATICA

Array[#^# - (# - 2)^# &, {18}] (* Michael De Vlieger, Sep 10 2015 *)

PROG

(PARI) a(n) = n^n - (n-2)^n;

vector(40, n, a(n))

(MAGMA) [n^n - (n-2)^n : n in [1..20]]; // Wesley Ivan Hurt, Sep 10 2015

CROSSREFS

Cf. A000312, A008788.

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).

Sequence in context: A032328 A019034 A091759 * A193480 A032076 A182146

Adjacent sequences:  A262064 A262065 A262066 * A262068 A262069 A262070

KEYWORD

nonn,easy

AUTHOR

Altug Alkan, Sep 10 2015

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 5 18:00 EDT 2021. Contains 343572 sequences. (Running on oeis4.)