Hubbard-Anderson-Kondo model with two electrons