Foundation is a science fiction novel by American writer Isaac Asimov. It is the first published in his Foundation Trilogy (later expanded into the Foundation series). Foundation is a cycle of five interrelated short stories, first published as a single book by Gnome Press in 1951. Collectively they tell the early story of the Foundation, an institute founded by psychohistorian Hari Seldon to preserve the best of galactic civilization after the collapse of the Galactic Empire.
Background
On August 1, 1941, Isaac Asimov proposed to John W. Campbell of Astounding Science Fiction that he write a short story set in a slowly declining Galactic Empire, based on the fall of the Western Roman Empire. Campbell liked the idea, and by the end of a two-hour meeting Asimov planned to write a series of stories depicting the fall of the first Galactic Empire and the rise of the second. Asimov submitted the first "Foundation" story on September 8, Campbell purchased it on September 15, and Astounding published it in May 1942. Asimov wrote seven more stories over eight years, and they were collected into The Foundation Trilogy. Published from 1951 to 1953, the three books became Asimov's most popular science fiction and won a Hugo Award for Best All-Time Series in 1966.

Plot summary
"The Psychohistorians" In 12,067 G.E. ("Galactic Era"), mathematician and psychologist Hari Seldon has developed psychohistory, a new field of science and psychology that allows for the probabilistic prediction of future events. By means of psychohistory, Seldon has discovered the decline and eventual fall of the Empire, angering its rulers, the Commission of Public Safety. Seldon defends his beliefs and the Commission, not wanting to make Seldon a martyr, offers him exile to a remote world, Terminus.

"The Encyclopedists" In 50 F.E. ("Foundation Era"), there is one region on Terminus that is suitable for the development of a large city, named Terminus City. The affairs of Terminus City are handled by its first Mayor, Salvor Hardin. Hardin believes Terminus is in danger of political exploitation by the four neighboring prefectures of the Empire. When Hardin's efforts are resisted by the Board, Hardin and his chief advisor, Yohan Lee, plan a "coup d'état."

"The Mayors" In the kingdom of Anacreon, Prince Regent Wienis and his teenaged nephew, King Lepold I, launch a direct military assault against Terminus, making use of an abandoned Imperial battlecruiser. Hardin secretly installs a kill switch into the cruiser, causing the crew to mutiny. The ship's commander, Admiral Prince Lefkin, Wienis's son, is captured and forced to broadcast a message to Anacreon. The message demands Wienis's arrest and trial before an ecclesiastical court. Wienis, maddened by his failure, orders Hardin's execution, but his royal guardsmen refuse to obey him. Attempting and failing, due to a protective energy field, to kill Hardin personally, Wienis dies by suicide.
"The Traders" Master Trader Eskel Gorov, an agent of the Foundation government, travels to the world of Askone, hoping to trade atomics. Gorov, however, is met with resistance by Askone's governing Elders due to traditional taboos that effectively ban advanced technology. Gorov is imprisoned and sentenced to death.
Trader Limmar Ponyets is ordered by the Foundation to try to negotiate with the Elders. He meets with the Elders' Grand Master and deduces that he may be willing to exchange Gorov for a suitable bribe. Ponyets clumsily fashions a transmuter that will convert iron into gold. Councilor Pherl, the Grand Master's protégé, believes that a stable supply of gold will increase his power, and Ponyets sells him the transmuter.
Gorov is released quickly. According to a new agreement, he and Ponyets can take as much tin from Pherl's mines as they can carry.
"The Merchant Princes" Three Foundation vessels have vanished near the Republic of Korell, which is suspected of either independent technological development or buying smuggled Foundation goods. Master Trader Hober Mallow is assigned to deal with Korell. Those who have assigned this mission to Mallow also plant an agent, Jaim Twer, aboard Mallow's ship, in disguise as a missionary, "Reverend Jord Parma." Korellian law forbids Foundation missionaries to be on the planet under penalty of death. Suspecting a set-up, Mallow decides to turn the missionary over to them.
Mallow's discoveries lead him to believe that the Empire has been providing weapons to client states. He journeys alone to the planet Siwenna, which he believes may be the capital of an Imperial province. He meets the impoverished patrician Onum Barr, who helps Mallow to understand the political situation.





