Calculus, series & sums

This page connects Mathematica directly to UI calculus and analysis courses. Every block here is designed to turn a standard exercise into a short, disciplined notebook.

Module A
Derivatives and gradients

Start by using D to differentiate functions you already recognise from class. Type these examples into a fresh notebook section titled “Derivatives”.

D[Sin[x], x] D[Exp[-x^2], x] D[x^2 y^3, x] D[x^2 y^3, y] D[Sin[x^2], x]

Make sure that you understand which variable you are differentiating with respect to. When in doubt, use a comment:

(* Differentiate with respect to x, treating y as a constant. *) D[x^2 y^3, x]
📐Calc I & II support 🧠Focus: basic fluency with D
Module B
Integrals: exact vs numeric

Now combine Integrate (exact) and NIntegrate (numeric). The goal is to never trust an unfamiliar exact answer without at least one numeric check.

(* An exact integral *) intExact = Integrate[1/(1 + x^2), {x, 0, 1}] (* Numeric approximation of the same integral *) intNumeric = NIntegrate[1/(1 + x^2), {x, 0, 1}] N[intExact] intNumeric

If the numeric values agree to several decimal places, that is a good sign that the exact answer is correct. Use this pattern for more complicated integrals from problem sheets.

Repeat the same pattern with at least three integrals from your course notes. Keep all of them in the same notebook section titled “Exact vs numeric integrals”.

Integral comparisons 🐝Useful for ODE–Integration Bee
Module C
Limits and local behaviour

Use Limit to make your intuition near singularities precise. Combine limits with plots to see local behaviour.

(* Classic limits *) Limit[Sin[x]/x, x -> 0] Limit[(1 + 1/n)^n, n -> Infinity] (* Compare with numeric approximations *) Table[{n, (1 + 1/n)^n}, {n, 1, 20}]

For each limit you compute, write a short comment: “Does this match what I expected from class?” If the answer is “no” or “not sure”, note that carefully — that’s exactly where learning happens.

Suggested exercise

Take a limit from your Real Analysis I notes. Reproduce it with Limit, and then plot the function near the point to see the behaviour visually.

Notebook structure

Create a section “Limits and pictures” with one subheading per limit, including a comment, the Limit line, and a small plot.

Module D
Power series with Series

Use Series to mirror what is done in class and to check expansion patterns.

(* Series of Exp[x] around 0 up to x^5 *) Series[Exp[x], {x, 0, 5}] // Normal (* Series of Sin[x]/x around 0 up to x^6 *) Series[Sin[x]/x, {x, 0, 6}] // Normal

The // Normal at the end converts the series object into an ordinary polynomial. This is usually easier to read when you are just checking coefficients.

For each example in your analysis notes that involves a Taylor series, add a small Mathematica block that confirms the first few terms.

Series from class 🧩Coefficient checking
Module E
Infinite sums and partial sums

Sum can evaluate many classical series symbolically. Pair that with partial sums to build intuition about convergence speed.

(* Exact value of the Basel series *) sExact = Sum[1/n^2, {n, 1, Infinity}]; (* Partial sums to see convergence *) Table[{N, Sum[1/n^2, {n, 1, N}]}, {N, 5, 50, 5}]

Graph the partial sums against the exact value to see how quickly they approach the limit.

ListLinePlot[ Table[{N, Sum[1/n^2, {n, 1, N}]}, {N, 5, 50, 5}], PlotRange -> All, AxesLabel -> {"N", "Partial sum"} ]

Try the same pattern with other convergent series from your notes, and at least one divergent series, just to see the different behaviour.

Module F
Parameter tricks and simple transforms

Tie Mathematica to techniques you meet in more advanced problems: differentiating under the integral sign, changing variables, or working with a parameter.

(* A parameter-dependent integral *) Clear[I]; I[a_] := Integrate[Exp[-a x^2], {x, 0, Infinity}] Table[{a, I[a]}, {a, 1, 5}] Simplify[I[a], a > 0]

This is the kind of pattern that appears in deeper analysis and in solution write-ups for the ODE–Integration Bee. Mathematica helps you experiment while you learn the underlying proofs.

📊Parameter dependence 🏁Contest preparation