All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad, sallallaahu ‘alayhi wa sallam, is His Slave and Messenger.
The basic rule is that women should perform Tawaaf behind men, and not mix with them. If the people cannot abide by that, or if they violate it either unintentionally or intentionally, it becomes incumbent upon the Muslim person to guard himself and endeavor to avoid what does not please Allaah Almighty as much as he could. Let him lower his gaze and engage his tongue and heart in supplication, Thikr and the like. If a man's body happens to touch a woman's, it is due on him to move away as much as he could, and not to persist in that. Mere touching does not break ablution according to the preponderant opinion of scholars.Allaah Knows best.