<s>[INST] Number of monomials in $a_n=a_{n-1}+(a_{n-2})^2$ with $a_1=a$, $a_2=b$ I was playing around with the sequence $a_1=a$, $a_2=b$ and the recurrence $a_n=a_{n-1}+(a_{n-2})^2$ and just listed out a few general terms.
For instance, $a_1=a$, $a_2=b$, $a_3=b+a^2$, $a_4=b+b^2+a^2$, $a_5=a^4+2a^2b+a^2+2b^2+b$, and $a_6=b^4+2b^3+3b^2+2a^2b^2+4a^2b+b+2a^4+a^2.$
When I did that, I realized that the number of terms in $a_n$ appears to be $F_n$ where $F$ represents the Fibonacci numbers. I conjecture that this is true, but I am not sure how to even approach this.
 [/INST] What an interesting question! The sequence of the number of monomial terms is $1,1,2,3,5,8,14,24,44,80,152,288,560,1088,2144,\dots$
-- not Fibonacci. For example $a_7$ =
$b + 4 b^2 + 6 b^3 + 5 b^4 + a^2 + 6 b a^2 + 10 b^2 a^2 + 8 b^3 a^2 + 3 a^4 + 6 b a^4 + 8 b^2 a^4 + 2 a^6 + 4 b a^6 + a^8$ has 14 terms.
The sequence is now in the OEIS as sequence A290075.
A recursion for the number of terms is $b_n = 2 b_{n-1} +2 b_{n-2} -4 b_{n-3}$ for $n\ge 6$ and there is more information in the OEIS link.
</s>