Find all values of $m$, s.t. $7x + 31y = m$ has exactly two positive solutions.
=> Finding a set of value for the particular solution (P.S.), using EEA (Extended Euclidean Algorithm): $$ \begin{align} 31 = 7.4 + 3 <--> & \ 3 = 31.1 + 7.(-4) \\ 7 = 3.2 + 1 <--> & \ 1 = 7 - 3.2 \implies & \ 1 = 7.9 - 31.2 \\ \end{align} $$
A new (though, unrelated) issue, that has cropped up, is which to actually take as $x_0$ (i.e., $a$), as I conventionally take the larger ( and hence, with negative coefficient in the PS ) value to be $a$ in the linear Diophantine equation(LDE) (formed by self) $ax+by =c$. But, here it is given that $31$ is $b$ (as $31$ has $y$ variable attached to it), and $31 \gt 7$.
Attempting solution :
Given, $d=1, x_0 = 9m, y_0 = -2m$.
Positive solutions are given by the number of integers $k$ satisfying : $d\frac{-x_0}{b} \lt k \lt \frac{y_0}{a}d => \frac{-9m}{31}d \lt k \lt \frac{-2m}{7}d => 0.290m \lt k \lt 0.285m$.
This is clearly not possible, unless either :-
(i) take $a=31, b=7$; or
(ii) $m$ is negative.
Pursuing the second approach (i.e.,, (ii)), $\frac{-9m}{31} \lt k \lt \frac{-2m} {7}$ => $-0.29m \lt k \lt -0.285m$.
But this also is not possible for any natural $m$. So, it means my conventional logic of taking the larger number as $a$ is correct.
By following that (i.e, (i)), the value range of $k$ is given by: $\frac{2m}{7} \lt k \lt \frac{9m}{31}$ => $0.285m \lt k \lt 0.29m.$ It means that need an integer value of m, s.t. there are two integer values possible between $0.285m$ & $0.29m$. This implies : $0.005m =3 \implies m = 600 \implies 171 \lt k \lt 174.$
The possible values of $k$ are : $172, 173$.
Now, coming to the question - it asks all values of $m$, but I have obtained only one value for $m = 600$. Can I take that the answer should be from $m=600$ to $m=799$ or so, based on the precision with which $\dfrac{2}{7}$ or $\dfrac{9}{31}$ is stated.