Energetics of Ternary Nitrides: Li−Ca−Zn−N and Ca−Ta−N Systems