# Find $G(n)$ with $n \geq 1$

Let $G(1) = 0, \ G(2) = 1$, $G(2n+1) = 2 + G(n) + G(n+1)$ and $G(2n) = 1 + G(n), \ \ n \geq 1$

Find $G(n)$

P.S: This is little problem in my problem. I tried to solve by using generating function, but I can not. Can anyone help me. Thanks in advance.

-
Please consider accepting answers to your previous questions. You've asked 10 questions so far, almost all of which have been answered. –  Bruno Joyal Dec 27 '11 at 9:24
Yeah, I accepted –  qwerty89 Dec 27 '11 at 9:28
@qwerty89 By accepting he meant that you click on the tick symbol next to the answer you want to accept. –  Matt N. Dec 27 '11 at 9:30
@qwerty89 Look here: meta.math.stackexchange.com/questions/3286/… –  Matt N. Dec 27 '11 at 9:43
Thanks, I understood. Anyone can help me solve above problem. Thanks ! –  qwerty89 Dec 27 '11 at 9:45