1. Supernova Explosion: The shockwaves from a nearby supernova can compress the gas and dust within a nebula. This compression increases the density of the nebula, enhancing the gravitational pull. The increased density also raises the temperature, which in turn increases the internal pressure. However, the increased gravity from the denser gas often outweighs the increased pressure, causing the nebula to collapse further.
2. Collision of Nebulae: When two nebulae collide, the impact can cause a similar effect to a supernova explosion. The collision compresses the gas and dust, increasing the density and gravitational pull. The energy released from the collision also increases the temperature and pressure, potentially leading to the collapse of the nebulae.
Both these events can disrupt the delicate balance between gravity and pressure within a nebula, potentially triggering the formation of stars and planetary systems.