Fixed volume, maximum area optimization. disclaimer: this question errs a bit on the practical side, I hope it is on topic on this se section.
Today I was cooking a savoury pie. You need to cook some spinach with bacon, then toss everything in eggs, add mozzarella, throw it in the oven and finally profit. The bottleneck of the procedure is waiting for the spinach to cool, because you do not want the egg to cook prematurely.
Say you have a known volume $V$ of a substance that is not solid nor liquid, so you can sort of shape it but not too much. You are constrained in a pan, which we can approximate with a short cylinder of radius $r$ and height $h$. The cylinder volume is approximately twice the substance volume.
Let us also assume that to cool the substance as fast as possible, it is necessary to maximize the ratio $\frac{S}{V}$, where $S$ is the surface of the substance. This is somewhat true, so I'll stick with this assumption.
Question: which is the best arrangement for the substance to cool it as fast as possible? An infinitely thin, infinitely wide plan is not an option, unfortunately. To clarify, any dimension of the final shape must be finite, i.e. given two points $x, y \in S$ it must hold $m < d(x,y) < M$ with $m, M \in R, m>0, M<+\infty$.
As noted in an answer, the condition as it was is not good because it won't allow for a continuous surface to exist. The idea is that every "thickness" must be finite, i.e. given any small enough sphere, it must be tangent to the solution in at most one point, and that the distance between any two points of the solution must be finite. 
Pic related:

(image credits to me)
 A: If I understand correctly what you meant, I will rewrite your "not infinitely thin" condition in the following way:
Every sphere entirely contained in solution volume and with $r < m$ must be tangent to solution surface only in one point, with $m \in R, m>0$.
With you formulation $x,y$ cannot be closer together enough to grant the continuity of $S$ and you will have a cloud of zero dimension dot instead of a surface.
Anyway I think you still need some stronger constraint, the empty spaces between surface point can still be infintely small.
At now, given the fact the solution can be a disjointed set of volumes, i bet on the trivial solution of a set of spheres with radius m, if $V \bmod (\frac{4}{3}  m^3 \pi) \not= 0 $ one sphere will be a capsule.
A: As noted in another answer, your condition $m>0$ actually prevents your set $S$ from having any volume at all. You might instead want to say that the set $S$ is a union of balls of radius $m,$ rather than requiring each pair of points to be that far apart, which would imply that the space all around each point is empty. 
With that condition, I think your maximum area is achieved by arranging $S$ into separate spheres of radius $m.$ In order to satisfy the maximum diameter condition involving $M,$ you might then need to  place the small spheres in some sort of three-dimensional packing within a larger sphere. 
This does not sound like a practical way to cool the ingredients in question, however. Possibly your best static arrangement is to form the spinach in ridges or "fins" of some sort. The arrangement in the picture (concentric circles) is one such kind of arrangement, but parallel lines might be easier to arrange into an efficient shape. 
