The following animation conveys more clearly than a set of static pictures ever could, what happens to form stars. It starts with an almost quiescent molecular cloud, which is rotated in front of us to give a better view of its chaotic, filamentary structure. Then we zoom in toward the center and watch the action around a mass concentration that is spinning under the pull of its own gravitational field and pulling sub-condensations of the cloud toward it. Most of them, however, are deflected and bounce back into the molecular cloud. It is through this complex process that a molecular cloud breaks itself up into the full range of stellar masses. These fragments then cool and collapse under their own gravity to form individual stars.Finally, we zoom back out to see the whole cloud and the retinue of stellar-mass fragments it has produced. (caution: 11 MB, do not download with slow connection) en00500_1.jpg (18578 bytes) (from Matthew Bate, Here you can repeat the details of the way stars form in the collapsing cloud core (caution: 13 MB)en00500_1.jpg (18578 bytes)

Stills from the movies show the stages of collapse and fragmentation:

bate1.gif (33637 bytes) bate2.gif (42406 bytes) bate3.gif (29165 bytes)
Clouds of interstellar gas are very turbulent with rapid internal motions. We begin with such a gas cloud, 1.2 light-years across, and containing 50 times the mass of the Sun. As the calculation proceeds, the turbulent motions in the cloud form shock waves that slowly damp the motions. When enough energy has been lost in some
regions of the simulation, gravity can pull the gas together to form a dense "core".
bate4.gif (26621 bytes) bate5.gif (21921 bytes) bate6.gif (20849 bytes)
The formation of stars and brown dwarfs begins in this dense core As the stars and brown dwarfs interact with each other, many are ejected from the cloud The cloud and star cluster at the end of simulation (which covers 266,000 years). Some stars and brown dwarfs have been ejected to large distances from the regions of dense gas in which the star formation occurs.
bate7.gif (25901 bytes) bate8.gif (27444 bytes) bate9.gif (26443 bytes)
Nine images showing the star formation in detail. They are 16 times smaller than the images above, measuring 5100 AU across (1 AU is the distance between the Earth and the Sun). Star formation begins with the formation of a binary. Gas filaments and discs form stars and brown dwarfs. Some of the remaining gas falls in around these protostars forming protoplanetary discs and building up the masses of the protostars. Stars and brown dwarfs fall together into a cluster. The objects range in mass from nearly the mass of the Sun down to as small as 6 times the mass of  Jupiter. A star with an edge-on disc is ejected,  center left.
bate10.gif (28863 bytes) bate11.gif (31811 bytes) bate12.gif (31354 bytes)
An unstable system of 5 stars breaks up and ejects stars from the cloud in three different directions (lower right; see animations). After a pause, star formation begins again with the gathering together of more gas (center). The discs of gas that form around the protostars also contain a lot of mass and gravity can also cause protostars to form within these discs. For example, around the first binary, 3 objects form,
and several form in the large disc in the image above (bottom).
The orbits of these objects are unstable and they are quickly ejected from the binary. Because they  are ejected from the dense gas just after they are formed they are unable to increase their masses by attracting the residual gas and they become brown dwarfs with masses of less than 75 times
that of Jupiter. Other objects are able to attract enough gas that they become proper stars.
bate13.gif (29779 bytes) bate14.gif (27757 bytes) bate15.gif (27816 bytes)
Complex gas flows and stellar encounters continue. Many of the stars and brown dwarfs are surrounded by discs which are truncated during encounters. Brown dwarf with a large disc is ejected, lower left. The stars and discs in the main star-forming
region at the end of the calculation.