A mass falls from a point A (height h) to a point P (height $0$) and then it continues to move with the speed acquired in P.
I have to find the position of the point P on the ground in order to have the minimum time.
I take x the lenght on the ground of A from P.
$E_A=mgh$ (the mass falls down and it has initial speed $0$).
$E_P= \frac{1}{2}m (v_P)^2$ (P is on the ground amd I've taken the ground as my reference plane).
$E_A=E_P \Rightarrow (v_P)^2=2gh \Rightarrow v_P= \sqrt{2gh}$.
This velocity remains constant until the mass reaches the final point B.
$v_P=v_A+gt_1 \Rightarrow t_1= \frac{v_P-v_A}{g}= \frac{\sqrt{2gh}-0}{g}=\sqrt{\frac{2h}{g}}$
$t_2= \frac{L-x}{\sqrt{2gh}}$
$ t_{tot}=t_1+t_2= \sqrt{\frac{2h}{g}} + \frac{L-x}{\sqrt{2gh}} = f(x)$
But $\frac{df}{dx}=0 $ is never verified and I don't know how to procede.
In the solution on the book I don't understand why it says that $x$ is the minimum of $L$ and $\frac{h}{\sqrt 3}$
and it analyze the cases of $h \le \sqrt3 l $ and of $h > \sqrt3 l $.
The issue is in your equation $$v_P=v_A+gt_1$$ The acceleration is not $g$, but the component of $g$ along the $AP$ line. You need to decompose $g$ into components parallel and perpendicular to $AP$. If $\alpha=\angle APC$, then $$g_{||}=g\sin\alpha$$ From $\triangle APC$, $$\sin\alpha=\frac h{\sqrt{h^2+x^2}}$$ Can you continue from here?