Modfied analysis to use message cost instead of energy cost