Star-tetrahedron transformation and calculation of bond energies at the crystal-mother phase boundary