Red giant will begin to expand into a subgiant. Eventually, the pressure builds up so much that the core will begin to fuse helium, and will expand even more into a red giant. At its largest, its surface (photosphere) will approximately reach the current orbit of Earth. It will then lose its atmosphere completely; its outer layers forming a planetary nebula and the core a white dwarf. The evolution of the Sun into and through the red-giant phase has been extensively modelled, but it remains unclear whether Earth will be engulfed by the Sun or will continue in orbit. The uncertainty arises
Giant star convection in the outer layers, triggers a second dredge-up, and causes a dramatic increase in size and luminosity. This is the asymptotic giant branch (AGB) analogous to the red-giant branch but more luminous, with a hydrogen-burning shell contributing most of the energy. Stars only remain on the AGB for around a million years, becoming increasingly unstable until they exhaust their fuel, go through a planetary nebula phase, and then become a carbon–oxygen white dwarf. Main-sequence stars with masses above about are already very luminous and they move horizontally across the HR diagram when they leave the main sequence, briefly becoming