Modeling of thermodynamic properties of binary and ternary mixtures. Determination of phase digrams