I have seen various treatments of the chemical potential. Basically it all amounted to a definition of it as a quantity maximizing the entropy for systems allowed to exchange particles. Now this quantity has become quite important in some models I am studying for current flow, specifically an equation I am looking at right now, which relates the current flowing between a source and a drain to the chemical potentials of the leads as well as the temperature. Now, a question in the book is what happens when the leads have different temperatures - so basically what happens to the expression for the current when I vary the temperature but not the chemical potential. But my question is, are temperature and chemical potential independent of each other? Applying a voltage keeps the leads at different chemical potentials because I raise the energy of the electrons in the source wrt the drain lead. But if I raise the temperature in one lead, does this not raise the energy of the electrons in the lead wrt the electrons in the other lead? I guess this all amounts to me not being completely confident with the distinction between energy and temperature. Temperature is a stastical quantity which maximizes energy given a known mean energy of the system. But still I can't see how you can raise the temperature and not the energy - and how exactly does it all relate to the chemical potential?