login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A213495 Number of (w,x,y) with all terms in {0,...,n} and w = min(|w-x|, |x-y|, |y-w|). 2
1, 4, 9, 16, 27, 38, 53, 70, 89, 110, 135, 160, 189, 220, 253, 288, 327, 366, 409, 454, 501, 550, 603, 656, 713, 772, 833, 896, 963, 1030, 1101, 1174, 1249, 1326, 1407, 1488, 1573, 1660, 1749, 1840, 1935, 2030, 2129, 2230, 2333, 2438, 2547, 2656 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
COMMENTS
For a guide to related sequences, see A212959.
LINKS
FORMULA
a(n) = a(n-1) + a(n-2) - a(n-4) - a(n-5) + a(n-6).
G.f.: (1 + 3*x + 4*x^2 + 3*x^3 + 3*x^4)/(1 - x - x^2 + x^4 + x^5 - x^6).
a(n) = (n+1)^3 - A213492(n).
MATHEMATICA
t = Compile[{{n, _Integer}}, Module[{s = 0}, (Do[If[w == Min[Abs[w - x], Abs[x - y], Abs[y - w]], s = s + 1], {w, 0, n}, {x, 0, n}, {y, 0, n}]; s)]];
m = Map[t[#] &, Range[0, 60]]
(* or *)
LinearRecurrence[{1, 1, 0, -1, -1, 1}, {1, 4, 9, 16, 27, 38}, 60]
CoefficientList[Series[(1+3x+4x^2+3x^3+3x^4)/(1-x-x^2+x^4+x^5-x^6), {x, 0, 50}], x] (* Harvey P. Dale, Aug 11 2021 *)
CROSSREFS
Sequence in context: A138994 A195618 A066969 * A109593 A237589 A138981
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Jun 13 2012
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 29 07:27 EDT 2024. Contains 371265 sequences. (Running on oeis4.)