The Pythagorean Theorem VI

|
\documentclass[tikz, border=2pt]{standalone}
|
|
\usetikzlibrary{calc}
|
|
\usetikzlibrary{math}
|
|
\begin{document}
|
|
\begin{tikzpicture}[line width=1pt]
|
|
\tikzmath{
|
|
\a = 5; \b = 12; \c = sqrt(\a*\a + \b*\b);
|
|
\l = 5;
|
|
\a = \a / \c * \l;
|
|
\b = \b / \c * \l;
|
|
\c = \l;
|
|
}
|
|
\coordinate (O) at (0, 0);
|
|
\coordinate (A) at (\a, 0);
|
|
\coordinate (B) at (\a, \b);
|
|
\coordinate (C) at (\c, 0);
|
|
\draw (O) circle [radius=\c];
|
|
\draw (O) -- node[above] {$c$} ($(O)-(C)$) node[left, align=center] {$\displaystyle\frac{c+a}{b}=\displaystyle\frac{b}{c-a}$\\ \\ $a^2+b^2=c^2$};
|
|
\draw (O) -- node[above] {$a$} (A);
|
|
\draw (A) -- node[above] {$c-a$} (C);
|
|
\draw (O) -- node[left] {$c$} (B);
|
|
\draw (A) -- node[right] {$b$} (B);
|
|
\draw[thin] (A) ++(-0.05*\l, 0) -- ++(0, 0.05*\l) -- ++(0.05*\l, 0);
|
|
\end{tikzpicture}
|
|
\end{document}
|
评论
Comments powered by Disqus