Generalized equations for the transport coefficients of electrons and phonons