$d_{\perp}$

$d$

A = (6, 5)
α = 4.1887902047863905 rad (slider from 0 to 6.283185307179586)
v: (1; α)
f = Line(A, v)
B = (-4, -2)
C = Intersect(f, Line[B, Vector[UnitOrthogonalVector[f]]])
dperp = Segment(C, B)
β = Angle(f, Line[C, dperp])
D = Intersect(f, xAxis)
i: (1, 0)
α_2 = Angle(A, D, (-100, 0))
α_1 = Angle(A, D, (100, 0))
d = Segment(A, B)
γ_1 = Angle(C, B, (x(B), 100))
j: (0, 1)
points: {A, B, C, D}
show: false
ref = Segment(B - (2 * j), B + (2 * j))
γ_2 = Angle(C, B, (x(B), -100))

Tool: slopeAngle
Tool[ <Point>, <Point>, <Point> ]
Input: B, A, C
Output: θ, showSlope, rise, run, Rise, Run

1

3

ab = Vector(A, B)
Slope_1: A + (0.4 * ab)
Slope_2: Slope_1 + ((0.6 * AxisStepX[]) * UnitVector[ab])
rise = Segment(Slope_2, (x(Slope_2), y(Slope_1)))
α = Angle(ab, Vector[(1, 0)])
slope = Element(RemoveUndefined[Sequence[If[IsInteger[(i * tan(α))], ((i * tan(α)), i)], i, 1, 20]], 1)
D = Mirror(C, A)
p = If(Angle[C, A, B] > 270°, {B, A, C}, If[Angle[C, A, B] > 180°, {D, A, B}, If[Angle[C, A, B] > 90°, {B, A, D}, {C, A, B}]])
showSlope: Defined[slope] ∧ rise ≠ 0
run = Segment(Slope_1, (x(Slope_2), y(Slope_1)))
Rise = Text("" + (abs(x(slope))) + "", Midpoint[rise] + ((AxisStepX[] / 4 * sgn(x(B))) * Vector[(1, 0)]))
θ = Angle(p(1), p(2), p(3))
Run = Text("" + (abs(y(slope))) + "", Midpoint[run] - ((AxisStepX[] / 3 * sgn(y(B))) * Vector[(0, 1)]))