I would appreciate if one could help me to solve this problem.
I have a bivariate quadratic function: $$ f(a_1,a_2)=(1-u_1^2)a_1^2 +(1-u_2^2)a_2^2 -2u_1u_2a_1a_2 $$ where $u_1^2+u_2^2=1$ and $a_1$ and $a_2$ are unknowns. In order to minimise this function I take the partial derivate and I find that it has its minimum on a line (instead of a point). I have derived the line as $$a_1=\frac{u_1}{u_2}a_2$$ and I have attached a figure showing this function and its minimum line.
My question is I am interested in finding the integer values for $a_1$ and $a_2$subject to $a_1^2+a_2^2<m$ constraint. Considering that I know the minimum line equation, is there any way to find integer values for $a_1$ and $a_2$?
any hint is greatly appreciated.
$$a_1=\frac{u_1}{u_2}a_2$$ My question is I am interested in finding the integer values for $a_1$ and $a_2$subject to $a_1^2+a_2^2<m$ constraint.
If $u_1/u_2$ is irrational, there are no nonzero integer solutions. How could there be? it would be $$ \frac{a_1}{a_2} = \frac{u_1}{u_2}, $$ rational equal to irrational. Impossible.
On the other hand, it is possible for $u_1/ u_2$ to be rational with $u_1^2 + u_2^2 = 1.$ I gave the examples $\left( \frac{3}{5}, \frac{4}{5} \right),$ then $\left( \frac{1}{\sqrt {10}}, \frac{3}{\sqrt {10}} \right).$ If so, write, in lowest terms, $$ \frac{p}{q} = \frac{u_1}{u_2}, $$ with integers $p,q,$ also $q > 0$ and $\gcd(p,q)=1.$ Your line becomes $$a_1=\frac{p}{q}a_2,$$ or $$ \frac{p}{q} = \frac{a_1}{a_2}. $$
The integer points on the line are $$ \ldots (-3p,-3q), (-2p, -2q); (-p,-q); (0,0); (p,q); (2p,2q); (3p,3q); \ldots $$ If $p^2 + q^2 \geq m,$ only he origin satisfies your constraint. If $p^2 + q^2 < m,$ some of these nonzero points satisfy the constraint.