MAT9004 · Mathematical Foundations For Data Science And Ai
Calculus
Single-variable calculus is the largest single block of the MAT9004 exam, and it is pure technique: take a function, apply the right rule, give the exact value. You start by recognising the standard function types (polynomial, exponential, logarithmic, power) and how log–log and semi-log plots fit data, then meet the derivative as a slope and rate of change. The engine of the topic is the full set of differentiation rules — power, product, quotient and chain — which you must execute by hand because the exam supplies a table but no calculator. With f′ you find stationary points (set f′ = 0) and classify them with the second-derivative test, the signature calculus question. The block closes with integration: antiderivatives, the power rule, definite integrals and the Fundamental Theorem of Calculus, with area under a curve as the payoff — and a least-squares link that connects derivatives to regression.
What this chapter covers
- 011.1 Functions and the function types you must recognise
- 021.2 Fitting data: log–log and semi-log plots
- 031.3 Limits — stated, not laboured
- 041.4 The derivative as slope and rate of change
- 051.5 All the differentiation rules (power, product, quotient, chain)
- 061.6 Tangent lines
- 071.7 Increasing / decreasing and stationary points
- 081.8 The first- and second-derivative tests; convexity and concavity
- 091.9–1.10 Applied and global optimisation on a closed interval
- 101.11 Least squares / RSS — the regression connection
- 111.12–1.13 Integration: antiderivatives, definite integrals, the FTC and area
Worked example: differentiate and find a tangent line
- +1(a) Spot the product: f is a product u·v with u = x and v = e2x, so use the product rule f′ = u′v + uv′.
- +1Differentiate each piece: u′ = 1, and by the chain rule v′ = 2e2x. So f′(x) = 1·e2x + x·2e2x = e2x(1 + 2x).
- +1(b) Point and slope at x = 0: f(0) = 0·e0 = 0, and f′(0) = e0(1 + 0) = 1.
- +1Write the tangent: y − f(0) = f′(0)(x − 0), so y = x.
Key terms
- Derivative
- The instantaneous rate of change of f, written f′(x) or df/dx — the slope of the tangent line at x. It is the engine of the whole calculus block: optimisation, tangents and curve sketching all run on it.
- Chain rule
- The rule for differentiating a composition: if y = f(g(x)) then dy/dx = f′(g(x))·g′(x). The most error-prone rule under exam time, because it is easy to forget the inner derivative g′(x).
- Stationary point
- A point where f′(x) = 0 — a candidate local maximum, minimum or inflection. You classify it with the sign of f″: negative means a maximum, positive a minimum, zero is inconclusive.
- Second-derivative test
- At a stationary point a, if f″(a) < 0 the point is a local maximum, if f″(a) > 0 a local minimum. If f″(a) = 0 the test fails and you fall back to a sign-of-f′ table.
- Fundamental Theorem of Calculus
- Links the two halves of calculus: the definite integral of f from a to b equals F(b) − F(a), where F is any antiderivative of f. It is how you turn an antiderivative into an exact area.
Calculus FAQ
Which differentiation rule do I reach for first?
Read the structure of the function before differentiating. A product of two x-terms (like x·e2x) needs the product rule; a quotient needs the quotient rule; anything 'inside' something else (like e2x or (3x+1)5) needs the chain rule for the inner derivative. Most marks are lost by jumping in — name the structure first, then apply the matching rule, and remember the chain rule's inner derivative.
How do I classify a stationary point if the second-derivative test fails?
When f″(a) = 0 the second-derivative test is inconclusive. Fall back to the first-derivative (sign) test: check the sign of f′ just to the left and just to the right of a. Negative-then-positive is a minimum, positive-then-negative is a maximum, and the same sign on both sides is a point of inflection, not an extremum.
Do I need to memorise derivative and integral formulas for the exam?
No — a formula sheet with the standard derivative and integral table is provided inside the paper. What you cannot outsource is executing the rules: applying the product, quotient and chain rules by hand, setting f′ = 0, and back-substituting to find exact values. Spend revision time on the method, not on cramming the table.
What is the least-squares / RSS bit doing in a calculus chapter?
It is the payoff that links calculus to data science. Fitting a line by least squares means minimising the residual sum of squares (RSS), and you minimise it the same way as any function: differentiate with respect to the parameters, set the derivative to zero, and solve. It is the single-variable optimisation method applied to regression.
Exam move
Make the chain differentiate → set f′ = 0 → classify with f″ automatic, because it is the most-examined sequence in the unit. Drill all four differentiation rules on fresh functions until you stop reaching for the formula sheet for the rules themselves (only the standard table is supplied). For optimisation, always check the endpoints when the domain is a closed interval [a, b] — a global extremum can sit at an endpoint, not a stationary point. Keep answers exact: fractions in lowest terms, no decimals unless asked. For integration, the move is the same every time — find an antiderivative, then apply the Fundamental Theorem F(b) − F(a); show the antiderivative line, because that is where the method mark lives.