Anathem by Neal Stephenson features a bifurcated world where a scholar-monk-class of mathematicians lives in walled-off areas that mingle with the rest of the world only on fixed dates. Some every year, some every ten years, and others only every 100 years. There is a lot more to it, but I don't want to give anything away.