Principles of energy conversion