X3783

X668com[T(bc, c²)]

< 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) { 1, 2 }: Nagel Line { 87, 193 }: Central Line L(87, 193) { 72, 695 }: Central Line L(72, 695) { 291, 518 }: Central Line L(291, 518) { 350, 740 }: Central Line L(350, 740) { 668, 730 }: Central Line L(668, 730) A = Vertex A (0.0000, 0.0000) B = Vertex B (1.0000, 0.0000) C = Vertex C (0.6122, 0.5999) X_1 = INCENTER (0.5714, 0.2333) X_2 = CENTROID (0.5374, 0.2000) X_87 = -CROSS CONJUGATE OF X(1) (0.4794, 0.1691) X_193 = -CEVA CONJUGATE OF X(2) (0.7878, 0.4690) X_72 = ISOGONAL CONJUGATE OF X(28) (0.4367, 0.0733) X_695 = ISOGONAL CONJUGATE OF X(384) (0.5903, 0.2249) X_291 = 2nd SHARYGIN POINT (1.0249, 0.0364) X_518 = ISOGONAL CONJUGATE OF X(105) (0.9154, 0.6489) X_350 = -HIRST INVERSE OF X(75) (-3.5227, -3.1370) X_740 = EVEN (- 1, 1) INFINITY POINT (0.9745, 0.5915) X_668 = TRILINEAR POLE OF LINE X(2)X(37) (0.0159, 0.3302) X_730 = EVEN (- 2, 1) INFINITY POINT (0.0843, -0.1730) X_3783 = com[T(bc, c2)] (4.1101, 3.7005) A B C X1 X2 X87 X193 X72 X695 X291 X518 X350 X740 X668 X730 X3783 (a, b, c) = (5, 6, 7) | AB = 1

X3783 (X668com[T(bc, c²)]) constructed on acute reference triangle \((a, b, c) = (5, 6, 7)\) with unit baseline AB = \(1\).

"""GEOMETOR construction model for X_3783 = X_668com[T(bc, c²)]."""

        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,
            centroid_of,
            construct_baseline_triangle,
            create_model,
            eval_barycentric_point,
            eval_trilinear_point,
            incenter_of,
            promote_point_to_top,
        )
        from geometor.etc.render import write_center_svg


        def construct_x_03783(
            model: Model, A: spg.Point, B: spg.Point, C: spg.Point
        ) -> spg.Point:
            """Construct X_3783 = X_668com[T(bc, c²)] on reference triangle ABC."""
            X_3783 = eval_barycentric_point(model, A, B, C, '(a*(a**(2) - b*c)*(b**(2) + c**(2) + b*c))', ID="X_3783", classes=["selected", "target"])
            X_1 = incenter_of(model, A, B, C, ID="X_1", classes=["center", "incident"])
            X_2 = centroid_of(model, A, B, C, ID="X_2", classes=["center", "incident"])
            central_line(model, X_1, X_2, 1, 2, incident=True)
            X_87 = eval_trilinear_point(model, A, B, C, '1/(a*b + a*c - b*c)', ID="X_87", classes=["center", "incident"])
            X_193 = eval_trilinear_point(model, A, B, C, '(csc(A))*(cot(B) + cot(C) - cot(A))', ID="X_193", classes=["center", "incident"])
            central_line(model, X_87, X_193, 87, 193, incident=True)
            X_72 = eval_trilinear_point(model, A, B, C, '(b + c)*cot(A)', ID="X_72", classes=["center", "incident"])
            X_695 = eval_trilinear_point(model, A, B, C, 'a/(a**(4) + b**(2)*c**(2))', ID="X_695", classes=["center", "incident"])
            central_line(model, X_72, X_695, 72, 695, incident=True)
            return promote_point_to_top(model, X_3783)


        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_3783 on the given reference triangle."""
            model = create_model('X_3783 = X_668com[T(bc, c²)]')
            A, B, C = construct_baseline_triangle(model, *sides, show_guides=show_guides)
            construct_x_03783(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-03783.json"))
            write_center_svg(
                model_acute,
                here / "x-03783.svg",
                subtitle="(a, b, c) = (5, 6, 7) | AB = 1",
            )