2026

Exploring SymPy or: What, Really, is the Purpose of Computer Algebra Systems?

I recently got interested in singular perturbation theory , and to get help with the algebra, I turned to SymPy. I had tried to use Mathematica in graduate school in the early 90s, but the experience had been sufficiently frustrating that I had steered clear of computer algebra systems since.

SymPy presents itself as a “friendly”, less intimidating alternative, with a more familiar and conventional language and operating model.

Case Study: Singular Perturbation Theory with SymPy

Formal perturbation theory, and in particular singular perturbation theory, are standard topics in applied mathematics, but seem to be largely unknown outside that specific community. Which is a shame, because they are both useful, and intellectually fascinating.

Perturbation expansions, in particular for higher orders, have a reputation for being “cumbersome”, as the say: the algebra quickly becomes both tedious and error-prone. Which is true, but it turns out that the SymPy computer-algebra system can be put to good use in this context.

Hot Chocolate

Hot Chocolate

Occasionally, I like to drink hot chocolate — that is, real hot chocolate, from pure cocoa powder and whole milk; not some (sugared, flavored) drink mix.

So, I was somewhat devastated when I learned that the venerable, time-honored Droste (those of the Droste Effect) seems to have gone tragically out of business.

Some replacement was required: at least as good as the original, and satisfying my various purist predilections.