Find the unknowns from LCM HCF relation. Consider $2$ numbers $x,y$ such that $\frac{x+y}{lcm(x,y)}=\frac{7}{12}$, and it is given that hcf(x,y) is $4$.
How to find $\mathbf{x,y}$.

I have tried the question like this.
\begin{align*}
  \frac{x + y}{(x\cdot y)/4} \Rightarrow \frac{4(x+y)}{x\cdot y} &= \frac{7}{12}\\
48x+ 48y &= 7xy\\
48x &= 7xy-48y\\
48x &= y\cdot(7x-48)\\
y &= \frac{48\cdot x}{7x-48}\\
\end{align*}
As $y$ is a positive number the denominator have to be $<0$, so $x \ge 7$. Now If I put $x =7$
I get $y = \frac{48\cdot 7}{49-48} = 336$. But
lcm(7,336) is 336
and $\frac{7+336}{336} \neq \frac{7}{12}$. Where am I making mistake? the hcf is not 4 for (7,336)

second method I Tried was,
$x = 4a, y =4b.$
now ,
\begin{align*}
  \frac{4a + 4b}{4\cdot a\cdot b} &= \frac{7}{12} \\ 
  \frac{a+b}{a\cdot b} &= \frac{7}{12} \\ 
    \frac{a+b}{a\cdot b} &= \frac{7}{12} \\ 
   \frac{1}{a}+\frac{1}{b} &= \frac{7}{12}\\
   \frac{1}{a} &= \frac{7}{12} - \frac{1}{b}\\
   \frac{1}{a} &= \frac{7b-12}{12b}\\
or\\
a &= \frac{12b}{7b-12}
\end{align*}
so $b\ge 2$ to get an integer, now for $b=2, a= 12. \Rightarrow x=48, y=4$, also if I choose b=2, the hcf is not 4, so if I put $b=3, a = 4 \Rightarrow (12, 16)$ , here the hcf and lcm are,
$4$ and $48$ respectively.and $\frac{12+16}{48} = \frac{7}{12}$.
What is the mistake I am making. ?
 A: For your first method since hcf(x,y)=4 then $4|x$ and $4|y$ so clearly $x=7$ is not  a possibility since $4\not|7.$ So you can only choose $x$ of the form $4k$ for some $k\in\mathbb N.$
In fact the possible integer solutions are given by $(x,y)=(-48,6),(6,-48),(7,336),(7,48)$ and $(12,16).$ Then checking, the correct one is $(12,16).$
For your second method you have $x=4a$ and $y=4b$ then $$\frac{a+b}{ab}=\frac{7}{12}=\frac{7}{3\cdot 4}=\frac{3+4}{3\cdot 4}$$
so clearly you can have $(a,b)=(3,4),(4,3)$ (and the other solutions are $(2,12)$ and $(12,2)$ which are not valid since they have a common divisor of $2$).
So setting $(a,b)=(3,4)$ we have $(x,y)=(12,16)$ and setting $(a,b)=(4,3)$ you have $(x,y)=(16,12).$
A: From the point you get to, $y = \frac{48\cdot x}{7x-48}$
As HCF of $x, y$ is $4$, try $x = 8, 12, ... \, (\ge 7)$. $8$ is not possible as that gives $y = 48$ and hence HCF of $8$. So next try with $x=12$ and you get $y=16$ and those are your numbers.
Your second method gives $b = 3, a = 4$ which is the same. In your second method, you have defined $x = 4a, y = 4b$ so HCF of $a$ and $b$ will be $1$. If you choose $b = 2$, you get $a = 12$ and HCF of $a, b$ is $2$ which is not what you are looking for. So, go with $b = 3$ and that works.
A: Cancelling $\,4\,$ from our gcd $\,(x,y)=4\,\Rightarrow\, \color{#c00}{(a,b)=1}$ thus  $\,\color{#0a0}{(a\!+\!b,\,ab) = 1}\,$ by here.
So $\ \dfrac{a\!+\!b}{\color{#90f}{ab}}\! =\! \dfrac{7}{\color{#90f}{12}}\,$  are $\rm\color{#0a0}{reduced}$, thus $\,\color{#90f}{ab = 12},\,$ so  $\,a,b\,$ are $\rm\color{#c00}{coprime}$ factors of $12$, so $\,a,b = \begin{cases}\!3,4\\\! 4,3\end{cases}$
So the "mistake" was not invoking enough number theory (viz. the $3$ linked well-known theorems).
The first method boils down to the second, but scaled by the gcd $4$ so their is no need to treat it separately. Generally, as explained here homogeneous problems like this are usually simplified by reducing to the coprime case by cancelling the gcd throughout (using gcd & lcm distributive laws).
