I'm messing around with voronoi diagrams and I'm trying to implement fortune's algorithm. I have started by taking this
https://www.cs.hmc.edu/~mbrubeck/voronoi.html code and adapting it to work with my rendering system and it seems to produce correct results, but it seems to me that the intersection function is incorrect. I have worked several equations out algebraically trying to understand the code but I get a different a, b, and c than his code. For example, using a focus of (2, 2) and directrix of (x = 3) I end up with x = -0.5y^2 + 2.5y - 1.25 but the equation that function comes up with is -0.5y^2 + 2y + 0.5 I'm not super confident in my math abilities but I really want to understand the algorithm and I just can't see how that function makes sense. Can anyone better than me at math tell me if that function really is wrong or if it's me thats wrong?