The requirement relates to your place of legal residence, not your physical presence. A trip abroad does not change your local residency unless it also rises to the level of canceling your U.S. residency. If you return from a three-week trip to the same residence you have established as your home, at which you have lived for approaching a year, then the trip doesn't change your place of residence. If you return from the trip and move to a different home in a new state, then the three months starts from when you establish residency in your new home.