Algebra of continuous functions

You already know how to check continuity at one point: take the limit, compare it to the function's value there. But real exam functions are rarely that bare — they are sums, products, quotients and chains of simpler pieces, like x2sin⁡x+3x−7x^2\sin x + 3x - 7 or tan⁡xx2+1\dfrac{\tan x}{x^2+1}. Re-deriving a limit from scratch for every such expression would be exhausting. The algebra of continuous functions is the shortcut: a small set of rules that lets you certify a combination of known continuous functions as continuous by inspection, just by naming which building blocks and which operations built it. It is the single most-used tool for the rest of the Continuity and Differentiability chapter.

The core insight

If ff and gg are continuous at x=cx=c, then f±gf\pm g, f⋅gf\cdot g, kfkf, and f∘gf\circ g are continuous at cc, and f/gf/g is continuous at cc provided g(c)≠0g(c)\neq 0.

The core idea

The five rules. Let ff and gg be continuous at x=cx = c. Then every combination below is also continuous at x=cx=c:

f+g,f−g,f⋅g,kf (any constant k)f+g,\quad f-g,\quad f\cdot g,\quad kf\ \text{(any constant }k\text{)}

and, with one extra condition,

fgis continuous at x=c provided g(c)≠0.\frac{f}{g}\quad\text{is continuous at }x=c\text{ provided }g(c)\neq 0.

where: f,gf,g are functions continuous at cc; kk is any real constant; g(c)≠0g(c)\neq 0 means the denominator does not vanish at the point in question.

Composition also preserves continuity. If gg is continuous at cc and ff is continuous at g(c)g(c), then the composite (f∘g)(x)=f(g(x))(f\circ g)(x) = f(g(x)) is continuous at cc. This is what lets you certify functions like sin⁡(x2)\sin(x^2) or ecos⁡xe^{\cos x} without extra work — each is an "outer" continuous function applied to an "inner" continuous function.

Why the quotient rule is the odd one out. Division by zero is undefined, so f/gf/g does not even have a value where g(c)=0g(c)=0 — and a function cannot be continuous at a point where it is not defined. That single exception is why rational functions typically lose continuity at isolated points (the zeros of the denominator), while sums and products of polynomials never do.

The known-continuous toolkit. Constant functions, the identity f(x)=xf(x)=x, all polynomials, sin⁡x\sin x, cos⁡x\cos x, and exe^x are continuous wherever they are defined. Combine these building blocks with the five rules above and you can certify the continuity of almost any expression that shows up in this chapter, purely by recognising its algebraic structure.

Figure
Two continuous inputs f and g combine through five operations into a continuous output, with the quotient branch flagged by the condition g of c not equal to zero
Combining continuous functions f continuous at x = c g continuous at x = c plus minus times k times, composition always continuous at c divide f by g needs g of c not 0 result continuous at c
Derivation AWhy the algebra of continuous functions works

The goal is to show, using only the definition of continuity and the standard limit laws you already know for sums, products, and quotients, that combining two functions that are continuous at x=cx=c by addition, multiplication, or division produces a function that is again continuous at x=cx=c, with division needing the single extra condition that the denominator is non-zero there.

Step 1. Start from the definition. ff is continuous at cc means lim⁡x→cf(x)=f(c)\lim_{x\to c} f(x) = f(c), and likewise lim⁡x→cg(x)=g(c)\lim_{x\to c} g(x) = g(c) for gg. These two limit statements are the only facts we are allowed to use.

Step 2. Apply the sum law for limits. The algebra-of-limits theorem states lim⁡x→c[f(x)+g(x)]=lim⁡x→cf(x)+lim⁡x→cg(x)\lim_{x\to c}[f(x)+g(x)] = \lim_{x\to c} f(x) + \lim_{x\to c} g(x). Substituting the two known limits gives lim⁡x→c[f(x)+g(x)]=f(c)+g(c)\lim_{x\to c}[f(x)+g(x)] = f(c)+g(c). But f(c)+g(c)f(c)+g(c) is exactly the value of the function (f+g)(f+g) at cc, so lim⁡x→c(f+g)(x)=(f+g)(c)\lim_{x\to c}(f+g)(x) = (f+g)(c) — which is precisely the definition of f+gf+g being continuous at cc. The same substitution with a minus sign proves the difference rule.

Step 3. Apply the product law for limits in the same way. lim⁡x→c[f(x)⋅g(x)]=(lim⁡x→cf(x))⋅(lim⁡x→cg(x))=f(c)⋅g(c)=(f⋅g)(c)\lim_{x\to c}[f(x)\cdot g(x)] = \left(\lim_{x\to c} f(x)\right)\cdot\left(\lim_{x\to c} g(x)\right) = f(c)\cdot g(c) = (f\cdot g)(c). So f⋅gf\cdot g is continuous at cc. Taking gg to be the constant function kk (which is trivially continuous everywhere) gives the scalar-multiple rule kfkf as a special case, with no extra work.

