The following description of a triangle is given:

Let Δ ABC be a right angle triangle. With ∠ABC=90, AB=12cm, AC=15cm. The point D lies on AB such that DB = 7cm. The last point E lies on AC such that ∠DEA = 90.

I am trying to draw the triangle only using the information above. Meaning I do not want to use Pythagoras to calculate AB = sqrt(AC^2 - BC^2) = 9.

The restrictions above led me to use tkz-euclide. In particular the lines

    \tkzDefLine[orthogonal=through B](A,B) \tkzGetPoint{b}
    \tkzInterLC[R](B,b)(A,\AC cm) \tkzGetPoint{C}

Seemed promising in defining where the point C should lie. In short we define a line orthogonal to AB through B (Since the angle ABC = 90^c), then intersect this line with a circle with center in A and radius 15. See the figure below.

enter image description here

Here the blue triangle is the correct one, while the bigger one is the one defined through the command above. The numbers shows the radius, so the circle is too big 16.9>15.00 using the command above. However, the correct result is obtained using

    \tkzDefLine[orthogonal=through B](A,B) \tkzGetPoint{b}
    \tkzInterLC[R](B,b)(A,\AC cm) \tkzGetPoints{C}{C2}


    \tkzDefLine[orthogonal=through B](A,B) \tkzGetPoint{b}
    \tkzInterLC[R](B,b)(A,\AC cm) \tkzGetFirstPoint{C}

What is the difference? And what is the problem with using \tkzGetPoint?



    \tkzInit[xmin=-0.4,xmax=12.45,ymin=-0.5,ymax = 12.5]



    \tkzDefLine[orthogonal=through B](A,B) \tkzGetPoint{b}
    \tkzInterLC[R](B,b)(A,\AC cm) \tkzGetPoint{C}


    \tkzDefLine[orthogonal=through D](A,C) % \tkzGetPoint{d}
    \tkzInterLL(A,C)(D,tkzPointResult) \tkzGetPoint{E}


    \tkzLabelPoint[below left](A){$A$}
    \tkzLabelPoint[below right](B){$B$}
    \tkzLabelPoint[above right](C){$C$}
    \tkzLabelPoint[above left](E){\rAC}


2 Answers 2


The intersection of a circle and a line defines 0,1 or two points but when you get two points it's not possible to know the order. When the first point gives a bad result, you need to take the second. It's why I defined three macros to get the two points, or only one point.


I do not use tkz-euclide so I cannot say much to your actual problem, but would like to mention that you can do things very easily here with calc and intersection "only".

 \path (0,0) coordinate (A) (12,0) coordinate (B) (12-7,0) coordinate (D);
  \path[name path=circ] (A) circle[radius=15cm];
  \path[name path=line] (B) -- ++ (0,15cm);
  \path[name intersections={of=circ and line,by=C}];
 \draw[blue] (A) -- (B) -- (C) -- cycle;
 \draw[red] (D) -- ($(A)!(D)!(C)$);

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .