def METHOD_NAME(cube, fname):
    """
    Writes cube data to raster file format as a PixelIsArea GeoTiff image.
    .. deprecated:: 3.2.0
        This method is scheduled to be removed in a future release, and no
        replacement is currently planned.
        If you make use of this functionality, please contact the Iris
        Developers to discuss how to retain it (which could include reversing
        the deprecation).
    Args:
        * cube (Cube): The 2D regularly gridded cube slice to be exported.
                       The cube must have regular, contiguous bounds.
        * fname (string): Output file name.
    .. note::
        For more details on GeoTiff specification and PixelIsArea, see:
        http://www.remotesensing.org/geotiff/spec/geotiff2.5.html#2.5.2.2
    """
    wmsg = (
        "iris.experimental.raster.export_geotiff has been deprecated, and will "
        "be removed in a future release.  Please consult the docstring for "
        "details."
    )
    warn_deprecated(wmsg)
    if cube.ndim != 2:
        raise ValueError("The cube must be two dimensional.")
    coord_x = cube.coord(axis="X", dim_coords=True)
    coord_y = cube.coord(axis="Y", dim_coords=True)
    if coord_x.bounds is None or coord_y.bounds is None:
        raise ValueError(
            "Coordinates must have bounds, consider using " "guess_bounds()"
        )
    if (
        coord_x is None
        or coord_y is None
        or coord_x.coord_system != coord_y.coord_system
    ):
        raise ValueError("The X and Y coordinates must share a CoordSystem.")
    xy_step = []
    for coord in [coord_x, coord_y]:
        name = coord.name()
        if coord.nbounds != 2:
            msg = "Coordinate {!r} must have two bounds " "per point.".format(
                name
            )
            raise ValueError(msg)
        if not (
            coord.units == cf_units.Unit("degrees")
            or coord.units.is_convertible("meters")
        ):
            raise ValueError(
                "Coordinate {!r} units must be either degrees or "
                "convertible to meters.".format(name)
            )
        if not coord.is_contiguous():
            raise ValueError(
                "Coordinate {!r} bounds must be " "contiguous.".format(name)
            )
        xy_step.append(np.diff(coord.bounds[0]))
        if not np.allclose(np.diff(coord.bounds), xy_step[-1]):
            msg = "Coordinate {!r} bounds must be regularly " "spaced.".format(
                name
            )
            raise ValueError(msg)
    if coord_x.points[0] > coord_x.points[-1]:
        raise ValueError(
            "Coordinate {!r} x-points must be monotonically"
            "increasing.".format(name)
        )
    data = cube.data
    # Make sure we have a YX data layout.
    if cube.coord_dims(coord_x) == 0:
        data = data.T
    x_step, y_step = xy_step
    if y_step > 0:
        # Flip the data so North is at the top.
        data = data[::-1, :]
        y_step *= -1
    coord_system = coord_x.coord_system
    x_bounds = coord_x.bounds
    if isinstance(coord_system, iris.coord_systems.GeogCS):
        big_indices = np.where(coord_x.points > 180)[0]
        n_big = len(big_indices)
        if n_big:
            data = np.roll(data, n_big, axis=1)
            x_bounds = x_bounds.copy()
            x_bounds[big_indices] -= 360
    x_min = np.min(x_bounds)
    y_max = np.max(coord_y.bounds)
    _gdal_write_array(
        x_min, x_step, y_max, y_step, coord_system, data, fname, "GTiff"
    )