If a grammar is either left linear (any non-terminal in production comes at the left end) or right linear (any non-terminal in production comes at right end) it is regular
$S\to Sa \mid a$ is left linear so it is regular grammar.
$S\to aS \mid a$ is right linear, so it is regular grammar.
$S\to SaS \mid a$ is neither left linear nor right linear and hence it is not regular grammar.
- All regular grammars generate regular language
- Non regular grammar can also generate regular langauge
- For any regular language, a regular grammar exist
- A regular grammar cannot generate a non-regular language
In short
A language is regular if and only if it can be generated by a regular grammar