The concept of resonant cavity