Toward an efficient and sustainable use of energy in industries and cities