I am not an expert on sleep disorders. I have no idea what sort of strange mental disorder - if any - would cause a man to dream there was an intruder in the house and sleep-walk his way to murdering his own wife. What I do know is this: if you can convince a court that you have such a mental disorder and as a result are cleared of murder then since I am not aware of any wonder-drugs that instantly cure sleep-uxoricidality I can only conclude that you should remain in a secure mental health facility for the rest of your life for the safety of others.
Seems like sentencing those who commit violence against women is having a bad week in general. In Scotland a man was given 18 months probabtion for "having sex with" a 13-year-old (and when the BBC says "having sex" you will realise that what they mean is "raping" since 13-year-olds are not considered old enough to give meaningful consent under British law). Still no doubt being on probation for a few months will make him think twice about doing it again..?
By way of comparison if you accuse someone of rape but then turn out to be an "escort" (and check the double-speak here because aren't escorts supposed to be "high-class" prostitutes who are at liberty to pick and choose which of their clients they have sex with?) and therefore are presumed to have consented to any and all sex ... you get two years in prison.
My advice if you're planning on getting sexually assaulted this weekend (because of course it is women asking for it - not men perpetrating it, remember!) try to get your case heard in front of (a) Judge Paul Downes or (b) whoever sits at Preston Crown Court who seem to have a better grasp of how to deal with rapists.