How would you create a function that would bounce off of 2 sides of a pool table. like this
imagine the coordinate axis on this pool table. we can make the lower-left pocket the origin. thus, to create the desired function you must create a piece-wise function consisting of three line segments.
for the first, you want a line segment connecting the origin to the point (8,2)
for the second, you want a line segment connecting the point (8,2) to the point (1,4)
for the third, you want a line segment connecting the point (1,4) to the point (0.5, 3.5)
can you continue?
(of course, if you wish, you could make the lower-center pocket the origin, whatever)