Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer)
Notes on this paper
National Examination, 04-BS-16 Discrete Mathematics, Dec 2013. Closed book, no aids, 3 hours, 12 questions of 10 marks each (100 marks); the exam instructs "answer 10 of 12" but every question is solved below as a complete study resource.
Reference texts: Rosen, Discrete Mathematics and Its Applications, 7th ed. (logic Ch.1, sets Ch.2, induction & pigeonhole Ch.5-6, relations Ch.9, counting Ch.6, discrete probability Ch.7, graphs Ch.10-11); Epp, Discrete Mathematics with Applications.
Find. Whether $f$ is a well-defined function; its domain and range; injectivity; surjectivity onto $\mathbb R$; and its inverse (over a corrected codomain if necessary).
(a) Is $f$ a function? A function must assign exactly one output to every input in its domain. $f(x)=4x+2$ is a single algebraic formula defined for every $x\in\mathbb R\setminus\mathbb Z$, producing exactly one real value each time. $\boxed{\text{Yes, }f\text{ is a well-defined function.}}$
(b) Domain and range. Domain $=\boxed{\mathbb R\setminus\mathbb Z}$ (given). Since $g(x)=4x+2$ is a bijection $\mathbb R\to\mathbb R$ (linear, slope $\ne0$), removing the integers from the domain removes exactly their images from the range: $g(n)=4n+2$ for $n\in\mathbb Z$. So
$$\text{Range} = \boxed{\mathbb R\setminus\{4n+2 : n\in\mathbb Z\}} = \mathbb R\setminus\{\dots,-6,-2,2,6,10,\dots\}.$$
(c) One-to-one? $f(x_1)=f(x_2)\Rightarrow4x_1+2=4x_2+2\Rightarrow x_1=x_2$ — the restriction of an injective linear map to a smaller domain is still injective. $\boxed{\text{Yes, one-to-one.}}$
(d) Onto (as a map to $\mathbb R$)? The range found in step 2 is $\mathbb R$ minus the countable set $\{4n+2:n\in\mathbb Z\}$, which is a proper subset of $\mathbb R$ (e.g. $y=2$ has no preimage, since $4x+2=2\Rightarrow x=0\in\mathbb Z$, excluded from the domain). $\boxed{\text{No, not onto }\mathbb R.}$
(e) Inverse. Because $f$ is not onto its stated codomain $\mathbb R$, it has no inverse $\mathbb R\to\mathbb R\setminus\mathbb Z$. However $f$ IS a bijection onto its own range: set
$$Y=\boxed{\mathbb R\setminus\{4n+2:n\in\mathbb Z\}}\ (\text{the range from step 2}).$$
Then $f:\mathbb R\setminus\mathbb Z\to Y$ is bijective, and solving $y=4x+2$ for $x$ gives the inverse
$$\boxed{f^{-1}(y)=\frac{y-2}{4}}.$$