Nasir Khusraw was born in 1004 AD, in Qabodiyon. He was well versed in the branches of the natural sciences, medicine, mathematics, astronomy and astrology, Greek philosophy, and the writings of al-Kindi, al-Farabi and Ibn Sina; and in the interpretation of the Qur'an. He also studied Arabic, Turkish, Greek, the vernacular languages of India and Sindh, and perhaps even Hebrew; and had visited Multan and Lahore, and the splendid Ghaznavid court under Sultan Mahmud, Firdousi's patron. He later chose Merv for his residence, and was the owner of a house and garden there.