Functions serve many purposes in Python and science and engineering computations. They allow you to reuse code, reducing repetition, and they are the core of many numerical methods in integration, root finding, differential equations, optimization and more. It is essential that you learn how to write functions and use them. This booklet covers basic to advanced topics in Python functions. You will learn about different kinds of arguments, different ways to use functions, and some things that can go wrong with functions.
A PDF and Jupyter notebook containing the narrative discussion and code