7GRAPHING FUNCTIONS
Functions with the type R -> R are functions that can be plotted on a graph. This chapter shows how to plot such functions. Tools for making graphs are not part of the Prelude, so we’ll start by discussing how to install and use library modules.
Using Library Modules
There are functions other people have written that we want to use but that are not included in the Prelude. However, such functions exist in library modules that can be imported into our source code file or loaded directly into GHCi. A standard set of library modules comes with GHC (the Glasgow Haskell Compiler we have been using), but other modules require installation. ...
Get Learn Physics with Functional Programming now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.