A rigorous solution to a heat transfer two phase model in porous media and packed beds