6
$\begingroup$

I was asked to teach the following topics to undergraduate Computer Science (CS) students in a discrete math course:

  • Sequences (definition, convergent sequences, find the limit of a convergent sequence, properties of convergent sequences)
  • Series (partial sums, convergent series, geometric series, harmonic series, test for divergence)
  • Testing series (integral test, comparison tests, alternating series test, absolute convergence, ratio and root tests)
  • Power series
  • Taylor series

This is included in my course because CS students are not required to take a 2nd calculus course. But I was told these topics may be useful if they go to graduate school so we must teach it somewhere.

I cannot really think of any graduate CS courses which may require these topics. How should I motivate my students in this case?

$\endgroup$
8
  • 13
    $\begingroup$ These topics are usually covered in a second calculus course, not a discrete mathematics course. Very unusual. $\endgroup$ Aug 19, 2022 at 11:13
  • 2
    $\begingroup$ Taylor series play a role in Machine Learning (ML), when various functions (e.g., rectifiers) are not smooth, but play a role in optimization. Iterative convergence is an important property of neural networks (NN). $\endgroup$ Aug 19, 2022 at 11:59
  • 8
    $\begingroup$ I would put these subjects under the banner of "numerical methods". I was taught this stuff in my CS course but I thought it had gone out of fashion. Probably very useful for mechanical and electrical engineers, not very useful for most fields of practical programming. But then CS isn't really about teaching specific tools and techniques, it's about teaching problem solving and algorithmic thinking, and it really doesn't matter much what problem domain you use to teach those skills. $\endgroup$ Aug 19, 2022 at 14:59
  • 4
    $\begingroup$ @MichaelKay: We don't always have the luxury of programming in an environment with a full-featured math library. See for example Skyrim mods, which don't even have a log function! $\endgroup$
    – Kevin
    Aug 19, 2022 at 18:36
  • 1
    $\begingroup$ Maybe something related to recursion? Lots of sequences are defined recursively... $\endgroup$
    – mweiss
    Aug 19, 2022 at 21:25

4 Answers 4

28
$\begingroup$

Big O and related notations relate closely to these notions. They are often defined using limits. Although it is also possible to define them without using limits, the style of those definitions is essentially the same as the style of definition used to define a limit: inequalities and several levels of quantifiers. Big O notation is a staple of computer science.

Whether one of your students will use Taylor series is probably luck of the draw, but they're a basic tool of literacy in STEM. One thing I don't quite understand about your list of topics is that you're supposed to be teaching them concepts taught in second-semester calculus (in the US), but the sub-topics include the integral test, and that makes it sound like they've already had a year of calculus.

Is there a textbook that has been used by previous instructors when teaching this class? If so, then you should be able to see how the text integrates these topics into the narrative, and where these topics get used to support other topics.

$\endgroup$
4
  • 6
    $\begingroup$ Taylor series and other numerical methods are maybe less relevant from a formal education standpoint, but they are an incredibly nifty suite of tools to have in your back pocket if you ever find yourself programming in an environment without a proper math library (or need to approximate something weird like the error function). $\endgroup$
    – Kevin
    Aug 19, 2022 at 18:32
  • 2
    $\begingroup$ Taylor series are literally how computers compute all trig and log functions, except maybe some that use newton approximation (sqrt comes to mind). Of course there's lookup tables and all kinds of speedups, but if I ask you "calculate sin(x), you may add, subtract, multiply, and divide", how will you ever do it if you don't know about Taylor? $\endgroup$ Aug 20, 2022 at 15:22
  • 1
    $\begingroup$ @GuntramBlohm With rare exceptions, most functions in standard math libraries are computed using minimax approximations, not Taylor series, and this has been the case for at least four decades. But Taylor series are still a useful concept in various kinds of numerical computation. $\endgroup$
    – njuffa
    Aug 21, 2022 at 13:04
  • 2
    $\begingroup$ Instead of thinking of using any of this stuff - e.g., Taylor series - for actual numerical calculations, like you would if you happened to have a software engineering job that happened to involve actual numerical calculations - as the commentators here seem to have in mind - consider instead how'd you use this stuff in a graduate CS program as the OP requested. This answer is correct: series and sequences are used to analyze algorithms in order to figure out their behavior, e.g. Big-O (and other) performance, and that is very much a staple of graduate computer science. $\endgroup$
    – davidbak
    Aug 21, 2022 at 21:50
