The sentencing issue of diminished capacity

Describe a case where the sentencing issue of diminished capacity may come up. You can be creative here 2) Describe a scenario where a judge may throw out a confession after improper administration of Miranda rights, or where a judge may keep a confession because of proper Miranda administration.