init_elements() z.O = point(0, 0) z.T = point(4, 0) C.OT = circle(z.O, z.T) z.A = C.OT:point(0.05) z.B = C.OT:point(0.20) z.M = C.OT:midarc(z.A, z.B) -- circle tangent to (OA) and (OB) through M, inside the sector local centers = line(z.O, z.A):c_ll_p(line(z.O, z.B), z.M) for i = 1, centers:count() do local c = centers:get(i) if point.abs(c - z.O) < point.abs(z.M - z.O) then z.W = c end end z.H = intersection(line(z.A, z.B), line(z.O, z.M)) L.pp = line(z.A, z.B):parallel_from(z.M) z.D = intersection(L.pp, line(z.O, z.B))