When a spouse dies
The surviving spouse may file a joint return for the year of death. For the next two years, a survivor who has not remarried and keeps a home for a dependent child can file as a qualifying surviving spouse, using joint rates and the joint standard deduction. After that, head of household may apply.
Property inherited from the decedent gets a basis equal to its value at death. In community property states both halves of community property get the new basis. Income the decedent earned but hadn't received, such as unpaid wages, traditional IRA balances and installment payments, is income in respect of a decedent: it gets no new basis, is taxed to whoever receives it, and that person may deduct the estate tax attributable to it.