summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-11-10 21:41:33 +0000
committerKarl Berry <karl@freefriends.org>2023-11-10 21:41:33 +0000
commit558b3386c6394c9542a7a3baddaa343f607776cf (patch)
tree6978c026fcbad9736efd6edf1657a18e1bc00fe5 /Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua
parent4994a32e6461365ce9fc7db632993d6bc096f7d7 (diff)
tkz-elements (10nov23)
git-svn-id: svn://tug.org/texlive/trunk@68806 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua')
-rw-r--r--Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua35
1 files changed, 20 insertions, 15 deletions
diff --git a/Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua b/Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua
index e1d6b4bd536..fe9c91d2f75 100644
--- a/Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua
+++ b/Master/texmf-dist/tex/latex/tkz-elements/tkz_elements_functions_circles.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_circles.lua
--- date 2023/10/20
--- version 1.00b
+-- date 2023/11/10
+-- version 1.20b
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -14,23 +14,28 @@
-- define a circle by the center and a radius
-function circle_cr ( c, r )
- return c + point(r,0)
-end
+-- function circle_cr ( c, r )
+-- return c + point(r,0)
+-- end
function midarc_ (o,a,b) -- a -> b
local phi = 0.5 * get_angle_ ( a,o,b )
return rotation_ (o,phi,b)
end
----------------------------------------------------------------------------
--- -- possible (C,p) with C.center and C.through
--- function tangent_from (c,p)
--- local m = midpoint_ (c.center,p)
--- return intersection_cc_ (c.center,c.through,m,p)
--- end
----------------------------------------------------------------------------
--- tangente à un cercle
----------------------------------------------------------------------------
+
+function radical_center (C1,C2,C3)
+ local t1,t2,t3,t4
+ t1,t2 = radical_axis_ (C3.center,C3.through,C1.center,C1.through)
+ t3,t4 = radical_axis_ (C3.center,C3.through,C2.center,C2.through)
+return intersection_ll_ (t1,t2,t3,t4)
+end
+
+function radical_circle (C1,C2,C3)
+ local rc
+ rc = radical_center (C1,C2,C3)
+ return C1 : orthogonal_from (rc)
+end
+
function tangent_from_ (c,p,pt)
local o
o = midpoint_ ( c,pt )
@@ -38,7 +43,7 @@ function tangent_from_ (c,p,pt)
end
function tangent_at_ (a,b,p)
- return rotation_ (p,math.pi/2,a),rotation_ (p,-math.pi/2,a)
+ return rotation_ (p,math.pi/2,a),rotation_ (p,-math.pi/2,a)
end
function orthogonal_from_ (a,b,p)