The formal study of language began in India with Pāṇini , the 5th century BC grammarian who formulated 3,959 rules of Sanskrit morphology .
The study of language began in India with Pāṇini , the 5th century BC grammarian who wrote about the 3,959 rules of Sanskrit morphology , which described the different kinds of vowels and consonants Sanskrit had , as well as verb and noun classes .