moved energy summarization functions to seperate file