  Phase diagrams of isoelectronic Eu$_{1-x}$Gd$_x$O and Eu$_{1-x}$Gd$_{x}$S
quasi-binary alloy systems are constructed using first-principles calculations
combined with the standard cluster expansion approach and Monte-Carlo
simulations. The oxide system has a wide miscibility gap on the Gd-rich side
but forms ordered compounds on the Eu-rich side, exhibiting a deep asymmetric
convex hull in the formation enthalpy diagram. The sulfide system has no stable
compounds. The large difference in the formation enthalpies of the oxide and
sulfide compounds is due to the contribution of local lattice relaxation, which
is sensitive to the anion size. The solubility of Gd in both EuO and EuS is in
the range of 10-20% at room temperature and quickly increases at higher
temperatures, indicating that highly doped disordered solid solutions can be
produced without the precipitation of secondary phases. We also predict that
rocksalt GdO can be stabilized under appropriate experimental conditions.
