summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/tkz/tkz-euclide/doc/latex/TKZdoc-euclide-circles.tex
blob: 66bbea6c769214ac56a4eaefe95ff2fbcff67489 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
\section{The Circles}

Among the following macros, one will allow you to draw a circle, which is not a real feat. To do this, you will need to know the center of the circle and either the radius of the circle or a point on the circumference. It seemed to me that the most frequent use was to draw a circle with a given centre passing through a given point. This will be the default method, otherwise you will have to use the \tkzname{R} option. There are a large number of special circles, for example the circle circumscribed by a triangle.

\begin{itemize}
  \item  I have created a first macro \tkzcname{tkzDefCircle} which allows, according to a particular circle, to retrieve its center and the measurement of the radius in cm. This recovery is done with the macros \tkzcname{tkzGetPoint} and \tkzcname{tkzGetLength},
 
 \item then a macro \tkzcname{tkzDrawCircle}
 
 \item then a macro that allows you to color in a disc, but without drawing the circle \tkzcname{tkzFillCircle}
 
 \item sometimes, it is necessary for a drawing to be contained in a disk this is the role assigned to \tkzcname{tkzClipCircle},

 
 \item  It finally remains to be able to give a label to designate a circle and if several possibilities are offered, we will see here \tkzcname{tkzLabelCircle}.
\end{itemize}
 

\subsection{Characteristics of a circle : \tkzcname{tkzDefCircle}}
 
This macro allows you to retrieve the characteristics (center and radius) of certain circles.

\begin{NewMacroBox}{tkzDefCircle}{\oarg{local options}\parg{A,B} ou \parg{A,B,C}}
\tkzHandBomb\ Attention the arguments are lists of two or three points. This macro is either used in partnership with \tkzcname{tkzGetPoint} and/or \tkzcname{tkzGetLength} to obtain the center and the radius of the circle, or by using \tkzname{tkzPointResult} and \tkzname{tkzLengthResult} if it is not necessary to keep the results.

\medskip
\begin{tabular}{lll}
\toprule
arguments           & exemple & explication                         \\
\midrule
\TAline{\parg{pt1,pt2} or \parg{pt1,pt2,pt3}}{\parg{A,B}} {$[AB]$ is radius $A$ is the center}
\bottomrule
\end{tabular} 

