What functions does the emperor fulfill
That depends on which historical empire you are considering when you ask. However in general an emperor serves as a figurehead of a government and absolute ruler of the military.