At first, I hope the title for the post is fine, because I wasn't able to sum up the question to a better title.
Anyways, this is the problem: I've got to prove that $a_n=b_n$ for every $n$ while:
- $a_n$ is for the amount of nonnegative solutions of the equation $x_1+x_2+x_3=n$ and when $x_2$ is even, and $x_3$ doesn't divide by 3.
- $b_n$ stands for the amount of nonnegative solutions for the equation $x_1+x_2+x_3=n$ and when $x_1$ is positive, and $x_3$ is dividable by 3.
this is what I've thought of until now:
for $b_n$ - I think I can represent it using the following generating functions: $$(x+x^2+x^3+...)(1+x+x^2+x^3+...)(1+x^3+x^6+x^9+...)$$
for $a_n$ - I think I can represent it using the following generating functions: $$(1+x+x^2+x^3+...)(1+x^2+x^4+...)(x+x^2+x^4+x^5+x^7+x^8+...)$$ that equals (I afraid i'm wrong at this step): $$(1+x+x^2+x^3+...)(1+x^2+x^4+...)((x+x^4+x^7+...)+(x^2+x^5+x^8+...))$$ that equals: $$x(1+x+x^3+x^6+...)(1+x+x^2+x^3+...)(1+x^2+x^4+...)(1+x)$$
is it correct what I did? I'm pretty sure about $b_n$, however $a_n$ doesn't seem to be correct. (should I use a solution based on the complementary, meaning, instead of looking for $x_3$ which isn't dividable by 3, to look for $x_3$ without any limitations and then to subtract the options when $x_3$ is dividable by 3? is there a more straightforward path?)
Thank you,
This is all correct, and a good way to solve the problem. Now all that's left to show is
$$ x(1+x^2+x^4+\cdots)(1+x)=x+x^2+x^3+\cdots\;. $$