The first nationwide government-funded school system in China was established in the year 3 AD under Emperor Ping of Han (9 BC–5 AD). During the Northern Song dynasty, the government gradually reestablished an official school system after it was heavily damaged during the preceding Five Dynasties period. Government-established schools soon eclipsed the role of private academies by the mid-11th century. At the apex of higher education in the school system were the central schools located in the capital city, the Guozijian, the Taixue, and several vocational schools. The first major reform effort to rebuild prefectural and county schools was initiated by Chancellor Fan Zhongyan (989–1052) in the 1040s. Before this time, the bulk of funds allotted for the establishment of prefectural and county schools was left up to private financing and minimal amount of government funding; Fan's reform effort started the trend of greater government financing, at least for prefectural schools. Major expansion of educational facilities was initiated by Emperor Huizong, who used funds originally allotted for disaster relief and food-price stabilizing to fund new prefectural and county schools and demoted officials who neglected to repair, rebuild, and maintain these government schools. The historian John W. Chaffe states that by the early 12th century the state school system had of land that could provide for some 200,000 student residents living in dormitories. After the widespread destruction of schools during the Jurchen invasions from the 1120s to 1140s, Emperor Gaozong of Song (r. 1127–1162) issued an edict to restore prefectural schools in 1142 and county schools in 1148, although the county schools by and large were reconstructed by the efforts of local county officials' private fundraising.