I see in many textbooks that all authors start field quantization with EM field confined in a cube of finite size, certainly some B.C. is imposed, usually periodic B.C., finally the cube goes to whole space. I have some questions on this procedure: 1, Is periodic(or other) B.C. reasonable? Doesn't the B.C. have any influence on final results? 2, Is this cube necessary? Why not just do the decomposition in the whole space(continuous decompostition spectrum encounterd?)? I heared that this method of quantizing EM field was originally proposed by Dirac in his Lectures on Quantum Field Theory. Would anyone be kind enough to share it? Thank you all for attention!