Constructing a right triangle with a given hypotenuse segment and given point of tangency for its incircle 
Given a hypotenuse $AB$ and an arbitrary point $C$ on $AB$. How to construct a right triangle with the given hypotenuse $AB$ such that point $C$ is the point of tangency of the inscribed circle?




My attempt: First draw a circle with $AB$ as diameter (Thales theorem). if i get the incenter of the triangle then the rest is easy. but how to locate the point$G$ on the circle  or how to locate the incenter with the given information
. any hints or idea
here is my construction.
$F$ is the midpoint of $CD$
here]
 A: 
Let $ABG$ be the triangle you want to construct, $F$ its incenter. In the circle $\Gamma$ with diameter $AB$, let $D$ be the endpoint of the diameter perpendicular to $AB$ and on the opposite side of $AB$ to $G$.
Since $AGB$ is a right triangle, $G$ lies on $\Gamma$. Because $GF$ bisects $\angle AGB$, it meets $\Gamma$ at $D$. Furthermore, it is easy to see that $\angle AFB = 135^{\circ}$. It follows that $F$ is on the circle $\Gamma'$ centered at $D$ passing through $A$ and $B$.
Hence $G$ can be constructed as follows. First construct the point $D$. Then let $F$ be the intersection of $\Gamma'$ with the perpendicular to $AB$ through $C$. Lastly, let $G$ be the other intersection of $DF$ with $\Gamma$.
A: 
Construction: Let $D$ be the midpoint of $AB$.Construct the point $E$ on the line $(AB)$ such that $BE=DC$. Construct congruent circles $\cal D$ and $\cal E$ with radii $DB=EC$ centered at $D$ and $E$, respectively. At point $B$ construct the perpendicular line to $AB$. Let its intersection with $\cal E$ be $F$. Connect $D$ and $F$. Let intersection of $DF$ with $\cal D$ be $G$. Draw a circle centered at $A$ with radius $AC+GF$. Its intersection with $\cal D$ will be the third triangle vertex $I$.
Explanation: the tangent points of the inscribed circle divide the triangle sides in such a way that
$$
a=y+z,\quad b=z+x,\quad c=x+y.
$$
The lengths $x=AC$ and $y=BC$ are given. To find $z$ we write:
$$
(y+z)^2+(z+x)^2-(x+y)^2=0\implies z=\sqrt{\left(\frac{x+y}2\right)^2+xy}-\frac{x+y}2.
$$
By the above construction it is the length of segment $GF$, since $DB=\frac{x+y}2, BF=\sqrt{xy}$.
A: Rephrasing your question:

Given a line segment $AB$ and an arbitrary point $C$ on $AB$. Construct a right triangle with $AB$ as hypotenuse such that point $C$ is the point of tangency of its incircle?

Solution:

\begin{align*}
(x+z)^2&=(x+y)^2+(y+z)^2\\
2xz&=2y^2+2yz+2xy\\
xz&=y(x+y+z)\\
xz&=y(y+AB)\tag{1}\\
\end{align*}

*

*Bisect $AB$ in $O$ and Draw a circle with $O$ as its center and $AB$ as its diameter.

*Draw an arc from C on AC with radius BC to get $AD=x-z$.

*Draw an arc from any point E on the circle with radius $x-z$ that cuts the circle in $F$.

*Produce $EF$ to $EG$ such that $FG=z$.

*Draw a line from $G$ through $O$ so that $HI=AB\Rightarrow GH=y\ (\because\text{Compare equation }1 \text{ and circle identity }GE.GF=GH.GI)$

*Draw a perpendicular through $C$ and cut it through an arc with radius $GH$ in $J$.

*Construct an incircle with $J$ as its center and $GH$ as its radius.

*Complete the required $\triangle AKB$ with $AK$ and $BK$ as tangents to the encircle.

PS:
Proof to the circle identity $GE.GF=GH.GI$:
\begin{align*}
\angle HIE &= \angle HFG&(\because \angle HFE=180^\circ - \angle HIE\ \ \text{in the cyclic quadrilateral HFEI})\\ 
\Rightarrow\triangle GEI &\sim \triangle GHF&(\because AA^\prime\text{ similarity})\\ 
\Rightarrow \frac{GF}{GI} &= \frac{GH}{GE}\\ 
\end{align*}
