MCS-212 · Block 2 Unit 1

Sets, Relations and Functions

Section 9 of 9

Block 2 · Unit 1Sets, Relations and Functions14 min · Section 9 of 9

1.9Operations on functions and composition

Covers IGNOU MCS-212 §1.5.2, E29–E30; programme guide: composition of functions, operations on functions

Functions can be combined to build new ones. Adding or multiplying them works pointwise, like adding two price lists item by item. Composition — feeding the output of one function into another — is how programs are built from smaller routines: round(sqrt(x)) is a composition.

Pointwise operations

For real functions ff and gg:

OperationDefinitionDomain
sum(f+g)(x)=f(x)+g(x)(f + g)(x) = f(x) + g(x)Df∩DgD_f \cap D_g
difference(f−g)(x)=f(x)−g(x)(f - g)(x) = f(x) - g(x)Df∩DgD_f \cap D_g
product(fg)(x)=f(x) g(x)(fg)(x) = f(x)\,g(x)Df∩DgD_f \cap D_g
quotient(fg)(x)=f(x)g(x)\left(\frac{f}{g}\right)(x) = \frac{f(x)}{g(x)}Df∩DgD_f \cap D_g minus the points where g(x)=0g(x) = 0

Two functions are equal when they have the same domain and the same value at every point of it. f(x)=x2+5f(x) = x^2 + 5 on R\mathbb{R} and g(x)=x2+5g(x) = x^2 + 5 on C\mathbb{C} are different functions, because their domains differ.

Composition

  • Composition is usually not commutative: with f(x)=x2f(x) = x^2 and g(x)=x+1g(x) = x + 1, (f∘g)(x)=(x+1)2(f \circ g)(x) = (x + 1)^2 but (g∘f)(x)=x2+1(g \circ f)(x) = x^2 + 1.
  • Composition is always associative: f∘(g∘h)=(f∘g)∘hf \circ (g \circ h) = (f \circ g) \circ h, because both mean “apply hh, then gg, then ff”.
  • If ff is a bijection, f∘f−1f \circ f^{-1} and f−1∘ff^{-1} \circ f are identity functions.

Products of permutations

The product fgfg of two permutations of the same set is their composition f∘gf \circ g: apply gg first, then ff.

Key takeaways

  • f+gf + g, f−gf - g, fgfg: pointwise, on Df∩DgD_f \cap D_g; fg\frac{f}{g} also excludes zeros of gg.
  • (f∘g)(x)=f(g(x))(f \circ g)(x) = f(g(x)): gg first, then ff.
  • Composition is associative but usually not commutative.
  • The product fgfg of permutations is f∘gf \circ g; compute it element by element.

Practice questions

Answer on paper first, then check. The explanation matters more than the letter you chose.

Question 1 · multiple choice

If f(x)=x2f(x) = x^2 and g(x)=x+1g(x) = x + 1, what is (f∘g)(2)(f \circ g)(2)?

Show answer

Answer: B. 9

g(2)=3g(2) = 3, then f(3)=9f(3) = 9. Option 1 is (g∘f)(2)=4+1(g \circ f)(2) = 4 + 1, which applies ff first.

Question 2 · multiple choice

What is the domain of fg\frac{f}{g} for f(x)=xf(x) = x and g(x)=x−2g(x) = x - 2 (both on R\mathbb{R})?

Show answer

Answer: C. R∖{2}\mathbb{R} \setminus \{2\}

Only zeros of the denominator gg are removed. Option 4 also removes 0, where f(x)=0f(x) = 0, but a zero numerator is allowed.

Question 3 · multiple choice

Which statement about composition of functions is always true?

Show answer

Answer: D. f∘(g∘h)=(f∘g)∘hf \circ (g \circ h) = (f \circ g) \circ h

Composition is associative. Option 1 (commutativity) fails, e.g. for x2x^2 and x+1x + 1.

Question 4 · multiple choice

For f=(123312)f = \begin{pmatrix} 1 & 2 & 3 \\ 3 & 1 & 2 \end{pmatrix} and g=(123132)g = \begin{pmatrix} 1 & 2 & 3 \\ 1 & 3 & 2 \end{pmatrix}, what is fg=f∘gfg = f \circ g?

Show answer

Answer: D. (123321)\begin{pmatrix} 1 & 2 & 3 \\ 3 & 2 & 1 \end{pmatrix}

1→g1→f31 \xrightarrow{g} 1 \xrightarrow{f} 3; 2→g3→f22 \xrightarrow{g} 3 \xrightarrow{f} 2; 3→g2→f13 \xrightarrow{g} 2 \xrightarrow{f} 1. Option 1 is gfgf (apply ff first).

Question 5 · multiple choice

For f(x)=1xf(x) = \frac{1}{x} and g(x)=x3+2g(x) = x^3 + 2, what is (fg)(x)(fg)(x)?

Show answer

Answer: B. x3+2x\frac{x^3 + 2}{x}

The product multiplies the values: 1x⋅(x3+2)\frac{1}{x} \cdot (x^3 + 2). Option 1 is the sum f+gf + g (as printed in the study material’s answer). Option 3 is f∘gf \circ g.

Question 6 · short answer

Let f(x)=x+1f(x) = \sqrt{x + 1} for x≥−1x \geq -1 and g(x)=x3g(x) = x^3 for x∈Rx \in \mathbb{R}. Find f∘gf \circ g and g∘fg \circ f with their domains.

Show worked answer

(f∘g)(x)=f(x3)=x3+1(f \circ g)(x) = f(x^3) = \sqrt{x^3 + 1}; it is defined when x3+1≥0x^3 + 1 \geq 0, i.e. x3≥−1x^3 \geq -1, i.e. x≥−1x \geq -1. (g∘f)(x)=g(x+1)=(x+1)3=(x+1)3/2(g \circ f)(x) = g(\sqrt{x + 1}) = (\sqrt{x + 1})^3 = (x + 1)^{3/2}; it is defined when ff is defined, i.e. x≥−1x \geq -1. The two functions are different: at x=0x = 0, f∘gf \circ g gives 11 and g∘fg \circ f gives 11, but at x=3x = 3, f∘gf \circ g gives 28≈5.29\sqrt{28} \approx 5.29 while g∘fg \circ f gives 88.

↑ ↓ move↵ openTab switch type