Surface structure of pyrolyzed polyimide