input: Write a python function to optimize a quadratic equation and find its roots.
  assert optimize_equation(1, -3, 2, 0) == (1.0, 2.0)
  assert optimize_equation(1, -2, 1, 0) == (1.0, 1.0)
  assert optimize_equation(1, 0, -4, 0) == (2.0, -2.0)
output: def optimize_equation(a, b, c, d):
      import math
      
      # Quadratic formula: ax^2 + bx + c = 0
      discriminant = b**2 - 4*a*c
      
      if discriminant >= 0:
          root1 = (-b + math.sqrt(discriminant)) / (2*a)
          root2 = (-b - math.sqrt(discriminant)) / (2*a)
          return (root1, root2)
      else:
          return None