The Universe is popularly accepted as having begun with a bang about 15 billion years ago. Since it is unlikely that we will encounter a bang bigger than the one that begat the Universe, this initial bang is known as The Big Bang.
The Universe in a Nutshell
A super-dense blob of matter and energy exploded releasing super-hot matter and a lot of radiation. As this matter and energy cooled, celestial bodies were formed. Eventually, in an unremarkable galaxy, an unremarkable star was formed with a few insignificant planets orbiting around it. The star became what we now know as our Sun. This birth of the Sun happened at least 4.5 - 5 billion years ago - roughly the same time Earth was formed.
How Does the Sun Work?
One could answer 'by nuclear fusion' and be done with the workings of the Sun. But frankly, in the story of man's discovery of the Sun lies the story of man discovering himself.
In earlier days, many cultures in the ancient world worshipped the Sun as a god, as light, or as being good. Darkness has forever been regarded as evil, and for good reason - the Sun is the ultimate source of all energy on the earth. No life is possible without it.
These ideas arose in a time when the Sun was beyond our understanding. It is only in the last two or three centuries that any credible understanding of the Sun has emerged. Interestingly, the initial theories proposed on the workings of the Sun included one that thought it to be a mass of burning coal. This theory is not so surprising if you consider the time when the idea was proposed, a time when steam, powered by coal, was once the most powerful energy on Earth. At one time, no force was as useful to man as the newly-invented steam-boiler. In due course, this and similar theories were discredited as unfeasible, simply because conventional chemical processes could not account for the Sun's radiance.
The true understanding of the sun has its roots in the theory of relativity put forward by Einstein in the early years of the 20th Century. This was when the equivalence of mass and energy was proposed for the first time. It was the first step in understanding the sun's power and led to the conclusion that the sun works on nuclear fusion. It does this by converting hydrogen into helium, a process similar to the one applied in a hydrogen bomb.
How it All Started
The Sun was made - like any other star - out of enormous clouds of gases coming together. As the Sun agglomerated, the various particles that came together started to pull one another into a gravitational collapse. This crushing of particles under their own attraction led to collisions that increased the temperature of the Sun tremendously. The rising temperature started to cause fusion of the hydrogen atoms into helium atoms with the release of a lot of energy - this is a hot process. Really, really hot. This energy release and rise in temperature countered the gravitational crushing and the Sun became a delicate balance of two catastrophic and incredibly powerful forces. This is exactly where it stands today.
If there is anything that is inevitable in this Universe, it is the ultimate triumph of gravity over everything else. What gravity will do to the Sun is clear and the future for the Sun is not very bright (pun intended). Some day, roughly another 4 billion years from now, the Sun will have used up all its hydrogen to get helium. The helium will simply sit there, unable to fuse. The process will no longer be powerful enough to hold the balance with gravity. The core of the Sun will start to collapse, but its outer skin will expand into a red giant.
The Earth will be consumed into the expanding Sun. The outer shell of the Sun will then explode and move away. The core will collapse further into a super-dense star-remnant - a White Dwarf. This has no source of fuel, but glows intensely with the left-over heat from when it was the centre of a star. If the mass is high enough it will become a neutron star. No one seriously believes that the mass of the Sun is high enough for it to become a Black Hole, though.
The Sun's Magnetism
There is a lot to know about the Sun. Apart from its origins and its destiny, the Sun, in its present form, is also a big mystery for astronomers. Its magnetism, solar flares, Sun spots and solar winds are all hot topics for study. That's because they affect the Earth in ways that are still not completely understood or which are predictable.
The Sun is made up of high velocity plasma; that is, charged particles moving around. This movement leads to magnetism in the Sun, exactly like a wire twisted around an iron object magnetises upon the passage of electricity through it. Or let's just simply say that a moving charge is a magnetic personality. As a consequence, the Sun is criss-crossed by magnetic lines of force1. Sometimes these lines of force attract matter out of the Sun and push it high into space in spectacular flares. These flares are best observed during a complete eclipse against a dark centre of the Sun as they can be seen emerging brilliantly from the edge. These flares cause electromagnetic radiation on the Earth. Eight minutes2 after a big flare the Earth is hit by electromagnetic storms that disrupt radio communication, the power supply and the functioning of electronic equipment.
The Sun affects the Earth in other ways. Solar winds, which are streams of charged particles given out by the Sun, produce the auroras at the polar latitudes.
Another phenomenon to be observed on the Sun is sun spots. These are darker patches, associated with cooler areas on the Sun, though the spots have some relation to the Sun's magnetism. It has been observed that sunspots follow a 12 year cycle of activity wherein the activity waxes and wanes.
And as if the Sun isn't busy enough coping with all that, it also gives comets their tails...