What are convection cells?

I am not able to understand what really are convection cells. Here is a photo from hyperphysics,

What are these wall like structures? They write

Convection cells are visible in the heated cooking oil in the pot at left. Heating the oil produces changes in the index of refraction of the oil, making the cell boundaries visible. Circulation patterns form, and presumably the wall-like structures visible are the boundaries between the circulation patterns.

What do they mean ? with that wall like structures? If possible please also try to explain to me from this picture of the sun below-

This is the surface of the sun. What is the relation of the wall like thing on the sun VS the wall like thing in water. After all , their phases, pressures, temperatures are very very different!

The lines in the heated cooking oil are Rayleigh–Bénard cells, while the structures on the surface of the Sun are the boundaries of solar granules. They both, however, arise from the same phenomenon: convection.

Picture a flat plane of liquid in a gravitational field. There is a heat source underneath - in the case of the oil, this is the stove; in the case of the Sun, this is the result of hydrogen fusion further down. This creates a temperature difference between the top of the plane and the bottom.

In general, hotter pockets of fluid expand against colder pockets of fluid. Think about the ideal gas law: $$PV=nRT$$ where $P$ is pressure, $V$ is volume, $n$ is the number of moles of the substance, $R$ is a constant, and $T$ is temperature. Alternatively, think of it in terms of density, $\rho$: $$P\sim\rho T\to\frac{P}{\rho}\sim T$$ As the temperature rises, so must $P/\rho$; therefore, the fluid expands. It becomes less dense. This means that the pocket will rise up above the colder fluid. Think about an oil spill in the ocean. In general, oil is denser than seawater (there are exceptions in freshwater); thus it floats to the top. The same is true in the case of cooking oil and the Sun. Buoyancy acts to counter the force of gravity.

In the case of the Rayleigh–Bénard cells, the ideal gas law isn't our best choice for an equation of state. We can approximate the temperature-density relationship by writing $$\rho-\rho_0\approx-\rho_0\alpha(T-T_0)$$ where $_0$ denotes the reference temperature and pressure and $\alpha$ is a chosen constant. This is sometimes called the Boussinesq approximation.

Once the heated material reaches the top of the fluid, it cools, and eventually moves back to the bottom to make room for newly heated fluid. The lines in the cooking oil are the boundaries of the Rayleigh–Bénard cells, where cool oil begins to sink downward while hot oil rises to the top through the center of the cells. The same thing is at work in the solar granules; the dark patches represent the cooler spots where (relatively!) cooler gas moves downward.

• Thank you for such a beautiful answer! But, there were somethings that i was not able to understand, it would be very polite of you if you could explain them a bit. 1- What do you mean by hotter and cold “pockets”. 2- The link that you’ve provided says that “But very heavy oils, which have a density of 1.01 g/cc, would float in the ocean, but sink in a river.” What’s the reason behind this? – Aaryan Dewan Sep 3 '16 at 1:31
• @AaryanDewan By "pocket", I meant a small bit of fluid that has had its temperature increased. The reason for the oil discrepancy is that salt water is denser than fresh water, because of the salt. – HDE 226868 Sep 3 '16 at 1:33
• +1 I meant to ask a similar question, but looking up wiki sorted most of it. Offhand, do you know how deep these cells go down in the sun, no worries about answering, I will keep looking , I have a feeling it might be difficult to judge, just curious. Thanks – user108787 Sep 3 '16 at 2:46
• Actually, it might be in your answer, sorry, I can read that first . – user108787 Sep 3 '16 at 2:49