; (2) the aggregate amount of credits under such section that were allowed for taxable years ending in that the year by qualified residents of such State; and (3) 25 percent of the amount by which— (A) the amount determined under paragraph (1) with respect to qualified residents of the State for such year; exceeds (B) the amount determined under paragraph (2) for such State for that year. (b) Appropriation For the purpose of making grants to States under this section, there is hereby appropriated to the Secretary, out of any funds in the Treasury not otherwise appropriated, for each year (beginning with 2017) an amount equivalent to the amount determined under subsection (a)(3) for all States under subsection (a) for the year in which such fiscal year ends, subject to adjustment under subsection (d)(2). (c) Grants to States for indigent assistance (1) Application A State may file with the Secretary (in a form and manner specified by the Secretary) an application to provide assistance in furnishing health services to indigent individuals residing in the State. Such application shall demonstrate the manner in which such assistance is furnished in an equitable manner to individuals residing in all parts of the State. (2) Amount of funds From the funds appropriated under subsection (b) for a year, the amount of funds paid to any State in any year under this section with an application filed in accordance with paragraph (1) is equal to an amount specified in the application, but not to exceed the amount computed under subsection (a)(3) for the State and the year. (3) Use of funds Funds paid to a State under this subsection may be used only to assist in the furnishing of health services to uninsured individuals residing in the State or for purposes of increasing the payment adjustments made under sections 1886(d)(5)(F) and 1923 of the Social Security Act ( 42 U.S.C. 1395ww(d)(5)(F) , 1396r–4) to hospitals that serve a disproportionate share of such individuals in the State. (d) Initial estimate