def rk4_step(force, state, time, dt):
    """Compute one step of the rk4 approximation.

    Parameters
    ----------
    force : callable
        Vector field that is being integrated.
    state : array-like, shape=[2, dim]
        State at time t, corresponds to position and velocity variables at
        time t.
    time : float
        Time variable.
    dt : float
        Time-step in the integration.

    Returns
    -------
    point_new : array-like, shape=[,,,, {dim, [n, n]}]
        First variable at time t + dt.
    vector_new : array-like, shape=[,,,, {dim, [n, n]}]
        Second variable at time t + dt.

    See Also
    --------
    https://en.wikipedia.org/wiki/Runge–Kutta_methods
    """
    k1 = force(state, time)
    k2 = force(state + dt / 2 * k1, time + dt / 2)
    k3 = force(state + dt / 2 * k2, time + dt / 2)
    k4 = force(state + dt * k3, time + dt)
    new_state = state + dt / 6 * (k1 + 2 * k2 + 2 * k3 + k4)
    return new_state