Finding the maximum of $\frac{a}{c}+\frac{b}{d}+\frac{c}{a}+\frac{d}{b}$ If $a,b,c,d$ are distinct real numbers such that $\dfrac{a}{b}+\dfrac{b}{c}+\dfrac{c}{d}+\dfrac{d}{a}=4$ and $ac=bd$.
Then how would we calculate the maximum value of $$\dfrac{a}{c}+\dfrac{b}{d}+\dfrac{c}{a}+\dfrac{d}{b}.$$
I was unable to proceed due to the 'distinct'.

Substituting $d=\frac{ac}{b}$ the constraint becomes
$$\left(\frac{a}{b}+\frac{b}{a}\right)+\left(\frac{c}{b}+\frac{b}{c}\right)=4$$
while the function to be maximized becomes
$$\frac{a}{c}+\frac{b^2}{ac}+\frac{c}{a}+\frac{ac}{b^2}=\frac{b}{c}\left(\frac{a}{b}+\frac{b}{a}\right)+\frac{c}{b}\left(\frac{a}{b}+\frac{b}{a}\right)=\left(\frac{a}{b}+\frac{b}{a}\right)\left(\frac bc+\frac cb\right).$$
Now set
$$x=\frac{a}{b}+\frac{b}{a}\qquad \mathrm{and}\qquad y=\frac bc+\frac cb$$
so that $x+y=4$ and we want to maximize $xy$. Observe that if $x$ is positive then $a$ and $b$ have the same sign and thus
$$x=\frac ab+\frac ba=\frac{(a-b)^2}{ab}+2>2$$
because $a$ and $b$ are distinct. The same clearly also holds for $y$.
But then $x$ and $y$ must have opposite signs: they can not be both negative because $x+y=4$, and they can not be both positive because the sum would be strictly greater than $4$. Suppose for example that $x<0$, then
$$x=\frac ab+\frac ba=\frac{(a+b)^2}{ab}-2\leq -2$$
because $a$ and $b$ have opposite signs. Therefore $y=4-x\geq 6$ which implies $xy\leq -12$. Putting wlog $b=1$ and solving for the equality cases we obtain the equations
$$a+\frac 1a=-2\qquad\mathrm{and}\qquad c+\frac1c=6$$
which have solutions and so the upper bound $-12$ is attained.
