X3921

X3524com(EXTOUCH TRIANGLE)

< A B C >: Reference Triangle △ABC [ A B ]: Sideline AB (Base c = 1) [ B C ]: Sideline BC (Side a) [ C A ]: Sideline CA (Side b) { 10, 12 }: Central Line L(10, 12) { 405, 3158 }: Central Line L(405, 3158) { 517, 3545 }: Central Line L(517, 3545) { 392, 3679 }: Central Line L(392, 3679) { 1962, 3214 }: Central Line L(1962, 3214) { 1698, 3555 }: Central Line L(1698, 3555) A = Vertex A (0.0000, 0.0000) B = Vertex B (1.0000, 0.0000) C = Vertex C (0.6122, 0.5999) X_10 = SPIEKER CENTER (0.5204, 0.1833) X_12 = {X(1),X(5)}-HARMONIC CONJUGATE OF X(11) (0.5641, 0.2407) X_405 = EULER LINE INTERCEPT OF LINE X(1)X(6) (0.5325, 0.1870) X_3158 = -CEVA CONJUGATE OF X(9) (0.6726, 0.2916) X_517 = ISOGONAL CONJUGATE OF X(104) (0.8180, 0.7154) X_3545 = EULER LINE INTERCEPT OF LINE X(11)X(1056) (0.5624, 0.2652) X_392 = X(1,6)∩X(10,11) (0.5265, 0.1800) X_3679 = com(EXTOUCH TRIANGLE) (0.5034, 0.1666) X_1962 = BICENTRIC SUM OF PU(32) (0.5646, 0.2243) X_3214 = -CEVA CONJUGATE OF X(37) (0.7124, 0.3714) X_1698 = INSIMILICENTER(BEVAN CIRCLE, NINE-POINTCIRCLE) (0.5306, 0.1933) X_3555 = DOSA POINT (0.7061, 0.3933) X_3921 = com(EXTOUCH TRIANGLE) (0.5111, 0.1711) A B C X10 X12 X405 X3158 X517 X3545 X392 X3679 X1962 X3214 X1698 X3555 X3921 (a, b, c) = (5, 6, 7) | AB = 1

X3921 (X3524com(EXTOUCH TRIANGLE)) constructed on acute reference triangle \((a, b, c) = (5, 6, 7)\) with unit baseline AB = \(1\).

"""GEOMETOR construction model for X_3921 = X_3524com(EXTOUCH TRIANGLE)."""

        from __future__ import annotations

        from pathlib import Path

        import sympy.geometry as spg
        from geometor.model import Model

        from geometor.etc.ops import (
            central_line,
            construct_baseline_triangle,
            create_model,
            eval_barycentric_point,
            eval_trilinear_point,
            promote_point_to_top,
            spieker_center_of,
        )
        from geometor.etc.render import write_center_svg


        def construct_x_03921(
            model: Model, A: spg.Point, B: spg.Point, C: spg.Point
        ) -> spg.Point:
            """Construct X_3921 = X_3524com(EXTOUCH TRIANGLE) on reference triangle ABC."""
            X_3921 = eval_barycentric_point(model, A, B, C, '(a*(b + c)*(b**(2) + c**(2) - a**(2) + 8*b*c))', ID="X_3921", classes=["selected", "target"])
            X_10 = spieker_center_of(model, A, B, C, ID="X_10", classes=["center", "incident"])
            X_12 = eval_trilinear_point(model, A, B, C, '1 + cos(B - C)', ID="X_12", classes=["center", "incident"])
            central_line(model, X_10, X_12, 10, 12, incident=True)
            X_405 = eval_trilinear_point(model, A, B, C, 'b*c*(a + b + c) + a*b*c*cos(A)', ID="X_405", classes=["center", "incident"])
            X_3158 = eval_trilinear_point(model, A, B, C, '((b + c - a)*(b + c - 3*a))', ID="X_3158", classes=["center", "incident"])
            central_line(model, X_405, X_3158, 405, 3158, incident=True)
            X_517 = eval_trilinear_point(model, A, B, C, '-1 + cos(B) + cos(C)', ID="X_517", classes=["center", "incident"])
            X_3545 = eval_trilinear_point(model, A, B, C, '3*cos(B)*cos(C) + 2*sin(B)*sin(C)', ID="X_3545", classes=["center", "incident"])
            central_line(model, X_517, X_3545, 517, 3545, incident=True)
            return promote_point_to_top(model, X_3921)


        def build_model(
            sides: tuple[float, float, float] = (5.0, 6.0, 7.0),
            show_guides: bool = False,
        ) -> Model:
            """Build a `geometor.model.Model` for X_3921 on the given reference triangle."""
            model = create_model('X_3921 = X_3524com(EXTOUCH TRIANGLE)')
            A, B, C = construct_baseline_triangle(model, *sides, show_guides=show_guides)
            construct_x_03921(model, A, B, C)
            return model


        if __name__ == "__main__":
            here = Path(__file__).resolve().parent
            model_acute = build_model((5.0, 6.0, 7.0))
            model_acute.save(str(here / "x-03921.json"))
            write_center_svg(
                model_acute,
                here / "x-03921.svg",
                subtitle="(a, b, c) = (5, 6, 7) | AB = 1",
            )