Relations and Functions
What to remember
- A relation from $A$ to $B$ is any subset of $A\times B$. If $n(A)=m$ and $n(B)=n$, there are $2^{mn}$ such relations.
- An equivalence relation is reflexive, symmetric and transitive together. It cuts the set into equivalence classes that never overlap and together cover the whole set.
- A function is a relation in which every element of the domain has exactly one image. From an $m$-element set to an $n$-element set there are $n^m$ functions.
- One-one means different inputs give different outputs. Onto means range equals codomain. A function has an inverse exactly when it is both.
- Always find the domain first. Composition, inverse and range questions all go wrong when the domain is ignored.
Ordered pairs and Cartesian product
An ordered pair $(a,b)$ is two objects with a fixed order. $(a,b)=(c,d)$ only when $a=c$ and $b=d$. So $(2,5)$ and $(5,2)$ are different points; this is the same reason the point $(2,5)$ on a graph is not $(5,2)$.
The Cartesian product of two sets is the set of all ordered pairs with the first entry from the first set and the second from the second:
Facts you will use again and again:
- $n(A\times B)=n(A)\cdot n(B)$.
- $A\times B\ne B\times A$ in general. They are equal only when $A=B$ or one of the sets is empty.
- $A\times\varnothing=\varnothing$.
- $A\times(B\cup C)=(A\times B)\cup(A\times C)$ and $A\times(B\cap C)=(A\times B)\cap(A\times C)$.
- $(A\times B)\cap(C\times D)=(A\cap C)\times(B\cap D)$. The intersection acts on each coordinate separately. A union does not behave this way.
Example 1: $A=\{1,2,3,4\}$ and $B=\{3,4,5\}$. Find $n\big((A\times B)\cap(B\times A)\big)$.
Use the intersection rule: $(A\times B)\cap(B\times A)=(A\cap B)\times(B\cap A)$.
$A\cap B=\{3,4\}$, so the product is $\{3,4\}\times\{3,4\}$.
It has $2\times2=4$ elements: $(3,3),(3,4),(4,3),(4,4)$.
Answer: 4. Why this works: a pair lies in both products only if each coordinate lies in both sets.
Relations: domain, codomain, range
A relation $R$ from $A$ to $B$ is a subset of $A\times B$. We write $aRb$ or $(a,b)\in R$. When $B=A$ we call it a relation on $A$.
- Domain of $R$: all first entries that actually occur.
- Codomain: the whole set $B$.
- Range: all second entries that actually occur. Range is a subset of codomain.
Take $A=\{1,2,3\}$ and $R=\{(a,b): b=a+1,\ b\in\{2,3,4\}\}$. Then $R=\{(1,2),(2,3),(3,4)\}$. Domain is $\{1,2,3\}$, range is $\{2,3,4\}$.
Counting relations. Each of the $mn$ pairs in $A\times B$ is either in the subset or out, so there are $2^{mn}$ relations from $A$ to $B$. On a set with $n$ elements there are $2^{n^2}$ relations. The empty set and $A\times B$ itself are both counted.
The inverse relation is $R^{-1}=\{(b,a): (a,b)\in R\}$. Its domain is the range of $R$ and vice versa.
Reflexive, symmetric, transitive, equivalence
For a relation $R$ on a set $A$:
| Property | Meaning | How it fails |
|---|---|---|
| Reflexive | $aRa$ for every $a\in A$ | one element is missing its own pair $(a,a)$ |
| Symmetric | $aRb\Rightarrow bRa$ | one pair $(a,b)$ present but $(b,a)$ missing |
| Transitive | $aRb$ and $bRc\Rightarrow aRc$ | a chain $a\to b\to c$ with $(a,c)$ missing |
A relation that is reflexive, symmetric and transitive is an equivalence relation.
Two small warnings. First, "transitive" only asks something when a chain exists; with no chain it holds without any work. So the empty relation on a non-empty set is symmetric and transitive but not reflexive. Second, a relation can be symmetric and transitive and still fail to be reflexive, because an element that is related to nothing has no $(a,b),(b,a)$ pair to force $(a,a)$.
Counting on an $n$-element set: reflexive relations number $2^{n^2-n}$ (the $n$ diagonal pairs are forced, the other $n^2-n$ are free). Symmetric relations number $2^{n(n+1)/2}$ (choose each diagonal pair and each unordered off-diagonal pair freely).
Equivalence classes
If $R$ is an equivalence relation on $A$, the class of $a$ is $[a]=\{x\in A: xRa\}$. Three facts follow from the three properties:
- $a\in[a]$ (reflexive), so no class is empty.
- Either $[a]=[b]$ or $[a]\cap[b]=\varnothing$ (symmetric and transitive).
- The classes together make up $A$.
So an equivalence relation is the same thing as a partition of the set into blocks. Conversely, any partition gives an equivalence relation: "$x$ and $y$ lie in the same block". Therefore the number of equivalence relations on an $n$-element set equals the number of ways to partition it: $1, 2, 5, 15$ for $n=1,2,3,4$.
Example 2: On $\mathbb Z$ define $aRb$ when $a-b$ is divisible by 3. Show that $R$ is an equivalence relation and list the classes.
Reflexive: $a-a=0$, and $0$ is divisible by 3. Yes.
Symmetric: if $3\mid(a-b)$ then $b-a=-(a-b)$ is also divisible by 3. Yes.
Transitive: $a-b=3p$ and $b-c=3q$ give $a-c=3(p+q)$. Yes.
Classes: remainders on division by 3. $[0]=\{\dots,-3,0,3,6,\dots\}$, $[1]=\{\dots,-2,1,4,\dots\}$, $[2]=\{\dots,-1,2,5,\dots\}$.
Answer: three classes, and $[4]=[1]$.
Why this works: "same remainder" is the real meaning of the relation, and same-remainder is obviously reflexive, symmetric and transitive.
Example 3: On $A=\{1,2,3\}$, $R=\{(1,2),(2,1)\}$. Check the three properties, then add the fewest pairs to make it an equivalence relation.
Reflexive? $(1,1)$ is missing. No.
Symmetric? $(1,2)$ has $(2,1)$. Yes.
Transitive? $(1,2)$ and $(2,1)$ force $(1,1)$, which is absent. No.
To repair: add $(1,1)$, $(2,2)$, $(3,3)$. Now the chains $1\to2\to1$ and $2\to1\to2$ land on pairs that are present, and no other chains exist.
Result: $\{(1,1),(2,2),(3,3),(1,2),(2,1)\}$ with classes $\{1,2\}$ and $\{3\}$.
Why this works: the missing pairs were forced by the other two rules, so nothing extra is needed.
Memory trick: "Reflexive looks at one, symmetric looks at two, transitive looks at three." Use it to decide what to test: one element $a$, a pair $a,b$, a chain $a,b,c$.
Functions
A function $f:A\to B$ is a relation from $A$ to $B$ in which every $a\in A$ has exactly one partner $b\in B$. We write $b=f(a)$ and call $b$ the image of $a$. Two things can break it: an element of $A$ with no partner, or an element with two partners.
- Domain is all of $A$. Codomain is $B$. Range is the set of values $f(a)$ actually taken.
- A graph in the plane represents a function exactly when every vertical line meets it at most once (once inside the domain).
When a rule is given without a domain, the domain means every real number for which the rule makes sense. The checks:
| Expression | Condition |
|---|---|
| $\dfrac{1}{g(x)}$ | $g(x)\ne0$ |
| $\sqrt{g(x)}$ | $g(x)\ge0$ |
| $\log_a g(x)$ | $g(x)>0$, with $a>0$, $a\ne1$ |
| $\tan x$, $\sec x$ | $x\ne(2k+1)\dfrac{\pi}{2}$ |
| $\cot x$, $\csc x$ | $x\ne k\pi$ |
| $[g(x)]$, $\{g(x)\}$, $\vert g(x)\vert$ | no condition beyond $g$ itself |
When several expressions are present, take the intersection of all conditions.
Finding the range. Three working methods: write $y=f(x)$ and solve for $x$, then see which $y$ allow a real $x$ in the domain; use bounds you already know ($-1\le\sin x\le1$, $x^2\ge0$, $e^x>0$); or complete the square for a quadratic.
Example 4: Find the domain of $f(x)=\dfrac{\ln(x^2-3x+2)}{\sqrt{4-x}}$.
Log needs $x^2-3x+2>0$, that is $(x-1)(x-2)>0$, so $x<1$ or $x>2$.
Root in the denominator needs $4-x>0$, so $x<4$. Strict, because the root also sits under a division.
Intersect: $x<1$, or $2<x<4$.
Answer: $(-\infty,1)\cup(2,4)$.
Why this works: every restriction applies at once, so the domain is the overlap, not the union.
Example 5: Find the range of $f(x)=\dfrac{2x-1}{x+3}$.
The domain is $x\ne-3$. Put $y=\dfrac{2x-1}{x+3}$, so $y(x+3)=2x-1$.
Collect $x$: $x(y-2)=-1-3y$, so $x=\dfrac{-(1+3y)}{y-2}$.
A real $x$ exists for every $y\ne2$. And $y=2$ would need $6=-1$, which is impossible.
Answer: range is $\mathbb R\setminus\{2\}$.
Why this works: solving for $x$ turns "which $y$ are reachable" into "when is the formula defined".
One-one, onto, bijective
$f:A\to B$ is one-one (injective) if $f(a_1)=f(a_2)$ forces $a_1=a_2$. Equivalent: different inputs give different outputs. Graph test: every horizontal line meets the graph at most once.
$f$ is onto (surjective) if every element of $B$ is an image: range = codomain.
$f$ is bijective if it is both.
To prove one-one: assume $f(a_1)=f(a_2)$ and derive $a_1=a_2$. To disprove: give two different inputs with the same output. To prove onto: take $y\in B$ and solve $f(x)=y$ for an $x$ in the domain. To disprove: find a $y$ with no solution.
Whether a function is one-one or onto depends on the stated domain and codomain, not only on the formula. The rule $f(x)=x^2$ is not one-one on $\mathbb R$ (since $f(-1)=f(1)$), not onto $\mathbb R$ (no square is negative), but it is bijective from $[0,\infty)$ to $[0,\infty)$.
Any strictly increasing or strictly decreasing function is one-one. A periodic function is never one-one on its full domain, and an even function is never one-one on a domain containing some $a\ne0$ along with $-a$.
Counting functions
Let $n(A)=m$ and $n(B)=n$.
| Type | Count | Reason |
|---|---|---|
| All functions | $n^m$ | each of $m$ inputs has $n$ choices |
| One-one | $n(n-1)\cdots(n-m+1)$, zero if $m>n$ | choices shrink as outputs are used |
| Onto, $n=2$ | $2^m-2$ | remove the two constant functions |
| Onto, $n=3$ | $3^m-3\cdot2^m+3$ | inclusion and exclusion |
| Bijective ($m=n$) | $n!$ | arrange the outputs |
Example 6: $A=\{1,2,3,4\}$, $B=\{a,b,c\}$. Count all functions, one-one functions and onto functions from $A$ to $B$.
All: $3^4=81$.
One-one: needs 4 distinct outputs from 3 elements. Impossible, so 0.
Onto: $3^4-3\cdot2^4+3=81-48+3=36$.
Check by direct counting: an onto map must send exactly two inputs to one output. Pick the pair of inputs: $\binom42=6$. Then assign the three groups (pair, single, single) to $a,b,c$ in $3!=6$ ways. $6\times6=36$.
Answer: 81, 0, 36.
Why this works: the second count confirms the inclusion-exclusion count from a different side.
Even and odd functions
On a domain that is symmetric about 0:
- $f$ is even if $f(-x)=f(x)$. The graph is mirror-symmetric about the $y$-axis. Examples: $x^2$, $\vert x\vert$, $\cos x$, $\dfrac{e^x+e^{-x}}{2}$.
- $f$ is odd if $f(-x)=-f(x)$. The graph is unchanged by a half-turn about the origin. Examples: $x^3$, $\sin x$, $\tan x$, $\mathrm{sgn}(x)$.
If $0$ is in the domain of an odd function, $f(0)=0$. The only function that is both even and odd is $f(x)=0$. Most functions are neither: $x+1$, $e^x$, $[x]$.
| Combination | Result |
|---|---|
| even $\pm$ even, odd $\pm$ odd | same parity |
| even $\times$ even, odd $\times$ odd | even |
| even $\times$ odd | odd |
| odd $\circ$ odd | odd |
| even $\circ$ odd, or anything $\circ$ even | even |
Every function on a symmetric domain splits uniquely into an even part and an odd part:
Memory trick: "Even is a mirror, odd is a spin." A mirror shows the same face on both sides of the $y$-axis; a spin of 180 degrees about the origin swaps the two. Use it to guess parity from a sketch before you prove it.
Special functions and their graphs
Polynomial. $a_nx^n+\dots+a_0$. Domain $\mathbb R$. Range $\mathbb R$ for odd degree; for even degree it is bounded on one side.
Rational. $\dfrac{p(x)}{q(x)}$. Domain excludes the zeros of $q$.
Modulus. $\vert x\vert=x$ for $x\ge0$ and $-x$ for $x<0$. Domain $\mathbb R$, range $[0,\infty)$, even. Remember $\vert x\vert=\sqrt{x^2}$.
Signum. $\mathrm{sgn}(x)=1$ for $x>0$, $0$ for $x=0$, $-1$ for $x<0$. Domain $\mathbb R$, range $\{-1,0,1\}$, odd.
Greatest integer. $[x]$ is the largest integer not exceeding $x$, so $[x]\le x<[x]+1$. Examples: $[3.7]=3$, $[-3.7]=-4$, $[5]=5$. Domain $\mathbb R$, range $\mathbb Z$. It is a staircase, flat between integers and jumping by 1 at each integer.
Fractional part. $\{x\}=x-[x]$. Always $0\le\{x\}<1$. Domain $\mathbb R$, range $[0,1)$. It climbs along slope 1 and drops back to 0 at each integer. Period 1.

