Size and charge effects on the structural stability of LiMO2 (M = transition metal) compounds