Math Lab
Home/Class XI/Ch 2/Real-valued functions and their graphs

Real-valued functions and their graphs

A real-valued function of a real variable is a function f:DRf : D \to \mathbb{R} with DRD \subseteq \mathbb{R}. The graph of ff is the set of points (x,f(x))(x, f(x)) in the Cartesian plane. Recognising the graphs of standard functions is a Class-XI skill that you will use every day for the next several years.

The catalogue

1. Constant function

f:RRf : \mathbb{R} \to \mathbb{R}, f(x)=cf(x) = c. Graph: the horizontal line y=cy = c. Domain R\mathbb{R}, range {c}\{c\}.

2. Identity function

f:RRf : \mathbb{R} \to \mathbb{R}, f(x)=xf(x) = x. Graph: the line y=xy = x through the origin at 4545^\circ. Domain R\mathbb{R}, range R\mathbb{R}.

3. Polynomial functions

f(x)=anxn+an1xn1++a1x+a0f(x) = a_n x^n + a_{n-1} x^{n-1} + \dots + a_1 x + a_0 with real coefficients. Domain R\mathbb{R}. Range depends on degree.

  • Linear f(x)=ax+bf(x) = ax + b: a straight line.
  • Quadratic f(x)=ax2+bx+cf(x) = ax^2 + bx + c: a parabola, opening up if a>0a > 0, down if a<0a < 0. Vertex at (b2a, f ⁣(b2a))\left(-\frac{b}{2a},\ f\!\left(-\frac{b}{2a}\right)\right).
  • Cubic f(x)=x3f(x) = x^3: passes through origin, increases everywhere, S-shape.

4. Rational functions

f(x)=p(x)q(x)f(x) = \dfrac{p(x)}{q(x)} where p,qp, q are polynomials. Domain is {xR:q(x)0}\{x \in \mathbb{R} : q(x) \ne 0\}.

The simplest is the reciprocal f(x)=1xf(x) = \dfrac{1}{x}. Domain R{0}\mathbb{R} \setminus \{0\}. Range R{0}\mathbb{R} \setminus \{0\}. Graph: two branches (hyperbola), one in the first quadrant and one in the third.

5. Modulus (absolute value) function

