Solution (source code)

= Solution

For the quartic free energy,
$$
f(\phi)-f(\phi_B)
=\frac b4(\phi^2-\phi_B^2)^2.
$$
With constant $\kappa$, part e gives, between the two bulk values,
$$
\frac{dx}{d\phi}
=\pm\frac{\sqrt{2\kappa/b}}
{\phi_B^2-\phi^2}.
$$
Integration gives
$$
x-x_0
=\pm\frac{\sqrt{2\kappa/b}}{\phi_B}
\operatorname{artanh}\frac{\phi}{\phi_B}
=\pm\xi_0\operatorname{artanh}\frac{\phi}{\phi_B},
$$
whose inversion is exactly the hyperbolic-tangent profile in part c.