->If we had an index file, we could look it up in the index file... under "index file".
-->-- '''Tegan''' discovers recursion
Previously on ''Series/DoctorWho'', the Doctor took a nasty spill from disconnecting the [[Recap/DoctorWhoS18E7Logopolis Pharos Project]]'s power cable, prompting his fourth regeneration. Unfortunately, the regeneration is in danger of failing. That is, unless he can get some rest and healing in the TARDIS' Zero Room, a sensory deprivation suite.
The freshly-regenerated Fifth Doctor wanders around his TARDIS with some regeneration amnesia, peeking into rooms and unraveling his scarf. The TARDIS is kind enough to hand her new Doctor a crickety outfit and a cricket room. Tegan just met the Doctor hours ago, and (though she took the whole new-body thing surprisingly calmly) even ''she'' realizes that he's gone batty. They get him into the Zero Room [[note]]which would be a great name for a nightclub[[/note]], but he's only just stretched out (three feet above the ground) and closed his weary eyes when the TARDIS' Cloister Bell alarm starts up. This is annoying enough for us humans when we're tired from a hard day slinging data and just need a good night's sleep before an important meeting in the morning; imagine how much it must suck if you're tired from saving the world and ''dying'' and being born again, plus the alarm isn't for an 8 AM meeting but an urgent warning that your spacetimeship is headed into the Big Bang.
Tegan and Nyssa put their heads together (as usual, Adric is being difficult ''and'' unwillingly in league with the villain), consult the TARDIS manual and inexpertly steer it to "Castrovalva: the Dwellings of Simplicity". Its brochure makes it sound like an alien day spa: the perfect place for a bit of R&R. The Doctor wakes up for a bit, and the TARDIS tries to help out by dumping a lot of random medicine on his head and providing him with a wheelchair. While spinning in circles in said chair and being extremely amnesiac, he instructs his companions on how to propel the TARDIS away from disaster by deleting rooms. Luckily, the control room doesn't accidentally get deleted. Sadly, the Zero Room does, so they have to improvise a new portable one out of some TARDIS doors.
Once they've landed and spent most of an ''entire episode'' carrying the Doctor through the woods, they discover that Castrovalva is... weird. It's built funny. All the books in the library are written in the same handwriting, even the very old ones. The quaint passageways always seem to lead to the same town square. Even more ominously, the kindly and wise elder statesman of the city is played by someone named "Neil Toynay", which of course is an anagram for "Tony Ainley", which means that the whole thing was an elaborate trap set by the Master! And they must escape Castrovalva as it dissolves into a puddle of Creator/MCEscher illogic around them.
Now ''that'' spells "regeneration trauma". No wonder the Tenth Doctor [[Recap/DoctorWho2005CSTheChristmasInvasion was bedridden and in need of a cup of tea]] after his regeneration. (And little wonder [[Recap/DoctorWhoS21E7TheTwinDilemma the Sixth Doctor spent his regeneration recovery trying to kill anyone and everyone around him.]])
Eventually, the Doctor regains his memory, convices the townsfolk to override their collective WeirdnessCensor and defeats the Master. Also, it turns out that Tegan didn't steer the TARDIS at all -- that was all the Master's doing. The Doctor pins a vegetable to his coat and happily heads over to the next adventure.
Watch it [[http://www.dailymotion.com/playlist/x1044o_tardismedia_castrovalva here]].
* ContinuityNod: The disoriented Doctor confuses his current companions for several previous ones, even going back to One's time when he calls Tegan "Vicki." He also takes on the mannerisms of the First ("I wonder, my boy, what you would do if you were me, hmm?", Second "Oh no! We've gone into the wrong part of the TARDIS! Jamie, you go back! When I say run, run!" and Third "Won't be long now, Brigadier - if the ice warriors don't get there first!") Doctors before developing his own, new personality.
* DemocracyIsBad: Used for the purposes of a gag.
* DistractedByMyOwnSexy: Averted this time around. The Fifth Doctor looks in the mirror, but his chief reaction is disappointment/alarm that the curls are gone.
* EnforcedMethodActing: According to TheOtherWiki and the DVDCommentary, Creator/MatthewWaterhouse was severely hungover and vomiting behind a tree in the scene at the end of Part 4 where the Doctor and Nyssa talk about landing the TARDIS. Creator/PeterDavison and Sarah Sutton kept acting, and the producers kept the shot, deciding it was useful anyway: it would show the ill effects on Adric's health from being under the Master's control.
* EstablishingCharacterMoment: The Fifth Doctor comes across as very gentle, very naive and very ''normal'' for the majority of the episode, but after about three quarters of the story, the "that's democracy for you" line firmly establishes him as a DeadpanSnarker as well.
* FakeMemories: Heck, the Castrovalvans have Fake ''History''
* GigglingVillain: Anthony Ainley is quietly chuckling to himself all through this episode and [[Recap/DoctorWhoS18E7Logopolis the last one]].
* IDieFree: Shardovan's FamousLastWords.
-->'''Shardovan:''' You made us, Man of Evil - but we are free!
* Creator/MCEscher: The episode is named after an Escher landscape lithograph (not one of his eyeball-benders).
* MindProbe: The Master keeps Adric trapped in a hadron web that forcibly extracts Block Transfer Computations from his mind, and trying to force the Master out of his head seems to be [[TheWoobie pretty painful for the poor kid.]]
* NiceHat: All of the Castrovalvans, but especially the Portreeve, who appears to be wearing a hat made of two Perspex boaters.
* RedHerring: The audience is clearly intended to believe that Shardovan (who is shifty and sinister and dresses all in black) is the Master. Probably intentional in-story as well.
* ResurrectionSickness: The Fifth Doctor had it bad. Probably the worst of any, barring perhaps the Eighth Doctor's.
* SignificantAnagram: The above-mentioned anagram for Anthony Ainley.
* SceneryPorn: The picturesque Castrovalvan [[GhibliHills countryside]], which comprises a good deal of Part Two.
* TomatoInTheMirror: For the Castrovalvans, especially Shardovan
* WeCanRuleTogether: The Master to Adric