for the purposes of immigration law it is a person who has indefinite leave to remain in the UK endorsed in their passport and who ordinarily resides in the UK. For tax purposes it has a different meaning.