outside the United States. Any such amount shall not be included in foreign-related deductions for purposes of applying subsection (a) to such taxable year. (2) Portion of previously deferred deductions For purposes of paragraph (1), the portion of the previously deferred deductions allocated to repatriated foreign income is— (A) the amount which bears the same proportion to such deductions, as (B) the repatriated income bears to the previously deferred foreign income. (c) Definitions and special rule For purposes of this section— (1) Foreign-related deductions The term foreign-related deductions means the total amount of deductions and expenses which would be allocated or apportioned to gross income from sources without the United States for the taxable year if both the currently-taxed foreign income and deferred foreign income were taken into account. (2) Currently-taxed foreign income The term currently-taxed foreign income means the amount of gross income from sources without the United States for the taxable year (determined without regard to repatriated foreign income for such year). (3) Deferred foreign income The term deferred foreign income means the excess of— (A) the amount that would be includible in gross income under subpart F of this part for the taxable year if— (i) all controlled foreign corporations were treated as one controlled foreign corporation, and (ii) all earnings and profits of all controlled foreign corporations were subpart F income (as defined in section 952), over (B) the sum of— (i) all dividends received during the taxable year from controlled foreign corporations, plus (ii) amounts includible in gross income under section 951(a). (4) Previously deferred foreign income The term previously deferred foreign income means the aggregate amount of deferred foreign income for all prior taxable years to which this part applies, determined as of the beginning of the taxable year, reduced by the repatriated foreign income for all such prior taxable years. (5) Repatriated foreign income The