The problem is as follows. Let $m$ be a fixed integer. Let $a,b\geq0$ be integers such that $(a,b)=1$ and both $a$ and $b$ are square-free. I want to show that the set $\{r,s\in\mathbb Z:ar^2+bs^2=m\}$ has size at most 6 times the number of ideals of $\mathbb Q(\sqrt{-ab})$ with norm $m$.
I have not really come up with any fruitful ideas. If the equation were instead $r^2+(ab)s^2=m$, then this sort of bound seems easier.
Also, the 6 is not important, any absolute constant will do.
Thanks!
I have found an answer! Well, I have recovered the bound that I want, which, was $O(m^\epsilon)$. Note that the quadratic form above is by assumption primitive, since we have taken $(a,b)=1$. Let $r(m,Q)$ be the number of integral solutions to $Q(r,s)=m$, with $Q$ the quadratic form above. Then in Iwaniec's book "Topics in Classical Automorphic Forms", he references Dirichlet having showed that $$ r(m,Q) \leq w_D\sum_{d\mid n}\chi_D(d), $$ where $w_D\leq6$ is a positive constant, and $\chi_D(d)=\left(\frac{D}{d}\right)$ is a character from the quadratic residue. Then we clearly have $$ r(m,q) \leq 6\sum_{d\mid n}1 = O_\epsilon(m^\epsilon). $$
Obviously, this is not a real solution, but I imagine that by diving into the classical theory of binary quadratic forms, I would recover what I originally wanted.
Please take all of this with a very large grain of salt, as it should be clear from this "explanation" that I am unsure of what I am talking, but at least I believe I know where to look.