def METHOD_NAME(dls, shape, pmc):
    """Backward derivative in x."""
    Nx, Ny = shape
    if Nx == 1:
        return sp.csr_matrix((Ny, Ny))
    dxb = sp.csr_matrix(sp.diags([1, -1], [0, -1], shape=(Nx, Nx)))
    if pmc:
        dxb[0, 0] = 2.0
    else:
        dxb[0, 0] = 0.0
    dxb = sp.diags(1 / dls).dot(dxb)
    dxb = sp.kron(dxb, sp.eye(Ny))
    return dxb