login
A356999
a(n) = 2*A356988(n) - n.
8
1, 0, 1, 2, 1, 2, 3, 2, 3, 4, 5, 4, 3, 4, 5, 6, 7, 8, 7, 6, 5, 6, 7, 8, 9, 10, 11, 12, 13, 12, 11, 10, 9, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 20, 19, 18, 17, 16, 15, 14, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 33, 32
OFFSET
1,4
COMMENTS
For k >= 3, the line graph of the sequence consists of a series of local peaks of height Fibonacci(k) at abscissa n = Lucas(k) separated by local valleys of height Fibonacci(k-1) at abscissa n = Fibonacci(k+2).
FORMULA
a(n+1) - a(n) is either 1 or -1.
The sequence is completely determined by the pair of formulas
1) for k >= 2, a(F(k) + j) = F(k-3) + j for 0 <= j <= F(k-2) and
2) for k >= 1, a(L(k) + j) = F(k) - j for 0 <= j <= F(k-2),
where F(n) = A000045(n) denotes the n-th Fibonacci number (with F(-1) = 1) and L(n) = A000032(n) denotes the n-th Lucas number.
EXAMPLE
The sequence arranged as a series of alternating monotone increasing and decreasing sequences:
1;
0;
1, 2;
1;
2, 3;
2;
3, 4, 5;
4, 3;
4, 5, 6, 7, 8;
7, 6, 5;
6, 7, 8, 9, 10, 11, 12, 13;
12, 11, 10, 9, 8;
9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21;
20, 19, 18, 17, 16, 15, 14, 13;
14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, ..., 32, 33, 34;
33, 32, 31, ..., 23, 22, 21;
MAPLE
# b(n) = A356988(n)
b:= proc(n) option remember; if n = 1 then 1 else n - b(b(n - b(b(b(n-1))))) end if; end proc:
seq(2*b(n) - n, n = 1..100);
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Peter Bala, Sep 13 2022
STATUS
approved