A bunch of lilac consists of flowers with $4$ or $5$ petals. The number of flowers and the total number of petals are perfect squares. Can the number of flowers with $4$ petals be divisible by the number of flowers with $5$ petals?
What I produced:
Total Flowers = $x + y$ Petal Total $5x + 4y$
$x | y$ can?
Like, be $x, y, k, q$ integers
$x + y = k^2$
$5x + 4y = q^2$
Prove that $x does not divide y
$x + 4k^2 = q^2$
$y = k^2 - x$
$\frac{y}{x} = \frac{k^2}{x -1}$
$x$ only divides $y$ divides $k^2$ x only splits k² splits q²
So divide $q^2$ and $k^2$
But it implies that there are two positive integers, say r and s such that
$1 + r^2x = s^2x$
Thus, $1 = x (r-s) (r + s)$
Which is absurd, because they are all natural numbers, and there is no other number that divides $1$ apart from itself.
So $x, r-s$ and $ r + s$ are equal to $ 1$
You are correct in the first steps.
Continuing your argument: $x = n^2 - 4m^2$ and $y = 5m^2 - n^2$.
Hence we have $5m^2 - n^2 = k(n^2 - 4m^2)$. This can be rewritten as $\frac{4k + 5}{k + 1} = \frac{n^2}{m^2}$.
Now notice that, since $k$ is integer, we have $\gcd(4k + 5, k + 1) = \gcd(1, k + 1) = 1$, hence both $4k + 5$ and $k + 1$ are actually square of integers.
This leads to $4k + 5 = u^2$ and $k + 1 = v^2$, or $(2v)^2 + 1 = u^2$.
This is impossible, since two positive squares cannot differ by $1$.