This is a lightly edited repeat of a contribution I have made to a discussion elsewhere.
Grammar is the set of rules that tells us how morphemes, the smallest units of meaning, may be combined to form words (morphology) and how words may be combined to form sentences (syntax). One rule of English grammar, for example, tells us that regular verbs form their past tense and past participle by the addition of -ed. We have to say, in modern Standard English, he walked and not *he wolk. Another tells us that determiners precede nouns. We have to say my house and not *house my. If you want something a little less obvious, then consider the fact that in English an anaphor may not both precede and command its antecedent.
These are real rules, which no normal adult native speaker of English will break. That’s why grammar is a matter of fact. It contrasts with style, which is a matter of opinion. There is no rule of English grammar that prohibits what is known inaccurately to most people as a split infinitive. It follows that whether a writer chooses to write ‘to suddenly realise’ or ‘to realise suddenly’ is a matter of style, of opinion. Nor is there any rule of English grammar that requires ‘that’ to introduce a restrictive relative clause. So an American president may choose to say ‘a day which will live in infamy’ or ‘a day that will live in infamy’ (and we know what he did choose). Both choices in each case are grammatical.
The rules of Standard English are codified in scholarly works of grammar. The early ones were little more than a reflection of the writer’s own preferences, but the past 30 years have seen the publication of grammars that go far beyond that approach, and they have been enormously improved by the availability of the evidence found in vast electronic corpora. The three monumental works during this period are ‘A Comprehensive Grammar of the English Language’ by Quirk and others, ‘The Longman Grammar of Spoken and Written English’ by Biber and others and ‘The Cambridge Grammar of the English Language’ by Rodney Huddleston and Geoffrey Pullum. They are based on a thorough examination of the way modern English is actually used, for, as Henry Sweet wrote in 1891:
In considering the use of grammar as a corrective of what are called ‘ungrammatical’ expressions, it must be borne in mind that the rules of grammar have no value except as statements of facts: whatever is in general use in a language is for that very reason grammatically correct.
The same thought has been expressed in our own day by the authors of ‘The Cambridge Grammar of the English Language’:
Grammar rules must ultimately be based on facts about how people speak and write. If they don’t have that basis, they have no basis at all.
As long ago as the early sixteenth century, John Colet saw that this was also true of Latin, as indeed it is of any language:
In the beginning men spake not Latin because such rules were made, but, contrariwise, because men spake Latin the rules were made. That is to say, Latin speech was before the rules, and not the rules before the Latin speech.
It would take a major piece of research to compare these three very long (and expensive) books, although all three have shortened versions. The authors of the ‘Cambridge Grammar’, at least, do have a different approach to some topics. They use the terms ‘integrated’ and ‘supplementary’, where others use ‘restrictive’ (or ‘defining’) and ‘non-restrictive’ (or ‘non-defining’) to describe the two types of relative clause. They do not consider what most others call the ‘were-subjunctive’ to be subjunctive at all, giving it instead the term ‘irrealis were’. Where most other linguists recognise only two English tenses, present and past, they speak of the perfect as ‘a past tense that is marked by means of an auxiliary verb rather than by inflection’. They class as prepositions words that other grammars class as adverbs or subordinating conjunctions.
The ‘Longman Grammar’ draws heavily on evidence from the Longman Spoken and Written English Corpus, and concentrates particularly on the grammatical differences between the four registers of Conversation, Fiction, News and Academic Prose. The stripped-down version, the ‘Longman Student Grammar of Spoken and Written English’ is one of the best general introductions to English grammar.
I suspect that there is much more agreement than disagreement in all three. They are concerned only with Standard English, and, as Huddleston and Pullum have written:
[There is] remarkably widespread agreement about how sentences should be constructed for such purposes as publication, political communication, or government broadcasting. This widespread agreement defines what we are calling Standard English.
So much for the rules of grammar themselves. The answer to the question ‘How are they changed?’ the answer is that, unlike style, they generally change very slowly. The erosion of inflections, for example, has been going on for centuries, and it continues. Our pronouns are pale shadows of their former selves, and it looks as if the remaining inflections will reduce further, with the growing merging of I and me, for example, and the loss of whom in all but the most formal contexts. The subjunctive, too, at least in British English, is all but extinct. These changes are not to be regretted. They are part of the very essence of language, and they occur because the needs of a language’s speakers change. Like the Sabbath, language was made for man, and not man for language. As Michael Halliday, the linguist most closely associated with Systemic Functional Linguistics, has written, ‘Language is as it is because of what it has to do’.
There is no single Standard English, but each major English-speaking state has its own standard. Any changes to those standards following the technological developments of the past few decades are likely to be in vocabulary rather than in grammatical structures. At the same time, the English used in computer mediated communication is developing its own grammatical forms. John McWhorter describes one aspect here. I would say that the most likely outcome is that the language of the web and texting, where it has its own identity, will grow alongside other varieties, rather than replace them.