What are the origins of alchemy in Fullmetal Alchemist?
It was never fully explained, when and how alchemy was "invented", but it's known that Xerxes was one of the first countries to know alchemy. It already existed when the dwarf in the flask was created, as he was created using alchemy. The creation of the dwarf in the flask just increased the knowledge because it knew much about alchemy and helped the alchemists gaining knowledge.