The real heart of a computer power supply is its transformer. These transformers are small, which is why computer cases can be so small. This was not always the way things were, however.
The first computer power supplies were huge by today’s standards. The technology of the time required that these devices used very large transformers to bring down wall voltage to the voltages required by the computers. The computers also used capacitors as part of the circuit that converted the voltage from AC to DC and these were bulky affairs at the time.
The new power supplies use a switching circuit that allows the device to actually take wall current and increase its frequency. This higher frequency current allows the builders to use much smaller transformers, compacting the entire device.
The secondary advantage of this is in preventing variations in the current that could destroy the components attached to the power supply. The higher frequencies are easier to regulate, eliminating some risk.
The switching technology and the better control over the voltages and current it provides make it possible for these devices to safely power very sensitive equipment. Of course, they also have very sophisticated cooling systems attached to them, and that helps to reduce the heat that they contribute to the case on the computer.
The power supply is not done yet. It still has to offer different voltages. There are many different voltages used on a computer and the power supply will have outputs for all of them.
The power supply also has to sit correctly in the case. This is a special consideration, of course, but a power supply that is improperly seated in the case may contribute to heat buildup. In some cases, other components, such as cooling towers on processors, may necessitate that smaller power supplies be used to accommodate the size of some cases.