You must file a federal income tax return if you are a citizen or resident of the United States or a resident of Puerto Rico and you meet the filing requirements. The filing requirements apply even if you do not owe tax. Most US citizens or greencard holders residing outside the United States for the tax year have the same filing requirements.
Surviving spouses and legal representatives of deceased taxpayers must file a final return if the deceased met the filing requirements at the date of death. Click for an example of filing as a surviving spouse.
Attention, noncitizens! The term 'resident' has one meaning for the IRS and another for immigration. You can be a 'resident' of the United States for tax purposes even though you have no green card.
Even certain individuals and businesses not resident to the United States might have filing requirements if they have sources of income within the United States. The basic principle is that income is taxed in the country in which it is earned. This is why US citizens residing outside the United States are not taxed on the first $97,600 (2013) of earned income if their visas allow them to legally be earning this income. This idea is generally accepted in most countries based on the premise that an individual or business is using the general services of that country (roads, schools, communication, etc) when residing or earning in the country.
We are growing serious, and, let me tell you, that's the very next step to being dull. - The Drummer (act IV, sc. 6) E
Joseph Addison, English essayist (1672-1719)