The physics of a Cantenna is quite complicated and in practice most people use a simple applet to calculate the dimensions of the can needed. This will be covered in the How to Build section of this website. Here I will work a graduate level physics problem that is similar to our Cantenna problem. If you are not at least a graduate level physics student, there is a good video explaining the general idea on the Links page. If you can follow this, it is a simple matter to move to the Cantenna problem, which is an exercise I will leave to the reader ( you don't learn anything it I just do it for you).
This problem is problem 8.19 in John David Jackson's Classical Electrodynamics, Third edition, which is a really good resource for all things electromagnetic. Chapter 8 covers Waveguides, Resonant Cavities, and Optical Fibers. On with the Problem:
The figure below shows a cross-sectional view of an infinitely long rectangular waveguide with the center conductor of a coaxial line extending vertically a distance h into its interior at . The current along the probe oscillates sinusoidally in time with frequency , and its variation in space can be approximated as . The thickness of the probe can be neglected. The frequency is such that only the mode can propagate in the guide.