x={x,x0x,x<0|x| = \begin{cases} x, & x \ge 0 \\ -x, & x < 0 \end{cases}

Domain R\mathbb{R}, range [0,)[0, \infty). Graph: V-shape with vertex at origin; right side is y=xy = x, left side is y=xy = -x.

6. Signum function

sgn(x)={1,x>00,x=01,x<0\text{sgn}(x) = \begin{cases} 1, & x > 0 \\ 0, & x = 0 \\ -1, & x < 0\end{cases}

Domain R\mathbb{R}, range {1,0,1}\{-1, 0, 1\}. Graph: three pieces; two horizontal half-lines y=1y = 1 and y=1y = -1, plus a single dot at origin. Note: sgn(x)=xx\text{sgn}(x) = \dfrac{|x|}{x} for x0x \ne 0.

7. Greatest integer (floor) function

x=largest integerx.\lfloor x \rfloor = \text{largest integer} \le x.

Examples: 2.7=2\lfloor 2.7 \rfloor = 2, 2.3=3\lfloor -2.3 \rfloor = -3, 5=5\lfloor 5 \rfloor = 5. Domain R\mathbb{R}, range Z\mathbb{Z}. Graph: a staircase of horizontal segments, each of length 11, with closed dot on the left and open dot on the right of each step.

8. Fractional part function

{x}=xx\{x\} = x - \lfloor x \rfloor. Domain R\mathbb{R}, range [0,1)[0, 1). Graph: a sawtooth with period 11.

9. Square root function

f(x)=xf(x) = \sqrt{x}, domain [0,)[0, \infty), range [0,)[0, \infty). Graph: a curve starting at the origin, increasing slowly. Note: by convention x\sqrt{x} denotes the non-negative root.

10. Exponential, logarithmic, trigonometric

You will meet exe^x, logx\log x, sinx\sin x, cosx\cos x etc. as soon as we get to Chapter 3. They obey the same vocabulary: domain, range, graph.

Properties to remember

  • Even function: f(x)=f(x)f(-x) = f(x). Graph is symmetric about the yy-axis. Examples: x2,x,cosxx^2, |x|, \cos x.
  • Odd function: f(x)=f(x)f(-x) = -f(x). Graph is symmetric about the origin. Examples: x,x3,sinx,sgn(x)x, x^3, \sin x, \text{sgn}(x), 1/x1/x.

For real functions, f(x)=f(0)+(odd part)+(even part)f(x) = f(0) + (\text{odd part}) + (\text{even part}) , but a deeper development of this waits for Class XII.

Worked examples

Example 1. Sketch f(x)=x1f(x) = |x - 1|.

Shift the V-graph of x|x| rightward by 11 unit. Vertex at (1,0)(1, 0). Right arm: y=x1y = x - 1 for x1x \ge 1. Left arm: y=1xy = 1 - x for x<1x < 1.

Example 2. Find the domain and range of f(x)=x2f(x) = \sqrt{x - 2}.

We need x20x - 2 \ge 0, so x2x \ge 2. Domain =[2,)= [2, \infty). The output x2\sqrt{x - 2} ranges over [0,)[0, \infty), so range =[0,)= [0, \infty).

Example 3. Evaluate 1.5+2.7+3\lfloor -1.5 \rfloor + \lfloor 2.7 \rfloor + \lfloor 3 \rfloor.

1.5=2\lfloor -1.5 \rfloor = -2 (the largest integer 1.5\le -1.5 is 2-2, not 1-1). 2.7=2\lfloor 2.7 \rfloor = 2. 3=3\lfloor 3 \rfloor = 3. Sum =2+2+3=3= -2 + 2 + 3 = 3.

Example 4. Find the range of f(x)=x24x+7f(x) = x^2 - 4x + 7.

Complete the square: f(x)=(x2)2+33f(x) = (x - 2)^2 + 3 \ge 3, with equality at x=2x = 2. Range =[3,)= [3, \infty).

Example 5 (harder). Sketch f(x)=sgn(x)x2f(x) = \text{sgn}(x) \cdot x^2.

For x>0x > 0: f(x)=1x2=x2f(x) = 1 \cdot x^2 = x^2 (the right half of a parabola). For x<0x < 0: f(x)=x2f(x) = -x^2 (the negative of x2x^2 , a downward curve in the third/fourth quadrant; here in the third). For x=0x = 0: f(0)=0f(0) = 0. The graph is an S-shaped curve through the origin, looking like x3x^3 but flatter.

Note this function is odd: f(x)=sgn(x)(x)2=sgn(x)x2=f(x)f(-x) = \text{sgn}(-x)(-x)^2 = -\text{sgn}(x) x^2 = -f(x).

Try it yourself

  1. Sketch f(x)=x+2f(x) = |x + 2|.
  2. Find the domain and range of f(x)=1x3f(x) = \frac{1}{x - 3}.
  3. Compute 5.9,3.2,0,0.5\lfloor 5.9 \rfloor, \lfloor -3.2 \rfloor, \lfloor 0 \rfloor, \lfloor -0.5 \rfloor.
  4. Find the range of f(x)=x2+4x+1f(x) = -x^2 + 4x + 1 on R\mathbb{R}.
  5. Sketch f(x)=sgn(x1)f(x) = \text{sgn}(x - 1).
  6. Find domain of f(x)=9x2f(x) = \sqrt{9 - x^2}.
  7. Is f(x)=x4x2f(x) = x^4 - x^2 even, odd, or neither?
  8. Sketch the fractional part function {x}\{x\} on [2,3][-2, 3].
  9. Find the range of f(x)=xxf(x) = \frac{x}{|x|}.
  10. Compute f(g(x))f(g(x)) where f(x)=xf(x) = \lfloor x \rfloor and g(x)=x+0.5g(x) = x + 0.5.
  11. Find domain of f(x)=x+3+15xf(x) = \sqrt{x + 3} + \frac{1}{\sqrt{5 - x}}.
  12. Show that f(x)=sinxf(x) = \sin x is odd and f(x)=cosxf(x) = \cos x is even.

Pitfalls / Tricks

  • For negative real numbers, x\lfloor x \rfloor rounds toward -\infty. So 1.5=2\lfloor -1.5 \rfloor = -2, not 1-1. A common exam trap.
  • x\sqrt{x} always denotes the non-negative root. The equation x=y2x = y^2 does not mean y=xy = \sqrt{x} in general.
  • For the reciprocal 1/x1/x and modulus x|x|, never forget the special value at x=0x = 0.
  • Insight. Memorise the six core graphs , line, parabola, cubic, 1/x1/x, x|x|, x\sqrt{x}. Most graphing questions reduce to shifting, scaling or reflecting one of these.

Practice quiz

Quick check on this topic.

Quiz
Quick check : Real functions and graphs
6 questions · pick the best answer
Q1

Q2

Q3

Q4

Q5

Q6