Step 4. Apply the quotient law for limits, which carries the proviso lim⁡x→cg(x)≠0\lim_{x\to c} g(x) \neq 0. lim⁡x→cf(x)g(x)=lim⁡x→cf(x)lim⁡x→cg(x)=f(c)g(c)\lim_{x\to c}\dfrac{f(x)}{g(x)} = \dfrac{\lim_{x\to c}f(x)}{\lim_{x\to c}g(x)} = \dfrac{f(c)}{g(c)}, valid exactly when g(c)≠0g(c)\neq 0. This equals (f/g)(c)(f/g)(c), so f/gf/g is continuous at cc whenever the denominator does not vanish there — and the condition is not a technicality, it is inherited directly from the quotient law for limits itself, which is undefined when the denominator's limit is zero. Verified: each step substitutes only the two hypotheses lim⁡f=f(c)\lim f = f(c), lim⁡g=g(c)\lim g = g(c) into the standard limit-algebra theorems for sum, product, and quotient — no new assumption is introduced.

Worked example

Discuss the continuity of f(x)=x2+1x2−5x+6f(x) = \dfrac{x^2+1}{x^2-5x+6}, and separately confirm h(x)=x2sin⁡x+3x−7h(x) = x^2\sin x + 3x - 7 is continuous everywhere.

Step 1. For ff, note both the numerator x2+1x^2+1 and denominator x2−5x+6x^2-5x+6 are polynomials, so each is continuous for every real xx on its own.

Step 2. By the quotient rule, ff is continuous wherever the denominator is non-zero. Factor it: x2−5x+6=(x−2)(x−3)x^2-5x+6=(x-2)(x-3), which vanishes exactly at x=2x=2 and x=3x=3. At those two points ff is not even defined, so continuity is impossible there.

Step 3. Conclusion for ff: continuous on R−{2,3}\mathbb{R}-\{2,3\}, discontinuous nowhere else.

Step 4. For hh, identify the pieces: x2x^2 (polynomial) and sin⁡x\sin x are each continuous everywhere, so by the product rule their product x2sin⁡xx^2\sin x is continuous everywhere. Then 3x3x (polynomial) and −7-7 (constant) are also continuous everywhere, so by the sum/difference rule the total h(x)=x2sin⁡x+3x−7h(x) = x^2\sin x + 3x - 7 is continuous for every real xx.

Answer: ff is continuous on R−{2,3}\mathbb{R}-\{2,3\}, and hh is continuous for all real xx — both conclusions reached without computing a single limit by hand.

Competitive stretch

For p(x)=sin⁡(x2)x2−4p(x) = \dfrac{\sin(x^2)}{x^2-4}, the numerator sin⁡(x2)\sin(x^2) is a composite of two continuous functions (sin⁡\sin outer, x2x^2 inner), hence continuous everywhere by the composition rule; the denominator's zeros at x=±2x=\pm 2 are the only discontinuities, so pp is continuous on R−{−2,2}\mathbb{R}-\{-2,2\}.

Common traps

  • Declaring a rational function continuous everywhere without factoring the denominator. Always locate the zeros of g(x)g(x) first; those points are automatically excluded.
  • Forgetting continuity is pointwise. "Continuous everywhere" for a built-up function must be justified point by point via the rules, not assumed because the pieces "look nice."
  • Misapplying composition. Both conditions are needed: gg continuous at cc and ff continuous at g(c)g(c) — checking only one is not enough.
  • Treating every "nice-looking" function as obviously continuous. ∣x∣|x| is continuous everywhere, but the greatest-integer function [x][x] is discontinuous at every integer; such functions need individual checking, not a blanket assumption.

Ask the tutor: if you're unsure how to break a messy-looking function into its continuous building blocks, ask the AI tutor to walk through two or three examples with you.

Why does the quotient rule need g of c not equal to zero but the sum and product rules do not?

Because division by zero is simply undefined — if g(c)=0g(c)=0 the expression f(c)/g(c)f(c)/g(c) has no value, so f/gf/g is not even defined at cc, let alone continuous there. Sums and products of real numbers are always defined, no matter what f(c)f(c) and g(c)g(c) are, so no such exception arises for them. The condition is not an extra rule you memorise separately; it falls straight out of the quotient law for limits, which itself requires a non-zero denominator limit.

Do I need to prove continuity from limits every time, or can I just cite the rules?

Once you know ff and gg are continuous (either given, or because they are polynomials, sin⁡x\sin x, cos⁡x\cos x, exe^x, or built from these), you can cite the algebra-of-continuous-functions rules directly — that is the entire point of this topic. You only fall back to computing a limit from first principles when the function is not a straightforward combination of known continuous pieces, for example at a point defined piecewise with a special value.

How is this different from the algebra of limits I already learned?

It is the same limit laws, applied at a single point where both functions happen to be continuous. The algebra of limits tells you lim⁡x→c[f(x)+g(x)]=lim⁡f(x)+lim⁡g(x)\lim_{x\to c}[f(x)+g(x)] = \lim f(x) + \lim g(x) in general; the algebra of continuous functions is what happens when you additionally know lim⁡f(x)=f(c)\lim f(x) = f(c) and lim⁡g(x)=g(c)\lim g(x) = g(c), which turns that limit statement directly into the continuity statement lim⁡x→c(f+g)(x)=(f+g)(c)\lim_{x\to c}(f+g)(x) = (f+g)(c). Continuity results are a direct corollary of limit algebra, not a separate set of facts.

Before this

Where this leads