|
| |
|
|
A065368
|
|
Alternating sum of ternary digits in n. Replace 3^k with (-1)^k in ternary expansion of n.
|
|
2
| |
|
|
0, 1, 2, -1, 0, 1, -2, -1, 0, 1, 2, 3, 0, 1, 2, -1, 0, 1, 2, 3, 4, 1, 2, 3, 0, 1, 2, -1, 0, 1, -2, -1, 0, -3, -2, -1, 0, 1, 2, -1, 0, 1, -2, -1, 0, 1, 2, 3, 0, 1, 2, -1, 0, 1, -2, -1, 0, -3, -2, -1, -4, -3, -2, -1, 0, 1, -2, -1, 0, -3, -2, -1, 0, 1, 2, -1, 0, 1, -2, -1, 0, 1, 2, 3, 0, 1, 2, -1, 0, 1, 2, 3, 4, 1, 2, 3, 0, 1, 2, 3, 4, 5, 2, 3
(list; graph; refs; listen; history; internal format)
|
|
|
|
OFFSET
| 0,3
|
|
|
COMMENTS
| Notation: (3)[n](-1)
Fixed point of the morphism 0-> 0,1,2 ; 1-> -1,0,1 ; 2-> -2,-1,0 ; ...; n-> -n,-n+1,-n+2 . - From DELEHAM Philippe, Oct 22 2011.
|
|
|
FORMULA
| a(n)=Sum_k>=0 {A030341(n,k)*(-1)^k}. - From DELEHAM Philippe, Oct 22 201.
|
|
|
EXAMPLE
| 15 = +1(9)+2(3)+0(1) -> +1(+1)+2(-1)+0(+1) = -1 = a(15)
|
|
|
CROSSREFS
| Cf. A030341, A053735, A065359, A065364
Sequence in context: A118822 A054848 A194525 * A010751 A194523 A180714
Adjacent sequences: A065365 A065366 A065367 * A065369 A065370 A065371
|
|
|
KEYWORD
| base,easy,sign
|
|
|
AUTHOR
| Marc LeBrun (mlb(AT)well.com), Oct 31 2001
|
|
|
EXTENSIONS
| Initial 0 added by DELEHAM Philippe, Oct 22 2011.
|
| |
|
|