  We prove that among all doubly connected domains of $\R^n$ bounded by two
spheres of given radii, $Z(t)$, the trace of the heat kernel with Dirichlet
boundary conditions, achieves its minimum when the spheres are concentric
(i.e., for the spherical shell). The supremum is attained when the interior
sphere is in contact with the outer sphere.This is shown to be a special case
of a more general theorem characterizing the optimal placement of a spherical
obstacle inside a convex domain so as to maximize or minimize the trace of the
Dirichlet heat kernel. In this case the minimizing position of the center of
the obstacle belongs to the "heart" of the domain, while the maximizing
situation occurs either in the interior of the heart or at a point where the
obstacle is in contact with the outer boundary. Similar statements hold for the
optimal positions of the obstaclefor any spectral property that can be obtained
as a positivity-preserving or positivity-reversing transform of
$Z(t)$,including the spectral zeta function and, through it, the regularized
determinant.