*Figure 2.1: Graphs of $[x]$ and $\{x\}$ for $-2\le x<3$*
Useful identities, for integer $n$: $[x+n]=[x]+n$ and $\{x+n\}=\{x\}$. For non-integer $x$: $[x]+[-x]=-1$ and $\{x\}+\{-x\}=1$. For integer $x$ both sums are $0$.
Exponential. $f(x)=a^x$, $a>0$, $a\ne1$. Domain $\mathbb R$, range $(0,\infty)$. Increasing if $a>1$, decreasing if $0<a<1$. It never reaches 0 and passes through $(0,1)$.
Logarithmic. $f(x)=\log_a x$. Domain $(0,\infty)$, range $\mathbb R$. Passes through $(1,0)$. Increasing if $a>1$.
Trigonometric.
| Function | Domain | Range | Parity | Period |
|---|---|---|---|---|
| $\sin x$ | $\mathbb R$ | $[-1,1]$ | odd | $2\pi$ |
| $\cos x$ | $\mathbb R$ | $[-1,1]$ | even | $2\pi$ |
| $\tan x$ | $x\ne(2k+1)\frac{\pi}{2}$ | $\mathbb R$ | odd | $\pi$ |
| $\cot x$ | $x\ne k\pi$ | $\mathbb R$ | odd | $\pi$ |
| $\sec x$ | $x\ne(2k+1)\frac{\pi}{2}$ | $(-\infty,-1]\cup[1,\infty)$ | even | $2\pi$ |
| $\csc x$ | $x\ne k\pi$ | $(-\infty,-1]\cup[1,\infty)$ | odd | $2\pi$ |
Periodic functions
$f$ is periodic if there is some $T>0$ with $f(x+T)=f(x)$ for every $x$ in the domain (and $x+T$ is in the domain). The smallest such $T$ is the fundamental period, usually just called "the period".
- If $f$ has period $T$, then $f(ax+b)$ has period $\dfrac{T}{\vert a\vert}$.
- $\sin^2x$, $\cos^2x$, $\vert\sin x\vert$ and $\vert\cos x\vert$ have period $\pi$. This is because $\sin(x+\pi)=-\sin x$ and the sign disappears when squared or under modulus.
- $\{x\}$ has period 1. A constant function has every $T>0$ as a period, so there is no smallest.
- For $f+g$ or $fg$, the least common multiple of the two periods is a period. It need not be the smallest: $\vert\sin x\vert+\vert\cos x\vert$ has period $\frac{\pi}{2}$, smaller than the LCM $\pi$.
Example 7: Find a period of $f(x)=\sin\dfrac{x}{3}+\cos\dfrac{x}{2}$.
$\sin\frac{x}{3}$ has period $\dfrac{2\pi}{1/3}=6\pi$.
$\cos\frac{x}{2}$ has period $\dfrac{2\pi}{1/2}=4\pi$.
In units of $2\pi$ the periods are 3 and 2. Their LCM is 6, so $T=6\times2\pi=12\pi$.
Answer: $12\pi$.
Why this works: both parts must come back to their starting values together, so $T$ must be a whole number of periods of each.
Algebra and composition of functions
For $f$ and $g$ with domains $D_f$ and $D_g$, the sum, difference and product are defined on $D_f\cap D_g$, and the quotient $\dfrac{f}{g}$ is defined where in addition $g(x)\ne0$.
Composition. $(f\circ g)(x)=f(g(x))$. Apply $g$ first. It exists for those $x\in D_g$ for which $g(x)\in D_f$. So the range of $g$ must overlap the domain of $f$.
- Composition is associative: $(f\circ g)\circ h=f\circ(g\circ h)$.
- Composition is not commutative: $f\circ g\ne g\circ f$ in general.
Example 8: $f(x)=\sqrt{x}$ and $g(x)=x^2-4$. Find $f\circ g$, $g\circ f$, and their domains.
$(f\circ g)(x)=\sqrt{x^2-4}$. Need $x^2-4\ge0$, so $x\le-2$ or $x\ge2$.
$(g\circ f)(x)=(\sqrt x)^2-4=x-4$. But $f$ needs $x\ge0$ first. The formula looks like it works for all $x$, but the domain is $[0,\infty)$.
Answer: $f\circ g=\sqrt{x^2-4}$ on $(-\infty,-2]\cup[2,\infty)$; $g\circ f=x-4$ on $[0,\infty)$.
Why this works: simplifying the formula must never widen the domain.
Invertible functions and the inverse
If $f:A\to B$ is bijective, then for each $y\in B$ there is exactly one $x\in A$ with $f(x)=y$. Define $f^{-1}(y)=x$. Then
Only a bijection has an inverse. A function that fails one-one gives two answers for $x$; one that fails onto leaves some $y$ with no answer.
To find the inverse: write $y=f(x)$, solve for $x$ in terms of $y$, then rename $y$ as $x$. Check domain and range swap places.
Graph. The graph of $f^{-1}$ is the mirror image of the graph of $f$ in the line $y=x$. Domain of $f^{-1}$ = range of $f$, and range of $f^{-1}$ = domain of $f$.
Fixing a non-invertible function. Restrict the domain until it is one-one, and shrink the codomain to the range. For $x^2$, restricting to $[0,\infty)$ gives inverse $\sqrt{x}$.
Other facts: $(f^{-1})^{-1}=f$, and $(f\circ g)^{-1}=g^{-1}\circ f^{-1}$ (undo the last step first, like taking off shoes before socks).