8
$\begingroup$

Look at the book “Concrete Mathematics” by Graham, Knuth, and Patashnik, which was written for a course for CS students. Power series show up in the context of generating functions.

I think that list of convergence tests is strange: let them learn it in a calculus course. Or are they not required to take calculus?

Odlyzko’s long survey paper here on asymptotic enumeration might be interesting to skim. It relies often on power series as functions of a complex variable (extracting polar terms), so going beyond the basic power series topics you’ll cover.

$\endgroup$
4
  • $\begingroup$ Not just generating functions. That book is all about analyzing algorithms, probabilities, asympotics, and more by solving complicated sums and recurrences in simpler terms. I imagine, from extensive reading, that this stuff comes up all the time in graduate computer science. I.e., CS theory. Not so much in anything most software engineers actually do during the day (though it does come up for a minority). But the OP said the justification was to prepare students for graduate programs in computer science. $\endgroup$
    – davidbak
    Aug 21, 2022 at 21:43
  • 1
    $\begingroup$ @davidbak I agree that the topics in "Concrete Mathematics" overall are worth knowing for anyone going to CS grad programs, but for many of the topics you mention, the focus is on manipulations of finite series without passage to an infinite series. From the OP's question, I was thinking about references that discuss genuine infinite series when I prepared my answer. $\endgroup$
    – KCd
    Aug 21, 2022 at 21:50
  • $\begingroup$ That's fine. I'm just saying this answer is correct mainly for pointing out the book "Concrete Mathematics" which is nothing if not a) for graduate CS students and b) all oriented around understanding and manipulating series and sequences of all kinds. And aren't recurrence relations typically infinite? (Not sure, I haven't actually understood all of that book ...) $\endgroup$
    – davidbak
    Aug 21, 2022 at 21:53
  • $\begingroup$ I'd also like to support this answer by quoting from the 2nd paragraph on the back cover description (on my 1994 2nd ed copy): "Concrete mathematics is a blending of CONtinuous and disCRETE mathematics. ''More concretely,'' the authors explain, ''it is the controlled manipulation of mathematical formulas, using a collection of techniques for solving problems.'' And those continuous and discrete methods are all about series and sequences ... and I think that's where you get your consideration of infinite series, from the continuous aspect ... $\endgroup$
    – davidbak
    Aug 21, 2022 at 21:55
4
$\begingroup$

Because every single one of those concepts naturally come up when you want to "do" things with computers!

Let make take for example convergent sequences, what does it mean to converge? If we have a sequence $(a_n)$ that means, for any possible $\epsilon$, there is some $N$ such that for any $m>N$ , we have:

$$ |a - a_m | < \epsilon$$

What does this mean? Suppose that I am a computer scientist and I wish to figure out how many terms of the series of $e$ I should take such that the difference between the series evaluation and actual value of $e$ below some error, then naturally the method of answering this systematically would be same as knowing what convergence is.

And more, the series convergence tests tells us what sequences it is worth to try search for bounds and which are not.

And to my understanding, Taylor series is like the swiss knife of modelling. So many problems which may come up in modelling natural phenomena through computers can be treated quite easily be consider Taylor expansions. See here

$\endgroup$
2
$\begingroup$
  1. Rationale for ever learning: They are related to numerical methods and algorithms.

  2. Rationale for (re)covering with CS students. Are a normal part of the calculus sequence (even the AP BC) in the US. Not even some "advanced calc" or "engine math" or God Help Us (real analysis) thingie. but at the end of the second semester and usually a little harder, more "off the path" of just learning antidifferentiation tricks. I'd say the rationale for giving them to CS AGAIN is that in general (IN GENERAL), CS are a bit math weak compared to other STEMS, so perhaps they need a bit more exposure to stuff they should have learned in standard second semester calculus (or even high school AP BC). And this is a part of that course that has some special relevance (more than partial fractions or the like). Note: That this is not a strong rationale, is a marginal one. If you have strong CS students, would not bother, teach 'em new stuff. But if you have weaker ones, than it might make sense...and it's not crazy off the beaten path (see point 1).

[Edited to clarify.]

$\endgroup$
1
  • 2
    $\begingroup$ Not slamming your answer but I do want to say I’m a little confused by most of the parentheses. As far as I can tell, the actual answer you’re giving is "They are related to numerical methods and algorithms", is that right? The rest of your text is unclear to me. $\endgroup$ Aug 20, 2022 at 14:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.