Ternary compounds of rare earths with gold and gallium