Energy and power in circuits