This theorem is based on one basic concept. According to Ohm’s law , when electric current flows through any resistor, there would be a voltage drop across the resistor . This dropped voltage opposes the source voltage. Hence voltage drop across a resistance in any network can be assumed as a voltage source acting opposite to the source voltage. The compensation theorem depends upon this concept.
According to this theorem, any resistance in a network may be replaced by a voltage source that has zero internal resistance and a voltage equal to the voltage drop across the replace resistance due to the electric current which was flowing through it. This imaginary voltage source is directed opposite to the voltage source of that replaced resistance. Think about a resistive branch of any complex network that's resistance value is R. Let's assume electric current I is flowing through that resistor R and voltage drops due to this electric current across the resistor is V = I.R. According to compensation theorem, this resistor can be replaced by a voltage source that's generated voltage will be V ( = IR) and will be directed against the direction of network voltage or direction of electric current I.
The compensation theorem can easily be understood by this following example.
Here in the network for 16 V source, all the currents flowing through the different resistive branches are shown in the first figure. The electric current through the right most branch in the figure is 2A and its resistance is 2 Ω. If this right most branch of the network is replaced by a voltage source V = 2ΩX2A = 4V directed as shown in the second figure, then electric current through the other branches of the network will remain the same as shown in the second figure.