# A formula to obtain every (positive) integers non-multiple of 4?

I'm working on a conjecture and I've come up to a point where I need to express every non-zero positive integers not divisble by 4 with only one parameter (as you would express every even number as 2p). Here the parameter p has to cross the whole natural integers domain $$N*$$.

Before giving you any further information about the idea I have to express such a set of numbers, I would like to show you something that might come in handy.

Earlier while working on the said conjecture I needed to express (still with only one parameter n) a repeating sequence: (5, 0, 2, 3, 8, 6). I've succeded. I've come up using Fibonacci's sequence to do it. The idea was to notice that -4 the sequence was (1, -4, -2, -1, 4, 2) then write it as $$u_n =(-1)^{f(n)}2^{g(n)}$$ with $$f(n)$$ being odd three consecutive time then even the three following, and $$g(n)$$ alternating between $$0,1,2$$. Finally I've come up with: $$g(n) =1+\frac {(-1)^{F_n}-(-1)^{F_{n+2}}}{2}$$ $$f(n)$$ is not interesting here. What's to be noticed is that $$h(n)=g(n)-1 =\frac {(-1)^{F_n}-(-1)^{F_{n+2}}}{2}$$ alternates between $$-1,0,1$$.

Now for the idea: non-multiples of 4 are $$u_i=1,2,3,5,6,7,9,10,11,13,14,15...$$ So basically we can add the $$h(n)$$ function to numbers $$2+6k$$ and write $$u_i$$ as: $$u_i = 2+6{k(i)} + h(i)$$With $$i$$ in $$N*$$

Therefore the question is can you find an expression for $$k(n)$$ that would at least inspire me. Thanks a lot for your answers.

Let $$n = 3k + r;$$ where $$1\le r \le 3$$. In other words $$k = \lfloor \frac {n-1}3\rfloor$$ and $$r = n - 3k$$.
Just let $$N = 4*k + r$$
Or $$N = 4 \lfloor \frac {n-1}3\rfloor + n - 3\lfloor \frac {n-1}3\rfloor = n + \lfloor \frac {n-1}3\rfloor$$
Thus you get $$1,2,3,5,6,7,9,10,......$$
$$u(i) = 4\left\lfloor\frac{i}{3}\right\rfloor +\left(i\;\mathrm{mod}\;3\right) + 1$$ should do the trick for enumerating all natural numbers not divisible by 4.