Tehran was well known as a village in the 9th century , but was less well-known than the city of Rhages ( Ray . Tehran was well known as a village in the 9th century , but was less well-known than the city of Rhages ( Ray ) which was flourishing nearby in the early era .