Please reason step by step, and put your final answer within \boxed{}.
The angle bisector of one of the acute angles of a right triangle, which is also the altitude dropped to the hypotenuse, is divided into segments whose ratio is $1+\sqrt{2}$, starting from the vertex. Find the acute angles of the triangle.
user