VOOZH about

URL: https://oeis.org/A387355

⇱ A387355 - OEIS


login
A387355
Upper (1/2)-midsequence of square numbers and triangular numbers; see Comments.
7
0, 1, 4, 8, 13, 20, 29, 39, 50, 63, 78, 94, 111, 130, 151, 173, 196, 221, 248, 276, 305, 336, 369, 403, 438, 475, 514, 554, 595, 638, 683, 729, 776, 825, 876, 928, 981, 1036, 1093, 1151, 1210, 1271, 1334, 1398, 1463, 1530, 1599, 1669, 1740, 1813, 1888, 1964
OFFSET
0,3
COMMENTS
Suppose that s = (s(n)) and t = (t(n)) are sequences of numbers and r > 0. The lower (r)-midsequence of s and t is given by u = floor(r*(s + t)); the upper r-midsequence of s and t is given by v = ceiling(r*(s + t)). If s and t are linearly recurrent and r is rational, then u and v are linearly recurrent.
FORMULA
a(n) = ceiling((3*n^2 + n)/4).
a(n) = 3*a(n-1) - 4*a(n-2) + 4*a(n-3) - 3*a(n-4) + a(n-5).
G.f.: -x*(1 + x + x^3)/((-1 + x)^3*(1 + x^2)).
EXAMPLE
s = (n^2) = A000290 = (0, 1, 4, 9, 16, 25, ...).
t = (n*(n+1)/2) = A000217 = (0, 1, 3, 6, 10, 15, ...).
u(n) = floor((1/2)*(0+0, 1+1, 4+3, 9+6, 16+10, ...)) = (0, 1, 3, 7, 13, ...).
v(n) = ceiling((1/2)*(0+0, 1+1, 4+3, 9+6, 16+10, ...)) = (0, 1, 4, 8, 13, ...).
MATHEMATICA
s[n_] := n^2; t[n_] := n (n + 1)/2; r = 1/2;
u[n_] := Floor[r*(s[n] + t[n])];
v[n_] := Ceiling[r*(s[n] + t[n])];
Table[u[n], {n, 0, 60}] (* A330707 *)
Table[v[n], {n, 0, 60}] (* A387355 *)
PROG
(Python)
def A387355(n): return (n*(3*n+1)-1>>2)+1 # Chai Wah Wu, Nov 08 2025
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Sep 24 2025
STATUS
approved