Pei Xiu (224–271), style name Jiyan, was a minister, geographer, and cartographer of the state of Cao Wei during the Three Kingdoms period of Chinese history, as well as the subsequent Jin Dynasty. Pei Xiu was very much trusted by Sima Zhao, and participated in the suppression of Zhuge Dan's coup. Following Sima Yan taking the throne of the newly established Jin Dynasty, he and Jia Chong had Cao Huang deprived of his position to accord to the will of heaven. In the year 267, Pei was appointed as the Minister of Works for the Jin Dynasty.
Pei Xiu outlined and analyzed the advancements of cartography, surveying, and mathematics up until his time. He criticized earlier Han Dynasty maps for their lack of precision and quality when representing scale and measured distances, although 20th century archeological excavations and findings of maps predating the 3rd century prove otherwise. There is also evidence that Zhang Heng (78–139 AD) was the first to establish the grid reference system in Chinese cartography.
Pei Xiu the cartographer 
Pei is best known for his work in cartography. Although professional map-making and use of the grid had existed in China before him, he was the first to mention a plotted geometrical grid reference and graduated scale displayed on the surface of maps to gain greater accuracy in the estimated distance between different locations. Historian Howard Nelson asserts that there is ample written evidence that Pei Xiu derived the idea of the grid reference from the map of Zhang Heng (78–139 AD), a polymath inventor and statesman of the Eastern Han period. Robert Temple asserts that Zhang should also be credited as the first to establish the mathematical grid in cartography, as evidenced by his work in maps, the titles of his lost books, and the hint given in the Book of Later Han (i.e. Zhang "cast a network of coordinates about heaven and earth, and reckoned on the basis of it").
The preface to Pei Xiu's written work was preserved in the 35th chapter of the Book of Jin, which is the official history for the Jin Dynasty and one of the Twenty-four Histories. It was written in the Book of Jin that Pei made a critical study of ancient texts in order to update the naming conventions of geographic locations described in old texts. His maps —drawn upon rolls of silk — were presented to the Jin emperor, who preserved them in the court's archives. Pei Xiu's maps have since been lost, decayed, or destroyed. Yet the oldest existing terrain maps from China date to the 4th century BC, found in a Qin State tomb of modern Gansu province in 1986. Han Dynasty era maps from the 2nd century BC were found earlier in the 1973 excavation of Mawangdui.
In 1697, the Qing Dynasty cartographer Hu Wei reconstructed Pei's maps in his Yugong Zhuizhui (A Few Points in the Vast Subject of the Yu Gong). Modern scholars have also used Pei's writing to reproduce his works, and historians such as Herrmann have compared Pei to other great ancient cartographers such as the Greek cartographer Ptolemy (83–161).
Pei's written work 
Pei Xiu wrote a preface to his maps with essential background information regarding older maps in China. Pei Xiu also provided a great deal of criticism about the existing maps from the Han Dynasty in his time. Later Chinese ideas about the quality of maps made during the Han Dynasty and before stem from the assessment given by Pei Xiu, which was not a positive one. Pei Xiu noted that the extant Han maps at his disposal were of little use since they featured too many inaccuracies and exaggerations in measured distance between locations. However, the Qin State maps and Mawangdui maps of the Han Dynasty discovered by modern archeologists were far superior in quality than those examined and criticized by Pei Xiu. It was not until the 20th century that Pei Xiu's 3rd century assessment of earlier maps' dismal quality would be overturned and disproven. The makers of the Han maps were familiar with the use of scale, while the Qin map makers had pinpointed the course of rivers with some accuracy. What these earlier maps did not feature was topographical elevation, which Pei Xiu would outline with his six principles of cartography.
Pei Xiu's preface describes geographers in the Xia, Shang, and Zhou dynasties, although the earliest known geographical work was the Yu Gong chapter (禹贡地域图) of the Classic of History, compiled in the 5th century BC during the mid Zhou period. Pei also referred to the officer Xiao He (d. 193), who assembled the maps made during the recently fallen Qin Dynasty. This was done after the founder of the Han Dynasty, Liu Bang (d. 195 BC) had sacked the city of Xianyang. Pei Xiu states:
The origin of maps and geographical treatises goes back into former ages. Under the three dynasties (Xia, Shang, and Zhou) there were special officials for this (Guo Shi). Then, when the Han people sacked Xianyang, Xiao He collected all the maps and documents of the Qin. Now it is no longer possible to find the old maps in the secret archives, and even those Xiao He found are missing. We only have maps, both general and local, from the (Later) Han time. None of these employs a graduated scale (fen lü) and none of them are arranged on a rectangular grid (zhun wang). Moreover, none of them gives anything like a complete representation of the celebrated mountains and the great rivers; their arrangement is very rough and imperfect, and one cannot rely on them. Indeed some of them contain absurdities, irrelevancies, and exaggerations, which are not in accord with reality, and which should be banished by good sense.
Pei Xiu continues his preface with short background information on the conquest of the Jin Dynasty and the impressive maps commissioned by Emperor Wen of Jin, otherwise known as Sima Zhao (211–264). He then described the methods he used to create new maps while examining the ancient Yu Gong text to create historical maps:
The assumption of power by the great Jin dynasty has unified space in all the six directions. To purify its territory, it began with Yong and Shu (Hubei and Sichuan), and penetrated deeply into their regions, though full of obstacles. The emperor Wen then ordered the appropriate officials to draw up maps of Wu and Shu. After Shu had been conquered and the maps were examined, with regard to the distances from one another of mountains, rivers, and places, the positions of plains and declivities, and the lines of the roads, whether straight or curved, which the six armies had followed; it was found that there was not the slightest error. Now, referring back to antiquity, I have examined according to the Yu Gong the mountains and lakes, the courses of the rivers, the plateaus and plains, the slopes and marshes, the limits of the nine ancient provinces and the sixteen modern ones, taking account of commanderies and fiefs, prefectures and cities, and not forgetting the names of places where the ancient kingdoms concluded treaties or held meetings; and lastly, inserting the roads, paths, and navigable waters, I have made this map in eighteen sheets.
Pei Xiu outlined six principles that should be observed when creating a map. He then defended his position and each of the six principles with a short explanation as to how they provide better accuracy in map-making and cartography. The first three principles outlined the use of scale (fan lu), direction (zhunwang), and road distance (daoli), while the last three principles are used to properly calculate distances on uneven terrain as represented on a flat, two dimensional map. Pei Xiu states:
In making a map there are six observable principles: (1) the graduated divisions, which are the means of determining the map's scale; (2) the rectangular grid (of parallel lines in two dimensions), which is the way of depicting correct relations between various parts of the map; (3) pacing out the sides of right-angled triangles, which is the way of fixing the lengths of derived distances (i.e., the third side of the triangle, which cannot be walked over); (4) (measuring) the high and the low; (5) (measuring) right angles and acute angles; (6) (measuring) curves and straight lines. These three principles are used according to the nature of the terrain, and are the means by which one reduces what are really plains and hills (lit. cliffs) to distances on a plane surface...If one draws a map without graduated divisions, there is no means of distinguishing between what is near and what is far. If one has graduated divisions, but no rectangular grid or network of lines, then while one may attain accuracy in one corner of the map, one will certainly lose it elsewhere (i.e. in the middle, far from guiding marks). If one has a rectangular grid, but has not worked upon the [third] principle, then when it is a case of places in difficult country, among mountains, lakes, or seas (which cannot be traversed directly by the surveyor), one cannot ascertain how they are related to one another. If one has adopted the [third] principle, but has not taken account of the high and the low, the right angles and acute angles, and the curves and straight lines, then the figures for distances indicated on the paths and roads will be far from the truth, and one will lose the accuracy of the rectangular grid. However, if we examine a map prepared by the combination of all these principles, we find that a true scale representation of the distances is fixed by the graduated divisions. So also the reality of the relative positions is attained by the use of paced sides of right-angled triangles; and the true scale of degrees and figures is reproduced by the determinations of high and low, angular dimensions, and curved or straight lines. Thus even if there are great obstacles in the shape of high mountains or vast lakes, huge distances or strange places, necessitating climbs and descents, retracting of steps or detours — everything can be taken into account and determined. When the principle of the rectangular grid is properly applied, then the straight and the curved, near and the far, can conceal nothing of their form from us.
See also 
- Needham, Volume 3, 538.
- Hsu, 96.
- Needham, Volume 3, 106–107.
- Needham, Volume 3, 538–540.
- Nelson, 359.
- Temple (1986) 30.
- Needham, Volume 3, 541.
- Needham, Volume 3, 540.
- Hsu, 90.
- Hsu, 97.
- Needham, Volume 3, 500.
- Needham, Volume 3, 539.
- Hsu, 96–97.
- Needham, Volume 3, 539–540.
- Hsu, Mei-ling. "The Qin Maps: A Clue to Later Chinese Cartographic Development," Imago Mundi (Volume 45, 1993): 90-100.
- Needham, Joseph (1986). Science and Civilization in China: Volume 3, Mathematics and the Sciences of the Heavens and the Earth. Taipei: Caves Books Ltd.
- Nelson, Howard. "Chinese Maps: An Exhibition at the British Library," The China Quarterly (Number 58, 1974): 357–362.
- Temple, Robert. (1986). The Genius of China: 3,000 Years of Science, Discovery, and Invention. With a forward by Joseph Needham. New York: Simon and Schuster, Inc. ISBN 0-671-62028-2.