(a) There shall be subtracted six hundred dollars as the city exemption of the estate or trust, and there shall be added the amount of its federal deduction for a personal exemption.
(b) There shall be subtracted the modification described in paragraph nine of subsection (c) of section twelve with respect to gains from the sale or other disposition of property, to the extent such gains are excluded from federal distributable net income of the estate or trust.
(c) There shall be added or subtracted (as the case may be) the share of the estate or trust in the city fiduciary adjustment determined under section nineteen.
(d) There shall be added or subtracted (as the case may be) the modifications described in paragraph six of subsection (b) and in paragraph eight of subsection (c) of section twelve.