Can the Ruler function be expressed in a closed-form expression?

289 Views Asked by At

The Ruler function has the following property:

$$\forall n \in \mathbb{N}: f(2n) = f(n)+1,\, f(2n+1) = 1.$$

Is there any other function with this property?