A sword is a weapon about 18+ inches long, with a single or double edged blade. They were likely first invented in the bronze age as a sidearm, a purpose they filled well up to the point when revolvers became widely available. They weren't primary weapons of war in any culture, as pole-arms, bows, and other weapons were better on the battlefield. Of course some specialized units such as dragoons, forlorn hope brigades, and sword and buckler men would use them. Most fighting swords only weigh about 2-4lbs. While Victorian England made "bearing swords" for display, no culture ever used heavy and clumsy swords for war.
Contrary to popular belief, the nihon-to (Japanese sword) is not superior to Western swords. The forge-folding technique was required for Japanese swords, as the domestic iron (tamahagane) was very low quality. Indian, Celtic, and Chinese swords are considered to be the best, as they combine good iron/steel with master smithing techniques. There are also examples from these cultures of swords with harder edges and a softer spine, much like the katana.
As with the development of other weapons, swords closely parelleled the development of armor. Early in the middle ages one would expect to fight mostly unarmored men. Therefore the blades of this era were usually flat, wide, and sharp. As chainmaille became more common the profile became more tapered, and the ridge stronger for better thrusting. With the development of plate armor some made swords such as the tuck, which was a little like a long ice pick. Swords were never intended to directly attack the plates, but instead thrust through the gaps.