Let's define a function $p_2(n)$ that it is total distinct way to write $n$ positive integer as sum of square of positive integers. For example, $9$ can be partitioned as sum of squares in 4 distinct ways:
$$3^2$$ $$2^2 + 2^2+1^2$$ $$2^2 + 1^2+1^2+1^2+1^2+1^2$$ $$1^2+1^2+1^2+1^2+1^2+1^2+1^2+1^2+1^2$$
Thus $p_2(9)=4$
I used the similar method of partition function to find generating function for $p_2(n)$ and I have gotten
$$\sum\limits_{n=0}^{ \infty }p_2(n)q^n=(1+q^{1^2}+q^{2.1^2}+q^{3.1^2}+......)(1+q^{2^2}+q^{2.2^2}+q^{3.2^2}+......)(1+q^{3^2}+q^{2.3^2}+q^{3.3^2}+......)..$$
$$\sum\limits_{n=0}^{ \infty }p_2(n)q^n=\frac{1}{\prod\limits_{n=1}^{ \infty }(1-q^{n^2})} $$
I expanded first terms of that product function
$$\prod\limits_{n=1}^{ \infty }(1-q^{n^2})=1-q-q^4+q^5-q^9+q^{10}+q^{13}-q^{14}-q^{16}+q^{17}+q^{20}-q^{21}+q^{34}-q^{35}-q^{36}+q^{37}-q^{38}+q^{39}+q^{40}-q^{42}-2q^{49}+q^{51}+q^{52}+........$$
I have not found any references for sum formula for $\prod\limits_{n=1}^{ \infty }(1-q^{n^2})$.
Is there any sum formula of $\prod\limits_{n=1}^{ \infty }(1-q^{n^2})$ as we can express $\prod\limits_{n=1}^{ \infty }(1-q^{n})=\sum\limits_{n=-\infty}^{ \infty }(-1)^n q^{\frac{n(3n-1)}{2}}$?
Thanks for references and links to related subject.
UPDATE: 9th December,2014
I have found a relation for that square sum partition function I would like to share it.
$$\Phi_2(q)=\prod\limits_{n=1}^{ \infty }(1-q^{n^2})$$ $$\Phi_2(q)=\prod\limits_{n=1}^{ \infty }(1-q^{(2n-1)^2})\prod\limits_{n=1}^{ \infty }(1-q^{(2n)^2})$$
$$\Phi_2(q)=\prod\limits_{n=1}^{ \infty }(1-q^{(2n-1)^2})\prod\limits_{n=1}^{ \infty }(1-(q^4)^{n^2})$$
$$\Phi_2(q)=\Phi_2(q^4)\prod\limits_{n=1}^{ \infty }(1-q^{(2n-1)^2}) \tag 1$$ $$\Phi_2(-q)=\Phi_2(q^4)\prod\limits_{n=1}^{ \infty }(1+q^{(2n-1)^2})$$
$$\Phi_2(-q)\Phi_2(q)=\Phi^2_2(q^4)\prod\limits_{n=1}^{ \infty }(1+q^{(2n-1)^2})\prod\limits_{n=1}^{ \infty }(1-q^{(2n-1)^2})$$
$$\Phi_2(-q)\Phi_2(q)=\Phi^2_2(q^4)\prod\limits_{n=1}^{ \infty }(1-(q^2)^{(2n-1)^2}) \tag 2$$ If we use Equation 1 and put $q -->q^2$ $$\Phi_2(q^2)=\Phi_2(q^8)\prod\limits_{n=1}^{ \infty }(1-(q^2)^{(2n-1)^2}) \tag 3$$
Now we can find and function relation for $\Phi_2(q)$ if we divide Equation 2 and 3
$$\frac{\Phi_2(-q)\Phi_2(q)}{\Phi_2(q^2)}=\frac{\Phi^2_2(q^4)}{\Phi_2(q^8)}$$
$$\Phi_2(-q)\Phi_2(q)\Phi_2(q^8)=\Phi^2_2(q^4)\Phi_2(q^2) \tag 4$$
$$\sum\limits_{n=0}^{ \infty }p_2(n)q^n=\frac{1}{\prod\limits_{n=1}^{ \infty }(1-q^{n^2})} =\frac{1}{\Phi_2(q)}$$
If we define $$P_2(q)=\sum\limits_{n=0}^{ \infty }p_2(n)q^n$$
$$P_2(q)=\frac{1}{\Phi_2(q)}$$
If we put in Equation 4,
$$P_2(-q)P_2(q)P_2(q^8)=P^2_2(q^4)P_2(q^2) \tag 5$$
Finally we can write square sum partition as function relation,
$$\left( \sum\limits_{n=0}^{ \infty }p_2(n)(-1)^nq^n \right) \left( \sum\limits_{n=0}^{ \infty }p_2(n)q^n \right) \left( \sum\limits_{n=0}^{ \infty }p_2(n)q^{8n}\right)=\left( \sum\limits_{n=0}^{ \infty }p_2(n)q^{4n} \right)^2 \left( \sum\limits_{n=0}^{ \infty }p_2(n)q^{2n} \right) $$
n terms can be sum both side and a relation can be found for square sum partition function but It is quite complex relationship. I could not get further. Can someone please help me or advice how to simplify it and get further from that point
Thanks a lot