$d = \sqrt{(x - 0)^2 + (y - 8a)^2}$

$d = \sqrt{x^2 + (y - 8a)^2}$

From

$ax^2 = y^3$

$x^2 = \dfrac{1}{a} y^3$

$d = \sqrt{\dfrac{1}{a} y^3 + (y - 8a)^2}$

$\dfrac{dd}{dy} = \dfrac{\dfrac{3}{a} y^2 + 2(y - 8a)}{2\sqrt{\dfrac{1}{a} y^3 + (y - 8a)^2}} = 0$

$\dfrac{3}{a} y^2 + 2y - 16a = 0$

$3y^2 + 2ay - 16a^2 = 0$

$y = \dfrac{-2a \pm \sqrt{4a^a - 4(3)(-16a^2)}}{2(3)}$

$y = \dfrac{-2a \pm 14a}{6}$

$y = 2a \, \text{ and } \, -\frac{8}{3}a$

$y = -\frac{8}{3}a$ is meaningless, use $y = 2a$

$d = \sqrt{\dfrac{1}{a} (2a)^3 + (2a - 8a)^2}$

$d = \sqrt{\dfrac{1}{a} (2a)^3 + (2a - 8a)^2}$

$d = \sqrt{44a^2}$

$d = 2a \sqrt{11}$ *answer*