import math


def rotate(position, center, radians):
    """Returns a Position rotated r radians around centre c from p
    Parameters
    ----------
    position : Position
        The position to rotate.
    center : Position
        The point to rotate about.
    radians : float
        The number of radians to rotate ``position`` by.
    """
    p_x, p_y = position
    c_x, c_y = center

    x_dist = p_x - c_x
    y_dist = p_y - c_y

    return [(x_dist * math.cos(radians) - y_dist * math.sin(radians)) + c_x,
            (x_dist * math.sin(radians) + y_dist * math.cos(radians)) + c_y]