# Can the two unknowns n and d (in the equations below) be found by using the simultaneous equations method

The two unknowns are n=3 and d=30. So the answers can be easily found by trial and error. Is it possible to find d and n using the simultaneous equation method ? If so could someone do the calculation. I only have schoolboy knowledge and it is two complex for me. If it can be solved other than by trial and error, I will communicate again as it is just a small part of a much larger problem I'm working on.

$$36\left(n + \frac{d+6}{12}\right)^2 - 24\left(n+\frac{d+6}{12}\right) - \frac{d^2 -16}{4} = 931$$

$$36n^2 + 12n +6dn +d = 930$$

• Since you know $n=30$ and $d=30$, how are they unknown? – 3x89g2 Jul 11 '16 at 1:06

From the first one, expanding the terms,

$\begin{array}\\ 931 &=36(n + (d+6)/12)^2 - 24(n + (d+6)/12) - (d^2 -16)/4\\ &=36(n^2+n(d+6)/6 + (d+6)^2/144) - 24n -2 (d+6)) - d^2/4 +4\\ &=36n^2+6n(d+6) + (d+6)^2/4 - 24n -2 (d+6) - d^2/4 +4\\ &=36n^2+6nd+36n + (d^2+12d+36)/4 - 24n -2 d-12 - d^2/4 +4\\ &=36n^2+6nd+36n + d^2/4+3d+9 - 24n -2 d-12 - d^2/4 +4\\ &=36n^2+6nd+12n +d+1\\ \end{array}$

But this is always one more that $36n² + 12n +6dn +d$, so the second equation does not provide any additional information.

Note that $(6n+d/2)^2 =36n^2+6nd+d^2/4$, so your expression equals

$\begin{array}\\ 6n² +6dn+d^2/4-d^2/4+ 12n +d+1 &=(6n+d/2)^2-d^2/4+ 2(6n +d/2)+1\\ &=((6n+d/2)+1)^2-d^2/4\\ \end{array}$

If $d = 2c$, then $931 =(6n+c+1)^2-c^2$ or

$\begin{array}\\ 931 &=7^2 19\\ &=(6n+c+1)^2-c^2\\ &=(6n+c+1-c)(6n+c+1+c)\\ &=(6n+1)(6n+2c+1)\\ &=(6n+1)(6n+d+1)\\ \end{array}$

If $n$ and $d$ are integers then $n = 3$ and $d = 30$ and there are no other solutions in positive integers (since the only possible values for $6n+1$ are $19$ and $49$).

If you don't care about $n$ and $d$ being integers, you can choose $n$ arbitrarily and let $d =\frac{931}{6n+1}-(6n+1)$.

More generally, if we want the value to be $m$ instead of $931$, we can get the following sequence of restrictions on $n$ and $d$.
First of all, we want $m =(6n+1)(6n+d+1)$. So, if there are no restrictions on $n$ and $d$, choose $n$ arbitrarily and let $d =\frac{m}{6n+1}-(6n+1)$.
If $n \ge 0$ and $d \ge 0$, then $m \ge (6n+1)^2$ or $n \le \dfrac{\sqrt{m}-1}{6}$.
If, in addition, we want $n$ and $d$ to be integers, then $(6n+1) | m$ and $d =\frac{m}{6n+1}-(6n+1)$.