Three. (Full marks 20 points) As shown in Figure 5, $AD$ is the altitude from the right angle $A$ to the hypotenuse $BC$ of the right triangle $\triangle ABC$. $P$ is the midpoint of $AD$, and $BP$ is extended to intersect $AC$ at $E$. Given that $AC: AB = k$. Find $AE: EC$.

---

The translation maintains the original format and line breaks as requested.
From $\mathrm{R} \triangle A C O \cap R \triangle B D A \sim S \mathrm{Rt} \triangle B A C$,
we get $\frac{D C}{A D}=\frac{A D}{B D}:=\frac{A C}{A B}=k$.
Let $B D=a$, then $A D=k a, D C=k^{2} a$. Therefore, we have
$$
\begin{array}{l}
\frac{D C}{B D}=\frac{k^{2} a}{a}=k^{2}, \\
\frac{B C}{B D}=\frac{D C+B D}{B D}=\frac{1+k^{2}}{1}=1+k^{2} .
\end{array}
$$

As shown in Figure 6, extend $B E$ to
$F$, such that $A F / / B C$, then $\triangle A E F$
$\backsim \triangle C E B$, so $\frac{A E}{E C}=\frac{A F}{B C}$.
In Rt $\triangle A F P$ and Rt $\triangle D B P$, since $A P=$ $P D, \angle A P F=\angle D P B$, therefore, Rt $\triangle A F P \cong \mathrm{Rt} \triangle D B P$. Thus, $A F=B D$. Therefore, $\frac{A E}{E C}=\frac{A F}{B C}=\frac{B D}{B C}=\frac{1}{1+k^{2}}$.