X3915

X3710com(TANGENTIAL 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) circumcircle: Circumcircle of △ABC { 1, 21 }: Central Line L(1, 21) { 8, 238 }: Central Line L(8, 238) { 46, 244 }: Central Line L(46, 244) { 40, 614 }: Central Line L(40, 614) { 10, 748 }: Central Line L(10, 748) { 3, 902 }: Central Line L(3, 902) A = Vertex A (0.0000, 0.0000) B = Vertex B (1.0000, 0.0000) C = Vertex C (0.6122, 0.5999) X_3 = CIRCUMCENTER (0.5000, 0.1021) X_109 = Ψ(INCENTER, CIRCUMCENTER) (0.3636, 0.5938) X_765 = CEVAPOINT OF X(1) AND X(100) (0.4286, 0.3110) X_1 = INCENTER (0.5714, 0.2333) X_21 = SCHIFFLER POINT (0.5287, 0.1771) X_8 = NAGEL POINT (0.4694, 0.1333) X_238 = -LINE CONJUGATE OF X(37) (1.6190, 1.4775) X_46 = -CEVA CONJUGATE OF X(1) (0.6917, 0.4543) X_244 = -LINE CONJUGATE OF X(100) (0.7857, 0.1166) X_40 = BEVAN POINT (0.4286, -0.0292) X_614 = INTERSECTION OF LINES X(1)X(2) AND X(11)X(33) (0.6310, 0.2916) X_10 = SPIEKER CENTER (0.5204, 0.1833) X_748 = INTERSECTION OF LINES X(2)X(31) AND X(9)X(38) (0.4360, 0.0802) X_902 = CROSSPOINT OF X(6) AND X(106) (1.2500, 1.2247) X_3915 = com[TANGENTIAL TRIANGLE))] (0.7045, 0.4082) A B C X3 X109 X765 X1 X21 X8 X238 X46 X244 X40 X614 X10 X748 X902 X3915 (a, b, c) = (5, 6, 7) | AB = 1

X3915 (X3710com(TANGENTIAL TRIANGLE)) constructed on acute reference triangle \((a, b, c) = (5, 6, 7)\) with unit baseline AB = \(1\).

"""GEOMETOR construction model for X_3915 = X_3710com(TANGENTIAL 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,
            crosspoint,
            eval_trilinear_point,
            incenter_of,
            nagel_point_of,
            promote_point_to_top,
        )
        from geometor.etc.render import write_center_svg


        def construct_x_03915(
            model: Model, A: spg.Point, B: spg.Point, C: spg.Point
        ) -> spg.Point:
            """Construct X_3915 = X_3710com(TANGENTIAL TRIANGLE) on reference triangle ABC."""
            X_109 = eval_trilinear_point(model, A, B, C, 'a/(cos(B) - cos(C))', ID="X_109", classes=["center"])
            X_765 = eval_trilinear_point(model, A, B, C, '(b - c) **(-2)', ID="X_765", classes=["center"])
            X_3915 = crosspoint(model, A, B, C, X_109, X_765, ID="X_3915", classes=["selected", "target"])
            X_1 = incenter_of(model, A, B, C, ID="X_1", classes=["center", "incident"])
            X_21 = eval_trilinear_point(model, A, B, C, '1/(cos(B) + cos(C))', ID="X_21", classes=["center", "incident"])
            central_line(model, X_1, X_21, 1, 21, incident=True)
            X_8 = nagel_point_of(model, A, B, C, ID="X_8", classes=["center", "incident"])
            X_238 = eval_trilinear_point(model, A, B, C, 'a**(2) - b*c', ID="X_238", classes=["center", "incident"])
            central_line(model, X_8, X_238, 8, 238, incident=True)
            X_46 = eval_trilinear_point(model, A, B, C, 'cos(B) + cos(C) - cos(A)', ID="X_46", classes=["center", "incident"])
            X_244 = eval_trilinear_point(model, A, B, C, '(b - c)**(2)', ID="X_244", classes=["center", "incident"])
            central_line(model, X_46, X_244, 46, 244, incident=True)
            return promote_point_to_top(model, X_3915)


        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_3915 on the given reference triangle."""
            model = create_model('X_3915 = X_3710com(TANGENTIAL TRIANGLE)')
            A, B, C = construct_baseline_triangle(model, *sides, show_guides=show_guides)
            construct_x_03915(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-03915.json"))
            write_center_svg(
                model_acute,
                here / "x-03915.svg",
                subtitle="(a, b, c) = (5, 6, 7) | AB = 1",
            )