Jon Maiga, 2018-11-23
This article describes a small observation I made between consecutive terms of Liouville’s function and the triangular numbers, namely
The Liouville function, , denotes the parity of the number of prime factors of n,
where Omega, is the number of prime divisors of n.
So for example
In oeis.org this sequence is
A008836 Liouville’s function lambda(n) = (-1)^k, where k is number of primes dividing n
Where the first few terms of are
1, -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, -1, 1, 1, 1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1,…
To get the triangular numbers, let use , you just keep adding to the previous term, starting at 0:
If you want to get the triangular number directly you can use
A000217 Triangular numbers: a(n) = binomial(n+1,2) = n(n+1)/2 = 0 + 1 + 2 + … + n.
The first few triangular numbers are
0, 1, 3, 6, 10, 15, 21, 28, 36, 45, 55, 66, 78, 91, 105, 120, 136, 153,…
As usual when playing with sequencedb.net I noticed a new formula for
A221280 Numbers n such that lambda(n) = lambda(n+1).
2, 7, 9, 11, 12, 14, 15, 17, 18, 19, 21, 24, 25, 27, 28, 29,…
The procedurally found formula managed to generate A221280 by via the triangular numbers which caught my attention.
I verified this for 10^5 terms and felt pretty confident that this relationship holds for all n and generates the full sequence and not just a subset.
The proof is simple, what we are saying is that
this means
so has to be odd, hence, if we drop the division by 2, has to be even.
Now we can rewrite since counts the factors and the inner multiplication adds them (e.g. ).
Because has to be even then both and require to be of the same parity (even=odd+odd or even+even).
Finally we put back the division of two to get to the triangular numbers again, and changing by a factor requires to be odd.
Clearly the complement work as well, .
After writing it down it seems very obvious.
Is it’s possible to extend this method to or generally to any extent?
Written with StackEdit.