Dissociative Identity Disorder and Psychosis **SPOILERS**
Since we have people here theorizing on what mental ailments Anna was suffering from, I thought I'd make a post which outlines my case for what mental illness(es) were actually at play.
Firstly, we have psychosis -
Throughout the film Anna is seeing things which, in hindsight, were clearly not real. These hallucinations include seeing her dead mother, her sister (and believing her to be alive), the 3 dead children, and Matt (after he had died).
We also have paranoid delusions, which stem from a gross misinterpretation of Rachael's mysterious past (and subsequent name change), and a conflating of the stories told to her in the psych ward by Mildred Kemp with her subsequent beliefs about Rachael's past.
On Dissociative Identity Disorder (DID) -
We're told at the start of the film by the psychiatrist/psychologist treating Anna that sometimes we survive by forgetting. This is extremely similar to descriptions by people who claim to have suffered trauma-based mind-control.
The splitting of one person into a number of "alters" is a psychologically-protective mechanism, whereby one (or more) "alters" is created to deal with the terrible suffering that the core-persona would not be able to endure.
People who have suffered sexual abuse...often incestuous (in a non-mind-control capacity) have also described similar coping mechanisms, where during the day they would go about their normal routine with no memory of what happened to them, and then dissociating during the times of abuse. This has also been linked to DID.
In hindsight we can see that "Alex" is the strong alter who protects Anna from both the guilt of causing the fire that took both her mother's and Alex's lives...and even the fact that Alex died at all. This knowledge has essentially been relegated to the "Alex" alter.
The "Alex" alter is also clearly responsible for killing Rachael, and we can only speculate that it was the same alter that killed Matt to prevent him from revealing the truth about Anna's involvement in the fatal fire.
Alternative Hypothesis ("She's a psychopath") -
This is one that I don't believe is supported at all by the film. A "psychopath" (which now comes under the umbrella diagnosis of "Antisocial Personality Disorder", or APD) is most strongly connected to a lack of empathy.
A great deal of studies have been done that show that there are definite patterns of brain abnormalities, typically through the use of fMRI - namely, reduced communication between the amygdala (an important emotional processing area, particularly when it comes to fear), and various sub-regions of the pre-frontal cortex (an important region for higher reasoning and impulse control, etc.).
The fact that Anna is distraught over the death of Matt makes it clear that she is not "psychopathic" or rather, suffering from APD...but instead has a genuine ability to feel for others...and feel grief.
Moreover, someone with APD would have no need to repress their involvement in an accidental fatal fire, as they would have no guilt. They certainly would not then go on to create an alter to deal with the reality of what they had done.
I believe that Anna's demeanor at the end is a result of the reintegration of her alter and core persona's, and the realization that the psychiatrist/psychologist was right about needing to return home to finish the work they were doing in therapy. Perversely, reintegration came at the cost of two lives, and the fact that she'll probably remain in a secure mental facility for the rest of her life.
She is almost certainly aware that this is not what he expected (see the dialogue about the watering can, and the doctor's suggestion that perhaps she was trying to put out the fire). He didn't fix her at all! Mildred Kemp was absolutely right.
These mental health professionals really had no idea how disturbed she was (because they were only seeing her front persona)...and their ignorance set off a chain of events that lead from accidental death, to outright murder.
She followed their advice...and look what happened! If I were her, I'd probably look a little smug too.
Movie Parallels -
Similar pathologies are present in other films. In case you haven't seen them I won't go into detail, but I recommend "Fight Club" and "Hide and Seek". The latter shows both DID and the creation of a hallucinatory reality during the times the alter was active.
Anyhow, I'd be interested in feedback...both critiques and plausible alternatives to this interpretation.