The core rubs against the surface of the earth. That is why we have thunder. It's like a little kid after exercise, blood circulation becomes faster, and he wants to get rid of his excessive energy by bothering other people. The core rubs the surface of the earth generating excessive energy for the earth. The earth therefore also wants to find something to pass its excessive energy to. It finds dense rain clouds, which are very conductive for earth's electric charge. Earth then passes its energy to rain clouds throwing thunder bolts at them. Thunder hits a rain cloud and comes back to earth. This hit and run process also resulted a certain amount of energy loss for the earth. The energy loss is what earth wanted since earth has too much excessive energy. When there are no rain clouds, there is no thunder because there is nothing that's conductive enough for such action.
If you don't agree with my theory, let me ask you a question to give you a
brain exercise. How come a planet is round? Who made it round? Is it because
that different layers of a planet rub against each other for billions of years, the planet
rounded itself out?
What about the sun? How come the sun is so hot? What kept it burning? Is
it because the sun has billions of layers which constantly rub against each other causing
the sun to burn like that? Give yourself some brain exercise.
If the layers of earth do not rub against each other, where did vocanos and thunder come from?
Hey think of it this way. We are nothing comparing to earth. We are dusts. Earth is a giant ball attracting dusts from all sides. Earth's static charge is enough to attract dusts like us.