*Figure 2.2: The curves $y=e^x$ and $y=\ln x$ are reflections of each other in $y=x$*
Example 9: $f(x)=x^2+4x+7$ on $[-2,\infty)$ with codomain $[3,\infty)$. Show that $f$ is invertible and find $f^{-1}$.
Complete the square: $f(x)=(x+2)^2+3$.
For $x\ge-2$, $x+2\ge0$ and squaring is strictly increasing there, so $f$ is one-one. Smallest value is $f(-2)=3$ and it grows without limit, so the range is $[3,\infty)$: onto.
Solve $y=(x+2)^2+3$: $(x+2)^2=y-3$. Since $x+2\ge0$, take the positive root: $x=-2+\sqrt{y-3}$.
Answer: $f^{-1}(x)=-2+\sqrt{x-3}$ for $x\ge3$.
Why this works: the stated domain removes the negative root, so only one value of $x$ is possible.
Memory trick: "Swap and solve, then reflect." Swap the roles of $x$ and $y$, solve, and remember the picture is a flip in $y=x$. Use it to catch errors: if the picture does not look like a mirror, the inverse is wrong.
Common traps
- Treating $A\times B$ as equal to $B\times A$ -> they differ unless $A=B$; $(2,5)\ne(5,2)$.
- Saying a relation is reflexive because it "looks" symmetric -> check every element of the set has its own pair $(a,a)$, including elements that appear in no other pair.
- Declaring a relation transitive after checking one chain -> test every chain; one missing $(a,c)$ breaks it.
- Assuming symmetric and transitive together force reflexive -> they do not when some element is related to nothing.
- Counting a function when one element of the domain has two images or none -> exactly one image per input.
- Calling $f(x)=x^2$ one-one without looking at the domain -> on $\mathbb R$ it is not; on $[0,\infty)$ it is.
- Using $[-3.7]=-3$ -> the greatest integer not exceeding $-3.7$ is $-4$.
- Cancelling factors before finding the domain -> $\dfrac{x^2-1}{x-1}$ is not defined at $x=1$ even though it simplifies to $x+1$.
- Taking the LCM of periods as always the smallest period -> it is only a period; check for smaller ones.
- Looking for $f^{-1}$ of a function that is not bijective -> first restrict the domain and codomain, then invert.
Quick revision
- $(a,b)=(c,d)$ iff $a=c$ and $b=d$; $n(A\times B)=n(A)\,n(B)$.
- $(A\times B)\cap(C\times D)=(A\cap C)\times(B\cap D)$.
- Number of relations from $A$ to $B$ is $2^{mn}$; on one $n$-set it is $2^{n^2}$.
- Reflexive relations on an $n$-set: $2^{n^2-n}$; symmetric: $2^{n(n+1)/2}$.
- Equivalence relation = reflexive + symmetric + transitive = a partition into classes.
- Number of equivalence relations on 1, 2, 3, 4 elements: 1, 2, 5, 15.
- Functions $A\to B$: $n^m$; one-one: $n(n-1)\cdots(n-m+1)$; bijective when $m=n$: $n!$.
- Onto functions from $m$ elements to 2 elements: $2^m-2$; to 3 elements: $3^m-3\cdot2^m+3$.
- One-one and onto together mean bijective, and only a bijection has an inverse.
- Even: $f(-x)=f(x)$; odd: $f(-x)=-f(x)$; odd with $0$ in its domain gives $f(0)=0$.
- $[x]\le x<[x]+1$, $\{x\}=x-[x]\in[0,1)$, and $\{x\}$ has period 1.
- $\mathrm{sgn}(x)$ has range $\{-1,0,1\}$; $a^x$ has range $(0,\infty)$; $\log_a x$ has domain $(0,\infty)$.
- $f(ax+b)$ has period $\dfrac{T}{\vert a\vert}$ if $f$ has period $T$; $\sin^2x$ and $\vert\sin x\vert$ have period $\pi$.
- $(f\circ g)(x)=f(g(x))$ needs $g(x)$ in the domain of $f$; composition is not commutative.
- $f^{-1}$ swaps domain and range; its graph is the reflection of the graph of $f$ in $y=x$.
Practice questions
A relation $R$ on $\mathbb Z$ is defined by $aRb$ when $a-b$ is even. Which statement is true?
- $R$ is reflexive only
- $R$ is symmetric but not transitive
- $R$ is an equivalence relation
- $R$ is transitive but not symmetric
Answer
C. $R$ is an equivalence relation
$a-a=0$ is even, so reflexive. If $a-b$ is even then $b-a$ is even, so symmetric. If $a-b$ and $b-c$ are even, their sum $a-c$ is even, so transitive. Hence equivalence.
A relation $R$ on $\mathbb N$ is defined by $xRy$ when $x$ divides $y$. Then $R$ is
- reflexive and transitive but not symmetric
- an equivalence relation
- symmetric and transitive but not reflexive
- reflexive and symmetric but not transitive
Answer
A. reflexive and transitive but not symmetric
$x$ divides $x$: reflexive. $x\mid y$ and $y\mid z$ give $x\mid z$: transitive. $2\mid4$ but $4\nmid2$: not symmetric.
The domain of $f(x)=\sqrt{\dfrac{x-1}{3-x}}$ is
- $[1,3]$
- $(-\infty,1]\cup(3,\infty)$
- $(1,3)$
- $[1,3)$
Answer
D. $[1,3)$
Need $\frac{x-1}{3-x}\ge0$ with $x\ne3$. The fraction is zero at $x=1$ and positive for $1<x<3$; for $x>3$ it is negative, for $x<1$ negative. So $1\le x<3$.
The range of $f(x)=\dfrac{x^2}{1+x^2}$, $x\in\mathbb R$, is
- $(0,1)$
- $[0,1)$
- $[0,1]$
- $[0,\infty)$
Answer
B. $[0,1)$
$y=\frac{x^2}{1+x^2}$ gives $x^2=\frac{y}{1-y}$. Need $\frac{y}{1-y}\ge0$, so $0\le y<1$. Check: $y=0$ at $x=0$, and $y=1$ would need $0=1$.
Which of the following functions is even?
- $x\cos x$
- $x^2\sin x$
- $e^x-e^{-x}$
- $\dfrac{e^x+e^{-x}}{2}$
Answer
D. $\dfrac{e^x+e^{-x}}{2}$
Replacing $x$ by $-x$: $x^2\sin x\to-x^2\sin x$ (odd), $x\cos x\to-x\cos x$ (odd), $e^x-e^{-x}\to-(e^x-e^{-x})$ (odd). The last is unchanged, so even.
The period of $f(x)=\sin 2x+\cos 3x$ is
- $\dfrac{2\pi}{3}$
- $2\pi$
- $\pi$
- $6\pi$
Answer
B. $2\pi$
$\sin2x$ has period $\pi$, $\cos3x$ has period $\frac{2\pi}{3}$. In units of $\frac{\pi}{3}$ they are 3 and 2, LCM 6, so $6\cdot\frac{\pi}{3}=2\pi$.
The function $f:\mathbb R\to\mathbb R$, $f(x)=x^3+x$ is
- one-one but not onto
- onto but not one-one
- both one-one and onto
- neither one-one nor onto
Answer
C. both one-one and onto
If $a<b$ then $a^3<b^3$ and $a<b$, so $f(a)<f(b)$: strictly increasing, hence one-one. For onto, $x^3+x=y$ is a cubic with an unbroken graph that rises from very negative to very positive values, so every real $y$ is reached.
$f(x)=x^2-4x+7$ is defined on $\mathbb R$. For $f$ to be onto, the codomain must be
- $[3,\infty)$
- $\mathbb R$
- $[7,\infty)$
- $(3,\infty)$
Answer
A. $[3,\infty)$
$f(x)=(x-2)^2+3\ge3$, with value 3 at $x=2$ and no upper limit. So the range is $[3,\infty)$.
If $f(x)=\dfrac{2x+1}{x-3}$, $x\ne3$, then $f^{-1}(x)$ equals
- $\dfrac{x-3}{2x+1}$
- $\dfrac{3x+1}{x+2}$
- $\dfrac{3x+1}{x-2}$
- $\dfrac{3x-1}{x+2}$
Answer
C. $\dfrac{3x+1}{x-2}$
$y(x-3)=2x+1\Rightarrow x(y-2)=3y+1\Rightarrow x=\frac{3y+1}{y-2}$. Rename: $f^{-1}(x)=\frac{3x+1}{x-2}$. Check: $f(4)=9$ and $\frac{3\cdot9+1}{9-2}=4$.
If $f(x)=2x+3$ and $g(x)=x^2$, then $(f\circ g)(x)$ is
- $2x^2+3$
- $(2x+3)^2$
- $2x^2+9$
- $x^2+2x+3$
Answer
A. $2x^2+3$
$(f\circ g)(x)=f(g(x))=f(x^2)=2x^2+3$. The other order $g(f(x))=(2x+3)^2$ is a different function.
The domain of $f(x)=\ln(x^2-5x+6)$ is
- $[2,3]$
- $(-\infty,2)\cup(3,\infty)$
- $(2,3)$
- $(-\infty,2]\cup[3,\infty)$
Answer
B. $(-\infty,2)\cup(3,\infty)$
Need $x^2-5x+6=(x-2)(x-3)>0$, which holds for $x<2$ or $x>3$. Zero is excluded because $\ln0$ is undefined.
The range of $f(x)=\mathrm{sgn}(x^2-4x+3)$ is
- $\{0,1\}$
- $\{-1,1\}$
- $\{-1,0\}$
- $\{-1,0,1\}$
Answer
D. $\{-1,0,1\}$
$x^2-4x+3=(x-1)(x-3)$ is positive for $x<1$ or $x>3$ (value 1), zero at $x=1,3$ (value 0), negative for $1<x<3$ (value $-1$).
The domain of $f(x)=\dfrac{1}{x-[x]}$ is
- $\mathbb R\setminus\mathbb Z$
- $\mathbb R$
- $\mathbb R\setminus\mathbb N$
- $\mathbb R\setminus\{0\}$
Answer
A. $\mathbb R\setminus\mathbb Z$
$x-[x]=\{x\}$ is zero exactly when $x$ is an integer (including negatives and 0). So all integers are excluded.
If $f(x)=\dfrac{x+1}{x-1}$ for $x\ne1$, then $f(f(x))$ equals
- $-x$
- $\dfrac{x-1}{x+1}$
- $x$
- $\dfrac1x$
Answer
C. $x$
$f(f(x))=\dfrac{\frac{x+1}{x-1}+1}{\frac{x+1}{x-1}-1}=\dfrac{2x/(x-1)}{2/(x-1)}=x$. Test: $f(3)=2$, $f(2)=3$.
If $n(A)=2$ and $n(B)=4$, the number of relations from $A$ to $B$ is
- 64
- 128
- 16
- 256
Answer
D. 256
$A\times B$ has 8 pairs; each relation is a subset, so $2^8=256$.
The number of onto functions from a set of 4 elements to a set of 2 elements is
- 8
- 14
- 16
- 12
Answer
B. 14
Total $2^4=16$ functions, minus the 2 constant ones that miss an element: $14$.
The number of one-one functions from a set of 3 elements to a set of 5 elements is
- 15
- 125
- 10
- 60
Answer
D. 60
First input: 5 choices, second: 4, third: 3. $5\cdot4\cdot3=60$.
The number of symmetric relations on a set of 3 elements is
- 512
- 64
- 8
- 32
Answer
B. 64
Three diagonal pairs and three unordered off-diagonal pairs are each free: $2^{3+3}=64$.
$n(A)=4$, $n(B)=3$ and $n(A\cap B)=2$. The number of elements in $(A\times B)\cap(B\times A)$ is
- 12
- 6
- 2
- 4
Answer
D. 4
$(A\times B)\cap(B\times A)=(A\cap B)\times(B\cap A)$, which has $2\cdot2=4$ elements.
The value of $[2.7]+[-2.7]+\{-2.7\}$ is
- $0.7$
- $-1.7$
- $-0.7$
- $0.3$
Answer
C. $-0.7$
$[2.7]=2$, $[-2.7]=-3$, $\{-2.7\}=-2.7-(-3)=0.3$. Sum $=2-3+0.3=-0.7$.
The number of equivalence relations on the set $\{1,2,3\}$ is
- 3
- 4
- 5
- 6
Answer
C. 5
Count partitions: one block (1 way), three singletons (1 way), one pair plus a singleton (3 ways). Total 5.
The period of $f(x)=\sin\dfrac{\pi x}{3}+\cos\dfrac{\pi x}{2}$ is
- 6
- 12
- 4
- 24
Answer
B. 12
Periods: $\frac{2\pi}{\pi/3}=6$ and $\frac{2\pi}{\pi/2}=4$. LCM of 6 and 4 is 12.
If $f(x)=2x-3$, the value of $f^{-1}(7)$ is
- 11
- 2
- 5
- $\frac14$
Answer
C. 5
Solve $2x-3=7$: $x=5$. Check $f(5)=7$.
If $f(x)=3x+2$ and $g(x)=x^2-1$, then $(g\circ f)(1)$ equals
- 24
- 10
- 16
- 14
Answer
A. 24
$f(1)=5$, then $g(5)=25-1=24$. (The other order gives $f(g(1))=f(0)=2$.)
The number of integers in the domain of $f(x)=\sqrt{6+x-x^2}$ is
- 5
- 6
- 7
- 4
Answer
B. 6
$6+x-x^2\ge0\iff(x-3)(x+2)\le0\iff-2\le x\le3$. Integers: $-2,-1,0,1,2,3$, which is 6.
The number of integers in the range of $f(x)=3\sin x+4$ is
- 7
- 6
- 5
- 8
Answer
A. 7
$-1\le\sin x\le1$ gives $1\le f(x)\le7$, and every value in $[1,7]$ is reached. Integers $1$ to $7$: 7.
Given below are two statements: Statement I: Every function from $A$ to $B$ is a relation from $A$ to $B$. Statement II: Every relation from $A$ to $B$ is a function from $A$ to $B$.
- Both Statement I and Statement II are correct
- Both Statement I and Statement II are incorrect
- Statement I is correct but Statement II is incorrect
- Statement I is incorrect but Statement II is correct
Answer
C. Statement I is correct but Statement II is incorrect
A function is a subset of $A\times B$, so I is correct. A relation may leave an element of $A$ unrelated or relate it to two elements, so II is false.
Given below are two statements: Statement I: $f(x)=[x]$ is an odd function. Statement II: $g(x)=\{x\}$ is an even function.
- Both Statement I and Statement II are correct
- Both Statement I and Statement II are incorrect
- Statement I is correct but Statement II is incorrect
- Statement I is incorrect but Statement II is correct
Answer
B. Both Statement I and Statement II are incorrect
$[0.5]=0$ but $[-0.5]=-1\ne-[0.5]$, so I is false. $\{0.3\}=0.3$ but $\{-0.3\}=-0.3-(-1)=0.7\ne0.3$, so II is false.
Given below are two statements: Statement I: On $A=\{1,2,3\}$ the relation $R=\{(1,1),(2,2)\}$ is reflexive. Statement II: The same relation $R$ is symmetric and transitive.
- Both Statement I and Statement II are correct
- Both Statement I and Statement II are incorrect
- Statement I is correct but Statement II is incorrect
- Statement I is incorrect but Statement II is correct
Answer
D. Statement I is incorrect but Statement II is correct
Reflexive needs $(3,3)$, which is absent, so I is false. Each pair is its own mirror image, and no chain gives a new pair, so $R$ is symmetric and transitive: II is true.
Given below are two statements: Statement I: The product of two odd functions is even. Statement II: The composition $f\circ g$ of two odd functions $f$ and $g$ is odd.
- Both Statement I and Statement II are correct
- Both Statement I and Statement II are incorrect
- Statement I is correct but Statement II is incorrect
- Statement I is incorrect but Statement II is correct
Answer
A. Both Statement I and Statement II are correct
If $f,g$ odd: $f(x)g(x)$ at $-x$ is $(-f(x))(-g(x))=f(x)g(x)$, even. And $f(g(-x))=f(-g(x))=-f(g(x))$, odd. Both correct.
Given below are two statements: Statement I: Every equivalence relation on a set is symmetric. Statement II: The relation 'is perpendicular to' on the set of lines in a plane is transitive.
- Both Statement I and Statement II are correct
- Both Statement I and Statement II are incorrect
- Statement I is correct but Statement II is incorrect
- Statement I is incorrect but Statement II is correct
Answer
C. Statement I is correct but Statement II is incorrect
I is part of the definition. II fails: if $L_1\perp L_2$ and $L_2\perp L_3$ then $L_1\parallel L_3$, not perpendicular.
Assertion (A): $f:\mathbb R\to\mathbb R$, $f(x)=x^2$ is not one-one. Reason (R): $f(-1)=f(1)$ although $-1\ne1$.
- Both A and R are true and R is the correct explanation of A
- Both A and R are true but R is not the correct explanation of A
- A is true but R is false
- A is false but R is true
Answer
A. Both A and R are true and R is the correct explanation of A
Two different inputs share an output, which is exactly what breaks one-one. R is true and directly shows A.
Assertion (A): $f(x)=x^2+1$ is an even function. Reason (R): The graph of every even function is symmetric about the $x$-axis.
- Both A and R are true and R is the correct explanation of A
- Both A and R are true but R is not the correct explanation of A
- A is true but R is false
- A is false but R is true
Answer
C. A is true but R is false
$f(-x)=x^2+1=f(x)$, so A is true. Even functions have graphs symmetric about the $y$-axis, so R is false.
Match List I with List II. List I: a. $\{x\}$ b. $\mathrm{sgn}(x)$ c. $e^x$ d. $\vert x\vert$. List II: i. $\{-1,0,1\}$ ii. $[0,\infty)$ iii. $[0,1)$ iv. $(0,\infty)$
- a-i, b-iii, c-iv, d-ii
- a-iii, b-i, c-ii, d-iv
- a-iii, b-iv, c-i, d-ii
- a-iii, b-i, c-iv, d-ii
Answer
D. a-iii, b-i, c-iv, d-ii
Fractional part lies in $[0,1)$; signum takes three values; $e^x$ is positive; modulus is non-negative.
Match List I with List II. List I (relation on $\mathbb R$): a. $xRy\iff x<y$ b. $xRy\iff x\le y$ c. $xRy\iff\vert x-y\vert\le1$ d. $xRy\iff x\ne y$. List II (exactly these properties): i. reflexive and symmetric only ii. transitive only iii. symmetric only iv. reflexive and transitive only
- a-ii, b-iv, c-i, d-iii
- a-ii, b-iv, c-iii, d-i
- a-iv, b-ii, c-i, d-iii
- a-ii, b-i, c-iv, d-iii
Answer
A. a-ii, b-iv, c-i, d-iii
$x<y$: transitive only. $x\le y$: reflexive, transitive, not symmetric. $\vert x-y\vert\le1$: reflexive and symmetric, but $0R1$ and $1R2$ while $0R2$ fails. $x\ne y$: symmetric; not reflexive; not transitive since $1\ne2$ and $2\ne1$ but $1\ne1$ is false.
Match List I with List II. List I: a. $\sin^2x$ b. $\cos\dfrac x2$ c. $\{x\}$ d. $\sin3x$. List II (period): i. $1$ ii. $\pi$ iii. $4\pi$ iv. $\dfrac{2\pi}{3}$
- a-iii, b-ii, c-i, d-iv
- a-ii, b-iv, c-i, d-iii
- a-i, b-iii, c-ii, d-iv
- a-ii, b-iii, c-i, d-iv
Answer
D. a-ii, b-iii, c-i, d-iv
$\sin^2x=\frac{1-\cos2x}{2}$ has period $\pi$; $\cos\frac x2$ has $\frac{2\pi}{1/2}=4\pi$; $\{x\}$ has 1; $\sin3x$ has $\frac{2\pi}{3}$.
Let $f:\mathbb R\to\mathbb R$ be $f(x)=\dfrac{x}{1+x^2}$. The range of $f$ is
- $[-1,1]$
- $\left[-\frac12,\frac12\right]$
- $\left[0,\frac12\right]$
- $\left(-\frac12,\frac12\right)$
Answer
B. $\left[-\frac12,\frac12\right]$
$y(1+x^2)=x$ gives $yx^2-x+y=0$. For $y\ne0$ a real $x$ needs discriminant $1-4y^2\ge0$, so $\vert y\vert\le\frac12$. $y=0$ is reached at $x=0$. Endpoints $\pm\frac12$ occur at $x=\pm1$.
Real numbers $a,b$ are such that $f(x)=ax+b$ satisfies $f(f(x))=4x+9$ and $f(0)>0$. Then $f(2)$ equals
- $5$
- $-13$
- $11$
- $7$
Answer
D. $7$
$f(f(x))=a^2x+ab+b$. So $a^2=4$ and $b(a+1)=9$. $a=2$ gives $b=3$ (and $f(0)=3>0$). $a=-2$ gives $b=-9$, rejected as $f(0)<0$. So $f(2)=2\cdot2+3=7$.
The function $f:[1,\infty)\to[2,\infty)$ is given by $f(x)=x^2-2x+3$. The value of $f^{-1}(11)$ is
- $4$
- $3$
- $-2$
- $1+\sqrt{11}$
Answer
A. $4$
$f(x)=(x-1)^2+2$. Set $(x-1)^2+2=11$, so $(x-1)^2=9$, $x-1=\pm3$. Domain needs $x\ge1$, so $x=4$. Check $f(4)=16-8+3=11$.