code: def parabola(xy, amplitude, x0, y0, sx, sy, theta):
      
  
      x = xy[0]
      y = xy[1]
  
      cth = np.cos(theta)
      sth = np.sin(theta)
      a = (cth ** 2) / (2 * sx ** 2) + (sth ** 2) / (2 * sy ** 2)
      b = -(np.sin(2 * theta)) / (4 * sx ** 2) + (np.sin(2 * theta)) / (
          4 * sy ** 2)
      c = (sth ** 2) / (2 * sx ** 2) + (cth ** 2) / (2 * sy ** 2)
      vals = amplitude - (a * ((x - x0) ** 2) +
                          2 * b * (x - x0) * (y - y0) +
                          c * ((y - y0) ** 2))
  
      return vals
docs: Evaluate a 2D parabola given by:
  
      f(x,y) = f_0 - (1/2) * \delta^T * R * \Sigma * R^T * \delta
  
      where
  
      \delta = [(x - x_0), (y - y_0)]
  
      and R is the matrix for a 2D rotation by angle \theta and \Sigma
      is the covariance matrix:
  
      \Sigma = [[1/\sigma_x^2, 0           ],
                [0           , 1/\sigma_y^2]] 
  
      Parameters
      ----------
      xy : tuple    
         Tuple containing x and y arrays for the values at which the
         parabola will be evaluated.
  
      amplitude : float
         Constant offset value.
  
      x0 : float
         Centroid in x coordinate.
  
      y0 : float
         Centroid in y coordinate.
  
      sx : float
         Standard deviation along first axis (x-axis when theta=0).
  
      sy : float
         Standard deviation along second axis (y-axis when theta=0).
  
      theta : float
         Rotation angle in radians.
  
      Returns
      -------
      vals : `~numpy.ndarray`    
         Values of the parabola evaluated at the points defined in the
         `xy` input tuple.