When it’s too hot, vasodilation occurs, in which the capillaries near the surface of the skin increase in diameter, allowing more blood to flow through them, releasing heat. Hairs on the skin lie flat. The sweat glands become active, which allows heat to be lost by evaporation. Some mammals will also begin to pant. When it’s too cold vasoconstriction will take place, limiting blood supply near the skin surface. The erector muscles in the skin will contract, causing hairs to stand up straight, trapping air. The sweat glands are inactive. Shivering (rapid contraction and relaxation of the muscles) to generate heat may also occur.