I have a nonhomogeneous heat conduction problem, where the thermal conductivity, the density, and the specific heat of the
material are piecewise functions.
The thermal conductivity derivative has a discontinuity that causes a problem in the pdsolve command (see the first test).
To avoid this problem, I did a second test where the product rule was calculated directly.
Is there a better way to deal with this problem?