cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A065364 Alternating sum of balanced ternary digits in n. Replace 3^k with (-1)^k in balanced ternary expansion of n.

Table of values

n a(n)
1 1
2 -2
3 -1
4 0
5 1
6 2
7 3
8 0
9 1
10 2
11 -1
12 0
13 1
14 -2
15 -1
16 0
17 -3
18 -2
19 -1
20 -4
21 -3
22 -2
23 -1
24 0
25 1
26 -2
27 -1
28 0
29 -3
30 -2
31 -1
32 0
33 1
34 2
35 -1
36 0
37 1
38 -2
39 -1
40 0
41 1
42 2
43 3
44 0
45 1
46 2
47 -1
48 0
49 1
50 2
51 3
52 4
53 1
54 2
55 3
56 0
57 1
58 2
59 3
60 4
61 5
62 2
63 3
64 4
65 1
66 2
67 3
68 0
69 1
70 2
71 -1
72 0
73 1
74 -2
75 -1
76 0
77 1
78 2
79 3
80 0
81 1
82 2
83 -1
84 0
85 1
86 2
87 3
88 4
89 1
90 2
91 3
92 0
93 1
94 2
95 -1
96 0
97 1
98 -2
99 -1
100 0
101 -3
102 -2
103 -1
104 0

List of values

[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, 4, 1, 2, 3, 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]