The letter says that on Friday 10 October 2008, the bank's non-executive directors agreed that Sir Fred should leave the bank "and that it was in the company's interest for there to be an orderly handover to his successor".
"Sir Fred Goodwin agreed to stay in post until his successor was appointed and available," the letter says.
"During the course of 10 October 2008 they [Sir Tom McKillop and Bob Scott] decided this would best be accomplished through treating Sir Fred Goodwin as leaving at the request of the company in accordance with the principles applied to other directors leaving the group and not being dismissed," the letter adds.
The rules of the RBS pension scheme are outlined in the bank's annual report for 2007.
They mean that the pension Sir Fred had earned to date would be payable at age 50, rather than age 60, without any reduction for early retirement.
And that in turn meant his pension pot would have to be topped up, from £8.4m to £16.9m, to finance the early payment of ten year's worth of pension.
Earlier, the company set up to manage the government's holdings in banks criticised the way that RBS agreed Sir Fred Goodwin's pension.
MPs question UKFI bosses
UK Financial Investments (UKFI) blamed the RBS board for deciding to give its former boss an enlarged pension, which UKFI described as "discretionary".
The letter from RBS rejects this suggestion.
"Sir Fred Goodwin's pension arrangements (and other payments and benefits) followed as an automatic consequence of him being asked to leave at the request of the company," the letter points out.
UKFI chief executive John Kingman and acting chairman Glen Moreno were being questioned by the Treasury Committee.
Mr Moreno said he regarded Sir Fred's pension as "reward for failure".
He said: "I think it was wrong. I don't think the remuneration committee or the board of RBS should have effectively increased, doubled I guess, a pension benefit in that situation."
In the dark?
Mr Moreno criticised Sir Fred's behaviour at RBS. "If I were [Sir] Fred, I would have walked," he told MPs.
Mr Kingman said that the government had been aware of the size of the pension pot, but accused the RBS board of not sharing material facts with Financial Services Secretary Lord Myners.
He said: "I don't think one can expect Lord Myners to know the finer details of the RBS pension scheme."
The letter from RBS to Mr McFall reveals that City minister Lord Myners was told on 12 October that the value of Sir Fred's pension would be in a range between £15m and £20m.
"These pension terms were a consequence of the basis upon which it had been agreed that Sir Fred would be leaving the company, although we believe that no alternative basis for departure was discussed with Lord Myners," the letter says.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.