I know what a stall is but I don't understand why there are in some cases two local maximums on the $C_L$ vs AOA curve of some airfoils. What is the reason for the mini stall that occurs before the main stall?
The mini stall is the stall that we normally talk about when considering the flight of an aeroplane, and is therefore the main stall. Below the AoA where the first stall occurs, the wing profile is reasonably aligned with the airflow, and flow at the upper wing surface can remain attached. When upper surface flow detaches:
- upper surface suction force decreases, causing the "mini-stall";
- air resistance rises dramatically due to the stalled upper surface flow;
- lift is still generated by the lower surface deflecting the airflow downwards, like a flat plate does.
So beyond the normal range stall the wing still generates lift, and increasing AoA produces even more lift. The reason why aeroplanes cannot fly in the region beyond the first stall can be found from considering aerodynamic drag as function of AoA as well.
From this answer: $C_d$ of a NACA 0012 profile staling at 11º. The jump in drag is dramatic, and would usually be impossible to compensate for with engine power. Drag is the reason why we want to remain at low wing AoA.