Computer Graphics, Mathematics, Linear Algebra.
to find an instance where p(t) = 0, we can use the equation: (p - c) * (p - c) - R² = 0 p → point being intersected c → sphere center R → sphere radius We can change this equation once again to: (e + td - c) * (e + td - c) - R² = 0 Rearrange the terms: (d * d)t² + 2d * (e - c)t + (e - c) * (e - c)