Search

 
Problem Description
This is a mathematical exploration of the
reflecting properties of parabolas.
Background & Techniques
I read a note about "whispering galleries" the other day. which prompted
me write this program to investigate the mathematics and illustrate the
results. Real world reflecting objects such as whispering chambers,
parabolic microphones, flashlight reflectors, satellite dishes,
etc. are paraboloids; 3 dimensional versions of parabolas formed
conceptually by rotating a parabola about its axis of symmetry.
They all take advantage of the fact that rays of energy entering parallel to
the axis will all be reflected to a common focal point or, conversely, light
or other energy generators placed at the focal point will emit parallel
rays.
We will be considering a parabola as a 2 dimensional crosssectional view
of a paraboloid. The tasks are

Find the equation of a parabola opening to
the left with its vertex at V and a focal length (FV) at point F.


Find the intersection point (B) of an arbitrary parallel ray
(AB) striking
the parabola.


Define the line tangent to the parabola at the intersection point
(CBD)


,By definition, the angle of incidence (ÐABE)
of a ray striking a surface is the angle between the ray and a line
"normal" to the
surface. IWe'll need to draw the "normal" line segment (BE) perpendicular to the tangent line.


Finally, we'll draw the reflected ray from
point B until it intersects the FV axis of symmetry, hopefully at point
F. The
angle of reflection (ÐEBF) of the line from B
must be equal to the angle of incidence but on the other side of the
normal line. . 
Equation of the parabola
A parabola is defined by a quadratic equation commonly expressed a
y=ax^{2} + b x +c which opens upwards and crosses the y axis at
c. Point (0,c) is the vertex. The focal point for
such a parabola is at (0, 1/(4a)). I wanted my
parabola to have a horizontal axis opening to the left which made the
mathematics somewhat harder. Now X depends on the
independent variable Y. I started with an equation from the
Wikipedia article for a parabola opening to the right with vertex at (h,k)
and focal length of f as (yk)^{2} = 4f(xh).
To make it open to the left, we'll invert the x scale by putting a minus sign in
front of the x term making our starting equation (yk)^{2}
=  4f(xh). Converting to ABC form, we get x =
(1/4f)Y^{2} + (k/2f)Y  k^{2}/4f + h so
a=1/4f, b=k/2f, and c=hk^{2}/4f. I
set the x coordinate of the vertex, h, to be a few pixels from the right
edge of the image area and the vertex y coordinate, k, to be the vertical
midpoint of the image area. The focal length, f, default
to 100 pixels, but may be changed by the user.
Intersection Point
Click in front of the parabola to create ray at height Y_{1.
}We'll start drawing at the left edge of the drawing area and stop at
the point where it intersects the parabola. By definition then , x_{1}=
ay_{1}^{2 }+ b y_{1} +c. We'll draw that line.
Multiple rays may be created.
Tangent Line
Using y as the independent variable, our parabola defined by
x = ay^{2} + by + c and the slope of the tangent line is the
derivative m = dx/dy = 2ay + b. If we define our tangent line by x
= my + d, we need to find the value for intercept d. Since
line must pass through (x_{1},y_{1}), x_{1}
= my_{1}+ d allowing us to evaluate d as d = x_{1}
my_{1}.
Now we have almost enough information to plot the tangent line once we decide how long to make
it. I decided on 80 pixels in each direction from the ray intercept point.
So we need to find the point on
the line x = my + d that is 80 units from (x_{1},y_{1}).
We want to find the deltas, D_{x} and
Dy that satisfy the distance equation
Dx^{2}+Dy^{2}=80^{2}. Since our slope m = dx/dy anywhere on the tangent line,
Dx = mDy and we
can substitute for Dx in the distance
equation and get (Dym)^{2} +Dy^{2}=6400.
This
implies Dy^{2}*(1+m^{2})
= 6400 and therefore Dy = sqrt(6400
/(1+m^{2})). Substituting back unto the line
equation will give us
Dx. We can add and subtract the
D values to/from (x_{1},y_{1})
to find the endpoints of the tangent line to be drawn.
Normal Line
Given that the slope of the tangent line is m, the slope of a
perpendicular line will be m_{2}=1/m. We can find intercept
d in line equation x = m_{2}y + d by
evaluating the end at ray intercept point (x_{1},y_{1}),
where d = x_{1}m_{2}*y_{1. }Now we
want to extend the normal line toward axis for 40 pixels. To do
this we'll use the same technique describe above for the tangent line length
to find the point
on the line that is 40 units from (x_{1},y_{1}).
to derive that Dy = sqrt(1600/(1+m_{2}^{2})
and Dx = m_{2}Dy.
Reflection Line
Since we are using y as the independent variable, the slope
(dx/dy) of the tangent line is relative to vertical and that is the
best basis to calculate the rest of the angles. In this diagram, we
illustrate the angles increasing counterclockwise from the y
axis to find the required angle of reflection.
 To BC is the known angle of the tangent. line because we have
already calculated the slope, m, which is the tangent of the angle.
Lets call it theta, q = arctan(m) 
 To BA , the incoming ray, the angle is 90 degrees, 
 To BE, the normal line, the angle is q
+ 90 
 The angle of incidence is the difference between the normal
and the ray angles which is (q + 90) 90 =
q. 
 Finally, our angle to the reflected ray, BF, is the normal
angle + the angle of incidence = (q + 90)
+ q = 90 +2q.

So we'll set m_{3}, the slope of reflected ray as m_{3}
= arctan(90+2q).
We're almost home now. As with our previous lines, we'll use the line
equation x = m_{3}Y + d_{3} and find d_{3}
by evaluating at the known (x_{1},y_{1}) intersection point.
d_{3 }= x_{1 } m_{3}y_{1.
}We'll extend the line to the point where it crosses the parabola axis
at y=k. making x_{3} = m_{3}*K + d_{3.
} If we are lucky and implemented the math correctly, the end point of the
reflected ray will land exactly on the focal point,. Sure enough, that
appears to be the case.
The above step by step derivation seems quite logical now. If I
said that was way to problem was solved, I'd be lying. Recognizing
that making Y the independent variable had logically rotated all of the
slopes and angles by 90 degrees took several days. Much time was spent
trying to replace tangent functions with cotangents. Only after the
rays were converging on the focal point did I backtrack to understand
why. In the meantime, thanks to trig identities, here are a few
additional "trial and error" ways to calculate the slope which all
produce the correct result.
m_{3} = cot(2arctan(m)); m_{3} = tan(pi/2  2arctan(m)); m_{3}
= tan(2arctan(m)  pi/2); m_{3} = cot(2*arctan(m)); m_{3} = tan(pi/2 + 2*arctan(m)); m_{3} = tan( 2arctan(1/m)  pi/2);
Notes for programmers
The code is a quite straightforward implementation of the above
description and quite well commented. The images are drawn using the
OnPaint exit of a TPaintbox control
Clicks on the image to generate rays are saved as an array of points
where the rays intersect the parabola. The OnPaint exit clears the
image and redraw the parabola and all of the currently defined rays using
the current draw options.
Running/Exploring the Program
Suggestions for Further Explorations
The program currently is not very informative about the math being
applied. Features could be easily added to display the parameters
(intercepts, distances, and angles), and the calculations which
produced them for any selected ray.
Original Date: April 30, 2009 
Modified:
July 29, 2017 

