(4)Notwithstanding anything contained in any other provisions of this Act, in the case of a demerger, the accumulated loss and the allowance for unabsorbed depreciation of the demerged company shall—(a)where such loss or unabsorbed depreciation is directly relatable to the undertakings transferred to the resulting company, be allowed to be carried forward and set off in the hands of the resulting company;(b)where such loss or unabsorbed depreciation is not directly relatable to the undertakings transferred to the resulting company, be apportioned between the demerged company and the resulting company in the same proportion in which the assets of the undertakings have been retained by the demerged company and transferred to the resulting company, and be allowed to be carried forward and set off in the hands of the demerged company or the resulting company, as the case may be.