Substantial presence test
(A) In general Except as otherwise provided in this paragraph, an individual meets the substantial presence test of this paragraph with respect to any calendar year (hereinafter in this subsection referred to as the “current year”) if— (i) such individual was present in the United States on at least 31 days during the calendar year, and (ii) the sum of the number of days on which such individual was present in the United States during the current year and the 2 preceding calendar years (when multiplied by the applicable multiplier determined under the following table) equals or exceeds 183 days:
| In the case of days in: | The applicable multiplier is: |
|---|---|
| Current year | 1 |
| 1st preceding year | ⅓ |
| 2nd preceding year | ⅙ |
(B) Exception where individual is present in the United States during less than one-half of current year and closer connection to foreign country is established An individual shall not be treated as meeting the substantial presence test of this paragraph with respect to any current year if— (i) such individual is present in the United States on fewer than 183 days during the current year, and (ii) it is established that for the current year such individual has a tax home (as defined in section 911(d)(3) without regard to the second sentence thereof) in a foreign country and has a closer connection to such foreign country than to the United States.
(C) Subparagraph (B) not to apply in certain cases Subparagraph (B) shall not apply to any individual with respect to any current year if at any time during such year— (i) such individual had an application for adjustment of status pending, or (ii) such individual took other steps to apply for status as a lawful permanent resident of the United States.
(D) Exception for exempt individuals or for certain medical conditions An individual shall not be treated as being present in the United States on any day if— (i) such individual is an exempt individual for such day, or (ii) such individual was unable to leave the United States on such day because of a medical condition which arose while such individual was present in the United States.