Iran has a long history of revolutions, coups and invasions, leaving it with a complex web of power.