Find naturals numbers $p$ and $q$ such that $\frac{\sqrt{p^2+7}}{\sqrt{q^2-3}}$ is rational Find naturals numbers $p$ and $q$ such that $\frac{\sqrt{p^2+7}}{\sqrt{q^2-3}}$ is rational
i have taken $$\frac{\sqrt{p^2+7}}{\sqrt{q^2-3}}=\frac{a}{b}$$ where $a$ and $b$ are positive integers which are co prime  then after simplification we get
$$3a^2+7b^2=(aq-bp)(aq+bp)$$
$$3(a^2+b^2)+4b^2=(aq-bp)(aq+bp)$$
Obviously $a$ and $b$ both cannot be even since they are co prime
but now if i consider other cases i could not find $p$ and $q$...i will be happy if i get any hint

If $\dfrac{p^2+7}{q^2-3} = \dfrac{a^2}{b^2}$, where $\gcd(a,b) = 1$, then there is a positive integer $r$ such that
$$\begin{cases}p^2 - ra^2 = -7& \\ q^2 - rb^2 = 3. &  \end{cases}$$
For each $r$ we have two independent generalized Pell's Equations. There are several algorithms to find the solutions to this equations. I suggest you read the ones here.