\medskip
\begin{tabular}{lll}
\toprule
options             & derror & definition                         \\ 
\midrule
\TOline{through}      {through}{circle characterized by two points defining a radius} 
\TOline{diameter}     {through}{circle characterized by two points defining a diameter}
\TOline{circum}       {through}{circle circumscribed of a triangle} 
\TOline{in}           {through}{incircle a triangle} 
\TOline{ex}           {through}{excircle of a  triangle}
\TOline{euler or nine}{through}{Euler's Circle}
\TOline{spieker}      {through}{Spieker Circle}
\TOline{apollonius}   {through}{circle of Apollonius} 
\TOline{orthogonal}   {through}{circle of given centre orthogonal to another circle}
\TOline{orthogonal through}{through}{circle orthogonal circle passing through 2 points} 
\TOline{K} {1}{coefficient used for a circle of Apollonius} 
 \bottomrule
\end{tabular}

{In the following examples, I draw the circles with a macro not yet presented, but this is not necessary. In some cases you may only need the center or the radius.}
\end{NewMacroBox}  

 \subsubsection{Example with a random point and the option \tkzimp{through}} 

\begin{tkzexample}[latex=7 cm,small]
 \begin{tikzpicture}[scale=1]
 \tkzDefPoint(0,4){A}
 \tkzDefPoint(2,2){B}
 \tkzDefMidPoint(A,B) \tkzGetPoint{I}
 \tkzDefRandPointOn[segment = I--B]
  \tkzGetPoint{C}
 \tkzDefCircle[through](A,C) 
 \tkzGetLength{rACpt}
 \tkzpttocm(\rACpt){rACcm} 
 \tkzDrawCircle(A,C)
 \tkzDrawPoints(A,B,C)
 \tkzLabelPoints(A,B,C) 
 \tkzLabelCircle[draw,fill=orange,
          text width=3cm,text centered,
          font=\scriptsize](A,C)(-90)%
 {La mesure du rayon est :
  \rACpt pt soit \rACcm cm}  
 \end{tikzpicture}     
 \end{tkzexample}  
 
 \subsubsection{Example with  the option \tkzimp{diameter}}  
 It is simpler here to search directly for the middle of AB
 \begin{tkzexample}[latex=7cm,small]  
 \begin{tikzpicture}[scale=1]
    \tkzDefPoint(0,0){A} 
    \tkzDefPoint(2,2){B}
    \tkzDefCircle[diameter](A,B)  
    \tkzGetPoint{O}  
    \tkzDrawCircle[blue,fill=blue!20](O,B) 
    \tkzDrawSegment(A,B)
    \tkzDrawPoints(A,B,O)   
    \tkzLabelPoints(A,B,O)
 \end{tikzpicture} 
 \end{tkzexample}    

 \subsubsection{Circles inscribed and circumscribed for a given triangle}
 You can also obtain the center of the inscribed circle and its projection on one side of the triangle with \tkzcname{tkzGetFirstPoint{I}} et \tkzcname{tkzGetSecondPoint{Ib}}. 
 
 
\begin{tkzexample}[latex=7cm,small]  
\begin{tikzpicture}[scale=1]
   \tkzDefPoint(2,2){A} 
   \tkzDefPoint(5,-2){B}
   \tkzDefPoint(1,-2){C}
   \tkzDefCircle[in](A,B,C)
   \tkzGetPoint{I}    \tkzGetLength{rIN}
   \tkzDefCircle[circum](A,B,C)
   \tkzGetPoint{K}   \tkzGetLength{rCI}
   \tkzDrawPoints(A,B,C,I,K)    
   \tkzDrawCircle[R,blue](I,\rIN pt) 
   \tkzDrawCircle[R,red](K,\rCI pt) 
   \tkzLabelPoints[below](B,C)
   \tkzLabelPoints[above left](A,I,K)
   \tkzDrawPolygon(A,B,C)
\end{tikzpicture} 
\end{tkzexample}

 \subsubsection{Example with the option \tkzimp{ex}}
We want to define an excircle of a  triangle relativement au point C

\begin{tkzexample}[latex=8cm,small]
\begin{tikzpicture}[scale=.75]
	\tkzDefPoints{ 0/0/A,4/0/B,0.8/4/C}
	\tkzDefCircle[ex](B,C,A) 		               
  \tkzGetPoint{Jc} \tkzGetLength{rc}
	\tkzDefPointBy[projection=onto A--C ](Jc)	 
  \tkzGetPoint{Xc}
  \tkzDefPointBy[projection=onto A--B ](Jc)	 
  \tkzGetPoint{Yc}	 	  
  \tkzGetPoint{I}
  \tkzDrawPolygon[color=blue](A,B,C)
  \tkzDrawCircle[R,color=lightgray](Jc,\rc pt)
  % possible  \tkzDrawCircle[ex](A,B,C) 
  \tkzDrawCircle[in,color=red](A,B,C)    \tkzGetPoint{I} 
	\tkzDefPointBy[projection=onto A--C ](I)	 
  \tkzGetPoint{F} 
	\tkzDefPointBy[projection=onto A--B ](I)	 
  \tkzGetPoint{D}    
	\tkzDrawLines[add=0 and 2.2,dashed](C,A C,B)
	\tkzDrawSegments[dashed](Jc,Xc I,D  I,F Jc,Yc)
	\tkzMarkRightAngles(A,F,I B,D,I Jc,Xc,A Jc,Yc,B)
	\tkzDrawPoints(B,C,A,I,D,F,Xc,Jc,Yc)
 	\tkzLabelPoints(B,A,Jc,I,D,Xc,Yc)
 	\tkzLabelPoints[above left](C)
	\tkzLabelPoints[left](F)
\end{tikzpicture}    
\end{tkzexample}
  
 \subsubsection{Euler's circle for a given triangle}
 
We verify that this circle passes through the middle of each side.
\begin{tkzexample}[latex=8cm,small]  
\begin{tikzpicture}[scale=.75]
   \tkzDefPoint(5,3.5){A} 
   \tkzDefPoint(0,0){B} \tkzDefPoint(7,0){C}
   \tkzDefCircle[euler](A,B,C)
   \tkzGetPoint{E}  \tkzGetLength{rEuler}
   \tkzDefSpcTriangle[medial](A,B,C){Ma,Mb,Mc}
   \tkzDrawPoints(A,B,C,E,Ma,Mb,Mc)    
   \tkzDrawCircle[R,blue](E,\rEuler pt)
   \tkzDrawPolygon(A,B,C)    
   \tkzLabelPoints[below](B,C)  
   \tkzLabelPoints[left](A,E)   
\end{tikzpicture}
\end{tkzexample}

 \subsubsection{Coloured Apollonius circles for a given segment} 
 
\begin{tkzexample}[latex=9cm,small]    
\begin{tikzpicture}[scale=0.75]
  \tkzDefPoint(0,0){A} 
  \tkzDefPoint(4,0){B}
  \tkzDefCircle[apollonius,K=2](A,B)
  \tkzGetPoint{K1}
  \tkzGetLength{rAp}
  \tkzDrawCircle[R,color = blue!50!black,
      fill=blue!20,opacity=.4](K1,\rAp pt)
  \tkzDefCircle[apollonius,K=3](A,B)
  \tkzGetPoint{K2}   \tkzGetLength{rAp}
  \tkzDrawCircle[R,color=red!50!black,
   fill=red!20,opacity=.4](K2,\rAp pt) 
  \tkzLabelPoints[below](A,B,K1,K2)
  \tkzDrawPoints(A,B,K1,K2) 
  \tkzDrawLine[add=.2 and 1](A,B)  
\end{tikzpicture}
\end{tkzexample}  

 \subsubsection{Circles exinscribed to a given triangle}
 You can also get the center and the projection of it on one side of the triangle. 
 
 with \tkzcname{tkzGetFirstPoint\{Jb\}} and \tkzcname{tkzGetSecondPoint\{Tb\}}.
 
\begin{tkzexample}[latex=8cm,small]  
\begin{tikzpicture}[scale=.6]
  \tkzDefPoint(0,0){A}
  \tkzDefPoint(3,0){B}
  \tkzDefPoint(1,2.5){C}
  \tkzDefCircle[ex](A,B,C) \tkzGetPoint{I} 
    \tkzGetLength{rI}
  \tkzDefCircle[ex](C,A,B) \tkzGetPoint{J} 
    \tkzGetLength{rJ}
  \tkzDefCircle[ex](B,C,A) \tkzGetPoint{K} 
    \tkzGetLength{rK}
   \tkzDefCircle[in](B,C,A) \tkzGetPoint{O}
     \tkzGetLength{rO} 
  \tkzDrawLines[add=1.5 and 1.5](A,B A,C B,C)
  \tkzDrawPoints(I,J,K)
  \tkzDrawPolygon(A,B,C)
  \tkzDrawPolygon[dashed](I,J,K)
  \tkzDrawCircle[R,blue!50!black](O,\rO)
  \tkzDrawSegments[dashed](A,K B,J C,I)
  \tkzDrawPoints(A,B,C)
  \tkzDrawCircles[R](J,{\rJ} I,{\rI} K,{\rK})    
  \tkzLabelPoints(A,B,C,I,J,K)
\end{tikzpicture}
\end{tkzexample}
 
  \subsubsection{Spieker circle}   
The  incircle of the medial triangle $M_AM_BM_C$ is the Spieker circle

\begin{tkzexample}[latex=8cm, small]
\begin{tikzpicture}[scale=1]
  \tkzDefPoints{ 0/0/A,4/0/B,0.8/4/C}
   \tkzDefSpcTriangle[medial](A,B,C){Ma,Mb,Mc}
   \tkzDefTriangleCenter[spieker](A,B,C) 
   \tkzGetPoint{Sp}
   \tkzDrawPolygon[blue](A,B,C)
   \tkzDrawPolygon[red](Ma,Mb,Mc)
   \tkzDrawPoints[blue](B,C,A)
   \tkzDrawPoints[red](Ma,Mb,Mc,Sp)
   \tkzDrawCircle[in,red](Ma,Mb,Mc)
   \tkzAutoLabelPoints[center=Sp,dist=.3](Ma,Mb,Mc)
   \tkzLabelPoints[blue,right](Sp)
   \tkzAutoLabelPoints[center=Sp](A,B,C)
\end{tikzpicture}
\end{tkzexample}
 
   
 \subsubsection{Orthogonal circle passing through two given points} 
 
\begin{tkzexample}[latex=8cm,small]  
\begin{tikzpicture}[scale=1]
  \tkzDefPoint(0,0){O}
  \tkzDefPoint(1,0){A}
  \tkzDrawCircle(O,A) 
  \tkzDefPoint(-1.5,-1.5){z1}
  \tkzDefPoint(1.5,-1.25){z2} 
  \tkzDefCircle[orthogonal through=z1 and z2](O,A)
   \tkzGetPoint{c}    
  \tkzDrawCircle[thick,color=red](tkzPointResult,z1)
  \tkzDrawPoints[fill=red,color=black,
  size=4](O,A,z1,z2,c)
  \tkzLabelPoints(O,A,z1,z2,c) 
\end{tikzpicture}
\end{tkzexample}

\subsubsection{Orthogonal circle of given center} 
 
\begin{tkzexample}[latex=7cm,small]
\begin{tikzpicture}[scale=.75]
  \tkzDefPoints{0/0/O,1/0/A}
  \tkzDefPoints{1.5/1.25/B,-2/-3/C}
  \tkzDefCircle[orthogonal from=B](O,A)
  \tkzGetPoints{z1}{z2}
  \tkzDefCircle[orthogonal from=C](O,A)
  \tkzGetPoints{t1}{t2}
  \tkzDrawCircle(O,A)
  \tkzDrawCircle[thick,color=red](B,z1)
  \tkzDrawCircle[thick,color=red](C,t1)
  \tkzDrawPoints(t1,t2,C)
  \tkzDrawPoints(z1,z2,O,A,B)
  \tkzLabelPoints(O,A,B,C)
\end{tikzpicture}
\end{tkzexample}


%<---------------------------------------------------------------------------->
% Tangente
%<---------------------------------------------------------------------------->
\subsection{Tangent to a circle}
Two constructions are proposed. The first one is the construction of a tangent to a circle at a given point of this circle and the second one is the construction of a tangent to a circle passing through a given point outside a disc. 

\begin{NewMacroBox}{tkzDefTangent}{\oarg{local options}\parg{pt1,pt2} ou \parg{pt1,dim}}
The parameter in brackets is the center of the circle or the center of the circle and a point on the circle or the center and the radius.

\medskip
\begin{tabular}{lll}
\toprule
arguments           & exemple & explication                         \\
\midrule
\TAline{\parg{pt1,pt2 or \parg{pt1,dim}} }{\parg{A,B} or \parg{A,2cm}} {$[AB]$ is radius $A$ is the center}
\bottomrule
\end{tabular} 

\medskip
\begin{tabular}{lll}
\toprule
options             & default & definition                         \\ 
\midrule
\TOline{at=pt}{at}{tangent to a point on the circle} 
\TOline{from=pt} {at}{tangent to a circle passing through a point}
\TOline{from with R=pt} {at}{idem, but the circle is defined by center = radius}  
\bottomrule
\end{tabular}

The tangent is not drawn. A second point of the tangent is given by \tkzname{tkzPointResult}.
\end{NewMacroBox}

 \subsubsection{Example of a tangent passing through a point on the circle } 
\begin{tkzexample}[latex=7cm,small]
\begin{tikzpicture}[scale=.5]
  \tkzDefPoint(0,0){O}
  \tkzDefPoint(6,6){E}
  \tkzDefRandPointOn[circle=center O radius 4cm]
  \tkzGetPoint{A}
  \tkzDrawSegment(O,A)
  \tkzDrawCircle(O,A)
  \tkzDefTangent[at=A](O)
  \tkzGetPoint{h}
  \tkzDrawLine[add = 4 and 3](A,h)
  \tkzMarkRightAngle[fill=red!30](O,A,h)
\end{tikzpicture}
\end{tkzexample}

 \subsubsection{Example of tangents passing through an external point } 

\begin{tkzexample}[latex=6cm,small]
\begin{tikzpicture}[scale=0.75] 
  \tkzDefPoint(3,3){c}
  \tkzDefPoint(6,3){a0}  
  \tkzRadius=1 cm 
  \tkzDrawCircle[R](c,\tkzRadius) 
  \foreach \an in {0,10,...,350}{
     \tkzDefPointBy[rotation=center c angle \an](a0)  
     \tkzGetPoint{a}  
     \tkzDefTangent[from with R = a](c,\tkzRadius)  
     \tkzGetPoints{e}{f} 
     \tkzDrawLines[color=magenta](a,f a,e) 
      \tkzDrawSegments(c,e c,f)
      }%
\end{tikzpicture} 
\end{tkzexample}

 \subsubsection{Example of Andrew Mertz }

\begin{tkzexample}[latex=6cm,small]
 \begin{tikzpicture}[scale=.5] 
 \tkzDefPoint(100:8){A}\tkzDefPoint(50:8){B}  
 \tkzDefPoint(0,0){C} \tkzDefPoint(0,4){R} 
 \tkzDrawCircle(C,R)
 \tkzDefTangent[from = A](C,R)  \tkzGetPoints{D}{E}
 \tkzDefTangent[from = B](C,R)  \tkzGetPoints{F}{G}
 \tkzDrawSector[fill=blue!80!black,opacity=0.5](A,D)(E)
 \tkzFillSector[color=red!80!black,opacity=0.5](B,F)(G)
 \tkzInterCC(A,D)(B,F) \tkzGetSecondPoint{I}
 \tkzDrawPoint[color=black](I)
 \end{tikzpicture}
\end{tkzexample}
\url{http://www.texample.net/tikz/examples/}  

\section{Draw, Label The Circles}

Among the following macros, one will allow you to draw a circle, which is not a real feat. To do this, you will need to know the center of the circle and either the radius of the circle or a point on the circumference. It seemed to me that the most frequent use was to draw a circle with a given centre passing through a given point. This will be the default method, otherwise you will have to use the \tkzname{R} option. 

\begin{itemize}
 \item  I created a first macro  \tkzcname{tkzDrawCircle},
 
 \item then a macro that allows you to color a disc, but without drawing the circle. \tkzcname{tkzFillCircle},
 
 \item sometimes, it is necessary for a drawing to be contained in a disc is the role assigned to \tkzcname{tkzClipCircle},

 
 \item  It finally remains to be able to give a label to designate a circle and if several possibilities are offered, we will see here \tkzcname{tkzLabelCircle}.
\end{itemize}
 
\subsection{Draw a circle}
\begin{NewMacroBox}{tkzDrawCircle}{\oarg{local options}\parg{A,B}}
\tkzHandBomb\ Attention the arguments are lists of two points. The circles that can be drawn are the same as in the previous macro. An additional option \tkzname{R} to give directly a measure.

\medskip
\begin{tabular}{lll}
\toprule
arguments           & exemple & explication                         \\
\midrule
\TAline{\parg{pt1,pt2 pt3,pt4 ...}}{\parg{A,B C,D}} {List of two points}
\bottomrule
\end{tabular}   

\medskip
\begin{tabular}{lll}
\toprule
options             & default & definition                         \\ 
\midrule
\TOline{through}{through}{circle with two points defining a radius}
\TOline{diameter}{through}{circle with two points defining a diameter}
\TOline{R} {through}{circle characterized by a point and the measurement of a radius}
 \bottomrule
\end{tabular}

\medskip
Of course, you have to add all the styles of \TIKZ for the tracings...
\end{NewMacroBox}
 
 \subsubsection{Circles and styles, draw a circle and color the disc}
 We'll see that it's possible to colour in a disc while tracing the circle.
 
\begin{tkzexample}[latex=7cm,small]
\begin{tikzpicture}
  \tkzDefPoint(0,0){O} 
  \tkzDefPoint(3,0){A}
 % cercle de centre O et passant par A
  \tkzDrawCircle[color=blue,style=dashed](O,A) 
 % cercle de diamètre $[OA]$
  \tkzDrawCircle[diameter,color=red,%
                 line width=2pt,fill=red!40,%
                 opacity=.5](O,A)
 % cercle de centre O et de rayon = exp(1) cm
  \edef\rayon{\fpeval{exp(1)}}
  \tkzDrawCircle[R,color=orange](O,\rayon cm) 
\end{tikzpicture} 
\end{tkzexample}  

\subsection{Drawing circles}  
\begin{NewMacroBox}{tkzDrawCircles}{\oarg{local options}\parg{A,B C,D}}
\tkzHandBomb\ Attention, the arguments are lists of two points. The circles that can be drawn are the same as in the previous macro. An additional option \tkzname{R} to give directly a measure.

\medskip
\begin{tabular}{lll}
\toprule
arguments           & exemple & explication                         \\
\midrule
\TAline{\parg{pt1,pt2 pt3,pt4 ...}}{\parg{A,B C,D}} {List of two points}
\bottomrule
\end{tabular}   

\medskip
\begin{tabular}{lll}
\toprule
options             & default & definition                         \\ 
\midrule
\TOline{through}{through}{circle with two points defining a radius}
\TOline{diameter}{through}{circle with two points defining a diameter}
\TOline{R} {through}{circle characterized by a point and the measurement of a radius}
 \bottomrule
\end{tabular}

\medskip
Of course, you have to add all the styles of \TIKZ for the tracings...
\end{NewMacroBox}

 \subsubsection{Circles defined by a triangle.} 
 
\begin{tkzexample}[latex=9cm,small]
\begin{tikzpicture}
  \tkzDefPoint(0,0){A}
  \tkzDefPoint(2,0){B}
  \tkzDefPoint(3,2){C}
  \tkzDrawPolygon(A,B,C)
  \tkzDrawCircles(A,B B,C C,A)
  \tkzDrawPoints(A,B,C)
  \tkzLabelPoints(A,B,C) 
\end{tikzpicture} 
\end{tkzexample}

 \subsubsection{Concentric circles.} 
 
\begin{tkzexample}[latex=7cm,small]
\begin{tikzpicture}
   \tkzDefPoint(0,0){A}
   \tkzDrawCircles[R](A,1cm A,2cm A,3cm)
   \tkzDrawPoint(A)
   \tkzLabelPoints(A)
\end{tikzpicture}
\end{tkzexample}

 \subsubsection{Exinscribed circles.} 

\begin{tkzexample}[latex=7cm,small] 
\begin{tikzpicture}[scale=1] 
\tkzDefPoints{0/0/A,4/0/B,1/2.5/C}
\tkzDrawPolygon(A,B,C)
\tkzDefCircle[ex](B,C,A) 
\tkzGetPoint{Jc} \tkzGetSecondPoint{Tc}
\tkzGetLength{rJc} 
\tkzDrawCircle[R](Jc,{\rJc pt})
\tkzDrawLines[add=0 and 1](C,A C,B)
\tkzDrawSegment(Jc,Tc)
\tkzMarkRightAngle(Jc,Tc,B)
\tkzDrawPoints(A,B,C,Jc,Tc)
\end{tikzpicture}
\end{tkzexample}
 
  \subsubsection{Cardioid}  
 Based on an idea by O. Reboux made with pst-eucl (Pstricks module) by D. Rodriguez.

 Its name comes from the Greek kardia (heart), in reference to its shape, and was given to it by Johan Castillon. Wikipedia     
 
   \begin{tkzexample}[latex=7cm,small]
   \begin{tikzpicture}[scale=.5]
     \tkzDefPoint(0,0){O} 
     \tkzDefPoint(2,0){A}
     \foreach \ang in {5,10,...,360}{%
        \tkzDefPoint(\ang:2){M}
        \tkzDrawCircle(M,A) 
      }  
   \end{tikzpicture} 
   \end{tkzexample}

\subsection{Draw a semicircle}
\begin{NewMacroBox}{tkzDrawSemiCircle}{\oarg{local options}\parg{A,B} ou \parg{A,B,C}}
\tkzHandBomb\ Attention the arguments are lists of two or three points. This macro is either used in partnership with \tkzcname{tkzGetPoint} and/or \tkzcname{tkzGetLength} to obtain the center and the radius of the circle, or by using \\ \tkzname{tkzPointResult} and \tkzname{tkzLengthResult} if it is not necessary to keep the results.
  

\medskip
\begin{tabular}{lll}
\toprule
options             & default & definition                         \\ 
\midrule
\TOline{through}  {through}{circle characterized by two points defining a radius} 
\TOline{diameter} {through}{circle characterized by two points defining a diameter}
 \bottomrule
\end{tabular}


\end{NewMacroBox}  

	   
\subsection{Colouring a disc}
This was possible with the previous macro, but disk tracing was mandatory, this is no longer the case.
  
\begin{NewMacroBox}{tkzFillCircle}{\oarg{local options}\parg{A,B}}
\begin{tabular}{lll}
options             & default & definition                         \\ 
\midrule
\TOline{radius}  {radius}{two points define a radius}
\TOline{R} {radius}{a point and the measurement of a radius }
\bottomrule
\end{tabular}

\medskip
You don't need to put \tkzname{radius} because that's the default option. Of course, you have to add all the styles of \TIKZ for the plots.
\end{NewMacroBox}  

 \subsubsection{Example from a sangaku} 

\begin{tkzexample}[latex=7cm,small]
\begin{tikzpicture}
   \tkzInit[xmin=0,xmax = 6,ymin=0,ymax=6] 
   \tkzDefPoint(0,0){B}  \tkzDefPoint(6,0){C}%
   \tkzDefSquare(B,C)    \tkzGetPoints{D}{A} 
   \tkzClipPolygon(B,C,D,A) 
   \tkzDefMidPoint(A,D)  \tkzGetPoint{F}
   \tkzDefMidPoint(B,C)  \tkzGetPoint{E}
   \tkzDefMidPoint(B,D)  \tkzGetPoint{Q}           
   \tkzDefTangent[from = B](F,A) \tkzGetPoints{G}{H} 
   \tkzInterLL(F,G)(C,D) \tkzGetPoint{J}
   \tkzInterLL(A,J)(F,E) \tkzGetPoint{K}
   \tkzDefPointBy[projection=onto B--A](K)   
	 \tkzGetPoint{M}  
   \tkzFillPolygon[color = green](A,B,C,D)
   \tkzFillCircle[color = orange](B,A)
   \tkzFillCircle[color = blue!50!black](M,A)
   \tkzFillCircle[color = purple](E,B)
   \tkzFillCircle[color = yellow](K,Q)  
\end{tikzpicture}
\end{tkzexample} 


  
\newpage     
\subsection{Clipping a disc}

\begin{NewMacroBox}{tkzClipCircle}{\oarg{local options}\parg{A,B} or \parg{A,r}}


\medskip
\begin{tabular}{lll}
\toprule
arguments           & exemple & explication                         \\
\midrule
\TAline{\parg{A,B} or \parg{A,r}}{\parg{A,B} or \parg{A,2cm}} {AB radius or diameter }
\bottomrule
\end{tabular}  
 
\medskip
\begin{tabular}{lll}
options             & default & definition                         \\ 
\midrule
\TOline{radius} {radius}{circle characterized by two points defining a radius} 
\TOline{R} {radius}{circle characterized by a point and the measurement of a radius }  
\bottomrule
\end{tabular}

\medskip
It is not necessary to put \tkzname{radius} because that is the default option.
\end{NewMacroBox}

 \subsubsection{Example} 
\begin{tkzexample}[latex=6cm,small] 
  \begin{tikzpicture}
  \tkzInit[xmax=5,ymax=5]
  \tkzGrid \tkzClip 
  \tkzDefPoint(0,0){A}
  \tkzDefPoint(2,2){O}
  \tkzDefPoint(4,4){B}
  \tkzDefPoint(6,6){C}
  \tkzDrawPoints(O,A,B,C) 
  \tkzLabelPoints(O,A,B,C)
  \tkzDrawCircle(O,A) 
  \tkzClipCircle(O,A)
  \tkzDrawLine(A,C)
  \tkzDrawCircle[fill=red!20,opacity=.5](C,O) 
\end{tikzpicture} 
\end{tkzexample}


\subsection{Giving a label to a circle}
\begin{NewMacroBox}{tkzLabelCircle}{\oarg{local options}\parg{A,B}\parg{angle}\marg{label}}
\begin{tabular}{lll}
\toprule

options             & default & definition                         \\
\midrule
\TOline{radius}  {radius}{circle characterized by two points defining a radius}
\TOline{R} {radius}{circle characterized by a point and the measurement of a radius }
\bottomrule
\end{tabular} 

\medskip
You don't need to put \tkzname{radius} because that's the default option. We can use the styles from \TIKZ. The label is created and therefore "passed" between braces.
\end{NewMacroBox} 

\subsubsection{Example}  
\begin{tkzexample}[latex=5cm,small] 
\begin{tikzpicture}
 \tkzDefPoint(0,0){O} \tkzDefPoint(2,0){N}
 \tkzDefPointBy[rotation=center O angle 50](N) 
     \tkzGetPoint{M}
 \tkzDefPointBy[rotation=center O angle -20](N) 
      \tkzGetPoint{P}
 \tkzDefPointBy[rotation=center O angle 125](N) 
      \tkzGetPoint{P'}
 \tkzLabelCircle[above=4pt](O,N)(120){$\mathcal{C}$}
 \tkzDrawCircle(O,M) 
 \tkzFillCircle[color=blue!20,opacity=.4](O,M) 
 \tkzLabelCircle[R,draw,fill=orange,%
       text width=2cm,text centered](O,3 cm)(-60)%
          {Le cercle\\ $\mathcal{C}$}  
 \tkzDrawPoints(M,P)\tkzLabelPoints[right](M,P)   
\end{tikzpicture}      
\end{tkzexample} 

\endinput