For purposes of Part 10.2 (commencing with Section 18401) and this part, the term “part-year resident” means a taxpayer who meets both of the following conditions during the same taxable year.
(a) Is a resident of this state during a portion of the taxable year.
(b) Is a nonresident of this state during a portion of the taxable year.