Ternary ionic compounds