Let, for real numbers $a$ and $b$, the mapping $f_{a,b} \ \colon \mathbf{R} \to \mathbf{R}$ be defined by $f_{a,b}(x) \colon = ax+b$ for all $x \in \mathbf{R}$.
Let $G \colon = \{ f_{a,b} \ | \ a, b \in \mathbf{R}, a \ne 0 \}$. Then $G$ is clearly a group under the composition of mappings. And, the set $H \colon = \{ f_{a,b} \ | \ a \in \mathbf{Q}, a \ne 0, b \in \mathbf{R} \}$ is a subgroup of $G$. What are all the distinct left cosets and all the distinct right cosets of $H$ in $G$?
Hint: since the inverse (in the group) of and element $\;\phi_{a,b}\in G\;$ is given by $\;\phi_{\frac1a,-\frac ba}\;$ , we get: $$\phi_{a,b}H=\phi_{a',b'}H\iff \phi_{a,b}\phi_{\frac1{a'},-\frac{b'}{a'}}\in H\iff \frac a{a'}\in\Bbb Q\;\ldots$$