def nbsdot(nv, nb0, nbs, C, e_effective, F, g, alpha, pv, r, eta):
    """
    Calculates the rate of change in minutes for the number of bacteria with spacers.
    
    Inputs:
    nv : total phage population size at time t
    nb0 : number of bacteria without spacers at time t
    nbs : number of bacteria with spacers at time t
    C : nutrient concentration at time t
    e_effective: average overlap between bac and phage populations
    F : chemostat flow rate
    g : bacterial growth rate
    alpha : phage adsorption rate
    pv : probability of phage infection success without CRISPR
    r : rate of spacer loss
    eta : probability of bacterial spacer acquisition
    """
    
    pva = pv*(1-e_effective)
    return (g*C - F - r)*nbs + alpha*(1-pv)*eta*nb0*nv - alpha*nv*pva*nbs