def intersection(p1,p2,pause=[0,0]):
    """
    Given two converging forks and their firing time and speeds,
    compute the position of the intersection
    as well as the position of the time of intersection.
    If the intersection is outside [x1,x2], the initial position of the forks,
    then return False
    """
    x1,t1,R_fork_speed=p1.pos,p1.firing_time,p1.R_fork_speed
    x2,t2,L_fork_speed=p2.pos,p2.firing_time,p2.L_fork_speed
    t1 += pause[0]
    t2 += pause[1]

    assert(x2>x1)

    #x = (x1+x2)/2 + (t2-t1)*v/2
    x = 1/(1/L_fork_speed+1/R_fork_speed)*(t2-t1 + x1/L_fork_speed+x2/R_fork_speed)
    if  not( x1<x<x2):
        return False,[None,None]

    t = (x2-x1)/(R_fork_speed+L_fork_speed) + (t1 * R_fork_speed + t2 * L_fork_speed)/(R_fork_speed+L_fork_speed)

    return True,[x,t]