Protons present in nucleus of an atom should repel each other. Also the electrons present outside should attract the protons inside the nucleus.this should cause the atom to explode. then why it is that atoms are highly stable?
The explanation of why the electrons don't collapse in further toward the nucleus is more like this. In classical physics, a particle can have any kinetic energy regardless of what position it's at, but not in quantum mechanics. The kinetic energy is determined by the shape of the same 'wave-function' which also represents the probable positions of the particle. If the wave is scrunched in tightly, the kinetic energies it represents are big. So when a wave starts scrunching in close to the nucleus, its kinetic energy goes up more than its potential energy goes down.