# Equation for simultaneous cooling and conduction

Imagine a long, uniform metal rod placed on the positive $$x$$-axis being heated with a power $$P$$ from its end at $$x=0$$. It is cylindrical in shape and the cross-section is a circle of radius $$r$$. Looking at a thin slice of the rod $$dx$$ (these vertical slices are assumed to have uniform temperature) at distance $$x$$ from the origin, heat will flow through it according to Fourier's conduction law: $$q_x=-k\frac{d}{dx}T(x,t)$$. At the same time, heat will escape the rod from its surface according to Newton's law of cooling: $$P_N=-hA(T(x,t)-T_0)=-hA2\pi r\int(T(x,t)-T_0)dx$$.

I'm trying to write a differential equation that will give me $$T(x,t)$$ when both of these mechanisms are accounted for so I could answer things like what the equilibrium temperature will be for a certain material at various $$P$$ and $$x$$, but that is proving to be beyond my ability. Is this function even analytically obtainable? The only thing I could find anywhere was the math for a fully insulated rod and I was unable to implement Newton's law into that.

It seems like you want to treat this as a time-dependent problem. If you do a heat balance on the portion of the rod between x and $$x+\Delta x$$, you have that the rate of change on internal energy with respect to time is equal to the axial heat flow in minus the axial heat flow out minus the rate of heat loss through the surface:$$\rho\pi r^2\Delta x C\frac{\partial T}{\partial t}=\pi r^2q(x)-\pi r^2q(x+\Delta x)-2\pi r\Delta x h(T-T_0)$$where C is the heat capacity of the rod material. If we divide this equation by the volume of the segment of rod and take the limit as $$\Delta x$$ approaches zero, we obtain,$$\rho C\frac{\partial T}{\partial t}=-\frac{\partial q}{\partial x}-\frac{2h}{r}(T-T_0)$$with$$q=-k\frac{\partial T}{\partial x}$$ So, if we combine these last two equations, we obtain: $$\rho C\frac{\partial T}{\partial t}=k\frac{\partial^2 T}{\partial x^2}-\frac{2h}{r}(T-T_0)$$ I hope this is what you were looking for.